:root {
  --bg: #1a1a2e;
  --surface: #16213e;
  --accent: #0f3460;
  --text: #e8e8e8;
  --text-muted: #a0a0a0;
  --border: #2a2a4a;
  --header-h: 52px;
  --nav-h: 64px;
  --nav-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
}

#root {
  min-height: 100vh;
  display: flex;
  align-items: stretch;
  justify-content: center;
}

/* Locked screen for unauthorized / unregistered users */
.locked-screen {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  padding: 20px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
}

.locked-screen__card {
  width: 100%;
  padding: 24px 20px 22px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--nav-shadow);
  text-align: center;
}

.locked-screen__icon {
  font-size: 40px;
  margin-bottom: 14px;
}

.locked-screen__title {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 700;
}

.locked-screen__subtitle {
  margin: 0 0 6px;
  font-size: 14px;
  color: var(--text-muted);
}

.locked-screen__text {
  margin: 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--text);
}

.app-shell {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  overflow-x: hidden;
}

.header {
  flex-shrink: 0;
  min-height: var(--header-h);
  height: var(--header-h);
  padding: 12px 16px;
  padding-top: calc(12px + env(safe-area-inset-top, 0px));
  display: flex;
  align-items: center;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.header__title {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
}

.content {
  flex: 1;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 20px 20px 100px;
  -webkit-overflow-scrolling: touch;
}

.screen {
  display: none;
  min-height: 100%;
}

.screen[aria-hidden="false"] {
  display: block;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%);
  width: 90%;
  max-width: 420px;
  height: var(--nav-h);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0 12px;
  background: var(--surface);
  border-radius: 24px;
  box-shadow: var(--nav-shadow);
  border: 1px solid var(--border);
  z-index: 10;
}

.bottom-nav__btn {
  flex: 1;
  min-width: 0;
  margin: 0 4px;
  border: none;
  border-radius: 14px;
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  padding: 10px 6px;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}

.bottom-nav__btn:hover {
  color: var(--text);
  background: var(--accent);
}

.bottom-nav__btn.active {
  color: var(--text);
  font-weight: 600;
  background: var(--accent);
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 12px;
  cursor: pointer;
}

.card:last-child {
  margin-bottom: 0;
}

.card__title {
  margin: 0 0 4px 0;
  font-size: 1rem;
  font-weight: 600;
}

