/* OUI Technologies — ouitech.net marketing site
   Editorial dark/mint + warm paper bands. Fraunces (display) / Inter (text) /
   IBM Plex Mono (report + technical motifs). No frameworks. */

:root {
  --bg: #0b1210;
  --bg-2: #0e1714;
  --panel: #101b17;
  --line: rgba(230, 245, 240, 0.09);
  --line-strong: rgba(230, 245, 240, 0.16);
  --text: #e8f4ee;
  --muted: #93aaa0;
  --mint: #2fd39e;
  --mint-bright: #7ff0cf;
  --mint-dim: rgba(47, 211, 158, 0.14);
  --flag: #ffb054;
  --err: #ff8a8f;
  --paper: #f2efe6;
  --paper-2: #eae6d9;
  --ink: #17211c;
  --ink-muted: #5c6b62;
  --ink-line: rgba(23, 33, 28, 0.14);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 70px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
::selection { background: var(--mint); color: #05271d; }

a { color: var(--mint-bright); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 28px; }
@media (max-width: 640px) { .wrap { padding: 0 20px; } }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 18, 16, 0.82); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-in { display: flex; align-items: center; gap: 28px; height: 62px; }
.wordmark {
  font: 600 15px/1 var(--mono); letter-spacing: 0.08em; color: var(--text);
  display: flex; align-items: center; gap: 10px; white-space: nowrap;
}
.wordmark:hover { text-decoration: none; }
.wordmark .tick { color: var(--mint); }
.nav-links { display: flex; gap: 22px; margin-left: auto; align-items: center; }
.nav-links a { font-size: 13.5px; color: var(--muted); letter-spacing: 0.01em; }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-cta {
  font: 600 13px/1 var(--sans); color: #05271d !important;
  background: var(--mint); padding: 10px 16px; border-radius: 999px;
}
.nav-cta:hover { background: var(--mint-bright); text-decoration: none !important; }
@media (max-width: 760px) { .nav-links a:not(.nav-cta) { display: none; } }

/* mobile menu */
.menu-btn {
  display: none; background: none; border: 1px solid var(--line-strong);
  border-radius: 10px; width: 42px; height: 36px; cursor: pointer; position: relative; flex: none;
}
.menu-btn span { position: absolute; left: 11px; right: 11px; height: 1.6px; background: var(--text); transition: all .22s ease; }
.menu-btn span:nth-child(1) { top: 12px; }
.menu-btn span:nth-child(2) { top: 17px; }
.menu-btn span:nth-child(3) { top: 22px; }
.menu-btn.open span:nth-child(1) { top: 17px; transform: rotate(45deg); }
.menu-btn.open span:nth-child(2) { opacity: 0; }
.menu-btn.open span:nth-child(3) { top: 17px; transform: rotate(-45deg); }
.drawer { display: none; }
@media (max-width: 760px) {
  .menu-btn { display: block; }
  .drawer { display: block; overflow: hidden; max-height: 0; transition: max-height .32s ease; }
  .drawer.open { max-height: 400px; }
  .drawer a {
    display: block; padding: 15px 28px; color: var(--text); font-size: 15px;
    border-top: 1px solid var(--line); text-decoration: none;
  }
  .drawer a:hover { color: var(--mint-bright); text-decoration: none; }
}

/* ---------- type ---------- */
.eyebrow {
  font: 500 12px/1 var(--mono); letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--mint); display: flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: var(--mint); }
h1, .h1 {
  font-family: var(--serif); font-weight: 560; letter-spacing: -0.015em;
  font-size: clamp(38px, 6vw, 66px); line-height: 1.04; margin: 22px 0 0;
}
h2, .h2 {
  font-family: var(--serif); font-weight: 540; letter-spacing: -0.01em;
  font-size: clamp(28px, 3.6vw, 40px); line-height: 1.12; margin: 18px 0 0;
}
.lede { font-size: 18px; line-height: 1.7; color: var(--muted); max-width: 56ch; margin: 22px 0 0; }
.lede b, .lede strong { color: var(--text); font-weight: 600; }

