/* --- Core Styles --- */
body {
    background-color: #000000;
    background-image: radial-gradient(ellipse at top, rgba(255, 255, 255, 0.12), transparent 60%);
    background-attachment: fixed;
    color: #EAEAEA;
    font-family: 'Montserrat', sans-serif;
    /* CSS variables for cursor tracking are set on #hero-section */
}
.font-title { font-family: 'Cormorant Garamond', serif; }
.font-body { font-family: 'Montserrat', sans-serif; }
.font-anton-sc { font-family: 'Anton SC', sans-serif; }
.font-zalando { font-family: 'Zalando Sans Expanded', sans-serif; }

/* --- Lenis Recommended Styles --- */
html.lenis, body.lenis {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

.lenis.lenis-scrolling iframe {
  pointer-events: none;
}
/* --- End Lenis Styles --- */

.grid-item img, .grid-item video, #modal-content, #viewer-image {
    will-change: transform, opacity;
}
.overlay, #modal-backdrop, #image-viewer {
     will-change: opacity;
}
#hero-bg-effect {
    will-change: background;
}
#hero-mouse-glow {
    will-change: transform;
}

/* --- Grainy Background Effect --- */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 300 300"><filter id="noise"><feTurbulence type="fractalNoise" baseFrequency=".8" numOctaves="4" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23noise)"/></svg>');
    opacity: 0.15;
    z-index: -1;
    pointer-events: none;
}