.card__meta {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.form-group {
  margin-bottom: 16px;
}

.form-group__label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.form-group input[type="text"],
.form-group input[type="date"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 1rem;
}

.form-group input::placeholder {
  color: var(--text-muted);
}

/* Список модулей с секциями и метками */
.module-list__section {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-top: 14px;
  margin-bottom: 6px;
  padding-bottom: 4px;
}
.module-list__section:first-child {
  margin-top: 0;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.checkbox-row:last-child {
  border-bottom: none;
}

.checkbox-row input {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  accent-color: var(--accent);
}

.checkbox-row__label {
  flex: 1;
  min-width: 0;
  cursor: pointer;
  font-size: 0.95rem;
}

.checkbox-row label {
  flex: 1;
  min-width: 0;
  cursor: pointer;
  font-size: 0.95rem;
}

.module-badge {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}
.module-badge--vk {
  background: rgba(0, 119, 255, 0.2);
  color: #5ba3ff;
}
.module-badge--ml {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.checkbox-row_disabled {
  opacity: 0.6;
}

.btn {
  display: inline-block;
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--accent);
  color: var(--text);
  width: 100%;
  margin-top: 8px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.empty-state {
  text-align: center;
  padding: 32px 16px;
  color: var(--text-muted);
}

.empty-state__text {
  margin-bottom: 16px;
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  margin-left: 8px;
}

.status-badge_created { background: var(--border); color: var(--text-muted); }
.status-badge_queued { background: #3d3d5c; color: #b8b8ff; }
.status-badge_running { background: #2d4a2d; color: #90ee90; }
.status-badge_done { background: #2d4a2d; color: #90ee90; }
.status-badge_error { background: #4a2d2d; color: #ffb0b0; }

.message {
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.message_error {
  background: #4a2d2d;
  color: #ffb0b0;
}

.message_success {
  background: #2d4a2d;
  color: #90ee90;
}

/* Wizard (config steps) */
.wizard {
  padding: 18px 16px 14px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  min-height: 320px;
  overflow-x: hidden;
}

.wizard-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}

.wizard-step-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
}

.wizard-step-progress {
  font-size: 12px;
  color: var(--text-muted);
}

.wizard-progress-dots {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.wizard-progress-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.2s;
}

.wizard-progress-dot--filled,
.wizard-progress-dot--current {
  background: var(--accent);
}

.wizard-progress-dot--current {
  width: 8px;
  height: 8px;
  margin: -1px 0 0 -1px;
}

.wizard-body {
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  margin-bottom: 16px;
  font-size: 14px;
}

/* Скрыть полосу прокрутки на шаге «Найти по адресу» */
.wizard-body.wizard-body--no-scrollbar {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.wizard-body.wizard-body--no-scrollbar::-webkit-scrollbar {
  display: none;
}

.wizard-field-group {
  margin-bottom: 14px;
}

.wizard-label {
  display: block;
  font-size: 13px;
  margin-bottom: 6px;
  color: var(--text-muted);
}

.wizard-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wizard-option {
  position: relative;
  cursor: pointer;
}

.wizard-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.wizard-option__card {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  transition: background 0.15s, border-color 0.15s;
}

.wizard-option:hover .wizard-option__card {
  border-color: var(--accent);
}

.wizard-option input[type="radio"]:checked + .wizard-option__card {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.3);
}

.wizard-option__title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

/* Шаг 5: переключатель вида Сводка / JSON */
.summary-view-switcher {
  display: flex;
  gap: 0;
  margin-bottom: 14px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 3px;
}

.summary-view-btn {
  flex: 1;
  padding: 10px 14px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.summary-view-btn:hover {
  color: var(--text);
}

.summary-view-btn--active {
  background: var(--accent);
  color: #fff;
}

.summary-view-panel {
  transition: opacity 0.2s ease;
}

.summary-view-panel--hidden {
  display: none;
}

.summary-json {
  margin: 0;
  padding: 14px;
  max-height: 50vh;
  overflow: auto;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 12px;
  line-height: 1.4;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-all;
}

.wizard-summary {
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
}

.wizard-summary-row {
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
}

.wizard-summary-row:last-child {
  border-bottom: none;
}

.wizard-summary-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.wizard-summary-value {
  font-size: 13px;
  color: var(--text);
}

.wizard-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.wizard-footer__spacer {
  flex: 1;
}

.wizard-btn {
  min-height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.wizard-btn--primary {
  background: var(--accent);
  color: var(--text);
}

.wizard-btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.wizard-btn--ghost:hover {
  background: var(--border);
}

.wizard-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.wizard-selected-badge {
  display: inline-block;
  margin-top: 8px;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 12px;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--border);
}

.wizard-days-count {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Date row: text input + calendar toggle (step: dates) */
.date-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.wizard-date-input {
  flex: 1;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}

.wizard-date-input::placeholder {
  color: var(--text-muted);
}

.wizard-number-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  -moz-appearance: textfield;
}

.wizard-number-input::placeholder {
  color: var(--text-muted);
}

.wizard-number-input::-webkit-outer-spin-button,
.wizard-number-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.calendar-toggle-btn {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.12s, border-color 0.12s;
}

.calendar-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent);
}

.calendar-wrap {
  margin-top: 10px;
  transition: opacity 0.2s ease;
}

.calendar-wrap--hidden {
  display: none;
}

/* Inline calendar (step: dates) */
.calendar-inline {
  background: var(--surface);
  border-radius: 12px;
  box-shadow: var(--nav-shadow);
  border: 1px solid var(--border);
  padding: 14px;
  margin-top: 8px;
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.calendar-month-select {
  flex: 1;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='%23a0a0a0'%3E%3Cpath d='M6 8L2 4h8z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}

.calendar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.calendar-nav__btn {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: background 0.12s;
}

.calendar-nav__btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 6px;
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
}

.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.calendar-day {
  min-width: 40px;
  min-height: 40px;
  height: 40px;
  width: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  margin: 0 auto;
}

.calendar-day:hover:not(.calendar-day--past):not(.calendar-day--other) {
  background: rgba(255, 255, 255, 0.08);
}

.calendar-day--selected {
  background: var(--accent);
  color: #fff;
}

.calendar-day--past {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

.calendar-day--other {
  color: var(--text-muted);
  opacity: 0.7;
}

.calendar-reset-btn {
  margin-top: 10px;
  width: 100%;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}

.calendar-reset-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.period-duration-block {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(15, 52, 96, 0.12);
  border: 1px solid var(--border);
  transition: border-color 0.2s, background 0.2s;
}

.period-duration-block--long {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.2);
}

.period-duration-block__header {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}

.period-duration-block__human {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.period-duration-block__months {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.period-duration-block__total {
  font-size: 13px;
  color: var(--text-muted);
}

.period-duration-block__num {
  font-weight: 600;
  color: var(--text);
  transition: transform 0.2s ease;
}

.period-duration-block__num--bump {
  transform: scale(1.08);
}

.wizard-summary-period-human {
  font-weight: 600;
  color: var(--text);
}

.wizard-summary-period-days {
  font-size: 13px;
  color: var(--text-muted);
}

.wizard-body input[type="text"],
.wizard-body input[type="date"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 1rem;
}

.wizard-body input::placeholder {
  color: var(--text-muted);
}

/* Area step: cards or selector + dropdown */
.area-cards-wrap {
  transition: opacity 0.2s ease, max-height 0.3s ease;
}
.area-cards-wrap--collapsed {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  margin: 0;
  padding: 0;
  pointer-events: none;
}
.area-selector-wrap {
  margin-bottom: 4px;
  position: relative;
}
.area-selector-wrap--hidden {
  display: none;
}
.area-selector {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.area-selector:hover {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.12);
}
.area-selector__icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}
.area-selector__icon svg {
  width: 20px;
  height: 20px;
}
.area-selector__label {
  flex: 1;
  min-width: 0;
  font-weight: 500;
}
.area-selector__chevron {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--text-muted);
}
.area-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 10;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--nav-shadow);
  overflow: hidden;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.area-dropdown--hidden {
  display: none;
}
.area-dropdown__item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 16px;
  border: none;
  border-bottom: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  font-size: 15px;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}
.area-dropdown__item:last-child {
  border-bottom: none;
}
.area-dropdown__item:hover {
  background: rgba(255, 255, 255, 0.06);
}
.area-dropdown__item--selected {
  background: rgba(15, 52, 96, 0.2);
  color: var(--text);
}
.area-dropdown__item-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}
.area-dropdown__item-icon svg {
  width: 20px;
  height: 20px;
}
.area-dropdown__item-label {
  flex: 1;
  min-width: 0;
}
.area-dropdown__check {
  flex-shrink: 0;
  color: var(--accent);
  font-weight: 600;
}

/* Area step: cards with icon + description */
.area-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
}

.area-card {
  position: relative;
  cursor: pointer;
  margin: 0;
}

.area-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.area-card__inner {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border-radius: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.area-card:hover .area-card__inner {
  border-color: var(--accent);
}

.area-card input[type="radio"]:checked + .area-card__inner,
.area-card--selected .area-card__inner {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.25);
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.area-card__icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.area-card__icon svg {
  width: 24px;
  height: 24px;
}

.area-card__text {
  flex: 1;
  min-width: 0;
}

.area-card__title {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 2px;
}

.area-card__desc {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
}

/* Area input blocks: appear with animation */
.area-input-block {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.25s ease, margin 0.2s ease;
  margin-top: 0;
}

.area-input-block--visible {
  max-height: 320px;
  opacity: 1;
  margin-top: 16px;
}

.wizard-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 6px 0 0 0;
}

.wizard-geo-btn {
  margin-top: 12px;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.wizard-geo-btn:hover {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.2);
}

.area-file-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  margin: 0 0 4px 0;
}

.area-file-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 14px 0;
}

