/* =====================================================================
   Camarim design system — the single stylesheet of the app.

   Tokens        :root custom properties (light), dark via
                 prefers-color-scheme or html[data-theme="dark"].
                 .mirror re-scopes tokens to the always-dark "mirror".
   Shell         .topbar (mobile, 56px) · .tabbar (mobile, fixed bottom,
                 5 tabs) · .sidebar (desktop >= 900px, 220px) · .page
   Brand         .brand (symbol + word) · .brand-stack (vertical, login)
                 .brand-light / .brand-dark pick the symbol by theme
   Buttons       .btn (primary) · .btn-secondary · .btn-ghost ·
                 .btn-danger · .btn-sm · .btn-block · .btn-accent ·
                 .fab (floating "+") · disabled / [aria-busy] / htmx
   Forms         .field · .label · .input (also select/textarea) ·
                 .field-error · .toggle · .segmented
   Chips         .chip · .chip.is-active · .chip-row (scrolls)
   Tiles         .tile (3:4 pastel, contain) · .tile-1..6 · .badge ·
                 .badge-review · .badge-archived · .badge-processing
                 .badge-failed · .tile-caption · .clamp-2
   Feedback      .alert (+ -info -warn -error -ok) · .spinner ·
                 .shimmer · .empty (empty state)
   Quota         .lights (row of dots) · .light.is-on · .meter
   Look          .slot (dashed) · .collage · .sheet (bottom panel)
   Lists         .day-row (week) · .progress-row (upload) · .card
   Utilities     a small set of layout/spacing helpers used by templates.
   ===================================================================== */

/* ---------------------------------------------------------------- tokens */
:root {
  color-scheme: light;
  --c-bg: #F6F7FA; --c-surface: #FFFFFF; --c-surface-2: #EEF1F5; --c-ink: #14161B;
  --c-muted: #5D6677; /* darkened from #667085: 4.39:1 on surface-2 failed AA */ --c-line: #E3E6EB;
  --c-accent: #FFB020; --c-accent-fg: #2A1C00; --c-accent-soft: #FFF1D6;
  --c-danger: #B42318; --c-danger-bg: #FEE4E2; --c-warn-bg: #FEF3C7; --c-warn-fg: #92400E;
  --c-ok-bg: #DCFCE7; --c-ok-fg: #166534; --c-info-bg: #E8EEF7; --c-info-fg: #1D3A66;
  --btn-bg: #14161B; --btn-fg: #FFFFFF; --btn-bg-hover: #2B2F38;
  --tile-1: #FBD9CF; --tile-2: #D6E6D3; --tile-3: #CFE0F3; --tile-4: #E4D9F3; --tile-5: #F1E6C9; --tile-6: #D9DDE4;
  --mirror-bg: #14161B; --mirror-fg: #F4F5F7; --mirror-line: #2B2F38; --mirror-glass-1: #1D212A; --mirror-glass-2: #14161B;
  --r-pill: 999px; --r-card: 16px; --r-tile: 12px; --r-input: 12px; --r-sheet: 24px;
  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body: "DM Sans", system-ui, sans-serif;
  --shadow-float: 0 6px 16px rgba(0, 0, 0, .18);
  --ease: cubic-bezier(.2, .7, .3, 1);
  --t-fast: 150ms; --t: 200ms;
  --tabbar-h: 64px; --topbar-h: 56px; --sidebar-w: 220px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

/* dark tokens, applied by system preference or by the manual switch */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --c-bg: #0F1217; --c-surface: #171B22; --c-surface-2: #252A34; --c-ink: #F1F3F6;
    --c-muted: #9AA3B0; --c-line: #2A303A;
    --c-accent-soft: #3A2D10;
    --c-danger: #F97066; --c-danger-bg: #3B1512; --c-warn-bg: #3B2F12; --c-warn-fg: #FCD34D;
    --c-ok-bg: #12301D; --c-ok-fg: #86EFAC; --c-info-bg: #1A2638; --c-info-fg: #B8CCEB;
    --btn-bg: #F1F3F6; --btn-fg: #14161B; --btn-bg-hover: #D9DDE4;
    --tile-1: #5A3A33; --tile-2: #38503A; --tile-3: #33475C; --tile-4: #493C5E; --tile-5: #5A4E30; --tile-6: #3A404B;
    --shadow-float: 0 6px 16px rgba(0, 0, 0, .5);
  }
}
:root[data-theme="dark"], .mirror {
  color-scheme: dark;
  --c-bg: #0F1217; --c-surface: #171B22; --c-surface-2: #252A34; --c-ink: #F1F3F6;
  --c-muted: #9AA3B0; --c-line: #2A303A;
  --c-accent-soft: #3A2D10;
  --c-danger: #F97066; --c-danger-bg: #3B1512; --c-warn-bg: #3B2F12; --c-warn-fg: #FCD34D;
  --c-ok-bg: #12301D; --c-ok-fg: #86EFAC; --c-info-bg: #1A2638; --c-info-fg: #B8CCEB;
  --btn-bg: #F1F3F6; --btn-fg: #14161B; --btn-bg-hover: #D9DDE4;
  --tile-1: #5A3A33; --tile-2: #38503A; --tile-3: #33475C; --tile-4: #493C5E; --tile-5: #5A4E30; --tile-6: #3A404B;
  --shadow-float: 0 6px 16px rgba(0, 0, 0, .5);
}
/* the mirror (login, try-on) is the same in both themes */
.mirror { --c-bg: var(--mirror-bg); --c-ink: var(--mirror-fg); --c-line: var(--mirror-line); }

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; background: var(--c-bg); color: var(--c-ink);
  font: 400 15px/22px var(--font-body); -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: transparent; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
