/* =============================================
   POONAM PATIL PORTFOLIO — STYLES
   ============================================= */

/* ── Variables ── */
:root {
    --bg: #F2EFE9;
    --text: #111111;
    --text-muted: #888888;
    --nav-h: 72px;
    --ease: cubic-bezier(0.77, 0, 0.175, 1);
    --ease-out: cubic-bezier(0.25, 1, 0.5, 1);
}

/* ── Reset ── */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    cursor: none;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    display: block;
    max-width: 100%;
}

/* ── Custom Cursor (Figma Style) ── */
.cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 28px;
    height: 28px;
    background-image: url('data:image/svg+xml,<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.5 3.5L22.5 12L13.5 14L10 24L5.5 3.5Z" fill="%237C3AED" stroke="white" stroke-width="2.5" stroke-linejoin="round"/></svg>');
    background-size: contain;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-4.5px, -3px);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cursor-follower {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 9998;
    background: #7C3AED;
    color: white;
    font-size: 13px;
    font-family: inherit;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 20px;
    border-top-left-radius: 0;
    transform: translate(14px, 14px);
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3);
    white-space: nowrap;
    opacity: 0.95;
    transition: transform 0.2s ease, opacity 0.3s ease;
}

.cursor-follower::after {
    content: "Poonam";
    letter-spacing: 0.5px;
}

/* cursor hover states */
body:has(a:hover) .cursor,
body:has(.project-card:hover) .cursor,
body:has(.lightbox-trigger:hover) .cursor {
    transform: translate(-4.5px, -3px) scale(1.15) rotate(-10deg);
}

body:has(a:hover) .cursor-follower,
body:has(.project-card:hover) .cursor-follower,
body:has(.lightbox-trigger:hover) .cursor-follower {
    opacity: 0;
    transform: translate(25px, 25px) scale(0.8);
}

/* ── Navbar ── */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-h);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 48px;
    z-index: 100;
    background: rgba(247, 245, 240, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.logo a {
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: -0.3px;
    color: var(--text-muted);
    transition: color 0.3s;
}

.logo a:hover {
    color: var(--text);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    position: relative;
    transition: color 0.3s;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: var(--text);
    transition: width 0.35s var(--ease-out);
}

.nav-links a:hover {
    color: var(--text);
}

.nav-links a:hover::after {
    width: 100%;
}

/* ── Hero ── */
.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: var(--nav-h);
}

.hero-bg-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 140vw;
    height: 140vh;
    min-width: 1000px;
    z-index: 0;
    pointer-events: none;
    user-select: none;
    display: flex;
    justify-content: center;
    align-items: center;
    will-change: transform;
}

/* Ensure the Lottie SVG inherits the exact dimensions, fixing Safari aspect-ratio and scaling issues */
.hero-bg-text svg {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 700;
    letter-spacing: -2px;
    line-height: 1;
    margin-bottom: 1rem;
    overflow: hidden;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.6rem);
    font-weight: 400;
    color: var(--text-muted);
    overflow: hidden;
}

.reveal-text {
    display: inline-block;
    opacity: 0;
    transform: translateY(110%);
    animation: revealUp 1s var(--ease) forwards;
}

.reveal-text.delay {
    animation-delay: 0.18s;
}

@keyframes revealUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── Section Heading ── */
.section-heading {
    font-size: clamp(0.8rem, 1.2vw, 1rem);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--text-muted);
    padding: 6rem 48px 2.5rem;
}

/* ── Webflow Replica Portfolio Container ── */
.portfolio {
    padding-bottom: 8rem;
}

