/* ============================================================
   Flare — product website
   Design system mirrors the app's "Indigo" minimalist redesign.
   ============================================================ */

:root {
  /* Brand + text */
  --accent: #4C5BD4;
  --accent-12: rgba(76, 91, 212, 0.12);
  --accent-10: rgba(76, 91, 212, 0.10);
  --accent-07: rgba(76, 91, 212, 0.07);
  --accent-26: rgba(76, 91, 212, 0.26);
  --ink: #15161C;
  --text-2: #5D6070;
  --muted: #9A9DAD;
  --faint: #AEB1C2;

  /* Surfaces */
  --bg: #E4E6EE;
  --screen-gradient: linear-gradient(180deg, #FBFCFF 0%, #EDEFF8 100%);
  --surface: #FFFFFF;
  --surface-soft: #FBFCFF;
  --fill-subtle: #EEF0FA;
  --avatar-bg: #EBEEF8;
  --avatar-text: #545870;
  --input-bg: #F8F9FE;
  --seg-track: #F1F3FA;

  /* Borders */
  --border: #E2E4EF;
  --border-light: #E8EAF2;
  --border-lighter: #EBECF3;
  --idle-ring: #DDE0EC;

  /* Layout */
  --maxw: 1080px;
  --radius: 18px;
  --radius-sm: 14px;

  --shadow-card: 0 18px 44px -28px rgba(20, 25, 60, 0.45);
  --shadow-phone: 0 30px 70px -34px rgba(20, 25, 60, 0.5);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Manrope', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--screen-gradient);
  background-attachment: fixed;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { display: block; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- Wordmark ---------- */
.wordmark {
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--ink);
  line-height: 1;
  display: inline-flex;
  align-items: center;
}
.wordmark .dot { color: var(--accent); }

/* Official Flare logo (SVG wordmark) */
.logo-img { height: 26px; width: auto; display: block; }
.site-footer .logo-img { height: 22px; }
.phone .logo-img { height: 20px; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 252, 255, 0.82);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border-lighter);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  color: var(--text-2);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--accent); }
/* CTA button keeps its own colors despite the nav-link color rule */
.nav-links a.btn-primary { color: #fff; }
.nav-links a.btn-primary:hover { color: #fff; text-decoration: none; }

.nav-toggle { display: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  padding: 13px 22px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px -14px rgba(76, 91, 212, 0.7);
}
.btn-primary:hover {
  background: #4252c4;
  text-decoration: none;
  transform: translateY(-1px);
}
.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border);
}
.btn-ghost:hover {
  border-color: #C9CEE8;
  text-decoration: none;
}

/* ---------- Hero ---------- */
.hero {
  padding: 72px 0 40px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 16px;
}
.hero h1 {
  font-size: 52px;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -1.4px;
  margin: 0 0 18px;
}
.hero h1 .accent { color: var(--accent); }
.hero .lede {
  font-size: 18px;
  color: var(--text-2);
  margin: 0 0 28px;
  max-width: 30em;
}
.hero-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.hero-note {
  font-size: 13px;
  color: var(--muted);
  margin-top: 16px;
}

/* ---------- Phone frame (mirrors app) ---------- */
.phone-stage {
  display: flex;
  justify-content: center;
  perspective: 1600px;
}
.phone {
  position: relative;
  width: 320px;
  height: 660px;
  border-radius: 38px;
  overflow: hidden;
  background: var(--screen-gradient);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-phone);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}
.phone-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px 4px;
}
.phone-header .dots { display: flex; gap: 4px; }
.phone-header .dots span {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--faint);
}
.phone .wordmark { font-size: 21px; }

.phone-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 0 24px;
}
.phone-title-block { padding: 18px 0 0; }
.phone-eyebrow {
  font-size: 11px; font-weight: 700; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--muted);
}
.phone-title {
  font-size: 26px; font-weight: 700; letter-spacing: -0.7px;
  line-height: 1.1; margin-top: 8px;
}
.flare-center {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}
.flare-circle {
  position: relative;
  width: 178px; height: 178px;
  border-radius: 50%;
  display: grid; place-items: center;
  border: 1.5px solid var(--idle-ring);
  background: radial-gradient(circle at 50% 36%, #FFFFFF, #F2F4FB);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.7);
}
.flare-disc {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--fill-subtle);
  display: grid; place-items: center;
}
.tap-to-send { font-size: 13px; font-weight: 600; color: var(--muted); }
.phone-footer { padding: 0 0 22px; }
.phone-footer .cap {
  text-align: center; font-size: 12.5px; color: var(--muted); margin-bottom: 12px;
}
.option-row {
  width: 100%;
  display: flex; align-items: center; justify-content: space-between;
  border: 1px solid var(--border-light);
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 13px 15px;
  font-size: 13px;
  color: var(--text-2);
}
.option-row b { color: var(--ink); font-weight: 600; }

.phone-nav {
  display: flex; gap: 6px;
  padding: 8px 18px 20px;
  border-top: 1px solid var(--border-lighter);
  background: var(--surface-soft);
}
.phone-nav .nav-item {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 600;
  color: var(--muted);
}
.phone-nav .nav-item.active { color: var(--accent); }

