/*
  OrderHub's look: Ultimate Crate's light and dark colours, and its accent colour.
  - <html data-theme="light|dark|system"> picks the set (Settings > Appearance). "system" follows
    the device's own light / dark setting.
  - The accent shades (--accent, --accent-hover, --accent-down, --accent-soft, --accent-soft2,
    --on-accent) come from Appearance.cs, made from the one colour picked.
  Change a colour here and every page follows.
*/

/* ---------- dark (the default) ---------- */
/* .theme-dark / .theme-light: one part of a page in the other look (the Calendar's own setting) */
:root, .theme-dark {
    --bg: #121417;           /* page background */
    --panel: #1A1D22;         /* cards, top bar */
    --panel2: #20242A;        /* table headers, group boxes */
    --input: #262A31;         /* text boxes, drop-downs */
    --input-border: #3A3F48;
    --track: #2C3038;
    --cal-head: #3A404A;        /* the Calendar's weekday strip, lighter than the days (owner, 2026-10-27) */
    --cal-other: #16181C;       /* days of the month before / after */
    --line: #2A2E35;
    --button: #39404B;          /* lighter than the text boxes, so a button never looks like one (owner, 2026-11-10) */
    --button-hover: #444C58;
    --button-down: #2A2F37;
    --button-border: #555E6B;
    --button-shadow: 0 1px 3px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .06);
    --input-shadow: inset 0 1px 3px rgba(0, 0, 0, .35);
    --text: #ECEEF1;
    --subtext: #9AA1AB;
    --dim: #6C737D;
    --warn: #E8A33C;
    --bad: #E5534B;
    --good: #3FB950;
    color-scheme: dark;
}
:root {
    /* until Appearance.cs's <style> arrives */
    --accent: #2F80ED; --accent-hover: #4E93F0; --accent-down: #2769C2;
    --accent-soft: rgba(47,128,237,.2); --accent-soft2: rgba(47,128,237,.333); --on-accent: #FFFFFF;
}

/* ---------- light ---------- */
:root[data-theme="light"], .theme-light {
    --bg: #F4F5F7;
    --panel: #FFFFFF;
    --panel2: #ECEEF1;
    --input: #FFFFFF;
    --input-border: #C6CBD3;
    --track: #D9DDE3;
    --cal-head: #C4CAD3;        /* darker than the days in light mode */
    --cal-other: #D3D8DF;
    --line: #E0E3E8;
    --button: #E4E8ED;
    --button-hover: #D7DCE3;
    --button-down: #C9CED6;
    --button-border: #A9B1BC;
    --button-shadow: 0 1px 2px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255, 255, 255, .7);
    --input-shadow: inset 0 1px 2px rgba(0, 0, 0, .08);
    --text: #16181C;
    --subtext: #5A626D;
    --dim: #9AA1AB;
    --warn: #A85F00;
    --bad: #C33A35;
    --good: #2A8A3B;
    color-scheme: light;
}

@media (prefers-color-scheme: light) {
    :root[data-theme="system"] {
        --bg: #F4F5F7;
        --panel: #FFFFFF;
        --panel2: #ECEEF1;
        --input: #FFFFFF;
        --input-border: #C6CBD3;
        --track: #D9DDE3;
        --cal-head: #C4CAD3;        /* darker than the days in light mode */
        --cal-other: #D3D8DF;
        --line: #E0E3E8;
        --button: #E4E8ED;
        --button-hover: #D7DCE3;
        --button-down: #C9CED6;
        --button-border: #A9B1BC;
        --button-shadow: 0 1px 2px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255, 255, 255, .7);
        --input-shadow: inset 0 1px 2px rgba(0, 0, 0, .08);
        --text: #16181C;
        --subtext: #5A626D;
        --dim: #9AA1AB;
        --warn: #A85F00;
        --bad: #C33A35;
        --good: #2A8A3B;
        color-scheme: light;
    }
}

/* ---------- basics ---------- */
:root {
    font-family: "Segoe UI", system-ui, -apple-system, Roboto, "Inter", sans-serif;
    font-size: 15px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
a { color: var(--link, var(--accent)); }               /* --link: Settings > Appearance > Link colour, else the accent */
a:hover { color: var(--link-hover, var(--accent-hover)); }
h1 { font-size: 1.5rem; margin: 0 0 16px; font-weight: 600; }
h2 { font-size: 1.05rem; margin: 0 0 8px; font-weight: 600; }
h1:focus { outline: none; }
.hint { color: var(--subtext); font-size: 0.9em; }
pre, code { font-family: Consolas, "Cascadia Mono", monospace; }
pre { background: var(--input); border: 1px solid var(--input-border); border-radius: 4px; padding: 10px 12px; overflow-x: auto; }

/* ---------- top bar and menu ---------- */
.topbar {
    position: sticky; top: 0; z-index: 10;
    display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
    background: var(--panel); border-bottom: 1px solid var(--line);
    padding: 0 16px; min-height: 52px;
}
.brand { color: var(--text); text-decoration: none; font-weight: 600; font-size: 1.15rem; white-space: nowrap; }
.brand span, .login h1 span { color: var(--accent); }
.menu { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; flex: 1; }
.menu a { color: var(--text); text-decoration: none; padding: 8px 10px; border-radius: 4px; }
.menu a:hover { background: var(--button-hover); color: var(--text); }
.menu a.active { background: var(--accent); color: var(--on-accent); }
.signout { margin-left: auto; }
.menu-toggle, .menu-button { display: none; }

@media (max-width: 860px) {
    .menu-button {
        display: block; margin-left: auto; cursor: pointer; font-size: 1.6rem;
        color: var(--text); padding: 4px 8px; user-select: none;
    }
    .menu { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; padding-bottom: 10px; }
    .menu a { padding: 12px 10px; }
    .menu-toggle:checked ~ .menu { display: flex; }
    .signout { margin-left: 0; }
    .signout button { width: 100%; }
}

/* ---------- page and cards ---------- */
.page { max-width: 1100px; margin: 0 auto; padding: 20px 16px 40px; }
/* the booking lists with Expenses and Net: room for them, so the other columns keep their size (owner, 2026-11-01) */
.page:has(.wide-list) { max-width: 1300px; }
.card {
    background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
    padding: 16px; margin-bottom: 16px;
}
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.checklist { margin: 0; padding-left: 20px; line-height: 1.9; }
.links { list-style: none; margin: 0 0 8px; padding: 0; }
.links li { padding: 8px 0; border-bottom: 1px solid var(--line); display: flex; gap: 12px; flex-wrap: wrap; align-items: baseline; }
.links li a { min-width: 100px; font-weight: 600; }
/* a line that opens like a list row (Settings, owner 2026-11-08): the whole line is clickable and lights up like a list row */
.links li.link { cursor: pointer; padding: 8px 8px; margin: 0 -8px; border-radius: 4px; }
.links li.link:hover { background: var(--row-hover, var(--accent-soft)); }
@media (hover: hover) and (pointer: fine) { .links li.link a.row-link { text-decoration: none; } }
.soon p:first-child { margin-top: 0; }

/* ---------- forms ---------- */
label { display: block; margin: 12px 0 4px; color: var(--subtext); }
input[type=text], input[type=password], input[type=email], input[type=tel], input[type=number], input[type=date], input[type=time], select, textarea {
    /* shorter boxes, the buttons the same height (owner, 2026-11-11: "shrink text box height and make buttons to match"): 34px */
    width: 100%; padding: 6px 10px; font: inherit; line-height: 1.25; color: var(--text);
    background: var(--input); border: 1px solid var(--input-border); border-radius: 4px; box-shadow: var(--input-shadow);
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
/* ComboInput: suggestions right under the box */
.combo { position: relative; }
.combo-list {
    position: absolute; left: 0; right: 0; top: calc(100% + 2px); z-index: 20; margin: 0; padding: 4px 0; list-style: none;
    max-height: 260px; overflow-y: auto; background: var(--input); border: 1px solid var(--input-border); border-radius: 4px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .25);
}
.combo-list li { padding: 8px 12px; cursor: pointer; }
.combo-list li:hover, .combo-list li.on { background: var(--accent-soft); }
.combo-list li.none, .combo-list li.none:hover { cursor: default; color: var(--subtext); background: none; }
.inline .combo { flex: 1; min-width: 160px; }
/* MoneyInput: "$" inside the box, right beside the number ("$350.00") */
.money-input { position: relative; display: block; }
.money-input .cur { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text); pointer-events: none; }
.money-input input[type=number] { padding-left: 21px; text-align: left; }
table.edit .money-input .cur { left: 8px; }
table.edit .money-input input[type=number] { padding-left: 17px; }
button {
    font: inherit; color: var(--text); background: var(--button); border: 1px solid var(--input-border);
    border-radius: 4px; padding: 6px 12px; line-height: 1.25; cursor: pointer;
}
button:hover { background: var(--button-hover); }
button:active { background: var(--button-down); }
button.danger { border-color: var(--bad); color: var(--bad); }
.error { color: var(--text); background: color-mix(in srgb, var(--bad) 15%, transparent); border-left: 3px solid var(--bad); padding: 8px 10px; }
.saved { color: var(--text); background: color-mix(in srgb, var(--good) 15%, transparent); border-left: 3px solid var(--good); padding: 8px 10px; }
/* orderhub.js fades a .saved note away after a few seconds */
.saved[data-gone] { opacity: 0; transition: opacity 0.6s; }
.saved[data-gone="1"] { display: none; }
.row-end { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }

