/* =========================================================================
   QamarNext Technologies — Full-viewport homepage
   Two-tone (white / coal-navy) · teal accent · interactive imagery
   ========================================================================= */

/* ---------- Design Tokens ---------- */
:root{
  --white:        #FCFCFA;
  --white-dim:    #F3F3EF;
  --coal:         #0B1420;
  --coal-raised:  #101C29;
  --coal-line:    #1B2A38;
  --silver:       #C9D3D6;

  --teal:         #2DD9C4;
  --teal-light:   #5EEAD4;
  --teal-dim:     rgba(45,217,196,0.14);

  --status-good:  #34D17E;
  --status-warn:  #F5A623;
  --status-bad:   #E5484D;

  --ink:          #0B1420;
  --ink-muted:    #4A5561;
  --paper:        #F6F8F7;
  --paper-muted:  #93A6A2;

  --line-on-white: rgba(11,20,32,0.10);
  --line-on-coal:  rgba(246,248,247,0.12);

  --font-display: 'Space Grotesk', 'Segoe UI', system-ui, sans-serif;
  --font-body:    'Inter', 'Segoe UI', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;

  --fs-hero:      clamp(2.15rem, 1.35rem + 3.2vw, 4.75rem);
  --fs-display:   clamp(2rem, 1.45rem + 2.6vw, 4.25rem);
  --fs-h2:        clamp(1.7rem, 1.35rem + 1.5vw, 2.85rem);
  --fs-h3:        clamp(1.2rem, 1.05rem + 0.7vw, 1.7rem);
  --fs-body-lg:   clamp(1.05rem, 0.98rem + 0.3vw, 1.25rem);
  --fs-body:      clamp(0.95rem, 0.92rem + 0.12vw, 1.0625rem);
  --fs-small:     clamp(0.8125rem, 0.79rem + 0.1vw, 0.9rem);
  --fs-micro:     clamp(0.6875rem, 0.67rem + 0.08vw, 0.75rem);

  --space-section: clamp(4.5rem, 3.2rem + 6.5vw, 11rem);
  --space-xl:      clamp(2.5rem, 1.8rem + 3.5vw, 6rem);
  --space-lg:      clamp(1.75rem, 1.4rem + 1.8vw, 3.5rem);
  --space-md:      clamp(1rem, 0.85rem + 0.8vw, 1.75rem);
  --space-sm:      clamp(0.5rem, 0.42rem + 0.4vw, 0.9rem);
  --gutter:        clamp(1.25rem, 1rem + 3vw, 5rem);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 180ms;
  --dur-med:  420ms;
  --dur-slow: 900ms;

  --radius-sm: 8px;
  --radius-md: 16px;
  --nav-h: 84px;
}

/* ---------- Reset ---------- */
*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
body{
  margin: 0;
  background: var(--coal);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, canvas, video{ max-width: 100%; display: block; }
img{ object-fit: cover; }
a{ color: inherit; text-decoration: none; }
ul{ list-style: none; margin: 0; padding: 0; }
button{ font: inherit; color: inherit; background: none; border: 0; cursor: pointer; text-align: left; }
h1,h2,h3,h4,p{ margin: 0; }
::selection{ background: var(--teal); color: var(--coal); }

.skip-link{
  position: absolute; left: -999px; top: 0; z-index: 999;
  background: var(--teal); color: var(--coal); padding: 0.75em 1.25em;
  font-family: var(--font-mono); font-size: var(--fs-small);
}
.skip-link:focus{ left: var(--gutter); top: var(--space-sm); }
:focus-visible{ outline: 2px solid var(--teal); outline-offset: 3px; }

/* ---------- Typography helpers ---------- */
.mono{ font-family: var(--font-mono); letter-spacing: 0.02em; }
.eyebrow{
  font-family: var(--font-mono);
  font-size: var(--fs-small);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--teal);
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
}
.eyebrow::before{
  content: '';
  width: 1.4em; height: 1px;
  background: currentColor;
  display: inline-block;
}
.section-heading{
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.01em;
  max-width: 18ch;
}
.section-kicker{
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}
.section-lede{
  font-size: var(--fs-body-lg);
  color: var(--ink-muted);
  max-width: 42ch;
}
.section-lede a{
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}
.on-coal .section-lede,
.services-fs .section-lede,
.solutions-fs .section-lede,
.process-fs .section-lede,
.final-cta .section-lede,
.proof-fs .section-lede{ color: var(--paper-muted); }

/* ---------- Full-screen sections ---------- */
.fs-section{
  position: relative;
  min-height: 100svh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}
