/* --- Consolidated spacing & eyebrow rules --- */
/* Base eyebrow spacing (desktop & large screens) */
.section-heading .eyebrow { margin-bottom: 0.25rem; line-height: 1; letter-spacing: 0.14em; }

/* About visuals base layout */
.about-visuals { display:flex; justify-content:center; align-items:center; }
.about-illustration { max-width:320px; width:100%; height:auto; display:block; }

@media (max-width: 900px) {
    /* Reduce section padding (non-hero) */
    .section { padding: var(--space-8) 0; }
    /* Push About content further down from hero */
    #about.section { padding: calc(var(--space-9) + var(--space-2)) 0 var(--space-8); }

    /* Neutralize reveal offset for headings to avoid perceived gaps */
    .section-heading.reveal { transform: none !important; }
    .section-heading.reveal.is-visible { transform: none !important; }

    /* Tight eyebrow-to-title spacing */
    .section-heading { gap: var(--space-1); margin-bottom: var(--space-2); }
    .section-heading .eyebrow { margin-bottom: 0; }

    /* About section: MASSIVELY tighten heading-to-illustration gap */
    #about .section-heading { gap: var(--space-1); margin-bottom: var(--space-0); }
    #about .section-heading .eyebrow { margin-bottom: 0; }
    #about .about-visuals { margin: 0 0 var(--space-2); }
    #about .section-body { gap: var(--space-5); }

    /* Reduce vertical gaps between stacked elements on small screens */
    .split { gap: var(--space-5); }
    #about .container.split { gap: var(--space-2); }
    
    /* Reduce spacing for products section on tablet */
    #products .section-heading { margin-bottom: var(--space-1); flex: 1 1 100% !important; }
    #products .container.split { gap: var(--space-1) !important; }
  /* Mobile/tablet menu: adjust spacing but keep card padding */
  .site-nav #primary-nav[aria-expanded="true"] {
      padding: 1.1rem 1.5rem; /* match overlay card, keep text away from edges */
      margin: 0; /* no extra outer margins */
  }
  .site-nav #primary-nav {
      list-style: none;
  }
  .site-nav #primary-nav > li {
      margin: 0; /* no extra gaps between items */
  }
  .site-nav #primary-nav > li > a {
      display: block;
      padding: 0.7rem 0; /* consistent vertical rhythm */
  }
  /* Submenu indentation and spacing under Products */
  .site-nav .has-dropdown .dropdown {
      position: static;
      display: block !important;
      padding-left: 1rem; /* indent under Products */
      margin-top: 0.25rem;
  }
  .site-nav .has-dropdown .dropdown li a {
      display: inline-block;
      padding: 0.5rem 0;
  }
  .site-nav .has-dropdown .dropdown li a::before {
      content: '•';
      display: inline-block;
      margin-right: 0.5rem;
      color: var(--text-secondary);
  }
  /* Hide chevron on small viewports */
  .site-nav .has-dropdown .chev { display: none !important; }
}

