@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   Western Cloud Client Hub
   Same family as WC Monitor: white cards on a cool grey field, one blue for
   actions. Clients see very little chrome - the report is the product.
   ========================================================================== */

:root {
  --brand: #2b6cf6; --brand-600: #1d4fd8; --brand-50: #eaf1ff; --brand-100: #d3e2ff; --cyan: #26a5e0;
  --ink: #0f172a; --ink-2: #475569; --muted: #8b96a8;
  --bg: #f4f7fb; --surface: #fff; --surface-2: #f8fafc; --line: #eaeff5; --line-2: #dfe6ef;
  --good: #16a34a; --good-bg: #e8f8ee; --warn: #b45309; --warn-bg: #fef5e0; --bad: #dc2626; --bad-bg: #fdecec;
  --r: 10px; --r-lg: 14px;
  --shadow: 0 1px 2px rgba(15,23,42,.04), 0 4px 14px rgba(15,23,42,.05);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 14px/1.5 Inter, system-ui, -apple-system, 'Segoe UI', sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-600); }
.tnum, .num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.block { display: block; }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.sp { flex: 1; }
.pad { padding: 18px 20px; }
code { font: 500 13px/1.4 ui-monospace, 'Cascadia Code', Consolas, monospace; background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 2px 6px; word-break: break-all; }
hr { border: 0; border-top: 1px solid var(--line); margin: 4px 0; width: 100%; }
:where(a, button, input, select, textarea, summary):focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 6px; }
svg { flex: 0 0 auto; }