.fs-inner{
  position: relative;
  z-index: 2;
  width: 100%;
  padding: calc(var(--nav-h) + 1.25rem) var(--gutter) 2.25rem;
}
.on-white{ background: var(--white); color: var(--ink); }
.on-coal{ background: var(--coal); color: var(--paper); }
.on-coal .eyebrow,
.services-fs .eyebrow,
.solutions-fs .eyebrow,
.process-fs .eyebrow,
.final-cta .eyebrow,
.proof-fs .eyebrow{ color: var(--teal-light); }

@media (min-width: 1100px){
  html:not(.is-preview){ scroll-snap-type: y proximity; }
  html:not(.is-preview) .fs-section{ scroll-snap-align: start; scroll-snap-stop: always; height: 100svh; min-height: 100svh; }
}

/* ---------- Buttons ---------- */
.btn{
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: var(--fs-small);
  padding: 0.95em 1.6em;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: transform var(--dur-fast) var(--ease-out), background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast);
  white-space: nowrap;
}
.btn-primary{ background: var(--teal); color: var(--coal); }
.btn-primary:hover{ background: var(--teal-light); transform: translateY(-1px); }
.btn-ghost{ border-color: currentColor; color: inherit; }
.on-white .btn-ghost{ border-color: var(--line-on-white); }
.btn-ghost:hover{ border-color: var(--teal); color: var(--teal); }
.btn-arrow{ transition: transform var(--dur-fast) var(--ease-out); }
.btn:hover .btn-arrow{ transform: translateX(3px); }

/* ---------- Loader ---------- */
.loader{
  position: fixed; inset: 0; z-index: 2000;
  background: var(--coal); color: var(--paper);
  display: flex; align-items: center; justify-content: center;
  transition: opacity var(--dur-slow) var(--ease-out), visibility var(--dur-slow);
}
.loader[data-state="done"]{ opacity: 0; visibility: hidden; pointer-events: none; }
.loader-inner{ text-align: center; font-family: var(--font-mono); font-size: var(--fs-small); }
.loader-mark{ width: 44px; height: 44px; margin: 0 auto var(--space-md); }
.loader-bar{
  width: 220px; height: 2px; background: var(--line-on-coal);
  margin-top: var(--space-md); overflow: hidden; border-radius: 2px;
}
.loader-bar-fill{
  height: 100%; width: 0%; background: var(--teal);
  transition: width var(--dur-med) var(--ease-out);
}
.loader-status{ color: var(--paper-muted); margin-top: 0.75em; }

/* ---------- Scroll progress ---------- */
.scroll-progress{
  position: fixed; top: 0; left: 0; height: 3px; width: 0%;
  background: var(--teal); z-index: 1500;
  transition: width 80ms linear;
}

/* ---------- Section dots ---------- */
.section-dots{
  position: fixed; right: 1.15rem; top: 50%; transform: translateY(-50%);
  z-index: 1100; display: flex; flex-direction: column; gap: 0.7rem;
}
.section-dots a{
  width: 9px; height: 9px; border-radius: 999px;
  border: 1px solid rgba(246,248,247,0.45);
  background: transparent;
  transition: transform var(--dur-fast), background var(--dur-fast), border-color var(--dur-fast), height var(--dur-med);
}
.section-dots a.is-active{
  background: var(--teal); border-color: var(--teal);
  height: 22px;
}
@media (max-width: 900px){ .section-dots{ display: none; } }

/* ---------- Nav ---------- */
.site-nav{
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h);
  display: flex; align-items: center;
  background: transparent;
  transition: background var(--dur-med) var(--ease-out), border-color var(--dur-med), height var(--dur-med);
  border-bottom: 1px solid transparent;
}
.site-nav[data-solid="true"]{
  background: rgba(11,20,32,0.78);
  backdrop-filter: blur(16px);
  border-color: var(--line-on-coal);
  height: calc(var(--nav-h) - 12px);
}
.nav-inner{
  width: 100%;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--gutter);
  color: var(--paper);
}
.nav-logo{ display: flex; align-items: center; gap: 0.6em; }
.nav-logo svg{ width: 30px; height: 30px; }
.nav-wordmark{ font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; letter-spacing: 0.01em; }
.nav-wordmark small{ display: block; font-family: var(--font-mono); font-size: 0.55rem; letter-spacing: 0.22em; color: var(--paper-muted); font-weight: 400; }
.nav-links{ display: flex; gap: var(--space-lg); font-size: var(--fs-small); }
.nav-links a{ position: relative; padding: 0.3em 0; color: var(--paper); opacity: 0.85; }
.nav-links a:hover,
.nav-links a[aria-current="page"]{ opacity: 1; }
.nav-links a::after{
  content: ''; position: absolute; left: 0; right: 100%; bottom: 0; height: 1px;
  background: var(--teal); transition: right var(--dur-med) var(--ease-out);
}
.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after{ right: 0; }
.nav-right{ display: flex; align-items: center; gap: var(--space-md); }
.nav-toggle{ display: none; flex-direction: column; gap: 5px; padding: 0.5em; }
.nav-toggle span{ width: 22px; height: 2px; background: var(--paper); display: block; }
.nav-mobile{
  position: fixed; inset: var(--nav-h) 0 0 0; z-index: 999;
  background: var(--coal); color: var(--paper);
  padding: var(--space-lg) var(--gutter);
  transform: translateY(-8px); opacity: 0; visibility: hidden;
  transition: transform var(--dur-med) var(--ease-out), opacity var(--dur-med), visibility var(--dur-med);
}
.nav-mobile[data-open="true"]{ transform: translateY(0); opacity: 1; visibility: visible; }
.nav-mobile a{ display: block; padding: 0.9em 0; font-family: var(--font-display); font-size: var(--fs-h3); border-bottom: 1px solid var(--line-on-coal); }
.nav-mobile .btn{ margin-top: var(--space-lg); }