@media (max-width: 600px){
    .about-illustration { max-width:240px; }
    /* Mirror tablet intent: heading sits close to illustration, but section further from hero */
    #about.section { padding-top: calc(var(--space-10) + var(--space-2)); }
    #about .about-visuals { margin:0 0 var(--space-2); }
    /* Ultra-tight eyebrow spacing on very small screens */
    .section-heading { gap: var(--space-1); margin-bottom: var(--space-2); }
    #about .section-heading { gap: var(--space-1); margin-bottom: var(--space-0); }
    .split { gap: var(--space-4); }
    #about .container.split { gap: var(--space-2); }
    
    /* AGGRESSIVE spacing reduction for products section on mobile */
    #products.section { padding: var(--space-8) 0 var(--space-2) 0; }
    #products .section-heading { margin-bottom: var(--space-1); gap: var(--space-1); flex: 1 1 100% !important; }
    #products .container.split { gap: var(--space-1) !important; }
    #products .carousel-container { margin-top: 0; }
}
/* Contact section: center Instagram button, row for Mail/Phone */
.cta-instagram {
    display: flex;
    justify-content: center;
    margin-bottom: 1.2rem;
}
.cta-instagram .btn {
    margin: 0 auto;
}
.cta-contact {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
}
@media (max-width: 900px) {
    .cta-contact {
        flex-direction: row;
        gap: 1.5rem;
    }
}
@media (max-width: 600px) {
    .cta-contact { flex-direction: column; align-items: center; }
}
@media (max-width: 900px) {
  .contact-section .cta-links { flex-direction: column; align-items: center; }
  .contact-section .cta-links > .btn { margin-bottom: 1.1rem; }
  .contact-section .cta-links .contact-row { display: inline-block; margin-right: 1.5rem; margin-bottom: 0; vertical-align: middle; }
  .contact-section .cta-links .contact-row:last-child { margin-right: 0; }
  /* Global centering for sections on tablet/phone */
  .section .section-heading, .section .section-body { text-align: center; }
  .container.split { align-items: center; }
  .section-heading .project-heading { justify-content: center; }
  .tilterra-visuals { justify-content: center; }

    /* Mobile/Tablet nav: show Products child inline, indented with a dot */
    .site-nav .has-dropdown .dropdown {
          position: static;
          display: block !important;
          padding-left: 1rem;
          margin-top: 0.25rem;
          background: transparent !important; /* remove hover card look */
          border: 0 !important;
          box-shadow: none !important;
          backdrop-filter: none !important;
    }
    .site-nav .has-dropdown .dropdown li a::before {
            content: '•';
            display: inline-block;
            margin-right: 0.5rem;
            color: var(--text-secondary);
    }
      .site-nav .has-dropdown .dropdown li a {
          display: inline-block;
          padding: 0.45rem 0; /* consistent vertical rhythm for submenu */
          line-height: 1.3;
      }
    /* Hide dropdown chevron and hover behaviors on small screens */
    .site-nav .has-dropdown .chev { display: none !important; }

      /* Normalize vertical spacing across all menu items */
    .site-nav #primary-nav > li > a {
            display: inline-block;
            padding: 0.6rem 0; /* unify top-level item height */
            line-height: 1.3;
    }
}
.cta-inline {
    display: block;
    width: auto;
    margin-left: auto;
    margin-right: auto;
    margin-top: 1.1rem; /* Extra space above product CTA block */
}
.cta-inline .btn {
        width: auto !important;
        min-width: 0 !important;
        max-width: none !important;
        align-self: flex-start !important;
        display: inline-flex !important;
        justify-content: center !important;
}
@media (max-width: 600px) {
    .cta-inline {
        width: 100% !important;
    }
    .cta-inline .btn {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        align-self: stretch !important;
        display: flex !important;
        justify-content: center !important;
    }
}
/* removed redundant overrides */

/* redundant mobile override removed; using .cta-inline .btn instead */
/* removed duplicate */
/* removed duplicate */
/* Using .cta-inline .btn to control width for product CTA */
    .site-nav .chevron,
    .site-nav .chev,
    .has-dropdown .chevron,
    .has-dropdown .chev {
        display: none !important;
    }
    .site-nav .chevron,
    .site-nav .chev,
    .has-dropdown .chevron,
    .has-dropdown .chev {
        display: none !important;
    }
    .site-nav .chevron,
    .has-dropdown .chevron {
        display: none !important;
    }
    .site-nav .chevron,
    .has-dropdown .chevron {
        display: none !important;
    }
    .site-nav .chevron {
        display: none !important;
    }
