/*
 * BNW contestant dashboard.
 * Everything is scoped to .bnw-dash so the site theme is never affected.
 * The layout responds to the dashboard's own width (container queries),
 * so it works inside any theme column, on tablets and on phones.
 *
 * Fonts are served from the plugin (no Google Fonts request, GDPR-safe).
 */
@font-face { font-family: "BNW Garamond"; src: url("../../books/assets/fonts/EBGaramond-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "BNW Garamond"; src: url("../../books/assets/fonts/EBGaramond-Medium.ttf") format("truetype"); font-weight: 500 600; font-display: swap; }
@font-face { font-family: "BNW Inter"; src: url("../../books/assets/fonts/Inter-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "BNW Inter"; src: url("../../books/assets/fonts/Inter-SemiBold.ttf") format("truetype"); font-weight: 500 700; font-display: swap; }

.bnw-dash {
    --bd-page: #f4f4f2;
    --bd-paper: #ffffff;
    --bd-ink: #121212;
    --bd-ink-2: #3d3d3b;
    --bd-muted: #74736f;
    --bd-line: #e3e2de;
    --bd-soft: #f0efec;
    --bd-warn-bg: #fbf1df; --bd-warn: #8a5a10; --bd-warn-line: #e3c58c;
    --bd-ok-bg: #e9f1ea; --bd-ok: #2f6b3a;
    --bd-info-bg: #eceff4; --bd-info: #3c4a63;
    --bd-danger: #9b2c2c;
    --bd-display: "BNW Garamond", "EB Garamond", Georgia, "Times New Roman", serif;
    --bd-text: "BNW Inter", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

    container-type: inline-size;
    color: var(--bd-ink);
    font-family: var(--bd-text);
    font-size: 14.5px;
    line-height: 1.55;
    background: var(--bd-paper);
    border: 1px solid var(--bd-line);
    margin: 0 0 32px;
    color-scheme: light;
}
.bnw-dash *, .bnw-dash *::before, .bnw-dash *::after { box-sizing: border-box; }
.bnw-dash a { color: var(--bd-ink); }
.bnw-dash img { max-width: 100%; height: auto; }
.bnw-dash :focus-visible { outline: 2px solid var(--bd-ink); outline-offset: 2px; }
.bnw-dash h1, .bnw-dash h2, .bnw-dash h3 { font-family: var(--bd-display); font-weight: 500; color: var(--bd-ink); letter-spacing: 0; text-transform: none; }
.bnw-dash p { margin: 0 0 1em; }

/* ---------- Top bar ---------- */
.bnw-dash .bd-bar { display: flex; align-items: center; gap: 16px; padding: 16px 28px; border-bottom: 1px solid var(--bd-line); flex-wrap: wrap; }
.bnw-dash .bd-brand { display: flex; align-items: baseline; gap: 10px; margin-right: auto; text-decoration: none; }
.bnw-dash .bd-brand b { font-family: var(--bd-display); font-size: 22px; font-weight: 600; letter-spacing: .02em; }
.bnw-dash .bd-brand span { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--bd-muted); }
.bnw-dash .bd-pill { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--bd-ink-2); background: var(--bd-soft); border-radius: 999px; padding: 6px 12px; }
.bnw-dash .bd-pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--bd-ok); display: inline-block; }
.bnw-dash .bd-pill.is-closed i { background: var(--bd-ink); }
.bnw-dash .bd-who { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.bnw-dash .bd-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--bd-ink); color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 13px; flex: none; }

