:root {
  --bg: #f5f1eb;
  --bg-strong: #efe7dc;
  --panel: rgba(255, 251, 247, 0.96);
  --panel-strong: #fffdfb;
  --ink: #0f4059;
  --ink-soft: #31586f;
  --muted: #6d7e89;
  --line: rgba(15, 64, 89, 0.12);
  --line-strong: rgba(15, 64, 89, 0.22);
  --accent: #ef3d43;
  --accent-deep: #c92933;
  --accent-soft: rgba(239, 61, 67, 0.12);
  --success: #1b7f68;
  --success-soft: rgba(27, 127, 104, 0.12);
  --danger: #a02332;
  --danger-soft: rgba(160, 35, 50, 0.12);
  --shadow: 0 22px 48px rgba(15, 64, 89, 0.08);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
}

body {
  margin: 0;
  font-family: "Avenir Next", "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(239, 61, 67, 0.18), transparent 25%),
    radial-gradient(circle at bottom right, rgba(15, 64, 89, 0.12), transparent 28%),
    linear-gradient(180deg, #faf6f1 0%, var(--bg) 46%, #efe8de 100%);
}

a {
  color: var(--ink);
  text-decoration-color: rgba(15, 64, 89, 0.28);
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-color: var(--accent);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.08;
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(2rem, 3vw, 2.6rem);
}

h3 {
  font-size: 1.08rem;
}

p {
  line-height: 1.6;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.shell {
  display: grid;
  grid-template-columns: minmax(270px, 290px) 1fr;
  min-height: 100vh;
}

.sidebar {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 28px 22px;
  border-right: 1px solid rgba(255, 255, 255, 0.28);
  background:
    linear-gradient(180deg, rgba(10, 49, 69, 0.96) 0%, rgba(12, 63, 88, 0.96) 100%);
  color: #f7f3ef;
  overflow: hidden;
}

.sidebar::before {
  content: "";
  position: absolute;
  inset: auto -42px -58px auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(239, 61, 67, 0.48), rgba(239, 61, 67, 0));
  pointer-events: none;
}

.brand {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
}

.brand-surface {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 92px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 24%),
    linear-gradient(135deg, #ef3d43 0%, #d92d3d 55%, #b92334 100%);
  box-shadow: 0 18px 40px rgba(6, 26, 37, 0.28);
}

.brand-surface::after {
  content: "";
  position: absolute;
  right: -34px;
  bottom: -42px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.14);
  color: #fffdfc;
  font-size: 1.25rem;
  font-weight: 800;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.brand-mark-logo {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  font-size: 1.7rem;
}

.brand-logo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  max-width: 210px;
  height: auto;
}

.brand-logo-white {
  filter: drop-shadow(0 10px 24px rgba(6, 26, 37, 0.2));
}

.nav {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.nav a {
  display: flex;
  align-items: center;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: 14px;
  color: rgba(247, 243, 239, 0.88);
  text-decoration: none;
  transition: transform 140ms ease, background-color 140ms ease, border-color 140ms ease;
}

.nav a.active,
.nav a:hover {
  transform: translateX(2px);
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.sidebar-note {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.07);
  color: rgba(247, 243, 239, 0.84);
}

.sidebar-note strong {
  display: block;
  margin-bottom: 6px;
  color: #ffffff;
}

.sidebar-logout {
  width: 100%;
  margin-top: -8px;
}

.main {
  padding: 32px;
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 24px;
}

.page-head p {
  max-width: 48rem;
  margin: 8px 0 0;
}

.page-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-card {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(240px, 0.9fr);
  gap: 18px;
  margin-bottom: 22px;
}

.hero-panel {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: calc(var(--radius) + 6px);
  background:
    linear-gradient(135deg, rgba(15, 64, 89, 0.96), rgba(10, 49, 69, 0.88)),
    linear-gradient(135deg, rgba(239, 61, 67, 0.18), rgba(239, 61, 67, 0));
  color: #fffdfc;
  box-shadow: var(--shadow);
}

.hero-panel::after {
  content: "";
  position: absolute;
  inset: auto -70px -90px auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(239, 61, 67, 0.55), rgba(239, 61, 67, 0));
}

