/* Planora — feuille de style partagée des pages publiques (marketing, terms, privacy).
   Reprend les tokens de l'apparence "Carnet" de l'app (PlanoraPalettes.swift). */

@font-face {
  font-family: 'Fraunces';
  src: url('/fonts/Fraunces-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Fraunces';
  src: url('/fonts/Fraunces-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Fraunces';
  src: url('/fonts/Fraunces-Italic.ttf') format('truetype');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Caveat';
  src: url('/fonts/Caveat-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/IBMPlexMono-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/fonts/IBMPlexMono-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #F7F2E8;
  --surface: #FFFDF6;
  --surface-alt: #F0E9D8;
  --ink: #2B2A26;
  --ink-muted: #6E6552;
  --ink-faint: #8A7F68;
  --accent: #C1442E;
  --on-accent: #FFFDF6;
  --accent-alt: #2E5EAA;
  --line: #D8CFB9;
  --line-strong: #2B2A26;
  --shadow: rgba(43, 42, 38, 0.12);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #171512;
    --surface: #201D18;
    --surface-alt: #2A261F;
    --ink: #F1EAD9;
    --ink-muted: #B3A78C;
    --ink-faint: #8C8168;
    --accent: #E0684E;
    --on-accent: #171512;
    --accent-alt: #82A7DC;
    --line: #3A342A;
    --line-strong: #F1EAD9;
    --shadow: rgba(0, 0, 0, 0.35);
  }
}
:root[data-theme="dark"] {
  --paper: #171512;
  --surface: #201D18;
  --surface-alt: #2A261F;
  --ink: #F1EAD9;
  --ink-muted: #B3A78C;
  --ink-faint: #8C8168;
  --accent: #E0684E;
  --on-accent: #171512;
  --accent-alt: #82A7DC;
  --line: #3A342A;
  --line-strong: #F1EAD9;
  --shadow: rgba(0, 0, 0, 0.35);
}
:root[data-theme="light"] {
  --paper: #F7F2E8;
  --surface: #FFFDF6;
  --surface-alt: #F0E9D8;
  --ink: #2B2A26;
  --ink-muted: #6E6552;
  --ink-faint: #8A7F68;
  --accent: #C1442E;
  --on-accent: #FFFDF6;
  --accent-alt: #2E5EAA;
  --line: #D8CFB9;
  --line-strong: #2B2A26;
  --shadow: rgba(43, 42, 38, 0.12);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Fraunces', Georgia, serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

h1, h2, h3 { font-family: 'Fraunces', Georgia, serif; text-wrap: balance; }

/* ── Top bar (shared) ── */
.topbar {
  max-width: 920px;
  margin: 0 auto;
  padding: 22px 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.wordmark {
  font-weight: 600;
  font-size: 20px;
  text-decoration: none;
  color: var(--ink);
}
.topbar nav {
  display: flex;
  gap: 24px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  color: var(--ink-muted);
}
.topbar nav a { text-decoration: none; }
.topbar nav a:hover { color: var(--accent); }

/* ── Legal page layout (terms / privacy) ── */
.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 20px 80px;
}

.header { margin-bottom: 8px; }

.app-name {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
  font-family: 'IBM Plex Mono', monospace;
}

.page h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
}

.updated {
  font-size: 13px;
  color: var(--ink-faint);
  margin-top: 8px;
  font-family: 'IBM Plex Mono', monospace;
}

.lang-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 24px 0 32px;
}

.lang-bar a {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-muted);
  transition: background .15s, color .15s, border-color .15s;
}

.lang-bar a:hover {
  background: var(--surface-alt);
  border-color: var(--accent);
  color: var(--accent);
}

.lang-bar a.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 28px 32px;
  margin-bottom: 12px;
}

.card h2 {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card h2::before {
  content: '';
  display: inline-block;
  width: 3px;
  height: 15px;
  background: var(--accent);
  border-radius: 2px;
  flex-shrink: 0;
}

.card p, .card li { color: var(--ink-muted); font-size: 15px; }

.card ul { padding-left: 18px; margin-top: 8px; }
.card ul li { margin-bottom: 5px; }
.card p + p { margin-top: 10px; }

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

.footer {
  margin-top: 40px;
  text-align: center;
  font-size: 13px;
  color: var(--ink-faint);
  font-family: 'IBM Plex Mono', monospace;
}
.footer a { color: var(--ink-faint); }

@media (max-width: 560px) {
  .page { padding: 24px 16px 60px; }
  .card { padding: 20px 18px; }
}

/* ── Marketing / landing page ── */
.wrap {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 24px;
}

.hero {
  position: relative;
  padding: 56px 0 80px;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 40px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 600;
  line-height: 1.1;
}

.hero .lede {
  margin-top: 18px;
  max-width: 46ch;
  color: var(--ink-muted);
  font-size: 19px;
}

.hero .script {
  font-family: 'Caveat', cursive;
  font-size: 26px;
  color: var(--accent-alt);
  display: inline-block;
  transform: rotate(-2deg);
  margin-top: 4px;
}

.cta-row {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.btn-primary {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  letter-spacing: .04em;
  text-decoration: none;
  background: var(--ink);
  color: var(--paper);
  padding: 14px 26px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 6px 16px var(--shadow);
}

.cta-note {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--ink-faint);
}

.stamp-wrap { display: flex; justify-content: center; }
.stamp {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 3px double var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  transform: rotate(-8deg);
  position: relative;
  background: var(--surface);
}
.stamp::after {
  content: '';
  position: absolute;
  inset: 14px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  opacity: .55;
}
.stamp-text { text-align: center; font-family: 'IBM Plex Mono', monospace; color: var(--accent); }
.stamp-text .big {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 24px;
  display: block;
  letter-spacing: .02em;
}
.stamp-text .small {
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  display: block;
  margin-top: 4px;
}

.trail { border: none; border-top: 2px dashed var(--line); margin: 0; }

.postcard {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 40px;
  margin: 64px 0;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 32px;
  box-shadow: 0 10px 30px var(--shadow);
}
.postcard h2 { font-size: 24px; font-weight: 600; }
.postcard p { color: var(--ink-muted); margin-top: 14px; font-size: 16px; }
.postcard-side {
  border-left: 1px dashed var(--line);
  padding-left: 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}
.postcard-side .row {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--ink-faint);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px dotted var(--line);
  padding-bottom: 8px;
}
.postcard-side .row b {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
}