ul, ol { list-style: none; padding: 0; }
fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
legend { padding: 0; }
table { border-collapse: collapse; }
hr { border: 0; border-top: 1px solid var(--c-line); margin: 0; }
.prose a, .alert a, a.link { text-decoration: underline; text-underline-offset: 2px; }
h1, .h1 { font: 800 26px/30px var(--font-display); letter-spacing: -.02em; }
h2, .h2 { font: 700 18px/24px var(--font-display); letter-spacing: -.01em; }
h3, .h3 { font: 700 15px/20px var(--font-body); }
.small { font-size: 13px; line-height: 18px; }
.caption { font-size: 12px; line-height: 16px; color: var(--c-muted); }
.muted { color: var(--c-muted); }
.prose { max-width: 65ch; }
.num { font-family: var(--font-display); font-weight: 800; letter-spacing: -.02em; }
code, pre { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 13px; }
pre.code { background: var(--c-surface-2); border-radius: var(--r-input); padding: 12px 14px; overflow-x: auto; white-space: pre-wrap; word-break: break-all; }
@media (min-width: 900px) { h1, .h1 { font-size: 32px; line-height: 36px; } }

:focus { outline: none; }
/* amber ring (2px, 2px away) + 1px ink edge so it reaches 3:1 on light backgrounds */
:focus-visible { outline: 2px solid var(--c-accent); outline-offset: 2px; box-shadow: 0 0 0 2px var(--c-bg), 0 0 0 5px var(--c-ink); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 8px; top: -48px; z-index: 50; background: var(--btn-bg); color: var(--btn-fg); padding: 8px 14px; border-radius: var(--r-pill); font-weight: 700; text-decoration: none; }
.skip-link:focus { top: 8px; }
.icon { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 18px; height: 18px; }
.icon-lg { width: 40px; height: 40px; }

/* ----------------------------------------------------------------- shell */
.page { width: 100%; max-width: 1120px; margin: 0 auto; padding: 16px 16px calc(var(--tabbar-h) + var(--safe-b) + 32px); }
.page-plain { padding-bottom: 32px; }
@media (min-width: 640px) { .page { padding-left: 24px; padding-right: 24px; } }

.topbar {
  position: sticky; top: 0; z-index: 20; height: var(--topbar-h); display: flex; align-items: center;
  justify-content: space-between; padding: 0 16px; background: var(--c-bg);
  border-bottom: 1px solid transparent; transition: border-color var(--t) var(--ease);
}
.topbar.is-scrolled { border-bottom-color: var(--c-line); }
.avatar {
  width: 32px; height: 32px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  font: 800 14px/1 var(--font-display); color: var(--c-ink); text-decoration: none;
}
.avatar-hit { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr);
  height: calc(var(--tabbar-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  background: var(--c-surface); border-top: 1px solid var(--c-line); box-shadow: var(--shadow-float);
}
.tab {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  min-height: 44px; color: var(--c-muted); text-decoration: none; font-size: 11px; line-height: 14px; font-weight: 500;
  transition: color var(--t-fast) var(--ease);
}
.tab[aria-current="page"] { color: var(--c-ink); font-weight: 700; }
.tab[aria-current="page"]::after {
  content: ""; position: absolute; bottom: 6px; width: 16px; height: 3px; border-radius: 2px; background: var(--c-accent);
}

.sidebar { display: none; }
@media (min-width: 900px) {
  .topbar, .tabbar { display: none; }
  .has-shell { display: grid; grid-template-columns: var(--sidebar-w) 1fr; }
  .has-shell .page { padding-bottom: 48px; padding-top: 32px; }
  .sidebar {
    display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; overflow-y: auto;
    padding: 20px 12px; border-right: 1px solid var(--c-line); background: var(--c-bg);
  }
  .sidebar .brand { padding: 4px 10px 20px; }
  .side-link {
    display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 12px; border-radius: var(--r-input);
    border: 1px solid transparent; color: var(--c-muted); text-decoration: none; font-weight: 500;
    transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  }
  .side-link:hover { color: var(--c-ink); background: var(--c-surface-2); }
  .side-link[aria-current="page"] { color: var(--c-ink); font-weight: 700; background: var(--c-surface); border-color: var(--c-line); }
  .side-sep { height: 1px; background: var(--c-line); margin: 8px 10px; }
  .side-foot { margin-top: auto; }
}

/* ----------------------------------------------------------------- brand */
.brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--c-ink); }
.brand-symbol { width: 28px; height: 28px; }
.brand-word { font: 800 22px/1 var(--font-display); letter-spacing: -.02em; }
.brand-stack { flex-direction: column; gap: 10px; }
.brand-stack .brand-symbol { width: 72px; height: 72px; }
.brand-stack .brand-word { font-size: 40px; }
.brand-dark { display: none; }
:root[data-theme="dark"] .brand-light, .mirror .brand-light { display: none; }
:root[data-theme="dark"] .brand-dark, .mirror .brand-dark { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-light { display: none; }
  :root:not([data-theme="light"]) .brand-dark { display: block; }
}