/* ---------- Services dropdown (desktop) ---------- */
.nav-item.has-dropdown{ position: relative; }
.nav-drop-trigger{
  display: inline-flex; align-items: center; gap: 0.35em;
  font: inherit; color: var(--paper); opacity: 0.85;
  background: none; border: 0; padding: 0.3em 0; cursor: pointer;
  position: relative;
}
.nav-drop-trigger:hover, .nav-item.has-dropdown.is-open .nav-drop-trigger{ opacity: 1; }
.nav-drop-trigger::after{
  content: ''; position: absolute; left: 0; right: 100%; bottom: 0; height: 1px;
  background: var(--teal); transition: right var(--dur-med) var(--ease-out);
}
.nav-drop-trigger:hover::after, .nav-item.has-dropdown.is-open .nav-drop-trigger::after{ right: 0; }
.nav-drop-caret{ font-size: 0.7em; transition: transform var(--dur-med) var(--ease-out); display: inline-block; }
.nav-item.has-dropdown.is-open .nav-drop-caret{ transform: rotate(180deg); }
.nav-dropdown{
  position: absolute; top: 100%; left: 50%; transform: translate(-50%, 8px);
  min-width: 260px; max-width: 320px;
  margin-top: 0.9em;
  background: rgba(11,20,32,0.96);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line-on-coal);
  border-radius: var(--radius-md);
  padding: 0.5em;
  display: flex; flex-direction: column;
  box-shadow: 0 20px 50px rgba(0,0,0,0.35);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out), visibility var(--dur-med);
  z-index: 1200;
}
.nav-item.has-dropdown.is-open .nav-dropdown{
  opacity: 1; visibility: visible; pointer-events: auto;
  transform: translate(-50%, 0);
}
.nav-dropdown a{
  padding: 0.65em 0.8em; border-radius: var(--radius-sm);
  color: var(--paper); opacity: 0.85; font-size: var(--fs-small);
  white-space: nowrap;
}
.nav-dropdown a:hover, .nav-dropdown a:focus-visible{ opacity: 1; background: rgba(255,255,255,0.06); }

/* ---------- Services accordion (mobile) ---------- */
.nav-mobile-item.has-accordion{ border-bottom: 1px solid var(--line-on-coal); }
.nav-accordion-trigger{
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  font: inherit; font-family: var(--font-display); font-size: var(--fs-h3);
  color: var(--paper); background: none; border: 0; padding: 0.9em 0; cursor: pointer;
}
.nav-accordion-icon{ font-size: 1.1em; line-height: 1; transition: transform var(--dur-med) var(--ease-out); }
.nav-mobile-item.has-accordion.is-open .nav-accordion-icon{ transform: rotate(45deg); }
.nav-accordion-panel{
  max-height: 0; overflow: hidden;
  transition: max-height var(--dur-med) var(--ease-out);
}
.nav-mobile-item.has-accordion.is-open .nav-accordion-panel{ max-height: 640px; }
.nav-accordion-panel a{
  font-family: var(--font-body); font-size: var(--fs-body); padding: 0.7em 0 0.7em 0.8em;
  border-bottom: 1px solid var(--line-on-coal);
}
.nav-accordion-panel a:last-child{ border-bottom: 0; }

@media (max-width: 900px){
  .nav-links{ display: none; }
  .nav-toggle{ display: flex; }
  .nav-right .btn{ display: none; }
}