/* ---------- buttons ---------- */
.btn-row { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; align-items: center; }
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font: 600 15px/1 var(--sans); border-radius: 999px; padding: 15px 26px;
  border: 1px solid transparent; cursor: pointer; transition: all .18s ease;
}
.btn.primary { background: var(--mint); color: #05271d; }
.btn.primary:hover { background: var(--mint-bright); text-decoration: none; transform: translateY(-1px); }
.btn.ghost { border-color: var(--line-strong); color: var(--text); background: transparent; }
.btn.ghost:hover { border-color: var(--mint); color: var(--mint-bright); text-decoration: none; }
.btn.on-paper { background: var(--ink); color: var(--paper); }
.btn.on-paper:hover { background: #0b1310; text-decoration: none; }

/* ---------- hero ---------- */
.hero { padding: 92px 0 74px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 64px; align-items: center; }
@media (max-width: 940px) { .hero-grid { grid-template-columns: 1fr; gap: 48px; } }
.hero .lede { font-size: 19px; }
.hero-note { margin-top: 26px; font: 400 12.5px/1.6 var(--mono); color: var(--muted); }
.hero-note .k { color: var(--mint); }

/* mock report card */
.report-card {
  background: var(--panel); border: 1px solid var(--line-strong); border-radius: 14px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  font-family: var(--mono); font-size: 13px; overflow: hidden;
}
.report-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 18px; border-bottom: 1px solid var(--line);
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted);
}
.report-head .live { display: flex; align-items: center; gap: 8px; color: var(--mint); }
.report-head .live i {
  width: 7px; height: 7px; border-radius: 50%; background: var(--mint);
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .25 } }
.report-field { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.report-field:last-child { border-bottom: 0; }
.report-label { font-size: 10.5px; letter-spacing: 0.18em; color: var(--muted); text-transform: uppercase; margin-bottom: 8px; }
.report-text { line-height: 1.75; color: #cfe6dc; min-height: 44px; }
.caret {
  display: inline-block; width: 8px; height: 15px; margin-left: 2px;
  background: var(--mint); vertical-align: -2px; animation: blink 1.05s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0 } }
.hl-ok { color: var(--mint-bright); border-bottom: 1px solid rgba(127, 240, 207, .5); }
.hl-flag { color: var(--flag); border-bottom: 1px dashed var(--flag); }
.flag-chip {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 12px;
  font-size: 11px; letter-spacing: 0.04em; color: var(--flag);
  border: 1px solid rgba(255, 176, 84, 0.4); background: rgba(255, 176, 84, 0.08);
  padding: 6px 11px; border-radius: 999px;
}
.flag-chip svg { flex: none; }

/* ---------- ticker ---------- */
.ticker { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); overflow: hidden; }
.ticker-track {
  display: flex; gap: 0; width: max-content;
  animation: ticker 46s linear infinite; padding: 13px 0;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-track span {
  font: 400 12px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted); padding: 0 34px; white-space: nowrap; position: relative;
}
.ticker-track span::after { content: "✳"; position: absolute; right: -7px; color: var(--mint); font-size: 10px; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- sections as stacked cards ----------
   Each card is position:sticky. JS (layoutStack) sets its `top` so a card
   pins only once it has been FULLY read (bottom at viewport bottom), then
   the next card slides up over it — works in both scroll directions, no
   scroll-hijacking. Without JS, no `top` is set and sticky degrades to
   normal flow. */
.section, .cta-band {
  max-width: 1240px; margin: 22px auto; padding: 88px 0;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 26px;
  position: sticky;
  display: flex; align-items: center;
  min-height: 88vh; min-height: 88svh;
  box-shadow: 0 -26px 70px rgba(0, 0, 0, 0.5);
}
.section > .wrap, .cta-band > .wrap { width: 100%; }
.section.paper { border-color: rgba(23, 33, 28, 0.06); box-shadow: 0 -26px 70px rgba(0, 0, 0, 0.38); }
@media (max-width: 1290px) { .section, .cta-band { margin-left: 18px; margin-right: 18px; } }
@media (max-width: 640px) {
  .section, .cta-band { margin: 12px 10px; padding: 58px 0; border-radius: 18px; }
}
/* the page must end ABOVE the stack: footer rides over all pinned cards */
footer { position: relative; z-index: 40; background: var(--bg); }
/* rise-in: cards drift up as they enter (added via JS, exempted for reduced motion) */
.rise { opacity: 0; transform: translateY(24px) scale(0.988); transition: opacity .7s ease, transform .7s cubic-bezier(.16, 1, .3, 1); }
.rise.in { opacity: 1; transform: none; }
.section-head { display: flex; align-items: baseline; gap: 26px; margin-bottom: 8px; }
.sec-num { font: 500 13px/1 var(--mono); color: var(--mint); letter-spacing: 0.1em; }
.section .lede { margin-top: 16px; }

/* steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 54px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step { background: var(--bg-2); padding: 34px 30px 38px; }
.step .n { font: 500 13px/1 var(--mono); color: var(--mint); }
.step h3 { font: 540 21px/1.3 var(--serif); margin: 14px 0 10px; letter-spacing: -0.01em; }
.step p { font-size: 14.5px; color: var(--muted); margin: 0; line-height: 1.7; }
.clients-row { display: flex; gap: 10px; margin-top: 48px; flex-wrap: wrap; }
.client-pill {
  font: 500 12px/1 var(--mono); letter-spacing: 0.08em; color: var(--muted);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 9px 16px;
}
.client-pill b { color: var(--text); font-weight: 500; }

/* ---------- paper band ---------- */
.paper { background: var(--paper); color: var(--ink); }
.paper .eyebrow { color: #0e7c5c; }
.paper .eyebrow::before { background: #0e7c5c; }
.paper .lede { color: var(--ink-muted); }
.paper .lede b { color: var(--ink); }
.paper h2 { color: var(--ink); }

/* mismatch demo */
.demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 54px; }
@media (max-width: 860px) { .demo-grid { grid-template-columns: 1fr; } }
.demo-col {
  background: #fffdf6; border: 1px solid var(--ink-line); border-radius: 12px;
  padding: 24px 26px; font-family: var(--mono); font-size: 13px; line-height: 1.85; color: #33413a;
  box-shadow: 0 14px 40px rgba(23, 33, 28, 0.07);
}
.demo-col .report-label { color: var(--ink-muted); }
.mk-ok { background: rgba(47, 211, 158, 0.16); border-bottom: 2px solid #16a67a; padding: 1px 3px; border-radius: 3px; }
.mk-bad { background: rgba(224, 122, 27, 0.13); border-bottom: 2px dashed #d97a1c; padding: 1px 3px; border-radius: 3px; }
.demo-verdict {
  grid-column: 1 / -1; display: flex; align-items: center; gap: 14px;
  background: var(--ink); color: var(--paper); border-radius: 12px; padding: 18px 24px;
  font: 400 13.5px/1.6 var(--mono);
}
.demo-verdict .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--flag); flex: none; animation: pulse 1.6s ease-in-out infinite; }
.demo-verdict b { color: var(--mint-bright); font-weight: 500; }
.check-notes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 56px; }
@media (max-width: 860px) { .check-notes { grid-template-columns: 1fr; gap: 28px; } }
.check-notes h4 { font: 540 17px/1.35 var(--serif); margin: 0 0 8px; }
.check-notes p { font-size: 14px; color: var(--ink-muted); margin: 0; line-height: 1.7; }
.check-notes .rule { border-top: 1px solid var(--ink-line); padding-top: 18px; }

/* ---------- E2EE ---------- */
.e2ee-flow {
  display: grid; grid-template-columns: 1fr auto 1fr auto 1.25fr; gap: 18px;
  align-items: stretch; margin-top: 56px;
}
@media (max-width: 900px) { .e2ee-flow { grid-template-columns: 1fr; } .e2ee-arrow { transform: rotate(90deg); justify-self: center; } }
.e2ee-node {
  border: 1px solid var(--line-strong); border-radius: 12px; padding: 22px;
  background: var(--panel);
}
.e2ee-node .t { font: 500 11px/1 var(--mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--mint); margin-bottom: 12px; }
.e2ee-node p { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.65; }
.e2ee-node code { font-family: var(--mono); color: var(--text); font-size: 12.5px; }
.e2ee-arrow { align-self: center; color: var(--mint); font: 400 18px/1 var(--mono); }
.cipher {
  font-family: var(--mono); font-size: 11.5px; line-height: 1.8; color: #4e6a5f;
  word-break: break-all; margin-top: 10px; user-select: none;
}
.e2ee-claims { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 56px; }
@media (max-width: 860px) { .e2ee-claims { grid-template-columns: 1fr; } }
.claim { background: var(--bg-2); padding: 26px 26px 30px; }
.claim .k { font: 500 12px/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--mint); }
.claim p { font-size: 14px; color: var(--muted); margin: 12px 0 0; line-height: 1.7; }
.claim p b { color: var(--text); font-weight: 600; }