/* ---------------------------------------------------------------- cards */
.card { background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--r-card); }
.card-pad { padding: 16px; }
.section + .section { margin-top: 24px; }
.stack > * + * { margin-top: 12px; }
.stack-lg > * + * { margin-top: 24px; }

/* --------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px;
  border: 0; border-radius: var(--r-pill); background: var(--btn-bg); color: var(--btn-fg);
  font: 700 14px/20px var(--font-body); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background var(--t-fast) var(--ease), opacity var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.btn:hover { background: var(--btn-bg-hover); }
.btn:active { transform: scale(.98); }
.btn-secondary { background: var(--c-surface-2); color: var(--c-ink); }
.btn-secondary:hover { background: var(--c-line); }
.btn-ghost { background: transparent; color: var(--c-ink); }
.btn-ghost:hover { background: var(--c-surface-2); }
.btn-danger { background: var(--c-danger-bg); color: var(--c-danger); }
.btn-danger:hover { background: var(--c-danger-bg); filter: brightness(.96); }
.btn-accent { background: var(--c-accent); color: var(--c-accent-fg); }
.btn-accent:hover { background: var(--c-accent); filter: brightness(1.05); }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: 13px; }
.btn-block { display: flex; width: 100%; }
.btn:disabled, .btn[aria-disabled="true"], .btn.htmx-request { opacity: .5; cursor: not-allowed; transform: none; }
.btn .spinner { display: none; }
.btn.htmx-request .spinner, .htmx-request .btn .spinner, .btn[aria-busy="true"] .spinner { display: inline-block; }
.fab {
  position: fixed; right: 16px; bottom: calc(var(--tabbar-h) + var(--safe-b) + 16px); z-index: 25;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 56px; height: 56px; padding: 0 20px;
  border-radius: var(--r-pill); background: var(--c-accent); color: var(--c-accent-fg); font-weight: 700; text-decoration: none;
  box-shadow: var(--shadow-float); transition: transform var(--t-fast) var(--ease);
}
.fab:active { transform: scale(.96); }
@media (min-width: 900px) { .fab { bottom: 32px; right: 32px; } }

/* ----------------------------------------------------------------- forms */
.field { display: block; }
.field + .field { margin-top: 16px; }
.grid > .field + .field { margin-top: 0; }
.label { display: block; font-size: 13px; line-height: 18px; font-weight: 700; margin-bottom: 6px; }
.input {
  display: block; width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--c-line); border-radius: var(--r-input);
  background: var(--c-surface); color: var(--c-ink); font-size: 16px; line-height: 22px; /* 16px avoids zoom on iOS */
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
select.input { appearance: none; padding-right: 36px; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
textarea.input { min-height: 88px; resize: vertical; }
.input::placeholder { color: var(--c-muted); }
.input:focus-visible, .input:focus { outline: none; border-color: var(--c-ink); box-shadow: 0 0 0 2px var(--c-bg), 0 0 0 4px var(--c-accent); }
.input[aria-invalid="true"] { border-color: var(--c-danger); }
input[type="file"].input { padding: 9px 12px; }
.field-error { margin-top: 6px; color: var(--c-danger); font-size: 13px; line-height: 18px; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--c-ink); width: 18px; height: 18px; }
.check { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; }

.toggle { position: relative; display: inline-block; width: 34px; height: 20px; flex: none; }
.toggle input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.toggle span { position: absolute; inset: 0; border-radius: var(--r-pill); background: var(--c-line); transition: background var(--t-fast) var(--ease); pointer-events: none; }
.toggle span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--c-surface); transition: transform var(--t-fast) var(--ease); }
.toggle input:checked + span { background: var(--c-ink); }
.toggle input:checked + span::after { transform: translateX(14px); }
.toggle input:focus-visible + span, .chip-input:focus-visible + .chip { outline: 2px solid var(--c-accent); outline-offset: 2px; box-shadow: 0 0 0 2px var(--c-bg), 0 0 0 5px var(--c-ink); }

.segmented { display: inline-flex; padding: 3px; gap: 2px; height: 36px; border-radius: var(--r-pill); background: var(--c-surface-2); }
.segmented > * { display: inline-flex; align-items: center; justify-content: center; min-width: 72px; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: transparent; color: var(--c-muted); font-size: 13px; font-weight: 700; cursor: pointer; text-decoration: none; }
.segmented > [aria-pressed="true"], .segmented > [aria-current="true"], .segmented > [aria-selected="true"] { background: var(--c-ink); color: var(--c-bg); }

/* ----------------------------------------------------------------- chips */
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border-radius: var(--r-pill);
  border: 0; background: var(--c-surface-2); color: var(--c-ink); font-size: 13px; font-weight: 500; line-height: 1;
  white-space: nowrap; text-decoration: none; cursor: pointer; transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