/* radio choices shown as buttons (light / dark) */
.choices { display: flex; gap: 6px; flex-wrap: wrap; }
.choices label { margin: 0; }
.choices input { position: absolute; opacity: 0; pointer-events: none; }
.choices span {
    display: inline-block; padding: 8px 14px; border-radius: 4px; cursor: pointer; color: var(--text);
    background: var(--button); border: 1px solid var(--input-border);
}
.choices input:checked + span { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.choices input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* accent swatches */
.swatches { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.swatches label { margin: 0; }
.swatches input { position: absolute; opacity: 0; pointer-events: none; }
.swatches span {
    display: block; width: 32px; height: 32px; border-radius: 50%; cursor: pointer;
    border: 2px solid transparent; box-shadow: inset 0 0 0 2px var(--panel);
}
.swatches input:checked + span { border-color: var(--text); }
.swatches input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.custom-accent { display: flex; gap: 8px; align-items: center; margin-top: 10px; }
.custom-accent input { width: 130px; }

/* ---------- sign in ---------- */
.bare { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; }
.login { width: 100%; max-width: 380px; }
.login h1 { margin-bottom: 2px; }
.login .sub { margin: 0 0 8px; color: var(--subtext); }
.login button.primary { width: 100%; margin-top: 16px; padding: 12px; font-size: 1.05rem; }
.password { display: flex; gap: 6px; }
.password input { flex: 1; }
.password .eye { padding: 0 12px; font-size: 1.1rem; }

/* ---------- tables ---------- */
table.list { width: 100%; border-collapse: collapse; }
table.list th { text-align: left; color: var(--subtext); font-weight: 600; background: var(--panel2); padding: 6px 8px; }
table.list td { border-bottom: 1px solid var(--line); padding: 8px; vertical-align: middle; }
table.list tr.off td { color: var(--dim); }
table.list tr.bad td { color: var(--bad); }
table.list form { margin: 0; }
.tag { background: var(--accent-soft2); color: var(--text); border-radius: 3px; padding: 1px 6px; font-size: 0.8em; margin-left: 6px; }

@media (max-width: 640px) {
    table.list:not(.figures) thead { display: none; }
    table.list:not(.figures) tr { display: block; border-bottom: 1px solid var(--line); padding: 6px 0; }
    table.list:not(.figures) td { display: block; border: none; padding: 2px 0; }
    /* Tables of figures (Reports) keep their columns: smaller, and they scroll sideways in their card if still too wide. */
    table.list.figures { font-size: 0.8em; }
    table.list.figures th, table.list.figures td { padding: 6px 4px; }
}
.figures-wrap { overflow-x: auto; }

/* ---------- Blazor's own messages ---------- */
.blazor-error-boundary { background: var(--bad); padding: 1rem; color: white; }
.blazor-error-boundary::after { content: "Something went wrong on this page."; }

/* ---------- step 3: lists, forms, bookings ---------- */
.page-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head h1 { margin: 0; flex: 1; }
/* on a phone the heading has its own line and the status and buttons sit in a row under it, not scattered between the
   heading's wrapped words (owner, 2026-11-09: Book Again and Email Customer looked out of line) */
@media (max-width: 640px) {
    .page-head { gap: 8px; }
    .page-head h1 { flex-basis: 100%; }
    /* a little tighter, so the status, Book Again and Email Customer fit one row on a phone */
    .page-head > .button, .page-head > button { white-space: nowrap; padding: 7px 10px; font-size: 0.92em; }
}
a.button, .button {
    display: inline-block; font: inherit; text-decoration: none; color: var(--text); background: var(--button);
    border: 1px solid var(--button-border); border-radius: 6px; padding: 6px 12px; line-height: 1.25; cursor: pointer;
    box-shadow: var(--button-shadow); font-weight: 600;
}
a.button:hover, .button:hover { background: color-mix(in srgb, var(--accent) 24%, var(--button)); border-color: var(--accent); color: var(--text); }
a.button:focus-visible, label.button:has(:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; border-color: var(--accent); }
a.button:active, .button:active { background: color-mix(in srgb, var(--accent) 36%, var(--button-down)); box-shadow: none; }

.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.filters input[type=text], .filters select { width: auto; min-width: 140px; flex: 1; max-width: 260px; padding: 6px 10px; }

table.list tbody tr.link { cursor: pointer; }
table.list tbody tr.link:hover td { background: var(--accent-soft); }
table.list td.num, table.list th.num { text-align: right; white-space: nowrap; }
table.list td.when { white-space: nowrap; }
/* a window too narrow for every column: tighter first, then only the table scrolls, never the page (owner, 2026-11-02) */
.table-scroll { overflow-x: auto; }
/* A list's column headings stay at the top, under the menu bar, as the page scrolls (owner, 2026-11-08). --topbar-h comes from
   orderhub.js. A box that scrolls sideways stops that, so .table-scroll only scrolls when its table is too wide (.fits, orderhub.js);
   a list in its own scrolling box (pop-ups, pickers) sticks to the top of that box. */
table.list thead th { position: sticky; top: var(--topbar-h, 52px); z-index: 4; }
.table-scroll.fits { overflow-x: visible; }
/* a table too wide to fit scrolls sideways in its box, and sticky headings there slid down over the rows (2026-11-08): not sticky */
.table-scroll:not(.fits) table.list thead th { position: static; }
/* not on Reports (owner, 2026-11-08: "doesn't need to stick on that tab"); its figures scroll sideways in .figures-wrap, which
   pushed the sticky headings down over the rows */
.page:has(table.list.figures) table.list thead th { position: static; }
.dialog table.list thead th, .pick-booking-list table.list thead th, .picker-rows table.list thead th,
.date-pick-scroll table.list thead th, .combo-list table.list thead th, .email-preview table.list thead th { top: 0; }
@media (min-width: 641px) and (max-width: 1240px) {
    table.wide-list th, table.wide-list td { padding-left: 4px; padding-right: 4px; }
}
table.list td.negative { color: var(--bad); }
.phone-only, .phone-zero { display: none; }
/* on a phone: the label, then the amount, lined up down the row (Blazor drops the space inside the label's span) */
@media (max-width: 640px) {
    .phone-only { display: inline-block; min-width: 5.5em; color: var(--subtext); }
    .phone-zero { display: inline; }
    .wide-zero { display: none; }
    table.list td.num:has(.phone-only) { text-align: left; }
}
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: baseline; }
.status { font-size: 0.85em; padding: 1px 8px; border-radius: 10px; background: var(--button); white-space: nowrap; }
.status.Confirmed { background: color-mix(in srgb, var(--good) 25%, transparent); }
.status.Tentative { background: color-mix(in srgb, var(--warn) 25%, transparent); }
.status.Cancelled { background: color-mix(in srgb, var(--bad) 20%, transparent); text-decoration: line-through; }
.status.Completed { background: var(--accent-soft2); }
.empty { color: var(--subtext); padding: 12px 0; }

/* forms laid out in columns, one column on a phone */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; }
.grid .wide { grid-column: 1 / -1; }
textarea { min-height: 80px; resize: vertical; }
label.check { display: flex; gap: 8px; align-items: center; color: var(--text); margin: 8px 0; cursor: pointer; }
label.check input { width: 18px; height: 18px; margin: 0; flex: none; } /* flex: none, or a wrapped label squeezes the box */
.checks { display: flex; gap: 4px 18px; flex-wrap: wrap; }
.inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline select, .inline input { flex: 1; min-width: 160px; }
.sub-card { background: var(--panel2); border-radius: 6px; padding: 4px 12px 12px; margin-top: 8px; }
.warning { color: var(--text); background: color-mix(in srgb, var(--warn) 18%, transparent); border-left: 3px solid var(--warn); padding: 8px 10px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
.actions .spacer { flex: 1; }
.loading { color: var(--subtext); padding: 20px 0; }

/* tabs on a booking */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tabs button { background: none; border: none; border-bottom: 3px solid transparent; border-radius: 0; padding: 10px 14px; color: var(--subtext); }
.tabs button:hover { background: var(--button-hover); color: var(--text); }
.tabs button.on { color: var(--text); border-bottom-color: var(--accent); font-weight: 600; }
/* on a phone the booking's five tabs fit on one row: less padding, spread evenly, the words a touch smaller (owner, 2026-11-09:
   they had to be scrolled); the box still scrolls sideways on a really narrow screen */
@media (max-width: 640px) {
    .tabs { gap: 0; }
    .tabs button { flex: 1 1 auto; padding: 10px 3px; font-size: 0.93em; white-space: nowrap; }
}

/* gig type and event type editors */
table.edit td { padding: 4px; }
table.edit input[type=text], table.edit input[type=number] { padding: 6px 8px; }
table.edit input[type=color] { width: 44px; height: 34px; padding: 0; border: 1px solid var(--input-border); background: none; }
.choices input:checked + span .dot { box-shadow: 0 0 0 2px var(--on-accent); }

/* ---------- expenses: the camera button and receipt photos ---------- */
label.button { display: inline-block; margin: 0; color: var(--text); }
label.button:hover { background: color-mix(in srgb, var(--accent) 24%, var(--button)); }


/* ---------- buttons look like buttons (owner, 2026-11-10) ----------
   "buttons should look different then text boxes too, across the entire app", and no blue main buttons anywhere: "the highlight
   can use the blue (or whatever theme color is active)". Every ordinary button (no class, or .primary / .danger / .small / the
   Documents tab's .doc-make / .doc-open) is raised: lighter than a text box, a firm border, bold, a small shadow, rounder corners.
   Hover and keyboard focus show the theme's accent. .primary still marks the main button (Enter, orderhub.js) but looks the same.
   button:where(...) has a plain button's weight, so a rule for a place (".tabs button", calendar days, the eye ...) still wins. */
button:where(:not([class]), .primary, .danger, .small, .doc-make, .doc-open) {
    background: var(--button); color: var(--text); border: 1px solid var(--button-border); box-shadow: var(--button-shadow);
    font-weight: 600; border-radius: 6px;
}
button:where(:not([class]), .primary, .danger, .small, .doc-make, .doc-open):hover {
    background: color-mix(in srgb, var(--accent) 24%, var(--button)); border-color: var(--accent);
}
button:where(:not([class]), .primary, .danger, .small, .doc-make, .doc-open):focus-visible {
    outline: 2px solid var(--accent); outline-offset: 2px; border-color: var(--accent);
}
button:where(:not([class]), .primary, .danger, .small, .doc-make, .doc-open):active {
    background: color-mix(in srgb, var(--accent) 36%, var(--button-down)); box-shadow: none;
}
button.danger { border-color: var(--bad); color: var(--bad); }
button.danger:hover { border-color: var(--bad); background: color-mix(in srgb, var(--bad) 16%, var(--button)); }
/* red stays red (owner, 2026-11-10: "i want red kept"): hover, keyboard and pressed in red, not the theme colour */
button.danger:focus-visible { outline-color: var(--bad); border-color: var(--bad); }
button.danger:active { background: color-mix(in srgb, var(--bad) 28%, var(--button-down)); }
.camera { font-size: 1.1rem; padding: 14px 18px; }
@media (max-width: 640px) { .camera { display: block; text-align: center; margin-bottom: 8px; } }
.photos { display: flex; gap: 10px; flex-wrap: wrap; }
.photo { position: relative; width: 96px; height: 96px; border: 1px solid var(--line); border-radius: 6px; overflow: hidden;
         background: var(--panel2); display: flex; align-items: center; justify-content: center; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo .pdf { color: var(--subtext); font-size: 0.85em; text-align: center; }
/* a receipt looked at before its expense is saved (ExpenseEdit) */
.receipt-look { display: block; max-width: min(90vw, 700px); max-height: 70vh; margin: 0 auto; object-fit: contain; }
.photo button { position: absolute; top: 3px; right: 3px; padding: 0 7px; line-height: 1.4; }
/* a receipt not saved yet: its whole tile is the button that opens it (ExpenseEdit; a link would be taken for leaving the page) */
.photo button.look { position: static; width: 100%; height: 100%; padding: 0; border: 0; border-radius: 0; background: none; line-height: 1.2; cursor: pointer; }
.dialog label.button { cursor: pointer; }
.photo.add { cursor: pointer; font-size: 2rem; color: var(--subtext); }
.photo.add:hover { background: var(--button-hover); }

/* ---------- calendar ---------- */
.month { padding: 8px; overflow-x: auto; }
.month.theme-light, .month.theme-dark { color: var(--text); }
.cal-look { display: flex; gap: 6px; align-items: center; }
.cal-look .choices span { padding: 4px 10px; font-size: 0.9em; }
.month-grid { display: grid; grid-template-columns: repeat(7, minmax(44px, 1fr)); gap: 2px; }
.month-grid .dow { text-align: center; color: var(--text); font-size: 0.85em; font-weight: 600; padding: 5px 0; background: var(--cal-head);
                  box-shadow: 2px 0 0 var(--cal-head); }      /* fills the gap to the next one: one solid bar (owner, 2026-10-27) */
.month-grid .dow:first-child { border-radius: 4px 0 0 4px; }
.month-grid .dow:nth-child(7) { border-radius: 0 4px 4px 0; box-shadow: none; }
.month-grid .day { min-height: 92px; background: var(--panel2); border-radius: 4px; padding: 3px; display: flex; flex-direction: column; gap: 2px; min-width: 0;
                  border: 1px solid var(--track); }   /* the outline: in light mode the squares were lost on white (owner, 2026-10-27) */
.month-grid .day.other { background: var(--cal-other); opacity: 0.7; }   /* the months either side: darker, so this month stands out */
.month-grid .day.today .num { color: var(--accent); font-weight: 700; }   /* today: its number; the blue outline follows the picked day (owner, 2026-11-08) */
.month-grid .num { font-size: 0.8em; color: var(--subtext); }
.month-grid .ev { display: block; font-size: 0.78em; line-height: 1.25; padding: 2px 4px; border-radius: 3px; background: var(--panel);
                  border: none; border-left: 3px solid var(--accent); color: var(--text); text-decoration: none; text-align: left;
                  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; width: 100%; font-family: inherit; }
.month-grid .ev:hover { background: var(--button-hover); }
.month-grid .ev.cancelled { text-decoration: line-through; opacity: 0.6; }
.month-grid .ev.unlinked { border-left: 3px dashed var(--warn); font-style: italic; }
.month-grid .day { cursor: pointer; }
.month-grid .day.off { background: repeating-linear-gradient(135deg, var(--panel2), var(--panel2) 6px, var(--track) 6px, var(--track) 12px); }
.month-grid .day.picked { outline: 2px solid var(--accent); }
.month-grid .ev.unavailable { border-left-color: var(--dim); color: var(--subtext); cursor: default; }
@media (max-width: 640px) { .month-grid .day { min-height: 64px; } .month-grid .ev { font-size: 0.7em; } }

/* ---------- pop-up questions (Shared/Dialog.razor) ---------- */
.dialog-back { position: fixed; inset: 0; background: rgb(0 0 0 / 0.5); display: flex; align-items: center; justify-content: center;
               padding: 16px; z-index: 100; }
.dialog { width: 100%; max-width: 480px; margin: 0; box-shadow: 0 8px 30px rgb(0 0 0 / 0.4); max-height: 90vh; overflow-y: auto; }
.dialog h2 { margin-bottom: 10px; }
.dialog p:first-of-type { margin-top: 0; }

/* ---------- photos (Shared/Photos.razor) ---------- */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.gallery-item { background: var(--panel2); border-radius: 6px; overflow: hidden; display: flex; flex-direction: column; }
.gallery-item img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; background: var(--track); }
.gallery-item .cap { padding: 6px 8px; font-size: 0.85em; display: flex; gap: 6px; align-items: center; }
.gallery-item .cap span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.paste-zone { border: 2px dashed var(--input-border); border-radius: 6px; padding: 14px; text-align: center; color: var(--subtext); margin-top: 10px; }
.paste-zone:focus { outline: 2px solid var(--accent); border-color: var(--accent); }

/* ---------- sortable list headings ---------- */
table.list th.sort { cursor: pointer; user-select: none; white-space: nowrap; }
table.list th.sort:hover { color: var(--text); }
.tick-list { display: flex; gap: 2px 14px; flex-wrap: wrap; margin: 4px 0 8px; }
.tick-list label.check { margin: 4px 0; }
details.pick { position: relative; }
details.pick summary { list-style: none; cursor: pointer; padding: 6px 28px 6px 10px; min-width: 160px; border: 1px solid var(--input-border);
                       border-radius: 4px; background: var(--input); position: relative; }
details.pick summary::after { content: "▾"; position: absolute; right: 10px; color: var(--subtext); }
details.pick .pick-list { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; min-width: 260px; max-height: 60vh; overflow-y: auto;
                          background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 8px 12px;
                          box-shadow: 0 6px 20px rgb(0 0 0 / 0.3); }
details.pick .pick-list label.check { margin: 6px 0; }

/* the venue photos to put in the contract email (Documents tab) */
label.email-photos { margin: 10px 0 4px; }
.email-photos-pick { margin-left: 24px; }
.list-total { margin: 0 0 8px; color: var(--subtext); font-size: 0.9em; }
.photo-group { margin: 12px 0 6px; font-weight: 600; display: flex; gap: 14px; align-items: center; }
.photo-group label.check { font-weight: normal; margin: 0; }
.gallery.pickable { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.gallery.pickable .gallery-item { cursor: pointer; outline: 2px solid transparent; }
.gallery.pickable .gallery-item.on { outline-color: var(--accent); }
.gallery.pickable .cap { gap: 6px; }

/* a booking's song requests (Documents tab) */
.ok-note { color: var(--text); background: color-mix(in srgb, var(--good) 15%, transparent); border-left: 3px solid var(--good); padding: 8px 10px; }

/* Settings > Backup's folder picker */
.folder-picker { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin: 8px 0; }
.folder-picker .crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; margin-bottom: 8px; font-weight: 600; }
.folder-picker .crumbs .sep { color: var(--subtext); }
.folder-picker .crumbs .sep:last-child { display: none; }
.folder-picker button.crumb { background: none; border: none; padding: 2px 4px; color: var(--accent); font-weight: 600; cursor: pointer; }
.folder-picker .folders { display: flex; flex-direction: column; max-height: 320px; overflow-y: auto; margin-bottom: 8px; }
.folder-picker button.folder { text-align: left; background: none; border: none; border-radius: 6px; padding: 8px; color: var(--text); cursor: pointer; }
.folder-picker button.folder:hover { background: var(--button-hover); }

/* Settings > Appearance: the background picture */
.background-preview { display: block; max-width: 320px; width: 100%; max-height: 180px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); margin: 6px 0; }

