/* journaly.raevori.com — same palette as the app (apps/mobile/src/theme/tokens.ts). */
:root {
  --bg: #ffffff;
  --surface: #f4f4f5;
  --text: #0a0a0b;
  --muted: #6b6b70;
  --border: rgba(0, 0, 0, 0.08);
  --accent: #0a0a0b;
  --on-accent: #ffffff;
  --radius: 20px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a0a0b;
    --surface: #151517;
    --text: #f5f5f7;
    --muted: #8e8e93;
    --border: rgba(255, 255, 255, 0.08);
    --accent: #f5f5f7;
    --on-accent: #0a0a0b;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-underline-offset: 3px; }

.wrap { max-width: 44rem; margin: 0 auto; padding: 0 20px; }

header.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
}

.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; text-decoration: none; letter-spacing: -0.01em; }

.icon {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  background: var(--accent);
  color: var(--on-accent);
}

nav a { color: var(--muted); text-decoration: none; margin-left: 16px; font-size: 15px; }
nav a:hover { color: var(--text); }

.hero { padding: 64px 0 40px; text-align: center; }
.hero h1 { font-size: clamp(2.1rem, 7vw, 3.2rem); line-height: 1.08; letter-spacing: -0.035em; margin: 0 0 16px; }
.hero p { color: var(--muted); font-size: 1.15rem; max-width: 32rem; margin: 0 auto 28px; }

.pill {
  display: inline-block;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  padding: 14px 26px;
  font-weight: 600;
  text-decoration: none;
}

.pill--quiet { background: var(--surface); color: var(--text); }

.grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); padding: 24px 0 56px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.card h3 { margin: 0 0 6px; font-size: 1.05rem; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

article { padding: 24px 0 64px; }
article h1 { font-size: clamp(1.8rem, 6vw, 2.4rem); letter-spacing: -0.03em; line-height: 1.15; margin: 16px 0 6px; }
article h2 { font-size: 1.2rem; letter-spacing: -0.01em; margin: 36px 0 8px; }
article .updated { color: var(--muted); margin: 0 0 24px; font-size: 0.95rem; }
article li { margin: 4px 0; }
article table { width: 100%; border-collapse: collapse; font-size: 0.95rem; margin: 8px 0; }
article th, article td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--border); vertical-align: top; }
article th { color: var(--muted); font-weight: 600; font-size: 0.85rem; }

.steps { counter-reset: s; list-style: none; padding: 0; }
.steps li { counter-increment: s; position: relative; padding: 14px 16px 14px 56px; background: var(--surface); border-radius: 16px; margin: 8px 0; }
.steps li::before {
  content: counter(s);
  position: absolute;
  left: 16px;
  top: 14px;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.note { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 14px 16px; }

footer { border-top: 1px solid var(--border); padding: 24px 0 40px; color: var(--muted); font-size: 0.9rem; }
footer a { color: var(--muted); margin-right: 16px; }

/* ── landing ── */
.landing { display: grid; gap: 40px; padding: 24px 0 64px; }
.hero { padding: 40px 0 0; text-align: center; }
.eyebrow { margin: 0 0 14px; color: var(--muted); font-size: 0.85rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.hero h1 { font-size: clamp(2.3rem, 8vw, 3.6rem); line-height: 1.04; letter-spacing: -0.04em; margin: 0 0 18px; }
.hero h1 span { color: var(--muted); }
.lede { color: var(--muted); font-size: 1.15rem; max-width: 26rem; margin: 0 auto 28px; }
.pill--soon { cursor: default; }

.phone {
  justify-self: center;
  width: min(340px, 100%);
  border-radius: 44px;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.35);
}
.screen {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-radius: 34px;
  background: var(--bg);
  padding: 28px 16px 22px;
  min-height: 460px;
}
.bubble {
  align-self: flex-end;
  max-width: 80%;
  border-radius: 20px 20px 6px 20px;
  background: var(--accent);
  color: var(--on-accent);
  padding: 10px 14px;
  font-size: 0.92rem;
}
.card-ui {
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  padding: 12px 14px;
  font-size: 0.88rem;
}
.card-ui p { margin: 0; }
.card-title { font-weight: 700; margin-bottom: 6px !important; }
.row { display: flex; justify-content: space-between; padding: 3px 0; color: var(--muted); }
.row b { color: var(--text); font-weight: 600; }
.row b.up { color: #1f9d45; }
@media (prefers-color-scheme: dark) { .row b.up { color: #34c759; } }
.confirm {
  display: block;
  margin-top: 10px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  text-align: center;
  padding: 8px;
  font-weight: 600;
}

.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.three div { display: flex; flex-direction: column; gap: 2px; text-align: center; background: var(--surface); border-radius: 18px; padding: 16px 10px; }
.three b { font-size: 1rem; }
.three span { color: var(--muted); font-size: 0.85rem; }
@media (max-width: 420px) { .three { grid-template-columns: 1fr; } }
