:root {
  color-scheme: dark;
  --bg: #0b1120;
  --bg-2: #111827;
  --bg-3: #151f32;
  --bg-4: #172033;
  --line: rgba(148, 163, 184, 0.16);
  --line-strong: rgba(96, 165, 250, 0.24);
  --text: #e5e7eb;
  --text-strong: #f8fafc;
  --text-soft: #94a3b8;
  --blue: #2563eb;
  --sky: #38bdf8;
  --violet: #6366f1;
  --green: #22c55e;
  --amber: #facc15;
  --rose: #ef4444;
  --teal: #14b8a6;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --sidebar-width: 274px;
  font-family: "Segoe UI Variable Text", "Segoe UI", Inter, Manrope, system-ui, sans-serif;
  background:
    radial-gradient(circle at 15% 20%, rgba(37, 99, 235, 0.20), transparent 24%),
    radial-gradient(circle at 90% 10%, rgba(56, 189, 248, 0.16), transparent 20%),
    linear-gradient(180deg, #09101e 0%, #0b1120 35%, #0b1120 100%);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  background: var(--bg);
}

body {
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

input,
select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 14px;
  background: rgba(8, 15, 28, 0.75);
  color: var(--text-strong);
  padding: 0.9rem 1rem;
  outline: none;
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

input:focus,
select:focus {
  border-color: rgba(56, 189, 248, 0.55);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.12);
}

.ambient {
  position: fixed;
  inset: auto;
  pointer-events: none;
  filter: blur(18px);
  opacity: 0.72;
}

.ambient-a {
  top: -120px;
  left: -80px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.16);
}

.ambient-b {
  top: 120px;
  right: -60px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.10);
}

.ambient-c {
  bottom: -100px;
  right: 20%;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.12);
}

.hidden {
  display: none !important;
}

.boot-card {
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 1rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 16px;
  background: rgba(8, 15, 28, 0.64);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.boot-card h1,
.sidebar__brand h1,
.login-panel__brand h1 {
  margin: 0;
  font-size: 1.15rem;
  color: var(--text-strong);
}

.boot-card p,
.sidebar__brand p,
.login-panel__brand p {
  margin: 0.15rem 0 0;
  font-size: 0.84rem;
  color: var(--text-soft);
}

.boot-card__icon,
.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #eff6ff;
  font-weight: 800;
  letter-spacing: 0.04em;
  background:
    linear-gradient(145deg, rgba(37, 99, 235, 1), rgba(56, 189, 248, 0.88));
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.35);
}

.brand-mark--sidebar {
  width: 48px;
  height: 48px;
  font-size: 1rem;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.login-panel {
  width: min(100%, 540px);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 30px;
  background:
    linear-gradient(180deg, rgba(17, 24, 39, 0.92), rgba(9, 14, 26, 0.94));
  box-shadow: var(--shadow);
  padding: 2rem;
  backdrop-filter: blur(18px);
}

.login-panel__brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 1.6rem;
}

.login-panel h2 {
  margin: 0;
  font-size: 1.9rem;
  color: var(--text-strong);
}

.login-panel__subtitle {
  margin: 0.55rem 0 1.4rem;
  color: var(--text-soft);
  line-height: 1.5;
}

.login-form {
  display: grid;
  gap: 1rem;
}