/* ---------- Hero ---------- */
.hero{
  color: var(--paper);
  justify-content: flex-end;
}
.hero-visual{
  position: absolute; inset: 0; z-index: 0;
  overflow: hidden;
}
.hero-photo{
  width: 108%; height: 108%;
  position: absolute; top: -4%; left: -4%;
  transform: translate3d(var(--px, 0), var(--py, 0), 0) scale(1.05);
  will-change: transform;
}
.hero-mesh{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0.45; pointer-events: none;
}
.hero-veil{
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(11,20,32,0.35) 0%, rgba(11,20,32,0.15) 35%, rgba(11,20,32,0.82) 100%),
    linear-gradient(90deg, rgba(11,20,32,0.72) 0%, rgba(11,20,32,0.15) 58%);
}
.hotspot{
  position: absolute;
  left: var(--hx); top: var(--hy);
  z-index: 2;
  width: auto; height: auto;
  background: none;
}
.hotspot span{
  display: block; width: 14px; height: 14px; border-radius: 50%;
  border: 1.5px solid var(--teal);
  background: rgba(45,217,196,0.18);
  box-shadow: 0 0 0 0 rgba(45,217,196,0.45);
  animation: hotspotPulse 2.4s var(--ease-out) infinite;
}
.hotspot em{
  position: absolute; left: 22px; top: 50%; transform: translateY(-50%);
  font-style: normal; font-family: var(--font-mono); font-size: var(--fs-micro);
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--paper);
  white-space: nowrap;
  opacity: 0; pointer-events: none;
  background: rgba(11,20,32,0.72);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line-on-coal);
  padding: 0.45em 0.7em; border-radius: 999px;
  transition: opacity var(--dur-fast);
}
.hotspot:hover em, .hotspot:focus-visible em{ opacity: 1; }
@keyframes hotspotPulse{
  0%{ box-shadow: 0 0 0 0 rgba(45,217,196,0.5); }
  70%{ box-shadow: 0 0 0 12px rgba(45,217,196,0); }
  100%{ box-shadow: 0 0 0 0 rgba(45,217,196,0); }
}
.hero-inner{
  position: relative; z-index: 2;
  /* max-width: 46rem; */
  padding: calc(var(--nav-h) + 1.25rem) var(--gutter) 5.25rem;
}
.hero-headline{
  font-family: var(--font-display);
  font-size: var(--fs-hero);
  font-weight: 600;
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin: var(--space-md) 0;
}
.hero-headline em{
  font-style: normal;
  background: linear-gradient(100deg, var(--teal), var(--teal-light));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub{
  font-size: var(--fs-body-lg);
  color: var(--paper-muted);
  /* max-width: 40ch; */
  margin-bottom: var(--space-lg);
}
.hero-actions{ display: flex; gap: var(--space-md); flex-wrap: wrap; margin-bottom: var(--space-lg); }
.hero-status{
  display: inline-flex; align-items: center; gap: 0.6em;
  font-size: var(--fs-micro);
  color: var(--paper-muted);
  border: 1px solid var(--line-on-coal);
  padding: 0.6em 1em;
  border-radius: 999px;
  background: rgba(11,20,32,0.35);
  backdrop-filter: blur(8px);
}
.status-dot{
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--status-good);
  box-shadow: 0 0 0 0 rgba(52,209,126,0.6);
  animation: statusPulse 2.4s var(--ease-out) infinite;
}
@keyframes statusPulse{
  0%{ box-shadow: 0 0 0 0 rgba(52,209,126,0.55); }
  70%{ box-shadow: 0 0 0 8px rgba(52,209,126,0); }
  100%{ box-shadow: 0 0 0 0 rgba(52,209,126,0); }
}
.hero-scroll-cue{
  position: absolute; bottom: var(--space-lg); left: var(--gutter); z-index: 2;
  font-family: var(--font-mono); font-size: var(--fs-micro);
  color: var(--paper-muted); text-transform: uppercase; letter-spacing: 0.2em;
  display: flex; align-items: center; gap: 0.8em;
}
.hero-scroll-cue::after{
  content: ''; width: 1px; height: 28px; background: var(--paper-muted);
  animation: scrollCue 2s ease-in-out infinite;
}
@keyframes scrollCue{ 0%,100%{ transform: scaleY(0.4); opacity: 0.4; } 50%{ transform: scaleY(1); opacity: 1; } }

/* ---------- Reveal ---------- */
html.js-enabled [data-reveal]{
  opacity: 0; transform: translateY(28px);
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out);
}
html.js-enabled [data-reveal].is-visible{ opacity: 1; transform: none; }
[data-reveal-group] > *{ transition-delay: calc(var(--i, 0) * 70ms); }

/* ---------- Brand statement / spotlight ---------- */
.statement{
  color: var(--paper);
  align-items: center;
  justify-content: center;
  text-align: center;
}
.spotlight{ position: absolute; inset: 0; }
.spotlight img{
  width: 100%; height: 100%;
  filter: saturate(1.05);
}
.spotlight-mask{
  position: absolute; inset: 0;
  background:
    radial-gradient(circle 220px at var(--mx, 50%) var(--my, 42%), transparent 0%, rgba(11,20,32,0.22) 28%, rgba(11,20,32,0.86) 70%);
  transition: background 80ms linear;
}
.statement-text{
  position: relative; z-index: 2;
  font-family: var(--font-display);
  font-size: var(--fs-display);
  font-weight: 500;
  line-height: 1.15;
  /* max-width: 22ch; */
  letter-spacing: -0.01em;
  padding: 0 var(--gutter);
}
.statement-text .accent{ color: var(--teal); }
.statement-hint{
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  z-index: 2; color: var(--paper-muted); font-size: var(--fs-micro);
  letter-spacing: 0.16em; text-transform: uppercase;
}

