/* ============================================================
   PRASUN SRIVASTAVA — BRAND COMPONENTS
   Requires: tokens.css (load first). No framework dependency —
   works in the Astro site, standalone HTML deliverables, and
   print/PDF rendering alike.
   Served at: https://prasunsrivastava.com/brand/components.css
   ============================================================ */

/* -- Document frame + band ------------------------------------ */
.doc-frame {
  max-width: 860px;
  margin: 44px auto;
  background: var(--panel);
  border: 1px solid var(--rule);
  box-shadow: var(--shadow-frame);
}
.doc-band {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px 24px;
  border-bottom: 3px solid var(--accent);
  padding: 18px 44px;
}

/* -- Mono label ("furniture") ---------------------------------- */
.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--grey);
}
.tag b { color: var(--accent); font-weight: 600; }

/* -- Links ------------------------------------------------------ */
.prose-links a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent);
  text-underline-offset: 3px;
}
.prose-links a:hover {
  color: var(--accent-deep);
  text-decoration-color: var(--accent-deep);
}

/* -- List rows (writing index, step lists, agendas) ------------ */
.row {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 22px;
  padding: 15px 0;
  border-top: 1px solid var(--rule);
  align-items: baseline;
}
.row:first-child { border-top: none; padding-top: 4px; }
.row .row-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--faint);
}

/* -- Plates (step cards): tinted ground, ghost numeral --------- */
.plate {
  position: relative;
  background: var(--ground);
  padding: 26px 22px 22px;
  overflow: hidden;
}
.plate .ghost {
  position: absolute;
  right: 6px;
  top: -14px;
  font-family: var(--font-serif);
  font-size: 96px;
  font-weight: 700;
  font-style: italic;
  line-height: 1;
  color: var(--accent);
  opacity: 0.13;
  font-variant-numeric: oldstyle-nums;
  pointer-events: none;
}
.plate .plate-title {
  position: relative;
  display: block;
  font-size: 18px;
  font-weight: 700;
}
.plate .plate-title::after {
  content: "";
  display: block;
  width: 26px;
  margin-top: 9px;
  border-top: 2px solid var(--accent);
}
.plate p {
  position: relative;
  font-size: 14.5px;
  color: var(--grey);
  line-height: 1.55;
  margin-top: 10px;
}

/* -- Primary CTA ------------------------------------------------ */
.cta {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--panel) !important;
  background: var(--accent);
  border: none;
  cursor: pointer;
  padding: 14px 22px;
  text-decoration: none !important;
}
.cta:hover { background: var(--accent-deep); }
.cta:disabled { cursor: wait; opacity: 0.6; }

/* ============================================================
   REPORT / DELIVERABLE PRIMITIVES (Swiss exhibit system)
   ============================================================ */

/* Cover */
.rpt-rule-heavy { border-top: 3px solid var(--ink); margin: 16px 0 8px; }
.rpt-title {
  font-family: var(--font-serif);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin-top: 16px;
}
.rpt-title em { font-style: italic; color: var(--accent); }

/* KPI blocks */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin-top: 38px;
}
.kpi { background: var(--panel); padding: 18px 20px; }
.kpi .n {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: var(--text-kpi);
  line-height: 1.05;
  color: var(--accent);
  font-variant-numeric: oldstyle-nums;
  letter-spacing: -0.01em;
}
.kpi .n small { font-size: 19px; font-style: italic; color: var(--grey); margin-left: 2px; }
.kpi.crit .n { color: var(--crit-text); }

/* Exhibits: every table/figure carries a mono label */
.exhibit { margin-top: 42px; }
.exhibit table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  font-size: 15.5px;
}
.exhibit th {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--grey);
  text-align: left;
  border-top: 2px solid var(--ink);
  border-bottom: 1px solid var(--rule);
  padding: 10px 12px 8px;
}
.exhibit td { border-bottom: 1px solid var(--rule); padding: 12px; }

/* Score bars: ink for data — accent never competes with data */
.bar { height: 8px; background: var(--ground); position: relative; }
.bar i { position: absolute; inset: 0 auto 0 0; background: var(--ink); }

/* Severity chips: reserved hues */
.sev {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  padding: 3px 8px;
}
.sev.high { background: var(--crit-solid); color: #fff; }
.sev.med  { background: var(--warn-bg); color: var(--warn-fg); }
.sev.ok   { background: var(--ok-bg); color: var(--ok-fg); }

/* Findings / pull-quotes */
.finding {
  margin-top: 30px;
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 18px;
  font-style: italic;
  color: var(--grey);
  font-size: 16px;
}

/* Alerts (forms, in-page notices) — three-tier status usage */
.alert { padding: 16px 20px; font-size: 15.5px; line-height: 1.55; }
.alert.error { background: var(--crit-bg); color: var(--crit-text); border: 1px solid color-mix(in srgb, var(--crit-solid) 35%, transparent); }
.alert.ok { background: var(--ok-bg); color: var(--ok-fg); border: 1px solid color-mix(in srgb, var(--ok-fg) 25%, transparent); }

/* Print: deliverables render to PDF */
@media print {
  .doc-frame { box-shadow: none; margin: 0; border: none; max-width: none; }
  .cta { display: none; }
}

/* Small screens */
@media (max-width: 720px) {
  .doc-band { padding: 16px 20px; }
  .row { grid-template-columns: 1fr; gap: 4px; }
  .kpi-row { grid-template-columns: 1fr; }
}