:root {
    /* Dark theme palette (provided) */
    --background: #0B1020;   /* page */
    --surface: #0F1528;      /* cards / nav */
    --overlay: #141B30;      /* dialogs / menus */
    --background-muted: var(--surface);
    --text-primary: #E6EAF2;
    --text-secondary: #A5B1CC;
    --primary: #1B4ED6;
    --accent: #19D9FF;
    --purple: #7B61FF;
    --border: #22304F;
    --ring: #2A3B63;
    --success: #22C55E;
    --warning: #FACC15;
    --danger: #EF4444;
    --accent-soft: rgba(25, 217, 255, 0.08);
    --shadow: 0 24px 60px rgba(2,6,23,0.6);
    --radius-pill: 999px;
    --radius-large: 28px;
    --transition-speed: 0.6s;
    /* Spacing scale */
    --space-0: 0;
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.5rem;
    --space-6: 2rem;
    --space-7: 2.5rem;
    --space-8: 3rem;
    --space-9: 3.5rem;
    --space-10: 4rem;
    font-size: 16px;
}

/* Smooth scrolling for internal anchor links */
html {
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
/* --- Unified Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 var(--space-3);
}

h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); }

p, ul, ol {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    margin: 0 0 var(--space-3);
    color: var(--text-secondary);
}

ul, ol { padding-left: 1.2rem; }
li { margin-bottom: var(--space-2); }

.section-heading {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
    margin-bottom: var(--space-3);
}

.section-body { display: grid; gap: var(--space-3); }

/* Eyebrow label */
.eyebrow, .section-heading .eyebrow {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--primary);
    font-weight: 600;
    line-height: 1;
    margin-bottom: var(--space-1);
}

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

a:hover,
a:focus {
    text-decoration: underline;
}

.container {
    width: min(1100px, 92vw);
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    width: 100%;
    backdrop-filter: blur(10px);
    background: #000000; /* make header pure black as requested */
    border-bottom: 1px solid rgba(255,255,255,0.04);
    z-index: 10;
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 0;
}

