/* ─────────────────────────────────────────────
   Bulles — shared stylesheet
   Used by: index.php, terms.php, privacy.php
───────────────────────────────────────────── */

:root {
  /* Brand */
  --blue:    #007AFF;
  --green:   #34C759;
  --yellow:  #FFD60A;

  /* Surfaces */
  --surface: #FFFFFF;
  --cream:   #FAF7F2;   /* marketing page bg */
  --bg:      #F5F5F7;   /* legal pages bg */
  --border:  rgba(0,0,0,.08);

  /* Text */
  --ink:     #1A1A2E;   /* marketing headings / dark sections */
  --ink2:    #2C2C3E;
  --text:    #1C1C1E;   /* legal pages body text */
  --muted:   #6E6E73;

  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', system-ui, sans-serif;
  --radius: 20px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }


/* ══════════════════════════════════════════
   MARKETING PAGE  (index.php)
══════════════════════════════════════════ */

body {
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

/* ─── NAV (marketing) ─── */
nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250,247,242,.88);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1120px; margin: 0 auto;
  padding: 0 32px; height: 60px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo {
  font-size: 20px; font-weight: 800;
  color: var(--ink); text-decoration: none;
  letter-spacing: -.5px;
  display: flex; align-items: center; gap: 9px;
}
.logo-bubble {
  width: 30px; height: 30px;
  background: var(--blue);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px; font-weight: 900;
}
.nav-cta {
  background: var(--ink);
  color: #fff; border: none;
  border-radius: 980px;
  padding: 9px 22px;
  font-size: 14px; font-weight: 600;
  font-family: var(--font);
  text-decoration: none;
  transition: background .15s;
}
.nav-cta:hover { background: var(--ink2); color: #fff; }

/* ─── HERO ─── */
.hero {
  max-width: 1120px; margin: 0 auto;
  padding: 80px 32px 0;
}
.hero-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  margin-bottom: 72px;
}
@media (max-width: 820px) {
  .hero-top { grid-template-columns: 1fr; gap: 40px; }
  .hero-badge-wrap { display: none; }
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(0,122,255,.1); color: var(--blue);
  font-size: 12px; font-weight: 700; letter-spacing: .4px;
  text-transform: uppercase;
  padding: 5px 14px; border-radius: 980px;
  margin-bottom: 28px;
}
.hero-badge span { width: 6px; height: 6px; background: var(--blue); border-radius: 50%; }
h1 {
  font-size: clamp(38px, 5.5vw, 68px);
  font-weight: 900;
  letter-spacing: -2px;
  line-height: 1.0;
  margin-bottom: 24px;
  color: var(--ink);
}
h1 em {
  font-style: normal;
  color: var(--blue);
}
.hero-sub {
  font-size: 18px;
  line-height: 1.65;
  color: var(--muted);
  max-width: 440px;
  margin-bottom: 36px;
}
.hero-actions {
  display: flex; gap: 12px; flex-wrap: wrap;
}
.btn-primary {
  background: var(--blue); color: #fff;
  border: none; border-radius: 980px;
  padding: 15px 32px;
  font-size: 16px; font-weight: 700;
  font-family: var(--font);
  text-decoration: none;
  transition: opacity .15s, transform .15s;
  display: inline-block;
}
.btn-primary:hover { opacity: .87; color: #fff; transform: translateY(-1px); }
.btn-outline {
  background: transparent; color: var(--ink);
  border: 1.5px solid rgba(0,0,0,.2);
  border-radius: 980px;
  padding: 14px 28px;
  font-size: 16px; font-weight: 600;
  font-family: var(--font);
  text-decoration: none;
  transition: border-color .15s, transform .15s;
  display: inline-block;
}
.btn-outline:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-1px); }

