/* The Alt/Lab — Partner Pre-Launch Portal
   Calibrated to Karpa's real scale: off-white bg, navy ink, blue accents, green checks.
   Poppins [display] + Inter [body]. */

:root {
  --bg: #f4f5fa;
  --card: #ffffff;
  --ink: #101828;
  --ink-navy: #0b1524;
  --ink-dim: #667085;
  --ink-faint: #98a2b3;
  --line: #e6e8f1;
  --line-soft: #eef0f6;

  --blue: #2563eb;
  --blue-strong: #0051d5;
  --blue-tint: #eff4ff;
  --blue-tint-line: #c7d7fe;

  --green: #16a34a;
  --green-btn: #43a877;
  --green-btn-h: #3b9a6c;
  --green-tint: #ecfdf3;
  --green-tint-line: #a7f3d0;
  --green-ink: #067647;

  --navy-btn: #0f1b2d;

  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(16,24,40,.04), 0 8px 24px rgba(16,24,40,.05);
  --shadow-card: 0 1px 3px rgba(16,24,40,.06);

  --display: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  zoom: 0.81;                /* global content reduction to Karpa density [~19% total] */
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--display); color: var(--ink-navy); letter-spacing: -0.01em; }

.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding: 40px 34px 104px; flex: 1; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 32px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand .logo {
  font-family: "Archivo", var(--sans);
  font-size: 17px;
  color: var(--ink-navy);
  text-transform: uppercase;
  letter-spacing: 0.24em;
  padding-left: 0.24em;      /* optical balance for the tracking */
  line-height: 1;
}
.logo-mark { flex: none; color: var(--ink-navy); }
.logo-mark rect { fill: currentColor; }

/* two-weight lockmark: bold SCALE + light MED */
.logo .lw1, .logo-lg .lw1 { font-weight: 700; }
.logo .lw2, .logo-lg .lw2 { font-weight: 300; }
.topbar .signout { color: var(--ink-faint); font-size: 15px; }
.topbar .signout:hover { color: var(--ink-dim); text-decoration: none; }

/* ---------- Back link ---------- */
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-faint); font-size: 15px; margin-bottom: 20px; }
.back:hover { color: var(--ink-dim); text-decoration: none; }

/* ---------- Lede ---------- */
.lede { max-width: 780px; margin-bottom: 34px; }
.lede h1 { font-size: clamp(28px, 3.5vw, 34px); line-height: 1.1; margin: 0 0 12px; font-weight: 700; }
.lede p { color: var(--ink-dim); font-size: 16.5px; line-height: 1.5; margin: 0; }

/* ---------- Hub cards ---------- */
.hub-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 1000px) { .hub-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .hub-grid { grid-template-columns: 1fr; } }

.hub-card {
  display: block; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px 22px; box-shadow: var(--shadow-card);
  transition: transform .12s ease, box-shadow .15s ease, border-color .15s ease;
}
.hub-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #d7dbec; text-decoration: none; }
.hub-card .ico { width: 42px; height: 42px; border-radius: 11px; background: #f1f3f9; color: var(--ink-navy); display: grid; place-items: center; margin-bottom: 18px; }
.hub-card h3 { font-size: 20px; margin: 0 0 9px; font-weight: 600; }
.hub-card p { color: var(--ink-dim); font-size: 15px; line-height: 1.5; margin: 0 0 18px; }
.hub-card .open { color: var(--blue); font-weight: 500; font-size: 15px; }

/* ---------- Ready box ---------- */
.ready { margin-top: 32px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-card); padding: 46px 24px; text-align: center; }
.ready h2 { font-size: 27px; margin: 0 0 11px; font-weight: 700; }
.ready p { color: var(--ink-dim); font-size: 16px; margin: 0 0 26px; }

.btn-green { display: inline-block; cursor: pointer; border: 0; background: var(--green-btn); color: #fff; font-family: var(--sans); font-weight: 600; font-size: 16px; padding: 15px 28px; border-radius: 12px; transition: background .15s ease, transform .04s ease; }
.btn-green:hover { background: var(--green-btn-h); text-decoration: none; }
.btn-green:active { transform: translateY(1px); }

/* ---------- Column / tier cards ---------- */
.cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: start; }
@media (max-width: 940px) { .cols { grid-template-columns: 1fr; } }

.col-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-card); padding: 28px 26px; }

