/* Koma: site styles. Brand: ink + paper + gold (matches the app's KomaTheme).
   Dark-first, with system-font typography and a warm-gold accent. */

:root {
  --bg: #0E0F12;
  --surface: #17181C;
  --surface-alt: #1F2127;
  --elevated: #23252B;
  --accent: #C8A872;        /* warm gold (app dark accent) */
  --accent-bright: #D8BE8A;
  --text: #F3F2EE;
  --text-2: #9A9EA6;
  --text-3: #6A6E76;
  --line: #2A2C32;
  --hairline: #202228;
  --seal: #D8452E;          /* cinnabar seal red, used sparingly */
  --radius: 16px;
  --maxw: 920px;
  --shadow: 0 14px 40px rgba(0,0,0,0.55);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Soft gold glow behind the hero, like the app's dark surfaces */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(900px 480px at 50% -10%, rgba(200,168,114,0.10), transparent 70%),
    radial-gradient(700px 420px at 85% 8%, rgba(216,69,46,0.045), transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.wrap { position: relative; z-index: 1; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

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

/* ---------- Header ---------- */
header.site {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 0; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand img { width: 38px; height: 38px; border-radius: 9px; box-shadow: 0 1px 0 rgba(255,255,255,0.06); }
.brand .name { font-weight: 650; font-size: 19px; letter-spacing: 0.2px; color: var(--text); }
nav.top a { color: var(--text-2); font-size: 15px; margin-left: 22px; }
nav.top a:hover { color: var(--text); text-decoration: none; }

/* ---------- Hero ---------- */
.hero { text-align: center; padding: 56px 0 40px; }
.hero .app-icon {
  width: 116px; height: 116px; border-radius: 26px; margin: 0 auto 26px;
  box-shadow: 0 18px 50px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.05);
  display: block;
}
.hero h1 { font-size: 44px; line-height: 1.1; margin: 0 0 14px; letter-spacing: -0.5px; font-weight: 700; }
.hero h1 .accent { color: var(--accent); }
.hero p.tag { font-size: 21px; color: var(--text-2); max-width: 620px; margin: 0 auto 12px; }
.hero p.sub { font-size: 16px; color: var(--text-3); max-width: 560px; margin: 0 auto; }

.badge-row { margin-top: 30px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  background: var(--accent); color: #1a1407; font-weight: 650; font-size: 16px;
  padding: 13px 22px; border-radius: 12px; border: 1px solid transparent;
}
.btn:hover { background: var(--accent-bright); text-decoration: none; color: #1a1407; }
.btn.ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn.disabled { opacity: 0.55; cursor: default; pointer-events: none; }
.coming { font-size: 13px; color: var(--text-3); margin-top: 14px; }

/* ---------- Sections ---------- */
section { padding: 40px 0; }
.section-title { font-size: 14px; letter-spacing: 1.4px; text-transform: uppercase; color: var(--accent); font-weight: 650; margin: 0 0 8px; }
h2 { font-size: 30px; line-height: 1.2; margin: 0 0 18px; letter-spacing: -0.3px; font-weight: 680; }
h3 { font-size: 19px; margin: 0 0 8px; font-weight: 640; }
p { color: var(--text); }
.lead { color: var(--text-2); font-size: 18px; max-width: 680px; }

.divider { height: 1px; background: var(--hairline); border: 0; margin: 8px 0; }

/* Feature grid */
.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 26px; }
.card {
  background: var(--surface); border: 1px solid var(--hairline);
  border-radius: var(--radius); padding: 24px;
}
.card .ico { font-size: 26px; margin-bottom: 12px; display: block; }
.card h3 { color: var(--text); }
.card p { color: var(--text-2); font-size: 15.5px; margin: 0; }

/* FAQ */
.faq { margin-top: 22px; }
.faq details {
  background: var(--surface); border: 1px solid var(--hairline);
  border-radius: 12px; padding: 4px 20px; margin-bottom: 12px;
}
.faq details[open] { border-color: var(--line); }
.faq summary {
  cursor: pointer; padding: 16px 0; font-weight: 600; font-size: 17px; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 22px; font-weight: 400; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq .body { padding: 0 0 18px; color: var(--text-2); font-size: 16px; }
.faq .body p { color: var(--text-2); margin: 0 0 10px; }
.faq .body p:last-child { margin-bottom: 0; }

/* Support callout */
.support-box {
  background: linear-gradient(180deg, var(--surface-alt), var(--surface));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px; text-align: center; margin-top: 22px;
}
.support-box .email { font-size: 22px; font-weight: 650; margin: 8px 0 4px; }
.support-box .email a { color: var(--accent); }
.support-box .note { color: var(--text-3); font-size: 14px; }

/* Privacy page prose */
.prose { max-width: 720px; }
.prose h2 { margin-top: 36px; }
.prose ul { padding-left: 22px; }
.prose li { color: var(--text-2); margin-bottom: 9px; }
.prose .updated { color: var(--text-3); font-size: 14px; }
.pill {
  display: inline-block; background: var(--accent); color: #1a1407;
  font-weight: 650; font-size: 13px; letter-spacing: 0.3px;
  padding: 5px 12px; border-radius: 999px; margin-bottom: 20px;
}

/* ---------- Footer ---------- */
footer.site {
  border-top: 1px solid var(--hairline); margin-top: 30px;
  padding: 30px 0 50px; color: var(--text-3); font-size: 14px;
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
}
footer.site a { color: var(--text-2); }
footer.site .links a { margin-left: 18px; }

/* ---------- Language switcher (nav icon + flag/name dropdown) ----------
   Standard component: a small icon button in the nav (sized like a theme
   toggle) opens a flag + language-name dropdown. Brand-neutral source mapped
   onto Koma's tokens. Auto-hidden until a 2nd locale ships (JS reveals it). */
.tbtn {
  width: 34px; height: 34px; border-radius: 9px;
  border: 1px solid var(--line); background: var(--surface); color: var(--text-2);
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center; font-size: 15px;
}
.tbtn:hover { color: var(--text); border-color: var(--accent); }
.langwrap { position: relative; display: inline-flex; margin-left: 22px; }
.langbtn { font-size: 11.5px; font-weight: 600; letter-spacing: 0.06em; }
.langbtn[aria-expanded="true"] { color: var(--text); border-color: var(--accent); }
.langmenu {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0; min-width: 172px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 11px;
  box-shadow: var(--shadow); padding: 6px; display: none; z-index: 60;
}
.langmenu.show { display: block; }
nav.top .langmenu a {
  display: flex; align-items: center; gap: 10px; margin-left: 0; padding: 9px 12px;
  border-radius: 8px; color: var(--text); font-size: 14px; text-decoration: none; white-space: nowrap;
}
nav.top .langmenu a:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--text); text-decoration: none; }
.langmenu a .fl { font-size: 16px; line-height: 1; }
nav.top .langmenu a[aria-current="true"] { color: var(--accent-bright); }
nav.top .langmenu a[aria-current="true"]::after { content: '\2713'; margin-inline-start: auto; color: var(--accent-bright); font-size: 13px; }

/* Language suggestion banner (detect-suggest-never-redirect) */
.i18n-banner {
  position: fixed; inset-block-end: 0; inset-inline: 0; z-index: 40;
  background: var(--surface); border-top: 1px solid var(--line);
  padding: 12px 18px; padding-bottom: max(12px, env(safe-area-inset-bottom));
  display: none; align-items: center; justify-content: center; gap: 14px; font-size: 14px;
}
.i18n-banner.show { display: flex; }
.i18n-banner button { background: var(--accent); color: #1a1407; border: none; border-radius: 8px; padding: 7px 16px; font-size: 13px; font-weight: 650; cursor: pointer; }
.i18n-banner button:hover { background: var(--accent-bright); }
.i18n-banner a.dismiss { color: var(--text-2); cursor: pointer; font-size: 13px; }

/* ---------- Responsive ---------- */
@media (max-width: 680px) {
  body { font-size: 16px; }
  .hero { padding: 36px 0 28px; }
  .hero h1 { font-size: 34px; }
  .hero p.tag { font-size: 18px; }
  .features { grid-template-columns: 1fr; }
  nav.top a { margin-left: 14px; font-size: 14px; }
  .langwrap { margin-left: 14px; }
  h2 { font-size: 25px; }
  footer.site { flex-direction: column; align-items: flex-start; }
  footer.site .links a { margin-left: 0; margin-right: 18px; }
}