/* --- Custom Scrollbar & Hovers --- */
.gallery-scrollbar::-webkit-scrollbar { height: 4px; }
.gallery-scrollbar::-webkit-scrollbar-track { background: #1a1a1a; }
.gallery-scrollbar::-webkit-scrollbar-thumb { background-color: #ffffff; border-radius: 20px; }
.grid-item .overlay { transition: opacity 0.5s cubic-bezier(0.23, 1, 0.32, 1); background: linear-gradient(to top, rgba(0, 0, 0, 0.75), transparent 70%); }
.grid-item:hover .overlay { opacity: 1; }
.grid-item img, .grid-item video { transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1); }
.grid-item:hover img, .grid-item:hover video { transform: scale(1.05); }

/* --- Modal & Viewer Transitions --- */
#modal-backdrop { transition: opacity 0.4s ease-in-out; }
#modal-content { transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.5s ease; transform: scale(0.95) translateY(20px); opacity: 0; }
#modal-backdrop.open #modal-content { transform: scale(1) translateY(0); opacity: 1; }
#modal-gallery { opacity: 0; transition: opacity 0.5s ease 0.2s; scroll-behavior: smooth; }
#modal-gallery.loaded { opacity: 1; }
#image-viewer { transition: opacity 0.3s ease-in-out; }
#viewer-image { transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.gallery-image-item, #viewer-image.zoom-in { cursor: zoom-in !important; }
.gallery-image-item:hover, #viewer-image.zoom-in:hover { cursor: zoom-in !important; }
#viewer-image.zoom-out { cursor: zoom-out !important; }
#viewer-image.grabbing { cursor: grabbing !important; }
#viewer-image.grab { cursor: grab !important; }

/* --- UI Elements & Animations --- */
.like-button { position: relative; }
@keyframes fly-up {
    0% { transform: translateY(0) scale(0.8); opacity: 1; }
    100% { transform: translateY(-60px) scale(1.5); opacity: 0; }
}
.flying-heart { position: absolute; top: 0; left: 0; pointer-events: none; animation: fly-up 0.6s cubic-bezier(0.17, 0.84, 0.44, 1) forwards; fill: currentColor; }

/* SEO FIX: Improved touch targets for links */
.footer-link { 
    position: relative; 
    text-decoration: none; 
    color: #EAEAEA; 
    padding: 2px 0; /* Increase hit area slightly */
}
.footer-link::after { content: ''; position: absolute; width: 100%; transform: scaleX(0); height: 1px; bottom: -2px; left: 0; background-color: #EAEAEA; transform-origin: bottom right; transition: transform 0.25s ease-out; }
.footer-link:hover::after { transform: scaleX(1); transform-origin: bottom left; }

#mobile-menu { transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1); }
.menu-link { transition: transform 0.3s ease; }
.menu-link:hover { transform: translateX(10px); }
.glowing-btn { box-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 15px #fff; animation: glow-animation 2.5s infinite ease-in-out; }
@keyframes glow-animation {
    0%, 100% { box-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 15px #fff; }
    50% { box-shadow: 0 0 10px #fff, 0 0 20px #fff, 0 0 30px #fff; }
}
@keyframes glow-animation-subtle {
    0%, 100% { box-shadow: 0 0 6px #fff, 0 0 10px #fff; }
    50% { box-shadow: 0 0 10px #fff, 0 0 18px #fff; }
}

.featured-badge {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    background-color: #ffffff;
    color: #000000;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    z-index: 10;
}

/* --- Highlight Effect for 'About' click --- */
#hero-subtitle {
     transition: text-shadow 0.5s ease-out, color 0.5s ease-out;
     text-shadow: none; 
}
.highlight-effect {
    color: #ffffff; 
    text-shadow: 0 0 12px rgba(255, 255, 255, 0.9),
                 0 0 22px rgba(255, 255, 255, 0.7); 
}


/* --- Custom Cursor --- */
@media (hover: hover) and (pointer: fine) {
    body { 
        cursor: none; 
    }
    .grid-item { 
        cursor: none; 
    }
}

.grid-item[role="button"]:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: -2px;
    cursor: pointer !important;
}
.custom-cursor { position: fixed; left: 0; top: 0; width: 20px; height: 20px; border-radius: 50%; background-color: #ffffff; mix-blend-mode: difference; pointer-events: none; transform: translate(-50%, -50%); transition: width 0.4s cubic-bezier(0.23, 1, 0.32, 1), height 0.4s cubic-bezier(0.23, 1, 0.32, 1), border 0.4s cubic-bezier(0.23, 1, 0.32, 1), background-color 0.4s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.2s ease-out; z-index: 9999; display: flex; align-items: center; justify-content: center; opacity: 0; }
.custom-cursor.view-state { width: 90px; height: 90px; background-color: rgba(0, 0, 0, 0); border: 1px solid #ffffff; }
.custom-cursor.link-hover-state { width: 10px; height: 10px; }
.cursor-text-inner { color: #ffffff; font-family: 'Montserrat', sans-serif; font-size: 14px; font-weight: 300; opacity: 0; transform: translateY(5px); transition: opacity 0.3s ease 0.1s, transform 0.3s ease 0.1s; }
.view-state .cursor-text-inner { opacity: 1; transform: translateY(0); }

/* --- Scroll Animations --- */
.scroll-animate { opacity: 0; transform: translateY(50px); transition: opacity 0.8s cubic-bezier(0.23, 1, 0.32, 1), transform 0.8s cubic-bezier(0.23, 1, 0.32, 1); }
.scroll-animate.is-visible { opacity: 1; transform: translateY(0); }

/* --- Preloader & Loaders --- */
#preloader { position: fixed; inset: 0; background-color: #000; z-index: 10000; display: flex; align-items: center; justify-content: center; transition: opacity 0.7s ease-in-out; }
#preloader.loaded { opacity: 0; pointer-events: none; }
#modal-loader { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background-color: #000; z-index: 5; transition: opacity 0.3s ease; }

.loader {
    width: 50px;
    aspect-ratio: 1;
    display: flex;
    color: #ffffff; 
    background: linear-gradient(currentColor 0 0) right / 51% 100%,
        linear-gradient(currentColor 0 0) bottom / 100% 51%;
    background-repeat: no-repeat;
    animation: l16-0 2s infinite linear 0.25s;
}
.loader::before {
    content: "";
    width: 50%;
    height: 50%;
    background: currentColor;
    animation: l16-1 0.5s infinite linear;
}
@keyframes l16-0 {
    0%, 12.49% { transform: rotate(0deg); }
    12.5%, 37.49% { transform: rotate(90deg); }
    37.5%, 62.49% { transform: rotate(180deg); }
    62.5%, 87.49% { transform: rotate(270deg); }
    87.5%, 100% { transform: rotate(360deg); }
}
@keyframes l16-1 {
    0% { transform: perspective(80px) rotate3d(-1, -1, 0, 0); }
    80%, 100% { transform: perspective(80px) rotate3d(-1, -1, 0, -180deg); }
}

/* --- Modal Scroll Arrow --- */
#scroll-arrow-btn { transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out; }
#scroll-arrow-btn.visible { opacity: 1; pointer-events: auto; animation: pulse-horizontal 2s infinite ease-in-out; }
@keyframes pulse-horizontal { 0%, 100% { transform: translateY(-50%) translateX(0); } 50% { transform: translateY(-50%) translateX(4px); } }

/* --- Logo Wall --- */
.logo-item { transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1); }
.logo-item:hover { transform: scale(1.1); }
.logo-item img { opacity: 0.6; transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1); width: 100%; height: auto; filter: brightness(0) invert(1); }
.logo-item:hover img { opacity: 1; }
.logo-item img.dark-icon { filter: brightness(1) invert(0); }
.logo-item img[src*="idr4gD0qFb"] {
    filter: brightness(0) invert(1) !important; 
}

/* --- Hero Title Animation --- */
#hero-title span { opacity: 0; }
.animate-flicker { display: inline-block; animation: flicker-letter 1.5s ease-out forwards; }
@keyframes flicker-letter { 0%{opacity:0} 30%{opacity:1} 35%{opacity:.2} 40%{opacity:1} 60%{opacity:.5} 100%{opacity:1} }

/* --- Hero Section Specific Styles --- */
#hero-section { 
    position: relative; 
    width: 100%; 
    min-height: 100vh; 
    min-height: 100svh;
    display: flex; 
    align-items: center; 
    justify-content: flex-start; 
    overflow: hidden; 
    padding: 11rem 6% 6rem 6%;
    box-sizing: border-box; 
    --mouse-x: 50%;
    --mouse-y: 50%;
}

#hero-bg-effect {
    position: absolute;
    inset: 0;
    background: 
        linear-gradient(to right, #000000 0%, #000000 40%, transparent 80%) 0% 0% / 100% 100%, 
        linear-gradient(to bottom right, transparent 50%, rgba(255, 255, 255, 0.3) 70%, rgba(255, 255, 255, 0.1) 90%) 0% 0% / 150% 150%;
    background-repeat: no-repeat;
    z-index: 1;
    animation: subtle-gradient-shift 15s infinite alternate ease-in-out;
}

#hero-mouse-glow {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at var(--mouse-x) var(--mouse-y), rgba(255, 255, 255, 0.35) 0%, transparent 50%);
    background-repeat: no-repeat;
    z-index: 2;
}

@keyframes subtle-gradient-shift {
    0% {
        background-position: 0% 0%, 0% 0%; 
        background-size: 100% 100%, 150% 150%; 
    }
    100% {
        background-position: 0% 0%, -20% -20%;
        background-size: 100% 100%, 170% 170%;
    }
}

#hero-content { position: relative; z-index: 3; display: flex; flex-direction: column; gap: 1.5rem; max-width: 60%; } 

#hero-title { 
    font-size: clamp(3.5rem, 10vw, 8rem); 
    line-height: 1.0; 
    color: #EAEAEA; 
    text-transform: uppercase; 
    letter-spacing: -0.05em; 
    margin-bottom: 2rem; 
} 

#hero-subtitle { font-size: 1rem; line-height: 1.6; color: #B0B0B0; max-width: 600px; padding: 0.5rem; }

#hero-skills { 
    position: absolute; 
    right: 6%; 
    /* FIX: Moved down from 50% to 55% to avoid overlapping with top popup */
    top: 55%; 
    transform: translateY(-50%); 
    z-index: 3; 
    color: #EAEAEA; 
    font-family: 'Montserrat', sans-serif; 
    font-size: 1rem; 
    line-height: 1.8; 
    text-align: right; 
    display: flex; 
    flex-direction: column;
    align-items: flex-end; 
}

#hero-skills span { display: block; margin-bottom: 1rem; font-weight: 600; } 

#hero-skills ul { list-style: none; padding: 0; margin: 0; }
#hero-skills li:hover,
.skill-link:hover {
    color: #ffffff;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.7),
                 0 0 16px rgba(255, 255, 0.5);
}
.skill-link {
    color: #B0B0B0;
    font-weight: 300;
    transition: all 0.3s ease-out;
    text-decoration: none;
    line-height: 1.8;
    display: inline-block;
    /* SEO FIX: Improved touch target sizing */
    padding: 2px 0; 
}

.hero-badge {
    display: flex; 
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0.2rem 0.8rem;
    font-size: 0.85rem;
    height: 1.8rem;
    font-weight: 500; 
    border-radius: 9999px; 
    margin: 0.2rem 0;
    background-color: rgba(255, 255, 255, 0.1);
    color: #EAEAEA;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-family: 'Montserrat', sans-serif;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.hero-badge-animated {
    background-color: #ffffff;
    color: #000000;
    font-weight: 600;
    animation: pulse-and-shine 2.5s infinite ease-in-out;
}

@keyframes pulse-and-shine {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 6px #fff, 0 0 10px #fff;
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 12px #fff, 0 0 20px #fff, 0 0 30px #fff;
    }
}

/* ===== Services Section Styles ===== */
.service-card {
    position: relative;
    overflow: hidden;
    transition: box-shadow 0.4s ease-in-out, transform 0.4s ease-in-out;
}

.service-promo-badge {
    position: absolute;
    top: -1px; 
    right: -1px;
    background-color: #ffffff;
    color: #000000;
    font-family: 'Anton SC', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.5rem 1rem 0.5rem 1.25rem;
    border-radius: 0 0 0 1.5rem; 
    z-index: 3; 
    letter-spacing: 0.05em;
    animation: shake-badge 6s infinite ease-in-out 1s;
}

@keyframes shake-badge {
    0%, 10%, 100% { transform: rotate(0deg); }
    2% { transform: rotate(2deg); }
    4% { transform: rotate(-2deg); }
    6% { transform: rotate(2deg); }
    8% { transform: rotate(0deg); }
}

.highlight-card {
    animation: pulse-halo 1.5s infinite ease-in-out;
}

@keyframes pulse-halo {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
    50% { box-shadow: 0 0 20px 5px rgba(255, 255, 255, 0.7), 0 0 8px 0 rgba(255, 255, 255, 0.5); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

.service-card h3 {
    font-family: 'Anton SC', sans-serif !important; 
    font-weight: 400; 
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.service-card > * {
    position: relative;
    z-index: 2;
}

/* --- "Looking for more?" Styles --- */
#expand-services-chevron {
    transition: transform 0.3s ease-in-out;
}
#additional-services-container {
    transition: height 0.5s cubic-bezier(0.23, 1, 0.32, 1), 
                opacity 0.3s ease-in-out;
    padding-bottom: 1rem;
}

@keyframes float {
    0% { transform: translate(-50%, -50%) translate(0px, 0px) rotate(0deg) scale(1); }
    25% { transform: translate(-50%, -50%) translate(-5px, 3px) rotate(-1deg) scale(1.02); }
    50% { transform: translate(-50%, -50%) translate(3px, -4px) rotate(1deg) scale(1); }
    75% { transform: translate(-50%, -50%) translate(4px, 2px) rotate(0.5deg) scale(1.01); }
    100% { transform: translate(-50%, -50%) translate(0px, 0px) rotate(0deg) scale(1); }
}

.additional-service-pill {
    position: absolute;
    cursor: pointer;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.2);
    top: 50%;
    left: 50%;
    transition: all 0.7s cubic-bezier(0.23, 1, 0.32, 1);
}

.additional-service-pill:hover {
    transform: translate(-50%, -50%) scale(1.1); 
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
    z-index: 10; 
}

#additional-services-container.animate-active .additional-service-pill {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    animation: float 20s infinite alternate ease-in-out;
}

