:root {
  /* ====== Базовая палитра ====== */
  --bg-app: #eef2f9;
  --bg-panel: #ffffff;
  --bg-elevated: #ffffff;
  --bg-soft: #f4f7fc;
  --bg-soft-strong: #eaf0fa;

  --border: #e3e9f4;
  --border-strong: #cfdaed;
  --border-focus: #2563eb;

  --text-primary: #0f1c34;
  --text-secondary: #51607c;
  --text-tertiary: #8a97b1;
  --text-inverse: #ffffff;

  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-active: #1e40af;
  --accent-soft: #e3edff;
  --accent-soft-border: #c4d8ff;
  --accent-glow: rgba(37, 99, 235, 0.18);

  --danger: #dc2626;
  --success: #16a34a;
  --warning: #d97706;

  --shadow-sm: 0 1px 2px rgba(15, 28, 52, 0.05);
  --shadow-md: 0 4px 16px rgba(15, 28, 52, 0.06), 0 1px 2px rgba(15, 28, 52, 0.04);
  --shadow-lg: 0 16px 48px rgba(15, 28, 52, 0.12);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;

  --sidebar-width: 360px;
  --sidebar-width-collapsed: 0px;

  --font: "Proba Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
  background: var(--bg-app);
  color: var(--text-primary);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 14px;
}

button {
  font-family: inherit;
  cursor: pointer;
}

input,
select,
button {
  font-family: inherit;
  color: inherit;
}