.portfolio-list {
    display: flex;
    flex-direction: column;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Flip odd items using RTL like Webflow does */
.portfolio-item:nth-child(odd) {
    direction: rtl; 
}
.portfolio-item:nth-child(odd) .light-bg-color,
.portfolio-item:nth-child(odd) .tagline,
.portfolio-item:nth-child(odd) .details {
    direction: ltr; /* Reset text direction inside */
    text-align: right;
}

.portfolio-item:nth-child(even) {
    direction: ltr;
}
.portfolio-item:nth-child(even) .light-bg-color,
.portfolio-item:nth-child(even) .tagline,
.portfolio-item:nth-child(even) .details {
    text-align: left;
}

.project-link {
    display: block;
    position: relative;
    margin-bottom: 5rem;
    text-decoration: none;
    transition: transform 0.5s var(--ease-out);
    opacity: 0;
    transform: translateY(40px);
    animation: revealUp 0.8s var(--ease-out) forwards;
}

.project-link:hover {
    transform: scale(0.98);
}

.case-study-part {
    display: flex;
    position: relative;
    z-index: 0;
}

.case-study {
    flex: 1; /* Automatically takes remaining width */
    position: relative;
    display: flex;
}

.case-study-spacer {
    width: 42%;
}

.light-bg-color {
    width: 100%;
    height: 82vh;
    min-height: 500px;
    max-height: 650px;
    border-radius: 20px;
    padding: 60px 60px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 40px 80px rgba(0,0,0,0.06);
}

.tagline {
    font-size: clamp(2rem, 3.5vw, 40px);
    font-weight: 700;
    line-height: 1.25;
    margin-top: 8%;
    margin-bottom: auto;
    max-width: 15ch;
    transition: transform 0.4s var(--ease-out);
}

.details {
    margin-bottom: 8%;
    margin-top: auto;
}

.company {
    font-size: 23px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 0.2rem;
    letter-spacing: 1px;
}

.role {
    font-size: 22px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: -0.6px;
    opacity: 0.85;
}

.mockup-part {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: row;
    align-items: center;
    z-index: 1;
    pointer-events: none; /* Let clicks pass through to link */
}

.mockup-spacer {
    width: 50%;
}

.laptopmockup {
    max-width: 53%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.18));
    transition: transform 0.6s var(--ease-out);
    margin: 0 auto;
}

/* Hover effect on image */
.project-link:hover .laptopmockup {
    transform: translateY(-12px) scale(1.03);
}

.project-link:hover .tagline {
    transform: translateY(-5px);
}
/* ── Resume Section ── */
.resume-section {
    padding: 2rem 48px 6rem;
}

.resume-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1100px;
    margin: 0 auto;
}

.resume-column {
    min-width: 0;
}