/* ---------- Services ---------- */
.services-fs{ color: var(--paper); }
.services-split{
  display: grid;
  grid-template-columns: minmax(18rem, 0.95fr) 1.15fr;
  gap: var(--space-xl);
  align-items: center;
  height: 100%;
}
.services-copy .section-lede{ margin: var(--space-md) 0 var(--space-lg); }
.service-picker{ display: flex; flex-direction: column; border-top: 1px solid var(--line-on-coal); }
.service-pick{
  display: grid;
  grid-template-columns: 2.6rem 1fr;
  gap: 0.75rem;
  align-items: center;
  width: 100%;
  padding: 0.85rem 0.2rem;
  border-bottom: 1px solid var(--line-on-coal);
  color: var(--paper);
  transition: color var(--dur-fast), padding-left var(--dur-med) var(--ease-out);
}
.service-pick:hover,
.service-pick.is-active{ color: var(--teal-light); padding-left: 0.55rem; }
.service-index{ font-family: var(--font-mono); color: var(--teal); font-size: var(--fs-small); }
.service-name{
  font-family: var(--font-display);
  font-size: clamp(1rem, 0.92rem + 0.4vw, 1.2rem);
  font-weight: 600;
  letter-spacing: -0.01em;
}
.services-visual{ height: calc(100svh - var(--nav-h) - 3.5rem); max-height: 760px; }
.svc-frame{
  position: relative;
  height: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--line-on-coal);
  transform-style: preserve-3d;
}
.svc-frame img{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 520ms var(--ease-out), transform 900ms var(--ease-out);
}
.svc-frame img.is-active{ opacity: 1; transform: scale(1); }
.svc-caption{
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.4rem 1.35rem 1.25rem;
  background: linear-gradient(180deg, transparent, rgba(11,20,32,0.88));
}
.svc-kicker{ color: var(--teal-light); font-size: var(--fs-micro); letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 0.45rem; }
.svc-desc{ color: var(--paper); max-width: 46ch; margin-bottom: 0.7rem; }
.service-tags{ display: flex; flex-wrap: wrap; gap: 0.5em; }
.tag{
  font-family: var(--font-mono); font-size: var(--fs-micro);
  color: var(--paper); border: 1px solid var(--line-on-coal);
  padding: 0.35em 0.7em; border-radius: 999px;
  background: rgba(11,20,32,0.35);
}

@media (max-width: 980px){
  .services-split{ grid-template-columns: 1fr; gap: var(--space-md); }
  .services-visual{ height: 42vh; min-height: 260px; }
}

/* ---------- AI Transformation & Intelligent Automation ---------- */
.ai-fs{ }
.ai-split{
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: var(--space-xl);
  align-items: center;
  height: 100%;
}
.ai-copy .section-lede{ margin: var(--space-md) 0 var(--space-md); }
.ai-list{
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 0.1rem 1.5rem; margin-bottom: var(--space-lg);
}
.ai-list-item{
  display: flex; align-items: center; gap: 0.65em;
  font-family: var(--font-display); font-weight: 600; font-size: 0.94rem;
  padding: 0.6em 0; border-bottom: 1px solid var(--line-on-white);
}
.ai-list-item .idx{ font-family: var(--font-mono); color: var(--teal); font-size: var(--fs-small); flex: none; }
.ai-tagline{
  font-family: var(--font-display); font-size: 1.02rem; font-weight: 500; line-height: 1.55;
  max-width: 46ch; padding-left: var(--space-md);
  border-left: 2px solid var(--teal);
  color: var(--ink-muted);
}
.ai-visual{
  position: relative;
  height: calc(100svh - var(--nav-h) - 3.5rem); max-height: 640px;
  border-radius: var(--radius-md); overflow: hidden;
  border: 1px solid var(--line-on-white);
  background: var(--coal);
}
.ai-visual svg{ width: 100%; height: 100%; }
.ai-visual-caption{
  position: absolute; left: 1.1rem; bottom: 1rem;
  font-size: var(--fs-micro); letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--paper-muted);
}

@media (max-width: 980px){
  .ai-split{ grid-template-columns: 1fr; gap: var(--space-md); }
  .ai-list{ grid-template-columns: 1fr; }
  .ai-visual{ height: 42vh; min-height: 260px; }
}

