:root {
  --ink: #112033;
  --navy: #0b2138;
  --navy-2: #123552;
  --teal: #078998;
  --teal-dark: #056a76;
  --aqua: #6ed4d6;
  --sand: #f2eee7;
  --paper: #fbfaf7;
  --white: #ffffff;
  --muted: #5b6875;
  --line: #d9e0e4;
  --success: #1d7a5b;
  --warning: #aa6b16;
  --shadow: 0 24px 70px rgba(11, 33, 56, 0.12);
  --radius: 22px;
  --max: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, Aptos, "Segoe UI", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 1000;
  padding: 10px 14px;
  color: var(--white);
  background: var(--navy);
  border-radius: 8px;
  transform: translateY(-150%);
}

.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(217, 224, 228, 0.75);
  background: rgba(251, 250, 247, 0.92);
  backdrop-filter: blur(14px);
}

.nav-wrap {
  width: min(calc(100% - 40px), var(--max));
  min-height: 78px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand strong { font-size: 1.05rem; }
.brand span { color: var(--teal-dark); font-size: 0.72rem; font-weight: 750; letter-spacing: 0.12em; text-transform: uppercase; }

.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { color: var(--navy); font-size: 0.92rem; font-weight: 700; text-decoration: none; }
.nav-links a:hover, .nav-links a:focus-visible { color: var(--teal-dark); }

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  color: var(--navy);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.btn {
  display: inline-flex;
  min-height: 48px;
  padding: 0 20px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 750;
  text-decoration: none;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.btn:hover { transform: translateY(-2px); }
.btn-primary { color: var(--white); background: var(--teal-dark); }
.btn-primary:hover { background: var(--navy); }
.btn-secondary { color: var(--navy); border-color: var(--line); background: var(--white); }
.btn-small { min-height: 40px; padding: 0 15px; border-radius: 10px; font-size: 0.86rem; }

.container { width: min(calc(100% - 40px), var(--max)); margin: 0 auto; }
.section { padding: 96px 0; }
.section-soft { background: var(--sand); }
.section-dark { color: var(--white); background: var(--navy); }

.eyebrow {
  margin: 0 0 14px;
  color: var(--teal-dark);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.section-dark .eyebrow { color: var(--aqua); }

h1, h2, h3 { margin: 0; color: var(--navy); line-height: 1.1; letter-spacing: -0.035em; }
.section-dark h2, .section-dark h3 { color: var(--white); }
h1 { max-width: 820px; font-size: clamp(2.7rem, 6vw, 5.4rem); }
h2 { max-width: 760px; font-size: clamp(2rem, 4vw, 3.5rem); }
h3 { font-size: 1.35rem; }

.lead { max-width: 690px; color: var(--muted); font-size: clamp(1.05rem, 1.8vw, 1.24rem); }
.section-dark .lead { color: #c9d6df; }
.section-head { margin-bottom: 46px; }
.section-head .lead { margin: 18px 0 0; }

.hero {
  min-height: 720px;
  display: grid;
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 90% 10%, rgba(110, 212, 214, 0.22), transparent 30%),
    linear-gradient(135deg, #fbfaf7 0%, #f4f2ec 100%);
}

.hero-grid {
  padding: 76px 0 64px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(310px, 0.65fr);
  gap: 70px;
  align-items: center;
}

.hero-copy .lead { margin: 26px 0 0; }
.hero-actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }

.portrait-shell {
  position: relative;
  max-width: 430px;
  margin-left: auto;
}

.portrait-shell::before {
  content: "";
  position: absolute;
  inset: 34px -24px -24px 28px;
  border-radius: 34px;
  background: linear-gradient(160deg, var(--teal), var(--navy));
}

.portrait-shell img {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border: 8px solid var(--white);
  border-radius: 30px;
  box-shadow: var(--shadow);
}

.impact-strip {
  margin-top: -42px;
  position: relative;
  z-index: 3;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.metric { padding: 28px; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric strong { display: block; color: var(--navy); font-size: 2rem; letter-spacing: -0.04em; }
.metric span { display: block; margin-top: 4px; color: var(--muted); font-size: 0.88rem; }

.grid-4, .grid-3, .grid-2 { display: grid; gap: 22px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  padding: 28px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.card-number { color: var(--teal-dark); font-weight: 850; }
.card h3 { margin-top: 24px; }
.card p { margin: 12px 0 0; color: var(--muted); }

.system-flow {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
}

.system-step {
  position: relative;
  min-height: 150px;
  padding: 20px;
  color: var(--white);
  background: var(--navy-2);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
}

.system-step span { display: block; margin-bottom: 35px; color: var(--aqua); font-size: 0.76rem; font-weight: 850; }
.system-step strong { font-size: 1.08rem; }

.case-card { padding: 0; overflow: hidden; }
.case-top { min-height: 190px; padding: 28px; display: flex; flex-direction: column; justify-content: space-between; color: var(--white); background: linear-gradient(145deg, var(--navy), var(--teal-dark)); }
.case-top.alt { background: linear-gradient(145deg, #173a42, #178d84); }
.case-top.warm { background: linear-gradient(145deg, #463b32, #967455); }
.case-code { font-size: 0.75rem; font-weight: 850; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.82; }
.case-top h3 { max-width: 320px; color: var(--white); font-size: 1.65rem; }
.case-body { padding: 26px 28px 30px; }
.case-body p { color: var(--muted); }
.case-results { margin: 20px 0; padding: 0; list-style: none; }
.case-results li { padding: 9px 0; border-top: 1px solid var(--line); font-size: 0.9rem; font-weight: 700; }
.text-link { color: var(--teal-dark); font-weight: 800; text-decoration-thickness: 1px; text-underline-offset: 4px; }

.ai-preview {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 50px;
  align-items: center;
}

.cockpit {
  padding: 18px;
  color: var(--ink);
  background: #eaf0f2;
  border: 1px solid #7d98a7;
  border-radius: 22px;
  box-shadow: 0 26px 70px rgba(0,0,0,.22);
}

.cockpit-bar { margin-bottom: 14px; display: flex; justify-content: space-between; align-items: center; font-size: 0.72rem; font-weight: 850; }
.status-dot { width: 8px; height: 8px; display: inline-block; margin-right: 6px; background: #2baa76; border-radius: 50%; }
.cockpit-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.cockpit-tile { min-height: 100px; padding: 14px; background: var(--white); border-radius: 13px; }
.cockpit-tile span { color: var(--muted); font-size: 0.7rem; }
.cockpit-tile strong { display: block; margin-top: 12px; color: var(--navy); font-size: 1.35rem; }
.cockpit-tile.wide { grid-column: span 2; }
.bar { height: 9px; margin-top: 12px; overflow: hidden; background: #e4e9ec; border-radius: 8px; }
.bar i { height: 100%; display: block; background: var(--teal); border-radius: inherit; }

.logo-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.logo-card { min-height: 140px; padding: 24px; display: grid; place-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 16px; }
.logo-card img { max-width: 165px; max-height: 80px; object-fit: contain; }
.logo-card.intact img { max-width: 195px; max-height: 95px; }
.disclosure { margin-top: 18px; color: var(--muted); font-size: 0.76rem; }

.cta-panel {
  padding: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  color: var(--white);
  background: linear-gradient(135deg, var(--navy), #124f62);
  border-radius: 28px;
}
.cta-panel h2 { color: var(--white); font-size: clamp(1.8rem, 4vw, 3rem); }
.cta-panel p { max-width: 650px; color: #d3e0e7; }

.page-hero { padding: 96px 0 76px; background: linear-gradient(145deg, var(--navy), #14465a); }
.page-hero h1 { max-width: 930px; color: var(--white); font-size: clamp(2.5rem, 5vw, 4.7rem); }
.page-hero .lead { color: #d6e2e7; }
.breadcrumbs { margin-bottom: 28px; color: var(--aqua); font-size: 0.8rem; font-weight: 750; }
.breadcrumbs a { text-underline-offset: 4px; }

.case-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 70px; align-items: start; }
.prose h2 { margin-top: 54px; font-size: 2rem; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 32px; }
.prose p, .prose li { color: #43515e; }
.prose ul { padding-left: 20px; }
.sidebar { position: sticky; top: 110px; }
.sidebar .card + .card { margin-top: 16px; }
.fact { padding: 14px 0; border-bottom: 1px solid var(--line); }
.fact:last-child { border-bottom: 0; }
.fact span { display: block; color: var(--muted); font-size: .74rem; font-weight: 750; text-transform: uppercase; letter-spacing: .08em; }
.fact strong { display: block; margin-top: 4px; }

.method-tags { display: flex; flex-wrap: wrap; gap: 9px; }
.tag { padding: 7px 11px; color: var(--teal-dark); background: #e6f3f3; border-radius: 999px; font-size: .78rem; font-weight: 750; }

.ai-controls { display: grid; grid-template-columns: 1fr 1fr auto; gap: 14px; margin-bottom: 24px; }
.field label { display: block; margin-bottom: 6px; color: var(--navy); font-size: .78rem; font-weight: 800; }
.field select { width: 100%; min-height: 48px; padding: 0 12px; color: var(--ink); background: var(--white); border: 1px solid #b8c6ce; border-radius: 10px; }
.portfolio-table { width: 100%; border-collapse: collapse; }
.portfolio-table th, .portfolio-table td { padding: 15px 14px; text-align: left; border-bottom: 1px solid var(--line); }
.portfolio-table th { color: var(--muted); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; }
.badge { padding: 5px 9px; display: inline-block; border-radius: 999px; font-size: .72rem; font-weight: 850; }
.badge.green { color: #176748; background: #dff3e9; }
.badge.amber { color: #895510; background: #faedcf; }
.badge.red { color: #8a3535; background: #f8dddd; }
.decision-brief { min-height: 180px; margin-top: 24px; padding: 26px; background: var(--navy); border-radius: 16px; }
.decision-brief h3 { color: var(--white); }
.decision-brief p { color: #d5e0e7; }

.timeline { position: relative; margin-top: 40px; }
.timeline::before { content: ""; position: absolute; left: 16px; top: 10px; bottom: 10px; width: 2px; background: var(--line); }
.timeline-item { position: relative; padding: 0 0 36px 54px; }
.timeline-item::before { content: ""; position: absolute; left: 9px; top: 7px; width: 14px; height: 14px; background: var(--teal); border: 3px solid var(--paper); border-radius: 50%; box-shadow: 0 0 0 2px var(--teal); }
.timeline-item time { color: var(--teal-dark); font-size: .78rem; font-weight: 850; }
.timeline-item h3 { margin-top: 5px; }
.timeline-item p { margin: 8px 0 0; color: var(--muted); }

.site-footer { padding: 44px 0; color: #b9c8d1; background: #071828; }
.footer-grid { display: flex; justify-content: space-between; gap: 30px; }
.footer-grid strong { color: var(--white); }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a { color: #dbe5eb; }

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

@media (max-width: 980px) {
  .hero-grid, .ai-preview, .case-layout { grid-template-columns: 1fr; }
  .portrait-shell { width: min(78vw, 420px); margin: 10px auto 20px; }
  .metric-grid, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2) { border-right: 0; }
  .metric:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .system-flow { grid-template-columns: repeat(3,1fr); }
  .grid-3 { grid-template-columns: 1fr; }
  .logo-row { grid-template-columns: repeat(2,1fr); }
  .sidebar { position: static; }
}

@media (max-width: 760px) {
  .section { padding: 72px 0; }
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 78px;
    left: 20px;
    right: 20px;
    padding: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 10px; }
  .nav-links .btn { width: 100%; }
  .hero { min-height: auto; }
  .hero-grid { padding-top: 60px; gap: 46px; }
  h1 { font-size: clamp(2.6rem, 13vw, 4rem); }
  .impact-strip { margin-top: 0; padding-top: 24px; }
  .metric-grid, .grid-4, .grid-2, .system-flow, .logo-row { grid-template-columns: 1fr; }
  .metric { border-right: 0; border-bottom: 1px solid var(--line); }
  .metric:last-child { border-bottom: 0; }
  .system-step { min-height: 120px; }
  .system-step span { margin-bottom: 18px; }
  .cockpit-grid { grid-template-columns: 1fr 1fr; }
  .cockpit-tile.wide { grid-column: span 2; }
  .cta-panel, .footer-grid { align-items: flex-start; flex-direction: column; }
  .cta-panel { padding: 34px 26px; }
  .ai-controls { grid-template-columns: 1fr; }
  .portfolio-scroll { overflow-x: auto; }
  .portfolio-table { min-width: 680px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
