:root {
  --brand-green-950: #003f24;
  --brand-green-900: #00552f;
  --brand-green-800: #00713e;
  --brand-green: #218a63;
  --brand-lime: #74b743;
  --brand-lime-soft: #eef9e7;
  --brand-teal: #40a7a4;
  --brand-teal-soft: #e9f7f6;
  --brand-purple: #764d98;
  --brand-purple-dark: #5f3d7b;
  --brand-purple-soft: #f3eef7;
  --ink: #172033;
  --muted: #667085;
  --muted-light: #8c98a8;
  --line: #d8dee8;
  --line-soft: #e9edf2;
  --bg: #f4f6f8;
  --surface: #ffffff;
  --green: #218a63;
  --green-bg: #e9f7f1;
  --amber: #a86d13;
  --amber-bg: #fff5df;
  --red: #c24134;
  --red-bg: #fcecea;
  --violet: #764d98;
  --blue: #00713e;
  --blue-soft: #eef9e7;
  --navy: #003f24;
  --shadow-raised: 0 18px 42px rgba(0, 63, 36, .10);
  --shadow-focus: 0 0 0 3px rgba(118, 77, 152, .16);
}

* { box-sizing: border-box; }

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: "Poppins", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
}

body { font-size: 14px; line-height: 1.45; }
a { color: inherit; text-decoration: none; }
button,
input,
select,
textarea { font: inherit; }
button,
a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid rgba(118, 77, 152, .28); outline-offset: 2px; }

.material-symbols-rounded {
  font-family: "Material Symbols Rounded";
  font-weight: normal;
  font-style: normal;
  font-size: 21px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
}

/* Application shell */
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 258px;
  background: var(--surface);
  color: var(--ink);
  border-right: 1px solid var(--line);
  padding: 22px 17px;
  display: flex;
  flex-direction: column;
  z-index: 30;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 3px 8px 18px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 13px;
}

