/* Folio marketing + legal site.

   The app's own tokens, not a second identity: paper, ink, and the one deep
   green the app uses for anything it is sure about. Light first, because the
   app is; the dark variant is the same paper under a lamp. Colours mirror
   `app/lib/core/theme/folio_tokens.dart` — change them there first.

   No external request anywhere on this page: the font is in this folder, the
   hero is an inline-styled SVG, there is no CDN, no analytics and no embed.
   A privacy page that phones a third party while claiming the app does not
   would be the wrong first impression. */

@font-face {
  font-family: "Fraunces";
  src: url("/assets/fraunces.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --paper: #f4f1ea;
  --surface: #fbf9f3;
  --ink: #23201a;
  --muted: #6f6858;
  --faint: #9a9280;
  --amount: #101010;
  --border: #ddd6c7;
  --accent: #1f5c45;
  --accent-wash: rgba(31, 92, 69, 0.1);
  --attention: #8a6a1c;
  --radius: 18px;
  --maxw: 1080px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #131210;
    --surface: #1c1a17;
    --ink: #eae6db;
    --muted: #a59d8c;
    --faint: #6f6858;
    --amount: #f5f2ea;
    --border: #2e2b26;
    --accent: #3e8a6c;
    --accent-wash: rgba(62, 138, 108, 0.16);
    --attention: #d2ae4b;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

/* Fraunces is variable: the axes are set once here, the same weight and
   optical size `FolioTokens.serifVariations` sets, or the face silently
   renders at 400 and stops looking like the app. */
h1, h2, h3 {
  font-family: "Fraunces", Georgia, "Times New Roman", serif;
  font-variation-settings: "wght" 500, "opsz" 32;
  font-weight: 500;
  line-height: 1.18;
  letter-spacing: -0.3px;
}

a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--accent);
}
a:hover { text-decoration-thickness: 2px; }

/* Only the inactive language is hidden, so the active one keeps whatever
   display its own rule gave it (flex, grid, block). */
html[data-lang="tr"] [lang="en"] { display: none; }
html[data-lang="en"] [lang="tr"] { display: none; }

/* ---------- Top bar ---------- */
.nav {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: blur(10px);
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  border-bottom: 1px solid var(--border);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 66px; }
.brand {
  display: flex; align-items: center; gap: 12px;
  font-family: "Fraunces", serif; font-variation-settings: "wght" 500, "opsz" 24;
  font-size: 20px; letter-spacing: 0.4px; text-decoration: none;
}
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--muted); font-size: 14px; text-decoration: none; }
.nav-links a:hover { color: var(--ink); }

.lang-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.lang-toggle button {
  background: transparent; color: var(--muted); border: 0; cursor: pointer;
  font: 600 12px/1 inherit; font-family: inherit; padding: 9px 12px; letter-spacing: 0.5px;
  min-height: 34px;
}
.lang-toggle button[aria-pressed="true"] { background: var(--accent-wash); color: var(--ink); }

/* ---------- Hero ---------- */
.hero { text-align: center; padding: 78px 0 4px; }
.hero h1 {
  font-size: clamp(48px, 9vw, 92px); margin: 0 0 16px;
  font-variation-settings: "wght" 500, "opsz" 84;
}
.hero .tagline {
  font-family: "Fraunces", serif; font-variation-settings: "wght" 500, "opsz" 32;
  font-size: clamp(20px, 3vw, 28px); margin: 0 auto 20px; max-width: 22ch; line-height: 1.28;
}
.hero .lede { max-width: 60ch; margin: 0 auto 30px; color: var(--muted); font-size: 17px; }

.cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; align-items: center; }
.badge {
  display: inline-flex; align-items: center; gap: 11px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  padding: 11px 18px; font-size: 14px; text-decoration: none;
}
.badge img { width: 26px; height: 26px; border-radius: 7px; }
.badge b { font-weight: 600; }
.badge small { display: block; color: var(--muted); font-size: 11px; letter-spacing: 0.6px; text-transform: uppercase; }
.link-ghost { color: var(--muted); font-size: 14px; padding: 11px 4px; text-decoration: none; }
.link-ghost:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--accent); }

/* ---------- The hero illustration ---------- */
.panel { padding: 40px 0 4px; }
.panel img { display: block; width: 100%; height: auto; }
.legend {
  display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: center;
  margin: 22px 0 0; padding: 0; list-style: none; color: var(--muted); font-size: 14px;
}
.legend li { display: flex; align-items: center; gap: 9px; }
.legend .key { width: 16px; height: 16px; border-radius: 4px; flex: none; }
.legend .key.total { background: var(--amount); }
.legend .key.mark { background: none; border: 2px solid var(--accent); }
.legend .key.chip { background: var(--accent-wash); border: 1px solid var(--accent); }