/* Pill Positions */
#additional-services-container .additional-service-pill:nth-child(1) { transition-delay: 0.1s; }
#additional-services-container.animate-active .additional-service-pill:nth-child(1) { top: 30%; left: 25%; animation-duration: 18s; animation-delay: 0s; }

#additional-services-container .additional-service-pill:nth-child(2) { transition-delay: 0.2s; }
#additional-services-container.animate-active .additional-service-pill:nth-child(2) { top: 20%; left: 70%; animation-duration: 22s; animation-delay: -5s; }

#additional-services-container .additional-service-pill:nth-child(3) { transition-delay: 0.3s; }
#additional-services-container.animate-active .additional-service-pill:nth-child(3) { top: 70%; left: 20%; animation-duration: 20s; animation-delay: -10s; }

#additional-services-container .additional-service-pill:nth-child(4) { transition-delay: 0.4s; }
#additional-services-container.animate-active .additional-service-pill:nth-child(4) { top: 65%; left: 75%; animation-duration: 23s; animation-delay: -3s; }

#additional-services-container .additional-service-pill:nth-child(5) { transition-delay: 0.5s; }
#additional-services-container.animate-active .additional-service-pill:nth-child(5) { top: 45%; left: 50%; animation-duration: 19s; animation-delay: -8s; }