/* ---------- Case studies ---------- */
.cases-fs{
  background: var(--coal);
  color: var(--paper);
  padding: calc(var(--nav-h) + 0.8rem) var(--gutter) 1.4rem;
  gap: 1rem;
}
.cases-head{
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: var(--space-md); flex-wrap: wrap; flex: 0 0 auto; z-index: 2;
}
.cases-stage{
  flex: 1 1 auto;
  display: flex; gap: 0.75rem;
  min-height: 0;
}
.case-panel{
  position: relative;
  flex: 1 1 38%;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--line-on-coal);
  cursor: pointer;
  transition: flex-basis 620ms var(--ease-out);
}
.case-panel.is-open{ flex-basis: 62%; }
.case-panel img{
  width: 100%; height: 100%;
  transform: scale(1.06);
  transition: transform 800ms var(--ease-out);
}
.case-panel:hover img, .case-panel.is-open img{ transform: scale(1); }
.case-veil{
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,20,32,0.08) 20%, rgba(11,20,32,0.86) 100%);
}
.case-body{
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.4rem 1.35rem 1.3rem;
  display: flex; flex-direction: column; gap: 0.55rem;
}
.case-tag{ font-family: var(--font-mono); font-size: var(--fs-micro); color: var(--teal); text-transform: uppercase; letter-spacing: 0.1em; }
.case-title{ font-family: var(--font-display); font-size: var(--fs-h3); font-weight: 600; }
.case-panel .service-desc{
  color: rgba(246,248,247,0.82);
  max-width: 46ch;
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height 500ms var(--ease-out), opacity 400ms;
}
.case-panel.is-open .service-desc{ max-height: 7em; opacity: 1; }
.case-stats{ display: flex; gap: var(--space-md); flex-wrap: wrap; }
.case-stat b{ font-family: var(--font-mono); color: var(--teal); font-size: var(--fs-h3); display: block; }
.case-stat span{ font-size: var(--fs-micro); color: var(--paper-muted); text-transform: uppercase; letter-spacing: 0.08em; }
.case-link{ font-family: var(--font-mono); font-size: var(--fs-small); display: inline-flex; align-items: center; gap: 0.5em; }

@media (max-width: 900px){
  .cases-stage{ flex-direction: column; }
  .case-panel, .case-panel.is-open{ flex: 1 1 auto; min-height: 280px; }
  .case-panel .service-desc{ max-height: 7em; opacity: 1; }
}

/* ---------- Infrastructure ---------- */
.solutions-fs{ color: var(--paper); }
.infra-split{
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: var(--space-xl);
  align-items: center;
}
.infra-photo{
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--line-on-coal);
  aspect-ratio: 4/3;
  transform-style: preserve-3d;
}
.infra-photo img{ width: 100%; height: 100%; filter: brightness(0.72) saturate(1.1); }
.infra-overlay{ position: absolute; inset: 0; width: 100%; height: 100%; }
.infra-list{ display: flex; flex-direction: column; gap: var(--space-md); margin-top: var(--space-lg); }
.infra-item{ display: flex; gap: var(--space-md); align-items: flex-start; }
.infra-item .idx{ font-family: var(--font-mono); color: var(--teal); font-size: var(--fs-small); }
.infra-item h4{ font-family: var(--font-display); font-size: 1.15rem; font-weight: 600; margin-bottom: 0.2em; }
.infra-item p{ color: var(--paper-muted); font-size: var(--fs-small); max-width: 40ch; }
.certs{ display: flex; flex-wrap: wrap; gap: 0.65rem; margin-top: var(--space-lg); }
.cert{
  border: 1px solid var(--line-on-coal); border-radius: var(--radius-sm);
  padding: 0.7em 1em; font-family: var(--font-mono); font-size: var(--fs-micro);
  color: var(--paper-muted); letter-spacing: 0.05em;
  background: rgba(16,28,41,0.55);
}

@media (max-width: 900px){ .infra-split{ grid-template-columns: 1fr; } }

/* ---------- Proof ---------- */
.proof-fs{ color: var(--paper); }
.proof-visual{ position: absolute; inset: 0; }
.proof-visual img{ width: 100%; height: 100%; }
.proof-veil{
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,20,32,0.72) 0%, rgba(11,20,32,0.78) 100%);
}
.proof-inner{ height: 100%; display: flex; flex-direction: column; justify-content: center; }
.metrics-row{
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
  border-top: 1px solid var(--line-on-coal);
  border-bottom: 1px solid var(--line-on-coal);
  padding: var(--space-lg) 0;
  margin-bottom: var(--space-lg);
}
.metric b{
  font-family: var(--font-mono); font-weight: 500;
  font-size: clamp(2rem, 1.5rem + 2vw, 3.5rem);
  color: var(--paper); display: block;
}
.metric span{ color: var(--paper-muted); font-size: var(--fs-small); }
.testimonials{ display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-lg); }
.testimonial{
  display: flex; flex-direction: column; gap: var(--space-md);
  padding: 1.15rem 1.2rem;
  border: 1px solid var(--line-on-coal);
  border-radius: var(--radius-md);
  background: rgba(11,20,32,0.38);
  backdrop-filter: blur(10px);
}
.testimonial blockquote{ font-family: var(--font-display); font-size: 1.12rem; font-weight: 500; line-height: 1.4; margin: 0; }
.testimonial cite{ font-style: normal; font-size: var(--fs-small); color: var(--paper-muted); display: flex; flex-direction: column; }
.testimonial cite b{ color: var(--paper); }

