/*
  Wat Pho Listening Dashboard
  Visual language: maroon, gold, cream, editorial Thai typography
  Extracted from reports/wat-pho-social-listening-2026/report.html
*/

:root {
  --maroon: #6e1712;
  --maroon-2: #8d241c;
  --maroon-deep: #4f100c;
  --gold: #c6a15b;
  --gold-soft: #e8d6ae;
  --gold-wash: #f3e8d2;
  --cream: #f3eee4;
  --cream-2: #ebe4d6;
  --paper: #fffdf8;
  --ink: #211c17;
  --ink-2: #4d463d;
  --muted: #837a6d;
  --line: #e0d6c6;
  --line-strong: #cfc2ad;
  --green: #3f6b4f;
  --green-soft: #e5efe8;
  --amber: #a8741f;
  --amber-soft: #f7ecd7;
  --red: #9b3a32;
  --red-soft: #f4e2df;
  --blue: #3c5a78;
  --blue-soft: #e4ebf1;
  --radius: 2px;
  --font-display: "IBM Plex Sans Thai", "Sarabun", "Leelawadee UI", sans-serif;
  --font-body: "Sarabun", "IBM Plex Sans Thai", "Leelawadee UI", sans-serif;
  --shadow-soft: 0 18px 40px rgba(79, 16, 12, 0.08);
  --sidebar-w: 266px;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection {
  background: var(--gold-soft);
  color: var(--maroon-deep);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  background: var(--maroon);
  color: #fff;
  padding: 10px 14px;
  transform: translateY(-160%);
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.app {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  min-height: 100vh;
}

/* ---------------- Sidebar ---------------- */

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  color: #f6ebd7;
  background:
    radial-gradient(circle at 18% 0%, rgba(198, 161, 91, 0.17), transparent 34%),
    linear-gradient(180deg, #671610 0%, #55110d 100%);
  border-right: 1px solid rgba(198, 161, 91, 0.24);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px 20px 20px;
  border-bottom: 1px solid rgba(232, 214, 174, 0.16);
}

.brand-mark {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(198, 161, 91, 0.75);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--gold-soft);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.brand-copy {
  min-width: 0;
}

.brand-kicker {
  display: block;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  line-height: 1.3;
}

.brand-title {
  display: block;
  margin-top: 3px;
  color: #fff8eb;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.sidebar-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 18px 12px 16px;
  scrollbar-width: thin;
  scrollbar-color: rgba(198, 161, 91, 0.35) transparent;
}

.nav-group-label {
  padding: 12px 10px 7px;
  color: rgba(232, 214, 174, 0.58);
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.nav-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  background: transparent;
  color: rgba(255, 248, 235, 0.74);
  text-align: left;
  transition: background 160ms ease, color 160ms ease;
}

.nav-link:hover {
  background: rgba(232, 214, 174, 0.08);
  color: #fff8eb;
}

.nav-link.active {
  background: rgba(198, 161, 91, 0.13);
  color: #fff8eb;
}

.nav-link.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  bottom: 7px;
  width: 2px;
  background: var(--gold);
}

.nav-icon {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  color: currentColor;
  opacity: 0.8;
}

.nav-link.active .nav-icon {
  color: var(--gold-soft);
  opacity: 1;
}

.nav-text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.nav-label {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
}

.nav-note {
  color: rgba(255, 248, 235, 0.44);
  font-size: 10px;
  line-height: 1.3;
}

.sidebar-footer {
  padding: 14px 16px 18px;
  border-top: 1px solid rgba(232, 214, 174, 0.16);
  background: rgba(0, 0, 0, 0.08);
}

.sidebar-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 11px;
  color: rgba(255, 248, 235, 0.58);
  font-size: 10.5px;
  line-height: 1.5;
}

.sidebar-meta strong {
  display: block;
  color: var(--gold-soft);
  font-weight: 500;
}

.sidebar-download {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid rgba(198, 161, 91, 0.55);
  background: transparent;
  color: var(--gold-soft);
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: background 160ms ease, color 160ms ease;
}

