/* HIVE - dark by default, light via <html data-theme="light"> */
/* Theme */
:root {
  color-scheme: dark;

  --bg: #0B0D12;
  --surface: #14171F;
  --surface-2: #1B1F2A;
  --line: #262B38;
  --line-strong: #333A4A;
  --text: #ECEFF5;
  --muted: #9AA4B8;
  --muted-2: #6C7689;
  --blue: #5B7CFF;
  --blue-ink: #7B95FF;
  --blue-wash: #171E38;
  --green: #29C46B;
  --green-wash: #10251A;
  --amber: #E8A33D;
  --amber-wash: #241C0E;
  --red: #F2555A;

  /* Aliases. Styles written against either naming now resolve - */
  --bg-1: var(--surface);
  --bg-2: var(--surface-2);
  --line-2: var(--line-strong);
  --fg: var(--text);
  --dim: var(--muted);
  --acc: var(--blue);
  --acc-ink: var(--blue-ink);
  --good: var(--green);
  --bad: var(--red);
  --warn: var(--amber);

  --red-wash: #2A1315;
  --slate-wash: #1A1E27;
  --topbar: rgba(11,13,18,.82);
  --shadow: 0 1px 2px rgba(0,0,0,.45), 0 1px 3px rgba(0,0,0,.35);
  --shadow-lg: 0 18px 50px rgba(0,0,0,.55);

  /* Shared across BOTH themes. These were trapped inside the light block, */
  --radius: 14px;
  --font-display: 'IBM Plex Sans', -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'IBM Plex Sans', -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #F5F6F8;
  --surface: #FFFFFF;
  --surface-2: #F0F2F5;
  --line: #E4E7EC;
  --line-strong: #D5DAE1;
  --text: #101828;
  --muted: #667085;
  --muted-2: #98A2B3;
  --blue: #3B6DFF;
  --blue-ink: #2A54D6;
  --blue-wash: #EDF2FF;
  --green: #12A150;
  --green-wash: #E7F6EC;
  --amber: #D9820A;
  --amber-wash: #FDF3E5;
  --red: #E5484D;
  --red-wash: #FDECEC;
  --slate-wash: #EEF0F3;
  --topbar: rgba(255,255,255,.85);
  --shadow: 0 1px 2px rgba(16,24,40,.05), 0 1px 3px rgba(16,24,40,.04);
  --shadow-lg: 0 12px 40px rgba(16,24,40,.14);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
/* One stray wide element used to blow the whole layout out and */
html, body { max-width: 100%; overflow-x: hidden; }
body { background: var(--bg); color: var(--text); font-family: var(--font-body); font-size: 14px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.018em; margin: 0; }
.mono { font-family: var(--font-mono); }
.muted { color: var(--muted); }
.sm { font-size: 13px; } .xs { font-size: 11.5px; }
.mt { margin-top: 14px; } .mt4 { margin-top: 4px; } .mb { margin-bottom: 14px; }
.num { text-align: right; } .full { width: 100%; } .center { text-align: center; }
.row { display: flex; gap: 8px; align-items: center; }

/* topbar */
.topbar { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 22px; padding: 0 20px; height: 58px; background: var(--topbar); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 9px; font-family: var(--font-display); font-weight: 650; font-size: 18px; }
.brand .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px var(--blue-wash); }
.nav { display: flex; gap: 2px; flex: 1; }
.nav a { padding: 7px 12px; border-radius: 8px; color: var(--muted); font-weight: 600; font-size: 14px; }
.nav a:hover { background: var(--surface-2); color: var(--text); }
.nav a.on { background: var(--blue-wash); color: var(--blue-ink); }
.topbar-right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.who { font-size: 13px; color: var(--muted); font-weight: 600; }