/* "Who's free" mini list (used in second mockup) */
.friend-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}
.friend-row:last-child { border-bottom: none; }
.avatar {
  width: 40px; height: 40px; border-radius: 50%;
  flex-shrink: 0;
  display: grid; place-items: center;
  font-weight: 700; font-size: 14px;
  background: var(--avatar-bg); color: var(--avatar-text);
  position: relative;
}
.avatar .status {
  position: absolute; right: -1px; bottom: -1px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--accent); border: 2.5px solid var(--surface-soft);
}
.friend-meta { flex: 1; min-width: 0; }
.friend-meta .name { font-weight: 600; font-size: 14px; }
.friend-meta .note {
  font-size: 12.5px; color: var(--text-2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.friend-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.friend-right .time { font-size: 11px; font-weight: 600; color: var(--muted); }
.wave-btn {
  border: 1px solid var(--idle-ring);
  background: transparent;
  color: var(--accent);
  border-radius: 999px;
  padding: 5px 13px;
  font-size: 12px; font-weight: 600;
  font-family: inherit;
}

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-head {
  text-align: center;
  max-width: 36em;
  margin: 0 auto 44px;
}
.section-head h2 {
  font-size: 34px; font-weight: 800; letter-spacing: -0.8px;
  margin: 0 0 12px;
}
.section-head p { font-size: 17px; color: var(--text-2); margin: 0; }

/* Feature cards */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow-card);
}
.card .icon {
  width: 46px; height: 46px; border-radius: 13px;
  background: var(--accent-10);
  display: grid; place-items: center;
  margin-bottom: 16px;
}
.card h3 { font-size: 18px; font-weight: 700; letter-spacing: -0.3px; margin: 0 0 8px; }
.card p { font-size: 14.5px; color: var(--text-2); margin: 0; }

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  counter-reset: step;
}
.step {
  position: relative;
  padding: 26px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.step .num {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: grid; place-items: center;
  font-weight: 700; font-size: 15px;
  margin-bottom: 14px;
}
.step h3 { font-size: 17px; font-weight: 700; margin: 0 0 6px; }
.step p { font-size: 14.5px; color: var(--text-2); margin: 0; }

/* Split / showcase */
.split {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 56px;
  align-items: center;
}
.split.reverse .split-media { order: -1; }
.split h2 { font-size: 30px; font-weight: 800; letter-spacing: -0.7px; margin: 0 0 14px; }
.split p { font-size: 16.5px; color: var(--text-2); margin: 0 0 16px; }
.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li {
  display: flex; gap: 11px; align-items: flex-start;
  font-size: 15px; color: var(--ink);
  margin-bottom: 12px;
}
.checklist li .tick {
  flex-shrink: 0; margin-top: 2px;
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent-12);
  display: grid; place-items: center;
}

/* Pricing-ish banner */
.banner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 44px 40px;
  text-align: center;
  box-shadow: var(--shadow-card);
}
.banner h2 { font-size: 30px; font-weight: 800; letter-spacing: -0.7px; margin: 0 0 12px; }
.banner p { font-size: 16.5px; color: var(--text-2); margin: 0 auto 26px; max-width: 34em; }

/* ---------- Article (legal / about) ---------- */
.page-hero {
  padding: 64px 0 24px;
  text-align: center;
}
.page-hero h1 { font-size: 42px; font-weight: 800; letter-spacing: -1px; margin: 0 0 10px; }
.page-hero p { font-size: 16px; color: var(--muted); margin: 0; }

.article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
  padding: 48px 52px;
  margin: 24px auto 72px;
  max-width: 820px;
}
.article h2 {
  font-size: 22px; font-weight: 700; letter-spacing: -0.4px;
  margin: 34px 0 12px;
}
.article h2:first-child { margin-top: 0; }
.article h3 { font-size: 17px; font-weight: 700; margin: 22px 0 8px; }
.article p, .article li { font-size: 15.5px; color: var(--text-2); }
.article p { margin: 0 0 14px; }
.article ul { margin: 0 0 16px; padding-left: 22px; }
.article li { margin-bottom: 8px; }
.article strong { color: var(--ink); }
.article a { font-weight: 600; }
.article .muted-note {
  font-size: 13.5px; color: var(--muted);
  border-top: 1px solid var(--border-light);
  margin-top: 32px; padding-top: 18px;
}

/* About story blocks */
.story-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 8px;
}
.value-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow-card);
}
.value-card h3 { font-size: 18px; margin: 0 0 8px; font-weight: 700; letter-spacing: -0.3px; }
.value-card p { font-size: 14.5px; color: var(--text-2); margin: 0; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border-lighter);
  background: var(--surface-soft);
  padding: 40px 0;
  margin-top: 40px;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer-links a { color: var(--text-2); font-size: 14px; font-weight: 600; }
.footer-links a:hover { color: var(--ink); }
.footer-copy { font-size: 13px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { font-size: 42px; }
  .split, .split.reverse { grid-template-columns: 1fr; gap: 36px; }
  .split.reverse .split-media { order: 0; }
  .cards, .steps, .story-grid { grid-template-columns: 1fr; }
  .nav-links { gap: 18px; }
  .article { padding: 34px 24px; }
}

@media (max-width: 560px) {
  .hero h1 { font-size: 34px; letter-spacing: -1px; }
  .section-head h2 { font-size: 28px; }
  .nav-links a:not(.nav-cta) { display: none; }
  .container { padding: 0 20px; }
}

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