.sidebar-download:hover {
  background: var(--gold);
  color: var(--maroon-deep);
}

/* ---------------- Main + topbar ---------------- */

.main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 64px;
  padding: 0 30px;
  background: rgba(243, 238, 228, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 11px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.breadcrumb strong {
  color: var(--maroon);
  font-weight: 600;
}

.breadcrumb-sep {
  color: var(--line-strong);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.search-wrap {
  position: relative;
  width: min(280px, 24vw);
}

.search-wrap svg {
  position: absolute;
  top: 50%;
  left: 11px;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px 8px 34px;
  border: 1px solid var(--line-strong);
  border-radius: 0;
  background: var(--paper);
  color: var(--ink);
  font-size: 12.5px;
}

.search-input::placeholder {
  color: #9a9082;
}

.search-input:focus {
  border-color: var(--gold);
  outline: none;
  box-shadow: 0 0 0 2px rgba(198, 161, 91, 0.18);
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 32px;
  padding: 4px 10px;
  border: 1px solid var(--line-strong);
  background: var(--paper);
  color: var(--ink-2);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 500;
  white-space: nowrap;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(63, 107, 79, 0.12);
}

@media (prefers-reduced-motion: no-preference) {
  .live-dot {
    animation: pulse 2.8s ease-in-out infinite;
  }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(63, 107, 79, 0.10); }
  50% { box-shadow: 0 0 0 6px rgba(63, 107, 79, 0.02); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: 0;
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: background 160ms ease, color 160ms ease, border-color 160ms ease, transform 120ms ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--maroon);
  border-color: var(--maroon);
  color: #fff8eb;
}

.btn-primary:hover {
  background: var(--maroon-2);
  border-color: var(--maroon-2);
}

.btn-secondary {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--ink-2);
}

.btn-secondary:hover {
  border-color: var(--gold);
  color: var(--maroon);
}

.btn-quiet {
  min-height: 32px;
  padding: 5px 9px;
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
}

.btn-quiet:hover {
  color: var(--maroon);
  background: var(--gold-wash);
}

.btn svg {
  width: 16px;
  height: 16px;
}

.btn.is-loading svg {
  animation: spin 800ms linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.content {
  width: 100%;
  max-width: 1480px;
  margin: 0 auto;
  padding: 28px 30px 72px;
}

/* ---------------- View header ---------------- */

.view-head {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.62fr);
  gap: 34px;
  align-items: end;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.view-kicker {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.view-kicker::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--gold);
}

.view-title {
  max-width: 34ch;
  margin: 8px 0 10px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 38px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.022em;
  text-wrap: balance;
}

.view-summary {
  max-width: 72ch;
  margin: 0;
  color: var(--ink-2);
  font-size: 15.5px;
  line-height: 1.72;
}

.view-side {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 12px;
  padding-left: 22px;
  border-left: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.view-side-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 9px;
  border-bottom: 1px dashed var(--line);
}

.view-side-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.view-side-row strong {
  color: var(--ink-2);
  font-weight: 500;
  text-align: right;
}

.brief-lead {
  margin-top: 18px;
  padding: 15px 18px 16px;
  border-top: 3px solid var(--gold);
  background: var(--maroon);
  color: var(--gold-soft);
}

.brief-lead p {
  max-width: 92ch;
  margin: 0;
  font-size: 14.5px;
  line-height: 1.72;
}

.view-stamp {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.stamp-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--maroon);
  font-size: 9px;
  line-height: 1.15;
  text-align: center;
}

/* ---------------- KPI grid ---------------- */

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin: 22px 0;
  border: 1px solid var(--line);
  background: var(--line);
}

