/* --- 1. CORE RESET & FONTS --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #0a0a0a;
    color: #ffffff;
    font-family: 'Inter', -apple-system, system-ui, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- 2. FIXED BACKGROUND --- */
.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('images/brand/tool-bg.png') repeat;
    background-size: 400px;
    opacity: 0.15; /* Slightly lowered for a cleaner read */
    z-index: -1;
    pointer-events: none;
}

/* --- 3. RESPONSIVE HEADER --- */
header {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 6%;
    background: transparent; /* Starts transparent */
    transition: background 0.5s cubic-bezier(0.25, 1, 0.5, 1), backdrop-filter 0.5s ease, border-bottom 0.5s ease;
    z-index: 9999;
    border-bottom: 1px solid transparent;
}

.scrolled {
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
    width: 150px;
    height: 50px;
}

.logo img {
    position: absolute;
    top: 15px;
    height: 120px;
    width: auto;
    z-index: 10000; 
    filter: drop-shadow(0px 8px 16px rgba(0,0,0,0.8)); 
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.logo img:hover {
    transform: scale(1.05);
}

/* Desktop Nav */
.desktop-nav ul {
    display: flex;
    list-style: none;
    gap: 35px;
    align-items: center;
}

.nav-item { position: relative; }

.nav-item a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: color 0.3s ease;
}

.nav-item:hover > a { color: #fff; }

.btn-outline {
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 10px 24px;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1) !important;
}

.btn-outline:hover {
    background: #fff;
    color: #000 !important;
}

/* Dropdowns */
.dropdown {
    position: absolute;
    top: 120%;
    left: -20px;
    background: rgba(15, 15, 15, 0.95);
    backdrop-filter: blur(10px);
    min-width: 220px;
    padding: 15px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    border: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.nav-item:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    top: 100%;
}

.dropdown a {
    display: block;
    padding: 12px 20px;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.6);
}

.dropdown a:hover {
    background: rgba(255,255,255,0.05);
    color: #fff;
    padding-left: 25px; /* Smooth indent on hover */
}

/* --- 4. HERO SECTION (home, about, contact, 404) --- */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 5%;
    position: relative;
    background-color: transparent;
    /* Base imagery; frosted veil matches .glass-panel vibe, stepped darker */
    background-image:
        url('images/brand/hero-tools.png'),
        url('images/brand/tool-bg.png');
    background-repeat: no-repeat, repeat;
    background-position: center, top left;
    background-size: contain, 400px;
}

/* Same language as .glass-panel: gradient + backdrop blur; slightly darker / more opaque */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: linear-gradient(
        145deg,
        rgba(12, 12, 14, 0.82) 0%,
        rgba(5, 5, 6, 0.94) 100%
    );
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.hero h1 {
    position: relative;
    z-index: 1;
    font-size: clamp(3rem, 12vw, 7rem);
    font-weight: 900;
    letter-spacing: -2px;
    line-height: 0.9;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.92);
    text-shadow:
        0 1px 3px rgba(0, 0, 0, 0.75),
        0 14px 44px rgba(0, 0, 0, 0.6);
}

/* Match softened hero headline outline */
.hero h1 .highlight {
    --hl-outline: rgba(255, 255, 255, 0.82);
}

.hero p {
    position: relative;
    z-index: 1;
    font-size: clamp(0.9rem, 2vw, 1.2rem);
    letter-spacing: 6px;
    color: rgba(255, 255, 255, 0.58);
    text-transform: uppercase;
    margin-bottom: 45px;
    text-shadow:
        0 1px 3px rgba(0, 0, 0, 0.6),
        0 4px 22px rgba(0, 0, 0, 0.6);
}

.cta-button {
    padding: 20px 45px;
    background: #fff;
    color: #000;
    text-decoration: none;
    font-weight: 800;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.3s ease;
}

.hero .cta-button {
    position: relative;
    z-index: 1;
    background: rgba(240, 240, 240, 0.94);
    color: #0c0c0c;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255,255,255,0.2);
}

.hero .cta-button:hover {
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
}

/* --- 5. SERVICES GRID --- */
.services-preview {
    padding: 80px 6%;
    background: #050505;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    align-items: stretch;
}

.service-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px 40px; 
    border-radius: 2px;
    cursor: pointer;
    will-change: transform;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.6s ease;
    text-decoration: none !important;
    color: #fff !important; 
}