.login-form label,
.form-grid label {
  display: grid;
  gap: 0.45rem;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.login-form span,
.form-grid span {
  color: var(--text-soft);
}

.primary-button,
.ghost-button,
.sidebar__collapse {
  border: 0;
  border-radius: 16px;
  padding: 0.9rem 1.15rem;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, border-color 180ms ease;
}

.primary-button {
  color: #eff6ff;
  font-weight: 700;
  background: linear-gradient(145deg, #2563eb, #1d4ed8);
  box-shadow: 0 18px 28px rgba(37, 99, 235, 0.22);
}

.primary-button:hover,
.ghost-button:hover,
.nav-item:hover {
  transform: translateY(-1px);
}

.primary-button--compact {
  padding-inline: 1.2rem;
}

.ghost-button {
  color: var(--text-strong);
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.login-panel__note {
  margin-top: 1.2rem;
  padding: 0.95rem 1rem;
  border-radius: 16px;
  background: rgba(37, 99, 235, 0.08);
  color: var(--text-soft);
  line-height: 1.45;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
}

.sidebar {
  position: sticky;
  top: 0;
  min-height: 100vh;
  padding: 1.3rem;
  border-right: 1px solid rgba(148, 163, 184, 0.10);
  background:
    linear-gradient(180deg, rgba(7, 13, 25, 0.98), rgba(10, 16, 30, 0.96));
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.sidebar__brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-bottom: 0.8rem;
}

.sidebar-nav {
  display: grid;
  gap: 0.45rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  padding: 0.95rem 1rem;
  border-radius: 16px;
  border: 1px solid transparent;
  color: var(--text);
  background: transparent;
  text-align: left;
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.20), rgba(37, 99, 235, 0.10));
  border-color: rgba(37, 99, 235, 0.40);
  box-shadow: inset 0 0 0 1px rgba(96, 165, 250, 0.06);
}

.nav-icon {
  width: 1.4rem;
  display: inline-flex;
  justify-content: center;
  color: #cbd5e1;
  opacity: 0.92;
}

.system-card,
.page-card,
.panel,
.settings-card {
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(180deg, rgba(17, 24, 39, 0.92), rgba(10, 15, 28, 0.94));
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.system-card {
  border-radius: 22px;
  padding: 1rem;
  margin-top: auto;
}

.system-card__title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-strong);
  margin-bottom: 0.9rem;
}

.dot {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 999px;
  background: #94a3b8;
  box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.06);
}

.dot--green {
  background: var(--green);
}

.system-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  color: var(--text-soft);
}

.system-row strong {
  color: var(--green);
}

.sidebar__collapse {
  margin-top: 0.1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  background: transparent;
  border: 1px solid rgba(148, 163, 184, 0.10);
}