/* ---------- Sections ---------- */
section { padding: 58px 0; }
.section-title { text-align: center; margin: 0 0 10px; font-size: clamp(28px, 4vw, 40px); }
.section-sub { text-align: center; color: var(--muted); margin: 0 auto 40px; max-width: 60ch; }

/* ---------- Three steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; counter-reset: step; }
.step {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px 22px;
}
.step .n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 8px;
  background: var(--accent-wash); color: var(--accent);
  font-size: 14px; font-weight: 700; margin-bottom: 16px;
}
.step h3 { margin: 0 0 8px; font-size: 20px; font-variation-settings: "wght" 500, "opsz" 20; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- The creed ---------- */
.creed {
  max-width: 760px; margin: 0 auto; text-align: center;
  border-top: 2px solid var(--accent); padding-top: 32px;
}
.creed h2 { margin: 0 0 14px; font-size: clamp(25px, 3.6vw, 34px); }
.creed p { margin: 0 auto 14px; color: var(--muted); max-width: 56ch; }
.creed p:last-child { margin-bottom: 0; }

/* Two columns of traffic: what goes out, what comes in. */
.traffic { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; max-width: 820px; margin: 34px auto 0; }
.traffic div {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px; text-align: left;
}
.traffic h3 { margin: 0 0 10px; font-size: 16px; letter-spacing: 0.02em; }
.traffic ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 15px; }
.traffic li { margin-bottom: 6px; }
.traffic .none { color: var(--accent); font-weight: 600; font-size: 15px; margin: 0; }

/* ---------- Feature grid ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px 22px; }
.card .ico { width: 26px; height: 3px; background: var(--accent); margin-bottom: 18px; }
.card h3 { margin: 0 0 8px; font-size: 19px; font-variation-settings: "wght" 500, "opsz" 20; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.card .tag {
  display: inline-block; margin-top: 14px; font-size: 11px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--accent);
  border: 1px solid var(--accent); border-radius: 999px; padding: 3px 9px;
}

/* ---------- Free / Pro ---------- */
.tiers { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; max-width: 880px; margin: 0 auto; }
.tier { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px 24px; }
.tier.paid { border-color: var(--accent); }
.tier h3 { margin: 0 0 4px; font-size: 22px; }
.tier .price { color: var(--muted); font-size: 14px; margin: 0 0 18px; }
.tier ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; color: var(--muted); font-size: 15px; }
.tier li { display: flex; gap: 10px; align-items: flex-start; }
.tier li::before { content: ""; width: 7px; height: 7px; border-radius: 2px; background: var(--accent); margin-top: 8px; flex: none; }
.tier-note { text-align: center; color: var(--muted); font-size: 14px; margin: 22px auto 0; max-width: 56ch; }

/* ---------- Questions ---------- */
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 12px; }
.faq details {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 16px 20px;
}
.faq summary {
  cursor: pointer; font-weight: 600; list-style: none;
  display: flex; justify-content: space-between; gap: 16px; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-weight: 400; font-size: 20px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq p { margin: 12px 0 0; color: var(--muted); font-size: 15px; }

/* ---------- Support ---------- */
.support { max-width: 620px; margin: 0 auto; text-align: center; }
.support p { color: var(--muted); margin: 0 auto 22px; }
.support .mail {
  display: inline-block; background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 14px 22px; font-size: 16px; text-decoration: none;
}
.support .mail:hover { border-color: var(--accent); }

/* ---------- Legal page ---------- */
.legal { max-width: 40rem; margin: 0 auto; padding: 32px 0 0; }
.legal h1 { font-size: clamp(30px, 5vw, 42px); margin: 0 0 6px; }
.legal .meta { color: var(--muted); font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; margin: 0 0 28px; }
.legal .lede { font-size: 17px; margin: 0 0 8px; }
.legal h2 { font-size: 21px; margin: 38px 0 10px; }
.legal p { margin: 0 0 12px; }
.legal .back { display: inline-block; margin-bottom: 24px; color: var(--muted); font-size: 14px; text-decoration: none; }
.legal .back:hover { color: var(--ink); }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--border); margin-top: 56px; padding: 40px 0; color: var(--muted); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }
footer .f-brand { display: flex; align-items: center; gap: 10px; font-family: "Fraunces", serif; letter-spacing: 0.4px; color: var(--ink); }
footer .f-brand img { width: 26px; height: 26px; border-radius: 7px; }
footer .f-links { display: flex; gap: 20px; font-size: 14px; }
footer .f-links a { color: var(--muted); text-decoration: none; }
footer .f-links a:hover { color: var(--ink); }
footer small { display: block; width: 100%; color: var(--faint); font-size: 13px; }

@media (max-width: 900px) {
  .grid, .steps { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .grid, .steps, .tiers, .traffic { grid-template-columns: 1fr; }
  .nav-links a { display: none; }
  .hero { padding: 54px 0 4px; }
  section { padding: 46px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