.section-head { text-align: center; margin: 88px 0 40px; }
.section-head h2 { font-size: 28px; font-weight: 600; margin-top: 10px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 26px 24px 24px;
}
.feature:nth-child(2n) { transform: rotate(.6deg); }
.feature:nth-child(3n) { transform: rotate(-.6deg); }

.feature .badge {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 16px;
}

.feature h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; }
.feature p { color: var(--ink-muted); font-size: 14.5px; }

.feature .tag {
  display: inline-block;
  margin-top: 12px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-alt);
  border: 1px solid var(--accent-alt);
  border-radius: 999px;
  padding: 3px 10px;
}

.appearances { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.apr-card { border-radius: 8px; padding: 22px 20px; border: 1px solid var(--line); }
.apr-card .apr-name {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 8px;
  display: block;
}
.apr-card .apr-title { font-size: 18px; font-weight: 600; margin-bottom: 6px; }
.apr-card .apr-desc { font-size: 13.5px; opacity: .85; }
.apr-carnet { background: #F7F2E8; color: #2B2A26; }
.apr-carnet .apr-name { color: #C1442E; }
.apr-departs { background: #1D1F23; color: #F4F4F2; }
.apr-departs .apr-name { color: #FFCC00; }
.apr-nuit { background: #0B0F1A; color: #EDEFF5; }
.apr-nuit .apr-name { color: #FFB454; }

.pro {
  margin: 88px 0;
  background: var(--ink);
  color: var(--paper);
  border-radius: 10px;
  padding: 48px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 36px;
  align-items: center;
}
.pro .eyebrow { color: var(--accent); opacity: 1; }
.pro h2 { font-size: 26px; font-weight: 600; margin-top: 8px; color: var(--paper); }
.pro p { color: var(--surface-alt); opacity: .85; margin-top: 12px; font-size: 15px; }
.pro ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.pro li { font-size: 14.5px; display: flex; gap: 10px; color: var(--surface-alt); }
.pro li::before { content: '✓'; color: var(--accent); font-weight: 700; }
.pro .price-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--ink-faint);
  margin-top: 18px;
  display: block;
}

footer.site {
  border-top: 1px dashed var(--line);
  margin-top: 100px;
  padding: 36px 0 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
footer.site .wordmark-small { font-weight: 600; font-size: 15px; }
footer.site nav {
  display: flex;
  gap: 22px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--ink-muted);
}
footer.site nav a { text-decoration: none; }
footer.site nav a:hover { color: var(--accent); }
footer.site .copyright {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--ink-faint);
  width: 100%;
  text-align: center;
  margin-top: 8px;
}

@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; }
  .stamp-wrap { order: -1; }
  .postcard { grid-template-columns: 1fr; }
  .postcard-side { border-left: none; border-top: 1px dashed var(--line); padding-left: 0; padding-top: 24px; }
  .features { grid-template-columns: 1fr; }
  .appearances { grid-template-columns: 1fr; }
  .pro { grid-template-columns: 1fr; padding: 32px 24px; }
  footer.site { flex-direction: column; text-align: center; }
}

/* ── Support / help page (réutilise la mise en page légale .page/.card) ── */
.page .intro {
  color: var(--ink-muted);
  font-size: 16px;
  margin-top: 12px;
  max-width: 62ch;
}

.contact-card {
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px 28px;
  margin: 24px 0 8px;
  text-align: center;
}
.contact-card p { color: var(--ink); font-size: 15px; margin-bottom: 8px; }
.contact-card a.email {
  color: var(--accent-alt);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  font-family: 'IBM Plex Mono', monospace;
}
.contact-card a.email:hover { text-decoration: underline; }

/* ── Focus clavier visible (partagé, toutes pages) ── */
a:focus-visible {
  outline: 2px solid var(--accent-alt);
  outline-offset: 2px;
  border-radius: 3px;
}