.service-card h3 {
    color: #ffffff !important;
}

.card-link {
    text-decoration: none;
    color: inherit;
}

.card-link::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
}

.service-card p {
    color: rgba(255, 255, 255, 0.6) !important;
}

.glass-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    z-index: 0;
    overflow: hidden;
    background: linear-gradient(145deg, rgba(20,20,20,0.6) 0%, rgba(5,5,5,0.95) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.glass-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: -150%;
    width: 65%;
    height: 100%;
    pointer-events: none;
    background: linear-gradient(
        105deg,
        transparent 0%,
        rgba(255, 255, 255, 0.04) 35%,
        rgba(255, 255, 255, 0.18) 50%,
        rgba(255, 255, 255, 0.04) 65%,
        transparent 100%
    );
    transform: skewX(-22deg);
    transition: left 0.85s cubic-bezier(0.22, 1, 0.36, 1);
}

.card-content {
    position: relative;
    z-index: 1;
    text-align: center;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    gap: 20px;
}

/* This targets the button ONLY when it's inside the service cards */
.services-preview .btn-outline {
    margin-top: auto !important; 
    align-self: center !important;
}

.service-card:hover,
.service-card:focus-within {
    transform: translateY(-12px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.9);
}

.service-card:hover .glass-panel,
.service-card:focus-within .glass-panel {
    border-color: rgba(255, 255, 255, 0.15);
    background: linear-gradient(145deg, rgba(30,30,30,0.8) 0%, rgba(10,10,10,0.95) 100%);
}

.service-card:hover .glass-panel::before,
.service-card:focus-within .glass-panel::before {
    left: 150%;
}

/* --- 6. THE PROCESS SECTION --- */
.process-section { padding: 100px 6%; max-width: 1400px; margin: 0 auto; }
.process-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.subtitle { color: rgba(255, 255, 255, 0.4); text-transform: uppercase; letter-spacing: 4px; font-size: 0.75rem; display: block; margin-bottom: 15px; }
.process-text h2 { font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1.1; margin-bottom: 30px; }
/*
 * .highlight: Barlow Condensed 900 — hollow outline (transparent fill + stroke).
 * Saira + -webkit-text-stroke often draws stray inner edges on R; Barlow strokes cleanly
 * with a similar condensed, technical headline feel.
 */
.highlight {
    font-family: "Barlow Condensed", sans-serif;
    font-weight: 900;
    font-style: normal;
    font-synthesis: none;
    letter-spacing: 0.06em;
    --hl-outline: rgba(255, 255, 255, 0.93);
    color: rgba(0, 0, 0, 0) !important;
    -webkit-text-fill-color: rgba(0, 0, 0, 0) !important;
    -webkit-text-stroke-width: clamp(0.7px, 0.055em, 1.05px);
    -webkit-text-stroke-color: var(--hl-outline);
    text-shadow: none !important;
    text-rendering: geometricPrecision;
    -webkit-font-smoothing: antialiased;
}
.process-text p { color: rgba(255,255,255,0.7); max-width: 500px; margin-bottom: 40px; }
.stats-row { display: flex; gap: 50px; }

.stat-item {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.stat-item strong {
    display: block;
    margin: 0 0 2px;
    font-size: 1.8rem;
    font-weight: 900;
    text-transform: uppercase;
}

.stat-item span {
    margin: 0;
    font-size: 0.8rem;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
}
/* Home process photo: inset frame; tilt+zoom via main.js when motion OK, else hover zoom only */
.process-image {
    position: relative;
    height: 500px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
}

/* Index only: no section transform so 3D isn’t flattened; overflow visible so tilt isn’t clipped */
.process-image.process-image-interactive {
    overflow: visible;
}

.process-image-interactive {
    perspective: 900px;
}

/* Shell tilts as one unit: photo + inset frame (::after) */
.process-tilt-shell {
    position: absolute;
    inset: 0;
    border-radius: 6px;
    transform-style: preserve-3d;
    transform-origin: center center;
    /* Default; main.js overrides for smooth zoom vs snappy tilt follow */
    transition: transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
}

.process-tilt-shell::after {
    content: "";
    position: absolute;
    inset: 16px;
    border: 1px solid rgba(255, 255, 255, 0);
    border-radius: 3px;
    box-shadow: none;
    pointer-events: none;
    z-index: 2;
    opacity: 0;
    transition: opacity 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}

.process-image-interactive:hover .process-tilt-shell::after {
    opacity: 1;
    border-color: rgba(255, 255, 255, 0.38);
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.04),
        0 10px 28px rgba(0, 0, 0, 0.5);
}

