/* ============================================================
   Revyi — site-wide styles
   ============================================================ */

:root {
  --primary-900: #0b2631;
  --primary-800: #10384a;
  --primary-700: #164b62;
  --primary-600: #1B5E7B;
  --primary-500: #2A7A9B;
  --primary-100: #cce5ef;
  --primary-50:  #e6f2f7;
  --accent:      #5BC0BE;
  --accent-deep: #2DA3A0;
  --ink:         #0E1F26;
  --ink-soft:    #3B4B53;
  --muted:       #6B7A82;
  --line:        #E6EBEE;
  --line-strong: #D6DEE3;
  --bg:          #F7F6F2;
  --bg-card:     #FFFFFF;
  --bg-deep:     #0B2531;
  --warn:        #C76F2F;
  --good:        #2F9E6E;
  --bad:         #C24E4E;
  --radius:      14px;
  --radius-lg:   22px;
  --shadow-sm:   0 1px 2px rgba(15,30,40,.04), 0 1px 1px rgba(15,30,40,.03);
  --shadow-md:   0 8px 24px -8px rgba(15,30,40,.10), 0 2px 4px rgba(15,30,40,.04);
  --shadow-lg:   0 24px 48px -16px rgba(15,30,40,.18), 0 4px 8px rgba(15,30,40,.04);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  text-wrap: pretty;
}
.mono { font-family: 'IBM Plex Mono', ui-monospace, monospace; }

.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- NAV ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 246, 242, 0.85);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background .2s ease;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}
.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--primary-600);
  display: grid;
  place-items: center;
  box-shadow: 0 2px 6px rgba(27,94,123,.25);
}
.brand-name {
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.02em;
  color: var(--primary-700);
}
.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav-links a:not(.btn) {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color .15s ease;
  position: relative;
}
.nav-links a:not(.btn):hover { color: var(--primary-700); }
.nav-links a.is-active {
  color: var(--primary-700);
  font-weight: 600;
}
.nav-links a.is-active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -22px;
  height: 2px; background: var(--accent-deep);
}
.nav-login {
  position: relative;
  padding-left: 24px !important;
}
.nav-login::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 1px; height: 16px;
  background: var(--line);
}

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14.5px;
  text-decoration: none;
  transition: transform .12s ease, box-shadow .15s ease, background .15s ease;
  cursor: pointer;
  border: 0;
  line-height: 1;
  white-space: nowrap;
}
.btn-primary {
  background: var(--primary-600);
  color: #fff;
  box-shadow: 0 6px 16px -6px rgba(27,94,123,.55), inset 0 1px 0 rgba(255,255,255,.12);
}
.btn-primary:hover {
  background: var(--primary-700);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px -8px rgba(27,94,123,.65), inset 0 1px 0 rgba(255,255,255,.12);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line-strong);
}
.btn-ghost:hover { border-color: var(--primary-600); color: var(--primary-700); }
.btn-lg { padding: 15px 26px; font-size: 15.5px; border-radius: 12px; }
.btn .arrow { transition: transform .15s ease; }
.btn:hover .arrow { transform: translateX(2px); }

/* ---------- TYPE ---------- */
h1 {
  font-size: clamp(32px, 3.2vw, 44px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 700;
  color: var(--primary-900);
  margin: 20px 0 22px;
  text-wrap: balance;
}
h1 em {
  font-style: normal;
  color: var(--primary-600);
  position: relative;
}
h1 em::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 4px;
  height: 10px;
  background: rgba(91,192,190,.32);
  z-index: -1;
  border-radius: 2px;
}
h2 {
  font-size: clamp(30px, 3.6vw, 42px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-weight: 700;
  color: var(--primary-900);
  margin: 0 0 16px;
}
h3 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
  color: var(--primary-900);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 8px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 100px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-soft);
  box-shadow: var(--shadow-sm);
}
.eyebrow .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent-deep);
  box-shadow: 0 0 0 4px rgba(91,192,190,.18);
}
.lede {
  font-size: 17.5px;
  color: var(--ink-soft);
  max-width: 520px;
  margin: 0 0 28px;
  line-height: 1.55;
}
.cta-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.micro {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}
.micro svg { color: var(--accent-deep); }
.strike {
  text-decoration: line-through;
  color: var(--bad);
  text-decoration-thickness: 2px;
  text-decoration-color: rgba(194,78,78,.6);
}