/* Settings > Appearance: "Same as the accent" and "Custom" beside the link colour swatches */
.swatches .swatch-text { width: auto; height: auto; padding: 4px 10px; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px;
                         background: var(--button); color: var(--text); font-size: 0.9em; }
.swatches input[type=color] { position: static; opacity: 1; pointer-events: auto; width: 32px; height: 24px; padding: 0; border: none; background: none; cursor: pointer; }

/* Settings > Contract: the banner and divider, on white like the page they go on */
.contract-picture { display: block; max-width: 100%; background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 6px; margin-top: 4px; }

/* a booking's Documents tab: the invoice's buttons on one row, the receipt's on the next, each with its name in front */
.doc-row .doc-what { min-width: 70px; font-weight: 600; color: var(--subtext); }
/* the Invoice and Receipt rows' buttons line up, whatever their words ("Make the Invoice Again", "Make Partial Receipt"; owner, 2026-11-10) */
.doc-row .doc-make { min-width: 14em; text-align: center; white-space: nowrap; }
.doc-row .doc-open { min-width: 12em; text-align: center; white-space: nowrap; }
/* a signed copy waiting: approve / not right side by side, never split across lines, the same width */
.check-buttons { display: inline-flex; flex-wrap: nowrap; gap: 8px; vertical-align: middle; }
.check-buttons button, .check-buttons .button { min-width: 13em; white-space: nowrap; text-align: center; box-sizing: border-box; }
@media (max-width: 560px) {   /* a phone: still one line, each half of it */
    .check-buttons { display: flex; width: 100%; margin-top: 6px; }
    .check-buttons button, .check-buttons .button { flex: 1 1 0; min-width: 0; white-space: normal; }
}