/* layout */
/* .wrap is defined once, in the LAYOUT block further down */
.empty { padding: 44px; text-align: center; color: var(--muted); }
.count { color: var(--muted); font-size: 13px; font-family: var(--font-mono); margin: 2px 2px 14px; }
.pagehead { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.pagehead .muted { font-family: var(--font-mono); font-size: 13px; }
.head-actions { display: flex; gap: 8px; }
.h1 { font-size: clamp(24px, 4vw, 32px); }
.h2 { font-size: 21px; } .h3 { font-size: 16px; }
.display { font-size: clamp(40px, 8vw, 68px); letter-spacing: -.03em; }
.lead { color: var(--muted); font-size: 17px; margin: 8px 0 0; }
.back { display: inline-block; color: var(--muted); font-weight: 600; font-size: 13px; margin-bottom: 14px; }
.back:hover { color: var(--blue-ink); }

/* card */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 20px; } .card.pad0 { overflow: hidden; }
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-family: var(--font-body); font-weight: 600; font-size: 14px; padding: 9px 15px; border-radius: 9px; cursor: pointer; background: var(--surface); color: var(--text); border: 1px solid var(--line-strong); transition: background .12s, border-color .12s, transform .05s; }
.btn:hover { background: var(--surface-2); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-ink); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--surface-2); color: var(--text); }
.btn-danger { color: var(--red); border-color: var(--red-wash); background: var(--red-wash); }
.btn-danger:hover { background: #fbdcdc; }
.btn-sm { padding: 6px 11px; font-size: 13px; border-radius: 8px; }
.btn-xs { padding: 4px 8px; font-size: 12px; border-radius: 7px; }

/* auth */
.landing { max-width: 920px; margin: 0 auto; padding: 40px 20px 80px; }
.hero { text-align: center; padding: 24px 0 4px; }
.hero-badge { display: inline-block; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--blue-ink); background: var(--blue-wash); border: 1px solid #d8e2ff; padding: 5px 12px; border-radius: 999px; }
.hero-h1 { font-family: var(--font-display); font-weight: 650; font-size: clamp(38px, 7vw, 58px); letter-spacing: -.03em; margin: 16px 0 10px; }
.hero-sub { color: var(--muted); font-size: 17px; max-width: 600px; margin: 0 auto; line-height: 1.55; }
.hero-cta { margin-top: 22px; font-size: 15px; padding: 11px 22px; }
.hero-ctas { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.intro-foot { text-align: center; margin-top: 34px; }
.hero-split { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; padding: 30px 0 8px; }
.hero-copy { text-align: left; }
.hero-split .hero-h1 { margin: 16px 0 12px; line-height: 1.02; }
.hero-split .hero-sub { margin: 0; max-width: 480px; }
.hero-note { color: var(--muted-2); font-size: 14px; margin: 10px 0 0; }
.hero-split .hero-cta { margin-top: 0; }
.hero-split .hero-ctas { justify-content: flex-start; margin-top: 24px; }
.hero-media { position: relative; }
.hero-media img { width: 100%; height: 100%; max-height: 480px; object-fit: cover; border-radius: 18px; box-shadow: var(--shadow-lg); display: block; }
.hero-media-tag { position: absolute; left: 16px; bottom: 16px; background: rgba(255,255,255,.93); backdrop-filter: blur(6px); color: var(--text); font-weight: 700; font-size: 13px; padding: 7px 15px; border-radius: 999px; box-shadow: var(--shadow); }
@media (max-width: 760px) {
  .hero-split { grid-template-columns: 1fr; gap: 22px; }
  .hero-copy { text-align: center; }
  .hero-split .hero-sub { margin: 0 auto; }
  .hero-split .hero-ctas { justify-content: center; }
  .hero-media img { max-height: 420px; }
}
.hero a { color: var(--blue-ink); font-weight: 600; cursor: pointer; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 42px 0 6px; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.step-n { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 10px; background: var(--blue); color: #fff; font-family: var(--font-mono); font-weight: 700; font-size: 16px; margin-bottom: 12px; }
.step h3 { font-size: 17px; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: 14px; margin: 0; line-height: 1.55; }
.landing .auth { max-width: 460px; padding-top: 34px; }
.landing-foot { text-align: center; color: var(--muted); font-size: 14px; margin-top: 18px; }
.landing-foot a { color: var(--blue-ink); font-weight: 600; cursor: pointer; }
@media (max-width: 720px) { .steps { grid-template-columns: 1fr; } }
.auth { max-width: 460px; padding-top: 56px; }
.auth-hero { text-align: center; margin-bottom: 26px; }
.auth-card { padding: 22px; }
.seg { display: flex; background: var(--surface-2); border-radius: 10px; padding: 3px; margin-bottom: 18px; }
.segbtn { flex: 1; padding: 8px; border: none; background: transparent; border-radius: 8px; font-weight: 600; color: var(--muted); cursor: pointer; font-family: var(--font-body); font-size: 14px; }
.segbtn.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.auth-foot { text-align: center; margin-top: 16px; font-size: 13px; }
.auth-foot a { color: var(--blue-ink); font-weight: 600; cursor: pointer; }

/* forms */
.input { width: 100%; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 9px; color: var(--text); font-family: var(--font-body); font-size: 14px; }
.input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-wash); }
textarea.input { resize: vertical; }
.fl { display: block; font-size: 12.5px; color: var(--muted); font-weight: 600; margin-bottom: 13px; }
.fl .input, .fl .select { margin-top: 5px; color: var(--text); font-weight: 400; }
.fl.inline { display: flex; align-items: center; gap: 8px; color: var(--text); }
.fl.inline input { width: 16px; height: 16px; accent-color: var(--blue); }
.frow { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .frow { grid-template-columns: 1fr; } }
.select { padding: 10px 12px; background: var(--surface); color: var(--text); border: 1px solid var(--line-strong); border-radius: 9px; font-family: var(--font-body); font-size: 14px; cursor: pointer; }
.select.full { width: 100%; }
.select:focus { outline: none; border-color: var(--blue); }
.checks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-weight: 400; color: var(--text); background: var(--surface-2); padding: 6px 11px; border-radius: 8px; cursor: pointer; text-transform: capitalize; }
.chk input { accent-color: var(--blue); }
.prog { font-family: var(--font-mono); font-size: 13px; color: var(--blue-ink); min-height: 18px; margin: 8px 0; }

/* toolbar / search */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.search { position: relative; flex: 1 1 300px; min-width: 200px; }
.search-input { width: 100%; padding: 10px 14px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px; font-family: var(--font-body); font-size: 14.5px; color: var(--text); }
.search-input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-wash); }

/* chips */
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 14px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; cursor: pointer; background: var(--surface); border: 1px solid var(--line-strong); color: var(--muted); font-size: 12.5px; font-weight: 500; }
.chip:hover { color: var(--text); }
.chip.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.chip-n { font-family: var(--font-mono); font-size: 11px; opacity: .7; }

