/* =========================================================================
   Таможенные органы Республики Беларусь — Личный кабинет клиента
   ========================================================================= */

:root {
  --blue:      #00478f;
  --blue-dark: #003a75;
  --blue-soft: #eaf1f8;
  --ink:       #1a1a1a;
  --ink-2:     #46535f;
  --ink-3:     #77838f;
  --line:      #d8dfe6;
  --line-soft: #e9eef3;
  --bg-soft:   #f4f7fa;

  --ok:    #1c7a45;
  --ok-bg: #eaf6ee;
  --warn:  #9a6100;
  --warn-bg: #fdf4e3;
  --err:   #b3261e;
  --err-bg: #fdecea;
}

* { box-sizing: border-box; }

html { height: 100%; }
html, body { margin: 0; padding: 0; }

body {
  font-family: Arial, 'Helvetica Neue', Helvetica, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg-soft);

  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

#page, .login, .doc-page, .cab-page { flex: 1 0 auto; display: flex; flex-direction: column; }
.ftr { flex: 0 0 auto; margin-top: auto !important; width: 100%; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { margin: 0; font-weight: bold; }
table { border-collapse: collapse; width: 100%; }
.is-hidden { display: none !important; }
.nowrap { white-space: nowrap; }

.wrap {
  max-width: 1840px;
  width: 98%;
  margin: 0 auto;
  padding: 0 12px;
}

/* ================================================================== ШАПКА */
.top {
  background: #171b22;
  color: #aeb7c2;
  font-size: 13px;
}

.top__in {
  display: flex;
  align-items: stretch;
  min-height: 44px;
  flex-wrap: wrap;
}

.top__title {
  display: flex;
  align-items: center;
  padding: 8px 0;
  font-weight: bold;
  color: #fff;
  letter-spacing: .02em;
}

.top__clock {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  padding: 8px 16px;
  color: #c3cbd5;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.top__login {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 18px;
  margin-right: -24px;
  color: #fff;
  font-weight: bold;
}
.top__login:hover { background: #232a35; text-decoration: none; }

.head { border-bottom: 1px solid var(--line); background: #fff; }

.head__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 0;
  flex-wrap: wrap;
}

.logo { display: flex; align-items: center; gap: 14px; }
.logo__img { width: 52px; height: 52px; object-fit: contain; }

.logo__name {
  font-size: 19px;
  font-weight: bold;
  color: var(--blue);
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1.15;
}

.logo__sub { font-size: 12.5px; color: var(--ink-2); }

.head__contacts {
  font-size: 13px;
  color: var(--ink-2);
  text-align: right;
  line-height: 1.6;
}
.head__contacts b { color: var(--ink); font-size: 15px; }

/* ШАПКА: ИНСТРУМЕНТЫ И ЯЗЫКИ */
.header-tools {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

.lang-nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.lang-link {
  background: none;
  border: none;
  color: #00478f;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 0;
  font-family: Arial, sans-serif;
  transition: opacity 0.2s;
}
.lang-link:hover { opacity: 0.75; }
.lang-link.is-active {
  font-weight: bold;
  color: #003a75;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ================================================= БЕГУЩАЯ СТРОКА (TICKER) */
.running-line {
  background: #f0f4f8;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  height: 36px;
  display: flex;
  align-items: center;
}

.running-line__track {
  display: flex;
  white-space: nowrap;
  animation: running-line-move 35s linear infinite;
}

.running-line:hover .running-line__track {
  animation-play-state: paused;
}

.running-line__item {
  display: inline-flex;
  align-items: center;
  padding: 0 40px;
  font-size: 13px;
  color: var(--blue-dark);
  font-weight: 500;
}

@keyframes running-line-move {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* =========================================================== СТРАНИЦА ВХОДА */
.login { background: #fff; padding: 34px 0 46px; }

.login__grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 56px;
  max-width: 1240px;
  margin: 0 auto 44px;
}

.login__l { flex: 1; max-width: 660px; }
.login__r { width: 440px; flex: none; }

.login__l h1 {
  font-size: 26px;
  color: var(--blue);
  line-height: 1.25;
  margin-bottom: 14px;
}
.login__l p { margin: 0 0 16px; color: var(--ink-2); }
.login__l ul { margin: 0 0 20px; padding: 0; list-style: none; }
.login__l li {
  position: relative;
  padding: 0 0 8px 24px;
  color: var(--ink-2);
}
.login__l li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 8px;
  width: 7px;
  height: 7px;
  background: var(--blue);
  border-radius: 50%;
}

/* Панель авторизации / регистрации */
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 50, 100, 0.06);
}

.tabs { display: flex; border-bottom: 1px solid var(--line); }

.tab {
  flex: 1;
  padding: 14px 10px;
  font-family: inherit;
  font-size: 13px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--ink-2);
  background: var(--bg-soft);
  border: 0;
  cursor: pointer;
}
.tab + .tab { border-left: 1px solid var(--line); }
.tab:hover { color: var(--blue); }
.tab.is-active {
  color: var(--blue);
  background: #fff;
  box-shadow: inset 0 3px 0 var(--blue);
}

.panel__hd { padding: 20px 24px 0; }
.panel__hd h3 { font-size: 18px; color: var(--blue); margin-bottom: 6px; }
.panel__hd .sub { font-size: 13px; color: var(--ink-2); }

.frm { padding: 18px 24px 22px; }
.frm__row { margin-bottom: 16px; }

/* ========================================================== ПОЛЯ ВВОДА (INPUTS) */
.frm label {
  display: block;
  font-size: 13.5px;
  font-weight: bold;
  color: var(--ink);
  margin-bottom: 6px;
}

.frm input[type="text"],
.frm input[type="email"],
.frm input[type="password"] {
  display: block;
  width: 100%;
  height: 44px;
  padding: 0 14px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  background: #fff;
  border: 1px solid #b9c4cf;
  border-radius: 6px;
  outline: none;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.frm input[type="text"]:focus,
.frm input[type="email"]:focus,
.frm input[type="password"]:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3.5px rgba(0, 71, 143, 0.14);
}

.frm input::placeholder {
  color: #94a3b8;
  font-size: 13.5px;
}

/* ПОЛЕ ТЕЛЕФОНА */
.phone {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  height: 44px;
  border: 1px solid #b9c4cf;
  border-radius: 6px;
  background: #fff;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.phone:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 3.5px rgba(0, 71, 143, 0.14);
}

.phone__cc {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 100%;
  padding: 0 12px;
  background: var(--bg-soft);
  border: 0;
  border-right: 1px solid #d8dfe6;
  border-radius: 5px 0 0 5px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
  flex: none;
  transition: background 0.15s;
}
.phone__cc:hover { background: #e2e8f0; }

.phone__dial { font-weight: bold; }
.phone__caret { font-size: 10px; color: var(--ink-3); transition: transform 0.15s; }
.phone__cc.is-open .phone__caret { transform: rotate(180deg); }

.phone__flag {
  width: 22px !important;
  height: 16px !important;
  flex: none !important;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
  display: inline-block !important;
}

.phone__flag svg {
  display: block !important;
  width: 22px !important;
  height: 16px !important;
  max-width: 22px !important;
  max-height: 16px !important;
}

.phone input.phone__num {
  flex: 1;
  width: 100%;
  height: 100%;
  padding: 0 14px;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  background: transparent;
  border: 0 !important;
  border-radius: 0 5px 5px 0;
  outline: none !important;
  box-shadow: none !important;
}

/* МЕНЮ ВЫБОРА СТРАНЫ */
.phone__menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  width: 240px;
  z-index: 1000;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 50, 100, 0.18);
  max-height: 220px;
  overflow-y: auto;
}