.eyebrow { font-family: var(--sans); font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); margin: 0 0 13px; }
.tier-title { font-size: 22px; font-weight: 600; margin: 0 0 10px; }
.tier-big { font-size: 25px; font-weight: 700; margin: 0 0 6px; color: var(--ink-navy); font-family: var(--display); }
.tier-sub { color: var(--ink-dim); font-size: 15.5px; line-height: 1.5; margin: 0 0 20px; }

/* ---------- Check lists ---------- */
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; line-height: 1.45; color: var(--ink); }
.checks li svg { flex: none; margin-top: 2px; width: 20px; height: 20px; }

.section-label { font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--blue-strong); margin: 24px 0 15px; }
.section-label:first-child { margin-top: 0; }
.hr-soft { border: 0; border-top: 1px solid var(--line-soft); margin: 22px 0; }

.addon { background: #f4f6fb; border-radius: var(--radius-sm); padding: 15px 17px; margin: 6px 0 6px 32px; display: flex; gap: 12px; }
.addon .dollar { color: var(--blue-strong); font-weight: 700; flex: none; }
.addon .body b { color: var(--ink-navy); font-weight: 600; font-size: 15px; }
.addon .body .opt { color: var(--ink-faint); font-weight: 400; }
.addon .body p { margin: 5px 0 0; color: var(--ink-dim); font-size: 14px; line-height: 1.5; }

.qrows { margin-top: 4px; }
.qrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 2px; border-bottom: 1px solid var(--line-soft); font-size: 16px; font-weight: 500; color: var(--ink-navy); }
.qrow:last-child { border-bottom: 0; }
.qrow .chev { color: var(--ink-faint); }

/* compact accordion inside column Common Questions */
.qrows .faq-item { border: 0; border-bottom: 1px solid var(--line-soft); border-radius: 0; background: none; }
.qrows .faq-item:last-child { border-bottom: 0; }
.qrows .faq-q { padding: 14px 2px; font-size: 15px; font-weight: 500; }
.qrows .faq-a .inner { padding: 0 2px 15px; font-size: 13.5px; }

.note-line { color: var(--ink-dim); font-size: 15px; line-height: 1.6; margin: 24px 0 0; max-width: 980px; }

/* ---------- Section blocks ---------- */
.block { margin-top: 50px; }
.block > h2 { font-size: 26px; font-weight: 700; margin: 0 0 8px; }
.block > .desc { color: var(--ink-dim); font-size: 15px; line-height: 1.55; margin: 0 0 20px; max-width: 980px; }
.block .foot-note { color: var(--ink-faint); font-size: 14px; margin-top: 13px; }

/* ---------- Tables ---------- */
.tbl-wrap { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--card); }
table { width: 100%; border-collapse: collapse; font-size: 16px; }
thead th { background: #f1f3f9; color: var(--ink-dim); font-family: var(--sans); font-weight: 600; font-size: 15px; text-align: left; padding: 15px 20px; border-bottom: 1px solid var(--line); }
tbody td { padding: 16px 20px; border-bottom: 1px solid var(--line-soft); color: var(--ink); }
tbody tr:last-child td { border-bottom: 0; }
td.b, .val { font-weight: 700; color: var(--ink-navy); }
.muted-inline { color: var(--ink-faint); font-weight: 400; font-size: 14px; }

/* ---------- Async / Sync callouts ---------- */
.callouts { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 22px; }
@media (max-width: 760px) { .callouts { grid-template-columns: 1fr; } }
.callout { border-radius: var(--radius); padding: 20px 22px; }
.callout h4 { margin: 0 0 9px; font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.callout p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--ink-dim); }
.callout.blue { background: var(--blue-tint); border: 1px solid var(--blue-tint-line); }
.callout.blue h4 { color: var(--blue-strong); }
.callout.green { background: var(--green-tint); border: 1px solid var(--green-tint-line); }
.callout.green h4 { color: var(--green-ink); }