.process-image .image-inner {
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: 6px;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.process-tilt-shell .image-inner {
    transform: translateZ(0);
    transform-style: preserve-3d;
}

.process-image-interactive .process-home-photo {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

@media (max-width: 1024px) {
    .process-image { height: min(420px, 55vw); }
}

@media (prefers-reduced-motion: reduce) {
    .process-tilt-shell {
        transition: none;
    }

    .process-tilt-shell::after {
        transition: none;
    }
}

/* --- 7. PORTFOLIO TEASER --- */
.portfolio-teaser { padding: 100px 6% 0 6%; background: #050505; }
.section-header { text-align: center; margin-bottom: 60px; }
.portfolio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.portfolio-item { height: 400px; position: relative; overflow: hidden; cursor: pointer; }
.portfolio-img { width: 100%; height: 100%; background-size: cover; background-position: center; transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); }
.portfolio-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); display: flex; justify-content: center; align-items: center; opacity: 0; transition: opacity 0.4s ease; }
.portfolio-overlay span { text-transform: uppercase; letter-spacing: 3px; font-weight: 700; font-size: 0.8rem; border-bottom: 1px solid #fff; padding-bottom: 5px; }
.portfolio-item:hover .portfolio-img { transform: scale(1.1); }
.portfolio-item:hover .portfolio-overlay { opacity: 1; }

/* --- 8. ANIMATIONS & REVEALS (Cleaned Up) --- */
.animate-hero { opacity: 0; transform: translateY(30px); animation: fadeUpHero 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; }
.animate-hero.delay-1 { animation-delay: 0.2s; }
.animate-hero.delay-2 { animation-delay: 0.4s; }
@keyframes fadeUpHero { to { opacity: 1; transform: translateY(0); } }

/* Mobile: opacity-only hero intro avoids blurry subpixel text after transform (esp. over imagery) */
@keyframes fadeUpHeroMobile {
    from { opacity: 0; }
    to { opacity: 1; }
}

.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }
.reveal.delay-1 { transition-delay: 0.15s; }
.reveal.delay-2 { transition-delay: 0.3s; }

/* Index home process block: fade-only reveal so parent never has transform (flattening kills rotateX/Y on the photo) */
.process-section.reveal.reveal--tilt {
    transform: none;
    transition: opacity 0.8s ease-out;
}

.process-section.reveal.reveal--tilt.active {
    transform: none;
}

/*
 * Showcase scroll-in: match original look (clip open) while keeping container opacity at 1.
 * Plain .reveal opacity on this parent prevents slide opacity crossfades from compositing (looks like a hard cut).
 */