/* ---------- Shell ---------- */
.bnw-dash .bd-body { display: grid; grid-template-columns: 220px minmax(0, 1fr); min-height: 560px; }
.bnw-dash .bd-nav { border-right: 1px solid var(--bd-line); padding: 22px 14px; display: flex; flex-direction: column; gap: 2px; margin: 0; list-style: none; }
.bnw-dash .bd-nav a {
    display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px;
    color: var(--bd-ink-2); font-size: 14px; text-decoration: none; position: relative;
}
.bnw-dash .bd-nav a svg { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; }
.bnw-dash .bd-nav a:hover { background: var(--bd-soft); }
.bnw-dash .bd-nav a[aria-current="page"] { background: var(--bd-ink); color: #fff; }
.bnw-dash .bd-nav .bd-sep { flex: 1; }
.bnw-dash .bd-short { display: none; }
.bnw-dash .bd-count { margin-left: auto; font-size: 11px; background: var(--bd-warn-bg); color: var(--bd-warn); border-radius: 999px; padding: 1px 8px; font-weight: 600; }
.bnw-dash .bd-nav a[aria-current="page"] .bd-count { background: rgba(255,255,255,.18); color: #fff; }
.bnw-dash .bd-main { padding: 32px 36px 48px; min-width: 0; }
.bnw-dash .bd-view { display: grid; gap: 28px; }

/* ---------- Headings ---------- */
.bnw-dash .bd-head { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: flex-end; justify-content: space-between; }
.bnw-dash .bd-head h1 { font-size: 38px; line-height: 1.05; margin: 0; text-wrap: balance; }
.bnw-dash .bd-head p { margin: 6px 0 0; color: var(--bd-muted); max-width: 60ch; }
.bnw-dash .bd-eyebrow { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--bd-muted); font-weight: 600; margin: 0 0 8px; }

/* ---------- Buttons ---------- */
.bnw-dash .bd-btn, .bnw-dash .bd-main .btn-primary, .bnw-dash .bd-main button.button.primary, .bnw-dash .bd-main .button.primary {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--bd-ink) !important;
    background: var(--bd-ink) !important; color: #fff !important; padding: 11px 20px !important; border-radius: 999px !important;
    font: 500 13.5px/1.3 var(--bd-text) !important; cursor: pointer; text-decoration: none !important; white-space: nowrap;
    text-transform: none !important; letter-spacing: 0 !important; box-shadow: none !important; width: auto; max-width: 100%;
}
.bnw-dash .bd-btn:hover { background: #2a2a2a !important; }
.bnw-dash .bd-btn.is-ghost { background: transparent !important; color: var(--bd-ink) !important; border-color: var(--bd-line) !important; }
.bnw-dash .bd-btn.is-ghost:hover { border-color: var(--bd-ink) !important; }
.bnw-dash .bd-btn.is-sm { padding: 7px 14px !important; font-size: 12.5px !important; }
.bnw-dash .bd-btn.is-warn { background: var(--bd-warn) !important; border-color: var(--bd-warn) !important; }
.bnw-dash .bd-btn.is-block { width: 100%; }
.bnw-dash .bd-btn[disabled], .bnw-dash .bd-btn.is-disabled { opacity: .4; cursor: not-allowed; pointer-events: none; }
.bnw-dash .bd-btn svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.bnw-dash .bd-link { background: none; border: 0; padding: 0; color: var(--bd-ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: 13px; }
.bnw-dash .bd-link.is-danger { color: var(--bd-danger); }

/* ---------- Panels, stats ---------- */
.bnw-dash .bd-panel { border: 1px solid var(--bd-line); border-radius: 14px; padding: 24px; min-width: 0; background: var(--bd-paper); }
.bnw-dash .bd-panel h2 { font-size: 24px; margin: 0 0 4px; }
.bnw-dash .bd-panel > p { color: var(--bd-muted); }
.bnw-dash .bd-panel.is-dark { background: var(--bd-ink); color: #fff; border: 0; }
.bnw-dash .bd-panel.is-dark h2 { color: #fff; font-size: 30px; }
.bnw-dash .bd-panel.is-dark p { color: #bdbdbb; }
.bnw-dash .bd-panel.is-dark .bd-btn { background: #fff !important; color: var(--bd-ink) !important; border-color: #fff !important; }
.bnw-dash .bd-reqs { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 22px; padding: 0; list-style: none; }
.bnw-dash .bd-reqs li { font-size: 12px; border: 1px solid rgba(255,255,255,.22); color: #e9e9e7; border-radius: 999px; padding: 4px 11px; margin: 0; }
.bnw-dash .bd-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--bd-line); border-radius: 14px; overflow: hidden; }
.bnw-dash .bd-stat { padding: 20px 22px; border-right: 1px solid var(--bd-line); }
.bnw-dash .bd-stat:last-child { border-right: 0; }
.bnw-dash .bd-stat .k { font-size: 12px; color: var(--bd-muted); }
.bnw-dash .bd-stat .v { font-family: var(--bd-display); font-size: 40px; line-height: 1.1; font-variant-numeric: lining-nums tabular-nums; }
.bnw-dash .bd-stat .s { font-size: 12.5px; color: var(--bd-ink-2); }
.bnw-dash .bd-split { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 24px; }
.bnw-dash .bd-prose { color: var(--bd-ink-2); font-size: 14px; }
.bnw-dash .bd-prose > :last-child { margin-bottom: 0; }
.bnw-dash .bd-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.bnw-dash .bd-strip figure { margin: 0; min-width: 0; }
.bnw-dash .bd-strip img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; border-radius: 8px; background: var(--bd-soft); }
.bnw-dash .bd-strip figcaption { font-size: 12.5px; margin: 6px 0 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Banners and notes ---------- */
.bnw-dash .bd-banner { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; border-radius: 14px; padding: 16px 18px; }
.bnw-dash .bd-banner .ic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; }
.bnw-dash .bd-banner .ic svg { width: 19px; height: 19px; stroke: currentColor; fill: none; stroke-width: 1.7; }
.bnw-dash .bd-banner b { display: block; font-weight: 600; }
.bnw-dash .bd-banner span { font-size: 13.5px; }
.bnw-dash .bd-banner.is-warn { background: var(--bd-warn-bg); color: var(--bd-warn); border: 1px solid var(--bd-warn-line); }
.bnw-dash .bd-banner.is-warn .ic { background: #fff; }
.bnw-dash .bd-banner.is-win { background: var(--bd-ink); color: #fff; }
.bnw-dash .bd-banner.is-win .ic { background: rgba(255,255,255,.12); }
.bnw-dash .bd-banner.is-win span { color: #c9c9c7; }
.bnw-dash .bd-banner.is-win .bd-btn { background: #fff !important; color: var(--bd-ink) !important; border-color: #fff !important; }
.bnw-dash .bd-note { display: flex; gap: 12px; align-items: flex-start; background: var(--bd-soft); border-radius: 12px; padding: 14px 16px; font-size: 13.5px; color: var(--bd-ink-2); }
.bnw-dash .bd-note svg { width: 18px; height: 18px; flex: none; margin-top: 1px; stroke: currentColor; fill: none; stroke-width: 1.6; }
.bnw-dash .bd-empty { border: 1px dashed var(--bd-line); border-radius: 14px; padding: 36px 24px; text-align: center; color: var(--bd-muted); }
.bnw-dash .bd-empty h3 { font-size: 24px; margin: 0 0 6px; }
.bnw-dash .bd-gate { border: 1px solid var(--bd-warn-line); background: var(--bd-warn-bg); border-radius: 16px; padding: 32px; display: grid; gap: 14px; justify-items: start; max-width: 620px; }
.bnw-dash .bd-gate h2 { font-size: 28px; margin: 0; }
.bnw-dash .bd-gate p { margin: 0; color: var(--bd-ink-2); }

/* ---------- Chips ---------- */
.bnw-dash .bd-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 600; border-radius: 999px; padding: 3px 10px; white-space: nowrap; line-height: 1.5; }
.bnw-dash .bd-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.bnw-dash .bd-chip.is-pay { background: var(--bd-warn-bg); color: var(--bd-warn); }
.bnw-dash .bd-chip.is-review { background: var(--bd-info-bg); color: var(--bd-info); }
.bnw-dash .bd-chip.is-ok { background: var(--bd-ok-bg); color: var(--bd-ok); }
.bnw-dash .bd-chip.is-award { background: var(--bd-ink); color: #fff; }
.bnw-dash .bd-chip.is-award::before { display: none; }
.bnw-dash .bd-chip.is-plain { background: var(--bd-soft); color: var(--bd-muted); }
.bnw-dash .bd-chip.is-bad { background: #f6e6e6; color: var(--bd-danger); }

/* ---------- Entries ---------- */
.bnw-dash .bd-editions { display: flex; gap: 6px; flex-wrap: wrap; }
.bnw-dash .bd-editions a { border: 1px solid var(--bd-line); background: var(--bd-paper); border-radius: 999px; padding: 7px 16px; font-size: 13px; color: var(--bd-ink-2); text-decoration: none; }
.bnw-dash .bd-editions a small { color: var(--bd-muted); margin-left: 4px; font-size: 11px; }
.bnw-dash .bd-editions a[aria-current="true"] { background: var(--bd-ink); border-color: var(--bd-ink); color: #fff; }
.bnw-dash .bd-editions a[aria-current="true"] small { color: #bdbdbb; }
.bnw-dash .bd-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.bnw-dash .bd-card { border: 1px solid var(--bd-line); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; min-width: 0; background: var(--bd-paper); }
.bnw-dash .bd-card.is-attention { border-color: var(--bd-warn-line); }
.bnw-dash .bd-card .ph { position: relative; background: var(--bd-soft); aspect-ratio: 4 / 3; display: grid; place-items: center; overflow: hidden; }
.bnw-dash .bd-card .ph img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: contain; display: block; }
.bnw-dash .bd-card .ph .sel { position: absolute; top: 10px; left: 10px; background: rgba(255,255,255,.94); border-radius: 999px; padding: 4px 10px 4px 6px; display: flex; gap: 6px; align-items: center; font-size: 12px; cursor: pointer; margin: 0; }
.bnw-dash .bd-card .ph .sel input { width: 16px; height: 16px; accent-color: var(--bd-ink); margin: 0; }
.bnw-dash .bd-card .ph .num { position: absolute; top: 10px; right: 10px; font-size: 11px; color: var(--bd-muted); background: rgba(255,255,255,.94); border-radius: 999px; padding: 3px 9px; font-variant-numeric: tabular-nums; }
.bnw-dash .bd-card .ph .ribbon { position: absolute; left: 0; bottom: 0; right: 0; background: var(--bd-ink); color: #fff; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; padding: 7px 12px; }
.bnw-dash .bd-card .meta { padding: 16px 18px 18px; display: grid; gap: 10px; flex: 1; align-content: start; }
.bnw-dash .bd-card h3 { font-size: 22px; line-height: 1.15; margin: 0; overflow-wrap: anywhere; }
.bnw-dash .bd-card .row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 0; }
.bnw-dash .bd-card .sub, .bnw-dash .bd-sub { font-size: 12.5px; color: var(--bd-muted); margin: 0; }
.bnw-dash .bd-card .acts { display: flex; gap: 10px 14px; align-items: center; flex-wrap: wrap; margin-top: auto; border-top: 1px solid var(--bd-line); padding-top: 12px; }
.bnw-dash .bd-card .acts .bd-btn:first-of-type { margin-left: auto; }
.bnw-dash .bd-card .acts.is-stack { display: grid; gap: 8px; }
.bnw-dash .bd-card .acts.is-stack .bd-btn { margin-left: 0; width: 100%; }
.bnw-dash .bd-task { background: var(--bd-warn-bg); color: var(--bd-warn); border-radius: 10px; padding: 10px 12px; font-size: 12.5px; display: grid; gap: 2px; }
.bnw-dash .bd-task b { font-size: 13px; }
.bnw-dash .bd-done { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--bd-ok); }
.bnw-dash .bd-done svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 2; }
.bnw-dash .bd-paybar { position: sticky; bottom: 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: var(--bd-ink); color: #fff; border-radius: 14px; padding: 12px 14px 12px 20px; box-shadow: 0 12px 30px rgba(0,0,0,.18); z-index: 2; }
.bnw-dash .bd-paybar .bd-btn { background: #fff !important; color: var(--bd-ink) !important; border-color: #fff !important; }
.bnw-dash .bd-paybar b { font-variant-numeric: tabular-nums; }
.bnw-dash .bd-history { display: grid; gap: 10px; }
.bnw-dash .bd-hrow { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 16px; align-items: center; border: 1px solid var(--bd-line); border-radius: 12px; padding: 10px 14px 10px 10px; }
.bnw-dash .bd-hrow img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; display: block; background: var(--bd-soft); }
.bnw-dash .bd-hrow h3 { font-size: 21px; margin: 0 0 4px; line-height: 1.2; overflow-wrap: anywhere; }
.bnw-dash .bd-hrow .right { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.bnw-dash .bd-paginate { display: flex; gap: 6px; flex-wrap: wrap; }
.bnw-dash .bd-paginate .page-numbers { border: 1px solid var(--bd-line); border-radius: 8px; padding: 5px 11px; text-decoration: none; font-size: 13px; }
.bnw-dash .bd-paginate .current { background: var(--bd-ink); color: #fff; border-color: var(--bd-ink); }

/* ---------- Forms ---------- */
.bnw-dash .bd-form { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.bnw-dash .bd-fields { display: grid; gap: 18px; }
.bnw-dash .bd-field { display: grid; gap: 6px; margin: 0; align-content: start; }
.bnw-dash [hidden] { display: none !important; }
.bnw-dash .bd-field > label, .bnw-dash .bd-field > .lbl { font-size: 13px; font-weight: 500; margin: 0; }
.bnw-dash .bd-req { color: var(--bd-danger); }
.bnw-dash .bd-hint { font-size: 12px; color: var(--bd-muted); }
.bnw-dash .bd-field input[type=text], .bnw-dash .bd-field input[type=email], .bnw-dash .bd-field input[type=password],
.bnw-dash .bd-field select, .bnw-dash .bd-field textarea,
.bnw-dash .bd-main .form-control {
    width: 100%; max-width: 100%; border: 1px solid var(--bd-line) !important; border-radius: 10px !important; padding: 11px 13px !important;
    background: var(--bd-paper) !important; color: var(--bd-ink) !important; font: 400 14.5px/1.4 var(--bd-text) !important; height: auto !important; box-shadow: none !important; margin: 0;
}
.bnw-dash .bd-field textarea { min-height: 110px; resize: vertical; }
.bnw-dash .bd-field input:focus, .bnw-dash .bd-field select:focus, .bnw-dash .bd-field textarea:focus, .bnw-dash .bd-main .form-control:focus { outline: none; border-color: var(--bd-ink) !important; box-shadow: 0 0 0 3px rgba(18,18,18,.08) !important; }
.bnw-dash .bd-field.is-missing select { border-color: var(--bd-warn) !important; box-shadow: 0 0 0 3px rgba(138,90,16,.12) !important; }
.bnw-dash .bd-two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.bnw-dash .bd-step { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--bd-muted); font-weight: 600; padding-top: 14px; border-top: 1px solid var(--bd-line); margin: 4px 0 0; }
.bnw-dash .bd-step:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.bnw-dash .bd-drop { position: relative; border: 1.5px dashed #c9c8c3; border-radius: 14px; padding: 22px; display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 20px; align-items: center; background: #fafaf8; cursor: pointer; }
.bnw-dash .bd-drop.is-empty { grid-template-columns: 1fr; text-align: center; padding: 34px 22px; }
.bnw-dash .bd-drop.is-over { border-color: var(--bd-ink); background: var(--bd-soft); }
.bnw-dash .bd-drop.is-bad { border-color: var(--bd-danger); }
.bnw-dash .bd-drop .preview { width: 120px; height: 90px; object-fit: cover; border-radius: 8px; display: block; background: var(--bd-soft); }
.bnw-dash .bd-drop.is-empty .preview { display: none; }
.bnw-dash .bd-drop .up-ic { display: none; width: 30px; height: 30px; stroke: var(--bd-muted); fill: none; stroke-width: 1.5; margin: 0 auto 8px; }
.bnw-dash .bd-drop.is-empty .up-ic { display: block; }
.bnw-dash .bd-drop b { display: block; font-weight: 500; overflow-wrap: anywhere; }
.bnw-dash .bd-drop .msg { display: block; margin-top: 4px; font-size: 12.5px; }
.bnw-dash .bd-drop .msg.is-ok { color: var(--bd-ok); }
.bnw-dash .bd-drop .msg.is-bad { color: var(--bd-danger); }
.bnw-dash .bd-drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.bnw-dash .bd-check { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--bd-ink-2); margin: 0; cursor: pointer; font-weight: 400; }
.bnw-dash .bd-check input { width: 17px; height: 17px; accent-color: var(--bd-ink); margin-top: 2px; flex: none; }
.bnw-dash .bd-check a { text-underline-offset: 3px; font-weight: 500; }
.bnw-dash .bd-cats { display: flex; flex-wrap: wrap; gap: 8px; }
.bnw-dash .bd-cats label { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--bd-line); border-radius: 999px; padding: 6px 14px; font-size: 13px; cursor: pointer; margin: 0; font-weight: 400; }
.bnw-dash .bd-cats input { accent-color: var(--bd-ink); margin: 0; }
.bnw-dash .bd-aside { position: sticky; top: 16px; display: grid; gap: 14px; }
.bnw-dash .bd-sumline { display: flex; justify-content: space-between; font-size: 13.5px; padding: 8px 0; border-bottom: 1px solid var(--bd-line); font-variant-numeric: tabular-nums; }
.bnw-dash .bd-sumline.is-total { border-bottom: 0; font-weight: 600; font-size: 15px; }
.bnw-dash .bd-rules { margin: 0; padding-left: 18px; font-size: 13px; color: var(--bd-ink-2); display: grid; gap: 6px; }

/* ---------- Messages (existing plugin notices) ---------- */
.bnw-dash .awards-result { border-radius: 12px; padding: 14px 16px; font-size: 13.5px; margin: 0 0 18px; border: 1px solid var(--bd-line); background: var(--bd-soft); color: var(--bd-ink-2); }
.bnw-dash .awards-result.result-danger { background: #f8ecec; border-color: #e9c9c9; color: var(--bd-danger); }
.bnw-dash .awards-result.result-success { background: var(--bd-ok-bg); border-color: #cfe1d2; color: var(--bd-ok); }

/* ---------- Legacy screens restyled (edit entry, payment, mass pay, credits, high-res) ---------- */
.bnw-dash .bd-main > h3, .bnw-dash .bd-legacy h3 { font-size: 30px; line-height: 1.1; margin: 0 0 18px; }
.bnw-dash .bd-main label { font-size: 13px; font-weight: 500; }
.bnw-dash .bd-main .form-group { margin-bottom: 16px; }
.bnw-dash .bd-main table { border-collapse: collapse; width: 100%; }
.bnw-dash .bd-main table th { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--bd-muted); font-weight: 600; text-align: left; }
.bnw-dash .bd-main table td, .bnw-dash .bd-main table th { border-color: var(--bd-line) !important; }
.bnw-dash .bd-legacy { overflow-x: auto; }
.bnw-dash .bd-main .mpa-highres-modal, .bnw-dash .bd-main .awm-highres-section { border-radius: 16px !important; }

/* High-res upload modal (rendered by user-dashboard-highres-section.php) */
/* Opened/closed with jQuery fadeIn/fadeOut by the upload script, so it uses display:block. */
.bnw-dash .bd-modal { position: fixed; inset: 0; background: rgba(18,18,18,.55); display: none; padding: 16px; z-index: 999999; overflow-y: auto; }
.bnw-dash .bd-dialog { background: var(--bd-paper); border-radius: 18px; width: min(760px, 100%); margin: 6vh auto; padding: 24px; position: relative; box-shadow: 0 30px 60px rgba(0,0,0,.3); }
.bnw-dash .bd-x { position: absolute; top: 14px; right: 14px; background: var(--bd-soft); border: 0; width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font-size: 18px; line-height: 1; color: var(--bd-ink); }

/* ---------- Responsive: follows the dashboard's own width ---------- */
@container (max-width: 920px) {
    .bnw-dash .bd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bnw-dash .bd-split { grid-template-columns: 1fr; }
    .bnw-dash .bd-form { grid-template-columns: 1fr; }
    .bnw-dash .bd-aside { position: static; }
}
@container (max-width: 720px) {
    .bnw-dash .bd-bar { padding: 14px 16px; gap: 10px; }
    .bnw-dash .bd-brand span, .bnw-dash .bd-who .name { display: none; }
    .bnw-dash .bd-body { grid-template-columns: 1fr; }
    /* Phone menu: every item visible as a 3 x 2 grid */
    .bnw-dash .bd-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; border-right: 0; border-bottom: 1px solid var(--bd-line); padding: 10px 12px; }
    .bnw-dash .bd-nav a { flex-direction: column; justify-content: center; gap: 4px; padding: 9px 4px; font-size: 12px; text-align: center; background: var(--bd-soft); border-radius: 10px; }
    .bnw-dash .bd-nav a svg { width: 17px; height: 17px; }
    .bnw-dash .bd-nav .bd-sep, .bnw-dash .bd-nav .bd-long { display: none; }
    .bnw-dash .bd-nav .bd-short { display: inline; }
    .bnw-dash .bd-count { position: absolute; top: 4px; right: 6px; margin: 0; padding: 0 6px; font-size: 10px; }
    .bnw-dash .bd-main { padding: 22px 16px 32px; }
    .bnw-dash .bd-head h1 { font-size: 30px; }
    .bnw-dash .bd-stats { grid-template-columns: 1fr 1fr; }
    .bnw-dash .bd-stat:nth-child(2) { border-right: 0; }
    .bnw-dash .bd-stat:nth-child(3) { grid-column: 1 / -1; border-right: 0; border-top: 1px solid var(--bd-line); }
    .bnw-dash .bd-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bnw-dash .bd-two { grid-template-columns: 1fr; }
    .bnw-dash .bd-drop { grid-template-columns: 1fr; padding: 18px; }
    .bnw-dash .bd-drop .preview { width: 100%; height: 160px; }
    .bnw-dash .bd-banner { grid-template-columns: auto minmax(0, 1fr); }
    .bnw-dash .bd-banner .bd-btn { grid-column: 1 / -1; }
    .bnw-dash .bd-gate { padding: 22px; }
    .bnw-dash .bd-main .row > [class*="col-"] { flex: 0 0 100%; max-width: 100%; }
}
@container (max-width: 520px) {
    .bnw-dash .bd-grid { grid-template-columns: 1fr; }
    .bnw-dash .bd-hrow { grid-template-columns: 60px minmax(0, 1fr); }
    .bnw-dash .bd-hrow img { width: 60px; height: 60px; }
    .bnw-dash .bd-hrow .right { grid-column: 1 / -1; justify-content: flex-start; }
    .bnw-dash .bd-pill { display: none; }
}
/* Browsers without container queries (very old): fall back to viewport width */
@supports not (container-type: inline-size) {
    @media (max-width: 720px) {
        .bnw-dash .bd-body { grid-template-columns: 1fr; }
        .bnw-dash .bd-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; border-right: 0; }
        .bnw-dash .bd-grid, .bnw-dash .bd-split, .bnw-dash .bd-form, .bnw-dash .bd-two { grid-template-columns: 1fr; }
    }
}
