/* kizart — paper, pencil, one crayon. Light only: this is about pictures on
   paper, and a dark page changes how a child's colours read. */
:root {
  color-scheme: light;
  --ink: #1f1a17;
  --bg: #fff8ee;
  --paper: #ffffff;
  --line: #eadfcd;
  --muted: #6d6259;
  --accent: #d9480f;
  --accent-ink: #ffffff;
  --soft: #fff0dc;
  --good: #2b8a3e;
  --warn: #b7791f;
  --bad: #c92a2a;
  --radius: 14px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

a { color: var(--accent); }
img { max-width: 100%; }
[hidden] { display: none !important; }

.top {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 14px 22px; border-bottom: 1px solid var(--line); background: var(--bg);
}
.brand { font-weight: 800; font-size: 22px; letter-spacing: -0.02em; color: var(--ink); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.brand .dot { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); box-shadow: 8px 6px 0 -3px #f59f00, -4px 8px 0 -4px #1c7ed6; }
.top nav { display: flex; gap: 16px; margin-left: auto; flex-wrap: wrap; font-size: 15px; }
.top nav a { color: var(--ink); text-decoration: none; }
.top nav a[aria-current="page"], .top nav a:hover { color: var(--accent); }

main { flex: 1; width: 100%; max-width: 760px; margin: 0 auto; padding: 40px 22px 64px; }
main.wide { max-width: 1100px; }

h1 { font-size: clamp(30px, 5.5vw, 48px); line-height: 1.12; letter-spacing: -0.025em; margin: 0 0 16px; }
h2 { font-size: clamp(22px, 3.4vw, 28px); letter-spacing: -0.015em; margin: 44px 0 12px; line-height: 1.2; }
h3 { font-size: 19px; margin: 0 0 6px; }
.lede { font-size: 20px; color: var(--muted); max-width: 40em; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

.button, button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 700; cursor: pointer;
  background: var(--accent); color: var(--accent-ink);
  border: 0; border-radius: 999px; padding: 12px 22px; text-decoration: none;
  min-height: 46px;
}
.button.ghost, button.ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
button.small, .button.small { min-height: 34px; padding: 6px 14px; font-size: 14px; }
button:disabled { opacity: .55; cursor: default; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin: 22px 0; }

.steps { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); padding: 0; list-style: none; counter-reset: step; }
.steps li { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; counter-increment: step; }
.steps li::before { content: counter(step); display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--soft); color: var(--accent); font-weight: 800; margin-bottom: 8px; }

.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin: 16px 0; }
.compare { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.compare ul { margin: 8px 0 0; padding-left: 20px; }

form.stack { display: grid; gap: 14px; max-width: 520px; }
label { display: grid; gap: 4px; font-weight: 600; font-size: 15px; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
label.check input { margin-top: 5px; width: 20px; height: 20px; }
input, textarea, select {
  font: inherit; color: var(--ink); background: var(--paper);
  border: 1.5px solid var(--line); border-radius: 10px; padding: 10px 12px; width: 100%;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
textarea { min-height: 120px; resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.note { padding: 12px 14px; border-radius: 10px; background: var(--soft); }
.note.good { background: #ebfbee; color: var(--good); }
.note.bad { background: #fff5f5; color: var(--bad); }

.pill { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; border: 1.5px solid currentColor; white-space: nowrap; }
.pill.granted { color: var(--good); }
.pill.pending { color: var(--warn); }
.pill.withdrawn { color: var(--bad); }

.foot { border-top: 1px solid var(--line); padding: 26px 22px 34px; font-size: 15px; color: var(--muted); text-align: center; }
.foot p { margin: 0 0 8px; }
.foot nav { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }

/* The app */
.bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.bar h1, .bar h2 { margin: 0; }
.bar .grow { flex: 1; }
.crumbs { font-size: 15px; margin-bottom: 8px; }
.list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.row { display: flex; align-items: center; gap: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.row .grow { flex: 1; min-width: 0; }
.row .name { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); text-decoration: none; }
.camera { width: 52px; height: 52px; border-radius: 50%; padding: 0; font-size: 22px; flex: none; }
.gallery { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.gallery figure { margin: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.gallery img, .gallery .ph { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--soft); }
.gallery .ph { display: grid; place-items: center; color: var(--muted); font-size: 13px; padding: 8px; text-align: center; }
.gallery figcaption { padding: 8px 10px; font-size: 14px; }
.gallery figcaption .muted { font-size: 12px; display: block; }
.banner { position: sticky; top: 0; z-index: 5; margin: -10px 0 16px; }
.code { font: 700 26px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; background: var(--soft); padding: 10px 14px; border-radius: 10px; display: inline-block; }
dialog { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; max-width: min(520px, 92vw); background: var(--paper); color: var(--ink); }
dialog::backdrop { background: rgba(31, 26, 23, .35); }

@media print { .top, .foot { display: none; } }
