/* dabotibi.com — the app's bright card table (docs/decisions/visual-system.md) on the web:
   dotted paper, cards with a 2px edge and a hard offset shadow, one orange action with a lip. */

/* The app's own fonts (SIL Open Font License), served from here rather than a font CDN so a
   visit tells no third party anything. */
@font-face { font-family: 'Nunito'; font-weight: 800; font-display: swap; src: url('/assets/fonts/Nunito-ExtraBold.ttf') format('truetype'); }
@font-face { font-family: 'IBM Plex Sans'; font-weight: 400; font-display: swap; src: url('/assets/fonts/IBMPlexSans-Regular.ttf') format('truetype'); }
@font-face { font-family: 'IBM Plex Sans'; font-weight: 600; font-display: swap; src: url('/assets/fonts/IBMPlexSans-SemiBold.ttf') format('truetype'); }
@font-face { font-family: 'Geist Mono'; font-weight: 400; font-display: swap; src: url('/assets/fonts/GeistMono-Regular.ttf') format('truetype'); }

:root {
  --paper: #fefcf6;
  --surface: #ffffff;
  --surface-muted: #fbf4e6;
  --edge: #61564b;
  --hard: #e0d5c1;
  --ink: #2e2822;
  --ink-muted: #6b6357;
  --ink-faint: #9e9689;
  --action: #ee8b2c;
  --action-lip: #bc6710;
  --on-action: #2a2318;
  --violet: #5e558c;
  --dot: rgba(97, 86, 75, 0.12);
  --radius: 14px;
  --sans: 'IBM Plex Sans', 'PingFang SC', 'Hiragino Sans GB', 'Noto Sans SC', system-ui, sans-serif;
  --display: 'Nunito', 'PingFang SC', 'Hiragino Sans GB', 'Noto Sans SC', system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  color-scheme: light;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background-color: var(--paper);
  background-image: radial-gradient(var(--dot) 1px, transparent 1.2px);
  background-size: 18px 18px;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
}

a { color: var(--ink); text-decoration-color: var(--action); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
img { max-width: 100%; display: block; }

.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(680px, 100% - 32px); margin-inline: auto; }