/* =================== LAYOUT =================== */
.app {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  background: var(--bg-app);
  transition: grid-template-columns 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.app.is-collapsed {
  grid-template-columns: var(--sidebar-width-collapsed) 1fr;
}

/* =================== SIDEBAR =================== */
.sidebar {
  display: flex;
  flex-direction: column;
  background: var(--bg-panel);
  border-right: 1px solid var(--border);
  min-height: 0;
  overflow: hidden;
  box-shadow: 1px 0 0 rgba(15, 28, 52, 0.02);
}

.sidebar__header {
  padding: 22px 22px 18px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff 0%, #fafcff 100%);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand__mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
  box-shadow: 0 6px 14px var(--accent-glow), inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.brand__mark img {
  width: 78%;
  height: 78%;
  object-fit: contain;
}

.brand__text h1 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.brand__text p {
  margin: 2px 0 0;
  font-size: 11.5px;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
}

.sidebar__scroll {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

.sidebar__scroll::-webkit-scrollbar {
  width: 8px;
}
.sidebar__scroll::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 8px;
  border: 2px solid transparent;
  background-clip: content-box;
}
.sidebar__scroll::-webkit-scrollbar-thumb:hover {
  background: #b1c0db;
  background-clip: content-box;
}

.sidebar__footer {
  padding: 14px 16px 16px;
  display: flex;
  gap: 8px;
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
}

/* =================== PANELS =================== */
.panel {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.panel:hover {
  border-color: var(--border-strong);
}

.panel--top {
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.panel--scenarios {
  background: linear-gradient(135deg, #f8fbff 0%, #eef5ff 100%);
  border-color: #d6e3f8;
}

.panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.panel__title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin: 0;
}

/* =================== STATUS LINE =================== */
.status-line {
  margin: 0;
  font-size: 12px;
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-line::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-tertiary);
  flex-shrink: 0;
}

.status-line[data-status="loading"]::before {
  background: var(--warning);
  animation: pulse 1s ease-in-out infinite;
}

.status-line[data-status="ok"]::before {
  background: var(--success);
}

.status-line[data-status="error"]::before {
  background: var(--danger);
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.field span {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
}

.field input,
input[type="url"],
input[type="text"] {
  height: 32px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-soft);
  font-size: 12.5px;
  color: var(--text-primary);
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  outline: none;
  width: 100%;
}

.field input:focus,
input[type="url"]:focus,
input[type="text"]:focus {
  border-color: var(--border-focus);
  background: #fff;
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* =================== BUTTONS =================== */
.btn {
  flex: 1;
  height: 34px;
  padding: 0 12px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-size: 12.5px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease,
    box-shadow 0.15s ease, transform 0.05s ease;
}

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

.btn--primary {
  background: var(--accent);
  color: var(--text-inverse);
  box-shadow: 0 1px 2px rgba(37, 99, 235, 0.25), 0 4px 12px rgba(37, 99, 235, 0.18);
}

.btn--primary:hover {
  background: var(--accent-hover);
}

.btn--ghost {
  background: var(--bg-panel);
  color: var(--text-secondary);
  border-color: var(--border);
}

.btn--ghost:hover {
  background: var(--bg-soft);
  border-color: var(--border-strong);
  color: var(--text-primary);
}

.icon-btn {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  border: 1px solid var(--border);
  background: var(--bg-panel);
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.icon-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.icon-btn.is-loading svg {
  animation: spin 0.8s linear infinite;
}

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

.link-btn {
  background: none;
  border: none;
  color: var(--text-tertiary);
  font-size: 11px;
  padding: 0;
  text-decoration: underline;
  text-decoration-color: transparent;
  transition: color 0.15s ease;
}

.link-btn:hover {
  color: var(--accent);
  text-decoration-color: var(--accent);
}

.badge {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid var(--accent-soft-border);
  padding: 3px 8px;
  border-radius: 999px;
  letter-spacing: 0.01em;
}

/* =================== SEGMENTED =================== */
.segmented {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 2px;
  padding: 3px;
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.segmented__btn {
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 500;
  padding: 7px 10px;
  border-radius: 7px;
  transition: all 0.15s ease;
}

.segmented__btn:hover {
  color: var(--text-primary);
}

.segmented__btn.is-active {
  background: var(--bg-panel);
  color: var(--accent);
  font-weight: 600;
  box-shadow: var(--shadow-sm), 0 0 0 1px rgba(37, 99, 235, 0.12);
}

/* =================== CHIPS (тип объекта) =================== */
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-panel);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.chip:hover {
  border-color: var(--accent-soft-border);
  color: var(--text-primary);
}

.chip__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
}

.chip.is-active {
  background: var(--accent-soft);
  border-color: var(--accent-soft-border);
  color: var(--accent);
  font-weight: 600;
}

.chip.is-active .chip__dot {
  background: var(--accent);
  opacity: 1;
}

/* =================== QUICK MARKET SCENARIOS =================== */
.quick-presets {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}

.quick-preset {
  min-height: 44px;
  padding: 8px 10px 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.86);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.quick-preset:hover {
  border-color: var(--accent-soft-border);
  background: #fff;
}

.quick-preset.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 3px 0 0 var(--accent);
}

.quick-preset__title {
  color: var(--text-primary);
  font-size: 12.5px;
  font-weight: 650;
}

.quick-preset__meta {
  color: var(--text-tertiary);
  font-size: 10.5px;
  white-space: nowrap;
}

.quick-preset.is-active .quick-preset__meta {
  color: var(--accent);
}

/* =================== RADIO CARDS (метрика) =================== */
.radio-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.radio-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 9px 11px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-panel);
  cursor: pointer;
  transition: all 0.15s ease;
}

.radio-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.radio-card__title {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
}

.radio-card__hint {
  font-size: 10.5px;
  color: var(--text-tertiary);
  letter-spacing: 0.01em;
}

.radio-card:hover {
  border-color: var(--accent-soft-border);
  background: var(--bg-soft);
}

.radio-card.is-active {
  background: var(--accent-soft);
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-glow);
}

.radio-card.is-active .radio-card__title {
  color: var(--accent);
}

.radio-card.is-active .radio-card__hint {
  color: var(--accent-hover);
  opacity: 0.8;
}

/* =================== RANGE (single) =================== */
.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--border-strong);
  border-radius: 999px;
  outline: none;
  margin: 4px 0;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px var(--accent), 0 2px 6px var(--accent-glow);
  cursor: pointer;
  transition: transform 0.1s ease;
}

.slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.slider::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px var(--accent);
  cursor: pointer;
}

.range-hint {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-tertiary);
}

/* =================== RANGE DUAL =================== */
.range-dual {
  position: relative;
  height: 28px;
  margin: 2px 0;
}

.range-dual__track {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--border-strong);
  border-radius: 999px;
  transform: translateY(-50%);
}

.range-dual__fill {
  position: absolute;
  top: 50%;
  height: 4px;
  background: linear-gradient(90deg, var(--accent) 0%, #4f8cff 100%);
  border-radius: 999px;
  transform: translateY(-50%);
  pointer-events: none;
}

.range-dual input[type="range"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 28px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  pointer-events: none;
  outline: none;
}

.range-dual input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  box-shadow: 0 1px 4px rgba(15, 28, 52, 0.18), 0 0 0 1px rgba(15, 28, 52, 0.04);
  cursor: grab;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.range-dual input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.12);
  box-shadow: 0 2px 8px var(--accent-glow), 0 0 0 4px var(--accent-glow);
}

.range-dual input[type="range"]::-webkit-slider-thumb:active {
  cursor: grabbing;
}

.range-dual input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  cursor: grab;
}

.range-readout {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
}

.range-readout .muted {
  color: var(--text-tertiary);
  letter-spacing: 0.2em;
}

/* =================== TOP LIST =================== */
.top-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  counter-reset: top;
}

.top-list__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 0.15s ease;
  counter-increment: top;
}

.top-list__item:hover {
  background: var(--bg-soft);
}

.top-list__item.is-active {
  background: var(--accent-soft);
}

.top-list__rank {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  background: var(--bg-soft-strong);
  color: var(--text-secondary);
  flex-shrink: 0;
}

.top-list__item:nth-child(1) .top-list__rank {
  background: linear-gradient(135deg, #f97316 0%, #dc2626 100%);
  color: #fff;
  box-shadow: 0 2px 6px rgba(220, 38, 38, 0.3);
}
.top-list__item:nth-child(2) .top-list__rank {
  background: linear-gradient(135deg, #fb923c 0%, #f97316 100%);
  color: #fff;
}
.top-list__item:nth-child(3) .top-list__rank {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: #fff;
}

.top-list__main {
  flex: 1;
  min-width: 0;
}

.top-list__name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-list__sub {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 1px;
}

.top-list__value {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.top-list__empty {
  padding: 8px;
  font-size: 12px;
  color: var(--text-tertiary);
  text-align: center;
  font-style: italic;
}

/* =================== MAP AREA =================== */
.map-area {
  position: relative;
  min-width: 0;
  height: 100vh;
  background: #dde5f0;
}

.map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.map-overlay {
  position: absolute;
  z-index: 10;
  pointer-events: none;
}

.map-overlay > * {
  pointer-events: auto;
}

.map-overlay--top {
  top: 16px;
  left: 16px;
}

.map-overlay--bottom {
  bottom: 16px;
  right: 16px;
}

/* Stat card */
.stat-card {
  display: flex;
  align-items: stretch;
  gap: 0;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  border: 1px solid rgba(227, 233, 244, 0.8);
  border-radius: var(--radius-lg);
  padding: 10px 6px;
  box-shadow: var(--shadow-md);
  min-width: 280px;
}

.stat-card__item {
  display: flex;
  flex-direction: column;
  padding: 4px 14px;
  min-width: 80px;
}

.stat-card__label {
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
}

.stat-card__value {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
  margin-top: 1px;
  letter-spacing: -0.01em;
}

.stat-card__value--accent {
  color: #c2410c;
}

.stat-card__divider {
  width: 1px;
  background: var(--border);
}

/* Legend */
.legend {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(227, 233, 244, 0.8);
  border-radius: 999px;
  padding: 8px 14px;
  box-shadow: var(--shadow-md);
}

.legend__label {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
}

.legend__bar {
  width: 140px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(59, 130, 246, 0.1) 0%,
    rgba(56, 189, 248, 0.55) 35%,
    rgba(244, 114, 182, 0.75) 70%,
    rgba(239, 68, 68, 0.95) 100%
  );
  box-shadow: inset 0 0 0 1px rgba(15, 28, 52, 0.08);
}

/* Sidebar toggle */
.sidebar-toggle {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(227, 233, 244, 0.8);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: all 0.2s ease;
  z-index: 20;
}

.sidebar-toggle:hover {
  color: var(--accent);
  border-color: var(--accent-soft-border);
  background: #fff;
  transform: scale(1.06);
}

.sidebar-toggle svg {
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.app.is-collapsed .sidebar-toggle svg {
  transform: rotate(180deg);
}

/* =================== BALLOON (ymaps) =================== */
.heat-balloon {
  font-family: var(--font);
  min-width: 260px;
  max-width: 360px;
}

.heat-balloon__header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 8px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.heat-balloon__swatch {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  flex-shrink: 0;
}

.heat-balloon__title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.heat-balloon__metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
  margin-bottom: 10px;
}

.heat-balloon__metric {
  display: flex;
  flex-direction: column;
}

.heat-balloon__metric-label {
  font-size: 10.5px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.heat-balloon__metric-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
}

.heat-balloon__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--border);
  padding-top: 8px;
  max-height: 300px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

.heat-balloon__list::-webkit-scrollbar { width: 7px; }
.heat-balloon__list::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 8px;
}