.showcase-slider-container.reveal {
    transform: none;
    opacity: 1;
    clip-path: inset(0 0 100% 0);
    transition: clip-path 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.showcase-slider-container.reveal.active {
    clip-path: inset(0 0 0 0);
}

/* --- 9. MOBILE MENU & RESPONSIVE --- */
.menu-toggle { display: none; flex-direction: column; gap: 6px; cursor: pointer; z-index: 10001; }
.menu-toggle span { width: 30px; height: 2px; background: #fff; transition: all 0.3s ease; }
.menu-toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background: rgba(5, 5, 5, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 88px 0 48px;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.45s cubic-bezier(0.25, 1, 0.5, 1), visibility 0.45s;
}

.mobile-nav-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-panel {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    padding: 0 8%;
    pointer-events: auto;
}

.mobile-nav-links {
    list-style: none;
    width: 100%;
    margin: 0;
    padding: 0;
    text-align: left;
}

.mobile-nav-links > li {
    margin: 0 0 6px;
    transform: translateY(16px);
    opacity: 0;
    transition: opacity 0.45s cubic-bezier(0.25, 1, 0.5, 1), transform 0.45s cubic-bezier(0.25, 1, 0.5, 1);
}

.mobile-nav-overlay.active .mobile-nav-links > li {
    transform: translateY(0);
    opacity: 1;
}

.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(1) { transition-delay: 0.04s; }
.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(2) { transition-delay: 0.08s; }
.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(3) { transition-delay: 0.12s; }
.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(4) { transition-delay: 0.16s; }
.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(5) { transition-delay: 0.2s; }
.mobile-nav-overlay.active .mobile-nav-links > li:nth-child(6) { transition-delay: 0.24s; }

/* Top-level links — match desktop .nav-item a (not browser default blue) */
.mobile-nav-links > li > a {
    display: block;
    padding: 14px 0;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.75);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    transition: color 0.25s ease;
}

.mobile-nav-links > li > a:hover,
.mobile-nav-links > li > a:focus-visible {
    color: #fff;
}

/* Expandable sections — same typography as desktop section headers */
.mobile-nav-details {
    border: none;
    padding: 0;
    margin: 0;
}

.mobile-nav-details summary {
    list-style: none;
    cursor: pointer;
    padding: 14px 28px 14px 0;
    position: relative;
    color: rgba(255, 255, 255, 0.75);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    transition: color 0.25s ease;
}

.mobile-nav-details summary::-webkit-details-marker {
    display: none;
}

.mobile-nav-details summary::after {
    content: '';
    position: absolute;
    right: 4px;
    top: 50%;
    width: 8px;
    height: 8px;
    margin-top: -6px;
    border-right: 2px solid rgba(255, 255, 255, 0.45);
    border-bottom: 2px solid rgba(255, 255, 255, 0.45);
    transform: rotate(45deg);
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.mobile-nav-details[open] summary {
    color: #fff;
}

.mobile-nav-details[open] summary::after {
    transform: rotate(225deg);
    margin-top: -2px;
}

.mobile-nav-details summary:hover {
    color: #fff;
}

/* Glass sub-panels — mirror .dropdown */
.mobile-submenu {
    list-style: none;
    margin: 8px 0 18px;
    padding: 12px 0;
    background: rgba(15, 15, 15, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 2px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55);
}

.mobile-submenu li {
    margin: 0;
}

.mobile-submenu a {
    display: block;
    padding: 12px 20px;
    text-decoration: none;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: rgba(255, 255, 255, 0.55);
    transition: color 0.2s ease, background 0.2s ease, padding-left 0.2s ease;
}

.mobile-submenu a:hover,
.mobile-submenu a:focus-visible {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    padding-left: 24px;
}

.mobile-nav-overlay .mobile-nav-cta {
    display: inline-block;
    margin-top: 12px;
    padding: 12px 28px;
    text-align: center;
    color: rgba(255, 255, 255, 0.85) !important;
}

.mobile-nav-overlay .mobile-nav-cta:hover,
.mobile-nav-overlay .mobile-nav-cta:focus-visible {
    color: #000 !important;
}

@media (max-width: 1024px) {
    /* Sit above .mobile-nav-overlay (10000) so the hamburger stays clickable to close */
    #main-header {
        z-index: 10002;
    }

    .desktop-nav { display: none; }
    .menu-toggle { display: flex; }
    .hero h1 { font-size: 3.5rem; }
    .process-grid, .footer-main { grid-template-columns: 1fr; gap: 40px; }
    .portfolio-grid { grid-template-columns: 1fr; }

    /* Mobile header logo — compact; #main-header bumps specificity */
    #main-header .logo {
        width: 48px;
        height: 16px;
    }

    #main-header .logo img {
        top: 4px;
        height: 40px;
        transform: none;
    }

    #main-header .logo img:hover {
        transform: scale(1.05);
    }

    html {
        -webkit-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }

    .animate-hero {
        transform: none;
        animation-name: fadeUpHeroMobile;
    }

    /* Pull-up carousel margin only on large screens; mid/mobile avoids overlap with hero copy */
    .showcase-slider-container {
        margin-top: 0;
    }
}