/* ---------- SECTION SHELL ---------- */
section { scroll-margin-top: 88px; }
.section { padding: 96px 0; }
.section-deep {
  background: linear-gradient(180deg, #fff 0%, #FBFAF7 100%);
}
.section-head {
  max-width: 720px;
  margin: 0 auto 56px;
  text-align: center;
}
.section-eyebrow {
  color: var(--accent-deep);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.section-sub {
  font-size: 18px;
  color: var(--ink-soft);
  margin: 0;
  line-height: 1.55;
}

/* ---------- PAGE HERO (subpages) ---------- */
.page-hero {
  padding: 80px 0 56px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(ellipse at 80% 0%, rgba(91,192,190,.12), transparent 55%),
    var(--bg);
}
.page-hero .crumb {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 24px;
  display: flex; align-items: center; gap: 10px;
}
.page-hero .crumb::before {
  content: ''; width: 28px; height: 1px; background: var(--accent-deep);
}
.page-hero h1 {
  font-size: clamp(40px, 5vw, 64px);
  margin: 0 0 18px;
  max-width: 18ch;
}
.page-hero .lede {
  font-size: 19px;
  max-width: 640px;
  margin: 0;
}

/* ---------- PROBLEM (full-bleed dark) ---------- */
.problem-bleed {
  background: var(--bg-deep);
  color: #E8EEF1;
  padding: 120px 0 140px;
  position: relative;
  overflow: hidden;
}
.problem-bleed::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(800px 400px at 85% 10%, rgba(91,192,190,.08), transparent 60%),
    radial-gradient(600px 300px at 10% 90%, rgba(45,163,160,.06), transparent 60%);
  pointer-events: none;
}
.problem-bleed > .wrap { position: relative; }
.problem-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 0.04em;
  margin-bottom: 28px;
  display: flex; align-items: center; gap: 10px;
}
.problem-tag::before {
  content: ''; width: 28px; height: 1px; background: var(--accent);
}
.problem-headline {
  font-size: clamp(40px, 5.2vw, 78px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.02;
  color: #fff;
  margin: 0 0 80px;
  max-width: 16ch;
  text-wrap: balance;
}
.problem-headline .accent {
  color: var(--accent);
  font-style: italic;
  font-weight: 500;
}
.problem-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
.problem-row {
  padding: 36px 32px 36px 0;
  border-right: 1px solid rgba(255,255,255,.08);
  position: relative;
}
.problem-row:last-child { border-right: none; padding-right: 0; }
.problem-row:first-child { padding-left: 0; }
.problem-row:not(:first-child) { padding-left: 32px; }
.problem-row .label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: rgba(232,238,241,.45);
  margin-bottom: 20px;
  display: block;
  letter-spacing: 0.02em;
}
.problem-row .label .num { color: var(--accent); }
.problem-row h3 {
  font-size: 22px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.problem-row p {
  color: rgba(232,238,241,.65);
  font-size: 15px;
  line-height: 1.6;
  margin: 0;
}
.problem-row .strike {
  text-decoration: line-through;
  text-decoration-color: rgba(194,78,78,.7);
  text-decoration-thickness: 2px;
  color: rgba(232,238,241,.4);
}

/* ---------- HOW IT WORKS ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  position: relative;
}
.steps::before {
  content: '';
  position: absolute;
  top: 32px;
  left: 12%;
  right: 12%;
  height: 2px;
  background: repeating-linear-gradient(90deg, var(--line-strong) 0, var(--line-strong) 6px, transparent 6px, transparent 12px);
  z-index: 0;
}
.step {
  text-align: center;
  padding: 0 22px;
  position: relative;
  z-index: 1;
}
.step-num {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--primary-600);
  color: var(--primary-700);
  font-weight: 700;
  font-size: 22px;
  display: grid; place-items: center;
  margin: 0 auto 22px;
  box-shadow: 0 4px 12px -2px rgba(27,94,123,.22);
}
.step:nth-child(2) .step-num { border-color: var(--accent-deep); color: var(--accent-deep); box-shadow: 0 4px 12px -2px rgba(45,163,160,.28); }
.step h3 { margin-bottom: 8px; }
.step p { color: var(--ink-soft); font-size: 14.5px; margin: 0; }

/* ---------- FEATURE / MODULE GRID ---------- */
.module {
  margin-bottom: 56px;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--line);
}
.module:last-child { border-bottom: 0; padding-bottom: 0; margin-bottom: 0; }
.module-head {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 28px;
  max-width: 760px;
}
.module-icon {
  flex-shrink: 0;
  width: 48px; height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary-600), var(--primary-700));
  color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 6px 14px -4px rgba(27,94,123,.4);
}
.module-eyebrow {
  color: var(--accent-deep);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.module-title {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--primary-900);
  margin: 0;
  line-height: 1.2;
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color .2s ease, transform .2s ease;
}
.feature:hover {
  border-color: var(--primary-100);
  transform: translateY(-2px);
}
.feature-icon {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: var(--primary-50);
  color: var(--primary-700);
  display: grid; place-items: center;
  margin-bottom: 18px;
}
.feature p {
  color: var(--ink-soft);
  margin: 0;
  font-size: 14.5px;
  line-height: 1.6;
}