@media (max-width: 768px) {
    #hero-section { 
        flex-direction: column; 
        align-items: flex-start; 
        padding: 7.7rem 4% 6rem 4%;
        min-height: auto; 
    }
    #hero-content { max-width: 90%; text-align: left; gap: 1rem; } 
    #hero-title { font-size: 12vw; margin-bottom: 1rem; } 
    #hero-subtitle { font-size: 0.9rem; max-width: 100%; }
    #hero-skills { 
        position: relative; 
        top: auto; 
        right: auto; 
        transform: none; 
        text-align: left; 
        margin-top: 2rem; 
        margin-left: 0; 
        align-items: flex-start;
    }
     #hero-skills span { margin-bottom: 0.75rem; } 
    #hero-bg-effect { 
        background: linear-gradient(to right, #000000 0%, #000000 40%, transparent 80%), linear-gradient(to bottom right, transparent 50%, rgba(255, 255, 255, 0.2) 70%, rgba(255, 255, 255, 0.05) 90%); 
        animation: none;
     } 
     #hero-mouse-glow {
        display: none;
     }
    #main-footer {
        margin-top: 15rem;
    }
    .service-promo-badge {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem 0.4rem 1rem;
        border-radius: 0 0 0 1.2rem;
    }
    #additional-services-container.animate-active .additional-service-pill:nth-child(1) { top: 20%; left: 20%; }
    #additional-services-container.animate-active .additional-service-pill:nth-child(2) { top: 30%; left: 80%; }
    #additional-services-container.animate-active .additional-service-pill:nth-child(3) { top: 75%; left: 25%; }
    #additional-services-container.animate-active .additional-service-pill:nth-child(4) { top: 70%; left: 75%; }
    #additional-services-container.animate-active .additional-service-pill:nth-child(5) { top: 45%; left: 50%; }
}

