/* =========================================
   1. CORE VARIABLES & DESIGN SYSTEM
   ========================================= */
:root {
    /* Colors (Strict Palette) */
    --color-bg: #0D0D0F;
    --color-text: #F9FAFB;
    --color-primary: #F9FAFB;
    --color-white: #FFFFFF;
    --color-secondary: #2A2D35;
    --color-accent: #32A4BD;
    --color-border: #2A2D35;

    /* Semantic Colors */
    --color-text-muted: rgba(249, 250, 251, 0.6);
    --color-text-faint: rgba(249, 250, 251, 0.4);
    --color-text-body: rgba(249, 250, 251, 0.75);
    --color-card-bg: rgba(255, 255, 255, 0.02);

    /* Typography */
    --font-sans: 'Plus Jakarta Sans', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Scaled Headings using clamp */
    --font-size-h1: clamp(2.5rem, 5vw + 1rem, 4.5rem);
    --font-size-h2: clamp(2rem, 4vw + 1rem, 3.5rem);
    --font-size-h3: clamp(1.25rem, 2vw + 1rem, 1.75rem);
    --font-size-p: 1.125rem;
    --font-size-xs: 0.875rem;
    --font-size-sm: 1rem;

    /* Spacing & Layout */
    --container-width: 80rem;
    --radius-enterprise: 12px;
    --radius-card: 12px;
}

/* =========================================
   2. RESET & BASE
   ========================================= */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: 'Plus Jakarta Sans', sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

h1,
h2,
h3,
h4 {
    line-height: 1.1;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

/* =========================================
   3. LAYOUT UTILITIES (Minimal)
   ========================================= */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.hidden {
    display: none !important;
}

/* Keyboard Focus Ring (Accessibility) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Screen-reader only utility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

@media (min-width: 768px) {
    .md\:hidden {
        display: none !important;
    }

    .md\:flex {
        display: flex !important;
    }
}

/* =========================================
   4. SEMANTIC COMPONENTS
   ========================================= */

/* --- BUTTONS --- */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    background-color: var(--color-primary);
    color: var(--color-bg);
    font-weight: 700;
    border-radius: var(--radius-enterprise);
    transition: background-color 0.3s;
}

.btn-primary:hover {
    background-color: #e5e7eb;
}

.btn-nav-cta {
    font-size: var(--font-size-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent);
    border: 1px solid rgba(50, 164, 189, 0.3);
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-enterprise);
    transition: all 0.3s;
}

.btn-nav-cta:hover {
    background-color: var(--color-accent);
    color: var(--color-primary);
}

.btn-white {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background-color: #fff;
    color: var(--color-bg);
    padding: 0.875rem 2rem;
    border-radius: var(--radius-enterprise);
    font-size: var(--font-size-sm, 1rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.btn-white:hover {
    background-color: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
}

.btn-ghost {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 0.875rem 2rem;
    border-radius: var(--radius-enterprise);
    font-size: var(--font-size-sm, 1rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: 1px solid var(--color-border);
    color: var(--color-text);
    transition: all 0.3s;
}

.btn-ghost:hover {
    background-color: rgba(42, 45, 53, 0.2);
    transform: translateY(-2px);
}

.btn-accent {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background-color: var(--color-accent);
    color: #fff;
    padding: 1.25rem 2.5rem;
    border-radius: var(--radius-enterprise);
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* --- HEADER --- */
.site-header {
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 50;
    background-color: rgba(13, 13, 15, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    padding: 1rem 0;
    /* Standard padding */
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    /* Needed for absolute centering of nav */
}

.brand-logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary);
    letter-spacing: -0.025em;
    /* Ensure clickable */
    display: flex;
    align-items: center;
    z-index: 60;
}

.brand-logo-img {
    height: 150px;
    width: auto;
    object-fit: contain;
    margin-top: -45px;
    margin-bottom: -45px;
    position: relative;
    z-index: 60;
    max-width: 70vw;
}

/* Desktop Nav - Centered */
.nav-menu {
    display: none;
    align-items: center;
    gap: 2rem;
}

@media (min-width: 768px) {
    .nav-menu {
        display: flex;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
}

.nav-link {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-text-muted);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-primary);
}

/* Right Side Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 20;
    /* Ensure clickable */
}

.menu-toggle {
    background: none;
    border: none;
    color: var(--color-primary);
    cursor: pointer;
}

/* --- MOBILE MENU --- */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background-color: var(--color-bg);
    z-index: 40;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-link {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
}

/* --- SECTION-HEADING --- */
.section-heading {
    font-size: var(--font-size-h2);
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 4rem;
    letter-spacing: -0.03em;
}

.section-heading.centered {
    text-align: center;
}

.text-muted {
    color: var(--color-text-muted);
}


/* --- FOOTER --- */
.site-footer {
    background-color: var(--color-bg);
    padding-top: 4rem;
    padding-bottom: 2rem;
    margin-top: 5rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 5rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: 4fr 2fr 2fr;
    }
}

.footer-about {
    grid-column: span 2;
}

@media (min-width: 768px) {
    .footer-about {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .footer-about {
        grid-column: auto;
        /* Reset to single column for desktop */
    }
}

.footer-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary);
    display: block;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
}

.footer-desc {
    color: var(--color-text-muted);
    line-height: 1.6;
    max-width: 24rem;
}

.footer-heading {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
}

.footer-link {
    color: var(--color-text-muted);
    font-size: 1rem;
    margin-bottom: 0.5rem;
    display: block;
}

.footer-link:hover {
    color: var(--color-primary);
}

.footer-bottom {
    border-top: 1px solid var(--color-border);
    padding-top: 2rem;
    color: var(--color-text-faint);
    font-size: var(--font-size-sm, 1rem);
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

.footer-legal {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
}

@media (min-width: 768px) {
    .footer-legal {
        margin-top: 0;
    }
}

/* --- GENERIC HERO (Inner Pages) --- */
.page-hero {
    padding-top: 10rem;
    padding-bottom: 5rem;
    border-bottom: 1px solid rgba(42, 45, 53, 0.3);
    margin-bottom: 0;
    position: relative;
    overflow: hidden;
}

.page-hero.centered {
    text-align: center;
}

.page-hero .hero-eyebrow {
    font-size: var(--font-size-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-accent);
    margin-bottom: 1.5rem;
    display: block;
}

.page-hero .hero-title {
    font-size: var(--font-size-h1);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.page-hero .hero-title span {
    color: var(--color-text-muted);
}

.page-hero .hero-lead,
.page-hero .hero-desc {
    font-size: 1.25rem;
    color: var(--color-text-muted);
    max-width: 44rem;
    margin: 0 auto;
    line-height: 1.7;
}

/* --- UTILITY CLASSES --- */
.text-accent {
    color: var(--color-accent) !important;
}

/* --- SCROLL REVEAL ANIMATION --- */
@keyframes revealUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

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

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered delays for child elements */
.reveal-delay-1 {
    transition-delay: 0.1s;
}

.reveal-delay-2 {
    transition-delay: 0.2s;
}

.reveal-delay-3 {
    transition-delay: 0.3s;
}

.reveal-delay-4 {
    transition-delay: 0.4s;
}

.reveal-delay-5 {
    transition-delay: 0.5s;
}

.reveal-delay-6 {
    transition-delay: 0.6s;
}

/* --- SHARED SECTION SPACING --- */
.section-block {
    padding: 6rem 0;
}

.section-block+.section-block {
    border-top: 1px solid rgba(42, 45, 53, 0.3);
}