/* ═══════════════════════════════════════════════════════════════════════════
   BOXY · DARK — the parts of the language that are not a colour

   Everything this file does could not be done by changing a token, and that
   is the only reason any of it is here. The ground's lift, the button ramp,
   the tile a slab sits on and the plate under the current tab are shapes and
   images, not values — the rest of the redraw lives in palette.css, where the
   card sheen rides inside `--surface` and the lit top edge rides inside
   `--shadow`, and therefore reached all ten screens without being listed.

   EVERY RULE IS SCOPED TO ONE COMBINATION. `[data-layout="boxy"]
   [data-theme="dark"]` — boxy light and both minimal themes never see a line
   of it. It loads LAST on each page, after the page's own stylesheet, because
   several of the buttons below write `background: var(--accent)` in a
   shorthand that would otherwise blank the ramp out from under them.

   MINIMAL PAGES DO NOT LOAD THIS. Flipping the layout navigates to the file
   drawn the other way (concepts.js), so a `-min` screen is never boxy and a
   stylesheet that could only ever be inert there is not linked there.

   Source: img/sample-ui.png, folded in by changes/0037.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── The ground ────────────────────────────────────────────────────────────
   A single soft lift behind the header, falling away by the top third. The
   reference's phones are not one flat dark — they are lit from above, and it
   is what stops a screen of dark cards on a dark field reading as a hole. */