.platform-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid !important;
  place-items: center;
  background: var(--brand-green-950);
  color: #fff !important;
  font-size: 12px !important;
  letter-spacing: -.04em !important;
  margin: 0 !important;
}
.brand > span {
  min-width: 0;
}
.brand strong,
.brand small { display: block; }
.brand strong { color: var(--brand-green-950); font-size: 12px; letter-spacing: -.02em; }
.brand small { color: var(--muted); font-size: 8px; margin-top: 2px; text-transform: uppercase; letter-spacing: .08em; }
.current-company { display: flex; align-items: center; gap: 9px; padding: 0 10px 15px; color: var(--brand-green-950); font-weight: 700; font-size: 10px; }
.current-company img,
.company-initial { width: 28px; height: 28px; border-radius: 7px; object-fit: contain; background: #fff; border: 1px solid var(--line-soft); padding: 3px; }
.company-initial { display: grid; place-items: center; background: var(--brand-lime-soft); color: var(--brand-green-950); padding: 0; }

.sidebar nav { display: grid; gap: 5px; }
.nav-label {
  padding: 0 13px 7px;
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .14em;
}
.nav-label-spaced { margin-top: 17px; }

.sidebar nav a {
  min-height: 44px;
  padding: 10px 13px;
  border-radius: 8px;
  color: #4c5b6b;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 13px;
  display: flex;
  gap: 12px;
  align-items: center;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}

.sidebar nav a .material-symbols-rounded {
  width: 22px;
  color: #718093;
  font-size: 20px;
}

.sidebar nav a:hover {
  color: var(--brand-green-800);
  background: #f7faf7;
}

.sidebar nav a.active {
  color: var(--brand-green-950);
  background: var(--brand-lime-soft);
  border-color: #dcefd2;
  box-shadow: inset 3px 0 0 var(--brand-lime);
}

.sidebar nav a.active .material-symbols-rounded { color: var(--brand-green-800); }

.sidebar-foot {
  margin-top: auto;
  border: 1px solid #dcefd2;
  border-radius: 8px;
  padding: 13px;
  background: var(--brand-lime-soft);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-foot strong,
.sidebar-foot small { display: block; }
.sidebar-foot strong { font-size: 10px; color: var(--brand-green-950); }
.sidebar-foot small { font-size: 9px; color: var(--brand-green-800); margin-top: 2px; }

.live-dot,
.status-dot {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(33, 138, 99, .12);
}

.sidebar-overlay { display: none; }
.main { margin-left: 258px; min-height: 100vh; }

.topbar {
  min-height: 72px;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  padding: 0 32px;
  position: sticky;
  top: 0;
  z-index: 20;
}

.menu-button {
  display: none;
  border: 0;
  background: transparent;
  color: var(--brand-green-800);
  padding: 5px;
  cursor: pointer;
}

.topbar-title strong,
.topbar-title span,
.topbar-context span,
.topbar-context strong { display: block; }
.topbar-title strong { color: var(--brand-green-950); font-size: 14px; }
.topbar-title span { color: var(--muted); font-size: 10px; margin-top: 2px; }
.company-switcher { display: grid; grid-template-columns: auto minmax(150px, 220px); gap: 7px; align-items: center; margin-left: auto; margin-right: 18px; }
.company-switcher label { color: var(--muted); font-size: 9px; font-weight: 700; }
.company-switcher select { min-height: 34px; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink); font-size: 10px; padding: 0 8px; }
.topbar-context { margin-left: auto; text-align: right; margin-right: 14px; }
.company-switcher + .topbar-context { margin-left: 0; }
.topbar-context span { font-size: 9px; color: var(--muted); }
.topbar-context strong { font-size: 10px; color: #4f5e6d; margin-top: 2px; }
.logout-form { margin: 0 10px 0 0; }
.logout-button { display: inline-flex; align-items: center; justify-content: center; width: 34px; min-height: 34px; padding: 0; border: 1px solid #d8c8e4; border-radius: 8px; background: #fff; color: var(--brand-purple); font: inherit; font-size: 10px; font-weight: 700; cursor: pointer; }
.logout-button:hover { background: var(--brand-purple-soft); border-color: #c7b2d6; }
.logout-button .material-symbols-rounded { font-size: 16px; }

.avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--brand-purple-soft);
  color: var(--brand-purple);
  border: 1px solid #e3d8eb;
  font-weight: 700;
  font-size: 11px;
}

.content { padding: 32px; max-width: 1540px; margin: auto; }

/* Page hierarchy and actions */
.page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 26px;
}
.page-head.compact { margin-bottom: 23px; }

.eyebrow,
.card-label {
  font-size: 9px;
  letter-spacing: .14em;
  color: var(--brand-green-800);
  font-weight: 700;
  margin: 0 0 8px;
}

.page-head h1,
.detail-head h1 {
  margin: 0;
  color: var(--brand-green-950);
  font-size: clamp(26px, 2.2vw, 32px);
  line-height: 1.14;
  letter-spacing: -.035em;
}

.page-head p:not(.eyebrow),
.detail-head p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.head-actions { display: flex; gap: 12px; align-items: center; }
.updated { font-size: 10px; color: var(--muted); }

.messages { margin: 0 0 16px; }
.message { border: 1px solid #cce8da; border-left: 4px solid #20a271; border-radius: 10px; background: #f2fbf6; color: var(--brand-green-950); padding: 11px 13px; font-size: 11px; font-weight: 600; }
.message.error { border-color: #f0c7c3; border-left-color: #bf4b43; background: #fff6f5; color: #812b25; }

.button {
  min-height: 38px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 7px;
  background: var(--brand-purple);
  color: #fff;
  border: 1px solid var(--brand-purple);
  border-radius: 999px;
  padding: 9px 17px;
  font-weight: 600;
  font-size: 11px;
  cursor: pointer;
  transition: background .16s ease, border-color .16s ease, transform .16s ease;
}
.button:hover { background: var(--brand-purple-dark); border-color: var(--brand-purple-dark); }
.button:active { transform: translateY(1px); }
.button.secondary { background: #fff; color: var(--brand-purple); border-color: #d8c8e4; }
.button.secondary:hover { background: var(--brand-purple-soft); border-color: #c7b2d6; }

/* Internal billing */
.billing-page-head { margin-bottom: 20px; }
.billing-create { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 20px; }
.billing-create h2 { margin: 4px 0 0; }
.billing-create p { color: var(--muted); font-size: 10px; margin: 6px 0 0; }
.billing-create-form { display: grid; grid-template-columns: minmax(180px, 250px) auto; gap: 9px; align-items: end; min-width: min(100%, 400px); }
.billing-create-form label { grid-column: 1 / -1; color: var(--muted); font-size: 9px; font-weight: 700; }
.billing-create-form select,
.billing-form-grid input,
.billing-form-grid textarea { width: 100%; border: 1px solid var(--line); background: #fff; border-radius: 7px; color: var(--ink); padding: 9px 10px; outline: 0; }
.billing-create-form select { height: 38px; font-size: 11px; }
.billing-create-form select:focus,
.billing-form-grid input:focus,
.billing-form-grid textarea:focus { border-color: var(--brand-purple); box-shadow: var(--shadow-focus); }
.selected-company { min-height: 38px; display: flex; align-items: center; padding: 9px 12px; border: 1px solid var(--line); border-radius: 7px; background: #f8faf9; color: var(--brand-green-950); font-size: 11px; font-weight: 700; }
.billing-kpis .kpi { min-height: 126px; }
.billing-table { margin-bottom: 20px; }
.invoice-status { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 8px; font-weight: 700; background: #f0f2f4; color: #687683; }
.invoice-status.draft { background: var(--amber-bg); color: var(--amber); }
.invoice-status.issued { background: var(--brand-teal-soft); color: #287d79; }
.invoice-status.paid { background: var(--green-bg); color: var(--green); }
.invoice-status.void { background: var(--red-bg); color: var(--red); }
.billing-detail-head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.billing-actions { flex-wrap: wrap; justify-content: flex-end; }
.billing-actions form { margin: 0; }
.billing-notice { display: flex; align-items: flex-start; gap: 10px; border: 1px solid #ead9b3; border-left: 4px solid var(--amber); background: #fffaf0; border-radius: 9px; color: #655224; padding: 11px 13px; margin-bottom: 20px; font-size: 10px; }
.billing-notice .material-symbols-rounded { font-size: 18px; }
.billing-notice p { margin: 0; }
.billing-notice.issued { border-color: #cde5dd; border-left-color: var(--green); background: #f4fbf8; color: var(--brand-green-950); }
.billing-detail-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(290px, .8fr); gap: 20px; margin-bottom: 20px; }
.billing-summary .panel-head,
.billing-provider-summary .panel-head { margin-bottom: 12px; }
.billing-breakdown { margin: 0; }
.billing-breakdown div { display: flex; justify-content: space-between; gap: 18px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); font-size: 11px; }
.billing-breakdown dt { color: var(--muted); }
.billing-breakdown dd { margin: 0; color: var(--ink); font-weight: 700; text-align: right; }
.billing-breakdown .total { padding-top: 15px; border-bottom: 0; }
.billing-breakdown .total dt,
.billing-breakdown .total dd { color: var(--brand-green-950); font-size: 14px; font-weight: 700; }
.billing-breakdown.compact div { padding: 10px 0; }
.billing-meta { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 12px; }
.billing-meta div { padding: 10px; background: var(--bg); border-radius: 7px; }
.billing-meta span { display: block; color: var(--muted); font-size: 8px; }
.billing-meta strong { display: block; color: var(--brand-green-950); font-size: 12px; margin-top: 4px; }
.billing-footnote { color: var(--muted); font-size: 9px; margin: 14px 0 0; }
.billing-editor { margin-bottom: 20px; }
.billing-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.billing-form-grid label { color: var(--muted); display: grid; gap: 6px; font-size: 9px; font-weight: 700; }
.billing-form-grid .billing-notes { grid-column: span 3; }
.billing-form-grid textarea { resize: vertical; min-height: 80px; }
.field-error,
.form-errors { color: var(--red); font-size: 9px; }

.reconciliation-table { margin-top: 20px; }
.reconciliation-status { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 8px; font-weight: 700; white-space: nowrap; }
.reconciliation-status.reconciled { background: var(--green-bg); color: var(--green); }
.reconciliation-status.pending { background: var(--amber-bg); color: var(--amber); }
.reconciliation-status.unavailable { background: #f0f2f4; color: #687683; }
.muted-value { color: var(--muted); }

/* Cards and KPI */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
  margin-bottom: 20px;
}
.kpi-grid.three { grid-template-columns: repeat(3, 1fr); }

.kpi,
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.kpi {
  min-height: 144px;
  padding: 20px 20px 17px;
  position: relative;
  overflow: hidden;
}
.kpi::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 3px;
  background: var(--brand-lime);
}
.kpi:nth-child(3)::after { background: var(--brand-teal); }
.kpi:nth-child(4)::after { background: var(--brand-purple); }

.kpi-icon {
  position: absolute;
  right: 17px;
  top: 17px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
}
.kpi-icon.blue { background: var(--brand-lime-soft); color: var(--brand-green-800); }
.kpi-icon.green { background: var(--green-bg); color: var(--green); }
.kpi-icon.violet { background: var(--brand-purple-soft); color: var(--violet); }
.kpi-icon.amber { background: var(--amber-bg); color: var(--amber); }
.kpi p { font-size: 10px; color: var(--muted); margin: 0 44px 11px 0; }
.kpi strong { color: var(--brand-green-950); font-size: 27px; display: block; letter-spacing: -.04em; }
.kpi small { display: block; color: var(--muted-light); margin-top: 7px; font-size: 9px; }

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, .8fr);
  gap: 20px;
  margin-bottom: 20px;
}
.panel { padding: 21px; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 17px; }
.panel h2 { color: var(--brand-green-950); font-size: 15px; margin: 0; letter-spacing: -.02em; }
.panel-head p { font-size: 10px; color: var(--muted); margin: 5px 0 0; }
.pill {
  border: 1px solid #dcefd2;
  border-radius: 999px;
  padding: 5px 10px;
  color: var(--brand-green-800);
  font-size: 9px;
  font-weight: 600;
  background: var(--brand-lime-soft);
}

/* Dashboard charts */
.bar-chart {
  height: 192px;
  display: flex;
  align-items: flex-end;
  gap: 7px;
  padding-top: 18px;
  border-bottom: 1px solid var(--line);
}
.bar-column {
  height: 100%;
  flex: 1;
  min-width: 7px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  position: relative;
}
.bar {
  width: 70%;
  max-width: 22px;
  background: var(--brand-teal);
  border-radius: 4px 4px 0 0;
  min-height: 8px;
  transition: background .16s ease;
}
.bar-column:hover .bar { background: var(--brand-purple); }
.bar-column small { height: 20px; font-size: 8px; color: var(--muted-light); padding-top: 6px; }
.bar-value { font-size: 8px; color: var(--muted); opacity: 0; margin-bottom: 3px; }
.bar-column:hover .bar-value { opacity: 1; }
.topic-list { display: grid; gap: 4px; }
.topic-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line-soft); font-size: 11px; }
.topic-row:last-child { border: 0; }
.topic-row span { display: flex; align-items: center; gap: 10px; }
.topic-row i { font-style: normal; width: 24px; height: 24px; border-radius: 50%; background: var(--brand-lime-soft); color: var(--brand-green-800); display: grid; place-items: center; font-size: 9px; font-weight: 700; }
.topic-row strong { background: var(--bg); border-radius: 999px; padding: 4px 8px; font-size: 9px; }

/* Tables */
.calls-panel { padding: 0; overflow: hidden; }
.calls-panel .panel-head,
.usage-table .panel-head { padding: 20px 21px 0; }
.text-link { color: var(--brand-purple); font-weight: 600; font-size: 10px; }
.text-link:hover { text-decoration: underline; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; white-space: nowrap; }
th {
  text-align: left;
  color: #738092;
  background: #f8faf9;
  font-size: 8px;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 11px 17px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
td { padding: 13px 17px; border-bottom: 1px solid var(--line-soft); font-size: 11px; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fbfdfb; }
td strong,
td small { display: block; }
td small { font-size: 9px; color: var(--muted-light); margin-top: 3px; }
.call-title { color: var(--ink); font-weight: 600; }
.call-title:hover { color: var(--brand-purple); }

.status,
.sentiment,
.followup,
.urgency {
  display: inline-flex;
  align-items: center;
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 8px;
  font-weight: 700;
}
.status.success,
.sentiment.positive,
.followup.completed,
.urgency.low { background: var(--green-bg); color: var(--green); }
.status.failure,
.sentiment.negative,
.urgency.high,
.urgency.critical { background: var(--red-bg); color: var(--red); }
.status.transferred,
.urgency.normal { background: var(--brand-teal-soft); color: #287d79; }
.status.unknown,
.sentiment.neutral,
.followup.none { background: #f0f2f4; color: #687683; }
.followup.open { background: var(--amber-bg); color: var(--amber); }
.row-arrow { font-size: 23px; color: var(--brand-purple); }

/* Filters */
.filter-bar { display: flex; gap: 9px; margin-bottom: 16px; }
.filter-bar select,
.search {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  height: 40px;
}
.filter-bar select { padding: 0 30px 0 12px; color: #536171; font-size: 10px; }
.filter-bar select:focus,
.search:focus-within { border-color: var(--brand-purple); box-shadow: var(--shadow-focus); outline: 0; }
.search { display: flex; align-items: center; gap: 8px; padding: 0 12px; flex: 1; max-width: 430px; }
.search span { font-size: 18px; color: var(--muted-light); }
.search input { border: 0; outline: 0; width: 100%; font-size: 10px; }
.standalone { min-height: 300px; }

/* Call detail */
.back-link { font-size: 10px; color: var(--brand-purple); font-weight: 600; display: inline-flex; align-items: center; gap: 5px; margin-bottom: 20px; }
.back-link .material-symbols-rounded { font-size: 16px; }
.back-link:hover { text-decoration: underline; }
.detail-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 22px; }
.detail-head h1 { margin-top: 12px; }
.detail-badges { display: flex; flex-wrap: wrap; gap: 7px; }
.cost-block { text-align: right; }
.cost-block small,
.cost-block strong { display: block; }
.cost-block small { font-size: 9px; color: var(--muted); }
.cost-block strong { color: var(--brand-green-950); font-size: 24px; margin-top: 4px; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(260px, .72fr); gap: 20px; }
.detail-grid > div { display: grid; gap: 20px; }
.detail-grid aside { display: grid; align-content: start; gap: 20px; }
.summary-card { border-left: 4px solid var(--brand-teal); }
.summary-card p { font-size: 12px; line-height: 1.7; margin: 10px 0 0; }
.transcript { display: grid; gap: 18px; }
.turn { display: grid; grid-template-columns: 34px 1fr; gap: 11px; }
.speaker {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--brand-lime-soft);
  color: var(--brand-green-800);
  display: grid;
  place-items: center;
  font-size: 9px;
  font-weight: 700;
}
.turn.user .speaker { background: var(--brand-purple-soft); color: var(--brand-purple); }
.turn strong { font-size: 10px; }
.turn time { font-weight: 400; color: var(--muted-light); margin-left: 8px; }
.turn p { font-size: 11px; line-height: 1.58; margin: 6px 0 0; background: #f7faf8; border-radius: 3px 8px 8px 8px; padding: 11px 13px; }
.turn.user p { background: var(--brand-purple-soft); }
.facts dl { margin: 17px 0 0; }
.facts dl div { display: flex; justify-content: space-between; gap: 14px; }
.facts dt,
.facts dd { font-size: 10px; border-bottom: 1px solid var(--line-soft); padding: 10px 0; margin: 0; }
.facts dt { color: var(--muted); }
.facts dd { text-align: right; font-weight: 600; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 8px !important; word-break: break-all; }
.privacy-note { background: var(--brand-lime-soft); border-color: #dcefd2; }
.privacy-note strong { font-size: 11px; color: var(--brand-green-950); }
.privacy-note p { font-size: 10px; color: #536f5d; line-height: 1.55; margin: 7px 0 0; }

/* Usage and integration */
.usage-table { padding: 0; overflow: hidden; }
.integration-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.provider-card { display: flex; align-items: center; gap: 16px; position: relative; }
.provider-logo { width: 54px; height: 54px; background: #111; color: #fff; border-radius: 8px; display: grid; place-items: center; font-weight: 700; font-size: 17px; }
.provider-logo.twilio-logo { background: #f22f46; font-size: 15px; }
.provider-card p { color: var(--muted); font-size: 10px; margin: 4px 0 0; }
.provider-card .status-dot { position: absolute; right: 22px; top: 22px; background: var(--amber); box-shadow: none; }
.provider-card .status-dot.ready { background: var(--green); }
.config-card { grid-row: span 2; }
.check-row { display: flex; gap: 12px; align-items: center; padding: 15px 0; border-bottom: 1px solid var(--line); }
.check { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--amber-bg); color: var(--amber); font-weight: 700; }
.check.ok { background: var(--green-bg); color: var(--green); }
.check-row strong,
.check-row small { display: block; }
.check-row strong { font-size: 11px; }
.check-row small { font-size: 9px; color: var(--muted); margin-top: 4px; }
.architecture-card { border-top: 3px solid var(--brand-teal); }
.architecture-card p { color: var(--muted); font-size: 10px; line-height: 1.6; }
.adapter-flow { display: flex; align-items: center; gap: 8px; margin-top: 16px; }
.adapter-flow span { padding: 8px 10px; background: var(--brand-lime-soft); color: var(--brand-green-900); border-radius: 6px; font-size: 9px; font-weight: 600; }
.adapter-flow b { color: var(--muted-light); font-size: 16px; }
.setup-card { border-left: 4px solid var(--brand-purple); }
.setup-card ol { padding-left: 18px; margin-bottom: 0; }
.setup-card li { font-size: 10px; line-height: 1.65; margin: 7px 0; }
.setup-card code { background: var(--brand-purple-soft); color: var(--brand-purple-dark); padding: 2px 5px; border-radius: 4px; }
.detail-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.plain-list { list-style: none; margin: 15px 0 0; padding: 0; display: grid; gap: 0; }
.plain-list li { padding: 10px 0; border-bottom: 1px solid var(--line-soft); }
.plain-list li:last-child { border-bottom: 0; }
.plain-list strong,
.plain-list small { display: block; }
.plain-list strong { color: var(--ink); font-size: 10px; }
.plain-list small { color: var(--muted); font-size: 9px; margin-top: 3px; overflow-wrap: anywhere; }
.company-layout { grid-template-columns: minmax(0, 1.4fr) minmax(260px, .6fr); align-items: start; }
.company-side { display: grid; gap: 20px; }
.company-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.settings-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; }
.settings-nav a { border: 1px solid var(--line); background: #fff; color: var(--brand-purple-dark); border-radius: 999px; padding: 7px 11px; font-size: 9px; font-weight: 700; }
.settings-nav a:hover { background: var(--brand-purple-soft); }
.settings-section { margin-bottom: 20px; scroll-margin-top: 24px; }
.section-label { margin: 0 0 13px; }
.section-label h2 { margin: 5px 0; font-size: 18px; }
.section-label p:not(.eyebrow) { max-width: 760px; margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.settings-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(270px, .75fr); gap: 20px; align-items: start; }
.config-card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.stacked-form { display: grid; gap: 14px; }
.stacked-form .form-actions { grid-column: auto; }
.internal-note { display: flex; gap: 13px; background: linear-gradient(145deg, #fbf8fe, #fff); border-left: 4px solid var(--brand-purple); }
.internal-note > .material-symbols-rounded { color: var(--brand-purple); font-size: 25px; }
.internal-note h3 { margin: 1px 0 7px; font-size: 13px; }
.internal-note p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.agent-card { min-width: 0; }
.agent-card.inactive { opacity: .7; background: #fafafa; }
.agent-card-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; border-bottom: 1px solid var(--line-soft); padding-bottom: 14px; }
.agent-card h3 { margin: 8px 0 4px; font-size: 14px; }
.agent-card p { margin: 0; color: var(--muted); font-size: 9px; overflow-wrap: anywhere; }
.agent-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.agent-actions form { margin: 0; }
.small-button { min-height: 32px; padding: 7px 9px; font-size: 9px; }
.small-button .material-symbols-rounded { font-size: 14px; }
.status-badge { display: inline-block; border-radius: 999px; padding: 4px 8px; background: var(--bg); color: var(--muted); font-size: 8px; font-weight: 700; }
.status-badge.ready { background: var(--brand-lime-soft); color: var(--brand-green-800); }
.agent-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 14px 0; }
.agent-facts div { background: #f7faf8; border-radius: 6px; padding: 9px; min-width: 0; }
.agent-facts small, .agent-facts strong { display: block; }
.agent-facts small { color: var(--muted); font-size: 8px; margin-bottom: 4px; }
.agent-facts strong { color: var(--ink); font-size: 9px; overflow-wrap: anywhere; }
.agent-first-message { padding: 9px 10px; background: var(--brand-lime-soft); border-radius: 6px; line-height: 1.5; }
.agent-config-note { margin-top: 13px !important; color: var(--muted) !important; line-height: 1.55; }
.agent-details { margin-top: 13px; border-top: 1px solid var(--line-soft); padding-top: 12px; }
.agent-details summary { color: var(--brand-purple-dark); cursor: pointer; font-size: 9px; font-weight: 700; }
.agent-details p { margin: 10px 0 0; color: var(--ink); line-height: 1.65; white-space: normal; }
.empty-config { color: var(--muted); font-size: 10px; line-height: 1.55; }
.empty-config .material-symbols-rounded { color: var(--brand-purple); font-size: 24px; vertical-align: middle; margin-right: 8px; }
.knowledge-card h3 { margin: 0; font-size: 13px; }
.knowledge-card a { color: var(--brand-purple-dark); text-decoration: underline; text-underline-offset: 2px; }
.audit-list { display: grid; }
.audit-row { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.audit-row:last-child { border-bottom: 0; }
.audit-row > .material-symbols-rounded { color: var(--brand-purple); font-size: 18px; }
.audit-row strong, .audit-row small { display: block; }
.audit-row strong { color: var(--ink); font-size: 10px; }
.audit-row small { color: var(--muted); font-size: 9px; margin-top: 4px; }
.form-field { display: grid; gap: 6px; }
.form-field.span-two,
.form-actions { grid-column: 1 / -1; }
.form-field label { color: var(--muted); font-size: 9px; font-weight: 700; }
.form-field input,
.form-field select { width: 100%; min-height: 39px; border: 1px solid var(--line); border-radius: 7px; padding: 9px 10px; color: var(--ink); background: #fff; outline: 0; }
.form-field input:focus,
.form-field select:focus { border-color: var(--brand-purple); box-shadow: var(--shadow-focus); }
.form-field small { color: var(--muted-light); font-size: 8px; }
.form-actions { padding-top: 5px; }
.empty { text-align: center !important; color: var(--muted-light); padding: 35px !important; }
.customer-summary-note { display: flex; gap: 10px; align-items: center; color: var(--muted); font-size: 10px; padding: 21px; }
.customer-summary-note .material-symbols-rounded { color: var(--brand-green-800); font-size: 18px; }
.customer-summary-note p { margin: 0; }
.customer-calls-table td { vertical-align: middle; }
.customer-calls-table .mini-topic { margin-top: 0; }
.customer-call-row { cursor: pointer; }
.customer-call-row:hover td { background: var(--brand-lime-soft); }
.customer-call-cell-link { display: block; color: inherit; }
.customer-call-cell-link:focus-visible { outline: 2px solid var(--brand-purple); outline-offset: 3px; border-radius: 3px; }
.result-pill { display: inline-block; border-radius: 999px; padding: 4px 8px; background: var(--bg); color: var(--muted); font-size: 9px; font-weight: 700; }
.result-pill.success { background: var(--brand-lime-soft); color: var(--brand-green-800); }
.result-pill.transferred { background: var(--brand-purple-soft); color: var(--brand-purple-dark); }
.result-pill.failure { background: var(--red-bg); color: var(--red); }
.customer-followup-note { margin: 16px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.compact-kpis { margin: 17px 0; }
.compact-kpis .kpi { min-height: 0; }
.twilio-usage { margin-top: 17px; }

/* Quality and follow-up */
.summary-cell { max-width: 370px; white-space: normal; }
.summary-cell small { line-height: 1.4; }
.mini-topic { display: inline-block; margin-top: 7px; padding: 3px 7px; border-radius: 999px; background: var(--brand-lime-soft); color: var(--brand-green-800); font-size: 8px; font-weight: 700; }
.score { color: var(--brand-green-800); font-size: 13px !important; }
.summary-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin-top: 20px; padding-top: 17px; border-top: 1px solid var(--line); }
.summary-facts div { background: #f7faf8; border-radius: 6px; padding: 11px; }
.summary-facts small,
.summary-facts strong { display: block; }
.summary-facts small { font-size: 8px; color: var(--muted); margin-bottom: 5px; }
.summary-facts strong { font-size: 10px; line-height: 1.4; }
.cost-breakdown { overflow: hidden; }
.cost-breakdown-head { display: flex; justify-content: space-between; gap: 22px; align-items: flex-start; padding-bottom: 18px; border-bottom: 1px solid var(--line-soft); }
.cost-breakdown-head h2 { margin: 5px 0 4px; }
.cost-breakdown-head p { color: var(--muted); font-size: 10px; margin: 0; }
.cost-total-summary { min-width: 155px; text-align: right; padding: 11px 13px; border-radius: 10px; background: linear-gradient(135deg, #ebf8e5, #f7fcf4); border: 1px solid #d6ebc9; }
.cost-total-summary small,
.cost-total-summary strong,
.cost-total-summary span { display: block; }
.cost-total-summary small { color: var(--brand-green-800); font-size: 8px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.cost-total-summary strong { color: var(--brand-green-950); font-size: 20px; line-height: 1.2; margin: 3px 0 5px; }
.cost-total-summary span { color: var(--brand-green-800); font-size: 8px; }
.cost-total-summary i { font-size: 11px; vertical-align: -2px; }
.cost-provider-section { padding: 16px 0; }
.cost-section-heading { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; }
.cost-section-heading > span { width: 27px; height: 27px; display: grid; place-items: center; background: var(--brand-purple-soft); color: var(--brand-purple); border-radius: 7px; font-size: 15px; }
.cost-section-heading strong,
.cost-section-heading small { display: block; }
.cost-section-heading strong { font-size: 10px; color: var(--ink); }
.cost-section-heading small { color: var(--muted); font-size: 8px; margin-top: 1px; }
.cost-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.cost-metric { position: relative; min-height: 91px; padding: 13px 11px 11px 45px; border: 1px solid var(--line-soft); border-radius: 8px; background: #fbfcfb; }
.cost-metric small,
.cost-metric strong { display: block; }
.cost-metric small { color: var(--muted); font-size: 8px; line-height: 1.3; }
.cost-metric strong { color: var(--brand-green-950); font-size: 15px; margin-top: 6px; }
.metric-icon { position: absolute; top: 12px; left: 11px; width: 25px; height: 25px; display: grid; place-items: center; border-radius: 7px; font-size: 14px; }
.metric-icon.voice { color: var(--brand-green-800); background: var(--brand-lime-soft); }
.metric-icon.llm { color: var(--brand-purple); background: var(--brand-purple-soft); }
.metric-icon.analysis { color: #1c7570; background: var(--brand-teal-soft); }
.telephony-reconciliation { display: grid; grid-template-columns: 31px 1fr auto; align-items: center; gap: 10px; padding: 12px; border-radius: 8px; background: #fffaf0; border: 1px solid #f0dfb8; }
.telephony-icon { width: 29px; height: 29px; display: grid; place-items: center; border-radius: 50%; background: #ffefd0; color: var(--amber); font-size: 15px; }
.telephony-reconciliation strong { display: block; color: #76521a; font-size: 10px; }
.telephony-reconciliation p { margin: 2px 0 0; color: #8c6a32; font-size: 8px; line-height: 1.4; }
.telephony-amount { min-width: 124px; text-align: right; }
.telephony-amount strong,
.telephony-amount small { display: block; }
.telephony-amount strong { color: var(--amber); font-size: 12px; }
.telephony-amount small { color: #8c6a32; font-size: 8px; margin-top: 2px; }
.twilio-call-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; margin-top: 8px; }
.twilio-call-facts div { padding: 8px 9px; border: 1px solid var(--line-soft); border-radius: 7px; background: #fbfcfb; }
.twilio-call-facts small,
.twilio-call-facts strong { display: block; }
.twilio-call-facts small { color: var(--muted); font-size: 8px; }
.twilio-call-facts strong { color: var(--ink); font-size: 9px; margin-top: 2px; overflow-wrap: anywhere; }
.usage-section { margin-top: 16px; padding-top: 15px; border-top: 1px solid var(--line-soft); }
.usage-section-heading { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 9px; margin-bottom: 9px; }
.usage-section-heading span { color: var(--brand-teal); font-size: 14px; }
.usage-chips { display: grid; grid-template-columns: 115px 1fr 1fr; gap: 8px; }
.usage-chips > div { padding: 9px 10px; border-radius: 7px; background: #f6f8f9; }
.usage-chips span,
.usage-chips strong,
.usage-chips small { display: block; }
.usage-chips span { color: var(--muted); font-size: 8px; }
.usage-chips strong { color: var(--ink); font-size: 10px; margin-top: 2px; }
.usage-chips small { color: var(--muted); font-size: 8px; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.llm-usage-section { margin-top: 16px; padding-top: 15px; border-top: 1px solid var(--line-soft); }
.llm-usage-section .usage-section-heading { justify-content: flex-start; }
.llm-usage-section .usage-section-heading > div { flex: 1; }
.llm-usage-section .usage-section-heading small { display: block; color: var(--muted); font-weight: 400; font-size: 8px; margin-top: 2px; }
.llm-reported-cost { color: var(--brand-purple); font-size: 9px; white-space: nowrap; }
.llm-table-wrap { overflow-x: auto; border: 1px solid var(--line-soft); border-radius: 8px; }
.llm-table { width: 100%; min-width: 520px; border-collapse: collapse; }
.llm-table th { background: var(--brand-purple-soft); color: var(--brand-purple-dark); font-size: 8px; letter-spacing: .04em; text-align: left; text-transform: uppercase; }
.llm-table th,
.llm-table td { padding: 9px 10px; border-bottom: 1px solid var(--line-soft); }
.llm-table tbody tr:last-child td { border-bottom: 0; }
.llm-table td { color: var(--ink); font-size: 9px; }
.llm-table td:not(:first-child) { font-variant-numeric: tabular-nums; text-align: right; }
.llm-empty { margin: 0; padding: 11px; border-radius: 7px; background: #f6f8f9; color: var(--muted); font-size: 9px; }
.quality-score { font-size: 23px; color: var(--green); }
.quality-list { display: grid; gap: 7px; }
.quality-check { border: 1px solid var(--line); border-radius: 7px; background: #fbfcfb; }
.quality-check summary { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 9px; padding: 10px 12px; cursor: pointer; list-style: none; }
.quality-check summary::-webkit-details-marker { display: none; }
.quality-check summary strong { font-size: 10px; }
.quality-check summary > span:last-child { font-size: 8px; color: var(--muted); }
.quality-check > p { font-size: 10px; color: var(--muted); line-height: 1.5; padding: 0 14px 12px 49px; margin: 0; }
.quality-icon { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 9px; font-weight: 700; }
.quality-icon.success { background: var(--green-bg); color: var(--green); }
.quality-icon.failure { background: var(--red-bg); color: var(--red); }
.quality-icon.unknown { background: #f0f2f4; color: #687683; }
.reason-box { background: var(--amber-bg); border: 1px solid #f0d89d; border-left: 4px solid var(--amber); border-radius: 6px; padding: 10px 11px; color: #76521a; font-size: 9px; line-height: 1.55; margin-bottom: 14px; }
.followup-card form label { font-size: 9px; color: var(--muted); font-weight: 600; }
.followup-card textarea { display: block; width: 100%; min-height: 78px; resize: vertical; margin: 7px 0 12px; padding: 10px; border: 1px solid var(--line); border-radius: 6px; font-size: 10px; outline: 0; }
.followup-card textarea:focus { border-color: var(--brand-purple); box-shadow: var(--shadow-focus); }
.action-buttons { display: flex; flex-wrap: wrap; gap: 7px; }
.action-buttons .button { font-size: 9px; padding: 8px 11px; }
.segmented { display: inline-flex; flex-wrap: wrap; background: #e9edf0; border-radius: 8px; padding: 4px; margin-bottom: 20px; }
.segmented a { font-size: 9px; font-weight: 600; padding: 8px 12px; border-radius: 6px; color: var(--muted); }
.segmented a.active { background: #fff; color: var(--brand-purple); box-shadow: 0 1px 4px rgba(23, 32, 51, .09); }
.followup-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 17px; }
.followup-item { display: flex; flex-direction: column; }
.followup-item-head { display: flex; justify-content: space-between; align-items: center; }
.followup-item-head small { color: var(--muted); font-size: 9px; }
.followup-item h2 { margin: 15px 0 7px; }
.followup-item h2 a:hover { color: var(--brand-purple); }
.followup-item > p { font-size: 10px; line-height: 1.58; color: var(--muted); margin: 0 0 14px; }
.followup-meta { display: flex; justify-content: space-between; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 8px; }
.followup-meta span { color: var(--brand-green-800); font-weight: 700; }
.followup-item .text-link { margin-top: auto; padding-top: 13px; }
.empty-state { grid-column: 1 / -1; text-align: center; padding: 55px; }
.empty-state > div { margin: auto; width: 45px; height: 45px; border-radius: 50%; display: grid; place-items: center; background: var(--green-bg); color: var(--green); font-size: 20px; }
.empty-state h2 { margin: 14px 0 6px; }
.empty-state p { color: var(--muted); font-size: 10px; }

/* Login */
.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: #eef7f9;
  padding: 28px;
}
.login-shell {
  width: min(930px, 100%);
  min-height: 570px;
  display: grid;
  grid-template-columns: 1.02fr .98fr;
  background: #fff;
  border: 1px solid #c9e0e7;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 18px 42px rgba(45, 122, 147, .14);
}
.login-brand-panel {
  padding: 45px;
  background: linear-gradient(145deg, #2d7a93, #245f74);
  color: #fff;
  display: flex;
  flex-direction: column;
}
.login-brand-panel img {
  width: 260px;
  height: 68px;
  object-fit: contain;
  object-position: left center;
  background: #fff;
  border-radius: 7px;
  padding: 6px 9px;
}
.login-brand-panel > div { margin: auto 0; }
.login-kicker { display: block; color: #c8eaf2; font-size: 9px; font-weight: 700; letter-spacing: .15em; margin-bottom: 14px; }
.login-brand-panel h1 { margin: 0; font-size: 33px; line-height: 1.22; letter-spacing: -.04em; }
.login-brand-panel p { max-width: 390px; margin: 18px 0 0; color: #e4f4f7; font-size: 12px; line-height: 1.7; }
.login-brand-panel > small { color: #c8eaf2; font-size: 10px; font-weight: 600; }
.login-form-panel { display: grid; place-items: center; padding: 45px; background: #fcfeff; }
.login-form-inner { width: min(330px, 100%); }
.secure-mark { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 50%; background: #e2f2f6; color: #2d7a93; margin-bottom: 22px; }
.login-form-inner .eyebrow { color: #2d7a93; }
.login-form-inner h2 { margin: 0; color: #1d5061; font-size: 28px; letter-spacing: -.03em; }
.login-form-inner > p:not(.eyebrow):not(.login-help) { font-size: 11px; color: #5a7480; margin: 8px 0 0; }
.login-form-inner form { display: grid; gap: 16px; margin-top: 28px; }
.login-form-inner label { font-size: 10px; font-weight: 600; color: #315b69; }
.login-form-inner input {
  display: block;
  width: 100%;
  height: 43px;
  border: 1px solid #c5dde5;
  border-radius: 6px;
  margin-top: 7px;
  padding: 0 12px;
  color: #193f4c;
  outline: 0;
}
.login-form-inner input:focus { border-color: #2d7a93; box-shadow: 0 0 0 3px rgba(45, 122, 147, .16); }
.login-button { width: 100%; margin-top: 4px; background: #2d7a93; border-color: #2d7a93; box-shadow: 0 8px 16px rgba(45, 122, 147, .18); }
.login-button:hover { background: #245f74; border-color: #245f74; }
.login-button:focus-visible { outline-color: rgba(45, 122, 147, .34); }
.login-button .material-symbols-rounded { font-size: 17px; }
.login-error { background: var(--red-bg); color: var(--red); border-left: 4px solid var(--red); padding: 10px; border-radius: 6px; font-size: 10px; margin-top: 17px; }
.login-help { display: flex; align-items: center; justify-content: center; gap: 6px; color: #78909a; font-size: 9px; margin: 24px 0 0; }
.login-help .material-symbols-rounded { font-size: 14px; }

/* Responsive */
@media (max-width: 1050px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid,
  .detail-grid,
  .detail-grid.two,
  .company-layout,
  .settings-grid { grid-template-columns: 1fr; }
  .config-card-grid { grid-template-columns: 1fr; }
  .integration-grid { grid-template-columns: 1fr; }
  .config-card { grid-row: auto; }
  .summary-facts { grid-template-columns: repeat(2, 1fr); }
  .cost-metrics { grid-template-columns: repeat(2, 1fr); }
  .twilio-call-facts { grid-template-columns: repeat(2, 1fr); }
  .usage-chips { grid-template-columns: 1fr 1fr; }
  .followup-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .billing-create,
  .billing-detail-head { display: block; }
  .billing-create-form { margin-top: 16px; }
  .billing-actions { justify-content: flex-start; margin-top: 16px; }
  .billing-detail-grid { grid-template-columns: 1fr; }
  .billing-form-grid { grid-template-columns: 1fr; }
  .billing-form-grid .billing-notes { grid-column: auto; }
  .company-form { grid-template-columns: 1fr; }
  .agent-card-head { display: block; }
  .agent-actions { justify-content: flex-start; margin-top: 12px; }
  .agent-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-field.span-two,
  .form-actions { grid-column: auto; }
}

@media (max-width: 760px) {
  body.menu-open { overflow: hidden; }
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; box-shadow: var(--shadow-raised); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 25;
    border: 0;
    background: rgba(0, 31, 18, .48);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
  }
  .sidebar-overlay.open { opacity: 1; pointer-events: auto; }
  .main { margin-left: 0; }
  .topbar { min-height: 64px; padding: 0 16px; }
  .menu-button { display: inline-flex; margin-right: 8px; }
  .topbar-title span,
  .company-switcher,
  .topbar-context { display: none; }
  .logout-form { margin-left: auto; }
  .avatar { margin-left: auto; width: 34px; height: 34px; }
  .content { padding: 22px 16px; }
  .page-head,
  .detail-head { display: block; }
  .head-actions { margin-top: 16px; }
  .kpi-grid,
  .kpi-grid.three,
  .summary-facts,
  .cost-metrics,
  .usage-chips,
  .followup-grid { grid-template-columns: 1fr; }
  .dashboard-grid { display: block; }
  .dashboard-grid .panel { margin-bottom: 16px; }
  .filter-bar { flex-wrap: wrap; }
  .search { max-width: none; flex-basis: 100%; }
  .detail-head .cost-block { text-align: left; margin-top: 16px; }
  .cost-breakdown-head { display: block; }
  .cost-total-summary { margin-top: 13px; text-align: left; }
  .telephony-reconciliation { grid-template-columns: 31px 1fr; }
  .telephony-amount { grid-column: 2; text-align: left; }
  .twilio-call-facts { grid-template-columns: 1fr; }
  .bar-chart { gap: 3px; }
  .bar-column small { display: none; }
  .panel { padding: 17px; }
  .adapter-flow { flex-wrap: wrap; }
  .login-page { padding: 16px; }
  .login-shell { display: block; min-height: 0; }
  .login-brand-panel { padding: 24px; }
  .login-brand-panel img { width: 220px; height: 58px; }
  .login-brand-panel > div { margin: 30px 0 20px; }
  .login-brand-panel h1 { font-size: 25px; }
  .login-brand-panel p { display: none; }
  .login-form-panel { padding: 32px 24px; }
}
