:root {
  --emerald-700: #047857;
  --emerald-600: #059669;
  --emerald-500: #10b981;
  --emerald-50: #ecfdf5;
  --neutral-900: #111827;
  --neutral-700: #374151;
  --neutral-500: #6b7280;
  --neutral-300: #d1d5db;
  --neutral-200: #e5e7eb;
  --neutral-100: #f3f4f6;
  --neutral-50: #f9fafb;
  --amber-600: #d97706;
  --amber-50: #fffbeb;
  --red-600: #dc2626;
  --red-50: #fef2f2;
  --radius: 10px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(17, 24, 39, 0.04);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.history-layout { display: grid; grid-template-columns: minmax(220px, 30%) minmax(0, 1fr); gap: 1rem; }
.history-conversation-panel { min-width: 0; }
.conversation-list { display: grid; gap: .35rem; max-height: 60vh; overflow-y: auto; }
.conversation-choice { display: grid; gap: .25rem; width: 100%; padding: .8rem; background: white; border: 1px solid var(--neutral-200); border-radius: var(--radius-sm); text-align: left; overflow-wrap: anywhere; cursor: pointer; }
.conversation-choice[aria-current="true"] { border-color: var(--emerald-600); background: var(--emerald-50); }
.history-thread { display: flex; flex-direction: column; gap: .75rem; min-width: 0; }
.history-timeline { display: flex; flex-direction: column; gap: .8rem; list-style: none; margin: 0; padding: .4rem; max-height: 65vh; overflow-y: auto; overscroll-behavior: contain; }
.history-message { align-self: flex-start; width: min(100%, 560px); padding: .85rem; border-radius: var(--radius); border: 1px solid var(--neutral-200); background: var(--neutral-50); overflow-wrap: anywhere; }
.history-message.is-outgoing { align-self: flex-end; background: var(--emerald-50); border-color: #b8e8d2; }
.message-direction { font-weight: 650; font-size: .85rem; }
.message-reference { display: block; margin-top: .5rem; }
.message-reply { margin: .5rem 0; padding-left: .65rem; border-left: 3px solid var(--emerald-600); color: var(--neutral-700); }
.history-attachment { display: grid; gap: .5rem; margin-top: .6rem; }
.history-attachment img, .history-attachment video { max-width: 100%; max-height: 330px; border-radius: var(--radius-sm); object-fit: contain; }
.history-attachment audio { width: 100%; }
.history-numbers { border: 0; padding: 0; margin: .6rem 0; }
#queue-numbers { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: .5rem; }
.history-number-choice { display: flex; gap: .5rem; padding: .5rem .65rem; border: 1px solid var(--neutral-200); border-radius: var(--radius-sm); align-items: flex-start; cursor: pointer; }
.history-number-choice span { display: grid; overflow-wrap: anywhere; }
.history-number-choice input { width: auto; flex: 0 0 auto; margin-top: .3rem; }
.queue-number + .queue-number { border-top: 1px solid var(--neutral-200); padding-top: .85rem; margin-top: .85rem; }
.queue-rows { list-style: none; padding: 0; margin: .5rem 0; max-height: 340px; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.queue-event { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: .6rem; align-items: center; padding: .6rem .3rem; border-bottom: 1px solid var(--neutral-200); overflow-wrap: anywhere; }
.queue-event input { width: auto; flex: 0 0 auto; align-self: flex-start; margin-top: .35rem; }
.queue-blocker { color: #92400e; background: var(--amber-50); padding: .35rem .5rem; border-radius: .3rem; }
.history-dialog { width: min(580px, calc(100% - 2rem)); border: 0; border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); max-height: 85vh; overflow: auto; }
.history-dialog::backdrop { background: rgb(17 24 39 / 55%); }
#view-delivery .row-form .field { flex: 1 1 260px; }
#view-delivery .row-form .field select { flex: 0 0 auto; }
.history-system-event { align-self: center; background: white; }
@media (max-width: 760px) { .history-layout { grid-template-columns: 1fr; } .conversation-list { max-height: 220px; } .history-timeline { max-height: 65vh; } }

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font);
  color: var(--neutral-900);
  background: var(--neutral-50);
  line-height: 1.5;
  font-size: 14px;
}

h1, h2, h3, h4 {
  margin: 0 0 0.4rem;
  line-height: 1.25;
}

h1 { font-size: 1.35rem; }
h3 { font-size: 1.05rem; }
h4 { font-size: 0.95rem; }

p { margin: 0 0 0.6rem; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--neutral-100);
  padding: 0.05rem 0.3rem;
  border-radius: 4px;
  font-size: 0.85em;
}