[data-layout="boxy"][data-theme="dark"] .cb .phone {
  background:
    radial-gradient(128% 58% at 50% -6%, #1B2A3E 0%, rgba(27, 42, 62, 0) 64%),
    var(--ground);
}

/* ── The thing to tap ──────────────────────────────────────────────────────
   One ramp, every primary action in the app. These are the buttons that
   already painted themselves `var(--accent)`; the ramp goes over that fill
   rather than replacing it, so the flat accent stays the fallback and the
   `:active` rules below each of them keep working — they set a colour, and
   the image on top of it is ours.

   WHITE, LIKE THE REFERENCE, WHICH COST THE RAMP A STEP OF BRIGHTNESS. White
   needs 4.5:1 against the lightest end of a gradient, not its average, and
   the image's #2F80ED measures 4.1:1 at 15px. `--accent-grad` stops at
   #2A78CE — 4.55:1 — which is a shade deeper than the image and the reason
   these read richer than they look there. */

[data-layout="boxy"][data-theme="dark"] .cb-go,
[data-layout="boxy"][data-theme="dark"] .cl-add,
[data-layout="boxy"][data-theme="dark"] .cl-duego,
[data-layout="boxy"][data-theme="dark"] .cl-sheet-go,
[data-layout="boxy"][data-theme="dark"] .cd-live-go,
[data-layout="boxy"][data-theme="dark"] .cd-send,
[data-layout="boxy"][data-theme="dark"] .cs-act--go,
[data-layout="boxy"][data-theme="dark"] .cs-sheet-go,
[data-layout="boxy"][data-theme="dark"] .cs-mic,
[data-layout="boxy"][data-theme="dark"] .cs-send,
[data-layout="boxy"][data-theme="dark"] .rd-go,
[data-layout="boxy"][data-theme="dark"] .rq-sheet-go,
[data-layout="boxy"][data-theme="dark"] .sk-scan,
[data-layout="boxy"][data-theme="dark"] .sk-act--send,
[data-layout="boxy"][data-theme="dark"] .lg-go,
[data-layout="boxy"][data-theme="dark"] .pf-save,
[data-layout="boxy"][data-theme="dark"] .pf-photo-btn,
[data-layout="boxy"][data-theme="dark"] .cb-btn--go {
  background-image: var(--accent-grad);
  color: var(--on-grad);
}

/* The press was a colour swap under a shorthand that no longer reaches the
   image. Dimming the whole ramp says the same thing and says it on all
   seventeen at once. */
[data-layout="boxy"][data-theme="dark"] .cb-go:active,
[data-layout="boxy"][data-theme="dark"] .cl-add:active,
[data-layout="boxy"][data-theme="dark"] .cl-duego:active,
[data-layout="boxy"][data-theme="dark"] .cl-sheet-go:active,
[data-layout="boxy"][data-theme="dark"] .cd-live-go:active,
[data-layout="boxy"][data-theme="dark"] .cd-send:active,
[data-layout="boxy"][data-theme="dark"] .cs-act--go:active,
[data-layout="boxy"][data-theme="dark"] .cs-sheet-go:active,
[data-layout="boxy"][data-theme="dark"] .cs-mic:active,
[data-layout="boxy"][data-theme="dark"] .cs-send:active,
[data-layout="boxy"][data-theme="dark"] .rd-go:active,
[data-layout="boxy"][data-theme="dark"] .rq-sheet-go:active,
[data-layout="boxy"][data-theme="dark"] .sk-scan:active,
[data-layout="boxy"][data-theme="dark"] .sk-act--send:active,
[data-layout="boxy"][data-theme="dark"] .lg-go:active,
[data-layout="boxy"][data-theme="dark"] .pf-save:active,
[data-layout="boxy"][data-theme="dark"] .pf-photo-btn:active,
[data-layout="boxy"][data-theme="dark"] .cb-btn--go:active {
  filter: brightness(.86);
}

/* ── The slab tiles ────────────────────────────────────────────────────────
   Rounder, and lifted off the panel they sit in. The reference never shows a
   photograph as a bare square — it is always a tile, and the tile is what
   makes a strip of three thumbnails read as objects rather than as a filmstrip.
   The hairline around each is already the glass one: `--line` is translucent
   white in this combination, so it lands on a card and on the lit top card
   without being mixed twice. */

[data-layout="boxy"][data-theme="dark"] .cb-look-img,
[data-layout="boxy"][data-theme="dark"] .cl-thumbs img,
[data-layout="boxy"][data-theme="dark"] .cd-mat img,
[data-layout="boxy"][data-theme="dark"] .cd-t img,
[data-layout="boxy"][data-theme="dark"] .cs-t img,
[data-layout="boxy"][data-theme="dark"] .cs-nowbar img,
[data-layout="boxy"][data-theme="dark"] .sk-shot,
[data-layout="boxy"][data-theme="dark"] .sk-hero img {
  border-radius: var(--r-tile);
  box-shadow: 0 4px 12px -6px rgba(0, 0, 0, .85);
}

/* A quote or request line's photo keeps the 7px corner (DEC-26). */
[data-layout="boxy"][data-theme="dark"] .rd-line-img {
  border-radius: 7px;
  box-shadow: 0 4px 12px -6px rgba(0, 0, 0, .85);
}

/* The trail behind her is 33px on a queue row and 53px on the top card;
   both take the tile's 7px, the ceiling (DEC-26). */
[data-layout="boxy"][data-theme="dark"] .cb-past-img,
[data-layout="boxy"][data-theme="dark"] .cb-now .cb-past-img { border-radius: 7px; }

/* ── The square tiles that are not photographs ─────────────────────────────
   A person's initials, a client's face in the rail, the brand mark in the
   bar. All three were 5px, which is the radius of the old language; they
   move together at the 7px ceiling (DEC-26) or they stop looking like one
   family. */

[data-layout="boxy"][data-theme="dark"] .cb-avatar,
[data-layout="boxy"][data-theme="dark"] .cb-avatar-img { border-radius: 7px; }

[data-layout="boxy"][data-theme="dark"] .cb-chat-face { border-radius: var(--r-tile); }

/* The mark is the app's own icon, and in the reference an app icon is the one
   thing that always wears the ramp. */
[data-layout="boxy"][data-theme="dark"] .cb-mark {
  border-radius: 7px;
  background-image: var(--accent-grad);
}

/* ── The bar ───────────────────────────────────────────────────────────────
   The current tab sits on a plate. `--accent-wash` and not the ramp: the icon
   keeps its own accent colour, which a bright plate underneath would have
   taken from it, and the tab bar is a place you read rather than press. */

[data-layout="boxy"][data-theme="dark"] .cb-tab.is-on .cb-ico {
  border-radius: 7px;
  box-shadow: 0 0 0 6px var(--accent-wash);
}

/* ── The numbers on the board ──────────────────────────────────────────────
   The reference prints every figure that matters in accent blue — a price, a
   count, a total — and lets the words around it stay quiet. Here the figures
   are clocks: how long she has been in the room, how long on this slab, where
   she ranks. They are 15–17px and bold, which is large text, so 4.5:1 on the
   lit top card is not required and 4.46:1 is what they measure there.

   Only the board's, deliberately. Every other screen keeps its numerals in
   `--ink` until each is looked at in this combination on its own terms —
   see the change file. */

[data-layout="boxy"][data-theme="dark"] .cb-rank,
[data-layout="boxy"][data-theme="dark"] .cb-row-time b,
[data-layout="boxy"][data-theme="dark"] .cb-look-time b {
  color: var(--accent);
}