/* --- Scroll Down Prompt --- */
@keyframes bounce-down {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

#scroll-down-prompt {
    position: absolute;
    bottom: 5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    color: rgba(255, 255, 255, 0.7);
    transition: opacity 0.3s ease, color 0.3s ease, background-color 0.4s ease, backdrop-filter 0.4s ease, padding 0.4s cubic-bezier(0.23, 1, 0.32, 1), width 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    width: 2.5rem; 
    height: 2.5rem; 
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-family: 'Montserrat', sans-serif; 
    font-size: 0.8rem; 
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-decoration: none;
}

#scroll-down-prompt .scroll-down-icon {
    width: 1.5rem; 
    height: 1.5rem; 
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease;
    animation: bounce-down 2.5s infinite ease-in-out;
    position: absolute;
}

#scroll-down-prompt .scroll-down-text {
    position: relative; 
    opacity: 0;
    transform: translateY(15px); 
    transition: opacity 0.3s ease, transform 0.3s ease, font-size 0.1s ease;
    white-space: nowrap;
    font-size: 0;
}

#scroll-down-prompt:hover {
    color: #ffffff;
    background-color: rgba(0, 0, 0, 0.4);
    width: auto;
    padding-left: 1.25rem; 
    padding-right: 1.25rem; 
}

#scroll-down-prompt:hover .scroll-down-icon {
    opacity: 0;
    transform: translateY(-15px); 
    animation: none; 
}

#scroll-down-prompt:hover .scroll-down-text {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.1s; 
    font-size: 0.8rem;
}

/* --- Language Dropdown --- */
#lang-dropdown-menu.visible {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}
#lang-dropdown-button svg { transition: transform 0.2s ease-in-out; }
#lang-dropdown-button[aria-expanded="true"] svg { transform: rotate(180deg); }
#lang-dropdown-menu button.active {
    font-weight: 600;
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.1);
}

/* --- Footer --- */
#main-footer {
    margin-top: 24rem; 
}