@media (max-width: 900px){
  .metrics-row{ grid-template-columns: repeat(2, 1fr); }
  .testimonials{ grid-template-columns: 1fr; }
}

/* ---------- Team ---------- */
.team-fs{ background: var(--white); color: var(--ink); }
.team-grid{
  display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-md);
}
.team-card{ display: flex; flex-direction: column; gap: 0.6em; }
.team-photo{
  aspect-ratio: 4/5; border-radius: var(--radius-md);
  overflow: hidden; position: relative;
}
.team-photo img{
  width: 100%; height: 100%;
  transition: transform 700ms var(--ease-out);
}
.team-card:hover .team-photo img{ transform: scale(1.06); }
.team-name{ font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
.team-role{ font-family: var(--font-mono); font-size: var(--fs-micro); color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.08em; }

@media (max-width: 900px){ .team-grid{ grid-template-columns: repeat(2, 1fr); } }

/* ---------- Process ---------- */
.process-fs{ color: var(--paper); }
.process-visual{ position: absolute; inset: 0; }
.process-visual img{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 560ms var(--ease-out), transform 900ms var(--ease-out);
}
.process-visual img.is-active{ opacity: 1; transform: scale(1); }
.process-veil{
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,20,32,0.55) 0%, rgba(11,20,32,0.82) 100%);
}
.process-inner{
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  flex: 1;
  min-height: 0;
  height: 100%;
  padding-bottom: 2.4rem;
}
.process-track{
  display: grid; grid-template-columns: repeat(5, 1fr);
  gap: 0.7rem;
  margin-top: var(--space-lg);
  position: relative;
}
.process-step{
  position: relative;
  display: flex; flex-direction: column; gap: 0.55em;
  padding: 1rem 0.9rem 1.05rem;
  border: 1px solid var(--line-on-coal);
  border-radius: var(--radius-md);
  background: rgba(11,20,32,0.42);
  backdrop-filter: blur(12px);
  color: var(--paper);
  transition: border-color var(--dur-fast), transform var(--dur-med) var(--ease-out), background var(--dur-fast);
}
.process-step:hover,
.process-step.is-active{
  border-color: var(--teal);
  background: rgba(11,20,32,0.62);
  transform: translateY(-4px);
}
.process-num{
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  background: rgba(11,20,32,0.55); border: 1px solid var(--teal);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: var(--fs-small); color: var(--teal);
}
.process-step h4{ font-family: var(--font-display); font-size: 1.05rem; font-weight: 600; }
.process-step p{ font-size: var(--fs-small); color: var(--paper-muted); }

@media (max-width: 900px){
  .process-track{ grid-template-columns: 1fr; }
  .process-inner{ padding-top: calc(var(--nav-h) + 1.5rem); }
}