a { color: var(--emerald-700); }

.muted { color: var(--neutral-500); }
.small { font-size: 0.85rem; }

.visually-hidden {
  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: absolute;
  left: -9999px;
  top: 0;
  background: var(--emerald-700);
  color: #fff;
  padding: 0.5rem 0.9rem;
  z-index: 100;
}
.skip-link:focus { left: 0; }

/* Layout */
.layout {
  display: grid;
  grid-template-columns: 212px minmax(0, 1fr);
  height: 100dvh;
}

.sidebar {
  background: #ffffff;
  border-right: 1px solid var(--neutral-200);
  padding: 1rem .75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  height: 100dvh;
  min-height: 0;
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--emerald-600);
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.brand div { display: flex; flex-direction: column; }

.nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.nav-item {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 0.55rem 0.7rem;
  border-radius: var(--radius-sm);
  font: inherit;
  color: var(--neutral-700);
  cursor: pointer;
}
.nav-item:hover { background: var(--neutral-100); }
.nav-item[aria-current="page"] {
  background: var(--emerald-50);
  color: var(--emerald-700);
  font-weight: 600;
}
.nav-item:focus-visible,
.btn:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--emerald-600);
  outline-offset: 2px;
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

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

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .85rem 1.25rem;
  background: #fff;
  border-bottom: 1px solid var(--neutral-200);
  flex: 0 0 auto;
}
.topbar-actions { display: flex; gap: 0.5rem; align-items: center; }

main {
  padding: 1rem 1.25rem;
  width: 100%;
  min-height: 0;
  overflow-y: auto;
  scrollbar-gutter: stable;
  flex: 1;
}

/* Panels */
.panel {
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  margin-bottom: .85rem;
}
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