.phone__menu[hidden] { display: none !important; }

.phone__menu li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13.5px;
  color: var(--ink);
  transition: background 0.15s;
}
.phone__menu li:hover { background: var(--blue-soft); color: var(--blue); }

.phone__menu .flag {
  width: 22px !important;
  height: 16px !important;
  flex: none !important;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
  display: inline-block !important;
}

.phone__menu .flag svg {
  display: block !important;
  width: 22px !important;
  height: 16px !important;
  max-width: 22px !important;
  max-height: 16px !important;
}

.phone__menu .name { flex: 1; font-weight: 500; }
.phone__menu .dial { font-weight: bold; color: var(--ink-2); font-size: 13px; }

/* КНОПКИ И ОШИБКИ */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 44px;
  background: var(--blue);
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: .04em;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s;
}
.btn:hover { background: var(--blue-dark); }

.btn--link {
  background: none;
  border: 0;
  color: var(--blue);
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  padding: 0;
}
.btn--link:hover { text-decoration: underline; }

.frm__opt { margin-bottom: 16px; }
.chk { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.err { color: var(--err); font-size: 13px; margin-bottom: 12px; }

.legal-agree, .consent {
  margin-top: 14px;
  font-size: 12px;
  color: var(--ink-3);
  line-height: 1.5;
}

.frm__links {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line-soft);
}

