:root {
  --bg: #f6f3ee;
  --ink: #1d1b19;
  --muted: #6b655e;
  --card: #fffdf9;
  --line: #e3ddd4;
  --accent: #1d1b19;
  --accent-ink: #fffdf9;
  --ok: #2f6b3a;
  --err: #9b2c2c;
  --radius: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171615; --ink: #f2eee8; --muted: #a59e95; --card: #211f1d;
    --line: #34312e; --accent: #f2eee8; --accent-ink: #171615;
    --ok: #7fc28b; --err: #f08a8a; color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--ink);
  font: 17px/1.45 ui-rounded, -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column;
  -webkit-text-size-adjust: 100%;
}
main { width: 100%; max-width: 30rem; margin: 0 auto; padding: max(16px, env(safe-area-inset-top)) 16px 24px; flex: 1; display: flex; flex-direction: column; gap: 16px; }
h1 { font-size: 1.6rem; line-height: 1.15; margin: 0 0 .5rem; letter-spacing: -0.01em; }
p { margin: 0 0 .9rem; }
a { color: inherit; }
.lead { font-size: 1.1rem; }
.small { font-size: .88rem; color: var(--muted); }
.mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .04em; }
.break { word-break: break-all; }
.eyebrow { font-size: .85rem; color: var(--muted); margin-bottom: .25rem; }
.eyebrow a { text-decoration: none; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }

.banner { border-radius: 10px; padding: 10px 14px; font-size: .95rem; }
.banner.ok { background: color-mix(in srgb, var(--ok) 14%, transparent); color: var(--ok); }
.banner.err { background: color-mix(in srgb, var(--err) 14%, transparent); color: var(--err); }

label { display: block; font-weight: 600; font-size: .92rem; margin: .8rem 0 .35rem; }
input[type=email], input[type=url], input:not([type]), textarea {
  width: 100%; font: inherit; color: inherit; background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px;
}
input:focus, textarea:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
textarea { resize: vertical; }
fieldset { border: 0; padding: 0; margin: 0; }
legend { font-weight: 600; font-size: .92rem; padding: 0; margin-bottom: .4rem; }
.choice { font-weight: 400; display: flex; gap: .6rem; align-items: center; margin: .5rem 0; }
.choice input { width: 1.15rem; height: 1.15rem; accent-color: var(--ink); }

.btn {
  display: inline-block; text-align: center; text-decoration: none; cursor: pointer;
  font: inherit; font-weight: 650; border: 0; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink);
  padding: 13px 22px; margin: 14px 8px 0 0; min-height: 48px;
}
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn.danger { background: var(--err); color: #fff; }
.btn.big { width: 100%; font-size: 1.1rem; }
form.inline { display: inline; }

/* text / link tabs, no JS: radios toggle the panes */
.tabs input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.tabs input[type=radio] + label {
  display: inline-block; margin: 0 6px 0 0; padding: 8px 16px; border-radius: 999px;
  border: 1px solid var(--line); font-weight: 600; cursor: pointer;
}
.tabs input[type=radio]:checked + label { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.tabs input[type=radio]:focus-visible + label { outline: 2px solid var(--ink); outline-offset: 2px; }
.pane { display: none; }
#k-text:checked ~ .pane-text, #k-link:checked ~ .pane-link { display: block; }
details summary { cursor: pointer; font-weight: 600; }
details[open] summary { margin-bottom: .6rem; }

.shirts { list-style: none; margin: 0 0 .5rem; padding: 0; }
.shirts li a {
  display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; gap: 2px 12px;
  padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: none;
}
.shirts .what { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shirts .scans { grid-column: 2; font-size: .85rem; color: var(--muted); }
.claimcode { font-size: 1.7rem; font-weight: 700; text-align: center; padding: 16px; border: 2px dashed var(--line); border-radius: 12px; }

/* public shirt pages: full-bleed in the shirt's color */
body[class^="cw-"] { background: var(--shirt); color: #fff; }
body[class^="cw-"] main { justify-content: center; }
body[class^="cw-"] .card { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.18); }
body[class^="cw-"] .small, body[class^="cw-"] .eyebrow { color: rgba(255,255,255,.72); }
body[class^="cw-"] input, body[class^="cw-"] textarea { background: rgba(0,0,0,.18); border-color: rgba(255,255,255,.25); }
body[class^="cw-"] .btn { background: #fff; color: var(--shirt); }
body[class^="cw-"] .btn.ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.4); }
.shirt { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: center; padding: 24px 4px; }
.slogan { font-size: clamp(2rem, 9vw, 3.2rem); line-height: 1.08; font-weight: 800; letter-spacing: -0.02em; white-space: pre-line; overflow-wrap: anywhere; margin: 0 0 1rem; }
.host { font-size: clamp(1.8rem, 8vw, 2.6rem); font-weight: 800; margin: 0 0 .4rem; overflow-wrap: anywhere; }
.fullurl { font-size: .85rem; opacity: .72; overflow-wrap: anywhere; }
.shirtfoot { display: flex; justify-content: space-between; font-size: .85rem; opacity: .8; padding: 8px 2px; }

.cw-black { --shirt: #262626; }
.cw-pepper { --shirt: #4f4c4a; }
.cw-graphite { --shirt: #55565a; }
.cw-true-navy { --shirt: #2b364f; }
.cw-midnight { --shirt: #2b3142; }
.cw-denim { --shirt: #3f4f66; }
.cw-blue-jean { --shirt: #5c7492; }
.cw-blue-spruce { --shirt: #3e5753; }
.cw-espresso { --shirt: #4a3a31; }
.cw-wine { --shirt: #5a2a34; }
.cw-crimson { --shirt: #7a2c35; }

/* shop */
.price { font-size: 1.4rem; font-weight: 750; margin-bottom: .6rem; }
img.product { width: 100%; height: auto; border-radius: 10px; margin-bottom: 12px; }
.pick { margin-top: .9rem; }
.pick input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.pick input[type=radio] + label {
  display: inline-flex; align-items: center; gap: 8px; margin: 0 6px 8px 0; padding: 9px 14px; min-height: 44px;
  border-radius: 999px; border: 1px solid var(--line); font-weight: 600; cursor: pointer;
}
.pick input[type=radio]:checked + label { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.pick input[type=radio]:focus-visible + label { outline: 2px solid var(--ink); outline-offset: 2px; }
.swatch { width: 18px; height: 18px; border-radius: 50%; background: var(--shirt); border: 1px solid var(--line); }

/* orders list */
.orders { list-style: none; margin: 0; padding: 0; }
.order { border-top: 1px solid var(--line); padding: 14px 0; }
.order .big { font-size: 1.15rem; font-weight: 700; margin-bottom: .4rem; }
.order address { font-style: normal; margin: .4rem 0; line-height: 1.35; }
.order.st-shipped { opacity: .75; }