/* ─── HERO: STAT CARDS ─── */
.hero-stats {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.stat-card {
  background: var(--surface);
  border-radius: 18px;
  padding: 22px 26px;
  box-shadow: 0 2px 12px rgba(0,0,0,.07);
  display: flex; align-items: center; gap: 18px;
}
.stat-card-icon {
  width: 48px; height: 48px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; flex-shrink: 0;
}
.stat-card-icon.blue   { background: rgba(0,122,255,.1); }
.stat-card-icon.green  { background: rgba(52,199,89,.1); }
.stat-card-icon.yellow { background: rgba(255,214,10,.15); }
.stat-card-text strong {
  display: block; font-size: 18px;
  font-weight: 800; letter-spacing: -.4px;
  color: var(--ink); margin-bottom: 2px;
}
.stat-card-text span {
  font-size: 13px; color: var(--muted);
}

/* ─── BOOKSHELF ─── */
.shelf-section {
  background: var(--ink);
  padding: 56px 0 0;
  overflow: hidden;
}
.shelf-label {
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
  margin-bottom: 40px;
}
.shelf-wrap {
  width: 100%;
  padding: 0;
}
.shelf {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  padding-bottom: 0;
}
.shelf-board {
  height: 14px;
  background: linear-gradient(to bottom, #5C3D1E 0%, #3D2810 100%);
  border-radius: 0;
  box-shadow: 0 -2px 8px rgba(0,0,0,.4), inset 0 2px 4px rgba(255,255,255,.08);
}
.spine {
  border-radius: 3px 3px 0 0;
  flex-shrink: 0;
  position: relative;
  box-shadow: inset -3px 0 6px rgba(0,0,0,.2), inset 1px 0 2px rgba(255,255,255,.1);
  transition: transform .25s cubic-bezier(.34,1.56,.64,1);
  cursor: default;
}
.spine:hover { transform: translateY(-12px); }
.spine-title {
  position: absolute;
  bottom: 37px; left: 50%;
  transform: translateX(-50%) rotate(-90deg);
  white-space: nowrap;
  font-size: 9px; font-weight: 700;
  letter-spacing: .3px;
  color: rgba(255,255,255,.7);
  text-transform: uppercase;
  pointer-events: none;
  width: 80px;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ─── PLATFORM STATS ─── */
.platform-stats {
  background: var(--ink2);
  padding: 48px 32px;
  text-align: center;
}
.platform-stats-inner {
  display: inline-flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
  justify-content: center;
}
.pstat {
  padding: 0 48px;
  text-align: center;
}
.pstat strong {
  display: block;
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 900;
  letter-spacing: -2px;
  color: #fff;
  line-height: 1;
  margin-bottom: 6px;
}
.pstat span {
  font-size: 14px;
  color: rgba(255,255,255,.4);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.pstat-sep {
  width: 1px;
  height: 48px;
  background: rgba(255,255,255,.1);
}
@media (max-width: 600px) {
  .pstat { padding: 20px 32px; }
  .pstat-sep { display: none; }
  .platform-stats-inner { gap: 0; }
}

/* ─── STATEMENT ─── */
.statement {
  background: var(--ink);
  padding: 80px 32px;
  text-align: center;
}
.statement blockquote {
  max-width: 780px; margin: 0 auto;
  font-size: clamp(26px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.2;
  color: #fff;
}
.statement blockquote em {
  font-style: normal;
  color: var(--yellow);
}
.statement p {
  margin-top: 20px;
  font-size: 15px;
  color: rgba(255,255,255,.45);
}

/* ─── FEATURES ─── */
.features {
  max-width: 1120px; margin: 0 auto;
  padding: 96px 32px;
}
.section-eyebrow {
  font-size: 13px; font-weight: 700;
  letter-spacing: .4px; text-transform: uppercase;
  color: var(--blue); margin-bottom: 16px;
}
.section-title {
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 900; letter-spacing: -1px;
  line-height: 1.1; margin-bottom: 14px;
}
.section-sub {
  font-size: 17px; color: var(--muted);
  line-height: 1.65; max-width: 500px;
  margin-bottom: 56px;
}

.feat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 20px;
}
@media (max-width: 700px) {
  .feat-grid { grid-template-columns: 1fr; }
}
.feat-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 36px;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
  transition: transform .2s, box-shadow .2s;
}
.feat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,.1);
}
.feat-card.wide {
  grid-column: 1 / -1;
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px;
  align-items: center;
}
@media (max-width: 700px) {
  .feat-card.wide { grid-template-columns: 1fr; }
}
.feat-icon {
  width: 54px; height: 54px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; margin-bottom: 20px;
}
.feat-icon.blue   { background: rgba(0,122,255,.1); }
.feat-icon.green  { background: rgba(52,199,89,.1); }
.feat-icon.yellow { background: rgba(255,214,10,.15); }
.feat-icon.purple { background: rgba(175,82,222,.1); }
.feat-card h3 {
  font-size: 20px; font-weight: 800;
  letter-spacing: -.4px; margin-bottom: 10px;
}
.feat-card p {
  font-size: 15px; color: var(--muted);
  line-height: 1.65;
}

/* gap illustration */
.gap-demo {
  display: flex; flex-direction: column; gap: 10px;
}
.gap-series {
  display: flex; align-items: center; gap: 8px;
}
.gap-series-name {
  font-size: 12px; font-weight: 700; color: var(--muted);
  width: 90px; text-align: right; flex-shrink: 0;
  letter-spacing: -.2px;
}
.gap-tomes {
  display: flex; gap: 4px; flex-wrap: wrap;
}
.tome {
  width: 28px; height: 28px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 800;
}
.tome.owned  { background: var(--blue); color: #fff; }
.tome.missing {
  background: rgba(255,59,48,.12);
  color: #FF3B30;
  border: 1.5px dashed rgba(255,59,48,.4);
}
.tome.empty  { background: rgba(0,0,0,.05); color: rgba(0,0,0,.25); }
.gap-legend {
  display: flex; gap: 14px; margin-top: 6px;
  font-size: 11px; color: var(--muted); font-weight: 600;
}
.gap-legend span { display: flex; align-items: center; gap: 5px; }
.dot-owned   { width: 8px; height: 8px; border-radius: 2px; background: var(--blue); }
.dot-missing { width: 8px; height: 8px; border-radius: 2px; background: rgba(255,59,48,.35); border: 1px dashed #FF3B30; }

/* ─── DECADE CHART (horizontal bars) ─── */
.decade-chart {
  display: flex;
  flex-direction: column;
}
.decade-chart-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}
.decade-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.dbar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.dbar-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  width: 48px;
  flex-shrink: 0;
  text-align: right;
  letter-spacing: -.3px;
}
.dbar-track {
  flex: 1;
  background: rgba(0,0,0,.06);
  border-radius: 6px;
  height: 26px;
  overflow: hidden;
}
.dbar-fill {
  width: 0;
  height: 100%;
  background: var(--color);
  border-radius: 6px;
  transition: width .8s cubic-bezier(.4,0,.2,1);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 10px;
  min-width: 0;
}
.dbar-count {
  font-size: 11px;
  font-weight: 800;
  color: rgba(255,255,255,.9);
  white-space: nowrap;
  opacity: 0;
  transition: opacity .3s ease .5s;
}
.dbar-fill[style*="width"] .dbar-count { opacity: 1; }

/* ─── HOW IT WORKS ─── */
.how {
  background: var(--ink);
  padding: 96px 32px;
}
.how-inner { max-width: 1120px; margin: 0 auto; }
.how .section-eyebrow { color: rgba(255,214,10,.8); }
.how .section-title { color: #fff; }
.how .section-sub { color: rgba(255,255,255,.5); }
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin-top: 56px;
  position: relative;
}
@media (max-width: 700px) {
  .steps { grid-template-columns: 1fr; }
}
.steps::before {
  content: '';
  position: absolute;
  top: 24px; left: calc(16.66% + 24px); right: calc(16.66% + 24px);
  height: 1px;
  background: rgba(255,255,255,.1);
}
@media (max-width: 700px) { .steps::before { display: none; } }
.step {
  padding: 0 28px;
  border-right: 1px solid rgba(255,255,255,.07);
}
.step:last-child { border-right: none; }
@media (max-width: 700px) {
  .step { padding: 24px 0; border-right: none; border-bottom: 1px solid rgba(255,255,255,.07); }
  .step:last-child { border-bottom: none; }
}
.step-num {
  width: 48px; height: 48px;
  background: var(--yellow); color: var(--ink);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 900;
  margin-bottom: 24px;
}
.step h3 {
  font-size: 20px; font-weight: 800;
  letter-spacing: -.3px; color: #fff;
  margin-bottom: 12px;
}
.step p { font-size: 15px; color: rgba(255,255,255,.5); line-height: 1.65; }

/* ─── MOBILE SECTION ─── */
.mobile-section {
  max-width: 1120px; margin: 0 auto;
  padding: 96px 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
@media (max-width: 820px) {
  .mobile-section { grid-template-columns: 1fr; gap: 48px; }
}
.mobile-phone {
  display: flex; justify-content: center;
}
.phone-frame {
  width: 250px;
  background: var(--ink);
  border-radius: 44px;
  padding: 14px;
  box-shadow: 0 32px 80px rgba(0,0,0,.22), 0 0 0 1px rgba(255,255,255,.08);
}
.phone-screen {
  border-radius: 34px;
  overflow: hidden;
  background: #fff;
}
.phone-screen img { width: 100%; display: block; }

.mobile-content .section-eyebrow { margin-bottom: 16px; }
.mobile-list {
  list-style: none; margin-top: 32px;
}
.mobile-list li {
  display: flex; gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px; line-height: 1.6;
}
.mobile-list li:last-child { border-bottom: none; }
.check {
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(52,199,89,.12); color: var(--green);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 900; flex-shrink: 0; margin-top: 1px;
}
.mobile-list strong { display: block; font-weight: 700; font-size: 15px; margin-bottom: 2px; }
.mobile-list span { color: var(--muted); font-size: 14px; }

/* ─── DESKTOP SCREENSHOT ─── */
.desktop-section {
  background: var(--cream);
  padding: 0 0 96px;
}
.desktop-section-inner {
  max-width: 1120px; margin: 0 auto; padding: 0 32px;
}
.desktop-header { padding: 80px 0 40px; }
.desktop-frame {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0,0,0,.15), 0 0 0 1px rgba(0,0,0,.06);
  background: #fff;
}
.desktop-frame img { width: 100%; display: block; }
/* chrome bar */
.desktop-chrome {
  background: #F0F0F0;
  padding: 12px 18px;
  display: flex; align-items: center; gap: 8px;
  border-bottom: 1px solid rgba(0,0,0,.08);
}
.chrome-dot { width: 12px; height: 12px; border-radius: 50%; }
.chrome-url {
  flex: 1; background: rgba(0,0,0,.07); border-radius: 6px;
  height: 22px; margin: 0 12px;
  display: flex; align-items: center; padding: 0 10px;
  font-size: 11px; color: #888; font-weight: 500;
}

/* ─── CTA BAND ─── */
.cta-band {
  background: var(--blue);
  padding: 88px 32px;
  text-align: center;
}
.cta-band h2 {
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 900; letter-spacing: -1.5px;
  color: #fff; margin-bottom: 16px;
}
.cta-band p {
  font-size: 18px; color: rgba(255,255,255,.75);
  margin-bottom: 40px; max-width: 460px;
  margin-left: auto; margin-right: auto; line-height: 1.6;
}
.btn-white {
  background: #fff; color: var(--blue);
  border: none; border-radius: 980px;
  padding: 17px 44px; font-size: 17px; font-weight: 800;
  font-family: var(--font); text-decoration: none;
  display: inline-block;
  transition: opacity .15s, transform .15s;
  letter-spacing: -.3px;
}
.btn-white:hover { opacity: .92; color: var(--blue); transform: translateY(-1px); }

/* ─── FOOTER (marketing) ─── */
footer {
  background: var(--ink); color: rgba(255,255,255,.4);
  padding: 44px 32px; text-align: center;
}
footer p { font-size: 14px; line-height: 1.8; }
footer a { color: rgba(255,255,255,.4); text-decoration: none; }
footer a:hover { color: rgba(255,255,255,.8); }


/* ══════════════════════════════════════════
   LEGAL PAGES  (terms.php, privacy.php)
══════════════════════════════════════════ */

body.legal {
  background: var(--bg);
  color: var(--text);
}

/* ─── NAV (legal) ─── */
body.legal nav {
  background: rgba(255,255,255,.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: static;
}
body.legal .nav-logo {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -.3px;
  display: block;
  gap: unset;
}
.nav-back {
  font-size: 14px;
  color: var(--blue);
  text-decoration: none;
}
.nav-back:hover { text-decoration: underline; }

/* ─── PAGE LAYOUT ─── */
.page {
  max-width: 720px;
  margin: 60px auto;
  padding: 0 24px 80px;
}
.page-header {
  margin-bottom: 48px;
}
.page-label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}
.page-header h1 {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -1px;
  margin: 0 0 12px;
}
.page-header p {
  color: var(--muted);
  font-size: 15px;
  margin: 0;
}

/* ─── CARDS ─── */
.card {
  background: var(--surface);
  border-radius: 18px;
  padding: 36px 40px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
@media (max-width: 600px) {
  .card { padding: 24px 20px; }
  .page-header h1 { font-size: 30px; }
}

body.legal h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.3px;
  margin: 0 0 16px;
}
body.legal p,
body.legal li {
  font-size: 15px;
  line-height: 1.7;
  color: #3A3A3C;
  margin: 0 0 12px;
}
body.legal p:last-child,
body.legal li:last-child { margin-bottom: 0; }
body.legal ul {
  padding-left: 20px;
  margin: 0 0 12px;
}
body.legal a { color: var(--blue); }

/* ─── REGISTER FORM ─── */
.field {
  margin-bottom: 20px;
}
.field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 7px;
}
.req { color: var(--blue); }
.opt { font-weight: 400; color: var(--muted); font-size: 13px; }
.field input,
.field textarea {
  width: 100%;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 11px 14px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  resize: vertical;
}
.field input:focus,
.field textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(0,122,255,.12);
}
.field input::placeholder,
.field textarea::placeholder { color: #BCBCC0; }
.submit-btn {
  display: inline-block;
  margin-top: 28px;
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: 980px;
  padding: 14px 32px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .15s, transform .15s;
}
.submit-btn:hover { opacity: .87; transform: translateY(-1px); }

/* ─── HIGHLIGHT (privacy) ─── */
.highlight {
  background: rgba(0,122,255,.06);
  border-left: 3px solid var(--blue);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
  margin-bottom: 16px;
  font-size: 15px;
  line-height: 1.6;
  color: #3A3A3C;
}
.highlight:last-child { margin-bottom: 0; }

/* ─── FOOTER (legal) ─── */
body.legal footer {
  background: transparent;
  color: var(--muted);
  border-top: 1px solid var(--border);
  padding: 32px 24px;
}
body.legal footer p { font-size: 14px; color: var(--muted); margin: 0; line-height: 1.8; }
body.legal footer a { color: var(--muted); text-decoration: none; }
body.legal footer a:hover { color: var(--blue); }