.kpi-grid.six {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kpi {
  min-height: 126px;
  padding: 16px 17px 14px;
  background: var(--paper);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.kpi-label {
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.kpi-value-row {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin: 7px 0 4px;
}

.kpi-value {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: clamp(26px, 2.6vw, 34px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}

.kpi-unit {
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 400;
}

.kpi-note {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.kpi-note.good { color: var(--green); }
.kpi-note.watch { color: var(--amber); }
.kpi-note.risk { color: var(--red); }

/* ---------------- Analysis layout ---------------- */

.analysis-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.72fr);
  gap: 18px;
  margin-bottom: 18px;
}

.analysis-grid > *,
.method-grid > *,
.report-grid > * {
  min-width: 0;
}

.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  min-width: 0;
}

.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 17px;
  border-bottom: 1px solid var(--line);
}

.panel-title {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.panel-note {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.45;
}

.panel-body {
  padding: 16px 17px 18px;
}

.panel-body.flush {
  padding: 0;
}

.panel-link {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.panel-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Topic share */

.share-list {
  display: flex;
  flex-direction: column;
}

.share-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.9fr) minmax(100px, 1.5fr) 46px;
  gap: 12px;
  align-items: center;
  min-height: 34px;
  padding: 6px 0;
  border-bottom: 1px dashed var(--line);
}

.share-row:last-child {
  border-bottom: 0;
}

.share-label {
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.3;
}

.share-track {
  height: 7px;
  background: var(--cream-2);
  overflow: hidden;
}

.share-fill {
  display: block;
  height: 100%;
  width: 0;
  transition: width 700ms cubic-bezier(0.16, 1, 0.3, 1);
}

.share-value {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.tone-maroon { background: var(--maroon); }
.tone-gold { background: var(--gold); }
.tone-amber { background: var(--amber); }
.tone-sage { background: var(--green); }
.tone-blue { background: var(--blue); }
.tone-red { background: var(--red); }
.tone-muted { background: #b9ad9a; }

/* Side insight list */

.insight-list {
  display: flex;
  flex-direction: column;
}

.insight-item {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--line);
}

.insight-item:first-child {
  padding-top: 0;
}

.insight-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.insight-label {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1.5;
  text-transform: uppercase;
}

.insight-label.watch { color: var(--amber); }
.insight-label.risk { color: var(--red); }
.insight-label.good { color: var(--green); }

.insight-title {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
}

.insight-body {
  margin: 0;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.55;
}

/* Two-group side panel */

.side-group + .side-group {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.side-group-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 7px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
}

.side-group-head::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
}

.side-group-head.good::before { background: var(--green); }
.side-group-head.watch::before { background: var(--amber); }
.side-group-head.risk::before { background: var(--red); }

.side-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.side-list li {
  position: relative;
  padding: 4px 0 4px 13px;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.55;
}

.side-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 4px;
  height: 1px;
  background: var(--line-strong);
}

