:root {
  --bg: #f5f1e8;
  --bg-alt: #ebe4d4;
  --surface: #fbf8f1;
  --olive-900: #1f2a22;
  --olive-800: #2b3a30;
  --olive-600: #5a705f;
  --text: #273029;
  --muted: #5f665f;
  --gold: #a6844f;
  --gold-deep: #8e6f3f;
  --highlight: #f2d9a6;
  --line: #d3c9b6;
  --shadow: 0 18px 48px rgba(31, 42, 34, 0.11);
}

::selection {
  background: var(--highlight);
  color: var(--olive-900);
}

::-moz-selection {
  background: var(--highlight);
  color: var(--olive-900);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 98px;
}

body {
  background: radial-gradient(circle at 18% 8%, #fff8eb 0%, var(--bg) 36%, #e7e0cf 100%);
  color: var(--text);
  font-family: "Manrope", "Montserrat", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

.page-glow {
  position: fixed;
  inset: -20% -10% auto;
  height: 40rem;
  background: radial-gradient(circle, rgba(166, 132, 79, 0.15), transparent 68%);
  pointer-events: none;
  z-index: -1;
  transform: translate3d(0, var(--glow-shift, 0px), 0);
  transition: transform 220ms linear;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 88%, white 12%);
  border-bottom: 1px solid rgba(31, 42, 34, 0.08);
  backdrop-filter: blur(8px);
  transition: transform 260ms ease, box-shadow 260ms ease, background-color 260ms ease;
}

.site-header.is-elevated {
  box-shadow: 0 10px 24px rgba(31, 42, 34, 0.08);
}

.site-header.header-hidden {
  transform: translateY(-102%);
}

.scroll-progress {
  height: 2px;
  width: 100%;
  background: rgba(31, 42, 34, 0.06);
}

.scroll-progress span {
  display: block;
  height: 100%;
  width: var(--scroll-progress, 0%);
  background: linear-gradient(90deg, var(--gold), #c3a26f);
  transition: width 80ms linear;
}

.nav-row {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  text-decoration: none;
  color: var(--olive-900);
  font-size: 1.08rem;
  letter-spacing: 0.22rem;
  font-weight: 800;
}

.top-nav {
  display: flex;
  gap: 1.5rem;
}

.top-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1;
  white-space: nowrap;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease;
}

.top-nav a:hover {
  color: var(--olive-900);
  background: rgba(166, 132, 79, 0.08);
}

.top-nav a.active {
  color: var(--olive-900);
  background: rgba(166, 132, 79, 0.14);
  border-color: rgba(166, 132, 79, 0.22);
}

.hero {
  padding: 5.5rem 0 4.2rem;
}

.hero-wrap {
  text-align: center;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12rem;
  font-size: 0.78rem;
  color: var(--olive-600);
  margin: 0 0 0.8rem;
  font-weight: 700;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.15;
}

h1 {
  font-size: clamp(2.1rem, 5vw, 4.8rem);
  color: var(--olive-900);
  letter-spacing: -0.03em;
  max-width: 900px;
  margin: 0 auto;
}

.hero-copy {
  max-width: 760px;
  margin: 1.2rem auto 2rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.hero-cta {
  display: flex;
  justify-content: center;
  gap: 1.15rem;
  flex-wrap: wrap;
  margin-bottom: 2.8rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background: linear-gradient(145deg, var(--gold), var(--gold-deep));
  color: #fff9ef;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  padding: 0.78rem 1.35rem;
  border: 1px solid rgba(255, 249, 239, 0.25);
  box-shadow: 0 10px 24px rgba(142, 111, 63, 0.26);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-sm {
  padding: 0.62rem 1rem;
  font-size: 0.84rem;
}

.text-link {
  color: var(--olive-800);
  font-weight: 700;
  text-decoration: none;
  padding: 0.75rem 0.5rem;
}

.interface-mockup {
  margin-top: 1.5rem;
  border: 1px solid var(--line);
  background: linear-gradient(150deg, #fcfaf4, #f4efe3);
  border-radius: 24px;
  box-shadow: var(--shadow);
  text-align: left;
  overflow: hidden;
  transform: translate3d(0, var(--mockup-shift, 0px), 0);
  transition: transform 260ms linear;
}

.window-bar {
  min-height: 48px;
  border-bottom: 1px solid rgba(39, 48, 41, 0.12);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.75rem 1rem;
}

.window-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #cbbba0;
}

.window-bar p {
  margin: 0 0 0 0.45rem;
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 700;
}

.window-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  min-height: 320px;
}

.window-grid aside {
  border-right: 1px solid rgba(39, 48, 41, 0.12);
  padding: 1.25rem 1rem;
}

.window-grid aside h3 {
  font-size: 0.88rem;
  color: var(--olive-800);
  margin-bottom: 0.7rem;
}

.window-grid ul {
  margin: 0;
  padding-left: 1.05rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.window-grid article {
  padding: 1.25rem;
}

.query-chip {
  display: inline-flex;
  font-size: 0.83rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  color: var(--olive-800);
  background: #f8f3e8;
}

.answer-block {
  margin-top: 1rem;
  background: #fffdf8;
  border: 1px solid #dfd4bf;
  border-radius: 14px;
  padding: 1rem;
}

.answer-block p {
  margin: 0;
  color: var(--text);
}

.meta-row {
  margin-top: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.meta-row span {
  font-size: 0.77rem;
  color: var(--muted);
  border: 1px solid #ddd1ba;
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
}

.section {
  padding: 5rem 0;
}

.section h2 {
  font-size: clamp(1.75rem, 3.3vw, 3rem);
  letter-spacing: -0.02em;
  color: var(--olive-900);
  max-width: 760px;
}

.alt {
  background: linear-gradient(180deg, var(--bg-alt), #e6decd);
  border-top: 1px solid #d6cdbb;
  border-bottom: 1px solid #d6cdbb;
}

.card-grid {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.pain-intro {
  margin-top: 1rem;
  max-width: 780px;
  color: var(--muted);
  font-size: 1.04rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 1.35rem;
  box-shadow: 0 12px 30px rgba(39, 48, 41, 0.06);
}

.card h3,
.engineering-grid h3,
.journey h3 {
  font-size: 1.15rem;
  margin-bottom: 0.6rem;
  color: var(--olive-800);
}

.card p,
.engineering-grid p,
.cta-box p {
  margin: 0;
  color: var(--muted);
}

.cost-breakdown {
  margin-top: 1.25rem;
  border: 1px solid #d2c7b3;
  border-radius: 20px;
  background: linear-gradient(160deg, #fbf6ec, #f1e8d6);
  padding: 1.3rem;
  box-shadow: 0 12px 30px rgba(39, 48, 41, 0.08);
}

.cost-breakdown h3 {
  font-size: 1.08rem;
  color: var(--olive-900);
  margin-bottom: 0.9rem;
}

.cost-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}

.cost-grid article {
  border: 1px solid #d8ccb6;
  border-radius: 14px;
  background: #fffcf6;
  padding: 0.85rem;
}

.cost-label,
.cost-math,
.cost-value {
  margin: 0;
}

.cost-label {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--olive-600);
  font-weight: 700;
}

.cost-math {
  margin-top: 0.45rem;
  font-size: 0.89rem;
  color: var(--muted);
}

.cost-value {
  margin-top: 0.55rem;
  font-size: 1.18rem;
  color: var(--olive-900);
  font-weight: 800;
}

.cost-total {
  margin-top: 0.9rem;
  border: 1px solid #cfb98f;
  border-radius: 14px;
  background: linear-gradient(145deg, #ac8a54, #8f6f3f);
  color: #fff9ef;
  padding: 0.9rem 1rem;
  display: grid;
  gap: 0.2rem;
}

.cost-total span {
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.cost-total strong {
  font-size: 1.45rem;
  line-height: 1.1;
}

.cost-total small {
  font-size: 0.83rem;
  opacity: 0.9;
}

.split {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 2rem;
  align-items: center;
}

.check-list {
  margin: 1.4rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.85rem;
}

.check-list li {
  padding-left: 1.6rem;
  position: relative;
  color: var(--text);
  font-weight: 600;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.48rem;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--gold), #7f6742);
}

.wall-diagram {
  background: #f8f3e8;
  border: 1px solid #cfc4ae;
  border-radius: 20px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  min-height: 220px;
}

.left-zone,
.right-zone {
  padding: 1.2rem;
}

.left-zone p,
.right-zone p {
  margin: 0;
  font-weight: 800;
  color: var(--olive-900);
}

.left-zone small,
.right-zone small {
  color: var(--muted);
}

.barrier {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #243328, #1d271f);
  color: #f6ecd9;
  padding: 1rem 0.6rem;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 800;
}

.engineering-grid {
  margin-top: 1.6rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.engineering-grid article {
  background: #f8f4ea;
  border: 1px solid #d8cdb9;
  border-radius: 18px;
  padding: 1.25rem;
}

.index-flow {
  margin-top: 1.8rem;
  border: 1px solid #cfc3ac;
  background: #fbf7ed;
  border-radius: 18px;
  padding: 1.1rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  align-items: center;
  gap: 0.65rem;
  font-weight: 700;
}

.flow-file,
.flow-engine,
.flow-state {
  border: 1px solid #d8ccb5;
  border-radius: 12px;
  padding: 0.7rem;
  text-align: center;
  background: #fffdf8;
}

.flow-arrow {
  color: var(--olive-600);
  text-align: center;
}

.flow-engine {
  position: relative;
}

.pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  display: inline-block;
  margin-right: 0.5rem;
  animation: ping 2s infinite;
}

@keyframes ping {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  80% {
    transform: scale(1.8);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 0;
  }
}

.roi-grid {
  margin-top: 1.8rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.journey {
  background: #f9f4e9;
  border: 1px solid #d8ccb6;
  border-radius: 18px;
  padding: 1.2rem;
}

.journey ol {
  margin: 0.7rem 0 0;
  padding-left: 1.1rem;
  color: var(--text);
}

.before {
  opacity: 0.82;
}

.after {
  background: linear-gradient(180deg, #fff8e8, #f4ecd9);
}

.cta {
  padding-bottom: 6rem;
}

.cta-box {
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fbf8f2;
  padding: 2.1rem;
  box-shadow: var(--shadow);
}

.cta-box h2 {
  margin: 0 auto;
}

.cta-box p {
  max-width: 680px;
  margin: 1rem auto 1.4rem;
}

.site-footer {
  border-top: 1px solid rgba(39, 48, 41, 0.12);
  padding: 1.5rem 0 2rem;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.88rem;
}

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 700ms ease, transform 700ms ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }

  .page-glow,
  .interface-mockup,
  .reveal,
  .reveal.in-view {
    transform: none !important;
    opacity: 1 !important;
  }
}

@media (max-width: 980px) {
  .top-nav {
    display: none;
  }

  .site-header.header-hidden {
    transform: translateY(0);
  }

  .split,
  .window-grid,
  .engineering-grid,
  .card-grid,
  .cost-grid,
  .roi-grid,
  .index-flow {
    grid-template-columns: 1fr;
  }

  .barrier {
    writing-mode: horizontal-tb;
    transform: none;
    padding: 0.6rem;
  }

  .wall-diagram {
    grid-template-columns: 1fr;
  }

  .flow-arrow {
    transform: rotate(90deg);
  }

  .hero {
    padding-top: 4.2rem;
  }
}