/* stat grid */
.statgrid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; margin-bottom: 18px; }
.statgrid.four { grid-template-columns: repeat(4, 1fr); }
.statgrid.three { grid-template-columns: repeat(3, 1fr); }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; box-shadow: var(--shadow); }
.stat-n { display: block; font-family: var(--font-mono); font-weight: 700; font-size: 22px; }
.stat-n.green { color: var(--green); } .stat-n.amber { color: var(--amber); } .stat-n.owe { color: var(--red); }
.stat-l { font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
@media (max-width: 860px) { .statgrid, .statgrid.four { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 520px) { .statgrid, .statgrid.four, .statgrid.three { grid-template-columns: repeat(2, 1fr); } }

/* pipeline tabs */
.pipe { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.pipetab { text-transform: capitalize; padding: 7px 13px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); font-weight: 600; font-size: 13.5px; cursor: pointer; display: inline-flex; gap: 7px; align-items: center; }
.pipetab span { font-family: var(--font-mono); font-size: 11.5px; background: var(--surface-2); padding: 1px 7px; border-radius: 999px; }
.pipetab.on { background: var(--text); border-color: var(--text); color: #fff; }
.pipetab.on span { background: rgba(255,255,255,.2); color: #fff; }

/* bulk */
.bulkbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: var(--blue-wash); border: 1px solid #cfdcff; border-radius: 11px; padding: 9px 12px; margin-bottom: 12px; }
.bulk-n { font-weight: 700; font-size: 13px; margin-right: 4px; color: var(--blue-ink); }

/* table */
.dbtable { width: 100%; border-collapse: collapse; font-size: 14px; }
.dbtable thead th { text-align: left; font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.dbtable td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.dbtable.sm td { padding: 8px 10px; }
.dbtable tbody tr:last-child td { border-bottom: none; }
.dbtable tbody tr:hover { background: var(--surface-2); }
.dbtable tr.rowsel { background: var(--blue-wash); }
.cbcol { width: 40px; text-align: center; }
.dbtable input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--blue); cursor: pointer; }
.cn { font-weight: 600; }
.csub { color: var(--muted); font-size: 12.5px; margin-top: 2px; display: flex; flex-wrap: wrap; gap: 5px; align-items: center; }
.cellrow { display: flex; align-items: center; gap: 11px; }
.mini { width: 54px; height: 32px; border-radius: 6px; overflow: hidden; background: var(--surface-2); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: var(--muted-2); font-size: 12px; }
.mini img { width: 100%; height: 100%; object-fit: cover; }
.rowbtns { display: flex; gap: 5px; justify-content: flex-end; white-space: nowrap; }
.owe { color: var(--red); font-weight: 600; }
.link { color: var(--blue-ink); font-weight: 600; }
.link:hover { text-decoration: underline; }

/* pills */
.pill { display: inline-block; font-size: 11.5px; font-weight: 600; padding: 2px 9px; border-radius: 999px; text-transform: capitalize; }
.pill.pending { color: var(--amber); background: var(--amber-wash); }
.pill.active, .pill.verified, .pill.paid { color: var(--green); background: var(--green-wash); }
.pill.paused, .pill.hidden { color: var(--muted); background: var(--slate-wash); }
.pill.banned, .pill.rejected { color: var(--red); background: var(--red-wash); }

/* video cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.card.vid { overflow: hidden; display: flex; flex-direction: column; padding: 0; }
.card-media { position: relative; aspect-ratio: 16/9; background: var(--surface-2); cursor: pointer; overflow: hidden; }
.playicon { position: absolute; inset: 0; margin: auto; width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; background: rgba(16,24,40,.55); color: #fff; border-radius: 50%; font-size: 15px; padding-left: 3px; pointer-events: none; transition: opacity .15s, transform .15s; }
.card-media:hover .playicon { opacity: 0; transform: scale(1.4); }
.mini video { width: 100%; height: 100%; object-fit: cover; }
.player { width: 100%; max-width: 720px; background: #000; border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-lg); }
.player-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; background: var(--surface); }
.player-title { font-weight: 600; font-size: 14px; }
.player-video { width: 100%; max-height: 72vh; display: block; background: #000; }
.player-foot { padding: 12px 14px; background: var(--surface); display: flex; justify-content: flex-end; }
.thumb { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.ph { display: flex; align-items: center; justify-content: center; color: var(--muted-2); font-size: 26px; }
.dur { position: absolute; right: 8px; bottom: 8px; background: rgba(16,24,40,.8); color: #fff; font-family: var(--font-mono); font-size: 11px; padding: 2px 6px; border-radius: 5px; }
.card-body { padding: 13px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.camp { align-self: flex-start; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--blue-ink); background: var(--blue-wash); padding: 2px 8px; border-radius: 6px; }
.camp.sm { font-size: 10px; }
.card-title { font-family: var(--font-body); font-weight: 600; font-size: 14.5px; line-height: 1.3; }
.tags { display: flex; flex-wrap: wrap; gap: 5px; }
.tag { font-size: 11px; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); padding: 1px 7px; border-radius: 5px; text-transform: capitalize; }
.tag.alt { color: var(--blue-ink); background: var(--blue-wash); border-color: #d8e2ff; }
.card-meta { font-family: var(--font-mono); font-size: 12px; color: var(--muted); margin-top: auto; }

/* detail */
.detail-head { display: grid; grid-template-columns: 1fr 300px; gap: 24px; }
.detail-controls { border-left: 1px solid var(--line); padding-left: 20px; }
@media (max-width: 760px) { .detail-head { grid-template-columns: 1fr; } .detail-controls { border-left: none; padding-left: 0; border-top: 1px solid var(--line); padding-top: 16px; } }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr; } }
.payform, .notebox { display: flex; gap: 8px; align-items: flex-start; }
.payform .input { flex: 1; } .notebox textarea { flex: 1; }
.notes { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.note { background: var(--surface-2); border-radius: 9px; padding: 9px 11px; }
.note-body { font-size: 13.5px; }
.note-meta { font-size: 11px; color: var(--muted-2); margin-top: 3px; }
.feed { display: flex; flex-direction: column; gap: 2px; }
.feeditem { display: flex; gap: 10px; padding: 7px 0; }
.feed-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted-2); margin-top: 7px; flex-shrink: 0; }
.feed-dot.staff { background: var(--blue); } .feed-dot.clipper { background: var(--green); }
.feeditem b { font-weight: 600; } .feed-time { font-size: 11px; color: var(--muted-2); margin-top: 2px; }
.status-badge { display: inline-block; text-transform: uppercase; letter-spacing: .05em; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 999px; margin-bottom: 12px; }
.status-badge.pending { color: var(--amber); background: var(--amber-wash); }
.status-badge.paused { color: var(--muted); background: var(--slate-wash); }
.status-badge.banned { color: var(--red); background: var(--red-wash); }

/* scan / upload */
.scanlist { display: flex; flex-direction: column; gap: 4px; max-height: 300px; overflow: auto; }
.scanitem { display: flex; align-items: center; gap: 9px; padding: 7px 9px; border-radius: 8px; background: var(--surface-2); }
.scanitem input { accent-color: var(--blue); }

/* modal */
.modal-bg { position: fixed; inset: 0; background: rgba(16,24,40,.4); backdrop-filter: blur(2px); display: flex; align-items: flex-start; justify-content: center; padding: 44px 16px; z-index: 100; overflow: auto; }
.modal { width: 100%; max-width: 540px; background: var(--surface); border-radius: 16px; padding: 22px; box-shadow: var(--shadow-lg); }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.modal-x { background: none; border: none; color: var(--muted); font-size: 24px; cursor: pointer; }
.modal-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 6px; }
.modal-foot > div { display: flex; gap: 8px; }