.side-foot {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.side-foot button {
  border: 0;
  background: transparent;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------------- Slope chart ---------------- */

.slope-wrap {
  padding: 6px 0 0;
}

.slope-svg {
  display: block;
  width: 100%;
  height: 220px;
}

.slope-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin-top: 12px;
  border: 1px solid var(--line);
  background: var(--line);
}

.slope-stat {
  padding: 10px 12px;
  background: var(--paper);
}

.slope-stat span {
  display: block;
  color: var(--muted);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.slope-stat strong {
  display: block;
  margin-top: 3px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* ---------------- Timeline ---------------- */

.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-left: 6px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 67px;
  top: 8px;
  bottom: 8px;
  width: 1px;
  background: var(--line-strong);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 62px 18px minmax(0, 1fr);
  gap: 10px;
  padding: 9px 0;
}

.timeline-date {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.5;
  text-align: right;
  white-space: nowrap;
}

.timeline-dot {
  position: relative;
  z-index: 1;
  width: 9px;
  height: 9px;
  margin-top: 5px;
  margin-left: 4px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  background: var(--paper);
}

.timeline-item.good .timeline-dot { border-color: var(--green); background: var(--green); }
.timeline-item.risk .timeline-dot { border-color: var(--red); background: var(--red); }
.timeline-item.gold .timeline-dot { border-color: var(--gold); background: var(--gold); }

.timeline-content {
  min-width: 0;
  padding-bottom: 9px;
  border-bottom: 1px dashed var(--line);
}

.timeline-item:last-child .timeline-content {
  padding-bottom: 0;
  border-bottom: 0;
}

.timeline-title {
  display: block;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.45;
}

.timeline-body {
  margin: 3px 0 0;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.55;
}

.timeline-tag {
  display: inline-block;
  margin-top: 5px;
  padding: 1px 6px;
  background: var(--gold-wash);
  color: #7a5a20;
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.brief-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.brief-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px dashed var(--line);
}

.brief-item:first-child {
  padding-top: 0;
}

.brief-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.brief-index {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1.6;
}

.brief-title {
  display: block;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.45;
}

.brief-body {
  margin: 3px 0 0;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.6;
}

/* ---------------- Calendar list ---------------- */

.calendar-list {
  display: flex;
  flex-direction: column;
}

.calendar-row {
  display: grid;
  grid-template-columns: 132px 92px minmax(0, 1fr) 92px;
  gap: 12px;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
}

.calendar-row:last-child {
  border-bottom: 0;
}

.calendar-row.upcoming {
  background: linear-gradient(90deg, rgba(198, 161, 91, 0.10), transparent 72%);
  margin: 0 -8px;
  padding-left: 8px;
  padding-right: 8px;
}

.calendar-date {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.4;
}

.calendar-type {
  color: var(--muted);
  font-size: 9.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.calendar-title {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 500;
  line-height: 1.4;
}

.calendar-note {
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.4;
  text-align: right;
}

.status-pill {
  display: inline-block;
  padding: 2px 7px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}

.status-pill.upcoming {
  border-color: rgba(168, 116, 31, 0.45);
  background: var(--amber-soft);
  color: #7a5215;
}

.status-pill.risk {
  border-color: rgba(155, 58, 50, 0.4);
  background: var(--red-soft);
  color: var(--red);
}

/* ---------------- Content table ---------------- */

.table-scroll {
  overflow-x: auto;
  max-width: 100%;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  min-width: 680px;
}

.data-table caption {
  text-align: left;
}

.data-table th {
  padding: 8px 10px;
  border-bottom: 1.5px solid var(--ink);
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  text-align: left;
  white-space: nowrap;
}

.data-table td {
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  vertical-align: top;
  line-height: 1.5;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.data-table td:first-child {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 500;
  white-space: nowrap;
}

.data-table td strong {
  color: var(--ink);
  font-weight: 600;
}

/* ---------------- Price ladder ---------------- */

.price-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.price-row {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr) 94px;
  gap: 12px;
  align-items: center;
}

.price-minutes {
  color: var(--ink-2);
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 500;
}

.price-track {
  height: 24px;
  background: var(--cream-2);
  overflow: hidden;
}

.price-fill {
  display: flex;
  align-items: center;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--maroon), var(--maroon-2));
  transition: width 700ms cubic-bezier(0.16, 1, 0.3, 1);
}

.price-fill.gold {
  background: linear-gradient(90deg, #a97f36, var(--gold));
}

.price-value {
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.price-note {
  grid-column: 2 / 4;
  margin-top: -8px;
  color: var(--muted);
  font-size: 10.5px;
}

/* ---------------- Risk matrix ---------------- */

.risk-matrix {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: 24px minmax(150px, auto) minmax(150px, auto);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.matrix-corner {
  background: var(--cream);
}

.matrix-axis {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cream);
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.matrix-y {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  letter-spacing: 0.12em;
}

.matrix-cell {
  position: relative;
  padding: 10px;
  background: var(--paper);
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.matrix-cell.high-high { background: #fbf1ee; }
.matrix-cell.high-low { background: #fdf8ee; }
.matrix-cell.low-high { background: #f7f8f2; }
.matrix-cell.low-low { background: #fbfaf6; }

.matrix-cell-label {
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.risk-chip {
  padding: 7px 8px;
  border: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.9);
}

.risk-chip strong {
  display: block;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.35;
}

.risk-chip span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9.5px;
  line-height: 1.35;
}

.matrix-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  color: var(--muted);
  font-size: 9.5px;
}

/* ---------------- Actions ---------------- */

.actions-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.action-card {
  padding: 15px 16px 14px;
  background: var(--paper);
}

.action-number {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.action-title {
  display: block;
  margin: 5px 0 4px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
}

.action-body {
  margin: 0;
  color: var(--ink-2);
  font-size: 11px;
  line-height: 1.55;
}

.action-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 9px;
  padding-top: 7px;
  border-top: 1px dashed var(--line);
  color: var(--muted);
  font-size: 9.5px;
}

/* ---------------- Feed ---------------- */

.feed-section {
  margin-top: 18px;
}

.feed-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 17px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.chip {
  min-height: 28px;
  padding: 4px 9px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.03em;
  transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}

.chip:hover {
  border-color: var(--gold);
  color: var(--maroon);
}

.chip.active {
  background: var(--maroon);
  border-color: var(--maroon);
  color: #fff8eb;
}

.feed-count {
  color: var(--muted);
  font-size: 10px;
  white-space: nowrap;
}

.feed-list {
  display: flex;
  flex-direction: column;
}

.feed-row {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) 130px;
  gap: 16px;
  align-items: start;
  width: 100%;
  padding: 14px 17px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  text-align: left;
  transition: background 150ms ease;
}

.feed-row:last-child {
  border-bottom: 0;
}

.feed-row:hover {
  background: #faf5e9;
}

.feed-date {
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.4;
}

.feed-time {
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 400;
}

.feed-title {
  display: block;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
}

.feed-body {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 3px 0 0;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.55;
}

.feed-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}

.topic-pill {
  display: inline-block;
  padding: 1px 6px;
  background: var(--cream-2);
  color: #6d6457;
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.feed-source {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  color: var(--muted);
  font-size: 9.5px;
  line-height: 1.4;
  text-align: right;
}

.feed-source svg {
  width: 13px;
  height: 13px;
  color: var(--gold);
}

.feed-empty {
  padding: 32px 17px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

.feed-empty strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 14px;
}

.feed-more {
  padding: 14px 17px;
  border-top: 1px solid var(--line);
  text-align: center;
}

.feed-more button {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 10.5px;
  font-weight: 500;
}

.feed-more button:hover {
  border-color: var(--gold);
  background: var(--gold-wash);
}

/* ---------------- Report cards ---------------- */

.report-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.report-card {
  display: flex;
  flex-direction: column;
  min-height: 190px;
  padding: 16px;
  background: var(--paper);
  transition: background 160ms ease;
}

.report-card:hover {
  background: #faf5e9;
}

.report-type {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.report-card h3 {
  margin: 7px 0 5px;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}

.report-card p {
  margin: 0;
  color: var(--ink-2);
  font-size: 11px;
  line-height: 1.55;
}

.report-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 12px;
  color: var(--muted);
  font-size: 9.5px;
}

.report-arrow {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line-strong);
  color: var(--maroon);
}

.report-card:hover .report-arrow {
  border-color: var(--gold);
  background: var(--gold-wash);
}

/* ---------------- Method ---------------- */

.method-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.55fr);
  gap: 18px;
}

.method-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.method-list li {
  position: relative;
  padding: 8px 0 8px 18px;
  border-bottom: 1px dashed var(--line);
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.55;
}

.method-list li:last-child {
  border-bottom: 0;
}

.method-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  width: 7px;
  height: 1px;
  background: var(--gold);
}

.plan-list {
  display: flex;
  flex-direction: column;
}

.plan-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
}

.plan-item:last-child {
  border-bottom: 0;
}

.plan-week {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.5;
}

.plan-title {
  display: block;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 600;
}

.plan-body {
  margin: 2px 0 0;
  color: var(--ink-2);
  font-size: 10.5px;
  line-height: 1.5;
}

/* ---------------- Sources footer ---------------- */

.sources-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.sources-bar a {
  color: var(--maroon);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

.sources-bar a:hover {
  color: var(--maroon-2);
}

/* ---------------- Drawer ---------------- */

.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  background: rgba(33, 28, 23, 0.38);
  backdrop-filter: blur(2px);
}

.drawer-overlay.open {
  display: block;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  width: min(460px, 100vw);
  height: 100vh;
  background: var(--paper);
  border-left: 1px solid var(--gold);
  box-shadow: -24px 0 60px rgba(33, 28, 23, 0.16);
  transform: translateX(102%);
  transition: transform 260ms cubic-bezier(0.16, 1, 0.3, 1);
}

.drawer.open {
  transform: translateX(0);
}

.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--line);
}