/* Header and footer */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 21px; letter-spacing: -0.01em; }
.brand img { width: 36px; height: 36px; border-radius: 9px; border: 2px solid var(--edge); }
.top nav { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.chip { display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px; border: 2px solid var(--edge); border-radius: 999px; background: var(--surface); font-size: 14px; font-weight: 600; text-decoration: none; }
.foot { margin-top: 72px; padding: 28px 0 40px; border-top: 2px dashed var(--hard); color: var(--ink-muted); font-size: 14px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.foot a { color: var(--ink-muted); }

/* The card: 2px edge, a hard shadow that is never blurred */
.card {
  background: var(--surface);
  border: 2px solid var(--edge);
  border-radius: var(--radius);
  box-shadow: 5px 5px 0 var(--hard);
}
.card.hero { transform: rotate(-0.6deg); }
.card.muted { background: var(--surface-muted); }
.band { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 14px; border-bottom: 2px solid var(--edge); border-radius: calc(var(--radius) - 2px) calc(var(--radius) - 2px) 0 0; color: #fff; font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; }
.band.violet { background: var(--violet); }
.band.orange { background: var(--action-lip); }
.band.ink { background: var(--edge); }

/* The one action: an orange slab with a 4px lip that sinks when pressed */
.slab {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 22px;
  border: 2px solid var(--edge); border-radius: 12px;
  background: var(--action); color: var(--on-action);
  box-shadow: 0 4px 0 var(--action-lip);
  font-family: var(--display); font-weight: 800; font-size: 17px;
  text-decoration: none; cursor: pointer;
  transition: transform 80ms ease, box-shadow 80ms ease;
}
.slab:active { transform: translateY(4px); box-shadow: 0 0 0 var(--action-lip); }
.slab.quiet { background: var(--surface); box-shadow: 0 4px 0 var(--hard); }
.slab.quiet:active { box-shadow: 0 0 0 var(--hard); }
.stores { display: flex; flex-wrap: wrap; gap: 12px; }

h1, h2, h3 { font-family: var(--display); line-height: 1.15; letter-spacing: -0.015em; margin: 0; }
h1 { font-size: clamp(34px, 6vw, 56px); font-weight: 800; }
h2 { font-size: clamp(26px, 4vw, 36px); font-weight: 800; }
h3 { font-size: 21px; font-weight: 800; }
p { margin: 0; }
.lede { font-size: clamp(18px, 2.3vw, 21px); color: var(--ink-muted); max-width: 34em; }
.label { font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-muted); }

/* Home */
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; padding: 40px 0 24px; }
.hero-copy { display: grid; gap: 22px; }
.deck { position: relative; height: 470px; }
.deck .card { position: absolute; width: min(300px, 78%); }
.deck .c1 { left: 0; top: 0; transform: rotate(-6deg); }
.deck .c2 { right: 0; top: 90px; transform: rotate(5deg); }
.deck .c3 { left: 10%; top: 250px; transform: rotate(-1.5deg); }
.face { padding: 14px 16px 18px; display: grid; gap: 8px; }
.face .art { font-size: 44px; line-height: 1.1; }
.face .title { font-family: var(--display); font-weight: 800; font-size: 20px; line-height: 1.2; }
.face .hook { color: var(--ink-muted); font-size: 15px; line-height: 1.45; }

.section { padding: 64px 0 0; display: grid; gap: 28px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.steps .card { padding: 22px; display: grid; gap: 10px; align-content: start; }
.steps .num { font-family: var(--mono); font-size: 13px; color: var(--action-lip); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.split .card { padding: 24px; display: grid; gap: 10px; align-content: start; }
.langs { display: flex; flex-wrap: wrap; gap: 8px; }
.langs span { padding: 4px 12px; border: 2px solid var(--edge); border-radius: 999px; background: var(--surface); font-size: 15px; }
.cta { padding: 32px; display: grid; gap: 18px; justify-items: start; }

/* Legal and help pages */
.doc { padding: 24px 0 0; }
.doc h1 { font-size: clamp(30px, 5vw, 42px); margin-bottom: 8px; }
.doc h2 { font-size: 23px; margin: 36px 0 10px; }
.doc p, .doc li { color: var(--ink); }
.doc p + p { margin-top: 12px; }
.doc ul { padding-left: 1.2em; margin: 10px 0; }
.doc li + li { margin-top: 6px; }
.doc .meta { color: var(--ink-muted); font-size: 15px; }
.doc .card { padding: 20px 22px; margin: 20px 0; }
.doc table { width: 100%; border-collapse: collapse; font-size: 15px; }
.doc th, .doc td { text-align: left; padding: 8px 10px 8px 0; border-bottom: 1px solid var(--hard); vertical-align: top; }
.lang-switch { margin: 8px 0 0; font-size: 14px; }

/* Share page */
.share { display: grid; gap: 22px; padding: 12px 0 0; justify-items: center; text-align: center; }
.share .gift { font-size: 15px; color: var(--ink-muted); }
.share .card { width: min(380px, 100%); text-align: left; }
.share .face .art { font-size: 72px; text-align: center; padding: 8px 0 4px; }
.share .face .title { font-size: 25px; }
.share .actions { display: grid; gap: 12px; width: min(380px, 100%); }
.share .actions .slab { width: 100%; }
.share .note { font-size: 15px; color: var(--ink-muted); max-width: 26em; }

@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; gap: 12px; padding-top: 16px; }
  /* On a phone the hand is held in a row: swipe it, nothing hides behind another card. */
  .deck { height: auto; display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; padding: 14px 16px 22px; margin-inline: -16px; }
  .deck .card { position: static; flex: 0 0 240px; scroll-snap-align: start; }
  .deck .c1, .deck .c2, .deck .c3 { transform: none; }
  .steps, .split { grid-template-columns: 1fr; }
  .top nav .chip.optional { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .slab { transition: none; }
}