/* ---------- features ---------- */
.feat-list { margin-top: 50px; border-top: 1px solid var(--line); }
.feat {
  display: grid; grid-template-columns: 220px 1fr; gap: 34px;
  padding: 26px 0; border-bottom: 1px solid var(--line);
}
@media (max-width: 720px) { .feat { grid-template-columns: 1fr; gap: 8px; } }
.feat h4 { margin: 0; font: 540 18px/1.4 var(--serif); letter-spacing: -0.005em; }
.feat p { margin: 0; font-size: 14.5px; color: var(--muted); line-height: 1.7; max-width: 66ch; }
.feat p b { color: var(--text); font-weight: 600; }

/* ---------- org band ---------- */
.org-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 70px; align-items: start; }
@media (max-width: 900px) { .org-grid { grid-template-columns: 1fr; gap: 40px; } }
.org-points { margin: 40px 0 0; padding: 0; list-style: none; }
.org-points li {
  padding: 18px 0 18px 34px; border-top: 1px solid var(--ink-line);
  font-size: 15px; color: var(--ink); position: relative; line-height: 1.65;
}
.org-points li::before {
  content: "—"; position: absolute; left: 0; color: #0e7c5c; font-family: var(--mono);
}
.org-points li b { font-weight: 600; }
.org-aside {
  background: #fffdf6; border: 1px solid var(--ink-line); border-radius: 12px; padding: 30px;
  box-shadow: 0 14px 40px rgba(23,33,28,.07);
}
.org-aside .t { font: 500 11px/1 var(--mono); letter-spacing: 0.16em; text-transform: uppercase; color: #0e7c5c; }
.org-aside p { font-size: 14.5px; color: var(--ink-muted); line-height: 1.75; }

/* ---------- founder ---------- */
.founder { text-align: left; max-width: 780px; }
.founder blockquote {
  font: italic 500 clamp(24px, 3vw, 34px)/1.4 var(--serif); letter-spacing: -0.01em;
  margin: 26px 0 0; color: var(--text);
}
.founder .who { margin-top: 28px; font: 400 13px/1.7 var(--mono); color: var(--muted); }
.founder .who b { color: var(--mint); font-weight: 500; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin-top: 46px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center;
  padding: 22px 4px; font: 540 17px/1.45 var(--serif); letter-spacing: -0.005em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 22px/1 var(--mono); color: var(--mint); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .a { padding: 0 4px 24px; font-size: 14.5px; color: var(--muted); line-height: 1.75; max-width: 70ch; }
.faq .a b { color: var(--text); font-weight: 600; }

/* ---------- CTA band ---------- */
.cta-band { text-align: center; }
.cta-band h2 { margin: 18px auto 0; max-width: 17ch; }
.cta-band .btn-row { justify-content: center; }
.cta-band .eyebrow { justify-content: center; }
.cta-band .eyebrow::before { display: none; }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line); padding: 54px 0 64px; }
.foot-grid { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.foot-tag { font: 400 13px/1.8 var(--mono); color: var(--muted); max-width: 40ch; }
.foot-tag .wordmark { margin-bottom: 14px; }
.foot-col { font-size: 13.5px; line-height: 2.1; }
.foot-col .t { font: 500 11px/1 var(--mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.foot-col a { color: var(--text); display: block; }
.foot-col a:hover { color: var(--mint-bright); text-decoration: none; }
.foot-legal { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }

/* ---------- inner pages ---------- */
.page-head { padding: 84px 0 30px; }
.page-head .lede { margin-top: 18px; }

/* forms */
.form-card {
  max-width: 620px; background: var(--panel); border: 1px solid var(--line-strong);
  border-radius: 16px; padding: 38px; margin: 40px 0 100px;
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 620px) { .form-grid { grid-template-columns: 1fr; } }
.form-grid .full { grid-column: 1 / -1; }
.form-card label { display: block; font: 500 11px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.form-card input, .form-card select, .form-card textarea {
  width: 100%; background: var(--bg); border: 1px solid var(--line-strong); border-radius: 10px;
  color: var(--text); font: 400 15px/1.5 var(--sans); padding: 13px 14px; outline: none;
  transition: border-color .15s;
}
.form-card textarea { resize: vertical; min-height: 130px; }
.form-card input:focus, .form-card select:focus, .form-card textarea:focus { border-color: var(--mint); }
.form-card .btn { width: 100%; justify-content: center; margin-top: 26px; }
.form-msg { margin-top: 18px; font-size: 14px; display: none; line-height: 1.6; }
.form-msg.ok { display: block; color: var(--mint-bright); }
.form-msg.err { display: block; color: var(--err); }
.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.form-after { display: none; text-align: center; padding: 30px 0 10px; }
.form-after.show { display: block; }
.form-after .big { font: 540 26px/1.3 var(--serif); }
.form-after p { color: var(--muted); font-size: 14.5px; }

/* pricing */
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin: 54px 0 26px; align-items: stretch; }
@media (max-width: 900px) { .tiers { grid-template-columns: 1fr; } }
.tier {
  border: 1px solid var(--line-strong); border-radius: 16px; padding: 34px 30px 38px;
  background: var(--panel); display: flex; flex-direction: column;
}
.tier.hot { border-color: var(--mint); position: relative; }
.tier.hot::before {
  content: "MOST POPULAR"; position: absolute; top: -11px; left: 28px;
  font: 600 10px/1 var(--mono); letter-spacing: 0.18em; color: #05271d;
  background: var(--mint); padding: 6px 12px; border-radius: 999px;
}
.tier .name { font: 500 12px/1 var(--mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--mint); }
.tier .price { font: 560 34px/1.1 var(--serif); margin: 18px 0 4px; letter-spacing: -0.01em; }
.tier .per { font-size: 13px; color: var(--muted); min-height: 20px; }
.tier ul { list-style: none; margin: 26px 0 30px; padding: 0; flex: 1; }
.tier li { padding: 9px 0 9px 26px; font-size: 14px; color: var(--muted); border-top: 1px solid var(--line); position: relative; line-height: 1.55; }
.tier li::before { content: "✓"; position: absolute; left: 2px; color: var(--mint); font-family: var(--mono); font-size: 12px; }
.tier li b { color: var(--text); font-weight: 600; }
.tier .btn { justify-content: center; }
.price-note { font-size: 13px; color: var(--muted); line-height: 1.7; max-width: 72ch; margin-bottom: 100px; }
.anchor-line { font: 400 13px/1.8 var(--mono); color: var(--muted); border-left: 2px solid var(--mint); padding-left: 18px; margin-top: 40px; max-width: 62ch; }
.anchor-line b { color: var(--text); font-weight: 500; }

/* misc */
.contact-alt { font-size: 14.5px; color: var(--muted); margin-top: 18px; }
.skip { position: absolute; left: -9999px; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal, .rise { opacity: 1; transform: none; transition: none; }
  .ticker-track { animation: none; }
  .caret, .report-head .live i, .demo-verdict .dot { animation: none; }
}
