/* ============================================================================
   Meterline — marketing + support site
   Visual system: "Aurora" (matches the app). Reference-locked to Reflect Notes
   (midnight-violet, aurora glows, inset-lit glassy cards, violet-only accent),
   with Superwhisper (app-download hero), FlutterFlow (Urbanist display), and
   Obsidian (1px inset-glow card edge). Palette = Meterline's real app tokens.
   ========================================================================== */

/* ----- Fonts ----- */
@import url('https://fonts.googleapis.com/css2?family=Urbanist:wght@500;600;700;800&family=Inter:wght@400;500;600&display=swap');

/* ----- Tokens ----- */
:root {
  /* surfaces */
  --bg: #0a0612;
  --bg-soft: #0d0820;
  --bg-elev: #140c28;
  --card: rgba(255, 255, 255, 0.035);
  --card-2: rgba(255, 255, 255, 0.055);
  --hair: rgba(255, 255, 255, 0.09);
  --hair-strong: rgba(255, 255, 255, 0.14);

  /* text */
  --ink: #ffffff;
  --ink-soft: #d9d2ec;
  --muted: #9a92b4;
  --faint: #6c6588;

  /* brand */
  --accent: #b388ff;          /* links, highlights — the app accent */
  --accent-bright: #c4a6ff;
  --g1: #c4a6ff;
  --g2: #8a63f4;
  --g3: #5b2bd6;
  --deep: #28027c;
  --violet-600: #6d3fe0;
  --on-accent: #1a1330;       /* near-black text on the bright gradient */
  --success: #46d68b;

  --grad: linear-gradient(135deg, var(--g1) 0%, var(--g2) 52%, var(--g3) 100%);
  --grad-text: linear-gradient(120deg, #e6d6ff 0%, #b388ff 55%, #8a63f4 100%);

  /* shape */
  --r-card: 20px;
  --r-sm: 14px;
  --r-pill: 999px;

  /* effects: inset glow, never heavy drop shadow */
  --edge: inset 0 0 0 1px var(--hair);
  --edge-glow: inset 0 0 0 1px var(--hair), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  --cta-glow: 0 14px 38px -12px rgba(138, 99, 244, 0.65), inset 0 0 0 1px rgba(255, 255, 255, 0.12);

  --container: 1120px;
}

/* ----- Reset / base ----- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink-soft);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--accent-bright); }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 {
  font-family: 'Urbanist', system-ui, sans-serif;
  color: var(--ink);
  margin: 0;
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
p { margin: 0; }
::selection { background: rgba(179, 136, 255, 0.32); color: #fff; }

/* ----- Layout ----- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 24px; }
.section { padding-block: clamp(64px, 10vw, 120px); position: relative; }
.section--tight { padding-block: clamp(48px, 7vw, 84px); }
.eyebrow {
  font-family: 'Inter', sans-serif;
  font-weight: 600; font-size: 13px;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 16px;
}
.lead { font-size: clamp(17px, 2.2vw, 20px); color: var(--muted); max-width: 60ch; }
.center { text-align: center; margin-inline: auto; }
.gradient-text {
  background: var(--grad-text);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ----- Aurora background glows ----- */
.aurora { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.aurora::before, .aurora::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.5;
}
.aurora::before {
  width: 720px; height: 720px; top: -260px; left: 50%; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(138, 99, 244, 0.55), rgba(91, 43, 214, 0) 62%);
}
.aurora::after {
  width: 560px; height: 560px; top: 120px; right: -160px;
  background: radial-gradient(circle, rgba(196, 166, 255, 0.28), rgba(196, 166, 255, 0) 60%);
}
.section > .container { position: relative; z-index: 1; }