.resume-category {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.resume-item {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.resume-item:last-child {
    border-bottom: none;
}

.resume-item-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.3rem;
}

.resume-item-header h4 {
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: -0.3px;
}

.resume-date {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}

.resume-company {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 0.6rem;
}

.resume-desc {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #555;
}

.skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.skill-tag {
    display: inline-block;
    font-size: 0.88rem;
    font-weight: 500;
    padding: 0.5rem 1.1rem;
    border-radius: 100px;
    border: 1.5px solid rgba(0, 0, 0, 0.1);
    color: var(--text);
    background: rgba(0, 0, 0, 0.02);
    transition: all 0.3s ease;
}

.skill-tag:hover {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

/* ── Footer ── */
footer {
    padding: 6rem 48px;
    border-top: 1px solid rgba(0, 0, 0, 0.07);
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-heading {
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -1.5px;
    line-height: 1;
}

.footer-email {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-muted);
    border-bottom: 1px solid currentColor;
    display: inline-block;
    padding-bottom: 2px;
    transition: color 0.3s;
    width: fit-content;
}

.footer-email:hover {
    color: var(--text);
}

.footer-copy {
    margin-top: 3rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ── Case Study Detail Pages ── */
.case-study-detail {
    min-height: 100vh;
    padding: calc(var(--nav-h) + 4rem) 48px 6rem;
    background: var(--card-bg, #F7F5F0);
}

.case-detail-container {
    max-width: 1100px;
    margin: 0 auto;
}

.case-detail-header {
    margin-bottom: 4rem;
    color: var(--card-color, #111);
}

.case-detail-header h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -1.5px;
    line-height: 1.1;
    margin-bottom: 2rem;
}

.case-meta-detail {
    display: flex;
    gap: 4rem;
    flex-wrap: wrap;
}

.meta-item h3 {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    font-weight: 700;
    margin-bottom: 0.4rem;
    opacity: 0.65;
}

.meta-item p {
    font-size: 1.1rem;
    font-weight: 500;
}

.case-detail-image {
    width: 100%;
    margin-bottom: 4rem;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.12);
}

.case-detail-image img {
    width: 100%;
    height: auto;
    display: block;
    max-height: 65vh;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.4);
    padding: 2rem;
}

.gallery-thumbnails {
    margin: 4rem 0;
}

.gallery-thumbnails h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
    color: var(--card-color, #111);
}

.thumbnails-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 0.75rem;
}

.thumbnail {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    opacity: 0.65;
}

.thumbnail:hover,
.thumbnail.active {
    opacity: 1;
    border-color: var(--card-color, #111);
    transform: scale(1.04);
}

.case-detail-content {
    color: var(--card-color, #111);
    max-width: 820px;
}

.case-detail-content section {
    margin-bottom: 3rem;
}

.case-detail-content h2 {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

.case-detail-content p {
    font-size: 1rem;
    line-height: 1.8;
    opacity: 0.85;
}

.case-nav {
    margin-top: 6rem;
    padding-top: 2.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.case-nav a {
    text-decoration: none;
    color: var(--card-color, #111);
    font-weight: 600;
    font-size: 1rem;
    padding: 0.7rem 1.4rem;
    border: 1.5px solid currentColor;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.case-nav a:hover {
    background: var(--card-color, #111);
    color: var(--card-bg, #fff);
}

/* ── Lightbox Gallery ── */
.lightbox-trigger {
    position: relative;
    cursor: pointer;
    display: inline-block;
    border-radius: 8px;
    overflow: hidden;
}

.lightbox-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(10, 64, 129, 0.9);
    color: white;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    white-space: nowrap;
}

.lightbox-trigger:hover .lightbox-overlay {
    opacity: 1;
    transform: translate(-50%, -60%);
}

.lightbox-trigger:hover img {
    filter: brightness(0.95);
}

.lightbox-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(10, 10, 10, 0.98);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.lightbox-modal.show {
    opacity: 1;
    visibility: visible;
}

.lightbox-close {
    position: absolute;
    top: 25px; right: 35px;
    color: white;
    font-size: 45px;
    font-weight: 300;
    cursor: pointer;
    transition: 0.3s;
    user-select: none;
    z-index: 2;
}
.lightbox-close:hover { color: #5B9BD5; transform: scale(1.1); }

.lightbox-prev, .lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 40px;
    padding: 30px 20px;
    cursor: pointer;
    transition: 0.3s;
    user-select: none;
    z-index: 2;
}
.lightbox-prev:hover, .lightbox-next:hover { color: #5B9BD5; }
.lightbox-prev { left: 10px; }
.lightbox-next { right: 10px; }

.lightbox-content {
    max-width: 85%;
    max-height: 85vh;
    object-fit: contain;
    transition: opacity 0.25s ease, transform 0.25s ease;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-counter {
    position: absolute;
    bottom: 25px;
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    letter-spacing: 3px;
    font-weight: 500;
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .project-link {
        margin-bottom: 2rem;
    }
    
    .portfolio-item:nth-child(odd),
    .portfolio-item:nth-child(even) {
        direction: ltr !important; 
    }
    .portfolio-item:nth-child(odd) .light-bg-color,
    .portfolio-item:nth-child(even) .light-bg-color {
        text-align: center !important;
    }

    .case-study-spacer, .mockup-spacer {
        display: none !important;
    }

    .mockup-part {
        position: relative;
        height: auto;
        margin-bottom: -40px;
        z-index: 2;
    }

    .laptopmockup {
        max-width: 90%;
    }

    .light-bg-color {
        height: auto;
        min-height: auto;
        padding: 80px 30px 40px;
    }

    .tagline {
        margin-top: 0;
        margin-bottom: 2rem;
    }
}