.file-drop-zone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  padding: 20px 16px;
  border: 2px dashed var(--border);
  border-radius: 14px;
  background: rgba(15, 52, 96, 0.08);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.file-drop-zone:hover {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.12);
}

.file-drop-zone--drag {
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.18);
}

.file-drop-zone--filled {
  border-style: solid;
  border-color: var(--accent);
  background: rgba(15, 52, 96, 0.15);
}

.file-drop-zone input[type="file"] {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.file-drop-zone__icon {
  width: 40px;
  height: 40px;
  margin-bottom: 10px;
  color: var(--accent);
}

.file-drop-zone__icon svg {
  width: 100%;
  height: 100%;
}

.file-drop-zone__text {
  font-size: 14px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.4;
}

.file-drop-zone--filled .file-drop-zone__text {
  display: none;
}

.file-drop-zone__name {
  display: none;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  text-align: center;
  word-break: break-all;
}

.file-drop-zone--filled .file-drop-zone__name {
  display: block;
}

.area-quick-examples {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.area-quick-chip {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.area-quick-chip:hover {
  border-color: var(--accent);
  color: var(--text);
  background: rgba(15, 52, 96, 0.15);
}

/* Модальное окно для уведомлений и ошибок */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.modal-overlay[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
}

.modal {
  width: 100%;
  max-width: 340px;
  padding: 24px 20px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--nav-shadow), 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.modal__title {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
}

.modal__message {
  margin: 0 0 20px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--text-muted);
}

.modal__json {
  margin: 0 0 20px;
  padding: 12px 14px;
  max-height: 60vh;
  overflow: auto;
  border-radius: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 12px;
  line-height: 1.4;
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-all;
}

.modal__btn {
  display: block;
  width: 100%;
  padding: 12px 20px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}

.modal__btn:hover {
  background: #134a7a;
}

.modal__btn:active {
  opacity: 0.9;
}