.content-shell {
  padding: 1.5rem 1.5rem 2rem;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.topbar h1 {
  margin: 0;
  font-size: 2rem;
  line-height: 1.05;
  color: var(--text-strong);
}

.topbar p {
  margin: 0.45rem 0 0;
  color: var(--text-soft);
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.status-pill {
  padding: 0.85rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(15, 23, 42, 0.78);
  color: var(--text-strong);
  font-weight: 700;
}

.status-pill--success {
  color: #86efac;
  border-color: rgba(34, 197, 94, 0.20);
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.03);
}

.status-pill--mode {
  color: #93c5fd;
}

.pages {
  display: grid;
  gap: 1.2rem;
}

.page {
  display: none;
}

.page.active {
  display: grid;
  gap: 1.2rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.stat-card {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.15rem;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(180deg, rgba(17, 24, 39, 0.94), rgba(10, 15, 28, 0.94));
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
}

.stat-card__icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  flex: 0 0 auto;
}

.tone-blue { background: rgba(37, 99, 235, 0.22); color: #93c5fd; }
.tone-amber { background: rgba(250, 204, 21, 0.18); color: #fde68a; }
.tone-violet { background: rgba(99, 102, 241, 0.20); color: #c4b5fd; }
.tone-cyan { background: rgba(56, 189, 248, 0.18); color: #7dd3fc; }
.tone-green { background: rgba(34, 197, 94, 0.18); color: #86efac; }
.tone-teal { background: rgba(20, 184, 166, 0.20); color: #5eead4; }
.tone-rose { background: rgba(239, 68, 68, 0.16); color: #fca5a5; }
.tone-indigo { background: rgba(79, 70, 229, 0.18); color: #a5b4fc; }

.stat-card__label {
  color: var(--text-soft);
  margin: 0 0 0.35rem;
}

.stat-card__value {
  margin: 0;
  font-size: 2rem;
  line-height: 1;
  color: var(--text-strong);
  font-weight: 800;
}

.stat-card__delta {
  margin: 0.55rem 0 0;
  font-size: 0.9rem;
  color: #86efac;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 1rem;
}

.dashboard-grid--bottom {
  grid-template-columns: 1.35fr 1fr;
}

.panel,
.page-card {
  border-radius: 24px;
  padding: 1.2rem;
}

.panel__header,
.page-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.panel__header h2,
.page-card__header h2 {
  margin: 0;
  font-size: 1.16rem;
  color: var(--text-strong);
}

.panel__header p,
.page-card__header p {
  margin: 0.3rem 0 0;
  color: var(--text-soft);
}

.panel-arrow {
  color: var(--text-soft);
  font-size: 1.8rem;
  line-height: 1;
}

.chart-wrap {
  position: relative;
}

.chart-legend {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-bottom: 0.85rem;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.chart-legend span {
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
}

.legend-dot {
  width: 1rem;
  height: 0.2rem;
  border-radius: 999px;
}

.legend-dot--line {
  background: linear-gradient(90deg, #2563eb, #38bdf8);
}

.legend-dot--dashed {
  background: linear-gradient(90deg, #38bdf8, #67e8f9);
  position: relative;
}

.legend-dot--dashed::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, #38bdf8, #38bdf8 8px, transparent 8px, transparent 14px);
  border-radius: 999px;
}

#contact-chart {
  width: 100%;
  min-height: 320px;
  overflow: visible;
}

.chart-grid-line {
  stroke: rgba(148, 163, 184, 0.08);
  stroke-width: 1;
}

.chart-label {
  fill: #94a3b8;
  font-size: 12px;
}

.chart-area {
  fill: url(#chartGradient);
  opacity: 0.95;
}

.chart-line {
  fill: none;
  stroke: url(#lineGradient);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-average {
  fill: none;
  stroke: #38bdf8;
  stroke-width: 3;
  stroke-dasharray: 10 9;
  opacity: 0.88;
}

.chart-point {
  fill: #0b1120;
  stroke: #3b82f6;
  stroke-width: 4;
}

.status-list,
.versions-list,
.mini-list,
.log-list {
  display: grid;
  gap: 0.8rem;
}

.status-item,
.version-item,
.search-item,
.log-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.10);
}

.status-item__left,
.version-item__left,
.search-item__left {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
}

.service-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(37, 99, 235, 0.16);
  color: #93c5fd;
  flex: 0 0 auto;
}

.status-item__name,
.version-item__name,
.search-item__name {
  margin: 0;
  font-weight: 700;
  color: var(--text-strong);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.status-item__note,
.version-item__meta,
.search-item__meta,
.log-item__meta {
  margin: 0.2rem 0 0;
  color: var(--text-soft);
  font-size: 0.9rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
}

.status-badge--ok {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
}

.status-badge--info {
  color: #7dd3fc;
  background: rgba(56, 189, 248, 0.12);
}

.status-badge--violet {
  color: #c4b5fd;
  background: rgba(99, 102, 241, 0.12);
}

.status-dot {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 999px;
  background: var(--green);
}

.table-wrap {
  overflow: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}

.table th,
.table td {
  text-align: left;
  padding: 0.9rem 0.8rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.09);
}

.table th {
  color: var(--text-soft);
  font-weight: 600;
  font-size: 0.9rem;
}

.table td {
  color: var(--text);
}

.table tr:hover td {
  background: rgba(37, 99, 235, 0.04);
}

.message-chip,
.message-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 0.75rem;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.14);
  color: #93c5fd;
  font-size: 0.88rem;
  font-weight: 700;
}

.message-chip--violet,
.message-badge--violet {
  background: rgba(99, 102, 241, 0.14);
  color: #c4b5fd;
}

.message-chip--yellow {
  background: rgba(250, 204, 21, 0.14);
  color: #fde68a;
}

.versions-list {
  gap: 0.9rem;
}

.version-item {
  flex-direction: column;
  align-items: stretch;
}

.version-item__top {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.version-bar {
  width: 100%;
  height: 10px;
  margin-top: 0.75rem;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  overflow: hidden;
}

.version-bar > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #38bdf8);
}

.mini-list {
  gap: 0.75rem;
}

.search-item__count {
  color: var(--text-soft);
  font-size: 0.92rem;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 240px;
  text-align: center;
  border-radius: 20px;
  border: 1px dashed rgba(148, 163, 184, 0.18);
  background: rgba(8, 15, 28, 0.60);
  padding: 2rem;
}

.empty-state h3 {
  margin: 0;
  color: var(--text-strong);
}

.empty-state p {
  margin: 0.6rem 0 0;
  color: var(--text-soft);
  max-width: 48ch;
}

.form-grid,
.settings-grid {
  display: grid;
  gap: 1rem;
}

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

.page-card__actions {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.reports-root {
  display: grid;
  gap: 1rem;
}

.reports-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.report-card {
  padding: 1rem 1.05rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.86), rgba(8, 15, 28, 0.92));
}

.report-card span,
.report-panel__header p,
.report-subpanel h4,
.report-empty {
  color: var(--text-soft);
}

.report-card strong {
  display: block;
  margin-top: 0.45rem;
  font-size: 1.7rem;
  color: var(--text-strong);
}

.report-card em {
  display: block;
  margin-top: 0.25rem;
  font-style: normal;
  color: var(--sky);
}

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

.report-panel {
  border-radius: 22px;
  padding: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(15, 23, 42, 0.72);
}

.report-panel--wide {
  grid-column: 1 / -1;
}

.report-panel__header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.report-panel__header h3 {
  margin: 0;
  font-size: 1.08rem;
  color: var(--text-strong);
}

.report-panel__header strong {
  color: var(--sky);
  font-size: 1.1rem;
}

.report-stack {
  display: grid;
  gap: 0.75rem;
}

.report-stack--timeline {
  gap: 0.65rem;
}

.report-row,
.report-pill,
.report-version,
.report-line,
.report-search {
  display: grid;
  gap: 0.4rem;
}

.report-row,
.report-pill,
.report-line,
.report-search {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.report-row div:first-child,
.report-pill div:first-child,
.report-search div:first-child {
  display: grid;
  gap: 0.16rem;
}

.report-row strong,
.report-pill strong,
.report-search strong,
.report-version__top strong {
  color: var(--text-strong);
}

.report-row span,
.report-pill span,
.report-search span,
.report-version small {
  color: var(--text-soft);
  font-size: 0.9rem;
}

.report-row__bar {
  grid-column: 1 / -1;
  height: 10px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.08);
  overflow: hidden;
}

.report-row__bar > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #38bdf8, #2563eb);
}

.report-row__bar--violet > span {
  background: linear-gradient(90deg, #8b5cf6, #6366f1);
}

.report-pill {
  padding: 0.85rem 0.95rem;
  border-radius: 18px;
  background: rgba(8, 15, 28, 0.54);
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.report-pill--teal {
  background: rgba(8, 15, 28, 0.54);
}

.report-version {
  padding: 0.85rem 0.95rem;
  border-radius: 18px;
  background: rgba(8, 15, 28, 0.54);
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.report-version__top,
.report-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

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

.report-subpanel {
  border-radius: 18px;
  padding: 0.9rem;
  background: rgba(8, 15, 28, 0.46);
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.report-subpanel h4 {
  margin: 0 0 0.8rem;
  color: var(--text-strong);
}

.report-empty {
  margin: 0;
}

.filters-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.8rem;
  margin-bottom: 0.9rem;
}

.filters-bar label {
  display: grid;
  gap: 0.4rem;
  color: var(--text-soft);
  font-size: 0.9rem;
}

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

.settings-card {
  border-radius: 20px;
  padding: 1rem;
}

.settings-card h3 {
  margin: 0 0 0.9rem;
  color: var(--text-strong);
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0;
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  color: var(--text-soft);
}

.settings-row strong {
  color: var(--text-strong);
}

.log-item {
  align-items: flex-start;
}

.log-item__bullet {
  width: 12px;
  height: 12px;
  margin-top: 0.25rem;
  border-radius: 999px;
  background: var(--sky);
  box-shadow: 0 0 0 6px rgba(56, 189, 248, 0.06);
}

.log-item__text {
  flex: 1;
}

@media (max-width: 1280px) {
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .dashboard-grid,
  .dashboard-grid--bottom {
    grid-template-columns: 1fr;
  }
}

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

  .sidebar {
    position: static;
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.10);
  }

  .content-shell {
    padding-top: 1rem;
  }
}

@media (max-width: 760px) {
  .boot-card {
    position: static;
    margin: 1rem;
    width: calc(100% - 2rem);
  }

  .login-screen {
    padding-top: 0;
    min-height: auto;
  }

  .login-panel {
    padding: 1.4rem;
    border-radius: 24px;
  }

  .stats-grid,
  .form-grid,
  .settings-grid,
  .filters-bar {
    grid-template-columns: 1fr;
  }

  .topbar {
    flex-direction: column;
  }

  .topbar__actions {
    justify-content: flex-start;
  }
}

.toast-host {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 60;
  display: grid;
  gap: 0.6rem;
  width: min(100%, 320px);
  pointer-events: none;
}

.toast {
  padding: 0.9rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(8, 15, 28, 0.96);
  color: var(--text-strong);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.24);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast--show {
  opacity: 1;
  transform: translateY(0);
}

.toast--success {
  border-color: rgba(34, 197, 94, 0.24);
}

.toast--warning {
  border-color: rgba(250, 204, 21, 0.24);
}

.toast--error {
  border-color: rgba(239, 68, 68, 0.26);
}

.password-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
}

.ghost-button--small {
  padding: 0.55rem 0.8rem;
  border-radius: 12px;
  font-size: 0.85rem;
}

.row-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.settings-field,
.sequence-field {
  display: grid;
  gap: 0.45rem;
  color: var(--text-soft);
}

.field-hint {
  color: var(--text-soft);
  font-size: 0.82rem;
}

.settings-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.settings-switch input {
  width: auto;
  min-width: 1.2rem;
  min-height: 1.2rem;
}

.sequence-grid {
  display: grid;
  gap: 1rem;
}

.sequence-card {
  padding: 1rem;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(15, 23, 42, 0.72);
}

.sequence-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.sequence-card__header h3 {
  margin: 0;
  color: var(--text-strong);
}

.sequence-card__header p {
  margin: 0.35rem 0 0;
  color: var(--text-soft);
}

.sequence-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text-soft);
}

.sequence-toggle input {
  width: auto;
}

.sequence-versions {
  display: grid;
  gap: 0.9rem;
}

.sequence-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  margin-top: 1rem;
}

.sequence-field textarea {
  resize: vertical;
  min-height: 140px;
}

.prospect-select {
  width: 1.1rem;
  height: 1.1rem;
}

.table td,
.table th {
  vertical-align: top;
}

.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 61;
  background: rgba(2, 6, 23, 0.58);
  backdrop-filter: blur(6px);
}

.detail-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 62;
  width: min(100%, 420px);
  height: 100vh;
  padding: 1.2rem;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 1rem;
  background: linear-gradient(180deg, rgba(10, 15, 28, 0.98), rgba(7, 11, 20, 0.98));
  border-left: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: -18px 0 50px rgba(0, 0, 0, 0.32);
}

.drawer-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.drawer-header h2 {
  margin: 0;
  color: var(--text-strong);
}

.drawer-header p {
  margin: 0.35rem 0 0;
  color: var(--text-soft);
}

.drawer-body {
  overflow: auto;
}

.drawer-grid {
  display: grid;
  gap: 0.8rem;
}

.drawer-field {
  display: grid;
  gap: 0.25rem;
  padding: 0.85rem 0.95rem;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.76);
}

.drawer-field span {
  color: var(--text-soft);
  font-size: 0.85rem;
}

.drawer-field strong {
  color: var(--text-strong);
  font-weight: 600;
}

.drawer-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.65rem;
}

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

  .filters-bar {
    grid-template-columns: 1fr;
  }

  .detail-drawer {
    width: 100%;
  }
}