.drawer-kicker {
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.drawer-title {
  margin: 5px 0 0;
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.015em;
}

.drawer-close {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink-2);
}

.drawer-close:hover {
  border-color: var(--gold);
  color: var(--maroon);
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px 20px 28px;
}

.drawer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.drawer-text {
  margin: 0 0 14px;
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.75;
}

.drawer-source {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  color: var(--maroon);
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 500;
}

.drawer-source:hover {
  border-color: var(--gold);
  background: var(--gold-wash);
}

.drawer-note {
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.55;
}

/* ---------------- Toast ---------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 120;
  max-width: min(420px, calc(100vw - 32px));
  padding: 10px 16px;
  background: var(--maroon-deep);
  color: #fff8eb;
  font-size: 12px;
  line-height: 1.45;
  box-shadow: var(--shadow-soft);
  transform: translate(-50%, 20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------------- Skeleton / error ---------------- */

.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--cream-2);
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 253, 248, 0.55), transparent);
  animation: shimmer 1.3s ease-in-out infinite;
}

@keyframes shimmer {
  to { transform: translateX(100%); }
}

.error-banner {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 18px 0;
  padding: 12px 14px;
  border: 1px solid rgba(155, 58, 50, 0.35);
  background: var(--red-soft);
  color: var(--red);
  font-size: 12px;
}