span.chip { cursor: default; }
.chip.is-active, .chip[aria-pressed="true"], .chip[aria-current="page"], input:checked + .chip { background: var(--c-ink); color: var(--c-surface); }
.chip-row {
  display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 16px; margin: 0 -16px;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 16px, #000 calc(100% - 16px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 16px, #000 calc(100% - 16px), transparent 100%);
}
.chip-row::-webkit-scrollbar { display: none; }
.chip-input { position: absolute; opacity: 0; pointer-events: none; }

/* ----------------------------------------------------------------- tiles */
.tile {
  position: relative; display: block; aspect-ratio: 3 / 4; border-radius: var(--r-tile); overflow: hidden;
  background: var(--c-surface-2) url("/static/brand/hanger-placeholder.svg") center / 36% no-repeat;
}
/* the hanger is only a placeholder: hide it behind real pictures (cutouts are transparent) */
.tile:has(> img:not(.is-broken)) { background-image: none; }
.tile > img.is-broken { visibility: hidden; }
.tile > img { width: 100%; height: 100%; object-fit: contain; padding: 12%; }
.tile-1 { background-color: var(--tile-1); } .tile-2 { background-color: var(--tile-2); } .tile-3 { background-color: var(--tile-3); }
.tile-4 { background-color: var(--tile-4); } .tile-5 { background-color: var(--tile-5); } .tile-6 { background-color: var(--tile-6); }
.tile-link { display: block; text-decoration: none; color: inherit; border-radius: var(--r-tile); }
.tile-link:hover .tile { filter: brightness(.97); }
.tile-caption { margin-top: 6px; font-size: 13px; line-height: 18px; }
.clamp-1 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.piece-row .grow { min-width: 0; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.badge {
  position: absolute; top: 8px; left: 8px; z-index: 1; display: inline-flex; align-items: center; gap: 4px;
  height: 22px; padding: 0 8px; border-radius: var(--r-pill); font-size: 11px; font-weight: 700; line-height: 1;
  background: var(--c-surface-2); color: var(--c-ink);
}
.badge-review { background: var(--c-accent); color: var(--c-accent-fg); }
.badge-archived { background: var(--c-surface-2); color: var(--c-ink); }
.badge-wish { background: var(--c-ink); color: var(--c-bg); }
.badge-processing { background: var(--c-surface); color: var(--c-ink); }
.badge-failed { background: var(--c-danger-bg); color: var(--c-danger); }
.badge-static { position: static; }
.grid-tiles { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 640px) { .grid-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .grid-tiles { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (min-width: 1280px) { .grid-tiles { grid-template-columns: repeat(6, minmax(0, 1fr)); } }


/* -------------------------------------------------------------- feedback */
.alert {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: var(--r-tile);
  background: var(--c-info-bg); color: var(--c-info-fg); font-size: 14px; line-height: 20px;
}
.alert > .icon { width: 20px; height: 20px; margin-top: 0; }
.alert a { font-weight: 700; }
.alert-info { background: var(--c-info-bg); color: var(--c-info-fg); }
.alert-warn { background: var(--c-warn-bg); color: var(--c-warn-fg); }
.alert-error { background: var(--c-danger-bg); color: var(--c-danger); }
.alert-ok { background: var(--c-ok-bg); color: var(--c-ok-fg); }

.spinner {
  display: none; width: 16px; height: 16px; flex: none; border: 2px solid currentColor; border-right-color: transparent;
  border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -3px;
}
.spinner.is-on, .htmx-request .spinner, .htmx-request.spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

.shimmer {
  border-radius: var(--r-tile);
  background: linear-gradient(90deg, var(--c-surface-2) 25%, var(--c-surface) 50%, var(--c-surface-2) 75%) 0 0 / 300% 100%;
  animation: shimmer 1.6s ease-in-out infinite;
}
.shimmer-tile { aspect-ratio: 3 / 4; }
.shimmer-line { height: 12px; border-radius: 6px; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }

.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 40px 16px; }
.empty-art { width: 96px; height: 96px; color: var(--c-line); margin-bottom: 8px; }
.empty .btn { margin-top: 12px; }

/* ------------------------------------------------------------ quota dots */
.lights { display: inline-flex; align-items: center; gap: 4px; }
.light { width: 8px; height: 8px; border-radius: 50%; background: var(--c-line); }
.light.is-on { background: var(--c-accent); box-shadow: 0 0 8px var(--c-accent); }
.quota { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; line-height: 18px; color: var(--c-muted); }
.meter { height: 8px; border-radius: var(--r-pill); background: var(--c-surface-2); overflow: hidden; }
.meter > span { display: block; height: 100%; border-radius: inherit; background: var(--c-ink); }
.meter.is-high > span { background: var(--c-danger); }

/* ------------------------------------------------------------------ looks */
.collage { display: grid; gap: 4px; grid-template-columns: repeat(2, minmax(0, 1fr)); border-radius: var(--r-card); overflow: hidden; }
.collage .tile { border-radius: 8px; }
/* fewer than 4 pieces: same 3:4 outline, wider cells instead of empty ones */
.collage-1 > .tile { grid-column: span 2; }
.collage-2 > .tile { grid-column: span 2; aspect-ratio: 3 / 2; }
.collage-3 > .tile:last-child { grid-column: span 2; aspect-ratio: 3 / 2; }
.collage-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.slot {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  aspect-ratio: 1; border: 1.5px dashed var(--c-line); border-radius: var(--r-tile); background: transparent;
  color: var(--c-muted); font-size: 13px; cursor: pointer; text-align: center; padding: 8px;
}
.slot.is-filled { border-style: solid; padding: 0; overflow: hidden; }
.slot-label { position: absolute; left: 6px; bottom: 6px; z-index: 1; padding: 2px 6px; border-radius: 6px; background: var(--c-surface); color: var(--c-ink); font-size: 11px; font-weight: 700; }

.sheet-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0, 0, 0, .4); opacity: 0; pointer-events: none; transition: opacity var(--t) var(--ease); }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; max-height: 70vh; overflow-y: auto;
  padding: 8px 16px calc(16px + var(--safe-b)); border-radius: var(--r-sheet) var(--r-sheet) 0 0;
  background: var(--c-surface); box-shadow: var(--shadow-float); transform: translateY(100%); transition: transform var(--t) var(--ease);
}
.sheet::before { content: ""; display: block; width: 36px; height: 4px; margin: 0 auto 12px; border-radius: 2px; background: var(--c-line); }
.sheet.is-open { transform: none; }
.sheet.is-open + .sheet-backdrop, .sheet-backdrop.is-open { opacity: 1; pointer-events: auto; }
@media (min-width: 900px) { .sheet { left: 50%; right: auto; width: 560px; transform: translate(-50%, 100%); } .sheet.is-open { transform: translate(-50%, 0); } }

