/* The text pages (Questions, Privacy, Terms, Refunds, Imprint): a sheet of the
   Glacier paper, as on Home. Written text is in Glacier's handwriting on the
   ruled lines; buttons and small print are in Montserrat, as in the app.
   Colours and rules from BRAND.md. */
@font-face { font-family: "Montserrat"; src: url("fonts/montserrat-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Montserrat"; src: url("fonts/montserrat-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Shantell Sans"; src: url("fonts/shantell-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Shantell Sans"; src: url("fonts/shantell-sans-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --paper: #eef4fb;
  --top: #dcebfb;
  --rule: #c7dcf2;
  --ink: #1b2a4a;
  --soft: #4f5f7d;
  --accent: #346cb4; /* Glacier accent #3f78c4, one step deeper on the web for readable contrast (WCAG AA) */
  --fill: #fff3c4;
  --lh: 1.8rem;     /* one ruled row */
  --shift: 6px;     /* the rule runs just under the letters */
  --hand: "Shantell Sans", system-ui, sans-serif;
  --ui: "Montserrat", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { background: var(--paper); }
body {
  margin: 0;
  font-family: var(--hand);
  font-size: 1.05rem;
  line-height: var(--lh);
  color: var(--ink);
  background: var(--paper);
}
a { color: var(--accent); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* --- Top bar, as on Home ------------------------------------------------- */
.top { display: flex; justify-content: space-between; align-items: center; gap: 16px; background: var(--top); padding: 18px max(16px, calc((100% - 72rem) / 2)) 18px; }
.brand { display: flex; align-items: center; gap: 10px; font: 700 1.05rem/1 var(--ui); color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand img { width: 30px; height: 30px; border-radius: 50%; image-rendering: pixelated; }
.pill {
  display: inline-block; white-space: nowrap;
  font: 700 0.9rem/1 var(--ui); color: var(--ink); text-decoration: none;
  background: color-mix(in srgb, var(--paper) 55%, #fff);
  border: 1px solid var(--rule); border-radius: 999px; padding: 0.65rem 1.1rem;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06);
}

/* --- The sheet ----------------------------------------------------------- */
main {
  padding: calc(var(--lh) * 2) max(16px, calc((100% - 42rem) / 2)) calc(var(--lh) * 2);
  background-image: repeating-linear-gradient(transparent 0 calc(var(--lh) - 1px), var(--rule) calc(var(--lh) - 1px) var(--lh));
  background-position: 0 calc(var(--lh) * 2 - var(--shift));
}
main > * { max-width: 42rem; }
h1 { font-size: 2.3rem; line-height: calc(var(--lh) * 2); margin: 0; font-weight: 700; }
h2 { font-size: 1.4rem; line-height: var(--lh); margin: var(--lh) 0 var(--lh); font-weight: 700; }
h3 { font-size: 1.1rem; line-height: var(--lh); margin: var(--lh) 0 0; font-weight: 700; }
p, ul, ol, dl, address { margin: 0 0 var(--lh); }
ul, ol { padding-left: 1.3em; }
li::marker { color: var(--accent); }
strong, b { font-weight: 700; }
address { font-style: normal; }
.updated { font: 400 0.8rem/var(--lh) var(--ui); color: var(--soft); margin: 0 0 var(--lh); }
/* A word from me, set off like a quote in a note. */
.note { color: var(--accent); border-left: 3px solid var(--rule); padding-left: 14px; }
/* Something the founder still has to fill in before launch. */
.fill { font-family: var(--ui); font-size: 0.85em; background: var(--fill); color: #463808; padding: 1px 5px; border-radius: 3px; }

/* Questions: each one with its answer right under it. */
.qa { display: grid; gap: var(--lh); margin: 0 0 var(--lh); }
.qa dt { font-weight: 700; }
.qa dd { margin: 0; }
kbd { font: 700 0.8em/1 var(--ui); background: #fff; border: 1px solid var(--rule); border-bottom-width: 2px; border-radius: 4px; padding: 2px 5px; }

/* --- The landscape along the bottom, as in the app ----------------------- */
.foot { background: var(--paper); }
.foot-land { display: block; width: 100%; height: 7rem; object-fit: cover; object-position: left bottom; image-rendering: pixelated; }
.made { margin: 0; background: var(--top); text-align: center; padding-top: 14px; color: var(--accent); }
.foot nav { background: var(--top); display: flex; flex-wrap: wrap; gap: 8px 22px; justify-content: center; padding: 16px 16px 28px; font: 400 0.85rem/1.4 var(--ui); }
.foot nav a { color: var(--ink); opacity: 0.8; }
.foot nav a[aria-current="page"] { opacity: 1; font-weight: 700; text-decoration: none; }

/* Small phones: the top bar keeps the name and the button on one line. */
@media (max-width: 420px) {
  .top { gap: 10px; }
  .top .brand { font-size: 0.95rem; gap: 8px; }
  .top .pill { font-size: 0.8rem; padding: 0.55rem 0.8rem; }
}

/* --- Articles ------------------------------------------------------------ */
.crumb { font: 400 0.8rem/var(--lh) var(--ui); margin: 0; }
.crumb a { color: var(--soft); }
.article h2 { font-size: 1.3rem; }
.article blockquote { margin: 0 0 var(--lh); padding-left: 14px; border-left: 3px solid var(--rule); font-style: italic; }
.article code { font: 700 0.85em/1 var(--ui); background: #fff; border: 1px solid var(--rule); border-radius: 4px; padding: 1px 5px; }
.article img { max-width: 100%; height: auto; border-radius: 8px; border: 1px solid var(--rule); }
.article-end { margin-top: calc(var(--lh) * 2); padding-left: 14px; border-left: 3px solid var(--accent); }
.article-end p:last-child { display: flex; flex-wrap: wrap; gap: 0 1.2rem; align-items: center; }
.article-list { list-style: none; padding: 0; display: grid; gap: var(--lh); }
.article-list li > a { font-size: 1.25rem; font-weight: 700; }
.article-list span { display: block; font: 400 0.8rem/var(--lh) var(--ui); color: var(--soft); }
.article-list p { margin: 0; }

/* --- Page not found: a little break with the penguin -------------------- */
.lost { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 2.5rem; align-items: start; max-width: 56rem !important; margin: 0 auto; }
main:has(.lost) { padding-left: max(16px, calc((100% - 56rem) / 2)); padding-right: max(16px, calc((100% - 56rem) / 2)); }
.lost p:has(.pill) { display: flex; flex-wrap: wrap; gap: 0.4rem 1.2rem; align-items: center; }
.lost .hint { font: 400 0.8rem/var(--lh) var(--ui); color: var(--soft); }
.break-box { position: relative; width: 20rem; height: 32rem; border-radius: 12px; overflow: hidden; border: 1px solid rgb(0 0 0 / 0.1); box-shadow: 0 10px 30px rgb(20 30 60 / 0.12); background: #fff; }
.break-poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; }
.break-game { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.break-start { position: absolute; left: 50%; bottom: 1.5rem; translate: -50% 0; font: 700 1rem/1 var(--ui); color: var(--paper); background: var(--ink); border: 0; border-radius: 999px; padding: 0.9rem 1.4rem; cursor: pointer; }
@media (max-width: 760px) {
  .lost { grid-template-columns: 1fr; }
  .break-box { width: min(20rem, 100%); height: 28rem; margin: 0 auto; }
}

/* --- Support (support.njk) ---------------------------------------------- */
.pay fieldset { border: 0; padding: 0; margin: 0 0 var(--lh); min-width: 0; }
.pay legend { font: 700 0.8rem/var(--lh) var(--ui); color: var(--soft); padding: 0; }
.plans { display: flex; gap: 8px; }
.plans input { position: absolute; opacity: 0; }
.plans span, .pick button, .go, .copy {
  display: inline-flex; align-items: center; gap: 0.6rem; cursor: pointer;
  font: 700 0.9rem/1 var(--ui); color: var(--ink);
  background: color-mix(in srgb, var(--paper) 55%, #fff);
  border: 1px solid var(--rule); border-radius: 999px; padding: 0.65rem 1.1rem;
}
.plans input:checked + span, .pick button[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.plans input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 3px; }
.pick { display: grid; gap: 8px; }
.pick button { border-radius: 12px; width: 100%; }
.pick img { width: 1.6rem; height: 1.6rem; image-rendering: pixelated; }
.pick span { flex: 1; text-align: left; font-family: var(--hand); font-weight: 400; font-size: 1.05rem; }
.amount { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.8rem; }
.amount input { width: 6rem; font: 700 1rem/1 var(--ui); color: var(--ink); background: #fff; border: 1px solid var(--rule); border-radius: 8px; padding: 0.5rem 0.6rem; }
.hint, .small { font: 400 0.8rem/var(--lh) var(--ui); color: var(--soft); }
.hint:empty { display: none; }
.go { color: var(--paper); background: var(--ink); border-color: var(--ink); font-size: 1rem; padding: 0.9rem 1.4rem; }
.go:disabled { opacity: 0.5; cursor: default; }
.code { display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem; }
.code code { font: 700 1.1rem/1 var(--ui); background: #fff; border: 1px solid var(--rule); border-radius: 8px; padding: 0.6rem 0.9rem; user-select: all; }