.heat-balloon__details {
  border-top: 1px solid var(--border);
  padding-top: 7px;
}

.heat-balloon__details summary {
  color: var(--accent);
  cursor: pointer;
  font-size: 11.5px;
  font-weight: 600;
  list-style-position: inside;
  user-select: none;
}

.heat-balloon__details .heat-balloon__list {
  border-top: 0;
  margin-top: 5px;
}

.heat-balloon__more {
  color: var(--text-tertiary);
  font-size: 11px;
  padding-top: 6px;
}

.heat-balloon__list li {
  font-size: 12px;
  color: var(--text-secondary);
  padding: 4px 0;
  display: flex;
  gap: 6px;
  align-items: baseline;
  border-bottom: 1px dashed var(--border);
}

.heat-balloon__list li:last-child {
  border-bottom: none;
}

.heat-balloon__list a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.heat-balloon__list a:hover {
  text-decoration: underline;
}

.heat-balloon__price {
  margin-left: auto;
  color: var(--text-primary);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* =================== SYNC BUTTON =================== */
.btn--sync {
  width: 100%;
  margin-top: 2px;
  height: 36px;
}

.btn--sync.is-loading svg {
  animation: spin 0.8s linear infinite;
}

.btn--sync.is-loading > span::after {
  content: " · загрузка…";
  opacity: 0.8;
}

/* =================== SWITCH (toggle) =================== */
.switch-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  background: var(--bg-soft);
  border: 1px solid var(--border);
  transition: all 0.15s ease;
  margin-top: 2px;
}

.switch-row:hover {
  border-color: var(--accent-soft-border);
  background: var(--accent-soft);
}

.switch {
  position: relative;
  display: inline-block;
  flex-shrink: 0;
  margin-top: 2px;
}

.switch input {
  position: absolute;
  opacity: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}

.switch__track {
  display: block;
  width: 34px;
  height: 20px;
  background: var(--border-strong);
  border-radius: 999px;
  transition: background 0.18s ease;
  position: relative;
}

.switch__thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(15, 28, 52, 0.2);
  transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}

.switch input:checked + .switch__track {
  background: var(--accent);
}

.switch input:checked + .switch__track .switch__thumb {
  transform: translateX(14px);
}

.switch input:focus-visible + .switch__track {
  box-shadow: 0 0 0 3px var(--accent-glow);
}

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

.switch__title {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
}

.switch__hint {
  font-size: 11px;
  color: var(--text-tertiary);
}

/* =================== BADGES (offer/signal kinds) =================== */
.badge-kind {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  white-space: nowrap;
}