.hero-eyebrow {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 253, 252, 0.8);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-logo {
  position: relative;
  z-index: 1;
  display: block;
  max-width: min(420px, 100%);
  height: auto;
  margin-bottom: 18px;
  filter: drop-shadow(0 16px 28px rgba(6, 26, 37, 0.18));
}

.hero-panel h2 {
  position: relative;
  z-index: 1;
  max-width: 12ch;
  margin-top: 18px;
  font-size: clamp(2.5rem, 5vw, 4rem);
}

.hero-panel p {
  position: relative;
  z-index: 1;
  max-width: 36rem;
  margin: 12px 0 0;
  color: rgba(255, 253, 252, 0.82);
}

.hero-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

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

.grid.tight {
  gap: 14px;
}

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), var(--panel));
  box-shadow: var(--shadow);
  padding: 22px;
}

.card h3 + .muted {
  margin-top: 8px;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 18px;
}

.card-header p {
  margin: 6px 0 0;
}

.metric-card {
  display: grid;
  gap: 10px;
  min-height: 160px;
}

.metric-card .label {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.metric {
  font-size: clamp(2.2rem, 4vw, 3.3rem);
  font-weight: 800;
  letter-spacing: -0.05em;
}

.metric-card .metric-note {
  max-width: 24rem;
  color: var(--muted);
}

.wrap-text {
  overflow-wrap: anywhere;
}

.table-wrap {
  overflow-x: auto;
}

.count-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.count-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(15, 64, 89, 0.08);
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 700;
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead th {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

th,
td {
  padding: 14px 10px;
  border-bottom: 1px solid rgba(15, 64, 89, 0.08);
  text-align: left;
  vertical-align: top;
}

tbody tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover {
  background: rgba(255, 255, 255, 0.56);
}

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

form.stack {
  max-width: 1100px;
}

.section-card {
  display: grid;
  gap: 18px;
}

.section-title {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.section-title p {
  margin: 0;
}

label,
.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--ink-soft);
  font-weight: 700;
}

.field-group {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.62);
}

.field-label {
  color: var(--ink);
}

input,
textarea,
select,
button {
  font: inherit;
}

input,
textarea,
select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid rgba(15, 64, 89, 0.16);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  font-weight: 400;
  transition: border-color 140ms ease, box-shadow 140ms ease, background-color 140ms ease;
}

textarea {
  min-height: 132px;
  resize: vertical;
}

.client-form-grid {
  gap: 14px 18px;
}

.field-span-2 {
  grid-column: 1 / -1;
}

input:focus,
textarea:focus,
select:focus,
button:focus,
a:focus {
  outline: none;
  border-color: rgba(239, 61, 67, 0.6);
  box-shadow: 0 0 0 4px rgba(239, 61, 67, 0.16);
}

button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent) 0%, #ff655f 100%);
  color: #fffaf8;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 140ms ease, filter 140ms ease;
  box-shadow: 0 16px 28px rgba(239, 61, 67, 0.22);
}

button:hover,
.button:hover {
  transform: translateY(-1px);
  filter: saturate(1.05);
}

.button.secondary,
button.secondary {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink);
  box-shadow: none;
}

button.secondary:disabled,
.button.secondary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.button.danger,
button.danger {
  background: linear-gradient(135deg, var(--danger) 0%, #c03e52 100%);
  color: #fffaf8;
  box-shadow: 0 16px 28px rgba(160, 35, 50, 0.22);
}

.button.ghost {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #fffefc;
  box-shadow: none;
}

.inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.inline-actions-clients {
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: 8px;
}

.action-button {
  width: 116px;
  min-width: 116px;
  padding: 11px 18px;
}

.icon-button,
.icon-action {
  width: 42px;
  min-width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 14px;
  box-shadow: none;
}

.icon-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(15, 64, 89, 0.14);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(241, 246, 249, 0.98));
  color: var(--ink);
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background-color 140ms ease, box-shadow 140ms ease;
}