/* ПОДТВЕРЖДЕНИЕ НОМЕРА ПО SMS */
.sent {
  margin: 0 0 16px;
  padding: 10px 12px;
  background: var(--blue-soft);
  border-left: 3px solid var(--blue);
  border-radius: 0 4px 4px 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-2);
}
.sent b { color: var(--ink); white-space: nowrap; }

.demo-note {
  margin: 0 0 12px;
  padding: 10px 12px;
  background: var(--warn-bg);
  border-left: 3px solid var(--warn);
  border-radius: 0 4px 4px 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--warn);
}
.demo-note b { font-size: 15px; letter-spacing: .08em; }

/* Служебная полоска прототипа — только для стенда, клиенту не показывается */
.devbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 18px;
  border-top: 1px solid var(--line-soft);
  background: var(--bg-soft);
  font-size: 12px;
  color: var(--ink-3);
}
.devbar .btn--link { font-size: 12px; }

/* Пояснение к способу подтверждения — не предупреждение, а справка */
.demo-note--info {
  background: var(--blue-soft);
  border-left-color: var(--blue);
  color: var(--ink-2);
}

.frm input[type="text"].code {
  font-size: 22px;
  font-weight: bold;
  letter-spacing: .5em;
  text-align: center;
  text-indent: .5em;
}

.frm__timer {
  font-size: 12px;
  color: var(--ink-3);
  white-space: nowrap;
}

.btn:disabled,
.btn--link:disabled {
  opacity: .55;
  cursor: default;
}
.btn:disabled:hover { background: var(--blue); }
.btn--link:disabled:hover { text-decoration: none; }

/* ========================================================== ПЛИТКИ СЕРВИСОВ */
.tiles-hd {
  max-width: 1240px;
  margin: 0 auto 20px;
  text-align: left;
  font-size: 20px;
  color: var(--blue);
}

.tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: 1240px;
  margin: 0 auto;
}