.error-banner.show {
  display: flex;
}

/* ---------------- Responsive ---------------- */

@media (max-width: 1180px) {
  .topbar {
    padding: 0 20px;
  }

  .content {
    padding: 24px 22px 60px;
  }

  .search-wrap {
    width: 210px;
  }

  .report-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 960px) {
  :root {
    --sidebar-w: 226px;
  }

  .brand {
    padding: 18px 15px 16px;
  }

  .brand-title {
    font-size: 13px;
  }

  .nav-note {
    display: none;
  }

  .topbar {
    gap: 10px;
  }

  .breadcrumb {
    display: none;
  }

  .search-wrap {
    flex: 1;
    width: auto;
  }

  .view-head {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .view-side {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px 18px;
    padding-left: 0;
    padding-top: 14px;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .view-side-row {
    flex-direction: column;
    gap: 2px;
    padding-bottom: 0;
    border-bottom: 0;
  }

  .view-side-row strong {
    text-align: left;
  }

  .analysis-grid {
    grid-template-columns: 1fr;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi-grid.six {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .actions-grid {
    grid-template-columns: 1fr;
  }

  .method-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .app {
    display: block;
  }

  .sidebar {
    position: relative;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(198, 161, 91, 0.24);
  }

  .sidebar-scroll {
    display: block;
    overflow: visible;
    padding: 0 10px 10px;
  }

  #navRoot {
    display: flex;
    align-items: center;
    gap: 4px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .nav-group-label {
    display: none;
  }

  .nav-list {
    display: flex;
    flex: 0 0 auto;
    flex-direction: row;
    gap: 4px;
  }

  .nav-list li {
    flex: 0 0 auto;
  }

  .nav-list + .nav-group-label + .nav-list {
    margin-top: 4px;
  }

  .nav-link {
    flex: 0 0 auto;
    width: auto;
    min-width: max-content;
    padding: 8px 10px;
    white-space: nowrap;
  }

  .nav-link.active::before {
    left: 7px;
    right: 7px;
    top: auto;
    bottom: 0;
    width: auto;
    height: 2px;
  }

  .nav-note {
    display: none;
  }

  .nav-label {
    white-space: nowrap;
  }

  .nav-text {
    flex-direction: row;
    align-items: center;
  }

  .sidebar-footer {
    display: block;
    padding: 10px 14px 14px;
  }

  .sidebar-meta {
    justify-content: flex-start;
    gap: 18px;
    margin-bottom: 10px;
  }

  .sidebar-download {
    width: 100%;
  }

  .topbar {
    position: relative;
    flex-wrap: wrap;
    min-height: 0;
    padding: 12px 14px;
  }

  .topbar-right {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    margin-left: 0;
  }

  .search-wrap {
    flex: 1 1 100%;
    width: 100%;
  }

  .live-pill {
    flex: 1 1 58%;
    min-width: 0;
    justify-content: center;
    white-space: nowrap;
  }

  #refreshBtn {
    flex: 0 0 auto;
  }

  .content {
    padding: 18px 14px 56px;
  }

  .view-title {
    max-width: 100%;
    font-size: 28px;
  }

  .view-summary {
    font-size: 14px;
  }

  .view-side {
    grid-template-columns: 1fr;
  }

  .kpi-grid {
    grid-template-columns: 1fr 1fr;
  }

  .kpi {
    min-height: 112px;
    padding: 13px 12px;
  }

  .kpi-value {
    font-size: 28px;
  }

  .share-row {
    grid-template-columns: minmax(110px, 1fr) minmax(60px, 1fr) 38px;
    gap: 8px;
  }

  .share-label {
    font-size: 10.5px;
  }

  .timeline::before {
    left: 53px;
  }

  .timeline-item {
    grid-template-columns: 48px 16px minmax(0, 1fr);
    gap: 8px;
  }

  .timeline-date {
    font-size: 9.5px;
  }

  .calendar-row {
    grid-template-columns: 1fr auto;
    gap: 5px 10px;
    padding: 10px 0;
  }

  .calendar-type {
    grid-column: 1;
    grid-row: 2;
  }

  .calendar-title {
    grid-column: 1;
    grid-row: 3;
  }

  .calendar-note {
    grid-column: 1;
    grid-row: 4;
    text-align: left;
  }

  .calendar-row .status-pill {
    grid-column: 2;
    grid-row: 1;
  }

  .price-row {
    grid-template-columns: 58px minmax(0, 1fr) 76px;
    gap: 8px;
  }

  .risk-matrix {
    grid-template-columns: 20px minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: 22px minmax(140px, auto) minmax(140px, auto);
  }

  .risk-chip strong {
    font-size: 9.5px;
  }

  .risk-chip span {
    font-size: 8.5px;
  }

  .feed-row {
    grid-template-columns: 1fr;
    gap: 5px;
    padding: 13px 14px;
  }

  .feed-source {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-align: left;
  }

  .report-grid {
    grid-template-columns: 1fr;
  }

  .slope-stats {
    grid-template-columns: 1fr;
  }

  .drawer {
    width: 100vw;
  }
}

@media (max-width: 430px) {
  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .kpi-grid.six {
    grid-template-columns: 1fr;
  }

  .topbar-right {
    flex-wrap: wrap;
  }

  .live-pill {
    order: 3;
  }
}

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

@media print {
  .sidebar,
  .topbar,
  .drawer,
  .drawer-overlay,
  .toast {
    display: none !important;
  }

  .app {
    display: block;
  }

  .content {
    max-width: none;
    padding: 0;
  }

  .panel,
  .kpi-grid,
  .actions-grid,
  .report-grid {
    break-inside: avoid;
  }
}