/* ----- Top nav ----- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 6, 18, 0.72);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.nav__inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-family: 'Urbanist', sans-serif; font-weight: 700; font-size: 19px; color: #fff; letter-spacing: -0.01em; }
.brand:hover { color: #fff; }
.brand__mark { width: 30px; height: 30px; flex: none; }
.nav__links { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.nav__link { color: var(--ink-soft); font-size: 15px; font-weight: 500; padding: 8px 12px; border-radius: 10px; }
.nav__link:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }
.nav__cta { margin-left: 6px; }
.nav__toggle { display: none; }

/* ----- Buttons ----- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: 'Inter', sans-serif; font-weight: 600; font-size: 15.5px;
  padding: 12px 22px; border-radius: var(--r-pill); border: 0; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease; white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--grad); color: var(--on-accent); box-shadow: var(--cta-glow); }
.btn--primary:hover { color: var(--on-accent); box-shadow: 0 18px 46px -12px rgba(138, 99, 244, 0.8), inset 0 0 0 1px rgba(255, 255, 255, 0.18); }
.btn--ghost { background: rgba(255, 255, 255, 0.04); color: #fff; box-shadow: var(--edge); }
.btn--ghost:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.btn--lg { padding: 15px 28px; font-size: 16.5px; }
.btn--block { width: 100%; }

/* App Store pill */
.appstore { display: inline-flex; align-items: center; gap: 11px; padding: 12px 20px 12px 18px; border-radius: var(--r-pill); background: #fff; color: #0a0612; box-shadow: var(--cta-glow); font-family: 'Inter', sans-serif; }
.appstore:hover { color: #0a0612; transform: translateY(-1px); }
.appstore svg { width: 24px; height: 24px; }
.appstore small { display: block; font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.7; line-height: 1; margin-bottom: 2px; }
.appstore b { font-family: 'Urbanist', sans-serif; font-weight: 700; font-size: 17px; line-height: 1; }
.soon-tag { font-size: 12px; color: var(--faint); margin-top: 12px; letter-spacing: 0.04em; }

/* ----- Hero ----- */
.hero { padding-top: clamp(56px, 8vw, 96px); padding-bottom: clamp(56px, 8vw, 104px); }
.hero__grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.hero h1 { font-size: clamp(40px, 6.4vw, 70px); font-weight: 700; letter-spacing: -0.035em; }
.hero .lead { margin-top: 22px; font-size: clamp(17px, 2.2vw, 20px); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; align-items: center; }
.hero__badges { display: flex; gap: 22px; margin-top: 30px; flex-wrap: wrap; }
.hero__badge { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--muted); }
.hero__badge svg { width: 18px; height: 18px; color: var(--accent); }

/* ----- Phone mockup (faithful meter screen, code-native) ----- */
.phone-wrap { display: flex; justify-content: center; position: relative; }
.phone {
  width: 300px; max-width: 78vw; aspect-ratio: 300 / 620;
  border-radius: 46px; padding: 12px;
  background: linear-gradient(160deg, #2a2140, #120b22);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14), inset 0 0 0 7px #0b0716, 0 40px 80px -30px rgba(91, 43, 214, 0.7);
  position: relative; z-index: 1;
}
.phone__screen {
  height: 100%; border-radius: 36px; overflow: hidden; position: relative;
  background: radial-gradient(120% 80% at 50% -10%, #1c1140 0%, #0a0612 60%);
  display: flex; flex-direction: column; align-items: center;
  padding: 30px 22px 26px;
}
.phone__notch { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: 92px; height: 22px; background: #0b0716; border-radius: 999px; z-index: 3; }
.m-status { margin-top: 16px; display: inline-flex; align-items: center; gap: 7px; padding: 7px 14px; border-radius: 999px; background: rgba(70, 214, 139, 0.14); color: var(--success); font-size: 12.5px; font-weight: 600; box-shadow: inset 0 0 0 1px rgba(70, 214, 139, 0.3); }
.m-status .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 10px var(--success); }
.m-ring { margin-top: 26px; width: 196px; height: 196px; border-radius: 50%; display: grid; place-items: center; position: relative; background: conic-gradient(from -90deg, var(--g2) 0deg, var(--g1) 120deg, rgba(255,255,255,0.06) 120deg 360deg); }
.m-ring::before { content: ""; position: absolute; inset: 11px; border-radius: 50%; background: radial-gradient(120% 120% at 50% 0%, #160e30, #0a0612); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08); }
.m-ring__inner { position: relative; text-align: center; }
.m-ring__eyebrow { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--faint); }
.m-fare { font-family: 'Urbanist', sans-serif; font-weight: 700; font-size: 42px; color: #fff; letter-spacing: -0.02em; line-height: 1.1; margin-top: 2px; font-variant-numeric: tabular-nums; }
.m-tiles { margin-top: 22px; width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.m-tile { background: rgba(255, 255, 255, 0.04); border-radius: 16px; padding: 13px 14px; box-shadow: var(--edge); }
.m-tile span { display: block; font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.m-tile b { font-family: 'Urbanist', sans-serif; font-weight: 600; font-size: 19px; color: #fff; font-variant-numeric: tabular-nums; }
.m-controls { margin-top: auto; padding-top: 22px; display: flex; gap: 16px; }
.m-btn { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; box-shadow: var(--edge); color: #fff; }
.m-btn--stop { background: rgba(248, 113, 113, 0.16); color: #f87171; box-shadow: inset 0 0 0 1px rgba(248, 113, 113, 0.32); }
.m-btn--go { background: var(--grad); color: var(--on-accent); box-shadow: var(--cta-glow); }
.m-btn svg { width: 22px; height: 22px; }

/* ----- Cards / feature grid ----- */
.grid { display: grid; gap: 20px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--card); border-radius: var(--r-card); padding: 28px;
  box-shadow: var(--edge-glow); position: relative; overflow: hidden;
  transition: box-shadow .25s ease, transform .25s ease, background .25s ease;
}
.card:hover { background: var(--card-2); box-shadow: inset 0 0 0 1px var(--hair-strong), 0 24px 50px -28px rgba(138, 99, 244, 0.5); transform: translateY(-3px); }
.card__icon { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: rgba(179, 136, 255, 0.14); color: var(--accent-bright); box-shadow: inset 0 0 0 1px rgba(179, 136, 255, 0.22); margin-bottom: 18px; }
.card__icon svg { width: 23px; height: 23px; }
.card h3 { font-size: 20px; font-weight: 600; margin-bottom: 9px; }
.card p { font-size: 15.5px; color: var(--muted); line-height: 1.6; }

/* feature: alternating rows */
.feature-row { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.feature-row + .feature-row { margin-top: clamp(48px, 7vw, 88px); }
.feature-row--flip .feature-row__media { order: -1; }
.feature-row h2 { font-size: clamp(26px, 3.4vw, 36px); font-weight: 700; }
.feature-row p { margin-top: 16px; color: var(--muted); }
.media-card { background: var(--card); border-radius: var(--r-card); box-shadow: var(--edge-glow); padding: 24px; min-height: 240px; display: grid; place-items: center; }

/* ----- Stat band ----- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat { text-align: center; }
.stat b { display: block; font-family: 'Urbanist', sans-serif; font-weight: 700; font-size: clamp(30px, 4vw, 44px); color: #fff; letter-spacing: -0.02em; }
.stat span { font-size: 14px; color: var(--muted); }

/* ----- Pricing card ----- */
.price-card { max-width: 460px; margin-inline: auto; text-align: center; background: var(--card); border-radius: 24px; box-shadow: var(--edge-glow); padding: 40px 34px; position: relative; }
.price-card__halo { position: absolute; inset: -1px; border-radius: 24px; padding: 1px; background: linear-gradient(135deg, rgba(196,166,255,0.5), rgba(138,99,244,0.1) 60%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.price { font-family: 'Urbanist', sans-serif; font-weight: 800; font-size: 52px; color: #fff; letter-spacing: -0.03em; }
.price small { font-size: 17px; color: var(--muted); font-weight: 500; }
.price-list { list-style: none; padding: 0; margin: 24px 0 28px; text-align: left; display: grid; gap: 12px; }
.price-list li { display: flex; gap: 11px; align-items: flex-start; font-size: 15.5px; color: var(--ink-soft); }
.price-list svg { width: 19px; height: 19px; color: var(--accent-bright); flex: none; margin-top: 2px; }

/* ----- CTA band ----- */
.cta-band { text-align: center; border-radius: 28px; padding: clamp(40px, 6vw, 72px) 28px; background: radial-gradient(120% 140% at 50% 0%, rgba(138, 99, 244, 0.28), rgba(10, 6, 18, 0) 70%), var(--bg-soft); box-shadow: var(--edge-glow); position: relative; overflow: hidden; }
.cta-band h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 700; }

/* ----- Prose (legal pages) ----- */
.page-head { padding-block: clamp(56px, 8vw, 96px) clamp(20px, 3vw, 36px); text-align: center; }
.page-head h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 700; }
.page-head p { margin-top: 14px; color: var(--muted); }
.prose { max-width: 760px; margin-inline: auto; padding-bottom: clamp(64px, 9vw, 110px); }
.prose h2 { font-size: 24px; font-weight: 700; margin-top: 48px; margin-bottom: 14px; scroll-margin-top: 90px; }
.prose h3 { font-size: 18px; font-weight: 600; color: var(--ink); margin-top: 28px; margin-bottom: 8px; }
.prose p { margin-bottom: 16px; color: var(--ink-soft); }
.prose ul { margin: 0 0 18px; padding-left: 22px; color: var(--ink-soft); }
.prose li { margin-bottom: 9px; }
.prose a { text-decoration: underline; text-underline-offset: 2px; }
.prose strong { color: #fff; }
.prose .muted-note { color: var(--muted); font-size: 15px; }
.callout { background: var(--card); border-radius: var(--r-sm); padding: 18px 20px; box-shadow: var(--edge); margin: 22px 0; }
.callout--warn { box-shadow: inset 0 0 0 1px rgba(250, 204, 21, 0.28); background: rgba(250, 204, 21, 0.05); }
.toc { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 26px; }
.toc a { font-size: 13.5px; padding: 7px 14px; border-radius: 999px; background: rgba(255,255,255,0.04); color: var(--ink-soft); box-shadow: var(--edge); text-decoration: none; }
.toc a:hover { background: rgba(255,255,255,0.08); color: #fff; }

/* ----- FAQ accordion (native details/summary) ----- */
.faq { max-width: 780px; margin-inline: auto; }
.faq__item { border-radius: var(--r-sm); background: var(--card); box-shadow: var(--edge); margin-bottom: 12px; overflow: hidden; transition: box-shadow .2s ease; }
.faq__item[open] { box-shadow: inset 0 0 0 1px var(--hair-strong); }
.faq__q { list-style: none; cursor: pointer; padding: 20px 22px; display: flex; align-items: center; justify-content: space-between; gap: 16px; font-family: 'Urbanist', sans-serif; font-weight: 600; font-size: 17px; color: #fff; }
.faq__q::-webkit-details-marker { display: none; }
.faq__q .chev { width: 20px; height: 20px; flex: none; color: var(--accent); transition: transform .25s ease; }
.faq__item[open] .chev { transform: rotate(45deg); }
.faq__a { padding: 0 22px 20px; color: var(--muted); font-size: 15.5px; line-height: 1.65; }
.faq__a a { color: var(--accent); }

/* ----- Forms (contact) ----- */
.form-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(28px, 4vw, 56px); align-items: start; }
.form-card { background: var(--card); border-radius: var(--r-card); box-shadow: var(--edge-glow); padding: clamp(26px, 3vw, 38px); }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); margin-bottom: 8px; letter-spacing: 0.01em; }
.field input, .field select, .field textarea {
  width: 100%; font-family: 'Inter', sans-serif; font-size: 15.5px; color: #fff;
  background: rgba(255, 255, 255, 0.035); border: 0; border-radius: var(--r-sm);
  padding: 13px 15px; box-shadow: var(--edge); transition: box-shadow .15s ease, background .15s ease;
}
.field textarea { min-height: 148px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px var(--accent); }
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%239a92b4' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
/* The native dropdown popup uses the OS background, so set option colors explicitly
   (otherwise white option text renders on a white popup and is unreadable). */
.field select option { background: #140c28; color: #ffffff; }
.hp { position: absolute; left: -9999px; }
.contact-aside h3 { font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.contact-aside p { color: var(--muted); font-size: 15.5px; margin-bottom: 22px; }
.contact-row { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-top: 1px solid rgba(255,255,255,0.06); }
.contact-row svg { width: 22px; height: 22px; color: var(--accent); flex: none; margin-top: 2px; }
.contact-row b { display: block; color: #fff; font-family: 'Urbanist', sans-serif; font-weight: 600; }
.contact-row span { font-size: 14.5px; color: var(--muted); }

/* success page */
.success-icon { width: 76px; height: 76px; margin: 0 auto 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(70, 214, 139, 0.14); color: var(--success); box-shadow: inset 0 0 0 1px rgba(70, 214, 139, 0.3); }
.success-icon svg { width: 36px; height: 36px; }

/* ----- Footer ----- */
.footer { border-top: 1px solid rgba(255, 255, 255, 0.06); padding-block: 56px 40px; margin-top: 24px; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 32px; }
.footer__brand p { color: var(--muted); font-size: 14.5px; margin-top: 14px; max-width: 30ch; }
.footer__col h4 { font-family: 'Inter', sans-serif; font-size: 12.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.12em; color: var(--faint); margin-bottom: 14px; }
.footer__col a { display: block; color: var(--ink-soft); font-size: 14.5px; padding: 5px 0; }
.footer__col a:hover { color: #fff; }
.footer__bottom { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.06); color: var(--faint); font-size: 13.5px; }

/* ----- Responsive ----- */
@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; text-align: center; }
  .hero .lead { margin-inline: auto; }
  .hero__cta, .hero__badges { justify-content: center; }
  .phone-wrap { order: -1; margin-bottom: 12px; }
  .grid--3 { grid-template-columns: 1fr 1fr; }
  .feature-row { grid-template-columns: 1fr; }
  .feature-row--flip .feature-row__media { order: 0; }
  .stats { grid-template-columns: 1fr 1fr; gap: 28px; }
  .form-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .nav__links { display: none; }
  .nav__links.open { display: flex; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 4px; padding: 14px 20px 20px; background: rgba(10,6,18,0.98); border-bottom: 1px solid rgba(255,255,255,0.08); }
  .nav__links.open .btn { width: 100%; margin: 6px 0 0; }
  .nav__toggle { display: inline-grid; place-items: center; margin-left: auto; width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,0.05); box-shadow: var(--edge); color: #fff; border: 0; cursor: pointer; }
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

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