/* toast */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--text); color: #fff; padding: 11px 18px; border-radius: 11px; font-size: 14px; z-index: 200; box-shadow: var(--shadow-lg); animation: pop .18s ease; max-width: 90vw; }
.toast.ok { background: var(--green); } .toast.err { background: var(--red); }
@keyframes pop { from { opacity: 0; transform: translate(-50%, 8px); } to { opacity: 1; transform: translate(-50%, 0); } }

@media (max-width: 720px) {
  /* The nav must NEVER be hidden. Most clippers are on a phone; */
  .dbtable thead { display: none; }
  .dbtable, .dbtable tbody, .dbtable tr, .dbtable td { display: block; width: 100%; }
  .dbtable tr { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; padding: 4px; }
  .dbtable td { border: none; padding: 5px 8px; text-align: left; }
  .rowbtns { justify-content: flex-start; }
  .cbcol { display: none !important; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* landing - JRCryptex clipper intro (premium) */
.landing { max-width: 1060px; }
.lx-hero { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; padding: 30px 0 12px; animation: lxUp .5s ease both; }
.lx-copy { text-align: left; }
.lx-eyebrow { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--blue-ink); }
.lx-h1 { font-family: var(--font-display); font-weight: 650; font-size: clamp(38px, 6.2vw, 62px); line-height: 1.02; letter-spacing: -.03em; margin: 14px 0 0; }
.lx-h1 em { font-style: normal; color: var(--blue); position: relative; white-space: nowrap; }
.lx-h1 em::after { content: ''; position: absolute; left: 0; right: 0; bottom: .05em; height: .11em; background: var(--blue); opacity: .22; border-radius: 2px; }
.lx-lead { font-size: clamp(17px, 2.1vw, 20px); font-weight: 600; color: var(--text); margin: 18px 0 0; }
.lx-body { color: var(--muted); font-size: 15.5px; line-height: 1.62; margin: 14px 0 0; max-width: 520px; }
.lx-ctas { display: flex; gap: 10px; flex-wrap: wrap; margin: 26px 0 0; }
.lx-cta { font-size: 15px; padding: 12px 22px; }
.lx-platforms { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 22px 0 0; }
.lx-platforms span { text-transform: uppercase; letter-spacing: .05em; font-weight: 600; font-size: 11.5px; color: var(--muted-2); }
.lx-plat { font-style: normal; font-weight: 600; font-size: 12.5px; color: var(--muted); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 999px; padding: 4px 12px; }

/* signature: hero image as a short-form clip that's performing */
.lx-stage { display: flex; justify-content: center; animation: lxUp .6s ease .08s both; }
.reel { position: relative; width: 100%; max-width: 336px; aspect-ratio: 4/5; margin: 0; border-radius: 26px; overflow: hidden; box-shadow: 0 30px 70px rgba(16,24,40,.28); background: #000; }
.reel img { width: 100%; height: 100%; object-fit: cover; display: block; }
.reel-scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.62) 0%, rgba(0,0,0,0) 44%); }
.reel-live { position: absolute; top: 14px; left: 14px; display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #fff; background: rgba(229,72,77,.92); padding: 4px 10px; border-radius: 999px; }
.reel-play { position: absolute; inset: 0; margin: auto; width: 58px; height: 58px; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,.16); backdrop-filter: blur(4px); border: 1.5px solid rgba(255,255,255,.7); border-radius: 50%; color: #fff; font-size: 17px; padding-left: 4px; }
.reel-cap { position: absolute; left: 16px; right: 16px; bottom: 15px; display: flex; align-items: center; justify-content: space-between; color: #fff; }
.reel-handle { font-weight: 600; font-size: 14px; }
.reel-views { font-family: var(--font-mono); font-size: 12.5px; opacity: .95; }
.reel-views b { font-weight: 700; }

.lx-pillars { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 46px 0 0; }
.lx-pillar { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); }
.lx-pk { display: block; font-family: var(--font-display); font-weight: 650; font-size: 22px; letter-spacing: -.02em; }
.lx-pd { display: block; color: var(--muted); font-size: 14.5px; margin-top: 6px; line-height: 1.5; }

.lx-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 16px 0 0; }
.lx-step { display: flex; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.lx-sn { flex-shrink: 0; width: 30px; height: 30px; display: inline-flex; align-items: center; justify-content: center; border-radius: 9px; background: var(--blue); color: #fff; font-family: var(--font-mono); font-weight: 700; font-size: 14px; }
.lx-step h3 { font-size: 16px; margin: 2px 0 5px; }
.lx-step p { color: var(--muted); font-size: 13.5px; line-height: 1.5; margin: 0; }
.lx-final { text-align: center; margin: 36px 0 0; }

@keyframes lxUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

@media (max-width: 820px) {
  .lx-hero { grid-template-columns: 1fr; gap: 26px; }
  .lx-copy { text-align: center; }
  .lx-body, .lx-lead { margin-left: auto; margin-right: auto; }
  .lx-ctas, .lx-platforms { justify-content: center; }
  .lx-pillars, .lx-steps { grid-template-columns: 1fr; }
  .lx-stage { order: -1; }
}

/* referrals */
.linkbox { display: flex; gap: 8px; margin-top: 10px; }
.linkbox .input { flex: 1; font-size: 13px; }
.reflink-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.reflink-row .mono { margin-top: 3px; word-break: break-all; }
.lstat { display: inline-block; font-size: 11.5px; color: var(--muted); text-transform: capitalize; margin-left: 6px; }
.green-t { color: var(--green); font-weight: 600; }
.stat-n.red { color: var(--red); }
textarea.mono { font-family: var(--font-mono); line-height: 1.5; }
.amber-t { color: var(--amber); font-weight: 600; }

/* executive dashboard */
.kpis { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px; }
.kpi.hero { background: linear-gradient(180deg, #0F172A 0%, #16233F 100%); border-color: #0F172A; }
.kpi.hero .kpi-l { color: rgba(255,255,255,.62); }
.kpi.hero .kpi-n { color: #fff; }
.kpi.hero .kpi-n.owe { color: #7FE3A8; }
.kpi.hero .kpi-s { color: rgba(255,255,255,.48); }
.kpi-l { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; }
.kpi-n { font-family: var(--font-mono); font-weight: 700; font-size: 30px; letter-spacing: -.02em; line-height: 1.15; }
.kpi-n.green { color: var(--green); } .kpi-n.owe { color: var(--red); }
.kpi-s { font-size: 12px; color: var(--muted-2); }
@media (max-width: 980px) { .kpis { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .kpis { grid-template-columns: 1fr; } }

.dgrid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 14px; }
@media (max-width: 900px) { .dgrid { grid-template-columns: 1fr; } }
.panel { display: flex; flex-direction: column; }
.link.sm { font-size: 12.5px; }

.spark { width: 100%; height: 110px; overflow: visible; }
.spark-fill { fill: rgba(59,109,255,.10); }
.spark-line { fill: none; stroke: var(--blue); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.spark-dot { fill: var(--blue); opacity: 0; transition: opacity .12s; }
.spark:hover .spark-dot { opacity: 1; }
.chart-empty { padding: 34px; text-align: center; color: var(--muted-2); font-size: 13px; }

.funnel { display: flex; flex-direction: column; gap: 13px; margin-top: 4px; }
.fnl-top { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 5px; }
.fnl-top b { font-size: 13.5px; }
.fnl-bar { height: 9px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.fnl-bar i { display: block; height: 100%; border-radius: 999px; transition: width .5s cubic-bezier(.2,.8,.2,1); }
.rank { width: 26px; font-family: var(--font-mono); font-size: 12px; color: var(--muted-2); font-weight: 700; }
.lbrow { cursor: pointer; }

/* skeletons */
.skelgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.skel { height: 92px; border-radius: var(--radius); background: linear-gradient(90deg, var(--surface-2) 25%, #E9ECF1 37%, var(--surface-2) 63%); background-size: 400% 100%; animation: shim 1.3s ease infinite; }
@keyframes shim { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* ⌘K palette */
.pal-bg { position: fixed; inset: 0; background: rgba(16,24,40,.42); backdrop-filter: blur(3px); z-index: 300; display: flex; justify-content: center; padding-top: 14vh; }
.pal { width: 100%; max-width: 560px; height: fit-content; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden; animation: palIn .14s ease; }
@keyframes palIn { from { opacity: 0; transform: translateY(-8px) scale(.99); } to { opacity: 1; transform: none; } }
.pal-input { width: 100%; border: none; border-bottom: 1px solid var(--line); padding: 17px 20px; font-family: var(--font-body); font-size: 16px; color: var(--text); background: transparent; }
.pal-input:focus { outline: none; }
.pal-list { max-height: 320px; overflow: auto; padding: 6px; }
.pal-item { display: flex; align-items: center; gap: 10px; padding: 10px 13px; border-radius: 9px; cursor: pointer; }
.pal-item.on { background: var(--blue-wash); }
.pal-kind { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted-2); font-weight: 600; min-width: 48px; }
.pal-label { font-weight: 600; font-size: 14px; }
.pal-sub { color: var(--muted); font-size: 12.5px; margin-left: auto; }
.pal-none { padding: 22px; text-align: center; color: var(--muted-2); font-size: 13px; }
.pal-foot { display: flex; gap: 16px; padding: 9px 16px; border-top: 1px solid var(--line); background: var(--surface-2); font-size: 11px; color: var(--muted-2); }
kbd { font-family: var(--font-mono); font-size: 10px; background: var(--surface); border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 4px; padding: 1px 5px; margin-right: 3px; }
.pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 16px; }
.pager .btn[disabled] { opacity: .4; cursor: not-allowed; }

/* leaderboard / bonus */
.bonusbox { background: linear-gradient(180deg, #0F172A 0%, #16233F 100%); border-color: #0F172A; }
.bonusbox .stat-l { color: rgba(255,255,255,.6); }
.bb-head { display: flex; align-items: baseline; justify-content: space-between; }
.bb-amt { font-family: var(--font-mono); font-weight: 700; font-size: 26px; color: #7FE3A8; }
.bb-bar { height: 10px; background: rgba(255,255,255,.12); border-radius: 999px; overflow: hidden; margin: 14px 0 12px; }
.bb-bar i { display: block; height: 100%; background: linear-gradient(90deg, #3B6DFF, #7FE3A8); border-radius: 999px; transition: width .6s cubic-bezier(.2,.8,.2,1); }
.bb-msg { color: #fff; font-size: 15px; margin: 0 0 6px; }
.bonusbox .muted { color: rgba(255,255,255,.55) !important; }
.bonusbox .green-t { color: #7FE3A8; }
.bonusbox .amber-t { color: #FFCC66; }
.rank.top1 { color: #D9820A; font-size: 14px; }
.rank.top2 { color: #7B8794; }
.rank.top3 { color: #B07A4B; }

/* ---- upload queue ---- */
.uq { margin-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.uq-row {
  display: grid; grid-template-columns: 1fr 140px 92px; gap: 12px; align-items: center;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-1);
}
.uq-name { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uq-bar { height: 6px; border-radius: 99px; background: var(--line); overflow: hidden; }
.uq-fill { height: 100%; width: 0; background: var(--acc); transition: width .25s ease; }
.uq-st { font-size: 12px; color: var(--dim); text-align: right; font-variant-numeric: tabular-nums; }
.uq-st.ok  { color: var(--good); font-weight: 600; }
.uq-st.err { color: var(--bad);  font-weight: 600; }
@media (max-width: 640px) {
  .uq-row { grid-template-columns: 1fr 80px; }
  .uq-bar { grid-column: 1 / -1; }
}
.callout.sm { font-size: 12.5px; line-height: 1.7; }

/* ---- source segment tabs (leads) ---- */
.segrow { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 4px; }
.seg {
  padding: 7px 13px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--bg-1); color: var(--dim); font-size: 13px; font-weight: 500;
  cursor: pointer; display: inline-flex; align-items: center; gap: 7px;
}
.seg b { font-variant-numeric: tabular-nums; color: var(--fg); }
.seg:hover { border-color: var(--line-2); }
.seg.on { background: var(--acc); border-color: var(--acc); color: #fff; }
.seg.on b { color: #fff; }

/* ---- email health ---- */
.statrow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 12px; }
.ministat { padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-1); }
.ms-v { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; }
.ms-v.bad { color: var(--bad); }
.ms-l { font-size: 11px; color: var(--dim); margin-top: 3px; }
.callout.warn { border-color: var(--warn, #b45309); background: rgba(180, 83, 9, .08); }
.callout.warn ul { margin: 6px 0 0; padding-left: 18px; }
.callout.warn li { margin: 3px 0; font-size: 13px; }
.chk { display: flex; align-items: center; gap: 9px; font-size: 14px; cursor: pointer; }
.row.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
@media (max-width: 640px) { .statrow { grid-template-columns: repeat(2, 1fr); } }

/* PULSE - what needs you today */
.todaystrip {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  border-radius: 12px; overflow: hidden; margin-bottom: 14px;
}
.tsi { background: var(--bg-1); padding: 13px 14px; }
.tsi-v { font-size: 21px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.tsi-l { font-size: 11px; color: var(--dim); margin-top: 5px; }
.tsi-l span { opacity: .55; }

.owedbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 13px 16px; border-radius: 12px; margin-bottom: 14px;
  border: 1px solid var(--acc); background: rgba(99,102,241,.07); font-size: 14px;
}
.owedbar b { font-size: 17px; }

.pulsegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 12px; margin-bottom: 20px; }
.pcard {
  border: 1px solid var(--line); border-left: 3px solid var(--dim);
  border-radius: 12px; background: var(--bg-1); padding: 14px 16px;
  display: flex; flex-direction: column; cursor: pointer;
  transition: border-color .15s ease, transform .15s ease;
}
.pcard:hover { transform: translateY(-1px); border-color: var(--line-2); }
.pcard.money { border-left-color: #16a34a; }
.pcard.good  { border-left-color: var(--acc); }
.pcard.todo  { border-left-color: #0ea5e9; }
.pcard.warn  { border-left-color: #d97706; }
.pcard.bad   { border-left-color: var(--bad); }
.pcard-top { display: flex; gap: 12px; align-items: flex-start; }
.pcard-n { font-size: 27px; font-weight: 650; line-height: 1; font-variant-numeric: tabular-nums; min-width: 34px; }
.pcard-l { font-size: 14px; font-weight: 650; line-height: 1.25; }
.pcard-w { font-size: 12px; color: var(--dim); margin-top: 4px; line-height: 1.45; }
.pcard-rows { list-style: none; margin: 11px 0 0; padding: 0; border-top: 1px solid var(--line); }
.pcard-rows li {
  font-size: 12.5px; padding: 5px 0; color: var(--dim);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pcard-rows li b { color: var(--fg); font-weight: 600; }
.pcard-rows li.more { opacity: .6; font-style: italic; }
.pcard-act { margin-top: 10px; font-size: 12px; font-weight: 650; color: var(--acc); }

.allclear {
  padding: 22px; border: 1px dashed var(--line-2); border-radius: 12px;
  text-align: center; color: var(--dim); font-size: 14px; margin-bottom: 20px;
}
.allclear b { color: var(--fg); display: block; margin-bottom: 3px; }

/* ---- collections / folders ---- */
.folderbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.folder {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 13px;
  border: 1px solid var(--line); border-radius: 9px; background: var(--bg-1);
  font-size: 13px; cursor: pointer; color: var(--dim);
}
.folder:hover { border-color: var(--line-2); color: var(--fg); }
.folder.on { background: var(--acc); border-color: var(--acc); color: #fff; }
.folder b { font-variant-numeric: tabular-nums; opacity: .75; font-weight: 600; }
.folder.on b { opacity: .9; }

@media (max-width: 900px) { .todaystrip { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px) { .todaystrip { grid-template-columns: repeat(2, 1fr); } .pulsegrid { grid-template-columns: 1fr; } }

/* CLIPPER - plain and unmissable */
/* .wrap.narrow is set once, in the layout block below */

.moneycard {
  display: flex; gap: 18px; align-items: stretch; flex-wrap: wrap;
  border: 1px solid var(--line); border-radius: 14px; background: var(--bg-1);
  padding: 20px 22px; margin-bottom: 14px;
}
.mc-main { flex: 1 1 220px; }
.mc-l { font-size: 12px; color: var(--dim); text-transform: uppercase; letter-spacing: .06em; }
.mc-n { font-size: 40px; font-weight: 650; line-height: 1.05; margin: 5px 0 6px; font-variant-numeric: tabular-nums; }
.mc-s { font-size: 13px; color: var(--dim); }
.mc-side { display: flex; flex-direction: column; justify-content: center; gap: 12px; padding-left: 18px; border-left: 1px solid var(--line); }
.mc-side div { display: flex; flex-direction: column; }
.mc-side b { font-size: 18px; font-variant-numeric: tabular-nums; }
.mc-side span { font-size: 11px; color: var(--dim); }

.alertbar {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 13px 16px; border-radius: 11px; margin-bottom: 14px; font-size: 14px;
  border: 1px solid var(--line);
}
.alertbar.warn { border-color: #d97706; background: rgba(217,119,6,.08); }
.alertbar.good { border-color: #16a34a; background: rgba(22,163,74,.08); }

.nextcard {
  border: 2px solid var(--acc); border-radius: 14px; padding: 18px 20px;
  background: rgba(99,102,241,.05); margin-bottom: 14px;
}
.nc-tag { font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--acc); }
.nc-do { font-size: 21px; font-weight: 700; margin: 6px 0 4px; line-height: 1.25; }
.nc-why { font-size: 14px; color: var(--dim); }
.nc-btns { display: flex; gap: 9px; margin-top: 14px; flex-wrap: wrap; }

.linkbox { display: flex; gap: 8px; margin-top: 10px; }
.linkbox .input { flex: 1; font-size: 13px; }

.pbar { height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; margin-top: 10px; }
.pbar-f { height: 100%; background: var(--acc); border-radius: 99px; transition: width .4s ease; }

.steps { margin: 10px 0 0; padding-left: 20px; }
.steps li { font-size: 14px; line-height: 1.65; margin-bottom: 4px; }

/* per-referral status - the "why haven't I been paid" killer */
.refrow { border: 1px solid var(--line); border-radius: 11px; padding: 13px 15px; margin-bottom: 9px; }
.refrow.done { border-color: #16a34a; background: rgba(22,163,74,.05); }
.refrow.dead { opacity: .55; }
.rr-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.rr-em { font-size: 13px; }
.rr-paid { font-size: 15px; font-weight: 700; color: #16a34a; }
.rr-pending { font-size: 12px; color: var(--dim); }
.rr-dead { font-size: 12px; color: var(--bad); }
.rr-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 6px; }
.rs { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--dim); }
.rs-dot {
  width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--line-2);
  display: grid; place-items: center; font-size: 10px; flex: 0 0 auto;
}
.rs.on { color: var(--fg); }
.rs.on .rs-dot { background: #16a34a; border-color: #16a34a; color: #fff; }
.rs-l b { color: var(--fg); }
.rr-wait {
  margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--line);
  font-size: 12.5px; color: var(--dim);
}
.paidto { display: flex; align-items: center; gap: 10px; margin-top: 8px; flex-wrap: wrap; }

@media (max-width: 560px) {
  .mc-side { border-left: 0; padding-left: 0; flex-direction: row; gap: 22px; }
  .mc-n { font-size: 34px; }
  .alertbar { flex-direction: column; align-items: flex-start; }
  .rr-steps { grid-template-columns: 1fr 1fr; }
}

/* ---- join Telegram, on the application form ---- */
.tgjoin {
  display: flex; align-items: center; gap: 12px; text-decoration: none;
  border: 1px solid var(--blue); background: var(--blue-wash);
  border-radius: 11px; padding: 13px 15px; margin: 4px 0 14px; color: var(--text);
  transition: transform .12s ease, border-color .12s ease;
}
.tgjoin:hover { transform: translateY(-1px); border-color: var(--blue-ink); }
.tgjoin-i {
  width: 32px; height: 32px; border-radius: 50%; background: var(--blue); color: #fff;
  display: grid; place-items: center; font-size: 16px; flex: 0 0 auto; font-weight: 700;
}
.tgjoin b { font-size: 14px; }

/* Telegram pill on a clipper row */
.tgpill {
  display: inline-flex; align-items: center; gap: 5px; font-size: 11px;
  padding: 2px 7px; border-radius: 99px; background: var(--blue-wash);
  color: var(--blue-ink); font-family: ui-monospace, monospace;
}

/* Link hero */
.linkhero {
  border: 1px solid var(--blue);
  background: linear-gradient(180deg, var(--blue-wash), transparent 70%), var(--surface);
  border-radius: var(--radius);
  padding: 20px 22px 18px;
  margin-bottom: 14px;
}
.lh-tag {
  font-size: 11px; font-weight: 650; letter-spacing: .1em; text-transform: uppercase;
  color: var(--blue-ink); margin-bottom: 11px;
}
.lh-url {
  font-family: var(--font-mono);
  font-size: clamp(15px, 2.6vw, 21px);
  font-weight: 600;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 15px 17px;
  word-break: break-all;
  line-height: 1.35;
  cursor: pointer;
  transition: border-color .15s ease;
}
.lh-url:hover { border-color: var(--blue); }
.lh-actions { display: flex; gap: 9px; margin-top: 11px; flex-wrap: wrap; }
.lh-copy { min-width: 148px; height: 46px; font-size: 15px; font-weight: 700; }
.lh-copy.ok { background: var(--green) !important; border-color: var(--green) !important; }
.lh-actions .btn { height: 46px; display: inline-flex; align-items: center; }

.lh-where {
  display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
  margin-top: 15px; font-size: 13px; color: var(--muted);
}
.lh-where b { color: var(--text); font-weight: 650; }
.lh-where i { color: var(--muted-2); font-style: normal; }
.lh-warn {
  margin: 11px 0 0; font-size: 12.5px; line-height: 1.55; color: var(--muted);
  border-top: 1px solid var(--line); padding-top: 11px;
}
.lh-warn u { text-decoration-color: var(--blue); text-underline-offset: 2px; }

@media (max-width: 560px) {
  .linkhero { padding: 16px 15px 15px; }
  .lh-url { font-size: 14px; padding: 13px 14px; }
  .lh-copy, .lh-actions .btn { flex: 1; justify-content: center; }
}

/* Polish */
/* --- Text selection. Default blue-on-dark is unreadable. --- */
::selection { background: var(--blue); color: #fff; }
::-moz-selection { background: var(--blue); color: #fff; }

/* --- Keyboard focus. Visible for keyboard users, invisible for */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 6px;
}
.btn:focus-visible, .input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--blue); outline-offset: 2px;
}
.input:focus, select:focus, textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-wash);
}

/* --- Mobile tap: kill the grey flash, keep 44px hit targets. --- */
* { -webkit-tap-highlight-color: transparent; }
button, .btn, .nav a, .folder, .seg, .pipetab, [role="button"] {
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}
@media (pointer: coarse) {
  .btn, .nav a, .folder, .seg, .pipetab { min-height: 42px; display: inline-flex; align-items: center; }
  .btn-sm { min-height: 38px; }
  .rowbtns .btn { min-height: 36px; }
}

/* --- Hover only where a pointer actually exists. On touch, :hover */
@media (hover: hover) and (pointer: fine) {
  .btn:hover { filter: brightness(1.08); }
  .btn:active { filter: brightness(.94); transform: translateY(1px); }
  tr:hover .rowbtns { opacity: 1; }
  .card:hover { border-color: var(--line-strong); }
}
@media (hover: none) {
  .pcard:hover, .card:hover, .folder:hover, .tgjoin:hover { transform: none; }
}
.btn { cursor: pointer; transition: filter .12s ease, transform .08s ease, background .15s ease, border-color .15s ease; }
.btn:disabled { opacity: .5; cursor: not-allowed; filter: none !important; transform: none !important; }

/* --- Scrollbars. An untouched light scrollbar on a dark page is */
* { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--muted-2); }

/* --- Inputs shouldn't zoom the page on iOS. Anything under 16px */
.input, select, textarea { font-size: 16px; font-family: inherit; }
@media (min-width: 768px) { .input, select, textarea { font-size: 14.5px; } }
input[readonly] { cursor: pointer; }

/* --- Images and long strings must never blow out a phone layout. --- */
img, video, canvas { max-width: 100%; height: auto; }
.mono, .lh-url, td, .rr-em { overflow-wrap: anywhere; }
table { width: 100%; }

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

/* Layout */
.wrap {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 16px 14px 96px;
}
.wrap.narrow, .narrow { max-width: 720px; }

@media (min-width: 640px)  { .wrap { padding: 22px 22px 96px; } }
@media (min-width: 1024px) { .wrap { padding: 26px 32px 96px; } }
@media (min-width: 1440px) {
  .wrap { padding: 28px 44px 96px; }
  .wrap.narrow, .narrow { max-width: 800px; }
  .pulsegrid { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
}
@media (min-width: 1800px) {
  .wrap { padding: 32px 64px 96px; }
  .wrap.narrow, .narrow { max-width: 860px; }
}
/* Very wide screens: more columns rather than wider ones */
@media (min-width: 2000px) {
  .kpis { grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr; }
}

/* --- Tables */
@media (min-width: 721px) {
  .card.pad0 { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .dbtable { min-width: 640px; }
}
@media (min-width: 1000px) { .dbtable { min-width: 0; } }

/* --- Topbar on a phone: brand + nav scrolls, no wrapping. --- */
@media (max-width: 720px) {
  .topbar { gap: 12px; padding: 0 12px; height: 54px; }
  .nav { overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; font-size: 13.5px; padding: 7px 10px; }
  .who { display: none; }
  .brand { font-size: 16px; }
  .h1 { font-size: 26px; }
  .pagehead { flex-direction: column; align-items: flex-start; gap: 10px; }
  .head-actions { width: 100%; }
  .frow { grid-template-columns: 1fr; }
}

/* --- Consistent card rhythm. --- */
.card { border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.card.pad { padding: 16px 18px; }
@media (min-width: 640px) { .card.pad { padding: 18px 20px; } }
.mb { margin-bottom: 14px; }
.mt { margin-top: 14px; }

/* Scroll performance */
.topbar {
  background: var(--bg);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  will-change: auto;
}
@supports (backdrop-filter: blur(1px)) {
  @media (min-width: 1024px) and (hover: hover) {
    .topbar { background: var(--topbar); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
  }
}

/* Long lists: skip painting rows that are off screen. Costs nothing, */
.pcard, .refrow, .uq-row, .vcard { content-visibility: auto; contain-intrinsic-size: auto 120px; }
.dbtable tbody tr { content-visibility: auto; contain-intrinsic-size: auto 56px; }

/* Promote only what actually animates */
.pbar-f, .uq-fill { will-change: width; }

/* Mobile nav */
@media (max-width: 720px) {
  .topbar {
    height: auto; min-height: 52px; padding: 0 12px;
    display: grid; grid-template-columns: auto 1fr auto;
    grid-template-areas: "brand . right" "nav nav nav";
    row-gap: 0; align-items: center;
  }
  .brand { grid-area: brand; font-size: 16px; }
  .topbar-right { grid-area: right; }
  .nav {
    grid-area: nav;
    display: flex; gap: 2px;
    overflow-x: auto; overscroll-behavior-x: contain;
    scrollbar-width: none; -ms-overflow-style: none;
    padding: 0 0 8px; margin: 0 -12px; padding-left: 12px; padding-right: 12px;
    scroll-snap-type: x proximity;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a {
    white-space: nowrap; flex: 0 0 auto; scroll-snap-align: start;
    font-size: 13.5px; padding: 8px 12px; min-height: 38px;
  }
  .who { display: none; }
}

/* Full-bleed rows on a phone read better than 14px gutters on both sides */
@media (max-width: 480px) {
  .h1 { font-size: 25px; letter-spacing: -.02em; }
  .h3 { font-size: 15px; }
  .moneycard { padding: 16px 16px; gap: 14px; }
  .mc-n { font-size: 32px; }
  .nextcard { padding: 15px 16px; }
  .nc-do { font-size: 18px; }
  .pcard { padding: 13px 14px; }
  .pcard-n { font-size: 23px; }
  .card.pad { padding: 14px 15px; }
  .toast { left: 12px; right: 12px; transform: none; max-width: none; text-align: center; }
  @keyframes pop { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
}

/* Thumbnails */
.thumb-none, .mini-none {
  display: grid; place-items: center;
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--surface-2), var(--surface));
  color: var(--muted-2);
  font-family: var(--font-display);
  font-weight: 650;
  letter-spacing: .04em;
}
.thumb-none span { font-size: 22px; opacity: .55; }
.mini-none { font-size: 11px; border-radius: 8px; }
img.thumb { object-fit: cover; width: 100%; height: 100%; display: block; background: var(--surface-2); }
.mini img { object-fit: cover; width: 100%; height: 100%; display: block; }

/* Numerals line up in columns. Money that jitters between rows reads as sloppy. */
.mono, .kpi-n, .mc-n, .stat-val, .pcard-n, .tsi-v, .ms-v, .rfs-val,
.num, td.num, .lh-url, .meet-stat-val { font-variant-numeric: tabular-nums; }
.lh-url { font-weight: 500; letter-spacing: -0.01em; }