/* ---------- SECURITY ---------- */
.security {
  background: var(--bg-deep);
  color: #DDE7EB;
  padding: 80px 0;
  position: relative;
  overflow: hidden;
}
.security::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 50%, rgba(91,192,190,.08), transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(27,94,123,.4), transparent 60%);
  pointer-events: none;
}
.security .wrap { position: relative; z-index: 1; }
.security h2 { color: #fff; }
.security .section-sub { color: #B6C7CE; }
.security .section-eyebrow { color: var(--accent); }
.sec-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 48px;
}
.sec-card {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius);
  padding: 22px;
}
.sec-card .ico {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: rgba(91,192,190,.15);
  color: var(--accent);
  display: grid; place-items: center;
  margin-bottom: 14px;
}
.sec-card h4 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
}
.sec-card p {
  margin: 0;
  font-size: 13.5px;
  color: #93A8B0;
  line-height: 1.55;
}

/* ---------- FAQ ---------- */
.faq-list {
  max-width: 760px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 0;
  font-weight: 600;
  font-size: 16.5px;
  color: var(--primary-900);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 24px;
  color: var(--muted);
  font-weight: 400;
  transition: transform .2s ease;
  line-height: 1;
}
.faq-item[open] summary::after { content: '–'; }
.faq-answer {
  padding: 0 0 22px;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.6;
  max-width: 640px;
}

/* ---------- BETA BADGE ---------- */
.beta-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 12px;
  background: rgba(91,192,190,.12);
  border: 1px solid rgba(45,163,160,.32);
  border-radius: 100px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--accent-deep);
  margin-bottom: 22px;
  letter-spacing: 0.01em;
}
.beta-pulse {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent-deep);
  box-shadow: 0 0 0 0 rgba(45,163,160,.6);
  animation: betaPulse 2s ease-out infinite;
}
@keyframes betaPulse {
  0%   { box-shadow: 0 0 0 0 rgba(45,163,160,.55); }
  70%  { box-shadow: 0 0 0 10px rgba(45,163,160,0); }
  100% { box-shadow: 0 0 0 0 rgba(45,163,160,0); }
}

/* ---------- FINAL CTA ---------- */
.final-cta {
  padding: 100px 0;
  background:
    radial-gradient(ellipse at 70% 0%, rgba(91,192,190,.18), transparent 60%),
    linear-gradient(180deg, #fff 0%, #FBFAF7 100%);
  text-align: center;
}
.final-cta-card {
  max-width: 720px;
  margin: 0 auto;
  padding: 56px 48px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
}
.final-cta h2 { margin-bottom: 14px; }
.final-cta p {
  color: var(--ink-soft);
  font-size: 17px;
  margin: 0 0 32px;
}
.final-cta .micro-row {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin-top: 28px;
  flex-wrap: wrap;
}

/* ---------- FOOTER ---------- */
footer {
  padding: 40px 0 32px;
  border-top: 1px solid var(--line);
  background: #fff;
}
.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--muted);
  font-size: 13px;
}
.footer-row .footer-links {
  display: flex; gap: 22px; flex-wrap: wrap;
}
.footer-row .footer-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  transition: color .15s ease;
}
.footer-row .footer-links a:hover { color: var(--primary-700); }
.footer-row .brand-name { font-size: 14px; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1080px) {
  .hero-grid, .showcase { grid-template-columns: 1fr; gap: 56px; }
  .hero-grid > div:first-child { max-width: 720px; }
}
@media (max-width: 920px) {
  .feature-grid, .sec-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; gap: 36px; }
  .steps::before { display: none; }
  .nav-links a:not(.btn) { display: none; }
}
@media (max-width: 880px) {
  .problem-bleed { padding: 80px 0 90px; }
  .problem-headline { margin-bottom: 48px; }
  .problem-list { grid-template-columns: 1fr; }
  .problem-row { border-right: none; border-bottom: 1px solid rgba(255,255,255,.08); padding: 28px 0 !important; }
  .problem-row:last-child { border-bottom: none; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 20px; }
  .section { padding: 64px 0; }
  .feature-grid, .sec-grid { grid-template-columns: 1fr; }
  .final-cta-card { padding: 40px 24px; }
  h1 { font-size: 38px; }
}
