/* ============================================================================
   Revlytics — site styles.
   Aesthetic: refined fintech-trust. Deep forest green (from the app icon),
   warm gold accent (the icon's "sun"), cream text. Self-hosted fonts, no
   third-party requests — consistent with the product's no-tracking promise.
   ========================================================================== */

/* ---- Self-hosted fonts ---------------------------------------------------- */
@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("/fonts/fraunces-600.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-500.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-700.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

/* ---- Tokens --------------------------------------------------------------- */
:root {
  --bg: #0c120c;
  --forest-deep: #16231a;
  --forest: #243a26;
  --moss: #7d9a59;
  --gold: #e3ad44;
  --gold-soft: #f0c970;
  --cream: #f3f1e6;
  --text: #eef2e7;
  --text-dim: #9fb09f;
  --text-faint: #6f7e6f;
  --border: #243024;
  --border-soft: #1b251c;

  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, sans-serif;

  --maxw: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Atmosphere: gradient mesh + grain overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1100px 600px at 78% -8%, rgba(125, 154, 89, 0.22), transparent 60%),
    radial-gradient(900px 520px at 8% 12%, rgba(36, 58, 38, 0.55), transparent 62%),
    radial-gradient(700px 500px at 50% 108%, rgba(227, 173, 68, 0.08), transparent 60%);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-soft); }

.shell { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---- Nav ------------------------------------------------------------------ */
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  max-width: var(--maxw);
  margin: 0 auto;
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: 0 4px 14px rgba(0,0,0,0.4); }
.brand span {
  font-family: var(--display);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: -0.3px;
  color: var(--cream);
}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { color: var(--text-dim); font-size: 15px; font-weight: 500; }
.nav-links a:hover { color: var(--cream); }

/* ---- Hero ----------------------------------------------------------------- */
.hero {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: center;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 56px 24px 40px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--moss);
  border: 1px solid var(--border);
  background: rgba(125, 154, 89, 0.06);
  padding: 7px 14px;
  border-radius: 999px;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }

.hero h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(40px, 6.4vw, 70px);
  line-height: 1.02;
  letter-spacing: -1.5px;
  margin: 22px 0 0;
  color: var(--cream);
}
.hero h1 em {
  font-style: italic;
  font-weight: 400;
  color: var(--gold);
}
.hero .lede {
  color: var(--text-dim);
  font-size: 19px;
  max-width: 520px;
  margin: 22px 0 0;
}
.hero-actions { display: flex; align-items: center; gap: 18px; margin-top: 32px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 16px;
  padding: 14px 24px;
  border-radius: 999px;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.btn-primary {
  background: linear-gradient(135deg, var(--gold), #c98f2e);
  color: #1a1206;
  box-shadow: 0 10px 30px rgba(227, 173, 68, 0.25);
}
.btn-primary:hover { transform: translateY(-2px); color: #1a1206; box-shadow: 0 16px 40px rgba(227, 173, 68, 0.34); }
.btn-ghost { color: var(--text-dim); }
.btn-ghost:hover { color: var(--cream); }

/* Apple "Download on the App Store" badge */
.appstore {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  padding: 10px 18px 10px 16px;
  border-radius: 13px;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #fff;
  transition: transform 0.25s var(--ease), border-color 0.25s var(--ease);
}
.appstore:hover { transform: translateY(-2px); color: #fff; border-color: rgba(255, 255, 255, 0.4); }
.appstore .apple { width: 22px; height: 24px; }
.appstore .as-text { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.appstore .as-text small { font-size: 11px; font-weight: 400; letter-spacing: 0.2px; opacity: 0.92; }
.appstore .as-text strong { font-size: 19px; font-weight: 600; letter-spacing: -0.2px; }

/* ---- Phone mockup (CSS facsimile; swap .screen content for a screenshot) -- */
.phone-stage { display: flex; justify-content: center; perspective: 1400px; }
.phone {
  position: relative;
  width: 290px;
  aspect-ratio: 9 / 19.3;
  border-radius: 46px;
  padding: 11px;
  background: linear-gradient(160deg, #2a3329, #11160f);
  box-shadow:
    0 40px 80px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(125, 154, 89, 0.15),
    inset 0 1px 1px rgba(255, 255, 255, 0.06);
  animation: float 7s ease-in-out infinite;
}
.phone .notch {
  position: absolute;
  top: 20px; left: 50%; transform: translateX(-50%);
  width: 96px; height: 26px; border-radius: 14px;
  background: #0a0d08; z-index: 3;
}
.screen {
  height: 100%;
  border-radius: 36px;
  background: radial-gradient(120% 80% at 50% 0%, #16201a, #0d130d);
  overflow: hidden;
  padding: 38px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.s-earn {
  border-radius: 20px;
  padding: 16px;
  background: linear-gradient(140deg, #3a5a39, #6f8a4f);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}
.s-earn .lbl { font-size: 9px; letter-spacing: 1.2px; color: rgba(255,255,255,0.75); font-weight: 700; }
.s-earn .amt { font-family: var(--display); font-weight: 600; font-size: 30px; color: #fff; margin-top: 4px; letter-spacing: -1px; }
.s-earn .pill {
  display: inline-flex; align-items: center; gap: 4px;
  margin-top: 8px; padding: 3px 9px; border-radius: 999px;
  background: rgba(255,255,255,0.18); color: #fff; font-size: 11px; font-weight: 700;
}
.s-chart { display: flex; align-items: flex-end; gap: 7px; height: 92px; padding: 12px; border-radius: 16px; background: #131b13; border: 1px solid #1f2a1f; }
.s-chart i { flex: 1; border-radius: 5px 5px 2px 2px; background: linear-gradient(180deg, #eef0e3, #b9c4a4); opacity: 0.92; }
.s-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: #131b13; border: 1px solid #1f2a1f; }
.s-row .ic { width: 22px; height: 22px; border-radius: 7px; background: rgba(227,173,68,0.16); }
.s-row .ln { flex: 1; height: 8px; border-radius: 4px; background: #26331f; }
.s-row .vl { width: 38px; height: 11px; border-radius: 4px; background: #2c3a24; }

/* ---- Section scaffolding -------------------------------------------------- */
section { position: relative; }
.section-pad { padding: 72px 24px; max-width: var(--maxw); margin: 0 auto; }
.kicker {
  font-size: 13px; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase;
  color: var(--gold);
}
.h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.08;
  letter-spacing: -0.8px;
  color: var(--cream);
  margin: 12px 0 0;
}

/* ---- Trust manifesto (the centerpiece) ------------------------------------ */
.manifesto {
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
  background:
    radial-gradient(700px 300px at 50% 0%, rgba(227,173,68,0.06), transparent 70%);
}
.manifesto .inner { max-width: var(--maxw); margin: 0 auto; padding: 84px 24px; text-align: center; }
.shield {
  width: 58px; height: 58px; margin: 0 auto 22px;
  display: grid; place-items: center;
  border-radius: 16px;
  background: rgba(227,173,68,0.1);
  border: 1px solid rgba(227,173,68,0.3);
  color: var(--gold);
}
.shield svg { width: 30px; height: 30px; }
.manifesto h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(34px, 5.5vw, 60px);
  letter-spacing: -1.4px;
  line-height: 1.02;
  margin: 0;
  color: var(--cream);
}
.manifesto h2 em { font-style: italic; font-weight: 400; color: var(--gold); }
.manifesto p { color: var(--text-dim); font-size: 19px; max-width: 560px; margin: 18px auto 0; }
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 44px;
}
.pillar {
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 22px;
  background: rgba(22, 35, 26, 0.4);
}
.pillar .x {
  display: inline-grid; place-items: center;
  width: 32px; height: 32px; border-radius: 9px;
  background: rgba(125,154,89,0.14); color: var(--moss);
  margin-bottom: 14px;
}
.pillar h3 { font-size: 17px; margin: 0 0 6px; color: var(--cream); font-weight: 700; }
.pillar p { font-size: 14.5px; color: var(--text-dim); margin: 0; }

/* ---- Features ------------------------------------------------------------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
  margin-top: 40px;
}
.f-card {
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 26px;
  background: linear-gradient(180deg, rgba(36,58,38,0.28), rgba(12,18,12,0.28));
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease);
}
.f-card:hover { transform: translateY(-4px); border-color: rgba(125,154,89,0.4); }
.f-card .glyph {
  font-family: var(--display);
  font-size: 26px;
  color: var(--gold);
  line-height: 1;
}
.f-card h3 { font-size: 18px; margin: 16px 0 8px; color: var(--cream); }
.f-card p { font-size: 15px; color: var(--text-dim); margin: 0; }

/* ---- How it works --------------------------------------------------------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 40px; }
.step { position: relative; padding-top: 18px; border-top: 2px solid var(--border); }
.step .n {
  font-family: var(--display); font-size: 15px; font-weight: 600;
  color: var(--gold); letter-spacing: 1px;
}
.step h3 { font-size: 19px; margin: 10px 0 8px; color: var(--cream); }
.step p { font-size: 15px; color: var(--text-dim); margin: 0; }

/* ---- Footer --------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--border-soft);
  margin-top: 24px;
  padding: 40px 24px;
}
.footer .inner {
  max-width: var(--maxw); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
}
.footer .brand span { font-size: 18px; }
.footer-links a { color: var(--text-dim); font-size: 15px; margin-left: 22px; }
.footer-links a:first-child { margin-left: 0; }
.footer-links a:hover { color: var(--cream); }
.footer .copy { width: 100%; color: var(--text-faint); font-size: 13.5px; text-align: center; margin-top: 8px; }

/* ---- Legal / doc pages ---------------------------------------------------- */
.doc { max-width: 760px; margin: 0 auto; padding: 40px 24px 80px; }
.doc h1 {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(32px, 5vw, 48px); letter-spacing: -1px;
  color: var(--cream); margin: 0 0 6px;
}
.doc .updated { color: var(--text-faint); font-size: 14px; margin: 0 0 36px; }
.doc h2 {
  font-family: var(--display); font-weight: 600;
  font-size: 23px; color: var(--cream); margin: 40px 0 12px;
}
.doc p, .doc li { color: #c6d2c4; }
.doc code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.88em; background: rgba(125,154,89,0.12);
  padding: 2px 6px; border-radius: 6px; color: var(--gold-soft);
}
.doc ul { padding-left: 22px; }
.doc li { margin: 7px 0; }
.doc strong { color: var(--cream); }
.callout {
  background: rgba(227,173,68,0.06);
  border: 1px solid rgba(227,173,68,0.22);
  border-left: 3px solid var(--gold);
  border-radius: 14px;
  padding: 18px 20px;
  margin: 22px 0;
}
.callout p { margin: 0; color: #d7e0d4; }

/* ---- Entrance animations -------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(22px); animation: rise 0.9s var(--ease) forwards; }
.d1 { animation-delay: 0.05s; }
.d2 { animation-delay: 0.15s; }
.d3 { animation-delay: 0.25s; }
.d4 { animation-delay: 0.35s; }
.d5 { animation-delay: 0.45s; }

@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }

@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none; opacity: 1; transform: none; }
  .phone { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---- Responsive ----------------------------------------------------------- */
@media (max-width: 880px) {
  .hero { grid-template-columns: 1fr; padding-top: 36px; gap: 48px; }
  .hero .phone-stage { order: 2; }
  .pillars { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .nav-links { gap: 18px; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .phone { width: 248px; }
}