.badge-kind--offer {
  background: #eef2f9;
  color: #51607c;
}

.badge-kind--signal {
  background: #fef3c7;
  color: #92400e;
}

.badge-kind--signal.is-new_object  { background: #dcfce7; color: #166534; }
.badge-kind--signal.is-new_block   { background: #dbeafe; color: #1e40af; }
.badge-kind--signal.is-new_deal_type { background: #fae8ff; color: #86198f; }

.badge-kind__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

/* =================== MARKER CHIPS — colored variants =================== */
.chip[data-marker="new_object"]   .chip__dot { background: #16a34a; }
.chip[data-marker="new_block"]    .chip__dot { background: #2563eb; }
.chip[data-marker="new_deal_type"] .chip__dot { background: #c026d3; }
.chip[data-marker="new_object"].is-active   { background: #dcfce7; border-color: #86efac; color: #166534; }
.chip[data-marker="new_block"].is-active    { background: #dbeafe; border-color: #93c5fd; color: #1e40af; }
.chip[data-marker="new_deal_type"].is-active { background: #fae8ff; border-color: #f0abfc; color: #86198f; }

/* =================== HINT LINE =================== */
.hint-line {
  margin: 0;
  font-size: 11px;
  color: var(--text-tertiary);
  line-height: 1.5;
}
.hint-line code {
  background: var(--bg-soft-strong);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 10.5px;
  color: var(--text-secondary);
}

/* =================== CHIP GROUP EMPTY =================== */
.chip-group__empty {
  font-size: 12px;
  color: var(--text-tertiary);
  font-style: italic;
  padding: 4px 2px;
}

/* =================== SEGMENTED COUNT =================== */
.segmented__btn .seg-count {
  display: inline-block;
  margin-left: 5px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(15, 28, 52, 0.08);
  font-size: 10.5px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text-secondary);
}

.segmented__btn.is-active .seg-count {
  background: rgba(37, 99, 235, 0.14);
  color: var(--accent);
}

.chip__count {
  margin-left: 4px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(15, 28, 52, 0.06);
  font-size: 10.5px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: inherit;
  opacity: 0.7;
}

.chip.is-active .chip__count {
  background: rgba(255, 255, 255, 0.4);
  opacity: 1;
}

/* =================== PERIOD (date range) =================== */
.range-dual-period {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.range-dual-period input[type="date"] {
  height: 32px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-soft);
  font-size: 12.5px;
  color: var(--text-primary);
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.range-dual-period input[type="date"]:focus {
  border-color: var(--border-focus);
  background: #fff;
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* =================== AI TOGGLE BUTTON (top-right) =================== */
.ai-spark {
  background: linear-gradient(135deg, #2563eb 0%, #8b5cf6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
  flex-shrink: 0;
  display: inline-block;
}

.btn--sync[disabled] {
  opacity: 0.7;
  cursor: wait;
}

.btn--sync[disabled] svg {
  animation: spin 1s linear infinite;
}

.ai-toggle {
  position: absolute;
  bottom: 16px;
  right: 16px;
  z-index: 20;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(227, 233, 244, 0.8);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: all 0.2s ease;
}

.ai-toggle:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: scale(1.06);
  box-shadow: 0 6px 20px var(--accent-glow);
}

.ai-toggle.is-active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.ai-toggle__spark {
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  background: linear-gradient(135deg, #2563eb 0%, #8b5cf6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transition: color 0.2s ease;
}

.ai-toggle:hover .ai-toggle__spark,
.ai-toggle.is-active .ai-toggle__spark {
  background: none;
  -webkit-text-fill-color: #fff;
  color: #fff;
}

.ai-toggle__pulse {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  opacity: 0;
  pointer-events: none;
}

.ai-toggle.is-pulsing .ai-toggle__pulse {
  animation: ai-pulse 1.6s ease-out infinite;
}

@keyframes ai-pulse {
  0% { opacity: 0.7; transform: scale(0.95); }
  100% { opacity: 0; transform: scale(1.35); }
}

/* =================== AI DRAWER (right) =================== */
.ai-drawer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 420px;
  max-width: 92vw;
  background: var(--bg-panel);
  border-left: 1px solid var(--border);
  box-shadow: -16px 0 48px rgba(15, 28, 52, 0.08);
  z-index: 30;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  visibility: hidden;
}

.ai-drawer.is-open {
  transform: translateX(0);
  visibility: visible;
}

.ai-drawer[aria-hidden="false"] {
  transform: translateX(0);
  visibility: visible;
}

.ai-drawer__header {
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff 0%, #f6faff 100%);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.ai-drawer__title {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  flex: 1;
}

.ai-drawer__title h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.ai-drawer__title p {
  margin: 3px 0 0;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.ai-drawer__title #ai-period-summary {
  color: var(--accent);
  font-weight: 600;
}

.ai-drawer__close {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-tertiary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.ai-drawer__close:hover {
  background: var(--bg-soft);
  color: var(--text-primary);
  border-color: var(--border);
}

.switch-row--compact {
  padding: 6px 10px;
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.switch-row--compact:hover {
  background: var(--accent-soft);
  border-color: var(--accent-soft-border);
}

.ai-drawer__body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 16px 20px 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

.ai-drawer__body::-webkit-scrollbar { width: 8px; }
.ai-drawer__body::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 8px;
  border: 2px solid transparent;
  background-clip: content-box;
}

/* =================== AI EMPTY STATE =================== */
.ai-empty {
  text-align: center;
  padding: 32px 12px 24px;
  color: var(--text-secondary);
}

.ai-empty__icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  margin: 0 auto 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-soft) 0%, #f3e8ff 100%);
  color: var(--accent);
  border: 1px solid var(--accent-soft-border);
  box-shadow: 0 4px 14px var(--accent-glow);
}

.ai-empty h3 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.ai-empty p {
  margin: 0 auto 16px;
  font-size: 12.5px;
  line-height: 1.5;
  max-width: 280px;
  color: var(--text-secondary);
}

.ai-empty__hints {
  text-align: left;
  list-style: none;
  padding: 0;
  margin: 16px auto 0;
  max-width: 280px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ai-empty__hints li {
  font-size: 12px;
  color: var(--text-secondary);
  padding: 8px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

/* =================== AI OUTPUT (внутри drawer) =================== */
.ai-out {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ai-out__stats {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px;
}

.ai-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}

.ai-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 4px 4px;
  border-radius: 6px;
}

.ai-stat__label {
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 500;
}

.ai-stat__value {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
  line-height: 1.25;
}

.ai-stat__value--accent { color: var(--accent); }
.ai-stat__value--hot { color: #c2410c; }
.ai-stat__delta {
  font-size: 10.5px;
  font-weight: 600;
  margin-top: 1px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}
.ai-stat__delta--up { color: var(--success); }
.ai-stat__delta--down { color: var(--danger); }
.ai-stat__delta--flat { color: var(--text-tertiary); }

/* =================== AI CHARTS (Yandex DataLens style) =================== */
.ai-chart-card {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px 8px;
}

.ai-chart-card__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 6px;
}

.ai-chart-card__title {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.01em;
}

.ai-chart-card__legend {
  display: flex;
  gap: 10px;
  font-size: 10.5px;
  color: var(--text-secondary);
}

.ai-chart-card__legend-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.ai-chart-card__legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

.ai-chart-svg {
  width: 100%;
  height: 130px;
  display: block;
}

.ai-chart-svg--donut {
  height: 160px;
}

.ai-chart-tooltip {
  pointer-events: none;
  position: absolute;
  background: rgba(15, 28, 52, 0.94);
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  line-height: 1.4;
  white-space: nowrap;
  opacity: 0;
  transform: translate(-50%, -100%);
  transition: opacity 0.1s ease;
  z-index: 10;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

.ai-chart-tooltip.is-visible {
  opacity: 1;
}

.ai-chart-tooltip b {
  font-weight: 700;
  color: #fff;
}

.ai-donut-center {
  font-size: 11px;
  fill: var(--text-secondary);
  text-anchor: middle;
  dominant-baseline: middle;
}

.ai-donut-center__value {
  font-size: 18px;
  font-weight: 700;
  fill: var(--text-primary);
}

.ai-donut-legend {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 12px;
  font-size: 11px;
  margin-top: 6px;
}

.ai-donut-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--text-secondary);
}

.ai-donut-legend-item span:last-child {
  margin-left: auto;
  color: var(--text-primary);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.ai-out__text {
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-primary);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 4px 18px 18px;
}

/* Заголовки — с боковой акцентной полосой и эмодзи-иконкой, как секции в DataLens */
.ai-out__text h1,
.ai-out__text h2,
.ai-out__text h3,
.ai-out__text h4 {
  margin: 22px 0 10px;
  font-weight: 700;
  letter-spacing: -0.005em;
  color: var(--text-primary);
  position: relative;
  padding-left: 12px;
  font-size: 14px;
  line-height: 1.3;
}

.ai-out__text h1:first-child,
.ai-out__text h2:first-child,
.ai-out__text h3:first-child,
.ai-out__text h4:first-child {
  margin-top: 14px;
}

.ai-out__text h1::before,
.ai-out__text h2::before,
.ai-out__text h3::before,
.ai-out__text h4::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--accent) 0%, #8b5cf6 100%);
}

.ai-out__text h1 { font-size: 16px; }
.ai-out__text h2 { font-size: 14.5px; }
.ai-out__text h3 { font-size: 13.5px; color: var(--text-secondary); }
.ai-out__text h4 { font-size: 13px; color: var(--text-secondary); }

/* Параграфы — с аккуратными отступами, без бьющих <br> */
.ai-out__text p {
  margin: 0 0 10px;
  padding-left: 12px;
}

.ai-out__text li > p,
.ai-out__text blockquote > p {
  padding-left: 0;
  margin: 0;
}

.ai-out__text p:last-child { margin-bottom: 0; }

.ai-out__text h1 + p,
.ai-out__text h2 + p,
.ai-out__text h3 + p,
.ai-out__text h4 + p {
  margin-top: 6px;
}

/* Списки — с • маркерами в accent цвете */
.ai-out__text ul,
.ai-out__text ol {
  margin: 6px 0 12px;
  padding-left: 28px;
}

.ai-out__text li {
  margin: 5px 0;
  padding-left: 2px;
  position: relative;
}

.ai-out__text ul > li::marker {
  color: var(--accent);
  font-size: 14px;
}

.ai-out__text ol > li::marker {
  color: var(--accent);
  font-weight: 700;
}

/* Жирный — с акцентом, но не режет глаз */
.ai-out__text strong {
  color: var(--accent-hover);
  font-weight: 700;
}

/* Если bold идёт в начале элемента списка — это "название метрики",
   добавим ему тонкий background как tag */
.ai-out__text li > strong:first-child {
  background: var(--accent-soft);
  padding: 1px 6px;
  border-radius: 4px;
  border: 1px solid var(--accent-soft-border);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  margin-right: 4px;
  display: inline-block;
}

.ai-out__text em { color: var(--text-secondary); font-style: italic; }

.ai-out__text code {
  background: var(--bg-soft-strong);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 11.5px;
  color: var(--text-secondary);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.ai-out__text blockquote {
  margin: 8px 0;
  padding: 6px 12px;
  border-left: 3px solid var(--accent-soft-border);
  background: var(--bg-soft);
  color: var(--text-secondary);
  border-radius: 0 6px 6px 0;
}

.ai-out__text hr {
  border: none;
  border-top: 1px dashed var(--border);
  margin: 14px 0;
}

.ai-out__text a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid var(--accent-soft-border);
}

.ai-out__text a:hover {
  border-bottom-color: var(--accent);
}

/* Курсор стриминга */
.ai-out__text .cursor {
  display: inline-block;
  width: 7px;
  height: 15px;
  background: var(--accent);
  vertical-align: text-bottom;
  margin-left: 2px;
  animation: blink 0.9s steps(2) infinite;
}

@keyframes blink {
  to { opacity: 0; }
}

.ai-error {
  color: var(--danger);
  font-size: 12.5px;
  padding: 10px 12px;
  background: #fef2f2;
  border-radius: var(--radius-md);
  border: 1px solid #fecaca;
  line-height: 1.5;
}

/* адаптивность: на мобильных drawer на весь экран */
@media (max-width: 880px) {
  .ai-drawer {
    width: 100vw;
    max-width: 100vw;
  }
  .ai-toggle {
    bottom: 16px;
    right: 16px;
  }
}

/* =================== AI PRESETS (quick prompts) =================== */
.ai-presets {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--border);
}

.ai-presets__title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.ai-presets__list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ai-preset {
  text-align: left;
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px 10px;
  font-size: 12.5px;
  color: var(--text-secondary);
  transition: all 0.15s ease;
  cursor: pointer;
  font-family: inherit;
}

.ai-preset:hover {
  background: var(--accent-soft);
  border-color: var(--accent-soft-border);
  color: var(--accent);
}

.ai-preset.is-active {
  background: var(--accent-soft);
  border-color: var(--accent-soft-border);
  color: var(--accent);
  font-weight: 600;
}

/* =================== AI CHAT INPUT =================== */
.ai-chat {
  margin-top: 14px;
  padding: 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ai-chat__input {
  width: 100%;
  border: none;
  background: transparent;
  resize: none;
  outline: none;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-primary);
  padding: 0;
}

.ai-chat__input::placeholder {
  color: var(--text-tertiary);
}

.ai-chat__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ai-chat__bar-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ai-chat__send {
  padding: 0 14px;
  height: 32px;
  font-size: 12.5px;
  gap: 6px;
}

.ai-chat__send[disabled] {
  opacity: 0.7;
  cursor: wait;
}

.ai-chat__send[disabled] svg {
  animation: spin 1s linear infinite;
}

.ai-chat__hist-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-panel);
  color: var(--text-tertiary);
  font-size: 11px;
  font-weight: 600;
  transition: all 0.15s ease;
}

.ai-chat__hist-btn:hover {
  border-color: var(--accent-soft-border);
  color: var(--accent);
  background: var(--accent-soft);
}

.ai-chat__history {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}

.ai-chat__history-item {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  padding: 6px 8px;
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 11.5px;
  color: var(--text-secondary);
  line-height: 1.4;
  transition: background 0.15s ease;
}

.ai-chat__history-item:hover {
  background: var(--accent-soft);
  color: var(--accent);
}

.ai-chat__history-item svg {
  flex-shrink: 0;
  margin-top: 1px;
}

.ai-chat__history-empty {
  font-size: 11px;
  color: var(--text-tertiary);
  font-style: italic;
  padding: 4px;
}

/* =================== RESPONSIVE =================== */
@media (max-width: 880px) {
/* Proba Pro — фирменный шрифт Ricci (скопирован из legacy-фронта) */
@font-face {
  font-family: "Proba Pro";
  src: url("./fonts/proba_pro_light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Proba Pro";
  src: url("./fonts/proba_pro_regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Proba Pro";
  src: url("./fonts/proba_pro_medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Proba Pro";
  src: url("./fonts/proba_pro_semibold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Proba Pro";
  src: url("./fonts/proba_pro_bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
    --sidebar-width: 320px;
  }

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

  .sidebar {
    position: absolute;
    z-index: 30;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    transform: translateX(-100%);
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .app.is-mobile-open .sidebar {
    transform: translateX(0);
    box-shadow: var(--shadow-lg);
  }

  .sidebar-toggle {
    top: 14px;
    left: 14px;
    right: auto;
  }

  .app.is-collapsed .sidebar-toggle svg {
    transform: none;
  }

  .stat-card {
    min-width: 0;
  }
  .stat-card__item {
    padding: 4px 10px;
    min-width: 64px;
  }
}