/* Buttons */
.btn {
  font: inherit;
  border-radius: var(--radius-sm);
  padding: .4rem .7rem;
  min-height: 36px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary {
  background: var(--emerald-600);
  color: #fff;
}
.btn-primary:hover:not(:disabled) { background: var(--emerald-700); }
.btn-danger {
  background: var(--red-600);
  color: #fff;
}
.btn-danger:hover:not(:disabled) { background: #b91c1c; }
.btn-ghost {
  background: #fff;
  border-color: var(--neutral-300);
  color: var(--neutral-700);
}
.btn-ghost:hover:not(:disabled) { background: var(--neutral-100); }

/* Badges */
.badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
}
.badge-warn { background: var(--amber-50); color: var(--amber-600); border: 1px solid #fde68a; }
.badge-ok { background: var(--emerald-50); color: var(--emerald-700); border: 1px solid #a7f3d0; }
.badge-off { background: var(--neutral-100); color: var(--neutral-500); border: 1px solid var(--neutral-200); }
.badge-err { background: var(--red-50); color: var(--red-600); border: 1px solid #fecaca; }

/* Forms */
.row-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.6rem;
}
.row-form label { display: block; width: 100%; font-size: 0.85rem; color: var(--neutral-700); }
.row-form > input,
.row-form > select { flex: 1 1 200px; }
.row-form .field { min-width: 0; flex: 1 1 220px; }

.stack-form { display: flex; flex-direction: column; gap: 0.8rem; }
.field { display: flex; flex-direction: column; gap: 0.25rem; }
.field label { font-size: 0.85rem; color: var(--neutral-700); }

fieldset.field {
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.8rem;
}
fieldset.field legend { font-size: 0.85rem; color: var(--neutral-700); padding: 0 0.3rem; }
.radio { display: flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; }
.radio input { width: auto; }
#proxy-fields { display: flex; flex-direction: column; gap: 0.7rem; }
#proxy-fields[hidden] { display: none; }

input, select, textarea {
  font: inherit;
  padding: 0.5rem 0.6rem;
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-sm);
  background: #fff;
  color: inherit;
  width: 100%;
  min-width: 0;
}
textarea { resize: vertical; }

.help { font-size: 0.78rem; color: var(--neutral-500); }

/* States */
.state {
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  background: var(--neutral-100);
  color: var(--neutral-700);
  font-size: 0.9rem;
  margin: 0.4rem 0;
}
.state[hidden] { display: none; }
.state.is-empty { background: var(--neutral-50); border: 1px dashed var(--neutral-300); }
.state.is-error { background: var(--red-50); color: var(--red-600); }
.state.is-pending { background: var(--amber-50); color: var(--amber-600); }

.alert {
  padding: 0.6rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-top: 0.6rem;
}
.alert-error { background: var(--red-50); color: var(--red-600); }
.alert-ok { background: var(--emerald-50); color: var(--emerald-700); }
.alert-warn { background: var(--amber-50); color: var(--amber-600); }
.alert[hidden] { display: none; }

/* Cards */
.cards {
  list-style: none;
  margin: 0.6rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 0.8rem;
}
.card {
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius);
  padding: 0.9rem;
  display: flex;
  gap: 0.8rem;
  align-items: center;
  background: #fff;
}
.avatar {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--emerald-50);
  color: var(--emerald-700);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  border: 1px solid #a7f3d0;
}
.card-body { min-width: 0; }
.card-name {
  font-weight: 600;
  overflow-wrap: anywhere;
}
.card-phone { font-size: 0.9rem; color: var(--neutral-700); font-variant-numeric: tabular-nums; }
.card-id { font-size: 0.78rem; color: var(--neutral-500); word-break: break-all; }

/* Lists */
.list { list-style: none; margin: 0.6rem 0 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.list-item {
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.list-item .meta { font-size: 0.78rem; color: var(--neutral-500); display: flex; flex-wrap: wrap; gap: 0.5rem; }
.prewrap { white-space: pre-wrap; word-break: break-word; }

.kv { display: grid; grid-template-columns: max-content 1fr; gap: 0.3rem 0.8rem; margin: 0.5rem 0; }
.kv dt { color: var(--neutral-500); font-size: 0.85rem; }
.kv dd { margin: 0; word-break: break-word; }

.preview {
  margin-top: 1rem;
  padding: 0.9rem;
  border: 1px solid var(--emerald-500);
  border-radius: var(--radius);
  background: var(--emerald-50);
}

.qr-box {
  margin-top: 0.8rem;
  display: flex;
  justify-content: center;
  padding: 0.8rem;
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius);
}
.qr-box img { width: 256px; height: 256px; image-rendering: pixelated; }

.pager { display: flex; align-items: center; gap: 0.8rem; margin-top: 0.8rem; }

.toast {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  background: var(--neutral-900);
  color: #fff;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  max-width: 90vw;
  z-index: 50;
}
.toast[hidden] { display: none; }

/* Login */
.login-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  background: linear-gradient(160deg, var(--emerald-50), var(--neutral-50));
}
.login-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.login-card form { display: flex; flex-direction: column; gap: 0.5rem; }
.login-card label { font-size: 0.85rem; color: var(--neutral-700); }

/* Lifecycle actions and dialogs */
.lifecycle-actions { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .3rem; }