.branding {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 20px;
    background: linear-gradient(135deg, var(--primary), #5c79ff);
    color: #ffffff;
    font-family: 'Nunito', 'Inter', sans-serif;
    font-size: 1.4rem;
    box-shadow: var(--shadow);
}

/* Image logo used when `assets/AIconBlack_web.png` is present */
.brand-logo {
    width: 48px;
    height: 48px;
    display: inline-block;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

/* Project / app logos used in section headings (e.g., Tilterra) */
.project-heading {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
}

.project-logo {
    width: 64px;
    height: 64px;
    display: inline-block;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 18px 40px rgba(27,78,214,0.12);
}

@media (max-width: 520px) {
    .project-logo {
        width: 48px;
        height: 48px;
    }
    .project-heading {
        justify-content: center;
    }
}

/* Tilterra visuals (station left, GARY right) */
.tilterra-visuals {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap; /* keep station and GARY on the same row at all widths */
    gap: 2.5rem; /* spacing between station and GARY */
    align-items: center;
    justify-content: center; /* center within heading column when space available */
    margin-top: 1.1rem; /* slightly tighter spacing from title */
    position: relative;
    width: 100%;
    max-width: 100%;
}

.tilterra-station-wrap {
    position: relative;
    display: inline-block;
}

.tilterra-station {
    width: clamp(160px, 22vw, 340px);
    height: auto;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 30px 60px rgba(0,0,0,0.6);
    position: relative;
    z-index: 2;
}

/* Subtle glowing ring/backdrop behind the station */
.tilterra-station-wrap::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: calc(100% + 60px);
    height: calc(100% + 60px);
    border-radius: 50%;
    background: radial-gradient(circle at 40% 30%, rgba(27,78,214,0.12), rgba(25,217,255,0.03) 30%, transparent 55%);
    filter: blur(12px);
    z-index: 1;
    pointer-events: none;
}

.gary {
    width: clamp(120px, 18vw, 260px);
    display: block;
}

.gary-img {
    width: 100%;
    height: auto;
    display: block;
}

.gary-animate {
    animation: gary-float 4s ease-in-out infinite; /* slower, smoother float */
    transform-origin: center;
}

@keyframes gary-float {
    0% { transform: translateY(0); }
    50% { transform: translateY(-16px); } /* slightly larger amplitude */
    100% { transform: translateY(0); }
}

@media (max-width: 700px) {
    .tilterra-visuals { gap: 0.85rem; }
    .tilterra-station { width: clamp(140px, 38vw, 240px); }
    .gary { width: clamp(110px, 32vw, 200px); }
}

/* Ensure row layout even on very small phones */
@media (max-width: 520px) {
    .tilterra-visuals { gap: 0.7rem; }
    .tilterra-station { width: clamp(130px, 44vw, 220px); }
    .gary { width: clamp(100px, 40vw, 180px); }
}

.brand-name {
    /* Use Space Grotesk for the brand name */
    font-family: 'Space Grotesk', 'Nunito', 'Inter', sans-serif;
    font-size: 1.35rem;
    color: var(--text-primary);
}

.site-nav ul {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    list-style: none;
    font-weight: 500;
    color: var(--text-primary);
}

.site-nav a {
    transition: color 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus {
    color: var(--primary);
}

/* Dropdown menu for Work -> Tilterra */
.site-nav li {
    position: relative;
}

.site-nav .dropdown {
    display: none;
    position: absolute;
    /* remove vertical gap to prevent hover gaps when moving mouse into submenu */
    top: calc(100% - 6px);
    left: 0;
    background: var(--overlay);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.25rem 0;
    min-width: 180px;
    box-shadow: 0 18px 40px rgba(2,6,23,0.6);
    z-index: 30;
}

.site-nav .dropdown li {
    display: block;
}

.site-nav .dropdown a {
    display: block;
    padding: 0.6rem 1rem;
    color: var(--text-primary);
    white-space: nowrap;
}

.site-nav .dropdown a:hover,
.site-nav .dropdown a:focus {
    color: var(--accent);
    background: rgba(255,255,255,0.02);
}

.has-dropdown:focus-within > .dropdown,
.has-dropdown:hover > .dropdown {
    display: block;
}

@media (max-width: 820px) {
    /* On small screens the primary nav will be toggled via JS; ensure dropdown becomes inline */
    .site-nav .dropdown {
        position: static;
        box-shadow: none;
        border: none;
        padding-left: 1.25rem; /* subtle indent under Products, not too deep */
        display: block !important;
        background: none;
        min-width: 0;
        margin-top: 0.2rem;
    }
    .site-nav .has-dropdown > a {
        pointer-events: auto;
        cursor: pointer;
    }
}

.nav-toggle {
    display: none;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    color: var(--text-primary);
    padding: 0.6rem 1.25rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    cursor: pointer;
}

.section {
    padding: 6.5rem 0;
    position: relative;
    overflow: hidden;
}

/* Prevent sticky header from covering anchored sections */
section {
    scroll-margin-top: 84px;
}

.section.muted {
    background: var(--background-muted);
}

/* About Tilterra section: black background */
#t-about.t-about-black {
    background: #000000;
    padding: 4.5rem 0 3.5rem 0 !important;
}

#t-about .section-body {
    margin-bottom: 2rem !important; /* tighten space below Download Tilterra button */
}

/* Plain illustration display without floating box styling */
.tilterra-illustration {
    width: 100%;
    max-width: 500px;
    height: auto;
    display: block;
    margin: 0 auto var(--space-6);
}

/* Make the Products section (id="products") black to emphasize space theme */
#products {
    background: #000000;
    color: var(--text-primary);
}

/* Ensure links inside a black section remain visible */
#products a {
    color: var(--accent);
}

#products .btn {
    color: #ffffff !important;
}

.hero {
    padding-top: 2rem; /* reduce top whitespace under header */
    padding-bottom: 2.5rem;
    min-height: calc(100vh - 96px); /* fill viewport minus sticky header */
    display: block;
}