/* --- 10. PREMIUM FOOTER --- */
footer { background: #020202; padding: 30px 6% 20px; border-top: 1px solid rgba(255,255,255,0.05); }
.footer-main { display: grid; grid-template-columns: 2fr 1fr 1.5fr; gap: 10px; margin-bottom: 10px; text-align: left; }
.footer-logo { height: 80px; margin-bottom: 25px; }
.brand-col p { color: rgba(255,255,255,0.5); max-width: 300px; font-size: 0.85rem; }
.footer-col h4 { text-transform: uppercase; letter-spacing: 2px; font-size: 0.8rem; margin-bottom: 25px; color: #fff; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 12px; }
.footer-col a { color: rgba(255,255,255,0.5); text-decoration: none; font-size: 0.85rem; transition: color 0.3s ease; }
.footer-col a:hover { color: #fff; }
.footer-bottom { padding-top: 30px; border-top: 1px solid rgba(255,255,255,0.03); text-align: center; }

.footer-bottom p {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.2);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.footer-bottom a {
    color: rgba(255, 255, 255, 0.3);
    text-decoration: none;
    font-weight: 600;
    margin-left: 10px;
    transition: color 0.3s ease, border-bottom 0.3s ease;
    border-bottom: 1px solid transparent;
}

.footer-bottom a:hover {
    color: #ffffff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* --- 11. LEGAL PAGES --- */
.legal-content {
    padding: 180px 6% 100px;
    max-width: 900px;
    margin: 0 auto;
}

.legal-container h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    margin-bottom: 50px;
    line-height: 1.1;
}

.legal-section {
    margin-bottom: 60px;
}

.legal-section h2 {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 1.8rem;
    margin-bottom: 25px;
    color: #fff;
}

.legal-section h3 {
    font-size: 1.1rem;
    margin: 30px 0 15px;
    color: rgba(255,255,255,0.9);
}

.legal-section p {
    color: rgba(255,255,255,0.6);
    margin-bottom: 20px;
    font-size: 1rem;
    line-height: 1.8;
}

.legal-list {
    list-style: none;
    margin-top: 20px;
}

.legal-list li {
    color: rgba(255,255,255,0.6);
    margin-bottom: 12px;
    padding-left: 20px;
    position: relative;
}

.legal-list li::before {
    content: "—";
    position: absolute;
    left: 0;
    color: rgba(255,255,255,0.3);
}

.legal-divider {
    border: none;
    border-top: 1px solid rgba(255,255,255,0.05);
    margin: 60px 0;
}

/* --- 12. PREMIUM CONTACT FORM --- */
.contact-section {
    padding: 80px 6% 120px;
    max-width: 1400px;
    margin: 0 auto;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 80px;
}

.contact-info-block {
    margin-bottom: 40px;
}

.contact-info-block h3 {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    margin-bottom: 10px;
}

.contact-info-block p, .contact-info-block a {
    font-size: 1.2rem;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
}

.contact-info-block a:hover {
    color: rgba(255,255,255,0.7);
}

.contact-form-wrapper {
    position: relative;
    padding: 50px;
    border-radius: 2px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: rgba(255,255,255,0.6);
    margin-bottom: 10px;
}

.premium-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 15px 20px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    border-radius: 2px;
    transition: border-color 0.28s ease, background-color 0.28s ease, box-shadow 0.28s ease;
}

/* No browser outline + no offset ring — single soft border + glow so focus doesn’t “jump” larger */
.premium-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.38);
    background: rgba(255, 255, 255, 0.055);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.12),
        0 0 22px rgba(255, 255, 255, 0.08),
        0 0 48px rgba(255, 255, 255, 0.05),
        0 6px 20px rgba(0, 0, 0, 0.25);
}

.premium-input:focus-visible {
    outline: none;
}

textarea.premium-input {
    min-height: 150px;
    resize: vertical;
}

.form-alert {
    padding: 15px 20px;
    margin-bottom: 25px;
    border-radius: 2px;
    font-size: 0.9rem;
    font-weight: 600;
    display: none;
}

.form-alert.success {
    background: rgba(0, 255, 100, 0.1);
    border: 1px solid rgba(0, 255, 100, 0.3);
    color: #4ade80;
}

.form-alert.error {
    background: rgba(255, 0, 50, 0.1);
    border: 1px solid rgba(255, 0, 50, 0.3);
    color: #f87171;
}

@media (max-width: 900px) {
    .contact-grid { grid-template-columns: 1fr; gap: 40px; }
    .contact-form-wrapper { padding: 30px 20px; }
}

/* --- 13. SELECT DROPDOWN STYLING --- */
select.premium-input {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 20px center;
    background-size: 15px;
    cursor: pointer;
}

select.premium-input option {
    background-color: #0f0f0f; 
    color: #ffffff;            
    padding: 10px;
}

/* --- 14. MATERIAL & SERVICE PAGES --- */
.service-hero {
    height: 40vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 5%;
    background-color: #050505;
    position: relative;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.service-hero h1 {
    color: rgba(255, 255, 255, 0.88);
    text-shadow: 0 8px 28px rgba(0, 0, 0, 0.5);
}

.service-hero h1 .highlight {
    --hl-outline: rgba(255, 255, 255, 0.82);
}

.material-showcase {
    padding: 100px 6%;
    max-width: 1400px;
    margin: 0 auto;
}

.showcase-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 80px;
    align-items: start;
}