/* ---------------------------------------------------------------- shell -- */
.top { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.top .in { max-width: 1240px; margin: 0 auto; padding: 0 24px; height: 66px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.brand:hover { color: var(--ink); }
.mark { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, #3fb9f0, #1b7fd0); color: #fff; font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; justify-content: center; letter-spacing: .3px; }
.wordmark { display: flex; flex-direction: column; line-height: 1.1; }
.wm { font-weight: 700; font-size: 15px; letter-spacing: -.2px; }
.tag { font-size: 11px; color: var(--muted); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; margin-top: 2px; }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--ink-2); font-weight: 600; padding: 8px 12px; border-radius: 8px; }
.nav a:hover { background: var(--surface-2); color: var(--ink); }
.nav a.active { background: var(--brand-50); color: var(--brand); }
.who { display: flex; align-items: center; gap: 10px; }
.who-t { display: flex; flex-direction: column; line-height: 1.2; }
.who-t b { font-size: 13px; font-weight: 600; }
.who-t small { font-size: 11.5px; color: var(--muted); }
.who form { margin: 0; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-50); color: var(--brand); font-weight: 700; font-size: 12px; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.avatar.sm { width: 30px; height: 30px; font-size: 11px; }
.avatar.anon { background: #f1f5f9; color: var(--ink-2); }
.avatar svg { width: 15px; height: 15px; }
.main { max-width: 1240px; margin: 0 auto; padding: 28px 24px 64px; }
.switch { display: flex; align-items: center; gap: 8px; margin: 0; padding: 0 4px 0 12px; height: 38px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface-2); min-width: 0; }
.switch:focus-within { border-color: var(--brand); background: #fff; }
.switch > svg { width: 16px; height: 16px; color: var(--brand); flex: 0 0 auto; }
.switch select { border: 0; background: transparent; font: inherit; font-weight: 600; color: var(--ink); height: 36px; max-width: 240px; min-width: 0; cursor: pointer; padding-right: 4px; }
.switch select:focus-visible { outline: none; }

@media (max-width: 760px) {
  .top .in { gap: 12px; padding: 0 16px; height: 58px; }
  .top .in:has(.switch) { flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 10px; row-gap: 8px; }
  .top .in:has(.switch) .sp { display: none; }
  .top .in:has(.switch) .who { margin-left: auto; }
  .switch { order: 5; flex: 1 0 100%; }
  .switch select { max-width: none; flex: 1; }
  .wordmark, .who-t { display: none; }
  .nav { overflow-x: auto; }
  .nav a { padding: 7px 9px; }
  .main { padding: 20px 16px 48px; }
}

/* ---------------------------------------------------------- page bits -- */
.page-head { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-size: 24px; letter-spacing: -.4px; }
.page-head .sub { margin: 4px 0 0; color: var(--ink-2); max-width: 70ch; }
.back { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; color: var(--ink-2); margin-bottom: 8px; }
.back svg { width: 15px; height: 15px; }
.page-sub { display: flex; align-items: center; gap: 12px; margin: 28px 0 12px; }
.page-sub h2 { margin: 0; font-size: 17px; flex: 1; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow); margin-bottom: 18px; min-width: 0; }
.card-h { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.card-h h2 { margin: 0; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.card-h h2 svg { width: 17px; height: 17px; color: var(--brand); }
.card-h .hint { color: var(--muted); font-size: 12.5px; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.cols > .card { margin-bottom: 0; }
.cols + .card, .cols + .cols, .card + .cols { margin-top: 18px; }
.cols.wide-left { grid-template-columns: 1.6fr 1fr; }
@media (max-width: 960px) { .cols, .cols.wide-left { grid-template-columns: 1fr; } }

.flash { padding: 11px 14px; border-radius: var(--r); margin-bottom: 18px; font-weight: 500; background: var(--good-bg); color: #14532d; border: 1px solid #bfe9cf; }
.flash.bad { background: var(--bad-bg); color: #7f1d1d; border-color: #f6caca; }

.secret { display: flex; gap: 18px; align-items: flex-start; padding: 18px 20px; border-color: #fcd98a; background: #fffbeb; flex-wrap: wrap; }
.secret > div { flex: 1; min-width: 260px; }
.secret h3 { margin: 0 0 4px; display: flex; align-items: center; gap: 8px; font-size: 15px; }
.secret p { margin: 0 0 10px; color: var(--ink-2); }
.secret dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0; }
.secret dt { color: var(--ink-2); font-weight: 600; }
.secret dd { margin: 0; }

/* -------------------------------------------------------------- stats -- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
.stats.six { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 1100px) { .stats.six { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) { .stats, .stats.six { grid-template-columns: repeat(2, 1fr); } }
.stat { padding: 16px 18px; margin: 0; display: flex; flex-direction: column; gap: 4px; }
.stat .lbl { display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.stat .lbl svg { width: 15px; height: 15px; color: var(--brand); }
.stat .num { font-size: 26px; font-weight: 700; letter-spacing: -.5px; line-height: 1.15; }
.stat small { color: var(--ink-2); font-size: 12.5px; }

/* ------------------------------------------------------------- tables -- */
.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: 11.5px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding: 10px 20px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl th.r { text-align: right; }
.tbl td { padding: 12px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr.off td { opacity: .55; }
.tbl small { font-size: 12px; }
.plain { list-style: none; margin: 0; padding: 6px 0; }
.plain li { padding: 10px 20px; border-bottom: 1px solid var(--line); }
.plain li:last-child { border-bottom: 0; }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: #f1f5f9; color: var(--ink-2); white-space: nowrap; vertical-align: middle; }
.pill svg { width: 12px; height: 12px; }
.pill.blue { background: var(--brand-50); color: var(--brand); }
.pill.gray { background: #f1f5f9; color: var(--ink-2); }

/* ------------------------------------------------------------ buttons -- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 15px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font: 600 13.5px/1 inherit; font-family: inherit; cursor: pointer; white-space: nowrap; }
.btn:hover { background: var(--surface-2); color: var(--ink); }
.btn svg { width: 16px; height: 16px; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }
.btn.danger { color: var(--bad); }
.btn.danger:hover { background: var(--bad-bg); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn.sm { height: 32px; padding: 0 11px; font-size: 12.5px; }
.btn.wide { width: 100%; height: 44px; }
.iconbtn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; border: 0; background: transparent; color: var(--ink-2); cursor: pointer; vertical-align: middle; }
.iconbtn:hover { background: var(--surface-2); color: var(--ink); }
.iconbtn.copied { color: var(--good); background: var(--good-bg); }
.iconbtn svg { width: 17px; height: 17px; }
form.inline { display: inline; margin: 0; }

/* -------------------------------------------------------------- forms -- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field em { font-style: normal; font-weight: 400; color: var(--muted); }
input[type=text], input[type=email], input[type=password], select, textarea { width: 100%; height: 40px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 9px; background: #fff; color: var(--ink); font: inherit; }
input[type=file] { font: inherit; font-size: 13px; max-width: 100%; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(43,108,246,.13); }
.grid-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.grid-form .span2 { grid-column: span 2; }
@media (max-width: 640px) { .grid-form { grid-template-columns: 1fr; } .grid-form .span2 { grid-column: auto; } }
.check { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; }
.check input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--brand); }
.check span { display: flex; flex-direction: column; }
.check small { color: var(--ink-2); }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; gap: 10px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.row form { margin: 0; }

/* ----------------------------------------------------- client portal -- */
.rgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.rcard { display: flex; flex-direction: column; gap: 6px; padding: 20px; margin: 0; color: var(--ink); transition: transform .12s, box-shadow .12s, border-color .12s; }
.rcard:hover { color: var(--ink); border-color: var(--brand-100); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(15,23,42,.09); }
.rc-ic { width: 42px; height: 42px; border-radius: 11px; background: var(--brand-50); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; margin-bottom: 6px; }
.rc-ic svg { width: 21px; height: 21px; }
.rc-t { font-weight: 700; font-size: 15.5px; letter-spacing: -.2px; }
.rc-p { color: var(--ink-2); }
.rc-f { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12.5px; }
.rc-go { margin-left: auto; color: var(--brand); font-weight: 600; display: inline-flex; align-items: center; gap: 5px; }
.rc-go svg { width: 14px; height: 14px; }
.empty { text-align: center; padding: 48px 20px; }
.empty > svg { width: 34px; height: 34px; color: var(--muted); }
.empty h3 { margin: 10px 0 4px; }
.empty p { margin: 0; color: var(--ink-2); }

/* ------------------------------------------------------- report admin -- */
.linkbar { padding: 14px 20px; display: flex; flex-direction: column; gap: 12px; }
.lb-state { display: flex; align-items: center; gap: 10px; color: var(--ink-2); flex-wrap: wrap; }
.lb-url { display: flex; gap: 10px; flex-wrap: wrap; }
.lb-url input { flex: 1; min-width: 240px; font: 500 13px ui-monospace, Consolas, monospace; color: var(--ink-2); background: var(--surface-2); }
.lb-url form { margin: 0; }

.toggle { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-2); font-weight: 600; font-size: 13px; }
.toggle .sw { width: 32px; height: 18px; border-radius: 999px; background: var(--line-2); position: relative; transition: background .15s; }
.toggle .sw::after { content: ''; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: left .15s; }
.toggle.on .sw { background: var(--brand); }
.toggle.on .sw::after { left: 16px; }

.secbars { padding: 12px 20px 16px; display: flex; flex-direction: column; gap: 4px; }
.sb { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(60px, 1fr) 64px 44px; gap: 12px; align-items: center; padding: 6px 0; }
.sb.mini { grid-template-columns: minmax(0, 1.3fr) minmax(50px, 1fr) 60px; padding: 3px 0; font-size: 13px; }
.sb-t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.sb-bar { height: 10px; border-radius: 999px; background: #eef2f7; overflow: hidden; }
.sb-bar i { display: block; height: 100%; border-radius: 999px; background: var(--brand); min-width: 2px; }
.sb-v { text-align: right; font-weight: 600; }
.sb-r { text-align: right; color: var(--ink-2); font-size: 12.5px; }
.sb-r.low { color: var(--warn); font-weight: 600; }

.sessions { display: flex; flex-direction: column; }
.sess { border-bottom: 1px solid var(--line); }
.sess:last-child { border-bottom: 0; }
.sess summary { list-style: none; display: grid; grid-template-columns: 30px minmax(0, 1fr) 80px 70px 60px 92px 110px; gap: 14px; align-items: center; padding: 12px 20px; cursor: pointer; }
.sess summary::-webkit-details-marker { display: none; }
.sess summary:hover { background: var(--surface-2); }
.sess[open] summary { background: var(--surface-2); }
.ss-who { display: flex; flex-direction: column; min-width: 0; }
.ss-who b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-who small { color: var(--muted); font-size: 12px; display: flex; align-items: center; gap: 5px; overflow: hidden; white-space: nowrap; }
.ss-who small svg { width: 13px; height: 13px; }
.ss-m { display: flex; flex-direction: column; text-align: right; line-height: 1.25; }
.ss-m small, .ss-when small { color: var(--muted); font-size: 11.5px; }
.ss-when { display: flex; flex-direction: column; text-align: right; font-size: 13px; line-height: 1.25; }
.ss-body { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 6px 20px 18px 64px; background: var(--surface-2); }
.ss-body h4 { margin: 8px 0 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.ss-body p { margin: 0; }
.timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
@media (max-width: 860px) {
  .sess summary { grid-template-columns: 30px minmax(0, 1fr) 70px; }
  .sess summary .ss-m:nth-of-type(n+2), .sess summary .ss-when { display: none; }
  .ss-body { grid-template-columns: 1fr; padding-left: 20px; }
}

/* --------------------------------------------------------------- login -- */
body.auth { min-height: 100vh; background: radial-gradient(1200px 600px at 10% -10%, #dbe9ff 0, transparent 60%), radial-gradient(900px 500px at 110% 110%, #d9f1fb 0, transparent 60%), var(--bg); }
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; }
.login { width: 100%; max-width: 400px; padding: 32px; display: flex; flex-direction: column; gap: 14px; margin: 0; }
.login .brand { margin-bottom: 10px; }
.login h1 { margin: 0; font-size: 21px; letter-spacing: -.3px; }
.login .sub { margin: -8px 0 4px; color: var(--ink-2); }
.login .flash { margin: 0; }
.login .fine { margin: 4px 0 0; color: var(--muted); font-size: 12.5px; text-align: center; }
body.auth.staff { background: radial-gradient(1200px 600px at 10% -10%, #1e3a6e 0, transparent 60%), #0f1b33; }

/* ===================================================== admin backend == */
body.admin { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.side { background: #0f1b33; color: #c7d2e5; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; padding: 18px 14px; }
.side .brand { color: #fff; padding: 4px 8px 20px; }
.side .brand:hover { color: #fff; }
.side .tag { color: #7d8cab; }
.snav { display: flex; flex-direction: column; gap: 2px; }
.snav a { display: flex; align-items: center; gap: 11px; color: #c7d2e5; font-weight: 600; padding: 10px 12px; border-radius: 9px; }
.snav a svg { width: 18px; height: 18px; color: #7d8cab; }
.snav a:hover { background: rgba(255,255,255,.06); color: #fff; }
.snav a.active { background: var(--brand); color: #fff; }
.snav a.active svg { color: #fff; }
.side-foot { margin-top: auto; border-top: 1px solid rgba(255,255,255,.08); padding-top: 14px; }
.side .who { gap: 9px; }
.side .who-t { flex: 1; min-width: 0; }
.side .who-t b { color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side .who-t small { color: #7d8cab; }
.side .avatar { background: rgba(255,255,255,.1); color: #fff; }
.side .iconbtn { color: #7d8cab; }
.side .iconbtn:hover { background: rgba(255,255,255,.08); color: #fff; }
.amain { padding: 28px 32px 64px; max-width: 1280px; width: 100%; min-width: 0; }
@media (max-width: 900px) {
  body.admin { display: block; }
  .side { position: sticky; z-index: 10; height: auto; flex-direction: row; align-items: center; gap: 8px; padding: 8px 12px; overflow-x: auto; }
  .side .brand { padding: 0; }
  .side .wordmark, .side .who-t, .snav a span { display: none; }
  .snav { flex-direction: row; }
  .side-foot { margin: 0 0 0 auto; border: 0; padding: 0; }
  .side .who .avatar { display: none; }
  .amain { padding: 20px 16px 48px; }
}

.stat.link { color: var(--ink); transition: border-color .12s, box-shadow .12s; }
.stat.link:hover { color: var(--ink); border-color: var(--brand-100); box-shadow: 0 8px 22px rgba(15,23,42,.08); }
.stat.link small { color: var(--brand); font-weight: 600; }
.stats.three { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 760px) { .stats.three { grid-template-columns: 1fr; } }
.num.sm { font-size: 15px; letter-spacing: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 6px 0 4px; }

.search { display: flex; align-items: center; gap: 8px; flex: 1; max-width: 360px; margin: 0; }
.search svg { width: 17px; height: 17px; color: var(--muted); }
.search input { height: 36px; }
.rowlink { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.rowlink:hover { color: var(--brand); }
.rows-link tbody tr:hover td { background: var(--surface-2); }
.avatar.sq { border-radius: 10px; }
.avatar.lg { width: 56px; height: 56px; font-size: 18px; border-radius: 14px; }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.small { font-size: 12.5px; margin: 0; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

.note { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: var(--r); margin-bottom: 18px; background: var(--brand-50); color: #1e3a8a; border: 1px solid var(--brand-100); }
.note svg { width: 18px; height: 18px; flex: 0 0 auto; }
.note.warn { background: var(--warn-bg); color: #78350f; border-color: #fbd38d; }

/* client profile */
.profile { display: flex; align-items: center; gap: 18px; padding: 20px 22px; flex-wrap: wrap; }
.pf-t { flex: 1; min-width: 220px; }
.pf-t h1 { margin: 0 0 4px; font-size: 22px; letter-spacing: -.3px; }
.pf-t p { margin: 0; font-size: 13px; }
.pf-stats { display: flex; gap: 6px; }
.pf-stats > div { display: flex; flex-direction: column; align-items: center; min-width: 78px; padding: 8px 12px; border-radius: 10px; background: var(--surface-2); }
.pf-stats b { font-size: 19px; }
.pf-stats small { color: var(--muted); font-size: 11.5px; }
@media (max-width: 640px) { .pf-stats { width: 100%; } .pf-stats > div { flex: 1; min-width: 0; } }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line-2); margin: 4px 0 18px; overflow-x: auto; }
.tabs a { display: inline-flex; align-items: center; gap: 7px; padding: 11px 14px; color: var(--ink-2); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a svg { width: 16px; height: 16px; }
.tabs a:hover { color: var(--ink); }
.tabs a.on { color: var(--brand); border-bottom-color: var(--brand); }
.count { background: #eef2f7; color: var(--ink-2); border-radius: 999px; font-size: 11.5px; padding: 1px 7px; }
.tabs a.on .count { background: var(--brand-50); color: var(--brand); }

details.upload > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 15px 20px; cursor: pointer; }
details.upload > summary::-webkit-details-marker { display: none; }
details.upload > summary svg { width: 18px; height: 18px; color: var(--brand); }
details.upload > summary .muted { font-size: 13px; }
details.upload[open] > summary { border-bottom: 1px solid var(--line); }
details.upload:not([open]) > summary:hover { background: var(--surface-2); border-radius: var(--r-lg); }

/* ========================================================= client area == */
.hero { display: flex; align-items: center; gap: 18px; padding: 22px 24px; flex-wrap: wrap; background: linear-gradient(120deg, #fff 55%, var(--brand-50)); }
.hero .rc-ic { margin: 0; width: 52px; height: 52px; border-radius: 14px; }
.hero-t { flex: 1; min-width: 220px; }
.hero-t h2 { margin: 2px 0; font-size: 20px; letter-spacing: -.3px; }
.hero-t p { margin: 0; }
.hero-a { display: flex; gap: 10px; flex-wrap: wrap; }
.eyebrow { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--brand); }
.rlist { list-style: none; margin: 0; padding: 0; }
.rlist li { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--line); }
.rlist li:last-child { border-bottom: 0; }
.rlist li > a:first-child { flex: 1; color: var(--ink); min-width: 0; }
.rlist li > a:first-child:hover b { color: var(--brand); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.foot { text-align: center; color: var(--muted); font-size: 12.5px; padding: 0 16px 32px; }
.iconbtn.danger:hover { background: var(--bad-bg); color: var(--bad); }

/* ------------------------------------------------ comments & requests -- */
.snav a .badge { margin-left: auto; font-style: normal; background: #f59e0b; color: #1f1300; font-size: 11.5px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; }
@media (max-width: 900px) { .snav a .badge { margin-left: 0; } }
a.note { font-weight: 500; }
a.note:hover { color: #1e3a8a; border-color: var(--brand); }
a.note span { display: inline-flex; align-items: center; gap: 4px; flex-wrap: wrap; }
a.note span svg { width: 15px; height: 15px; }
.seg { display: inline-flex; gap: 2px; padding: 3px; background: #f1f5f9; border-radius: 9px; }
.seg a { padding: 5px 12px; border-radius: 7px; color: var(--ink-2); font-weight: 600; font-size: 13px; }
.seg a:hover { color: var(--ink); }
.seg a.on { background: #fff; color: var(--brand); box-shadow: 0 1px 3px rgba(15,23,42,.1); }
.reqs { list-style: none; margin: 0; padding: 0; }
.req { padding: 16px 20px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.req:last-child { border-bottom: 0; }
.req.done .req-msg { color: var(--ink-2); }
.req.done .req-h > .pill:first-child { background: #f1f5f9; color: var(--ink-2); }
.req-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.req-h a.muted { font-size: 13px; }
.req-where { margin: 0; font-size: 13px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.req-where svg { width: 13px; height: 13px; }
.req-msg { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 11px 14px; white-space: normal; overflow-wrap: anywhere; }
.req-f { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.req-f .small { display: inline-flex; align-items: center; gap: 5px; }
.req-f .small svg { width: 14px; height: 14px; color: var(--good); }
.req-on { margin: 0; font-size: 13px; color: var(--ink-2); display: flex; align-items: center; gap: 5px; }
.req-on svg { width: 14px; height: 14px; color: var(--brand); }
.req-rep { display: flex; gap: 10px; margin-left: 18px; padding-left: 14px; border-left: 2px solid var(--line); }
.req-rep p { margin: 2px 0 0; overflow-wrap: anywhere; }
.req-rep .pill { margin: 0 4px; }
.avatar.dark { background: #0f1b33; color: #fff; }
.req-reply > summary { list-style: none; width: max-content; }
.req-reply > summary::-webkit-details-marker { display: none; }
.req-reply[open] > summary { display: none; }
.req-reply form { display: flex; flex-direction: column; gap: 8px; }
.req-reply textarea { height: auto; padding: 10px 12px; resize: vertical; font: inherit; }

/* ---------------------------------------------- email, codes and tasks -- */
.pill.good { background: var(--good-bg); color: var(--good); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.pill.task { background: #e6f7f0; color: #0b7a52; }
.pill.doing { background: #fff4e0; color: #b45309; }
.pill.high { background: var(--bad-bg); color: var(--bad); }
.login-alt { display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; font-size: 13px; }
.login-alt a { display: inline-flex; align-items: center; gap: 6px; }
.login-alt svg { width: 15px; height: 15px; }
.linkbtn { border: 0; background: none; padding: 0; color: var(--brand); font: inherit; font-weight: 500; cursor: pointer; }
.linkbtn:hover { color: var(--brand-600); text-decoration: underline; }
.login input.otp { font: 700 26px/1.2 ui-monospace, 'Cascadia Code', Consolas, monospace; letter-spacing: 10px; text-align: center; padding: 12px; }
.btn.primary.wide svg { width: 16px; height: 16px; }
.email-ctl { gap: 12px; }
.check b { font-weight: 600; }
.task-st { display: inline-flex; gap: 6px; align-items: center; }
.task-st select { height: 32px; padding: 0 8px; border: 1px solid var(--line-2); border-radius: 8px; background: #fff; font: inherit; font-size: 13px; }
.req.task .req-msg { font-weight: 500; }
.sendto { display: flex; flex-direction: column; gap: 8px; }
.sendto .check { padding: 8px 10px; }
.sent-log { list-style: none; margin: 0; padding: 0 20px 16px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.sent-log li { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sent-log .pill { font-size: 11px; }

/* ---------------------------------------------- agencies and businesses -- */
.pf-group { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px !important; }
.pf-group a.pill:hover { background: var(--brand-50); color: var(--brand); }
.pf-group .pill a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.tbl tr.child td:first-child { padding-left: 46px; position: relative; }
.tbl tr.child td:first-child::before { content: ''; position: absolute; left: 30px; top: 0; bottom: 50%; width: 10px; border-left: 2px solid var(--line-2); border-bottom: 2px solid var(--line-2); border-bottom-left-radius: 6px; }

/* ------------------------------------------------------- report page -- */
.rhead { display: flex; align-items: center; gap: 18px; padding: 20px 22px; margin: 6px 0 14px; flex-wrap: wrap; }
.rh-ic { width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, var(--brand-50), #dff3fd); color: var(--brand); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.rh-ic svg { width: 24px; height: 24px; }
.rh-t { flex: 1; min-width: 240px; }
.rh-t h1 { margin: 0; font-size: 22px; letter-spacing: -.4px; line-height: 1.25; }
.rh-t p { margin: 3px 0 0; }
.rh-pills { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.rh-act { display: flex; gap: 8px; flex-wrap: wrap; }
.live { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; color: var(--muted); padding: 3px 10px 3px 8px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); }
.live i { width: 8px; height: 8px; border-radius: 50%; background: #cbd5e1; }
.live.on { color: var(--good); background: var(--good-bg); border-color: #c6ecd3; }
.live.on i { background: var(--good); animation: livepulse 1.6s infinite; }
@keyframes livepulse { 0% { box-shadow: 0 0 0 0 rgba(22,163,74,.5); } 70% { box-shadow: 0 0 0 7px rgba(22,163,74,0); } 100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); } }
@media (prefers-reduced-motion: reduce) { .live.on i { animation: none; } }
.tabs .sp { flex: 1; min-width: 12px; }
.tabs .toggle { border: 0; padding: 0 4px; margin: 0; }

.kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-bottom: 18px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 16px 18px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.kpi > span { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.kpi > span svg { width: 15px; height: 15px; color: var(--brand); }
.kpi b { font-size: 28px; font-weight: 700; letter-spacing: -.6px; line-height: 1.15; }
.kpi b em { font-style: normal; font-size: 14px; color: var(--muted); font-weight: 600; margin-left: 2px; }
.kpi small { color: var(--muted); font-size: 12.5px; }
@media (max-width: 1100px) { .kpis { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .kpis { grid-template-columns: repeat(2, 1fr); } .kpi b { font-size: 23px; } }

.heat { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
.heat.hot { background: #fee2e2; color: #b91c1c; }
.heat.warm { background: #fef3c7; color: #b45309; }
.heat.cold { background: #e0f2fe; color: #0369a1; }

.trend { display: flex; align-items: flex-end; gap: 4px; height: 170px; padding: 20px 20px 6px; }
.tb { flex: 1; height: var(--h); background: linear-gradient(180deg, var(--brand), #6b9bfa); border-radius: 4px 4px 2px 2px; min-width: 3px; transition: opacity .15s; }
.tb.z { background: var(--line); }
.tb:hover { opacity: .75; }
.trend-x { display: flex; justify-content: space-between; padding: 0 20px 14px; font-size: 12px; }

.geo { list-style: none; margin: 0; padding: 10px 20px 4px; display: flex; flex-direction: column; gap: 4px; }
.geo li { display: grid; grid-template-columns: 26px minmax(0, 1fr) 90px 34px; gap: 10px; align-items: center; padding: 5px 0; }
/* Windows has no flag emoji: this font draws just the flags (78 KB, loaded only when a flag shows). */
@font-face { font-family: 'Flags'; src: url('https://cdn.jsdelivr.net/npm/country-flag-emoji-polyfill@0.1.8/dist/TwemojiCountryFlags.woff2') format('woff2'); unicode-range: U+1F1E6-1F1FF; font-display: swap; }
.flag { font-size: 18px; line-height: 1; font-family: 'Flags', 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; }
.flag svg { width: 16px; height: 16px; color: var(--muted); }
.ss-who .flag, small .flag { font-size: 14px; }
.g-n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.g-bar { height: 8px; border-radius: 999px; background: #eef2f7; overflow: hidden; }
.g-bar i { display: block; height: 100%; background: var(--cyan); border-radius: 999px; }
.geo b { text-align: right; }
.split { border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.split-bar { display: flex; height: 10px; border-radius: 999px; overflow: hidden; background: #eef2f7; }
.split-bar i, .split-l i { background: var(--brand); }
.split-bar .d-mobile, .split-l i.d-mobile { background: var(--cyan); }
.split-bar .d-tablet, .split-l i.d-tablet { background: #a78bfa; }
.split-l { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12.5px; color: var(--ink-2); }
.split-l span { display: inline-flex; align-items: center; gap: 5px; }
.split-l i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.split-l svg { width: 13px; height: 13px; }

.card-f { display: flex; align-items: center; gap: 7px; padding: 12px 20px; border-top: 1px solid var(--line); font-weight: 600; font-size: 13px; }
.card-f svg { width: 15px; height: 15px; }
.card-f svg:last-child { margin-left: auto; }
.card-f:hover { background: var(--surface-2); border-radius: 0 0 var(--r-lg) var(--r-lg); }
.stack-cards { display: flex; flex-direction: column; gap: 18px; }
.stack-cards > .card { margin: 0; }
.heat-cta { display: flex; align-items: center; gap: 14px; padding: 18px 20px; color: var(--ink); background: linear-gradient(120deg, #fff 40%, #fff4ec); transition: transform .15s, box-shadow .15s, border-color .15s; }
.heat-cta:hover { color: var(--ink); transform: translateY(-2px); border-color: #fed7aa; box-shadow: 0 10px 24px rgba(249,115,22,.12); }
.heat-cta > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; }
.heat-cta small { color: var(--ink-2); font-size: 12.5px; }
.heat-cta > svg { width: 16px; height: 16px; color: var(--muted); }
.hc-ic { width: 44px; height: 44px; border-radius: 12px; background: linear-gradient(135deg, #f97316, #dc2626); color: #fff; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.hc-ic svg { width: 22px; height: 22px; }
.copied { list-style: none; margin: 0; padding: 8px 20px; display: flex; flex-direction: column; }
.copied li { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.copied li:last-child { border-bottom: 0; }
.copied q { font-weight: 500; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.act { display: inline-flex; align-items: center; gap: 10px; }
.act > span:last-child { display: flex; flex-direction: column; line-height: 1.3; }
.act small { font-size: 11.5px; }
.act-ic { width: 30px; height: 30px; border-radius: 8px; background: var(--brand-50); color: var(--brand); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.act-ic svg { width: 15px; height: 15px; }

.heatbar { display: flex; align-items: center; gap: 12px; padding: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.seg { display: inline-flex; gap: 2px; padding: 3px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 11px; flex-wrap: wrap; }
.seg a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 8px; color: var(--ink-2); font-weight: 600; font-size: 13px; white-space: nowrap; }
.seg a svg { width: 15px; height: 15px; }
.seg a:hover { color: var(--ink); background: #fff; }
.seg a.on { background: #fff; color: var(--brand); box-shadow: 0 1px 3px rgba(15,23,42,.1); }
.seg.sm a { padding: 6px 10px; font-size: 12.5px; }
.heat-hint { display: flex; align-items: center; gap: 8px; margin: 0 4px 12px; font-size: 13px; flex-wrap: wrap; }
.heat-hint > svg { width: 15px; height: 15px; color: var(--brand); }
.legend { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-size: 12px; }
.legend i { width: 120px; height: 8px; border-radius: 999px; background: linear-gradient(90deg, #2563eb, #06b6d4, #22c55e, #facc15, #f97316, #dc2626); }
.heatframe { background: #e2e8f0; border: 1px solid var(--line-2); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); }
.heatframe iframe { display: block; width: 100%; height: calc(100vh - 230px); min-height: 520px; border: 0; background: #fff; }
.heatframe.mobile { padding: 24px 0; background: repeating-linear-gradient(45deg, #eef2f7, #eef2f7 10px, #e5eaf1 10px, #e5eaf1 20px); }
.heatframe.mobile iframe { width: 390px; max-width: 100%; margin: 0 auto; border-radius: 22px; box-shadow: 0 0 0 8px #0f172a, 0 20px 40px rgba(15,23,42,.25); }

.ss-who b { display: flex; align-items: center; gap: 6px; }
.ss-who b .pill { font-size: 10.5px; padding: 1px 7px; }
.ss-body .span-all { grid-column: 1 / -1; }
.journey { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 0; align-items: center; }
.journey li { position: relative; display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; background: #fff; border: 1px solid var(--line-2); border-radius: 999px; padding: 4px 10px; }
.journey li b { color: var(--brand); font-weight: 600; }
.journey li + li { margin-left: 16px; }
.journey li + li::before { content: ""; position: absolute; left: -17px; top: 50%; width: 16px; height: 2px; background: var(--line-2); }

.danger-zone .dz { display: flex; align-items: center; gap: 16px; padding: 14px 20px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.danger-zone .dz:last-child { border-bottom: 0; }
.danger-zone .dz > div { flex: 1; min-width: 220px; display: flex; flex-direction: column; }
.danger-zone .dz small { color: var(--ink-2); }
.danger-zone form { margin: 0; }
@media (max-width: 760px) {
  .rh-act { width: 100%; } .rh-act .btn { flex: 1; }
  .heatbar .seg { width: 100%; } .heatbar .seg a { flex: 1; justify-content: center; }
  .legend { margin-left: 0; }
}
.ss-m .heat { align-self: flex-end; }

/* ------------------------------------------------ filters and labels -- */
.filterbar { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.filterbar .search { flex: 1 1 240px; }
.search.sm { flex: 0 1 240px; }
.search input[type=search] { width: 100%; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line-2); background: #fff; color: var(--ink-2); font: 600 12.5px/1 inherit; font-family: inherit; cursor: pointer; transition: background .12s, border-color .12s, color .12s; }
.chip:hover { border-color: var(--brand-100); color: var(--ink); }
.chip span { color: var(--muted); font-weight: 600; }
.chip svg { width: 14px; height: 14px; }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip.on span { color: rgba(255,255,255,.7); }
.chip.warn:not(.on) { color: var(--warn); border-color: #f6dca5; background: var(--warn-bg); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: hsl(var(--h) 70% 50%); flex: 0 0 auto; }
.biz { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; padding: 3px 10px 3px 8px; border-radius: 999px; background: hsl(var(--h) 85% 95%); color: hsl(var(--h) 55% 32%); white-space: nowrap; }
.biz::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: hsl(var(--h) 70% 50%); }
a.biz:hover { background: hsl(var(--h) 85% 90%); color: hsl(var(--h) 55% 26%); }
.biz.sm { font-size: 11px; padding: 1px 8px 1px 6px; vertical-align: 1px; }
.eyebrow .biz { text-transform: none; letter-spacing: 0; }
.avatar[style*="--h"] { background: hsl(var(--h) 85% 94%); color: hsl(var(--h) 55% 35%); }

/* ------------------------------------------------------- clients list -- */
.newclient { margin-bottom: 18px; }
.clients-tbl .crow { display: flex; align-items: center; gap: 8px; }
.fold, .fold-sp { width: 28px; height: 28px; flex: 0 0 28px; }
.fold { display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line-2); border-radius: 8px; background: #fff; color: var(--ink-2); cursor: pointer; }
.fold:hover { border-color: var(--brand-100); color: var(--brand); }
.fold svg { width: 15px; height: 15px; transition: transform .15s; }
.fold[aria-expanded="true"] svg { transform: rotate(90deg); }
.clients-tbl tr.agency.open td { background: #f8fbff; }
.clients-tbl tr.child td { background: #fbfcfe; }
.clients-tbl tr.child td:first-child { padding-left: 70px; }
.clients-tbl tr.child td:first-child::before { left: 54px; }

/* ------------------------------------------------------ send result -- */
.pop { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(15,23,42,0); transition: background .2s; }
.pop.in { background: rgba(15,23,42,.45); }
.pop.out { background: rgba(15,23,42,0); }
.pop-card { width: 100%; max-width: 440px; background: #fff; border-radius: 20px; padding: 30px 28px 24px; text-align: center; box-shadow: 0 30px 70px rgba(15,23,42,.3); transform: scale(.7); opacity: 0; transition: transform .35s cubic-bezier(.2,1.4,.4,1), opacity .2s; }
.pop.in .pop-card { transform: scale(1); opacity: 1; }
.pop.out .pop-card { transform: scale(.9); opacity: 0; }
.pop[data-pop="bad"].in .pop-card { animation: shake .45s .3s; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
.pop-card h2 { margin: 14px 0 6px; font-size: 22px; letter-spacing: -.4px; }
.pop-card p { margin: 0 0 10px; color: var(--ink-2); }
.pop-ic { width: 76px; height: 76px; margin: 0 auto; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.pop-ic.ok { background: var(--good-bg); color: var(--good); }
.pop-ic.bad { background: var(--bad-bg); color: var(--bad); }
.pop-ic svg { width: 52px; height: 52px; fill: none; stroke: currentColor; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.pop-ic circle { stroke-width: 2.5; opacity: .35; stroke-dasharray: 151; stroke-dashoffset: 151; }
.pop-ic path { stroke-dasharray: 40; stroke-dashoffset: 40; }
.pop.in .pop-ic circle { animation: draw .5s .15s forwards; }
.pop.in .pop-ic path { animation: draw .35s .5s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.pop-list { list-style: none; margin: 12px 0; padding: 0; display: flex; flex-direction: column; gap: 6px; text-align: left; }
.pop-list li { display: flex; align-items: flex-start; gap: 8px; padding: 9px 12px; border-radius: 10px; font-weight: 500; flex-wrap: wrap; }
.pop-list li svg { width: 16px; height: 16px; margin-top: 2px; }
.pop-list li small { flex-basis: 100%; padding-left: 24px; color: var(--ink-2); font-weight: 400; }
.pop-list li.ok { background: var(--good-bg); color: #14532d; }
.pop-list li.ok svg { color: var(--good); }
.pop-list li.bad { background: var(--bad-bg); color: #7f1d1d; }
.pop-list li.bad svg { color: var(--bad); }
.pop-a { display: flex; gap: 10px; justify-content: center; margin-top: 16px; }
.pop-a .btn { min-width: 120px; }
.confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1001; }
@media (prefers-reduced-motion: reduce) { .pop-card, .pop { transition: none; } .pop.in .pop-card { animation: none; } .pop-ic circle, .pop-ic path { stroke-dashoffset: 0; animation: none !important; } }
.spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255,255,255,.45); border-top-color: #fff; display: inline-block; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ------------------------------------------------------ two-step bits -- */
.check > svg { width: 18px; height: 18px; color: var(--good); margin-top: 2px; flex: 0 0 auto; }
.check.trust { margin: 2px 0 4px; text-align: left; }
[hidden] { display: none !important; }

/* ------------------------------------------------ video & more reports -- */
.vid-card { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.vid-thumb { position: relative; flex: 0 0 220px; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: linear-gradient(135deg, var(--brand), #7c3aed); box-shadow: var(--shadow); }
.vid-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.vid-play { position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%; background: rgba(255,255,255,.95); color: var(--brand); display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.vid-play svg { width: 20px; height: 20px; margin-left: 3px; fill: currentColor; }
.vid-thumb em { position: absolute; right: 7px; bottom: 7px; padding: 1px 6px; border-radius: 5px; background: rgba(15,23,42,.8); color: #fff; font-size: 11px; font-weight: 600; font-style: normal; }
.vid-meta { flex: 1; min-width: 200px; display: flex; flex-direction: column; gap: 4px; }
.vid-meta form { margin: 0; }
.vid-change summary { cursor: pointer; color: var(--brand); font-weight: 600; font-size: 13px; margin-bottom: 10px; }
.extras { list-style: none; margin: 0; padding: 8px 20px 0; display: flex; flex-direction: column; }
.extras li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.extras form { margin: 0; }
.ex-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ex-t b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.ext { flex: 0 0 auto; width: 38px; padding: 3px 0; border-radius: 6px; text-align: center; font-size: 10px; font-weight: 700; color: #fff; }
.ext.pdf { background: var(--bad); }
.ext.web { background: var(--brand); }
.tag-mini { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; background: #f1f5f9; color: var(--ink-2); vertical-align: 1px; margin-left: 4px; }
.tag-mini svg { width: 11px; height: 11px; }
.tag-mini.video { background: #f3e8ff; color: #7c3aed; }
.tag-mini.pdf { background: var(--bad-bg); color: var(--bad); }
.r-vid { position: relative; display: inline-block; width: 96px; aspect-ratio: 16 / 9; border-radius: 8px; overflow: hidden; background: linear-gradient(135deg, var(--brand), #7c3aed); vertical-align: middle; flex: 0 0 auto; }
.r-vid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.r-vid span { position: absolute; left: 50%; top: 50%; width: 26px; height: 26px; margin: -13px 0 0 -13px; border-radius: 50%; background: rgba(255,255,255,.95); color: #7c3aed; display: flex; align-items: center; justify-content: center; }
.r-vid svg { width: 12px; height: 12px; margin-left: 2px; fill: currentColor; }
.r-title { display: flex; align-items: center; gap: 12px; }
.hero-vid { position: relative; display: block; width: 220px; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: linear-gradient(135deg, var(--brand), #7c3aed); box-shadow: var(--shadow); flex: 0 0 auto; }
.hero-vid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-vid .vid-play { width: 46px; height: 46px; margin: -23px 0 0 -23px; }
.hero-vid small { position: absolute; left: 8px; bottom: 8px; padding: 2px 8px; border-radius: 6px; background: rgba(15,23,42,.8); color: #fff; font-size: 11.5px; font-weight: 600; }
@media (max-width: 640px) { .vid-thumb, .hero-vid { flex-basis: 100%; width: 100%; } .r-vid { display: none; } }
.hero-vid small svg, .tag-mini.video svg { width: 11px; height: 11px; fill: currentColor; vertical-align: -1px; }