/* ------------------------------------------------------------------ lists */
.day-row {
  display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 12px; border-radius: var(--r-card);
  background: var(--c-surface); border: 1px solid var(--c-line); text-decoration: none; color: inherit;
}
.day-row.is-today { border-color: var(--c-ink); }
.day-date { width: 40px; text-align: center; flex: none; }
.day-date small { display: block; font-size: 10px; line-height: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--c-muted); }
.day-date b { display: block; font: 800 17px/22px var(--font-display); }
.mini-thumbs { display: flex; gap: 4px; }
.text-warn { color: var(--c-warn-fg); }
.text-warn .icon, .text-green-700 .icon { display: inline-block; vertical-align: -4px; margin-right: 4px; }
.ai-mark { display: inline-flex; align-items: center; gap: 3px; color: var(--c-muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.ai-mark .icon { width: 14px; height: 14px; color: var(--c-accent); }
/* Provador: choose the look by its pieces (scrolls sideways, ring not clipped) */
.look-row { display: flex; gap: 12px; overflow-x: auto; margin: 0 -6px; padding: 6px 6px 10px; scroll-padding-inline: 6px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.look-opt { flex: 0 0 112px; scroll-snap-align: start; cursor: pointer; }
.look-mini { display: block; }
.look-mini .collage { outline: 2px solid transparent; outline-offset: 2px; border-radius: 12px; }
.look-opt input:checked + .look-mini .collage { outline-color: var(--c-ink); }
.look-opt input:focus-visible + .look-mini .collage { outline: 3px solid var(--c-accent); }
.look-mini-name { display: -webkit-box; margin-top: 8px; font-size: 13px; line-height: 17px; font-weight: 700; color: var(--c-muted); }
.look-opt input:checked + .look-mini .look-mini-name { color: var(--c-ink); }
.wish-box { padding: 12px 14px; border-radius: var(--r-card); background: var(--c-surface-2); }
.wish-box .icon { display: inline-block; vertical-align: -3px; }
/* face photo card (Fotos de corpo) */
.face-row { display: flex; gap: 16px; align-items: flex-start; }
.face-row > .face-tile { flex: none; width: 84px; height: auto; aspect-ratio: 3 / 4; border-radius: 12px; padding: 0; }
.face-tile .icon { width: 28px; height: 28px; }
.face-card label.btn { cursor: pointer; }
.face-card form:has(input[type=file]:focus-visible) label.btn { outline: 2px solid var(--c-accent); outline-offset: 2px; }
/* pieces of the look next to a try-on result */
.piece-strip { display: flex; flex-wrap: wrap; gap: 8px; }
.piece-strip .tile { width: 56px; border-radius: 10px; }
.piece-strip .tile > img { padding: 10%; }
/* horizontal picker of garments (Me veste: "Quero usar esta peça"); padded so the
   selection ring is not clipped by the scroll area */
.anchor-row { display: flex; gap: 8px; overflow-x: auto; margin: 0 -6px; padding: 6px 6px 10px; scroll-padding-inline: 6px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.anchor-opt { flex: 0 0 64px; scroll-snap-align: start; cursor: pointer; }
.anchor-tile { display: flex; width: 64px; aspect-ratio: 3 / 4; border-radius: 10px; outline: 2px solid transparent; outline-offset: 2px; }
.anchor-tile > img { padding: 10%; }
.anchor-tile { position: relative; }
.anchor-wish { position: absolute; top: 4px; right: 4px; display: inline-flex; padding: 2px; border-radius: 50%; background: var(--c-ink); color: var(--c-bg); }
.anchor-wish .icon { width: 12px; height: 12px; }
.anchor-none { flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 1.5px dashed var(--c-muted); color: var(--c-muted); font-size: 11px; font-weight: 700; }
.anchor-none .icon { width: 18px; height: 18px; }
.anchor-opt input:checked + .anchor-tile { outline-color: var(--c-ink); }
.anchor-opt input:checked + .anchor-none { border-style: solid; border-color: var(--c-ink); color: var(--c-ink); }
.anchor-opt input:focus-visible + .anchor-tile { outline: 3px solid var(--c-accent); }
.mini-thumbs .tile { width: 30px; border-radius: 6px; }
.mini-thumbs .tile > img { padding: 8%; }
.progress-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.progress-row + .progress-row { border-top: 1px solid var(--c-line); }
.progress-row .tile { width: 40px; flex: none; border-radius: 8px; }
.progress { height: 4px; border-radius: 2px; background: var(--c-surface-2); overflow: hidden; margin-top: 6px; }
.progress > span { display: block; height: 100%; background: var(--c-accent); }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; line-height: 18px; }
.table th { text-align: left; font-weight: 700; color: var(--c-muted); padding: 8px 10px 8px 0; border-bottom: 1px solid var(--c-line); white-space: nowrap; }
.table td { padding: 8px 10px 8px 0; border-bottom: 1px solid var(--c-line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
details.disclosure > summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; font-weight: 700; }
details.disclosure > summary::-webkit-details-marker { display: none; }
details.disclosure > summary::after { content: "+"; font-size: 20px; color: var(--c-muted); }
details.disclosure[open] > summary::after { content: "–"; }

/* ------------------------------------------------------------- utilities
   Small utility layer used by the templates; colors mapped to the tokens. */
.block { display: block; } .hidden { display: none; }
.flex { display: flex; } .grid { display: grid; }
.flex-col { flex-direction: column; } .flex-wrap { flex-wrap: wrap; } .grow { flex-grow: 1; }
.items-center { align-items: center; } .items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; } .justify-center { justify-content: center; }
.gap-1 { gap: 4px; } .gap-2 { gap: 8px; } .gap-3 { gap: 12px; }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mt-1 { margin-top: 4px; } .mt-2 { margin-top: 8px; } .mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; } .mt-6 { margin-top: 24px; }
.mb-2 { margin-bottom: 8px; } .mb-3 { margin-bottom: 12px; } .mb-4 { margin-bottom: 16px; }
.p-2 { padding: 8px; } .px-2 { padding-left: 8px; padding-right: 8px; } .pt-2 { padding-top: 8px; }
.py-4 { padding-top: 16px; padding-bottom: 16px; }
.w-full { width: 100%; } .w-20 { width: 80px; } .w-28 { width: 112px; }
.max-w-xs { max-width: 320px; }
.overflow-hidden { overflow: hidden; }
.text-left { text-align: left; } .text-center { text-align: center; }
.font-normal { font-weight: 400; } .font-semibold, .font-bold { font-weight: 700; }
.text-red-700 { color: var(--c-danger); } .text-green-700 { color: var(--c-ok-fg); }
.border { border: 1px solid var(--c-line); }

@media (min-width: 640px) {
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sm\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sm\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}


/* --------------------------------------------------------------- motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* ------------------------------------------------------- mirror: login */
.arc { display: flex; justify-content: center; align-items: flex-start; gap: 18px; height: 28px; }
.arc .light { width: 9px; height: 9px; }
.arc .light:nth-child(1), .arc .light:nth-child(7) { margin-top: 16px; }
.arc .light:nth-child(2), .arc .light:nth-child(6) { margin-top: 7px; }
.arc .light:nth-child(3), .arc .light:nth-child(5) { margin-top: 2px; }
.arc.is-pulsing .light { animation: pulse 2.4s ease-in-out infinite; }
.arc.is-pulsing .light:nth-child(2n) { animation-delay: .4s; }
.arc.is-pulsing .light:nth-child(3n) { animation-delay: .8s; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; box-shadow: none; } }
.login .login-wrap { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; padding: 40px 0 32px; }
.login .brand-stack { margin-top: 40px; }
.login .brand-word { margin: 0; }
.login-tagline { margin-top: 12px; color: var(--c-muted); text-align: center; }
.login-form { width: 100%; max-width: 360px; margin-top: 36px; }
.login-form > .alert { margin-bottom: 16px; }
.stack-form > * + * { margin-top: 16px; }
.stack-form .btn { margin-top: 24px; }
.login-foot { margin-top: 20px; text-align: center; }

/* ------------------------------------------------------------- page bits */
.page-head { margin-bottom: 20px; }
.page-head p { margin-top: 4px; }
.page-head-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.eyebrow { font-size: 12px; line-height: 16px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--c-muted); }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
.empty-compact { padding: 24px 16px; }
.empty-compact .empty-art { width: 64px; height: 64px; margin-bottom: 4px; }
.today-card h2 a { text-decoration: none; }
.shortcut-grid { display: grid; gap: 8px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 900px) { .shortcut-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.shortcut {
  display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 12px 14px; border-radius: var(--r-card);
  background: var(--c-surface); border: 1px solid var(--c-line); font-weight: 700; font-size: 14px; line-height: 20px;
  transition: background var(--t-fast) var(--ease);
}
.shortcut:hover { background: var(--c-surface-2); }
.shortcut small { display: block; font-weight: 400; font-size: 12px; line-height: 16px; color: var(--c-muted); }
.link-quiet { color: var(--c-muted); font-size: 13px; text-decoration: underline; text-underline-offset: 2px; display: inline-flex; align-items: center; min-height: 44px; }
.link-quiet:hover { color: var(--c-ink); }
.search { position: relative; }
.search .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--c-muted); pointer-events: none; width: 20px; height: 20px; }
.search .input { padding-left: 44px; }
.filter-block + .filter-block { margin-top: 10px; }
.tile-link .tile-caption { color: var(--c-ink); }
.tile-link .tile-sub { display: block; color: var(--c-muted); font-size: 12px; line-height: 16px; }
.tile.is-processing::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent 25%, rgba(255,255,255,.35) 50%, transparent 75%) 0 0 / 300% 100%; animation: shimmer 1.6s ease-in-out infinite; }
.search-grid { display: grid; gap: 8px; grid-template-columns: minmax(0, 1fr) 112px; }
@media (max-width: 479px) { .search-grid { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------------------------------------- upload (dropzone) */
.dropzone {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  min-height: 180px; padding: 24px 16px; text-align: center; cursor: pointer;
  border: 1.5px dashed var(--c-line); border-radius: var(--r-card); background: var(--c-surface-2);
  transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease);
}
.dropzone:hover, .dropzone.is-over { border-color: var(--c-ink); }
.dropzone-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.dropzone:focus-within { outline: 2px solid var(--c-accent); outline-offset: 2px; box-shadow: 0 0 0 2px var(--c-bg), 0 0 0 5px var(--c-ink); }
.dropzone-plus { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--c-accent); color: var(--c-accent-fg); margin-bottom: 4px; }
.dropzone-title { font-weight: 700; }
.tips li { display: flex; gap: 8px; align-items: flex-start; }
.tips li + li { margin-top: 6px; }
.tips .icon { color: var(--c-ok-fg); margin-top: 1px; }
.upload-status .progress { max-width: 240px; }
.upload-status.is-ready .progress > span, .upload-status.is-review .progress > span { background: var(--c-ok-fg); }
.upload-status.is-failed .progress > span { background: var(--c-danger); }
.pct-15 { width: 15%; } .pct-45 { width: 45%; } .pct-75 { width: 75%; } .pct-100 { width: 100%; }