.icon-action:hover {
  transform: translateY(-1px);
  border-color: rgba(15, 64, 89, 0.28);
  filter: none;
}

.icon-action svg {
  width: 17px;
  height: 17px;
}

.icon-edit,
.icon-duplicate,
.icon-run {
  color: #ffffff;
  border-color: rgba(8, 58, 80, 0.12);
  background: linear-gradient(180deg, #0f5c82 0%, #083a50 100%);
  box-shadow: 0 12px 22px rgba(8, 58, 80, 0.18);
}

.icon-delete {
  color: var(--danger);
  border-color: rgba(160, 35, 50, 0.18);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(252, 241, 243, 0.98));
}

.client-directory-sections {
  margin-top: 0;
}

.errors {
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid rgba(160, 35, 50, 0.18);
  border-radius: 16px;
  background: rgba(160, 35, 50, 0.08);
  color: var(--danger);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(15, 64, 89, 0.09);
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 700;
}

.client-status-badge {
  min-width: 88px;
}

.client-status-ACTIVE {
  background: var(--success-soft);
  color: var(--success);
}

.client-status-TESTING {
  background: rgba(221, 177, 46, 0.18);
  color: #8a6300;
}

.client-status-PAUSED {
  background: rgba(239, 61, 67, 0.14);
  color: var(--danger);
}

.client-status-DELETED {
  background: rgba(15, 64, 89, 0.12);
  color: var(--ink-soft);
}

.sender-badge {
  min-width: 110px;
}

.sender-RESEND_DDN {
  background: rgba(15, 64, 89, 0.1);
  color: var(--ink);
}

.sender-GMAIL_JAMIE {
  background: rgba(239, 61, 67, 0.12);
  color: var(--accent-deep);
}

.status-COMPLETED {
  background: var(--success-soft);
  color: var(--success);
}

.status-FAILED {
  background: var(--danger-soft);
  color: var(--danger);
}

.status-CANCELED {
  background: rgba(109, 126, 137, 0.14);
  color: var(--muted);
}

.status-QUEUED,
.status-SEARCHING,
.status-SEARCHED,
.status-DEDUPING,
.status-DEDUPED,
.status-EVALUATING,
.status-EVALUATED,
.status-RENDERING,
.status-RENDERED,
.status-SENDING {
  background: rgba(239, 61, 67, 0.12);
  color: var(--accent-deep);
}

.muted {
  color: var(--muted);
}

.field-help {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.5;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.checkbox-chip,
.checkbox-inline {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.78);
  font-weight: 600;
}

.checkbox-chip input,
.checkbox-inline input {
  width: auto;
  min-height: auto;
  margin: 0;
}

.html-preview {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.9fr) auto;
  gap: 12px;
  align-items: end;
}

.blog-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.blog-editor-toolbar button {
  min-height: 40px;
  padding: 10px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--panel-strong);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
}

.blog-editor-toolbar button:hover {
  border-color: rgba(239, 61, 67, 0.28);
  color: var(--accent-deep);
}

.blog-editor-textarea {
  min-height: 440px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  line-height: 1.55;
}

.deleted-clients-card details {
  display: grid;
  gap: 12px;
}

.deleted-clients-card summary {
  cursor: pointer;
  color: var(--muted);
  font-weight: 700;
  list-style: none;
}

.deleted-clients-card summary::-webkit-details-marker {
  display: none;
}

.deleted-clients-card summary::before {
  content: "+";
  display: inline-block;
  width: 1.25rem;
  color: var(--accent);
  font-weight: 800;
}

.deleted-clients-card details[open] summary::before {
  content: "-";
}

.list {
  display: grid;
  gap: 12px;
}

.list-item {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.62);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 18px;
}

.detail-row {
  display: grid;
  gap: 4px;
}

.detail-row-full {
  grid-column: 1 / -1;
}

.detail-row strong {
  color: var(--ink);
}

.run-log {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.run-log-item {
  display: grid;
  grid-template-columns: 190px 110px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
}

.run-log-time,
.run-log-stage {
  color: var(--muted);
  font-size: 0.9rem;
}

.run-log-stage {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-card {
  width: min(480px, 100%);
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), var(--panel));
  box-shadow: var(--shadow);
}