/* the venue's "Other:" access tick with its own words beside it */
.check-other { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.check-other input[type=text] { width: 260px; max-width: 100%; }

/* a paste / drop zone with something dragged over it */
.paste-zone.dragging-over { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }

/* Settings > Business: the invoice number row (a narrow year, a wide pattern, the example) */
.grid.number-row { grid-template-columns: 170px minmax(260px, 2fr) minmax(170px, 1fr); }
@media (max-width: 700px) { .grid.number-row { grid-template-columns: 1fr; } }

/* a box with something wrong in it: red, with a note under it or on the page (owner, 2026-10-31) */
input.invalid, textarea.invalid, select.invalid { border-color: var(--bad); box-shadow: 0 0 0 1px var(--bad); background: color-mix(in srgb, var(--bad) 10%, var(--input)); }
.field-error { color: var(--bad); font-size: 0.85em; margin: 4px 0 0; }

/* Shared/MiniCalendar.razor: under a date box, and in the Book again pop-up */
.mini-cal { width: 266px; max-width: 100%; user-select: none; }
.mini-head { display: flex; align-items: center; gap: 2px; margin-bottom: 6px; }
.mini-head strong { flex: 1; text-align: center; font-size: 0.95em; }
.mini-head button { padding: 2px 8px; }
.mini-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.mini-dow { text-align: center; font-size: 0.8em; color: var(--subtext); padding: 2px 0; }
.mini-day { position: relative; padding: 6px 0; background: none; border: 1px solid transparent; }
.mini-day.today { border-color: var(--accent); }
.mini-day.on, .mini-day.on:hover { background: var(--accent); color: var(--on-accent); font-weight: 600; }
.mini-day.marked::after { content: ""; position: absolute; left: 50%; bottom: 2px; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--warn); }
.combo-list.mini-drop { right: auto; width: 282px; max-width: calc(100vw - 32px); max-height: none; overflow: visible; padding: 8px; background: var(--panel); }
/* a search box or filter with an x to clear it (Shared/ClearBox.razor) */
.filters .clear-box { position: relative; display: flex; flex: 1; min-width: 140px; max-width: 260px; }
.filters .clear-box input[type=text], .filters .clear-box select { width: 100%; max-width: none; min-width: 0; }
/* room for the x only while it shows, so a narrow box doesn't clip its words */
.filters .clear-box:has(.clear-x) input[type=text] { padding-right: 30px; }
.filters .clear-box:has(.clear-x) select { padding-right: 46px; }
.clear-x { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; padding: 0; line-height: 1;
           border: 0; border-radius: 50%; background: none; color: var(--subtext); font-size: 18px; cursor: pointer; }
.clear-x:hover { color: var(--text, inherit); background: rgba(127,127,127,.2); }
.clear-box select ~ .clear-x { right: 22px; }
.filters .clear-box details.pick { width: 100%; }
.clear-box:has(.clear-x) details.pick summary { padding-right: 50px; }
.clear-box details ~ .clear-x { top: 19px; right: 24px; }
.filters .date-range { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-weight: normal; }
.filters .date-input { flex: 0 1 170px; min-width: 150px; }
.filters .date-input input { padding: 8px 10px; }

/* a pop-up with a list in it (Link to booking) */
.dialog.wide { max-width: 860px; }
.picker-rows { max-height: 52vh; overflow-y: auto; border: 1px solid var(--line); border-radius: 6px; }
table.list tbody tr.picked td { background: var(--accent-soft2); }

/* a helper's pay on a booking */
.helper-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 2px 0; }
.helper-row label.check { min-width: 160px; margin: 4px 0; }
.helper-row .money-input { width: 130px; }
.days-box { width: 80px !important; display: inline-block; padding: 6px 8px !important; }