.hero-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2.5rem;
    flex-wrap: wrap;
    min-height: inherit; /* ensure inner fills hero height */
}

#t-intro.hero.section {
    padding-top: 2rem !important;
    padding-bottom: 3.5rem !important;
}

.hero-content {
    flex: 1 1 420px;
    display: grid;
    gap: 0.35rem; /* Much tighter spacing between elements */
}

.eyebrow {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--primary);
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 0.08rem; /* Ultra tight connection to title below */
}

/* Base section-heading layout */
.section-heading { display:flex; flex-direction:column; align-items:flex-start; gap:0.12rem; }

/* Position eyebrow tight to title, with generous space above from logo */
.hero .eyebrow {
    margin-top: 2.5rem; /* Generous space from logo above */
    margin-bottom: 0.15rem; /* Very tight gap before title, matching section-heading style */
}

.section-heading .project-heading {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.section-heading .project-title {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.hero h1 {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: clamp(3rem, 6.5vw, 4.6rem);
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--text-primary);
}

.hero-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: clamp(1.4rem, 2.8vw, 1.9rem);
    color: var(--primary);
    font-weight: 600;
    line-height: 1.3;
}

.hero-body {
    max-width: 36rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.35rem; /* Added extra breathing room above hero buttons */
}

/* App Store badge styling in hero */
.appstore-badge {
    display: inline-block;
    line-height: 0; /* remove extra inline spacing */
}
.appstore-badge img {
    display: block;
    height: 48px; /* harmonize with button height */
    width: auto;
}

@media (max-width: 520px) {
    .appstore-badge img { height: 44px; }
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.9rem 1.85rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    letter-spacing: -0.01em;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, color 0.3s ease;
    position: relative;
}

.btn.primary {
    background: var(--primary);
    color: #ffffff;
    box-shadow: var(--shadow);
}

.btn.secondary {
    background: rgba(27, 78, 214, 0.08);
    color: #ffffff;
    border: 1px solid rgba(27, 78, 214, 0.18);
}

.btn.tertiary {
    background: linear-gradient(135deg, rgba(27, 78, 214, 0.85), rgba(0, 255, 255, 0.65));
    color: #ffffff;
    box-shadow: var(--shadow);
}

.btn:hover,
.btn:focus {
    transform: translateY(-4px);
}

.hero-visual {
    flex: 1 1 320px;
    display: flex;
    justify-content: center;
    margin-top: 0;
    margin-bottom: 0;
}

/* Large logo used in the hero to replace the orbital visual */
.hero-logo-large {
    width: clamp(220px, 32vw, 460px);
    aspect-ratio: 1 / 1;
    object-fit: contain;
    display: block;
    border-radius: 16px;
    margin-top: 0;
    margin-bottom: 0;
    filter: drop-shadow(0 30px 60px rgba(0,0,0,0.6));
}