.dialog-overlay {
  position: fixed;
  inset: 0;
  background: rgba(17, 24, 39, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 60;
}

.dialog {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--neutral-200);
  box-shadow: var(--shadow);
  padding: 1.2rem;
  width: 100%;
  max-width: 460px;
  max-height: 90vh;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.dialog-buttons { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: flex-end; }

@media (max-width: 480px) {
  .dialog { padding: 1rem; }
  .dialog-buttons { flex-direction: column-reverse; }
  .dialog-buttons .btn { width: 100%; }
}

/* Author display rules must never reveal controls hidden by state. */
[hidden] { display: none !important; }

/* Shared compact layout and native disclosure controls. */
#main:focus { outline: none; }
.view { max-width: 1440px; margin-inline: auto; min-width: 0; }
.topbar-titles { min-width: 0; }
.topbar-titles p { margin: .2rem 0 0; }
.topbar-actions { flex-shrink: 0; }
.panel-head h3 { margin: 0; }
.field, .panel, .card { min-width: 0; }
summary { cursor: pointer; font-weight: 600; }
summary:focus-visible, a:focus-visible, pre:focus-visible { outline: 2px solid var(--emerald-600); outline-offset: 3px; }
details.panel > summary { padding: .1rem 0; }
details.panel[open] > summary { margin-bottom: .75rem; }
.compact-form .stack-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
.compact-form fieldset { margin: 0; }
.compact-form button[type="submit"] { align-self: end; justify-self: start; }
.instance-card { display: grid; grid-template-columns: 40px minmax(0, 1fr); grid-template-rows: 1fr auto; align-items: start; gap: .6rem; padding: .85rem; }
.instance-card .avatar { width: 40px; height: 40px; }
.instance-card .lifecycle-actions { grid-column: 1 / -1; padding-top: .6rem; border-top: 1px solid var(--neutral-200); }
.instance-card .lifecycle-actions .btn { flex: 1 1 auto; font-size: .8rem; }
.card-badges { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; margin-top: .35rem; }
#instances-state:not(.is-error):not(.is-empty):not(.is-pending) { background: transparent; padding: 0; margin: .25rem 0; }
#connection-route-summary { padding: 0; margin: .65rem 0 .25rem; color: var(--neutral-700); }
#queue-state { background: transparent; padding: 0; margin: .65rem 0 0; font-size: .8rem; }
.history-number-choice:has(input:checked) { border-color: #a7d9c7; background: #f5fcf9; }
.queue-event-heading { display: flex; align-items: center; flex-wrap: wrap; gap: .3rem .5rem; }
.queue-event-heading > span:not(.badge) { font-size: .85rem; }
.queue-event > .btn { font-size: .8rem; }
.queue-event .queue-blocker { margin: .25rem 0; font-size: .8rem; }
.queue-number > h3 { font-size: .95rem; margin-bottom: .15rem; }
.queue-number > p { margin-bottom: .35rem; }
.queue-rows > li:last-child { border-bottom: 0; }
.queue-rows:has(.queue-event) { border-top: 1px solid var(--neutral-200); }
.queue-operation-panel .row-form { margin-bottom: .5rem; }
#history-messages-tab[aria-pressed="true"], #history-events-tab[aria-pressed="true"] { color: var(--emerald-700); border-color: #a7d9c7; background: var(--emerald-50); }
.kv { grid-template-columns: minmax(80px, max-content) minmax(0, 1fr); }
.pager { flex-wrap: wrap; }

/* Human-only inspection: fixed header/footer, independently scrollable panes. */
.delivery-dialog { width: min(1100px, calc(100% - 2rem)); height: min(760px, calc(100dvh - 2rem)); max-height: calc(100dvh - 2rem); padding: 0; overflow: hidden; }
.delivery-dialog[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.delivery-header, .delivery-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .5rem; padding: .85rem 1rem; background: white; }
.delivery-header { border-bottom: 1px solid var(--neutral-200); }
.delivery-header > div { min-width: 0; }
.delivery-header h2 { font-size: 1.1rem; overflow-wrap: anywhere; }
.delivery-header p { margin: .25rem 0 0; }
.delivery-footer { border-top: 1px solid var(--neutral-200); justify-content: flex-end; }
.delivery-detail-grid { display: grid; grid-template-columns: minmax(250px, .85fr) minmax(0, 1.35fr); min-height: 0; }
.delivery-overview { overflow-y: auto; padding: 1rem; border-right: 1px solid var(--neutral-200); }
.delivery-payload { display: flex; flex-direction: column; gap: .6rem; padding: 1rem; min-height: 0; min-width: 0; background: var(--neutral-50); }
.delivery-payload > p { margin: 0; font-size: .78rem; }
.delivery-dialog h3 { font-size: .86rem; margin: 0 0 .35rem; }
.delivery-destination p { overflow-wrap: anywhere; margin: 0; }
.delivery-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin: 1rem 0; }
.delivery-facts dt { font-size: .75rem; color: var(--neutral-500); }
.delivery-facts dd { margin: .15rem 0 0; overflow-wrap: anywhere; font-size: .85rem; }
.delivery-json { flex: 1; min-height: 0; overflow: auto; padding: .85rem; margin: 0; background: white; border: 1px solid var(--neutral-200); border-radius: var(--radius-sm); white-space: pre-wrap; overflow-wrap: anywhere; font: .76rem/1.5 ui-monospace, monospace; tab-size: 2; }
.delivery-section, .delivery-overview .queue-blocker { padding: .65rem; margin-bottom: .65rem; background: var(--neutral-50); border-radius: var(--radius-sm); font-size: .85rem; }
.delivery-overview .queue-blocker { background: var(--amber-50); }
.delivery-section p, .delivery-overview .queue-blocker p { margin: 0; }
.delivery-overview .queue-blocker .btn { margin-top: .5rem; max-width: 100%; }
.delivery-error { background: var(--red-50); color: #991b1b; }
.delivery-overview details { font-size: .8rem; overflow-wrap: anywhere; }
.delivery-overview details p { margin-top: .5rem; }
@media (max-width: 1040px) {
  .layout { grid-template-columns: 190px minmax(0, 1fr); }
  .sidebar { padding: .75rem .5rem; }
  .nav-item { padding: .5rem; font-size: .85rem; }
  main { padding: .85rem; }
}
@media (max-width: 760px) {
  .layout { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .sidebar { display: grid; grid-template-columns: minmax(0, 1fr) auto; height: auto; padding: .5rem .75rem; gap: .45rem; border-right: 0; border-bottom: 1px solid var(--neutral-200); overflow: hidden; }
  .sidebar .brand { grid-column: 1; grid-row: 1; }
  .brand-mark { width: 30px; height: 30px; font-size: .8rem; }
  .brand .small { font-size: .7rem; }
  .sidebar-footer { grid-column: 2; grid-row: 1; margin: 0; }
  .sidebar-footer > .badge { display: none; }
  .sidebar nav { grid-column: 1 / -1; grid-row: 2; overflow-x: auto; }
  .nav { flex-direction: row; flex-wrap: nowrap; width: max-content; }
  .nav-item { white-space: nowrap; min-height: 40px; }
  .topbar { padding: .65rem .75rem; gap: .5rem; }
  .topbar h1 { font-size: 1.1rem; }
  .topbar-titles p { font-size: .75rem; }
  .topbar-actions > .badge { display: none; }
  .btn { min-height: 40px; }
  main { padding: .75rem; }
  .panel { padding: .85rem; }
  .compact-form .stack-form { grid-template-columns: minmax(0, 1fr); }
  .compact-form button[type="submit"] { justify-self: stretch; }
  .queue-event { grid-template-columns: 18px minmax(0, 1fr); }
  .queue-event > .btn { grid-column: 2; justify-self: start; }
  .queue-rows { max-height: 320px; }
  .delivery-dialog { width: calc(100% - 1rem); height: calc(100dvh - 1rem); max-height: calc(100dvh - 1rem); }
  .delivery-header, .delivery-footer { padding: .65rem .85rem; }
  .delivery-detail-grid { display: block; overflow-y: auto; }
  .delivery-overview { overflow: visible; padding: .85rem; border: 0; }
  .delivery-payload { padding: .85rem; border-top: 1px solid var(--neutral-200); }
  .delivery-json { flex: none; max-height: 55dvh; min-height: 160px; }
  .kv { grid-template-columns: minmax(75px, 30%) minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