#footer-bg-text-wrapper {
    position: absolute; 
    z-index: 2; 
    pointer-events: none;
    width: 100%;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
}
#footer-bg-text {
    display: block;
    position: relative;
    font-size: 27vw;
    color: rgba(255, 255, 255, 0.12);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 35%, rgba(0,0,0,0) 85%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 35%, rgba(0,0,0,0) 85%);
    /* FIX: Changed to -85% so it sits squarely ON TOP of the footer edge */
    transform: translateY(-85%);
}

/* --- Promo Modal --- */
#promo-modal { transition: opacity 0.4s ease-in-out; }
#promo-backdrop { transition: opacity 0.4s ease-in-out; }
#promo-content { transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.5s ease; }
#promo-modal.open { opacity: 1; pointer-events: auto; }
#promo-modal.open #promo-content { opacity: 1; transform: scale(1); }

/* --- Sticky Bottom "Call Now" Pop-up --- */
@keyframes wiggle-in {
    0% { transform: rotate(0deg) scale(1); }
    10% { transform: rotate(-5deg) scale(1.1); }
    20% { transform: rotate(5deg) scale(1.1); }
    30% { transform: rotate(-3deg) scale(1.1); }
    40% { transform: rotate(3deg) scale(1.1); }
    50% { transform: rotate(0deg) scale(1.1); }
    100% { transform: rotate(0deg) scale(1); }
}

#call-now-popup {
    animation-name: glow-animation;
    animation-duration: 2.5s;
    animation-iteration-count: infinite;
    animation-timing-function: ease-in-out;
    animation-play-state: paused; 
    transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.3s ease, padding 0.4s ease;
    box-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 15px #fff;
    justify-content: center; 
    white-space: nowrap; 
}

#call-now-popup.opacity-100 {
    animation-play-state: running;
    animation: wiggle-in 0.7s ease-out 0.5s 1, glow-animation 2.5s infinite ease-in-out;
}

#call-now-popup:hover {
    animation-play-state: paused;
    transform: translateY(-5px) scale(1.03);
    box-shadow: 0 0 10px #fff, 0 0 20px #fff, 0 0 30px #fff;
    padding-left: 1.5rem; 
    padding-right: 1.5rem; 
}

.call-now-text,
.call-now-phone-text {
    white-space: nowrap;
    overflow: hidden;
    transition: max-width 0.4s cubic-bezier(0.23, 1, 0.32, 1), 
                opacity 0.2s ease-out,
                margin-left 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.call-now-text {
    max-width: 100px; 
    opacity: 1;
    margin-left: 0.5rem; 
}

.call-now-phone-text {
    max-width: 0px; 
    opacity: 0;
    margin-left: 0;
}

#call-now-popup:hover .call-now-text {
    max-width: 0px;
    opacity: 0;
    margin-left: 0;
}

#call-now-popup:hover .call-now-phone-text {
    max-width: 200px; 
    opacity: 1;
    margin-left: 0.5rem; 
}

/* --- Hero Call Now Pop-up (Top Right) --- */
#hero-call-popup {
    z-index: 50; 
    box-shadow: 0 0 15px rgba(0,0,0,0.2), inset 1px 1px 0 rgba(255,255,255,0.1);
    /* FIX: Force position to top: 6rem to clear the text area */
    top: 6rem;
}

#hero-call-popup.is-visible {
    opacity: 1;
    transform: translateX(0);
}

#hero-call-popup .bg-white {
    animation: pulse-hero-icon 3s infinite ease-in-out;
}

@keyframes pulse-hero-icon {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(255, 255, 255, 0); }
}

/* Mobile Adjustment for Hero Pop-up */
@media (max-width: 768px) {
    #hero-call-popup {
        transform: scale(0.85) translateX(20px); 
        transform-origin: right center;
    }
    
    #hero-call-popup.is-visible {
        transform: scale(0.85) translateX(0);
        opacity: 1;
    }
}

/* --- SEO & Performance Optimizations --- */
/* FIX: Removed #main-footer from here to prevent clipping of "PULSE" text */
#llm-seo-content, #logo-wall {
    content-visibility: auto;
    contain-intrinsic-size: 1px 500px; /* Estimate height to prevent scroll jump */
}

@media (prefers-reduced-motion: reduce) {
    *, ::before, ::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    #hero-bg-effect, #hero-mouse-glow { display: none; }
}