@media (max-width: 900px) {
    .hero {
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
        min-height: auto; /* allow content-driven height on smaller screens */
    }
    .hero-inner {
        gap: 0.3rem;
    }
    .hero-logo-large {
        width: clamp(160px, 60vw, 320px);
        margin-top: 0;
        margin-bottom: 0;
    }

    /* Stack hero visual above hero content on small screens */
    .hero-inner {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-visual {
        order: -1;
        margin-bottom: 1.25rem;
        width: 100%;
        display: flex;
        justify-content: center;
    }
}

/* Tighter vertical rhythm for small phones */
@media (max-width: 520px) {
    /* tighter header */
    .site-header .container {
        padding: 0.25rem 0; /* reduce header height to minimum */
    }

    /* shrink brand logo and text slightly */
    .branding .brand-logo {
        width: 32px;
        height: 32px;
    }
    .branding .brand-name {
        font-size: 1rem;
    }

    /* ultra tight hero spacing for small screens */
    .hero {
        padding-top: 0.1rem;
        padding-bottom: 0.1rem;
        min-height: auto;
    }
    .hero-inner {
        gap: 0.02rem;
        padding: 0;
    }
    .hero-visual {
        margin-top: 0;
        margin-bottom: 0;
    }
    .hero-logo-large {
        width: clamp(120px, 80vw, 340px);
        margin-top: 0;
        margin-bottom: 0;
    }
}

.orbital {
    position: relative;
    width: clamp(260px, 30vw, 360px);
    aspect-ratio: 1/1;
    border-radius: 50%;
    background: radial-gradient(circle at top, rgba(0, 255, 255, 0.25), rgba(27, 78, 214, 0.08) 65%, transparent 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: float 6s ease-in-out infinite;
}

.planet {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: linear-gradient(160deg, #00ffff, #1b4ed6);
    box-shadow: 0 30px 50px rgba(27, 78, 214, 0.35);
}

.orbit {
    position: absolute;
    border-radius: 50%;
    border: 2px solid rgba(27, 78, 214, 0.1);
    width: 100%;
    height: 100%;
    animation: rotate 14s linear infinite;
}

.orbit.accent {
    border-color: rgba(0, 255, 255, 0.28);
}

.orbit.secondary {
    width: 70%;
    height: 70%;
    border-color: rgba(27, 78, 214, 0.16);
    animation-duration: 10s;
}

.orbit.tertiary {
    width: 45%;
    height: 45%;
    border-color: rgba(106, 74, 251, 0.2);
    animation-duration: 7s;
}

.split {
    display: flex;
    gap: 2.75rem;
    align-items: flex-start;
    flex-wrap: wrap;
}

.split > * {
    flex: 1 1 320px;
}

/* Remove conflicting redefinition of .section-heading; using earlier flex-based layout */

.section-heading h2 {
    font-family: 'Nunito', 'Inter', sans-serif;
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -0.01em;
    margin: 0; /* eliminate default h2 margins that create extra vertical space */
}

.section-body {
    display: grid;
    gap: 1.25rem;
    color: var(--text-secondary);
    font-size: 1.04rem;
    margin-bottom: 5rem; /* Much more spacing between content blocks */
}

.contact-section .cta-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1.5rem;
}

.contact-row {
    color: var(--text-primary);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.contact-label {
    color: var(--text-secondary);
    font-weight: 600;
}

/* Tilterra privacy AdMob section enhancements */
/* Remove any visual line break between label and first bullet */
#t-privacy .admob-block { margin: 1.25rem 0 0 0; padding: 0; }
#t-privacy .admob-label { margin: 0; padding: 0; font-weight: 800; color: var(--text-primary); letter-spacing: -0.01em; line-height: 1.2; }
#t-privacy .admob-datalist { margin-top: 0; }
#t-privacy .admob-google-link { margin-top: 0.6rem; font-size: 0.92rem; }
#t-privacy .admob-google-link a { color: var(--primary); font-weight: 600; text-decoration: none; }
#t-privacy .admob-google-link a:hover, #t-privacy .admob-google-link a:focus { text-decoration: underline; }

/* Instagram icon inside CTA */
.icon-instagram {
    display: inline-block;
    margin-right: 0.6rem;
    vertical-align: text-bottom;
    color: var(--text-primary);
}

.btn-text{ display:inline-block; font-family: 'Inter', sans-serif; font-weight: 600; letter-spacing: -0.01em; color: inherit; }

/* Privacy policy section styles */
#t-privacy h3 {
    color: var(--text-primary);
    font-family: 'Nunito', 'Inter', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    margin-top: 4.5rem; /* Much more space before new section */
    margin-bottom: 0.35rem; /* Much tighter connection to content */
}

#t-privacy .meta {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

#t-privacy ul {
    list-style-position: inside;
    padding-left: 1rem;
    margin: 1rem 0;
}

#t-privacy ul li {
    margin: 0.5rem 0;
    color: var(--text-secondary);
}