.tile {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px 20px;
  text-align: center;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.tile:hover {
  border-color: var(--blue);
  box-shadow: 0 6px 20px rgba(0, 71, 143, 0.12);
  transform: translateY(-2px);
  text-decoration: none;
}

.tile svg { color: var(--blue); margin-bottom: 14px; }
.tile__t { font-size: 15px; font-weight: bold; color: var(--blue-dark); margin-bottom: 6px; }
.tile__d { font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }

/* ================================================================== ПОДВАЛ */
.ftr {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  padding: 20px 0;
  font-size: 12.5px;
  color: var(--ink-2);
  line-height: 1.6;
}

.ftr__in {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

/* =============================================================== ЛИЧНЫЙ КАБИНЕТ
   Секция была потеряна при пересборке стилей: разметку cabinet.js рисует,
   а правил под неё не осталось. Оформление то же, что на странице входа —
   белые карточки с тонкой рамкой, синие заголовки, строгие таблицы.
   ============================================================================ */

/* Меню разделов и строка пользователя */
.nav {
  background: var(--blue);
  border-bottom: 3px solid var(--blue-dark);
}

.nav__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 44px;
}

.nav a {
  display: inline-block;
  padding: 13px 16px;
  color: #dce7f2;
  font-size: 13.5px;
  text-transform: uppercase;
  letter-spacing: .03em;
  transition: background .15s, color .15s;
}
.nav a:hover { background: var(--blue-dark); color: #fff; }
.nav a.is-active { background: #fff; color: var(--blue); font-weight: bold; }

.nav__user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 0;
  color: #cfe0f0;
  font-size: 13px;
}
.nav__user b { color: #fff; }

.btn-exit {
  padding: 6px 14px;
  background: transparent;
  color: #fff;
  font-family: inherit;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .04em;
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 4px;
  cursor: pointer;
  transition: background .15s;
}
.btn-exit:hover { background: rgba(255, 255, 255, .16); }

/* Хлебные крошки */
.crumbs {
  padding: 12px 0;
  color: var(--ink-3);
  font-size: 12.5px;
}
.crumbs b { color: var(--ink-2); font-weight: bold; }

/* Заголовок страницы */
.page__title {
  padding-bottom: 16px;
  margin-bottom: 18px;
  border-bottom: 2px solid var(--blue);
}
.page__title h1 {
  margin: 0 0 6px;
  color: var(--blue);
  font-size: 22px;
  line-height: 1.3;
}
.page__title .sub { color: var(--ink-2); font-size: 13px; }

/* Плашка-уведомление */
.msg {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 16px;
  margin-bottom: 18px;
  border: 1px solid var(--line);
  border-left-width: 4px;
  border-radius: 0 4px 4px 0;
  font-size: 13.5px;
  line-height: 1.55;
}
.msg b { display: block; margin-bottom: 2px; }

.msg__i {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  color: #fff;
  font-size: 13px;
  font-weight: bold;
  line-height: 22px;
  text-align: center;
}

.msg--warning { background: var(--warn-bg); border-color: var(--warn); color: #6d4600; }
.msg--warning .msg__i { background: var(--warn); }
.msg--ok { background: var(--ok-bg); border-color: var(--ok); color: #145c33; }
.msg--ok .msg__i { background: var(--ok); }
.msg--info { background: var(--blue-soft); border-color: var(--blue); color: var(--ink-2); }
.msg--info .msg__i { background: var(--blue); }

/* Две колонки */
.cols {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: start;
  gap: 20px;
  padding-bottom: 32px;
}
.stack { display: flex; flex-direction: column; gap: 20px; }

/* Карточка-блок */
.blk {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 4px;
  box-shadow: 0 1px 2px rgba(0, 50, 100, .04);
  overflow: hidden;
}

.blk__hd {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 16px;
  background: var(--blue-soft);
  border-bottom: 1px solid var(--line);
  color: var(--blue);
  font-size: 14px;
  font-weight: bold;
}
.blk__hd .note {
  color: var(--ink-3);
  font-size: 12px;
  font-weight: normal;
  white-space: nowrap;
}

.blk__bd { padding: 14px 16px; }

/* Наименование товара внутри блока */
.auto__name {
  color: var(--ink);
  font-size: 16px;
  font-weight: bold;
  line-height: 1.35;
}
.auto__vin {
  margin: 3px 0 12px;
  color: var(--ink-3);
  font-size: 12.5px;
  letter-spacing: .02em;
}

/* Таблицы */
.tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}
.tbl th {
  padding: 7px 8px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: bold;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: .02em;
}
.tbl td {
  padding: 8px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink);
  vertical-align: top;
}
.tbl tr:last-child td { border-bottom: 0; }
.tbl .key { width: 44%; color: var(--ink-2); }
.tbl .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tbl .nowrap { white-space: nowrap; color: var(--ink-3); }
.tbl .hint { color: var(--ink-3); font-size: 12px; }

/* Этапы оформления */
.steps .st {
  width: 26px;
  color: var(--ink-3);
  font-size: 13px;
  text-align: center;
}
.steps .dt {
  width: 92px;
  color: var(--ink-2);
  font-size: 12.5px;
  text-align: right;
  white-space: nowrap;
}
.steps .name { font-weight: bold; }

.steps tr.done .st { color: var(--ok); font-weight: bold; }
.steps tr.done .name { color: var(--ink-2); font-weight: normal; }
.steps tr.now { background: var(--blue-soft); }
.steps tr.now .st { color: var(--blue); }
.steps tr.now .name { color: var(--blue); }
.steps tr.todo .name,
.steps tr.todo .hint { color: var(--ink-3); }

/* Ярлык состояния. Прямоугольный, как всё остальное на портале: скруглённые
   «пилюли» выбивались из строгой сетки таблиц и карточек. */
.st-tag {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid transparent;
  border-left-width: 3px;
  border-radius: 2px;
  font-size: 12px;
  font-weight: bold;
  white-space: nowrap;
}
.st-paid, .st-ready       { background: var(--ok-bg);     border-color: #cbe6d6; border-left-color: var(--ok);   color: var(--ok); }
.st-due, .st-waiting      { background: var(--warn-bg);   border-color: #ecdcb8; border-left-color: var(--warn); color: var(--warn); }
.st-pending, .st-progress { background: var(--blue-soft); border-color: #cddfee; border-left-color: var(--blue); color: var(--blue); }
.st-col { width: 104px; }

/* Итоговые строки в платежах */
.tbl .total td {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  font-weight: bold;
}
.tbl .total--due td { background: var(--warn-bg); color: var(--warn); }

/* Специалист */
.mgr { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.mgr td { padding: 7px 8px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.mgr tr:last-child td { border-bottom: 0; }
.mgr .k { width: 44%; color: var(--ink-2); }

/* Телефоны и планшеты */
@media (max-width: 900px) {
  .cols { grid-template-columns: 1fr; }
  .nav__in { flex-direction: column; align-items: stretch; }
  .nav__user { justify-content: space-between; }
  .page__title h1 { font-size: 18px; }
  .tbl .key, .mgr .k { width: 50%; }
}

/* Разделы кабинета */
.nav__menu { display: flex; flex-wrap: wrap; }
.pane--narrow { max-width: 880px; }

.pane__note {
  margin: 14px 0 0;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.6;
}

/* Полоса выполнения оплаты */
.bar {
  height: 8px;
  margin-bottom: 14px;
  background: var(--line-soft);
  border-radius: 4px;
  overflow: hidden;
}
.bar__fill {
  height: 100%;
  background: var(--ok);
  border-radius: 4px;
}

/* ============================================================ ФОТОФИКСАЦИЯ */
/* Раздел не растягиваем на весь широкий экран — иначе 4 кадра прижаты влево,
   а справа большая пустота. Ограничиваем ширину, кадры заполняют ряд ровно. */
.pane[data-pane="photos"] { max-width: 1120px; }

.shots {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.shot {
  margin: 0;
  cursor: pointer;
  transition: transform .12s;
}
.shot[data-full]:hover { transform: translateY(-2px); }
.shot:not([data-full]) { cursor: default; }
.shot:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

/* Кадр в стиле стоп-кадра видеонаблюдения */
.shot__frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid #2b3138;
  border-radius: 3px;
  background: #14181d;
  color: #c9d3dd;
}
.shot__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Заглушка, пока реального снимка нет */
.shot__ph {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #48525d;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 1px, transparent 1px 3px),
    radial-gradient(120% 90% at 50% 40%, #20262d 0%, #14181d 100%);
  font-size: 12px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.shot__glyph { width: 88px; height: 44px; }

/* Оверлеи камеры */
.shot__rec, .shot__cam, .shot__time {
  position: absolute;
  font-size: 11px;
  font-weight: bold;
  letter-spacing: .05em;
  text-shadow: 0 1px 2px rgba(0,0,0,.8);
  font-variant-numeric: tabular-nums;
}
.shot__rec  { top: 8px; left: 9px; color: #ff5a52; }
.shot__cam  { top: 8px; right: 9px; color: #e8eef4; }
.shot__time { bottom: 8px; right: 9px; color: #9fe6b4; }

.shot__cap {
  margin-top: 7px;
  font-size: 12.5px;
  color: var(--ink-2);
  line-height: 1.4;
}

/* Просмотр кадра крупно */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 32px;
  background: rgba(10, 14, 18, .9);
}
.lightbox__img {
  max-width: min(1100px, 92vw);
  max-height: 80vh;
  object-fit: contain;
  border: 1px solid #2b3138;
  border-radius: 4px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.lightbox__cap {
  color: #dbe3ec;
  font-size: 13.5px;
  text-align: center;
}
.lightbox__close {
  position: absolute;
  top: 18px;
  right: 22px;
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,.12);
  color: #fff;
  border: 0;
  border-radius: 6px;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  transition: background .15s;
}
.lightbox__close:hover { background: rgba(255,255,255,.24); }

@media (max-width: 900px) {
  .shots { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}

/* ================================================================ АДМИНКА */
.adm-head { background: #fff; border-bottom: 1px solid var(--line); }
.adm-head__in { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; }
.adm-brand { font-size: 16px; font-weight: bold; color: var(--blue); }
.adm-brand span { display: block; font-size: 12px; font-weight: normal; color: var(--ink-3); }

.adm-login { max-width: 420px; margin: 48px auto; padding: 0 12px; }

.adm-work { padding: 20px 12px 48px; }

.adm-grid {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.adm-list {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  position: sticky;
  top: 12px;
}
.adm-list__hd {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; background: var(--blue-soft);
  border-bottom: 1px solid var(--line);
  font-size: 13px; font-weight: bold; color: var(--blue);
}

.adm-case {
  display: block; width: 100%; text-align: left;
  padding: 11px 14px; border: 0; border-bottom: 1px solid var(--line-soft);
  background: #fff; cursor: pointer; font-family: inherit;
  transition: background .12s;
}
.adm-case:hover { background: var(--bg-soft); }
.adm-case.is-active { background: var(--blue-soft); box-shadow: inset 3px 0 0 var(--blue); }
.adm-case__top { display: flex; align-items: center; gap: 8px; margin-bottom: 3px; }
.adm-case__name { font-weight: bold; font-size: 13.5px; color: var(--ink); }
.adm-case__sub { font-size: 12px; color: var(--ink-3); }
.adm-case.is-new { animation: admFlash 1.4s ease; }
@keyframes admFlash { 0% { background: #fff7db; } 100% { background: #fff; } }

.adm-badge {
  font-size: 10.5px; font-weight: bold; padding: 1px 7px; border-radius: 2px;
  border-left: 3px solid transparent; text-transform: uppercase; letter-spacing: .02em;
}
.adm-badge--new    { background: var(--warn-bg); border-left-color: var(--warn); color: var(--warn); }
.adm-badge--active { background: var(--ok-bg);   border-left-color: var(--ok);   color: var(--ok); }

.adm-editor {
  background: #fff; border: 1px solid var(--line); border-radius: 4px;
  min-height: 200px;
}
.adm-empty { padding: 40px; text-align: center; color: var(--ink-3); }

.adm-sec { border-bottom: 1px solid var(--line-soft); padding: 16px 18px; }
.adm-sec:last-child { border-bottom: 0; }
.adm-sec__hd { font-size: 13px; font-weight: bold; color: var(--blue); margin-bottom: 12px; text-transform: uppercase; letter-spacing: .02em; }

.adm-fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px 14px; }
.adm-fields--1 { grid-template-columns: 1fr; }
.adm-f { display: flex; flex-direction: column; gap: 4px; }
.adm-f label { font-size: 12px; color: var(--ink-2); font-weight: bold; }
.adm-f input, .adm-f select, .adm-f textarea {
  height: 36px; padding: 0 10px; font-family: inherit; font-size: 13.5px;
  border: 1px solid #b9c4cf; border-radius: 5px; background: #fff; color: var(--ink); outline: none;
}
.adm-f textarea { height: auto; padding: 8px 10px; resize: vertical; min-height: 60px; }
.adm-f input:focus, .adm-f select:focus, .adm-f textarea:focus {
  border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0,71,143,.13);
}

/* Редакторы массивов (платежи, документы, фото) */
.adm-rows { display: flex; flex-direction: column; gap: 8px; }
.adm-row {
  display: grid; gap: 8px; align-items: center;
  padding: 8px; background: var(--bg-soft); border: 1px solid var(--line-soft); border-radius: 5px;
}
.adm-row input, .adm-row select {
  height: 32px; padding: 0 8px; font-family: inherit; font-size: 13px;
  border: 1px solid #cbd5e0; border-radius: 4px; background: #fff; min-width: 0;
}
.adm-row__del {
  width: 30px; height: 30px; flex: none; border: 0; border-radius: 4px; cursor: pointer;
  background: var(--err-bg); color: var(--err); font-size: 18px; line-height: 1;
}
.adm-add {
  margin-top: 8px; padding: 6px 12px; font-size: 12.5px; font-family: inherit;
  background: var(--blue-soft); color: var(--blue); border: 1px dashed var(--blue);
  border-radius: 5px; cursor: pointer; font-weight: bold;
}

.adm-bar {
  position: sticky; bottom: 0; display: flex; align-items: center; gap: 14px;
  padding: 14px 18px; background: #fff; border-top: 1px solid var(--line);
}
.adm-bar .btn { width: auto; padding: 0 26px; }
.adm-bar__msg { font-size: 13px; }
.adm-bar__msg.ok { color: var(--ok); }
.adm-bar__msg.err { color: var(--err); }

/* Индикатор реалтайма */
.top__clock.is-live { color: #7fe0a0; }
.top__clock.is-live::before,
.top__clock::before { content: '●'; margin-right: 6px; color: #c3502f; }
.top__clock.is-live::before { color: #57d98a; }

/* Тост о новой заявке */
.adm-toast {
  position: fixed; top: 16px; right: 16px; z-index: 100;
  max-width: 340px; padding: 12px 16px;
  background: var(--blue); color: #fff; border-radius: 6px;
  box-shadow: 0 10px 30px rgba(0,40,90,.3);
  font-size: 13.5px; cursor: pointer;
}
.adm-toast b { display: block; margin-bottom: 2px; }

@media (max-width: 860px) {
  .adm-grid { grid-template-columns: 1fr; }
  .adm-list { position: static; }
  .adm-fields { grid-template-columns: 1fr; }
}

/* Предпросмотр разбивки растаможки в админке */
.adm-split {
  margin-top: 6px;
  padding: 12px 14px;
  background: var(--blue-soft);
  border: 1px solid #cddfee;
  border-radius: 6px;
  font-size: 13px;
}
.adm-split__hd { font-weight: bold; color: var(--blue); margin-bottom: 8px; }
.adm-split__row { display: flex; justify-content: space-between; padding: 4px 0; color: var(--ink-2); }
.adm-split__row b { color: var(--ink); font-variant-numeric: tabular-nums; }
.adm-split__total { margin-top: 4px; padding-top: 8px; border-top: 1px solid #cddfee; }
.adm-split__total span, .adm-split__total b { color: var(--blue); font-weight: bold; }

/* Вкладки редактора дела в админке */
.ed-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  padding: 8px 10px 0;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 5;
}
.ed-tab {
  padding: 9px 16px;
  font-family: inherit;
  font-size: 13px;
  font-weight: bold;
  color: var(--ink-2);
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  border-radius: 5px 5px 0 0;
  transition: background .12s, color .12s;
}
.ed-tab:hover { background: #fff; color: var(--blue); }
.ed-tab.is-active {
  color: var(--blue);
  background: #fff;
  border-bottom-color: var(--blue);
}
.ed-pane .adm-sec:first-child { border-top: 0; }

/* Загрузка файла в строке фотофиксации */
.adm-upload { display: flex; gap: 6px; align-items: center; min-width: 0; }
.adm-upload input { flex: 1; min-width: 0; }
.adm-upbtn {
  flex: none; height: 32px; padding: 0 10px; font-family: inherit; font-size: 12px;
  background: var(--blue-soft); color: var(--blue); border: 1px solid #bcd3e8;
  border-radius: 4px; cursor: pointer; white-space: nowrap;
}
.adm-upbtn:hover { background: #dbe8f5; }
.adm-upbtn:disabled { opacity: .6; cursor: default; }