/* Shared/RichEditor.razor: Quill, in OrderHub's colours */
.rich-insert { width: auto !important; max-width: 100%; padding: 6px 10px !important; margin-bottom: 6px; }
.rich .ql-toolbar.ql-snow, .rich .ql-container.ql-snow { border-color: var(--input-border); }
.rich .ql-toolbar.ql-snow { background: var(--panel2); border-radius: 4px 4px 0 0; }
.rich .ql-container.ql-snow { background: var(--input); border-radius: 0 0 4px 4px; font: inherit; color: var(--text); }
.rich .ql-editor { min-height: 180px; max-height: 480px; font-size: 1rem; }
.rich .ql-snow .ql-stroke { stroke: var(--text); }
.rich .ql-snow .ql-fill { fill: var(--text); }
.rich .ql-snow .ql-picker { color: var(--text); }
.rich .ql-snow .ql-picker-options { background: var(--panel); border-color: var(--input-border); }
.rich .ql-snow .ql-tooltip { background: var(--panel); color: var(--text); border-color: var(--input-border); box-shadow: none; z-index: 5; }
.rich .ql-snow .ql-tooltip input[type=text] { width: 200px; background: var(--input); color: var(--text); }
.rich .ql-snow .ql-picker.ql-size .ql-picker-label[data-value="12px"]::before, .rich .ql-snow .ql-picker.ql-size .ql-picker-item[data-value="12px"]::before { content: "Small"; }
.rich .ql-snow .ql-picker.ql-size .ql-picker-label[data-value="18px"]::before, .rich .ql-snow .ql-picker.ql-size .ql-picker-item[data-value="18px"]::before { content: "Large"; }
.rich .ql-snow .ql-picker.ql-size .ql-picker-label[data-value="24px"]::before, .rich .ql-snow .ql-picker.ql-size .ql-picker-item[data-value="24px"]::before { content: "Huge"; }
.photo.add.camera-tile { font-size: 1.5rem; }
.filters .date-input input[type=text] { width: 100%; min-width: 0; max-width: none; }
.weekday-ticks { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; }
.weekday-ticks label.check { margin: 0; white-space: nowrap; }
.month-grid .ev.web-open { background: #2e7d32; color: #fff; border-left-color: #1b5e20; }
.email-preview { background: #fff; color: #111; border: 1px solid var(--track); border-radius: 6px; overflow: auto; max-height: 720px; }
.email-preview table { width: 100%; }

/* dragging a row by its handle (orderhub.js dragRows; Settings > Expense categories) */
.grip { display: inline-block; cursor: grab; padding: 4px 8px; color: var(--subtext); font-size: 1.1rem; user-select: none; touch-action: none; vertical-align: middle; }
.grip:hover { color: var(--text); }
tr.dragging td { opacity: .45; }
tr.dragging .grip { cursor: grabbing; }
tr.drop-line td { padding: 0; height: 3px; background: var(--accent); border: none; }
/* a category picked on each row of the Expenses list */
td.row-pick { min-width: 170px; }
td.row-pick input[type=text] { padding: 4px 8px; }

/* Settings > Expense categories: fixed columns, so the boxes, the tick, the count and the handle line up (owner, 2026-11-07) */
table.cats { table-layout: fixed; }
table.cats .c-name { width: 31%; }
table.cats .c-use { width: 64px; text-align: center; }
table.cats td.c-use input { margin: 0 auto; display: block; }
table.cats .c-count { width: 76px; }
table.cats .c-act { width: 100px; }
@media (max-width: 640px) { table.cats { table-layout: auto; } table.cats td.c-use input { margin: 0; } }

/* OrderHub's own pick-from-a-list box (Shared/PickInput.razor) looks like a dropdown: an arrow at the right (owner, 2026-11-07) */
.combo.pick-input::after { content: "▾"; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--subtext); pointer-events: none; }
.combo.pick-input:has(.combo-list)::after { top: 22px; }
.combo.pick-input input[type=text] { padding-right: 30px; cursor: pointer; }
td.row-pick .combo.pick-input::after { right: 8px; }
td.row-pick .combo.pick-input:has(.combo-list)::after { top: 15px; }

/* a list row that opens when clicked anywhere: the whole row lights up (owner, 2026-11-07) */
table.list tbody tr.link:hover td { background: var(--accent-soft); }

/* the email editor's Visual / Code tabs, top right like WordPress (owner, 2026-11-07) */
.rich-top { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; }
.rich-top .rich-insert { margin-bottom: 0; }
.rich-tabs { margin-left: auto; display: flex; gap: 2px; }
.rich-tabs button { padding: 5px 12px; border-radius: 4px 4px 0 0; border-bottom: none; background: var(--panel2); color: var(--subtext); }
.rich-tabs button.on { background: var(--button-hover); color: var(--text); font-weight: 600; }
.rich-top { margin-bottom: 0; }
.rich .rich-visual, .rich .rich-code { margin-top: 0; }
textarea.rich-code { width: 100%; min-height: 260px; font-family: Consolas, "Cascadia Mono", monospace; font-size: 0.9rem; border-radius: 0 0 4px 4px; }

/* list rows that open (tr.link): the colour from Settings > Appearance > List Highlight Colour. The column the row opens from (its
   a.row-link, mostly the first) is in the link colour (Settings > Appearance > Link Colour, else the accent; owner, 2026-11-08); with a mouse it has no underline, since the whole row is
   the link. On a phone (no hover) it keeps the underline, to show what can be tapped. */
table.list tbody tr.link:hover td { background: var(--row-hover, var(--accent-soft)); }
table.list tbody tr.link a.row-link:not(.button) { color: var(--link, var(--accent)); }
@media (hover: hover) and (pointer: fine) {
    table.list tbody tr.link a.row-link:not(.button) { text-decoration: none; }
}

/* the email editor with the designed layout ticked: the email's own look around the box (EmailLayout.Wrap's colours) */
.rich-visual .mail-card, .rich-visual .mail-body { display: contents; }
.rich-visual.framed { background: #eef1f6; padding: 18px 12px; border: 1px solid var(--input-border); border-top: none; border-radius: 0 0 4px 4px; }
.rich-visual.framed .mail-card { display: block; max-width: 600px; margin: 0 auto; background: #ffffff; border: 1px solid #d5d9df; border-radius: 10px; overflow: hidden; font-family: Arial, Helvetica, sans-serif; }
.rich-visual.framed .mail-head { background: #111827; padding: 22px 28px; }
.rich-visual.framed .mail-business { color: #7fb2f5; font-size: 12px; font-weight: bold; letter-spacing: 2px; text-transform: uppercase; }
.rich-visual.framed .mail-title { color: #ffffff; font-size: 24px; font-weight: bold; padding-top: 6px; }
.rich-visual.framed .mail-band { background: #2f80ed; padding: 18px 28px; color: #ffffff; }
.rich-visual.framed .mail-band-label { font-size: 12px; letter-spacing: 1px; text-transform: uppercase; }
.rich-visual.framed .mail-band-main { font-size: 21px; font-weight: bold; padding-top: 3px; }
.rich-visual.framed .mail-band-sub { font-size: 15px; padding-top: 3px; }
.rich-visual.framed .mail-body { display: block; padding: 8px 12px 12px; }
.rich .rich-visual.framed .ql-container.ql-snow { background: #ffffff; color: #111827; border: none; font-family: Arial, Helvetica, sans-serif; }
.rich .rich-visual.framed .ql-editor { font-size: 15px; line-height: 1.5; }
.rich .rich-visual.framed .ql-editor.ql-blank::before { color: #9aa1ab; }

/* the email editor's emoji button and its panel (orderhub.js orderhubEmojis) */
.rich .ql-snow .ql-toolbar button.ql-emoji::before, .rich .ql-toolbar.ql-snow button.ql-emoji::before { content: "😊"; font-size: 15px; line-height: 18px; }
.rich .ql-toolbar.ql-snow { position: relative; }
.emoji-panel { position: absolute; z-index: 30; top: 100%; left: 0; width: 320px; max-width: calc(100vw - 40px); display: grid; grid-template-columns: repeat(8, 1fr);
               gap: 2px; padding: 8px; background: var(--panel); border: 1px solid var(--input-border); border-radius: 6px; box-shadow: 0 6px 18px rgb(0 0 0 / 0.3); }
.rich .ql-toolbar.ql-snow .emoji-panel button { width: auto; height: 32px; padding: 0; font-size: 20px; line-height: 1; float: none; border-radius: 4px; }
.rich .ql-toolbar.ql-snow .emoji-panel button:hover { background: var(--button-hover); }

/* a venue's photos from each booking, opened and closed (owner, 2026-11-07) */
details.photo-booking { margin: 10px 0; border: 1px solid var(--line, rgba(128,128,128,.3)); border-radius: 6px; padding: 6px 10px; }
details.photo-booking > summary { cursor: pointer; font-weight: 600; display: flex; gap: 12px; align-items: baseline; list-style-position: inside; }
details.photo-booking > summary .count { font-weight: normal; opacity: .7; }
details.photo-booking > summary a { font-weight: normal; margin-left: auto; }
details.photo-booking[open] > .gallery { margin-top: 8px; }
/* putting a venue's photos with another booking: ticked, dragged, dropped (owner, 2026-11-07) */
.gallery-item[draggable="true"] { cursor: grab; }
.gallery-item.picked { outline: 3px solid var(--accent); }
.photo-picked { position: sticky; top: var(--topbar-h, 52px); z-index: 5; display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
                background: var(--panel2); border-radius: 6px; padding: 8px 10px; margin-bottom: 10px; }
.photo-picked .hint { margin: 0; }
.photo-drop { border-radius: 6px; padding: 2px 0; }
.photo-drop.over, details.photo-booking.over, .photo-drop-chip.over { outline: 2px dashed var(--accent); outline-offset: 2px; }
details.photo-booking > summary button.small { font-size: .8em; padding: 2px 8px; font-weight: normal; }
.photo-drop-list { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 10px 0; }
.photo-drop-chip { border: 1px dashed var(--line); border-radius: 6px; padding: 6px 10px; font-size: .9em; }
.gallery-item { position: relative; }
.gallery-item .cap > input.photo-tick { flex: none; width: 18px; height: 18px; margin: 0 auto 0 0; cursor: pointer; }
/* the caption on its own line, the buttons under it at the right (owner, 2026-11-07: "Sep 21 ..." was all that showed) */
.gallery-item .cap { flex-wrap: wrap; justify-content: flex-end; }
.gallery-item .cap > span { flex: 1 0 100%; }
.gallery-item .cap > input[type=text] { flex: 1 0 100%; }
/* the photo link pop-up's bookings list (owner, 2026-11-07) */
.pick-booking-filters { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
.pick-booking-filters input[type=search] { flex: 1 1 280px; }
.pick-booking-filters label.check { margin: 0; white-space: nowrap; }
.pick-booking-list { max-height: 50vh; overflow-y: auto; border: 1px solid var(--line); border-radius: 6px; }
.pick-booking-list table { margin: 0; }
.pick-booking-list tr.chosen td { background: var(--accent); color: #fff; }
.gallery-item.drop-before { box-shadow: -5px 0 0 0 var(--accent); }
/* the closed photo groups light up like a list's rows (Settings > Appearance's highlight colour) */
details.photo-booking > summary { border-radius: 4px; padding: 4px 6px; margin: -4px -6px; }
details.photo-booking:not([open]) > summary:hover { background: var(--row-hover, var(--accent-soft)); }
/* the date pop-ups (New Booking, Book Again): the calendar, and the month's bookings beside it (owner, 2026-11-07) */
.dialog.fit { width: auto; max-width: min(760px, calc(100vw - 32px)); }
.date-pick { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.date-pick .mini-cal { flex: none; }
.date-pick { align-items: stretch; }
.date-pick-list { flex: none; width: 400px; max-width: 100%; min-height: 220px; position: relative; display: flex; flex-direction: column;
                  border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.date-pick-scroll { position: relative; flex: 1; }
.date-pick-scroll > table { position: absolute; top: 0; left: 0; right: 0; }
.date-pick-scroll { overflow-y: auto; }
.date-pick-count { font-size: 0.8em; color: var(--subtext); text-align: center; padding: 3px; border-top: 1px solid var(--line); background: var(--panel2); }
.date-pick-list table { margin: 0; }
.date-pick-list td { padding: 5px 8px; vertical-align: top; font-size: 0.9em; overflow-wrap: anywhere; }
.date-pick-list td.when { white-space: nowrap; }
.date-pick-list .hint { margin: 0; font-size: 0.85em; }
.date-pick-list tr.chosen td { background: var(--accent-soft2); }
.date-pick-list.none { align-items: center; justify-content: center; color: var(--subtext); font-size: 0.9em; }
/* room for six weeks, so a month that spans six doesn't make the pop-up taller */
.date-pick .mini-cal { min-height: 269px; }
/* the New Booking wizard's step heading (owner, 2026-11-07) */
.wizard-head { margin-bottom: 10px; }
.wizard-head h2 { margin: 2px 0 0; }
/* New Booking's gig type step: the same size as the date step after it */
.gig-step { padding: 4px 0 8px; }
.gig-step .choices { gap: 10px; }
.gig-step .choices > label > span { padding: 10px 18px; font-size: 1.05em; }
/* hovering a gig type lights it up in its own colour (owner, 2026-11-07) */
.gig-step .choices > label > span { transition: box-shadow .15s, background-color .15s, transform .15s; }
.gig-step .choices > label:hover > span { background: var(--row-hover, var(--accent-soft)); box-shadow: 0 0 0 2px var(--gig), 0 0 14px 2px var(--gig); transform: translateY(-1px); }
.gig-step .choices > label > input:checked + span { box-shadow: 0 0 0 2px var(--gig); }
.gig-step .choices > label:hover > input:checked + span { background: var(--accent); box-shadow: 0 0 0 2px var(--gig), 0 0 14px 2px var(--gig); }
/* the date pop-ups' buttons at the lower right (owner, 2026-11-07) */
.dialog.fit > .actions { justify-content: flex-end; }
/* the New Booking wizard's steps: not the page's full width (owner, 2026-11-07) */
/* the wizard's steps and the pop-up before them share one spot: across the middle, 10% down from the top, the same width as the
   date step (716px), over the dimmed page. Absolute, not fixed, so a long new-customer form scrolls with the page. */
.wizard-back { position: fixed; inset: 0; background: rgb(0 0 0 / 0.5); z-index: 90; }
.card.wizard-card { position: absolute; top: 10vh; left: 50%; transform: translateX(-50%); width: min(716px, calc(100vw - 32px));
                    margin: 0 0 32px; z-index: 95; box-shadow: 0 8px 30px rgb(0 0 0 / 0.4); }
.dialog-back:has(> .dialog.fit) { align-items: flex-start; padding-top: 10vh; }
/* the scrollbar's room kept, so a step lines up with the pop-up (whose page has one) and doesn't shift when a long form opens */
html:has(.wizard-card) { scrollbar-gutter: stable; }
/* the Calendar: the venue on its own line under the time and customer, and Settings > Appearance's day colours (owner, 2026-11-07) */
.month-grid .ev-venue { display: block; font-size: 0.9em; color: var(--subtext); overflow: hidden; text-overflow: ellipsis; }
.status-colours { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.status-colour { display: flex; align-items: center; gap: 8px; }
.status-colour input[type=color] { width: 44px; height: 30px; padding: 2px; }
.status-colour label.check { margin: 0; }
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; margin-top: 10px; font-size: 0.88em; color: var(--subtext); }
.cal-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.cal-swatch { width: 18px; height: 14px; border-radius: 3px; border: 1px solid var(--track); display: inline-block; }
.cal-legend a { margin-left: auto; }

/* Settings > Appearance: Default Colours beside the Light or Dark choices (owner, 2026-11-08) */
.mode-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mode-row .choices { margin: 0; }

/* Settings > Appearance > Themes (owner, 2026-11-08) */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.theme-card { background: var(--panel2); border: 1px solid var(--line); border-radius: 8px; padding: 8px; display: flex; flex-direction: column; gap: 3px; }
.theme-card .hint { margin: 0; font-size: 0.8em; }
.theme-pic { height: 84px; border-radius: 6px; background-size: cover; background-position: center; position: relative; }
.theme-mine { display: flex; align-items: center; justify-content: center; text-align: center; font-size: 0.85em; color: var(--subtext);
              border: 1px dashed var(--track); padding: 6px; }
.theme-dots { position: absolute; left: 6px; bottom: 6px; display: flex; gap: 3px; }
.theme-dots span { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgb(255 255 255 / 0.85); }
.theme-name { font-weight: 600; margin-top: 4px; }
.theme-buttons { display: flex; gap: 6px; margin-top: 4px; }
.theme-buttons button { flex: 1; padding: 5px 8px; }
.theme-pictures { font-size: 0.85em; margin-top: 2px; }
.theme-pic-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.theme-pic-grid .background-preview { max-width: 100%; }

/* Settings > Appearance: the glass boxes slider; while it's on, the box picture's own controls hide (owner, 2026-11-08) */
.glass-row { display: flex; align-items: center; gap: 12px; max-width: 420px; }
.glass-row input[type=range] { flex: 1; padding: 0; }
.glass-row span { min-width: 72px; color: var(--subtext); }
.picture-section.glass-on .box-picture-only { display: none; }
.picture-section:not(.glass-on) .glass-only { display: none; }

/* a link styled as a button that can't be used yet (the wizard's Next before an event is picked) */
a.button.disabled { pointer-events: none; opacity: 0.5; }

/* a button that can't be pressed yet looks it (2026-11-08: the wizard's Next, switched off until an event is picked, looked ready) */
button:disabled, input[type=submit]:disabled { opacity: 0.5; cursor: not-allowed; }
button:disabled:hover { background: var(--button); border-color: var(--button-border); }   /* no highlight on a button that can't be pressed */

/* New Booking's event step: every button the same width, the text centred in it (owner, 2026-11-08) */
.event-step { width: min(640px, calc(100vw - 72px)); }   /* the pop-up fits its contents, so the grid needs a width: three across, fewer on a phone */
.event-step .choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.event-step .choices > label > span { display: flex; justify-content: center; align-items: center; width: 100%; box-sizing: border-box; text-align: center; }

/* the wizard's choices always show where the keyboard is, even when it was opened by a click (the browser hides the outline
   then, so it looked as if the keyboard wasn't there; owner, 2026-11-08) */
[data-enter-next] .choices input:focus + span { outline: 2px solid var(--accent); outline-offset: 3px; }

/* orderhub.js: OrderHub was updated while this page was open, and something on it isn't saved yet */
.update-bar { position: fixed; left: 50%; top: 8px; transform: translateX(-50%); z-index: 200; background: var(--panel); color: var(--text);
              border: 1px solid var(--accent); border-radius: 8px; padding: 8px 12px; box-shadow: 0 4px 16px rgb(0 0 0 / 0.35); }
.update-bar button { margin-left: 8px; }

/* the Calendar's picked day has the keyboard: its outline is the picked one, not a second browser ring (owner, 2026-11-08) */
.month-grid .day:focus { outline: 2px solid var(--accent); }
.month-grid .day:focus:not(.picked) { outline-style: dashed; }
.dialog:focus { outline: none; }   /* the pop-up holding the keyboard itself: no ring round it */

/* a pop-up's button that has the keyboard always shows it, even when the pop-up was opened by a click (the browser hides the
   outline then; owner, 2026-11-08: the delete question seemed not to take the keyboard) */
.dialog .actions button:focus, .dialog .actions a.button:focus { outline: 2px solid var(--accent); outline-offset: 2px; }

/* the list row the keyboard is on: lit exactly like a row under the pointer, no outline (owner, 2026-11-08) */
table.list tbody tr.link:focus { outline: none; }
table.list tbody tr.link:focus td { background: var(--row-hover, var(--accent-soft)); }
/* while the arrow keys move the highlight, the row under the resting pointer doesn't light up too: one highlight (owner, 2026-11-08) */
table.list.kb tbody tr.link:not(:focus):hover td { background: none; }

/* the lists' shared date picker (Shared/DateRangePicker.razor, owner 2026-11-09): the list and Change Dates side by side, and the
   Custom Range pop-up's From and To, each a box over a mini calendar, side by side (one above the other on a phone) */
.date-range-pick { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.range-cals { display: flex; gap: 24px; flex-wrap: wrap; justify-content: center; }
.range-side { display: flex; flex-direction: column; gap: 6px; width: 266px; max-width: 100%; }
.range-side label { margin: 0; font-weight: 600; }
.range-side input { width: 100%; }

/* the Calendar's legend in the full text colour, not the dim one, so it reads in either look (owner, 2026-11-09: "just the colors";
   chips behind each entry were tried and not wanted) */
.cal-legend { color: var(--text); }

/* every slider drawn by OrderHub itself, the same everywhere: no outline round the track (owner, 2026-11-10: the browser's own drew one on
   the glass sliders and not on Fade It, and the plain one was liked). A thin track in the accent up to the knob (--fill, set by orderhub.js). */
input[type=range] {
    -webkit-appearance: none; appearance: none; height: 6px; border: none; border-radius: 3px; padding: 0; margin: 8px 0; outline: none;
    background: linear-gradient(var(--accent), var(--accent)) 0 / var(--fill, 50%) 100% no-repeat, color-mix(in srgb, var(--text) 18%, transparent);
}
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--accent); border: none; cursor: pointer; }
input[type=range]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--accent); border: none; cursor: pointer; }
input[type=range]::-moz-range-track { background: transparent; border: none; }
input[type=range]:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* a box filled in from the receipt (ExpenseEdit, owner 2026-11-10): highlighted in the accent until it's changed */
.suggested input { background: color-mix(in srgb, var(--accent) 16%, var(--input)); border-color: var(--accent); }
.suggested-note { color: var(--accent); }
/* the file an email linked to (BookingDocuments ?doc=, orderhub.showDoc) */
.found, .found td { outline: 2px solid var(--accent); outline-offset: 2px; background: var(--accent-soft); transition: background .6s; }

/* Items (owner, 2026-11-11): the list's small photo, the item page's size groups and colours */
.items-list td.pic, .items-list th.pic { width: 56px; padding-right: 0; }
.items-list td.pic img { width: 48px; height: 48px; object-fit: cover; border-radius: 6px; display: block; background: var(--track); }
.items-list tr.inactive td { opacity: 0.55; }
.filters input.wide-search { min-width: min(100%, 340px); }
.sizes-table input { width: 100%; min-width: 70px; }
.sizes-table td.num input { max-width: 110px; text-align: right; }
.colour-list { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.colour-chip { display: inline-flex; align-items: center; gap: 2px; }
.colour-chip input { width: 140px; }
/* a photo's box: what it shows on its own line, the buttons under it */
.gallery-item .cap.photo-cap { flex-wrap: wrap; }
.gallery-item .cap.photo-cap select { flex: 1 1 100%; min-width: 0; }
.gallery-item .cap.photo-cap .spacer { flex: 1; }
button.icon { padding: 2px 9px; min-width: 0; line-height: 1.3; }
@media (max-width: 640px) {
    /* the item page's size groups: each a labelled block of four, two by two */
    table.list.sizes-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 8px; padding: 8px 0; }
    table.list.sizes-table td { padding: 0; }
    table.list.sizes-table td[data-label]::before { content: attr(data-label); display: block; font-size: 0.8em; color: var(--subtext); text-align: left; }
    table.list.sizes-table td.num input { max-width: none; }
    table.list.sizes-table td.profit { align-self: center; text-align: left; }
    table.list.sizes-table td.remove { align-self: center; }
    /* the Items list: a card each, the photo beside its details */
    table.list.items-list tr { display: grid; grid-template-columns: 56px 1fr; column-gap: 10px; grid-auto-flow: row dense; }
    table.list.items-list td.pic { grid-column: 1; grid-row: 1 / span 7; width: auto; }
    table.list.items-list td { grid-column: 2; text-align: left; }
    table.list.items-list td[data-label]:not(:empty)::before { content: attr(data-label) ": "; color: var(--subtext); }
}
.grid.price-row { grid-template-columns: repeat(3, minmax(0, 160px)); }
.profit-figure { padding: 10px 0; font-weight: 600; }
@media (max-width: 640px) { .grid.price-row { grid-template-columns: 1fr 1fr; } }
.colour-chip input.photo-no { width: 52px; text-align: center; }
/* Orders and the supplier (owner, 2026-11-11) */
.status.ToOrder, .status.NotSent { background: color-mix(in srgb, var(--warn) 25%, transparent); }
.status.Ordered, .status.Sent { background: var(--accent-soft2); }
.status.Arrived { background: color-mix(in srgb, var(--good) 25%, transparent); }
.status.HandedOver { background: var(--button); }
td.owing, .order-totals .owing strong { color: var(--bad); font-weight: 600; }
.order-lines td { vertical-align: middle; }
.order-lines td.item-cell { min-width: 220px; }
.order-lines input[type=number] { max-width: 90px; text-align: right; }
.order-lines select { min-width: 90px; }
.order-lines .colour-pick { display: block; min-width: 110px; }
.order-lines tr.ordered td { color: var(--subtext); }
.order-lines td.line-buttons { white-space: nowrap; }
.payments-table input[type=number] { max-width: 110px; text-align: right; }
.order-totals { display: flex; gap: 28px; margin: 14px 0 4px; flex-wrap: wrap; }
.order-totals div { display: flex; flex-direction: column; }
.order-totals span { color: var(--subtext); font-size: 0.85em; }
.order-totals strong { font-size: 1.2em; }
pre.email-text { white-space: pre-wrap; background: var(--panel2); padding: 12px 14px; border-radius: 6px; font-family: inherit; margin: 0 0 10px; }
@media (max-width: 640px) {
    table.list.order-lines tr, table.list.payments-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 8px; padding: 8px 0; }
    table.list.order-lines td, table.list.payments-table td { padding: 0; }
    table.list.order-lines td.item-cell { grid-column: 1 / -1; min-width: 0; }
    table.list.order-lines td[data-label]::before, table.list.payments-table td[data-label]::before { content: attr(data-label); display: block; font-size: 0.8em; color: var(--subtext); text-align: left; }
    table.list.order-lines input[type=number], table.list.payments-table input[type=number] { max-width: none; width: 100%; }
    table.list.order-lines td.num, table.list.payments-table td.num { text-align: left; }
    table.list:not(.figures):not(.order-lines):not(.payments-table):not(.sizes-table) td[data-label]:not(:empty)::before { content: attr(data-label) ": "; color: var(--subtext); }
}
.order-lines td.size-cell { min-width: 90px; max-width: 120px; }
.order-lines td.size-cell .field-error { font-size: 0.8em; }
.inline.numbered-colours { align-items: center; margin-top: 10px; flex-wrap: wrap; }
.inline.numbered-colours span { flex: 0 0 auto; color: var(--subtext); }
.inline.numbered-colours input[type=number] { width: 80px; min-width: 0; flex: 0 0 80px; }
.inline.numbered-colours button { flex: 0 0 auto; }

/* a tick box in a row of boxes keeps its own size (.inline input stretched it, far from its words) */
.inline label.check input { flex: none; min-width: 0; }
/* My Orders: Open like To Order; the Add Items pop-up's list */
.status.Open { background: color-mix(in srgb, var(--warn) 25%, transparent); }
.pick-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 6px 14px; max-height: 55vh; overflow: auto; }
label.check.pick-item { margin: 0; padding: 6px; border-radius: 6px; align-items: center; }
label.check.pick-item.on { background: var(--accent-soft2); }
label.check.pick-item img { width: 40px; height: 40px; object-fit: cover; border-radius: 4px; flex: none; }
details.email-preview-box { margin-top: 12px; }
details.email-preview-box summary { cursor: pointer; color: var(--subtext); margin-bottom: 8px; }
/* Family Discount (owner, 2026-11-11): a button that stays down while it's on */
button.family-toggle { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
button.family-toggle .family-box { display: inline-flex; width: 18px; height: 18px; border: 2px solid currentColor; border-radius: 4px; align-items: center; justify-content: center; font-size: 13px; line-height: 1; }
button.family-toggle.on { background: color-mix(in srgb, var(--good) 28%, var(--button)); border-color: var(--good); }
.status.Family { background: color-mix(in srgb, var(--good) 25%, transparent); margin-left: 6px; }
.family-note { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 12px 0 0; }
.family-note .status.Family { margin-left: 0; }
/* a sale in one of the owner's orders (owner, 2026-11-11) */
.status.Sale { background: color-mix(in srgb, var(--bad) 22%, transparent); margin-left: 6px; }
.sale-table input[type=number] { max-width: 110px; text-align: right; }
.inline.phone-row input.phone-label { flex: 0 0 80px; min-width: 0; }
/* a credit on a customer's order (owner, 2026-11-11) */
.credit-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.credit-row .credit-amount { display: inline-flex; align-items: center; gap: 4px; }
.credit-row .credit-amount input { width: 110px; text-align: right; }
.credit-row input.credit-note { flex: 1; min-width: 200px; }
.order-totals .credit strong { color: var(--good); }
/* an item's additional pictures under its description (owner, 2026-11-11) */
.more-photos { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin-top: 4px; }
.more-photos img { width: 32px; height: 32px; object-fit: cover; border-radius: 4px; display: block; background: var(--track); }
table.list td.pic img { width: 48px; height: 48px; object-fit: cover; border-radius: 6px; display: block; background: var(--track); }
table.list td.pic, table.list th.pic { width: 56px; padding-right: 0; }

/* the contact's cost check (Pages/CostCheck.razor, owner 2026-11-11) */
.check-sheet { width: 100%; max-width: 760px; }
.check-sheet h1 { margin-bottom: 2px; }
.check-sheet .sub { margin: 0 0 12px; color: var(--subtext); }
.check-item { display: flex; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line, rgba(128,128,128,.25)); }
.check-pic { flex: none; width: 110px; }
.check-pic img { width: 110px; height: 110px; object-fit: cover; border-radius: 8px; display: block; background: var(--track); }
.check-body { flex: 1; min-width: 0; }
.check-body h2 { margin: 0 0 4px; font-size: 1.05rem; }
.check-costs { border-collapse: collapse; margin: 8px 0; }
.check-costs th, .check-costs td { padding: 4px 10px 4px 0; text-align: left; }
.check-costs th.num, .check-costs td.num { text-align: right; }
.check-costs input { width: 7em; text-align: right; }
.check-available { display: flex; gap: 14px; align-items: center; margin: 4px 0 8px; }
.check-available label.check { margin: 0; }
.check-available label.check input { flex: none; min-width: 0; }
.check-sheet button.primary { width: 100%; margin-top: 16px; padding: 12px; font-size: 1.05rem; }
@media (max-width: 560px) {
    .check-item { flex-direction: column; }
    .check-pic, .check-pic img { width: 100%; height: auto; max-height: 260px; object-fit: contain; }
}
.status.NotAvailable { background: rgba(200, 60, 60, .18); color: #c84040; }

/* the owner as a customer (owner, 2026-11-11) */
.status.Me { background: color-mix(in srgb, var(--good) 25%, transparent); margin-left: 6px; }
.family-note .status.Me { margin-left: 0; }
.profits-box { margin-top: 20px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; }
.profits-box h2 { margin-top: 0; }
.profits-box button.primary { margin-top: 8px; }
.signature-preview { padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: #222; font-family: Calibri, Arial, sans-serif; }
.signature-preview p { margin: 0; }

/* the same height for a box, a select and a button side by side */
input[type=text], input[type=password], input[type=email], input[type=tel], input[type=number], input[type=date], input[type=time], select { height: 34px; }
/* an order's details as simple labels (owner, 2026-11-11) */
.order-facts .order-totals { margin-top: 0; }
.order-facts .facts-notes { margin: 8px 0 0; white-space: pre-wrap; }
.order-facts .actions { margin-top: 10px; }

/* the customers' page (Pages/ShopPage.razor, owner 2026-11-11): the thank-you cards' taupe and cream */
.bare:has(.shop) { align-items: flex-start; }
.shop { width: 100%; max-width: 1100px; }
.shop-head { text-align: center; margin: 8px 0 16px; }
.shop-head h1 { margin: 0; color: #96745C; letter-spacing: 3px; font-weight: 500; font-size: 2.2rem; }
.shop-tag { margin: 2px 0 6px; color: #96745C; letter-spacing: 2px; font-size: .85rem; }
.shop-sub { margin: 0; color: var(--subtext); }
.shop-search { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; position: sticky; top: 0; z-index: 5; padding: 8px 0; background: var(--bg, transparent); }
.shop-search input { flex: 1; height: 38px; padding: 6px 12px; font: inherit; color: var(--text); background: var(--input); border: 1px solid var(--input-border); border-radius: 6px; }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.shop-item { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; }
.shop-item[hidden] { display: none; }
.shop-pic img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; background: var(--track); }
.shop-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.shop-body h2 { margin: 0; font-size: 1.02rem; }
.shop-more { display: flex; gap: 4px; flex-wrap: wrap; }
.shop-more img { width: 40px; height: 40px; object-fit: cover; border-radius: 4px; display: block; }
.shop-prices div { display: flex; justify-content: space-between; gap: 8px; }
.shop-prices strong { color: #96745C; }
.shop-pick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 4px; }
.shop-pick select { flex: 1 1 100px; width: auto; }
.shop-pick input[type=number] { width: 64px; flex: none; }
.shop-pick .shop-add { flex: 1 1 100%; }
.shop-pick select.invalid { outline: 2px solid var(--bad); }
.shop-list { margin-top: 20px; background: var(--panel); border: 2px solid #D6C6B6; border-radius: 10px; padding: 14px 16px; }
.shop-list h2 { margin: 0 0 6px; color: #96745C; }
.shop-list ul { list-style: none; margin: 0; padding: 0; }
.shop-list li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.shop-list button.primary { width: 100%; margin-top: 14px; padding: 10px; font-size: 1.05rem; }
.shop-hp { position: absolute; left: -5000px; width: 1px; height: 1px; opacity: 0; }
.shop-foot { text-align: center; margin: 16px 0; }
.status.New { background: color-mix(in srgb, var(--warn) 30%, transparent); }
.status.Done { background: var(--accent-soft2, var(--track)); }
.shop-order { margin-bottom: 18px; }
.shop-order[hidden] { display: none; }
.shop-order-head { margin: 6px 0 10px; color: #96745C; }
.shop-body h3 { margin: 0; font-size: 1.02rem; }
.shop-ticks { display: flex; flex-direction: column; gap: 4px; }
.shop-ticks label.check { margin: 0; }
.shop-ticks label.check input { flex: none; min-width: 0; }
/* Back at the top of a page (owner, 2026-11-11) */
.back-button { flex: none; }
.page-head .back-button { order: -1; }
.settings-back { margin-bottom: 8px; }
button.row-x { color: var(--subtext); }
button.row-x:hover { color: var(--bad); border-color: var(--bad); }
.page-head .spacer { flex: 1; }
/* the signature on the thank-you cards (Settings > Thank You Cards, owner 2026-11-11) */
.font-picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.font-pick { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 0; padding: 8px; border: 1px solid var(--input-border); border-radius: 8px; cursor: pointer; background: #F7F3EE; color: #222; }
.font-pick.on { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.font-pick input { position: absolute; opacity: 0; pointer-events: none; }
.font-pick:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.font-sample { font-size: 2rem; line-height: 1.3; }
.signature-preview-img { max-height: 70px; max-width: 260px; background: #F7F3EE; padding: 6px 10px; border-radius: 6px; flex: 0 0 auto; min-width: 0; }
/* a picture shown big over the page (data-lightbox, owner 2026-11-12) */
.lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(20, 18, 16, .88); display: flex; align-items: center; justify-content: center; cursor: zoom-out; }
.lightbox img { max-width: 94vw; max-height: 90vh; object-fit: contain; border-radius: 6px; box-shadow: 0 6px 30px rgba(0, 0, 0, .5); background: #fff; }
.lightbox .lb-close { position: absolute; top: 12px; right: 14px; font-size: 2rem; line-height: 1; padding: 4px 12px; background: rgba(255, 255, 255, .15); color: #fff; border: 0; border-radius: 6px; cursor: pointer; }
.lightbox .lb-count { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #eee; font-size: .9rem; }
.picture-section.solid-on .page-picture-only { display: none; }
.picture-section:not(.solid-on) .solid-only { display: none; }
/* the Files card's drop zone (owner, 2026-11-12) */
.drop-zone { position: relative; margin-top: 10px; border: 2px dashed var(--input-border); border-radius: 8px; padding: 18px 14px; text-align: center; color: var(--subtext); }
.drop-zone .drop-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.drop-zone:hover, .drop-zone.over { border-color: var(--accent); color: var(--text); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.drop-zone.busy { opacity: .7; }
/* the row highlight fades in and out quickly as the mouse or the arrow keys move from row to row (owner, 2026-11-12) */
/* only with Crossfade ticked (Settings > Appearance, List Highlight Colour) */
html.row-fade table.list tbody tr.link td, html.row-fade ul.links li.link { transition: background-color .15s ease; }

/* a theme card shows its light or dark picture, for the mode in use (owner, 2026-11-12) */
.theme-pic { background-image: var(--pic-light); }
html[data-theme="dark"] .theme-pic { background-image: var(--pic-dark); }
@media (prefers-color-scheme: dark) { html[data-theme="system"] .theme-pic { background-image: var(--pic-dark); } }

/* (a strip kept for the scroll bar on every page, scrollbar-gutter, showed as a dark bar on pages that don't scroll: taken off. The
   background picture is a full-window layer instead, Appearance.BackgroundCss html::before, so it doesn't move either way.) */
.shop-logo { display: block; width: 130px; height: 130px; object-fit: contain; margin: 4px auto 10px; }
@media (max-width: 560px) { .shop-logo { width: 100px; height: 100px; } }
/* an order's pictures pop-up (owner, 2026-11-12) */
.order-pictures { display: flex; flex-direction: column; gap: 14px; max-height: 70vh; overflow-y: auto; }
.order-pictures-name { margin-bottom: 6px; }
.order-pictures-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
/* the whole picture, not cropped: they're often collages of every colour */
.order-pictures-grid img { width: 100%; aspect-ratio: 1; object-fit: contain; border-radius: 6px; display: block; background: var(--track); }
.lightbox { z-index: 3000; }