#t-privacy .notice {
    background: rgba(27, 78, 214, 0.08);
    border-left: 3px solid var(--primary);
    padding: 1rem 1.25rem;
    border-radius: 8px;
    margin: 1.5rem 0;
}

#t-privacy h3 strong,
#t-privacy p strong {
    color: var(--text-primary);
}

.site-footer {
    border-top: 1px solid rgba(255,255,255,0.04);
    background: #000000; /* pure black footer */
    padding: 3rem 0;
}

.site-footer .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    color: var(--text-secondary);
}

.footer-branding {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    font-weight: 500;
}

.footer-links a {
    color: var(--text-secondary);
}

.footer-note {
    font-size: 0.95rem;
}

.reveal {
    opacity: 0;
    transform: translateY(32px) scale(0.98);
    transition: opacity var(--transition-speed) ease, transform var(--transition-speed) ease;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0);
    }
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 900px) {
    .site-nav ul {
        display: none;
        position: absolute;
        top: 72px;
        right: 4vw;
        background: var(--overlay);
        border: 1px solid rgba(34,48,79,0.18);
        border-radius: var(--radius-large);
        padding: 1.1rem 1.5rem;
        box-shadow: var(--shadow);
        flex-direction: column;
        align-items: flex-start;
        gap: 0.6rem; /* tighter, more even vertical rhythm */
    }

    /* Ensure the station illustration centers and sits above text when used inside sections */
    .tilterra-station-wrap {
        display: flex;
        justify-content: center;
        width: 100%;
        margin-bottom: 1rem;
    }

    .site-nav ul[aria-expanded="true"] { display: flex; }
    .nav-toggle { display: inline-flex; }
    .hero { padding-top: 6rem; }
    .hero-inner { justify-content: center; }
    .hero-content { text-align: center; }
    .hero-body { margin: 0 auto; }
    .hero-actions { justify-content: center; }
    .split { flex-direction: column; text-align: center; }
    .contact-section .cta-links { justify-content: center; }
}

@media (max-width: 520px) {
    .site-header .container {
        padding: 1.1rem 0;
    }

    .hero h1 {
        font-size: clamp(2.6rem, 12vw, 3.6rem);
    }

    .hero-subtitle {
        font-size: 1.35rem;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .footer-links {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }
}

/* Phone footer nav left-alignment only for main Tytonext site */
@media (max-width: 520px) {
    body.home .footer-links { justify-content: flex-start; }
    body.home .footer-links a:first-child { margin-left: 0; }
}

/* --- Final mobile overrides to ensure About spacing wins over later base rules --- */
@media (max-width: 900px) {
    /* Push About down from hero */
    #about.section { padding-top: calc(var(--space-10) + var(--space-2)) !important; }
    /* Collapse gap between heading and illustration specifically in About */
    #about .container.split { gap: var(--space-1) !important; }
    #about .section-heading { margin-bottom: var(--space-0) !important; gap: var(--space-1) !important; }
    #about .about-visuals { margin-top: 0 !important; margin-bottom: var(--space-2) !important; }

    /* Force #about stack to use grid with explicit row-gap to avoid flex-gap inconsistencies */
    #about .container.split { display: grid !important; grid-auto-flow: row; row-gap: var(--space-1) !important; justify-items: center; align-items: start; }
}

@media (max-width: 600px) {
    /* Even tighter row-gap on very small screens */
    #about .container.split { row-gap: 0.05rem !important; }
}

/* --- Carousel Styles --- */
.carousel-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: var(--space-6) auto;
    padding: 0 var(--space-4);
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.carousel {
    display: flex;
    gap: 0;
    padding: var(--space-4) 0;
    justify-content: center;
    align-items: center;
    height: 320px;
    width: 100%;
    position: relative;
}

.carousel-slide {
    flex: 0 0 auto;
    transition: opacity 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), margin 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), order 0s;
    opacity: 0;
    transform: scale(0.5);
    pointer-events: none;
    visibility: hidden;
    width: 0;
    height: 0;
    overflow: hidden;
    position: absolute;
}