/* ------------------------------------------------------------ detail pages */
.detail-grid { display: grid; gap: 20px; margin-top: 8px; }
@media (min-width: 768px) { .detail-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px; align-items: start; } .detail-media { position: sticky; top: 24px; } }
.tile-lg { border-radius: var(--r-card); }
.tile-lg > img { padding: 8%; }
.chip-wrap { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-wrap label { display: inline-flex; }
.narrow { max-width: 480px; margin: 0 auto; }
.tile-empty { background: var(--c-surface-2); }
.fav.is-on .icon { fill: var(--c-accent); stroke: var(--c-accent-fg); }
.look-card { display: block; }
.look-card .collage { border-radius: var(--r-card); }
.look-meta { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-top: 8px; }
.look-meta h2 { font: 700 15px/20px var(--font-body); }
.look-meta a { text-decoration: none; }
.grid-looks { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 768px) { .grid-looks { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .grid-looks { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.fav-only { width: 36px; padding: 0; }

/* ------------------------------------------------------------ look builder */
.builder { display: grid; gap: 20px; }
@media (min-width: 900px) { .builder { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); align-items: start; } .builder-side { position: sticky; top: 24px; } }
.slots { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.slot { width: 100%; aspect-ratio: 3 / 4; }
.slot .slot-body { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.slot.is-filled .slot-body { position: absolute; inset: 0; }
.slot.is-filled .tile { width: 100%; height: 100%; border-radius: 0; }
.slot-count { position: absolute; top: 6px; right: 6px; z-index: 1; padding: 2px 7px; border-radius: var(--r-pill); background: var(--c-ink); color: var(--c-surface); font-size: 11px; font-weight: 700; }
.slot:hover { border-color: var(--c-ink); color: var(--c-ink); }
.recent-strip { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
.recent-strip::-webkit-scrollbar { display: none; }
.recent-pick { width: 64px; flex: none; border-radius: var(--r-tile); }
.recent-pick .tile { border-radius: 10px; }
.recent-pick.is-picked .tile { outline: 2px solid var(--c-ink); outline-offset: -2px; }
.pick-grid { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (min-width: 640px) { .pick-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.pick { display: block; cursor: pointer; position: relative; }
.pick .tile { transition: outline-color var(--t-fast) var(--ease); outline: 2px solid transparent; outline-offset: -2px; }
.pick input:checked + .tile { outline-color: var(--c-ink); }
.pick input:focus-visible + .tile { outline: 2px solid var(--c-accent); outline-offset: 2px; }
.pick-mark { position: absolute; top: 6px; right: 6px; display: none; width: 24px; height: 24px; border-radius: 50%; background: var(--c-ink); color: var(--c-surface); align-items: center; justify-content: center; }
.pick input:checked + .tile .pick-mark { display: inline-flex; }
.pick-mark .icon { width: 16px; height: 16px; stroke-width: 2.4; }
.sheet { visibility: hidden; transition: transform var(--t) var(--ease), visibility 0s linear var(--t); }
.sheet.is-open { visibility: visible; transition: transform var(--t) var(--ease), visibility 0s; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; position: sticky; top: -8px; background: var(--c-surface); padding: 4px 0; z-index: 1; }
.has-sheet, .has-sheet body { overflow: hidden; }
.piece-list > li + li { border-top: 1px solid var(--c-line); }
.piece-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; min-height: 56px; }
.piece-row .icon { color: var(--c-muted); }
.w-12 { width: 48px; flex: none; }
.w-12 .tile { border-radius: 8px; }
.w-12 .tile > img { padding: 8%; }
.tryon-thumb { object-fit: cover !important; padding: 0 !important; }
@media (max-width: 767px) { .detail-media .collage, .detail-media .tile-lg { max-width: 360px; margin: 0 auto; } }
/* dashed outlines need 3:1 against the page: use the muted ink, not the line color */
.slot:not(.is-filled), .dropzone { border-color: var(--c-muted); }
.slots { max-width: 520px; }

/* ------------------------------------------------------------ mirror: try-on */
.mirror-layout { display: grid; gap: 24px; }
@media (min-width: 900px) { .mirror-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.glass {
  position: relative; width: 100%; max-width: 440px; margin: 0 auto; aspect-ratio: 3 / 4; overflow: hidden;
  border: 1px solid var(--mirror-line); border-radius: 220px 220px 24px 24px;
  background: linear-gradient(180deg, var(--mirror-glass-1), var(--mirror-glass-2));
}
.glass > img { width: 100%; height: 100%; object-fit: contain; }
.glass-dim { opacity: .35; filter: blur(1px); }
.glass-note { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 24px; text-align: center; }
.glass-note .alert { text-align: left; }
.mirror-panel { max-width: 440px; width: 100%; margin: 0 auto; }
.photo-pick { display: flex; gap: 8px; flex-wrap: wrap; }
.photo-pick .tile { border-radius: 10px; }
.suggest-grid { display: grid; gap: 12px; }
@media (min-width: 768px) { .suggest-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.w-60 { width: 60%; }
.block { display: block; }


/* ------------------------------------------------- Semana, Diário, Eu, Turma */
.chip-sm { height: 24px; padding: 0 10px; font-size: 11px; font-weight: 700; }
.day-row { cursor: pointer; transition: background var(--t-fast) var(--ease); }
.day-row:hover { background: var(--c-surface-2); }
.day-row .chip-sm { background: var(--c-ink); color: var(--c-surface); }
.plan-list > li + li { border-top: 1px solid var(--c-line); }
.plan-option { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px 4px; cursor: pointer; border-radius: var(--r-input); }
.plan-option:hover { background: var(--c-surface-2); }
.plan-option input { flex: none; }
.plan-none { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 40px; border-radius: 6px; border: 1.5px dashed var(--c-muted); color: var(--c-muted); }
.avatar-lg { width: 56px; height: 56px; font-size: 24px; flex: none; }
.break-all { overflow-wrap: anywhere; }
.new-photo { aspect-ratio: 3 / 4; }
.segmented-option { display: inline-flex; position: relative; }
.segmented-option span { display: inline-flex; align-items: center; justify-content: center; min-width: 84px; height: 30px; padding: 0 12px; border-radius: var(--r-pill); color: var(--c-muted); font-size: 13px; font-weight: 700; cursor: pointer; }
.segmented-option input:checked + span { background: var(--c-ink); color: var(--c-bg); }
.segmented-option input:focus-visible + span { outline: 2px solid var(--c-accent); outline-offset: 2px; }
.segmented:has(.segmented-option) { height: auto; }
.danger-zone { border-color: var(--c-danger-bg); }
.stat-grid { display: grid; gap: 12px; }
@media (min-width: 640px) { .stat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.stat { font-size: 28px; line-height: 34px; margin-top: 4px; }
.nowrap { white-space: nowrap; }
.min-w-60 { min-width: 240px; }
.quota-form { display: grid; gap: 8px; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; }
.quota-form .btn { grid-column: 1 / -1; justify-self: start; }
@media (min-width: 768px) { .quota-form { grid-template-columns: repeat(3, minmax(0, 140px)) auto; } .quota-form .btn { grid-column: auto; } }
.copy-block { display: flex; gap: 8px; align-items: flex-start; flex-wrap: wrap; }
.copy-block pre { flex: 1 1 260px; margin: 0; }
.tile-flat { border-radius: 0; }
.table th[scope="row"] { color: var(--c-ink); }
.segmented-option span { white-space: nowrap; min-width: 0; padding: 0 14px; }

/* ------------------------------------------------------------- error pages */
.error-page { padding-top: 48px; }
.error-code { font-size: 64px; line-height: 1; color: var(--c-line); margin: 24px 0 8px; }