/* ---------- FAQ accordion ---------- */
.faq { display: flex; flex-direction: column; gap: 13px; }
.faq-item { background: var(--card); border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.faq-q { width: 100%; cursor: pointer; text-align: left; background: none; border: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 24px; font-family: var(--sans); font-size: 16.5px; font-weight: 500; color: var(--ink-navy); }
.faq-q .chev { color: var(--ink-faint); transition: transform .18s ease; flex: none; }
.faq-item.open .faq-q .chev { transform: rotate(180deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .22s ease; }
.faq-a .inner { padding: 0 24px 20px; color: var(--ink-dim); font-size: 15px; line-height: 1.6; }

/* ---------- Sticky Next button ---------- */
.next-bar { position: fixed; right: 26px; bottom: 26px; z-index: 40; }
.btn-navy { display: inline-flex; align-items: center; gap: 10px; background: var(--navy-btn); color: #fff; font-family: var(--sans); font-weight: 600; font-size: 16px; padding: 15px 24px; border-radius: 12px; box-shadow: 0 10px 30px rgba(15,27,45,.28); }
.btn-navy:hover { background: #16263d; text-decoration: none; }

/* ---------- Calculator (P&L app) ---------- */
.calc2 { display: grid; grid-template-columns: 1fr 440px; gap: 26px; align-items: start; }
@media (max-width: 1040px) { .calc2 { grid-template-columns: 1fr; } }

.seg { display: inline-flex; background: #eef0f6; border-radius: 12px; padding: 5px; gap: 4px; margin-bottom: 24px; }
.seg button { border: 0; background: none; cursor: pointer; font-family: var(--sans); font-weight: 600; font-size: 16px; color: var(--ink-dim); padding: 11px 26px; border-radius: 9px; }
.seg button.active { background: var(--navy-btn); color: #fff; }

.pcard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-card); padding: 26px; margin-bottom: 20px; }
.pcard h3 { font-size: 25px; font-weight: 600; margin: 0 0 18px; }
.pcard h3.tight { font-size: 21px; margin-bottom: 6px; }
.pcard .cap { color: var(--ink-dim); font-size: 15px; margin: 0 0 18px; }

.stat-boxes { display: grid; gap: 12px; }
.stat-boxes.c3 { grid-template-columns: repeat(3, 1fr); }
.stat-boxes.c4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 520px) { .stat-boxes.c4 { grid-template-columns: repeat(2, 1fr); } }
.stat-box { background: #f4f6fb; border: 1px solid transparent; border-radius: 12px; padding: 16px 12px; text-align: center; }
.stat-box.active { background: var(--blue-tint); border-color: var(--blue-tint-line); }
.stat-box .num { font-family: var(--display); font-weight: 700; font-size: 24px; color: var(--ink-navy); }
.stat-box .lbl { color: var(--ink-faint); font-size: 14px; margin-top: 4px; }
.covers { color: var(--ink-dim); font-size: 15px; margin-top: 16px; }

.pp-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2px; }
.pp-head h3 { margin: 0; }
.btn-dark { display: inline-flex; align-items: center; gap: 8px; background: var(--navy-btn); color: #fff; border: 0; cursor: pointer; font-family: var(--sans); font-weight: 600; font-size: 16px; padding: 13px 20px; border-radius: 10px; }
.btn-dark:hover { background: #16263d; }
.empty { text-align: center; padding: 42px 10px 32px; }
.empty .t { font-family: var(--display); font-weight: 600; font-size: 20px; color: var(--ink-navy); }
.empty .d { color: var(--ink-faint); font-size: 15px; margin-top: 6px; }

.prog { border: 1px solid var(--line); border-radius: 12px; padding: 16px; margin-top: 14px; }
.prog .grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 12px; }
.prog label { font-size: 12.5px; color: var(--ink-dim); font-weight: 600; display: block; margin-bottom: 6px; }
.prog input { width: 100%; border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; font-family: var(--sans); font-size: 15px; outline: none; }
.prog input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.prog .rmrow { text-align: right; margin-top: 10px; }
.prog .rm { background: none; border: 0; color: #d92d20; cursor: pointer; font-size: 13px; font-weight: 600; }

.fees { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 520px) { .fees { grid-template-columns: 1fr; } }
.fee label { font-size: 15px; color: var(--ink-dim); font-weight: 500; }
.fee .inp { position: relative; margin-top: 8px; }
.fee .inp .cur { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-faint); font-size: 17px; }
.fee input { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 13px 13px 13px 32px; font-size: 18px; outline: none; }
.fee input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.paid { margin-top: 8px; font-size: 14px; }
.paid .g { color: var(--green); font-weight: 600; }
.paid .n { color: var(--ink-faint); }
.fee .hint { margin-top: 8px; font-size: 14px; color: var(--ink-faint); }

.rpanel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-card); padding: 24px 26px; margin-bottom: 18px; }
.rpanel .rlabel { font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-faint); }
.rpanel .rsubcount { color: var(--ink-dim); font-size: 15px; margin-top: 3px; margin-bottom: 14px; }
.rrow { display: flex; justify-content: space-between; align-items: baseline; padding: 11px 0; font-size: 16px; }
.rrow .k { color: var(--ink); }
.rrow .v { font-weight: 700; color: var(--ink-navy); }
.rrow.muted .k, .rrow.muted .v { color: var(--ink-faint); font-weight: 400; }
.rrow.total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 16px; }
.rrow.total .k { font-family: var(--display); font-weight: 600; font-size: 20px; color: var(--ink-navy); }
.rrow.total .v { font-family: var(--display); font-weight: 700; font-size: 26px; }
.rsub-head { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-faint); margin: 12px 0 0; }
.rdash { border: 0; border-top: 1px dashed var(--line); margin: 10px 0; }
.rnote { color: var(--ink-faint); font-size: 14px; margin-top: 12px; line-height: 1.5; }
.btn-export { width: 100%; display: flex; align-items: center; justify-content: center; gap: 10px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; font-family: var(--sans); font-weight: 600; font-size: 17px; color: var(--ink-navy); cursor: pointer; box-shadow: var(--shadow-card); }
.btn-export:hover { background: #f7f9fc; }

/* ---------- Add Program modal ---------- */
.modal-overlay { position: fixed; inset: 0; background: rgba(15,23,42,.45); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); display: none; align-items: center; justify-content: center; z-index: 60; padding: 24px; }
.modal-overlay.open { display: flex; }
.modal { background: #fff; border-radius: 18px; width: 100%; max-width: 640px; box-shadow: 0 30px 90px rgba(0,0,0,.4); padding: 28px 30px; max-height: 88vh; overflow: auto; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.modal-head h3 { font-size: 24px; margin: 0; font-weight: 700; }
.modal-close { background: none; border: 0; font-size: 22px; line-height: 1; color: var(--ink-faint); cursor: pointer; }
.modal .fld { display: block; font-size: 14px; font-weight: 600; color: var(--ink-navy); margin: 16px 0 8px; }
.modal input[type=text], .modal input[type=number], .modal select { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; font-family: var(--sans); font-size: 15px; outline: none; background: #fff; color: var(--ink-navy); }
.modal input:focus, .modal select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.prot-head { display: flex; align-items: center; justify-content: space-between; margin: 18px 0 10px; }
.prot-head .lbl { font-size: 14px; font-weight: 600; color: var(--ink-navy); }
.add-prod { background: none; border: 0; color: var(--blue); font-weight: 600; font-size: 14px; cursor: pointer; }
.prod-row { display: flex; gap: 10px; align-items: center; margin-bottom: 9px; }
.prod-row select { flex: 1; min-width: 0; }
.prod-row .qty { width: 62px; text-align: center; }
.prod-row .pc { font-family: var(--display); font-weight: 700; color: var(--ink-navy); min-width: 50px; text-align: right; font-size: 15px; }
.prod-row .rmp { background: none; border: 0; color: #d92d20; cursor: pointer; font-size: 17px; line-height: 1; }
.retail-row { display: flex; gap: 16px; align-items: flex-end; margin-top: 4px; }
.retail-row .rp { flex: 1; }
.money { position: relative; }
.money .cur { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--ink-faint); }
.money input { padding-left: 28px; }
.cogs-box { background: #f4f6fb; border-radius: 10px; padding: 12px 16px; min-width: 190px; }
.cogs-box .k { font-size: 12.5px; color: var(--ink-dim); }
.cogs-box .v { font-family: var(--display); font-weight: 700; font-size: 18px; color: var(--ink-navy); }
.modal-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 24px; }
.btn-ghost { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 22px; font-weight: 600; cursor: pointer; font-family: var(--sans); font-size: 15px; color: var(--ink-navy); }
.btn-save { background: var(--navy-btn); color: #fff; border: 0; border-radius: 10px; padding: 12px 22px; font-weight: 600; cursor: pointer; font-family: var(--sans); font-size: 15px; }

/* ---------- Saved program card ---------- */
.prog-top { display: flex; align-items: center; justify-content: space-between; }
.prog-top h4 { font-family: var(--display); font-size: 18px; margin: 0; color: var(--ink-navy); font-weight: 600; }
.prog-top .rm { background: none; border: 0; color: var(--ink-faint); cursor: pointer; font-size: 18px; line-height: 1; }
.prod-pills { display: flex; flex-wrap: wrap; gap: 8px; margin: 11px 0 14px; }
.prod-pill { background: #eef1f6; border-radius: 8px; padding: 5px 11px; font-size: 13px; color: var(--ink-dim); }
.prog-inputs { display: flex; gap: 20px; align-items: flex-end; flex-wrap: wrap; }
.prog-inputs .fieldc label { display: block; font-size: 12px; color: var(--ink-dim); font-weight: 600; margin-bottom: 6px; }
.prog-inputs .fieldc input { width: 96px; border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; font-size: 15px; font-family: var(--sans); outline: none; }
.prog-inputs .fieldc input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.prog-meta { font-size: 14px; color: var(--ink-dim); line-height: 1.6; }
.prog-meta b { color: var(--ink-navy); }

/* ---------- Price sheet ---------- */
.legend { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 8px 0 22px; }
@media (max-width: 820px) { .legend { grid-template-columns: 1fr; } }
.lg-card { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 15px 18px; box-shadow: var(--shadow-card); }
.lg-card b { display: block; color: var(--ink-navy); font-weight: 600; font-size: 16px; }
.lg-card span { color: var(--ink-dim); font-size: 14px; }

.pharm { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; font-family: var(--display); font-weight: 700; font-size: 14px; flex: none; }
.pharm.a { background: #fef3c7; color: #b45309; }
.pharm.b { background: #dbeafe; color: #1d4ed8; }
.pharm.c { background: #dcfce7; color: #15803d; }

.info-banner { background: var(--blue-tint); border: 1px solid var(--blue-tint-line); color: var(--blue-strong); border-radius: 12px; padding: 15px 18px; font-size: 15px; margin-bottom: 6px; }

.cat-label { font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-faint); margin: 28px 0 12px; }

.price-table td, .price-table th { padding: 14px 18px; }
.price-table { font-size: 15.5px; }
.form-pill { display: inline-block; background: #eef1f6; color: var(--ink-dim); border-radius: 6px; padding: 3px 10px; font-size: 13.5px; white-space: nowrap; }
.prod-name { font-weight: 600; color: var(--ink-navy); }
.prod-sub { color: var(--ink-faint); font-size: 13.5px; margin-top: 3px; }
.tv { color: var(--ink-dim); }
.cost { font-weight: 700; color: var(--ink-navy); white-space: nowrap; }
.cost .per { color: var(--ink-faint); font-weight: 400; font-size: 13px; margin-left: 4px; }

/* ---------- Gate ---------- */
.gate { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.card-gate { width: 100%; max-width: 420px; background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 34px 32px 28px; }
.gate-lockup { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; margin-bottom: 22px; }
.gate-lockup .logo-mark { color: var(--ink-navy); }
.card-gate .logo-lg { font-family: "Archivo", var(--sans); font-size: 21px; color: var(--ink-navy); text-transform: uppercase; letter-spacing: 0.26em; padding-left: 0.26em; line-height: 1; }
.card-gate .logo-lg + .rule { display: block; width: 34px; height: 2px; background: var(--ink-navy); border-radius: 2px; margin-top: 4px; }
.card-gate h1 { font-size: 22px; font-weight: 600; margin: 0 0 8px; }
.card-gate .sub { color: var(--ink-dim); font-size: 15px; line-height: 1.55; margin: 0 0 24px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 8px; }
.input { width: 100%; background: #fff; color: var(--ink-navy); border: 1px solid var(--line); border-radius: 10px; padding: 13px 15px; font-size: 16px; outline: none; }
.input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.btn-blue { width: 100%; cursor: pointer; border: 0; background: var(--blue-strong); color: #fff; font-family: var(--sans); font-weight: 600; font-size: 16px; padding: 15px 16px; border-radius: 10px; }
.btn-blue:hover { filter: brightness(1.05); }
.err { color: #d92d20; font-size: 13.5px; margin-top: 10px; min-height: 18px; }
.gate-note { margin-top: 18px; font-size: 14px; color: var(--ink-faint); text-align: center; }

/* ---------- Footer ---------- */
.foot { border-top: 1px solid var(--line); background: #fff; padding: 26px 32px; display: flex; align-items: center; justify-content: space-between; gap: 16px; font-size: 14px; color: var(--ink-faint); }
.foot .logo { font-family: "Archivo", var(--sans); color: var(--ink-navy); font-size: 13px; text-transform: uppercase; letter-spacing: 0.22em; }
.foot .center { color: var(--ink-faint); }
@media (max-width: 720px) { .foot { flex-direction: column; text-align: center; gap: 10px; } }

/* ---------- Liquid glass buttons ---------- */
.glass-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--sans); font-size: 16px; font-weight: 600; letter-spacing: .01em;
  padding: 14px 28px; border-radius: 999px; border: none; cursor: pointer;
  background: transparent; color: var(--ink-navy); isolation: isolate;
  transition: transform .3s cubic-bezier(.2,.6,.2,1); -webkit-tap-highlight-color: transparent;
}
.glass-btn:hover { transform: scale(1.04); text-decoration: none; }
.glass-btn:active { transform: scale(.98); }
.glass-btn .glass-label { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 9px; }
.glass-btn .glass-rim { position: absolute; inset: 0; z-index: 0; border-radius: 999px; pointer-events: none; }
.glass-btn .glass-distort {
  position: absolute; inset: 0; z-index: -1; border-radius: 999px; overflow: hidden;
  -webkit-backdrop-filter: blur(8px) saturate(1.4); backdrop-filter: blur(8px) saturate(1.4);
  backdrop-filter: url("#container-glass");
}

/* white glass — frosted, dark ink */
.glass-btn.gb-white { color: var(--ink-navy); }
.glass-btn.gb-white .glass-distort { background: rgba(255,255,255,.55); }
.glass-btn.gb-white .glass-rim {
  box-shadow:
    0 0 6px rgba(0,0,0,.03), 0 2px 8px rgba(0,0,0,.10),
    inset 3px 3px .5px -3px rgba(255,255,255,.9), inset -3px -3px .5px -3px rgba(0,0,0,.30),
    inset 1px 1px 1px -.5px rgba(255,255,255,.7), inset -1px -1px 1px -.5px rgba(0,0,0,.25),
    inset 0 0 7px 6px rgba(255,255,255,.22), inset 0 0 2px 2px rgba(255,255,255,.10),
    0 0 14px rgba(255,255,255,.30);
}

/* black glass — dark tint, white ink */
.glass-btn.gb-black { color: #fff; }
.glass-btn.gb-black .glass-distort { background: rgba(11,17,27,.74); }
.glass-btn.gb-black .glass-rim {
  box-shadow:
    0 1px 3px rgba(0,0,0,.22), 0 8px 24px rgba(15,27,45,.30),
    inset 3px 3px .5px -3.5px rgba(255,255,255,.55), inset -3px -3px .5px -3.5px rgba(255,255,255,.18),
    inset 1px 1px 1px -.5px rgba(255,255,255,.5), inset -1px -1px 1px -.5px rgba(255,255,255,.2),
    inset 0 0 7px 6px rgba(255,255,255,.10), inset 0 0 2px 2px rgba(255,255,255,.06),
    0 0 14px rgba(0,0,0,.18);
}

/* ---------- Glass surfaces [carry the button aesthetic through] ---------- */
.seg {
  background: rgba(255,255,255,.5);
  border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(8px) saturate(1.3);
  backdrop-filter: blur(8px) saturate(1.3);
}
.seg button.active {
  background: rgba(11,17,27,.92);
  color: #fff;
  box-shadow:
    0 1px 3px rgba(0,0,0,.25),
    inset 2px 2px .5px -2.5px rgba(255,255,255,.6),
    inset -2px -2px .5px -2.5px rgba(255,255,255,.2),
    inset 0 0 6px 4px rgba(255,255,255,.08);
}

/* faint glass top-edge highlight on card surfaces */
.hub-card, .col-card, .pcard, .rpanel, .ready, .lg-card {
  box-shadow: var(--shadow-card), inset 0 1px 0 rgba(255,255,255,.9);
}
.hub-card:hover { box-shadow: var(--shadow), inset 0 1px 0 rgba(255,255,255,.9); }

/* stat boxes + form pills pick up the frosted-glass feel */
.stat-box { -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); box-shadow: inset 0 1px 0 rgba(255,255,255,.7); }
.stat-box.active { box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 0 0 1px var(--blue-tint-line); }

/* ---------- Print block ---------- */
#print-block { display: none; }
@media print {
  body * { display: none !important; }
  #print-block {
    display: flex !important; position: fixed; inset: 0;
    flex-direction: column; align-items: center; justify-content: center; gap: 16px;
    background: #fff; color: #0b1c30; font-family: system-ui, sans-serif;
  }
  #print-block .t { font-size: 22px; font-weight: 700; }
  #print-block .d { font-size: 14px; color: #64748b; max-width: 320px; text-align: center; }
}