.carousel-slide img {
    height: 300px;
    width: auto;
    object-fit: contain;
    display: block;
}

/* Center slide (position 0) - ALWAYS centered */
.carousel-slide[data-position="0"] {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
    z-index: 5;
    visibility: visible;
    width: auto;
    height: auto;
    position: relative;
    order: 2;
    margin: 0;
}

/* Left slide (position -1) - appears to the left */
.carousel-slide[data-position="-1"] {
    opacity: 0.5;
    transform: scale(0.8);
    z-index: 4;
    visibility: visible;
    width: auto;
    height: auto;
    position: relative;
    order: 1;
    margin: 0 var(--space-3) 0 0;
}

/* Right slide (position 1) - appears to the right */
.carousel-slide[data-position="1"] {
    opacity: 0.5;
    transform: scale(0.8);
    z-index: 4;
    visibility: visible;
    width: auto;
    height: auto;
    position: relative;
    order: 3;
    margin: 0 0 0 var(--space-3);
}

/* All other positions hidden */
.carousel-slide[data-position="-2"],
.carousel-slide[data-position="2"],
.carousel-slide[data-position="-3"],
.carousel-slide[data-position="3"] {
    opacity: 0;
    visibility: hidden;
    width: 0;
    height: 0;
}

.carousel-control {
    position: static;
    transform: none;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 2rem;
    padding: var(--space-2) var(--space-3);
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    z-index: 10;
    flex-shrink: 0;
}

.carousel-control:hover {
    background: rgba(255, 255, 255, 0.1);
}

.carousel-control.prev {
    left: auto;
    order: -1;
}

.carousel-control.next {
    right: auto;
    order: 1;
}

@media (max-width: 900px) {
    .carousel-container {
        max-width: 450px;
        padding: 0 var(--space-2);
        display: flex;
        align-items: center;
        gap: var(--space-2);
    }

    .carousel {
        height: 270px;
        position: relative;
    }

    .carousel-slide img {
        height: 250px;
    }

    .carousel-control {
        position: static;
        transform: none;
        font-size: 1.5rem;
        padding: var(--space-1) var(--space-2);
        background: transparent;
        color: var(--text-primary);
        flex-shrink: 0;
    }

    .carousel-control:hover {
        background: rgba(255, 255, 255, 0.1);
    }

    .carousel-control.prev {
        left: auto;
        order: -1;
    }

    .carousel-control.next {
        right: auto;
        order: 1;
    }
}

@media (max-width: 600px) {
    .carousel-container {
        max-width: 320px;
        margin: 0 auto;
        padding: 0;
        display: flex;
        align-items: center;
        gap: var(--space-1);
    }

    .carousel {
        gap: var(--space-2);
        padding: 0;
        height: 220px;
        position: relative;
    }

    .carousel-slide img {
        height: 200px;
    }

    .carousel-control {
        position: static;
        transform: none;
        font-size: 1.2rem;
        padding: var(--space-1) 0.4rem;
        background: transparent;
        color: var(--text-primary);
        flex-shrink: 0;
    }

    .carousel-control:hover {
        background: rgba(255, 255, 255, 0.1);
    }

    .carousel-control.prev {
        left: auto;
        order: -1;
    }

    .carousel-control.next {
        right: auto;
        order: 1;
    }
}

/* Lightbox Modal */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.8);
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 48px;
    color: #ffffff;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 10000;
    padding: 10px 20px;
    line-height: 1;
    transition: opacity 0.3s ease;
}

.lightbox-close:hover {
    opacity: 0.7;
}

.carousel-slide {
    cursor: pointer;
}