/* ---------- Final CTA ---------- */
.final-cta{
  background: var(--coal);
  color: var(--paper);
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  align-items: stretch;
  padding: 0;
}
.cta-visual{
  position: relative;
  height: 100%;
  overflow: hidden;
}
.cta-visual img{ width: 100%; height: 100%; object-fit: cover; }
.cta-veil{
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(11,20,32,0.15), rgba(11,20,32,0.35));
}
.cta-visual-label{
  position: absolute; left: 1.4rem; bottom: 1.4rem;
  font-size: var(--fs-micro); letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--paper);
  border: 1px solid var(--line-on-coal);
  padding: 0.55em 0.85em; border-radius: 999px;
  background: rgba(11,20,32,0.45);
  backdrop-filter: blur(8px);
}
.final-cta-inner{
  display: flex; flex-direction: column; justify-content: center;
  gap: var(--space-lg);
  padding: calc(var(--nav-h) + 1.5rem) var(--gutter) 2.4rem;
}
.final-cta h2{
  font-family: var(--font-display); font-size: var(--fs-display);
  font-weight: 600; line-height: 1.05; letter-spacing: -0.01em;
}
.final-cta .section-lede{ margin-top: var(--space-md); }
.contact-form{ display: flex; flex-direction: column; gap: var(--space-md); max-width: 34rem; }
.form-row{ display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-md); }
.field{ display: flex; flex-direction: column; gap: 0.4em; }
.field label{ font-family: var(--font-mono); font-size: var(--fs-micro); text-transform: uppercase; letter-spacing: 0.08em; color: var(--paper-muted); }
.field input, .field select, .field textarea{
  background: rgba(16,28,41,0.55); border: 1px solid var(--line-on-coal);
  color: var(--paper); padding: 0.85em 1em; border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: var(--fs-body);
}
.field input:focus, .field select:focus, .field textarea:focus{ border-color: var(--teal); outline: none; }
.form-note{ font-size: var(--fs-micro); color: var(--paper-muted); }
.form-success,
.form-error{
  display: none; border-radius: var(--radius-sm); padding: var(--space-md);
  font-family: var(--font-mono); font-size: var(--fs-small);
}
.form-success{ border: 1px solid var(--teal); color: var(--teal); }
.form-error{ border: 1px solid var(--status-bad); color: #F5C2C4; }
.form-error a{ color: var(--teal); text-decoration: underline; text-underline-offset: 0.15em; }
.form-success.is-visible,
.form-error.is-visible{ display: block; }
.contact-form{ position: relative; }
.contact-form.is-sending{ opacity: 0.72; pointer-events: none; }
.hp{
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
}

@media (max-width: 900px){
  .final-cta{ grid-template-columns: 1fr; }
  .cta-visual{ min-height: 36vh; }
  .cta-visual img{ min-height: 36vh; }
  .form-row{ grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */
.site-footer{
  background: var(--coal); color: var(--paper-muted);
  padding: var(--space-xl) var(--gutter) var(--space-lg);
  position: relative; overflow: hidden;
  border-top: 1px solid var(--line-on-coal);
}
.footer-grid{
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-lg); position: relative; z-index: 1;
}
.footer-brand{ display: flex; flex-direction: column; gap: var(--space-md); max-width: 26ch; }
.footer-brand svg{ width: 34px; height: 34px; }
.footer-tagline{ font-family: var(--font-mono); font-size: var(--fs-micro); letter-spacing: 0.14em; text-transform: uppercase; color: var(--teal-light); }
.footer-col h5{ font-family: var(--font-mono); font-size: var(--fs-micro); text-transform: uppercase; letter-spacing: 0.1em; color: var(--paper); margin-bottom: var(--space-md); }
.footer-col a, .footer-col p{ display: block; margin-bottom: 0.65em; font-size: var(--fs-small); }
.footer-col a:hover{ color: var(--teal-light); }
.footer-bottom{
  display: flex; justify-content: space-between; align-items: center;
  margin-top: var(--space-xl); padding-top: var(--space-lg);
  border-top: 1px solid var(--line-on-coal);
  font-size: var(--fs-micro); flex-wrap: wrap; gap: var(--space-sm);
}

@media (max-width: 900px){
  .footer-grid{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px){
  .footer-grid{ grid-template-columns: 1fr; }
  .footer-bottom{ flex-direction: column; align-items: flex-start; }
}

/* ---------- Ultra-wide refinement ---------- */
@media (min-width: 1800px){
  :root{ --gutter: clamp(3rem, 2vw + 4rem, 8rem); }
}

/* ---------- Print / utility ---------- */
.visually-hidden{
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap;
}

html.is-preview .loader{ display: none !important; }
html.is-preview .fs-section{
  height: 900px;
  min-height: 900px;
  scroll-snap-align: none;
}

@media (max-width: 1099px){
  html:not(.is-preview) .fs-section{ height: auto; min-height: 100svh; }
}

@media (min-width: 1100px) and (max-height: 820px){
  .hero-headline{ font-size: clamp(2.1rem, 1.4rem + 2.6vw, 4.2rem); }
  .hero-inner{ padding-bottom: 4.2rem; }
  .services-visual{ max-height: 620px; }
  .service-pick{ padding: 0.62rem 0.2rem; }
  .team-photo{ aspect-ratio: 4/4.4; }
  .metrics-row{ padding: 1.1rem 0; }
  .testimonial blockquote{ font-size: 1rem; }
  .process-step p{ display: none; }
}

/* ---------- Developer tools lock ---------- */
html.devlock-on,
html.devlock-on body{ overflow: hidden !important; }
.devlock-overlay{
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  align-items: center;
  justify-content: center;
  background: rgba(11, 20, 32, 0.96);
  color: var(--paper);
  padding: var(--gutter);
}
.devlock-overlay.is-on{ display: flex; }
.devlock-card{
  max-width: 28rem;
  text-align: center;
}
.devlock-kicker{
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 var(--space-sm);
}
.devlock-card h2{
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  margin: 0 0 var(--space-sm);
}
.devlock-card p{
  color: var(--paper-muted);
  margin: 0;
}