.showcase-text h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 25px;
    line-height: 1.1;
}

.showcase-text p {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 30px;
}

/* The Glass Spec Sheet */
.spec-sheet {
    padding: 40px;
    border-radius: 2px;
    background: linear-gradient(145deg, rgba(20,20,20,0.6) 0%, rgba(5,5,5,0.95) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.spec-sheet h3 {
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 25px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 10px;
}

.spec-list {
    list-style: none;
}

.spec-list li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    color: rgba(255,255,255,0.6);
    font-size: 0.95rem;
}

.spec-list li span {
    color: #fff;
    font-weight: 600;
    text-align: right;
}

/* Needs & Benefits Grid */
.benefits-section {
    padding: 80px 6% 120px;
    background: #020202;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1400px;
    margin: 60px auto 0;
}

.benefit-card {
    padding: 40px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.05);
    transition: transform 0.4s ease;
}

.benefit-card:hover {
    transform: translateY(-10px);
    background: rgba(255,255,255,0.04);
}

.benefit-card h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #fff;
}

.benefit-card p {
    color: rgba(255,255,255,0.5);
    font-size: 0.9rem;
    line-height: 1.6;
}

@media (max-width: 900px) {
    .showcase-grid { grid-template-columns: 1fr; gap: 50px; }
}

/* --- 15. PREMIUM IMAGE SHOWCASE (CAROUSEL) --- */
.showcase-slider-container {
    position: relative;
    max-width: 1200px;
    margin: -60px auto 80px auto;
    height: 600px;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8);
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.05);
    background: #000;
    isolation: isolate;
}

.showcase-slider-container::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, transparent 40%, rgba(0, 0, 0, 0.4) 100%);
    pointer-events: none;
    z-index: 5;
}

/* Direct child only — avoids any stray wrapper breaking transitions */
.showcase-slider-container > .showcase-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    z-index: 1;
    pointer-events: none;
    transform: translateZ(0);
    backface-visibility: hidden;
    /* Long ease-in-out so the blend is obvious (stacked: incoming fades in over outgoing) */
    transition: opacity 4s ease-in-out;
}

.showcase-slider-container > .showcase-slide.active {
    opacity: 1;
    z-index: 2;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(10, 10, 10, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    font-size: 1.5rem;
    user-select: none;
}

.slider-arrow:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
}

.slider-prev { left: 30px; }
.slider-next { right: 30px; }

@media (max-width: 900px) {
    .showcase-slider-container {
        height: 400px;
        margin: 0 auto 50px auto;
        border-radius: 0;
        border-left: none;
        border-right: none;
    }

    .slider-arrow {
        width: 45px;
        height: 45px;
    }

    .slider-prev { left: 15px; }
    .slider-next { right: 15px; }
}

.about-button-space {
    display: inline-block;
    margin-top: 45px;
}

/* --- 16. ACCESSIBILITY & POLISH --- */
.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 100000;
    padding: 12px 20px;
    background: #fff;
    color: #000;
    font-weight: 800;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    border-radius: 2px;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 16px;
    outline: 2px solid #fff;
    outline-offset: 3px;
}

button.menu-toggle {
    background: transparent;
    border: none;
    padding: 0;
    font: inherit;
    color: inherit;
}

a:focus-visible,
button:focus-visible,
.cta-button:focus-visible,
.nav-item a:focus-visible,
.dropdown a:focus-visible,
.mobile-nav-links a:focus-visible,
.mobile-nav-details summary:focus-visible,
.footer-col a:focus-visible,
.btn-outline:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.85);
    outline-offset: 3px;
}

.slider-arrow:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.9);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .animate-hero {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .showcase-slider-container.reveal {
        clip-path: none;
    }

    .portfolio-img,
    .benefit-card {
        transition: none !important;
    }

    /*
     * OS “reduced motion” often sets this — 0.2s reads as a hard cut.
     * Slower carousel crossfade is still gentle (not vestibular-triggering motion).
     */
    .showcase-slider-container > .showcase-slide {
        transition: opacity 1.5s ease-in-out;
    }

    .mobile-nav-overlay.active .mobile-nav-links > li {
        transition-delay: 0s !important;
    }
}