.login-brand {
  min-height: 84px;
}

.article-title {
  font-weight: 700;
}

.article-meta {
  margin-top: 4px;
}

.article-copy {
  margin-top: 8px;
  color: var(--ink-soft);
  line-height: 1.55;
  white-space: pre-line;
}

.system-log-list {
  display: grid;
  gap: 14px;
}

.system-log-view-toggle {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.system-log-view-toggle .secondary.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.system-log-list-simple {
  gap: 10px;
}

.system-log-list-compact {
  gap: 10px;
}

.system-event-simple-row {
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.78);
}

.system-event-simple-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: baseline;
  color: var(--ink-soft);
  line-height: 1.5;
}

.system-event-simple-line span {
  display: inline-flex;
  align-items: baseline;
}

.system-event-simple-line span:not(:last-child)::after {
  content: "•";
  margin-left: 12px;
  color: var(--line-strong, rgba(15, 64, 89, 0.25));
}

.system-event-card {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.7);
}

.system-event-card-log {
  padding: 20px 22px;
}

.system-event-card-compact {
  padding: 14px 16px;
}

.system-event-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.system-event-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.system-event-time {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
}

.system-event-category {
  background: rgba(15, 64, 89, 0.08);
  color: var(--ink);
}

.system-event-headline {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: baseline;
  margin-bottom: 8px;
}

.system-event-title {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--ink);
}

.system-event-client {
  color: var(--ink-soft);
  font-weight: 700;
}

.system-event-message {
  color: var(--ink-soft);
  line-height: 1.6;
}

.system-event-context {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.system-event-context-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  align-items: baseline;
  color: var(--ink-soft);
}

.system-event-context-label {
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.76rem;
}

.system-event-details {
  margin-top: 12px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.system-event-details-log {
  margin-top: 16px;
}

.system-event-details-heading {
  margin: 0 0 10px;
  color: var(--ink);
  font-weight: 800;
}

.system-event-details summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 700;
  list-style: none;
}

.system-event-details summary::-webkit-details-marker {
  display: none;
}

.system-event-details summary::before {
  content: "+";
  display: inline-block;
  width: 1rem;
  color: var(--accent);
  font-weight: 800;
}

.system-event-details[open] summary::before {
  content: "-";
}

.system-event-metadata {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.system-event-meta-row {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(15, 64, 89, 0.04);
}

.system-event-meta-key {
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.8rem;
}

.system-event-meta-value {
  color: var(--ink-soft);
  line-height: 1.55;
  word-break: break-word;
}

.system-event-raw {
  width: 100%;
  min-height: 180px;
  margin-top: 10px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(15, 64, 89, 0.04);
  color: var(--ink-soft);
  font: inherit;
  line-height: 1.5;
  resize: vertical;
  white-space: pre;
}

pre {
  overflow: auto;
  padding: 16px;
  border-radius: 18px;
  background: #14384d;
  color: #f7f3ef;
}

@media (max-width: 1040px) {
  .shell,
  .hero-card,
  .grid,
  .detail-grid,
  .search-row {
    grid-template-columns: 1fr;
  }

  .sidebar {
    gap: 18px;
  }

  .main {
    padding: 22px;
  }

  .run-log-item {
    grid-template-columns: 1fr;
  }

  .system-event-topline,
  .system-event-headline,
  .system-event-meta-row {
    grid-template-columns: 1fr;
    display: grid;
  }

  .system-event-context-row {
    display: grid;
  }

  .system-log-view-toggle {
    width: 100%;
  }
}

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

  .sidebar {
    padding-bottom: 20px;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  }

  .brand-lockup {
    font-size: 1.7rem;
  }

  .page-head {
    flex-direction: column;
  }

  .hero-panel,
  .card {
    padding: 18px;
  }

  th,
  td {
    padding: 12px 8px;
  }

  .inline-actions-clients {
    flex-wrap: wrap;
  }
}
