/* Хаб ProfiSkills. Темы: «Чистый лист» (светлая, по умолчанию) и «Ночная смена» (тёмная).
   data-theme на <html>: light | dark | auto (auto — как в системе). */
:root {
  --bg: #f7f7f8;
  --surface: #ffffff;
  --surface-2: #efeff1;
  --text: #1f2023;
  --muted: #74767c;
  --line: #e6e6ea;
  --accent: #5c5c5c;
  --accent-soft: #ececee;
  --accent-text: #ffffff;
  --good: #1f9d6b;
  --good-bg: #e4f5ec;
  --bad: #e5484d;
  --bad-bg: #fdecec;
  --warn: #b7791f;
  --warn-bg: #fdf3dc;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(28, 30, 46, 0.04), 0 4px 16px rgba(28, 30, 46, 0.04);
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #2e3236;
  --surface: #3a3f43;
  --surface-2: #454a4f;
  --text: #f1f2f3;
  --muted: #aab0b5;
  --line: #4d5358;
  --accent: #e4e6e8;
  --accent-soft: #50565b;
  --accent-text: #2e3236;
  --good: #5fd39a;
  --good-bg: #2f4a3e;
  --bad: #ff8a80;
  --bad-bg: #563634;
  --warn: #f2c35b;
  --warn-bg: #54472b;
  --shadow: none;
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    --bg: #2e3236;
  --surface: #3a3f43;
  --surface-2: #454a4f;
  --text: #f1f2f3;
  --muted: #aab0b5;
  --line: #4d5358;
  --accent: #e4e6e8;
  --accent-soft: #50565b;
  --accent-text: #2e3236;
  --good: #5fd39a;
  --good-bg: #2f4a3e;
  --bad: #ff8a80;
  --bad-bg: #563634;
  --warn: #f2c35b;
  --warn-bg: #54472b;
    --shadow: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }  /* иначе display у .row, .card и т. п. перебивает атрибут hidden */
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 30px; margin: 0; letter-spacing: -0.02em; font-weight: 650; }
h2 { font-size: 16px; margin: 0 0 12px; font-weight: 600; }
h3 { font-size: 14px; margin: 16px 0 8px; }
code { font-family: var(--mono); font-size: 0.9em; }

/* Иконки (hub/static/icons.svg): цвет — от текста, размер — от шрифта */
.ic { width: 1.15em; height: 1.15em; flex-shrink: 0; vertical-align: -0.2em; }
.btn .ic { width: 17px; height: 17px; }
.btn-small .ic { width: 15px; height: 15px; }
.done-btn .ic { width: 13px; height: 13px; }

/* Шапка с меню сверху */
.layout { min-height: 100vh; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { max-width: 1200px; margin: 0 auto; padding: 10px 32px; display: flex; align-items: center; gap: 18px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); flex-shrink: 0; }
.brand:hover { text-decoration: none; }
.brand strong { font-weight: 650; letter-spacing: -0.01em; }
.brand small { display: block; font-size: 11px; color: var(--muted); }
.brand-logo { width: 32px; height: 32px; border-radius: 10px; object-fit: contain; background: #fff; flex-shrink: 0; }
.login-card .brand-logo { width: 44px; height: 44px; }
.brand-mark {
  width: 32px; height: 32px; border-radius: 10px;
  background: var(--accent); color: var(--accent-text);
  display: grid; place-items: center; font-weight: 700;
}
.nav-label { display: block; font-size: 11px; color: var(--muted); margin: 0 0 2px; }
nav.main-nav { display: flex; gap: 2px; flex: 1; overflow-x: auto; scrollbar-width: none; }
nav.main-nav::-webkit-scrollbar { display: none; }
nav.main-nav a { color: var(--muted); padding: 7px 12px; border-radius: 999px; white-space: nowrap; font-weight: 500;
  display: inline-flex; align-items: center; gap: 7px; }
nav.main-nav a .ic { width: 17px; height: 17px; opacity: 0.85; }
nav.main-nav a.active .ic { opacity: 1; }
nav.main-nav a:hover { color: var(--text); background: var(--surface-2); text-decoration: none; }
nav.main-nav a.active { color: var(--text); background: var(--accent-soft); }
.topbar-tools { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.ws-switch { display: flex; gap: 6px; align-items: center; }
.ws-switch select { width: auto; padding: 6px 10px; }
.ws-name { font-size: 13px; color: var(--muted); }
.logout { display: flex; align-items: center; gap: 8px; margin: 0; }
.theme-switch { display: inline-flex; padding: 3px; gap: 2px; background: var(--surface-2); border-radius: 999px; }
.theme-switch button {
  font: inherit; font-size: 12px; border: 0; background: transparent; color: var(--muted);
  padding: 4px 10px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 5px;
}
.theme-switch .ic { width: 15px; height: 15px; }
.theme-switch button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }

.content { padding: 32px; max-width: 1200px; width: 100%; margin: 0 auto; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.eyebrow { font-size: 13px; font-weight: 500; color: var(--muted); margin: 0 0 4px; }
.eyebrow a { color: var(--muted); }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.grid-2 { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 20px; align-items: start; }
.stack { display: grid; gap: 20px; }

.stats { display: flex; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; min-width: 150px; color: var(--muted); font-size: 13px; box-shadow: var(--shadow); }
.stat span { display: block; font-size: 28px; font-weight: 650; letter-spacing: -0.02em; color: var(--text); }
.stat-good span { color: var(--good); }
.stat-bad { border-color: var(--bad); }
.stat-bad span { color: var(--bad); }

.table-wrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table .url { max-width: 260px; overflow-wrap: anywhere; }

.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge-good { background: var(--good-bg); color: var(--good); }
.badge-bad { background: var(--bad-bg); color: var(--bad); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-off { background: var(--surface-2); color: var(--muted); }
.tag { display: inline-block; padding: 1px 7px; border: 1px solid var(--line); border-radius: 6px; font-size: 12px; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 12px; }

.form { display: grid; gap: 14px; }
.form .row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
/* iOS Safari даёт полям даты и времени собственную минимальную ширину — без этого они наезжают на соседние */
.form .row > label { min-width: 0; }
.form input[type="date"], .form input[type="time"] { min-width: 0; max-width: 100%; display: block; -webkit-appearance: none; appearance: none; }
label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
label.check { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 14px; }
input, select, textarea {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; width: 100%;
}
input[type="checkbox"] { width: auto; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: grid; gap: 12px; margin: 0; }
legend { font-weight: 600; padding: 0 6px; }
.hint { font-size: 12px; color: var(--muted); margin: 0; }
.error { color: var(--bad); font-size: 12px; }
.actions { display: flex; gap: 10px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-weight: 600; font-size: 14px;
  padding: 9px 16px; border-radius: 10px; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface-2); color: var(--text);
}
.btn:hover { text-decoration: none; filter: brightness(0.97); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn-ghost { background: transparent; }
.btn-danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn-small { padding: 4px 10px; font-size: 12px; }

.alert { background: var(--warn-bg); color: var(--text); border-radius: 8px; padding: 10px 14px; margin: 0 0 16px; }
.alert-error { background: var(--bad-bg); }
.alert-ok { background: var(--good-bg); }
.code { font-family: var(--mono); font-size: 28px; letter-spacing: 0.2em; font-weight: 700; margin: 8px 0; }
.list { list-style: none; padding: 0; margin: 0 0 8px; display: grid; gap: 8px; }
.list-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 8px; background: var(--muted); }
.dot-ok { background: var(--good); }
.dot-fail, .dot-config_error { background: var(--bad); }
.dot-blocked { background: var(--warn); }
.danger { border-color: var(--bad); }
.empty { text-align: center; }

.center-page { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login-card { width: 100%; max-width: 380px; display: grid; gap: 14px; }

@media (max-width: 860px) {
  .topbar-inner { flex-wrap: wrap; padding: 10px 16px; gap: 10px; }
  nav.main-nav { order: 3; flex-basis: 100%; }
  .topbar-tools { margin-left: auto; }
  .ws-name, .logout .muted, .theme-switch span, .logout span { display: none; }
  .content { padding: 20px 16px; }
  h1 { font-size: 24px; }
  .grid-2 { grid-template-columns: 1fr; }
  .table thead { display: none; }
  .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
  .table tr { border-bottom: 1px solid var(--line); padding: 8px 0; }
  .table td { border: 0; padding: 4px 14px; }
  .table td::before { content: attr(data-label); display: block; font-family: var(--mono); font-size: 10px; text-transform: uppercase; color: var(--muted); }
  .table .url { max-width: none; }
}

/* --- фаза 3: задачи и календарь --- */
.count { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 12px; text-align: center; font-weight: 600; }
.card-bad { border-color: var(--bad); }
.mono { font-family: var(--mono); font-size: 0.92em; }

.quick-add { display: grid; grid-template-columns: 1fr auto auto auto; gap: 8px; margin-bottom: 20px; }
.quick-add input[type="date"], .quick-add input[type="time"] { width: auto; }

.tasks { list-style: none; margin: 0; padding: 0; }
.task { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); }
.task:last-child { border-bottom: 0; }
.task-check { margin: 0; }
.done-btn {
  width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); background: transparent;
  color: var(--good); font-weight: 700; line-height: 1; cursor: pointer; padding: 0; margin-top: 1px;
}
.done-btn:hover { border-color: var(--good); }
.task-important .done-btn { border-color: var(--bad); }
.task-body { display: grid; gap: 2px; color: var(--text); flex: 1; min-width: 0; }
.task-body:hover { text-decoration: none; }
.task-body:hover .task-title { color: var(--accent); }
.task-title { overflow-wrap: anywhere; }
.important { color: var(--bad); font-weight: 700; }
.task-meta { display: flex; flex-wrap: wrap; gap: 10px; font-size: 12px; color: var(--muted); }
.task-done .task-title { text-decoration: line-through; color: var(--muted); }
.task-done .done-btn { border-color: var(--good); }
.proj { display: inline-flex; align-items: center; gap: 4px; }
.pdot { width: 8px; height: 8px; border-radius: 50%; background: var(--pc, var(--muted)); display: inline-block; }

.tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 16px; }
.tabs a { padding: 6px 12px; border-radius: 8px; color: var(--text); border: 1px solid transparent; }
.tabs a:hover { background: var(--surface-2); text-decoration: none; }
.tabs a.active { background: var(--surface); border-color: var(--line); font-weight: 600; }
.tabs a.tab-bad .count { background: var(--bad-bg); color: var(--bad); }

.cal-nav { display: flex; gap: 6px; flex-wrap: wrap; }
.cal-wrap { overflow-x: auto; }
.cal { width: 100%; border-collapse: collapse; table-layout: fixed; min-width: 640px; }
.cal th { font-family: var(--mono); font-size: 11px; text-transform: uppercase; color: var(--muted); padding: 8px; border-bottom: 1px solid var(--line); }
.cal td { vertical-align: top; height: 104px; padding: 6px; border: 1px solid var(--line); }
.cal-out { background: var(--bg); }
.cal-out .cal-num { color: var(--muted); }
.cal-weekend { background: color-mix(in srgb, var(--surface-2) 40%, transparent); }
.cal-today { box-shadow: inset 0 0 0 2px var(--accent); }
.cal-num { display: inline-block; font-weight: 700; font-size: 15px; color: var(--text); margin-bottom: 4px; }
.cal-task {
  display: block; font-size: 12px; line-height: 1.3; padding: 3px 6px; margin-bottom: 3px; border-radius: 6px;
  background: var(--surface-2); color: var(--text); border-left: 3px solid var(--pc, var(--muted));
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: grab;
}
.cal-task:hover { text-decoration: none; filter: brightness(0.96); }
.cal-task.task-done { text-decoration: line-through; color: var(--muted); }
.dragging { opacity: 0.4; }
.drop-target { background: var(--good-bg) !important; }
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; }
.week-day { padding: 12px; min-height: 160px; }
.week-day h2 { font-size: 13px; }
.week-day h2 a { color: var(--text); }

.pc-2f45d8 { --pc: #2f45d8; } .pc-1f8a4c { --pc: #1f8a4c; } .pc-c7362b { --pc: #c7362b; } .pc-e07b00 { --pc: #e07b00; }
.pc-8a3ffc { --pc: #8a3ffc; } .pc-0f9aa8 { --pc: #0f9aa8; } .pc-c2378a { --pc: #c2378a; } .pc-6f6a5f { --pc: #6f6a5f; }

@media (max-width: 860px) {
  .quick-add { grid-template-columns: 1fr 1fr; }
  .quick-add input[name="title"] { grid-column: 1 / -1; }
  .quick-add button { grid-column: 1 / -1; }
  .week { grid-template-columns: 1fr; }
  .cal td { height: 80px; padding: 3px; }
  .cal-task { font-size: 11px; padding: 2px 4px; }
}

/* Широкие блоки (календарь) прокручиваются внутри себя, а не растягивают страницу. */
.content { min-width: 0; }
.hint-touch { display: none; }
@media (max-width: 860px) {
  .hint-drag { display: none; }
  .hint-touch { display: block; }
}

/* --- фаза 5: клиенты, оплаты, карточки --- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px; }
.filters input[name="q"] { flex: 1 1 260px; width: auto; }
.filters select { width: auto; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0 0 10px; }
.facts dt { color: var(--muted); font-size: 13px; }
.facts dd { margin: 0; overflow-wrap: anywhere; }
.notes { white-space: pre-wrap; background: var(--bg); border-radius: 8px; padding: 10px 12px; margin: 0; }
.pay-row { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
.pay-row:last-child { border-bottom: 0; }
.pay-paid { opacity: 0.7; }
.pay-overdue strong { color: var(--bad); }
.row-actions { display: flex; gap: 4px; flex-shrink: 0; }
.row-actions form { margin: 0; }
.add-payment { margin-top: 12px; }
.add-payment summary { cursor: pointer; color: var(--accent); font-weight: 600; }
.add-payment .form { margin-top: 10px; }
.narrow { max-width: 640px; }
h1 .pdot { width: 14px; height: 14px; vertical-align: middle; }

/* --- фаза 6: сроки --- */
.dl-soon strong { color: var(--warn); }
.cal-deadline {
  display: block; font-size: 11px; line-height: 1.3; padding: 2px 6px; margin-bottom: 3px; border-radius: 6px;
  background: var(--warn-bg); color: var(--text); border-left: 3px solid var(--pc, var(--warn));
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.cal-deadline:hover { text-decoration: none; filter: brightness(0.96); }

/* --- фаза 7: сервер --- */
.server-mini { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; padding: 5px 12px; border-radius: 999px; background: var(--surface-2); }
.server-mini:hover { text-decoration: none; background: var(--surface-2); }
.server-mini .nav-label { display: none; }
.srv-row { display: flex; gap: 4px; }
.srv-bad, .srv-bad .mono { color: var(--bad); font-weight: 700; }
.srv-today { display: flex; gap: 18px; margin-bottom: 8px; }
.srv-today div { display: grid; color: var(--muted); font-size: 12px; }
.srv-today .mono { font-size: 22px; font-weight: 700; color: var(--text); }
.srv-today .srv-bad .mono { color: var(--bad); }
.spark { display: grid; grid-template-columns: 90px 1fr; align-items: center; gap: 10px; margin-bottom: 10px; }
.spark svg { width: 100%; height: 48px; background: var(--bg); border-radius: 6px; }
.spark-bar { fill: var(--accent); }
.spark-bad { fill: var(--bad); }
.spark-limit { stroke: var(--bad); stroke-dasharray: 4 3; vector-effect: non-scaling-stroke; }
@media (max-width: 860px) { .server-mini { display: none; } }

/* --- фаза 8: Метрика --- */
.stats.compact .stat { min-width: 110px; padding: 8px 12px; }
.stats.compact .stat span { font-size: 20px; }
.metrika-chart { width: 100%; height: 80px; background: var(--bg); border-radius: 6px; }
.metrika-chart rect { fill: var(--accent); }

/* Шапка на экранах до 1440 px: переключатель темы и «Выйти» — только иконки (подписи — в title) */
@media (max-width: 1440px) {
  .theme-switch span, .logout span, .ws-name { display: none; }
  .theme-switch button { padding: 5px 8px; }
  nav.main-nav a { padding: 7px 9px; gap: 6px; }
  .topbar-inner { gap: 12px; }
}

/* Иконки в заголовках, вкладках и фильтрах */
h1 .ic { width: 26px; height: 26px; vertical-align: -4px; margin-right: 10px; color: var(--muted); }
h2 .ic { width: 18px; height: 18px; vertical-align: -3px; margin-right: 7px; color: var(--muted); }
.card-bad h2 .ic { color: var(--bad); }
.tabs a { display: inline-flex; align-items: center; gap: 6px; }
.tabs a .ic { width: 16px; height: 16px; opacity: 0.8; }
.tabs a.active .ic { opacity: 1; }
.search-field { position: relative; display: block; flex: 1 1 260px; color: var(--muted); }
.search-field .ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; pointer-events: none; }
.search-field input { padding-left: 38px; width: 100%; }
.filters input[name="q"] { flex: none; }
.filter-icon { color: var(--muted); display: inline-flex; }
.filter-icon .ic { width: 18px; height: 18px; }
.filters .check .ic, p.small .ic { width: 15px; height: 15px; vertical-align: -3px; }
.filters .search-field input { width: 100%; }
.filters .check { flex-shrink: 0; white-space: nowrap; }

/* --- Работа без связи --- */
.offline-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin: 12px auto 0; width: calc(100% - 64px); max-width: 1136px; padding: 10px 14px; border-radius: var(--radius);
  background: var(--warn-bg); color: var(--warn); font-weight: 600;
}
.offline-bar[hidden] { display: none; }
.offline-bar .offline-actions { display: flex; gap: 6px; margin-left: auto; flex-wrap: wrap; }
/* Без связи формы не отправятся — показываем это заранее. */
.is-offline main form[method="post"] button:not([type="button"]) { opacity: .45; cursor: not-allowed; }
.is-offline.queue-ready main form.quick-add button, .is-offline.queue-ready main form.task-check button { opacity: 1; cursor: pointer; }
@media (max-width: 860px) { .offline-bar { width: calc(100% - 32px); } }

/* --- Очередь действий без связи --- */
.sync-badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  background: var(--warn-bg); color: var(--warn); font-weight: 600; font-size: 13px;
}
.sync-badge[hidden] { display: none; }
.sync-panel {
  margin: 12px auto 0; width: calc(100% - 64px); max-width: 1136px; padding: 14px 16px;
  border-radius: var(--radius); background: var(--surface); border: 1px dashed var(--warn); box-shadow: var(--shadow);
}
.sync-panel[hidden] { display: none; }
.sync-panel h3 { margin: 0 0 4px; font-size: 15px; }
.sync-panel .alert { margin: 10px 0 0; }
.sync-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 6px; }
.sync-list li { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sync-list li > span:first-child { flex: 1 1 220px; }
.task-pending { outline: 1px dashed var(--warn); outline-offset: 2px; border-radius: 8px; }
@media (max-width: 860px) { .sync-panel { width: calc(100% - 32px); } }

/* --- Цвет акцента пространства (sites.ACCENTS): класс accent-<ключ> на <html>. Сгенерировано из палитры. --- */
:root.accent-graphite { --accent: #5c5c5c; --accent-soft: #ebebeb; --accent-text: #ffffff; }
:root.accent-graphite[data-theme="dark"] { --accent: #e4e6e8; --accent-soft: #5f6467; --accent-text: #2e3236; }
:root.accent-rose { --accent: #b4436c; --accent-soft: #f6e8ed; --accent-text: #ffffff; }
:root.accent-rose[data-theme="dark"] { --accent: #f0a6bf; --accent-soft: #62565e; --accent-text: #2e3236; }
:root.accent-plum { --accent: #7a3e8a; --accent-soft: #efe8f1; --accent-text: #ffffff; }
:root.accent-plum[data-theme="dark"] { --accent: #d7a8e3; --accent-soft: #5d5666; --accent-text: #2e3236; }
:root.accent-lavender { --accent: #5b5bb0; --accent-soft: #ebebf6; --accent-text: #ffffff; }
:root.accent-lavender[data-theme="dark"] { --accent: #b7b7f0; --accent-soft: #565969; --accent-text: #2e3236; }
:root.accent-ocean { --accent: #2563a6; --accent-soft: #e5ecf4; --accent-text: #ffffff; }
:root.accent-ocean[data-theme="dark"] { --accent: #9cc3ef; --accent-soft: #505c69; --accent-text: #2e3236; }
:root.accent-teal { --accent: #0f7d7a; --accent-soft: #e2efef; --accent-text: #ffffff; }
:root.accent-teal[data-theme="dark"] { --accent: #8fd8d3; --accent-soft: #4d6163; --accent-text: #2e3236; }
:root.accent-sage { --accent: #4f7a4a; --accent-soft: #eaefe9; --accent-text: #ffffff; }
:root.accent-sage[data-theme="dark"] { --accent: #b3d6ad; --accent-soft: #55605a; --accent-text: #2e3236; }
:root.accent-sand { --accent: #8a6a2f; --accent-soft: #f1ede6; --accent-text: #ffffff; }
:root.accent-sand[data-theme="dark"] { --accent: #e3cb98; --accent-soft: #5f5e56; --accent-text: #2e3236; }
:root.accent-coral { --accent: #b8533a; --accent-soft: #f6eae7; --accent-text: #ffffff; }
:root.accent-coral[data-theme="dark"] { --accent: #f2b09e; --accent-soft: #625857; --accent-text: #2e3236; }
:root.accent-mint { --accent: #2e8a6c; --accent-soft: #e6f1ed; --accent-text: #ffffff; }
:root.accent-mint[data-theme="dark"] { --accent: #8fdcc0; --accent-soft: #4d625e; --accent-text: #2e3236; }
@media (prefers-color-scheme: dark) {
  :root.accent-graphite[data-theme="auto"] { --accent: #e4e6e8; --accent-soft: #5f6467; --accent-text: #2e3236; }
  :root.accent-rose[data-theme="auto"] { --accent: #f0a6bf; --accent-soft: #62565e; --accent-text: #2e3236; }
  :root.accent-plum[data-theme="auto"] { --accent: #d7a8e3; --accent-soft: #5d5666; --accent-text: #2e3236; }
  :root.accent-lavender[data-theme="auto"] { --accent: #b7b7f0; --accent-soft: #565969; --accent-text: #2e3236; }
  :root.accent-ocean[data-theme="auto"] { --accent: #9cc3ef; --accent-soft: #505c69; --accent-text: #2e3236; }
  :root.accent-teal[data-theme="auto"] { --accent: #8fd8d3; --accent-soft: #4d6163; --accent-text: #2e3236; }
  :root.accent-sage[data-theme="auto"] { --accent: #b3d6ad; --accent-soft: #55605a; --accent-text: #2e3236; }
  :root.accent-sand[data-theme="auto"] { --accent: #e3cb98; --accent-soft: #5f5e56; --accent-text: #2e3236; }
  :root.accent-coral[data-theme="auto"] { --accent: #f2b09e; --accent-soft: #625857; --accent-text: #2e3236; }
  :root.accent-mint[data-theme="auto"] { --accent: #8fdcc0; --accent-soft: #4d625e; --accent-text: #2e3236; }
}

/* --- Студия: журнал записей (главный экран мастера на телефоне) --- */
.day-nav { display: flex; gap: 6px; flex-wrap: wrap; margin: -8px 0 16px; }
.booking-list { display: grid; gap: 12px; }
.booking { display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; align-items: start; padding: 16px 18px; }
.booking-time { font-size: 20px; font-weight: 700; line-height: 1.1; }
.booking-time span { display: block; font-size: 13px; font-weight: 500; color: var(--muted); }
.booking-body strong { font-size: 16px; }
.booking-body .ic { width: 14px; height: 14px; vertical-align: -2px; margin-right: 3px; }
.booking-status { margin-top: 6px; display: flex; gap: 6px; }
.booking-actions { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.booking-actions form { margin: 0; }
.booking-actions .btn { width: 100%; justify-content: center; }
.booking-done { border-left: 4px solid var(--good); }
.booking-confirmed { border-left: 4px solid var(--accent); }
.booking-cancelled, .booking-no_show { opacity: .6; }
.week-list { display: grid; gap: 10px; }
.week-booking { display: block; padding: 6px 0; border-top: 1px solid var(--line); color: var(--text); }
.week-booking.booking-cancelled, .week-booking.booking-no_show { text-decoration: line-through; border-left: 0; }
.week-booking.booking-done, .week-booking.booking-confirmed { border-left: 0; }
.service-row { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 12px; }
.service-row:first-of-type { border-top: 0; margin-top: 0; padding-top: 0; }
@media (max-width: 640px) {
  .booking { grid-template-columns: 1fr; gap: 8px; }
  .booking-time { font-size: 22px; }
  .booking-time span { display: inline; margin-left: 4px; }
  .booking-actions { flex-direction: row; flex-wrap: wrap; }
  .booking-actions .btn { width: auto; min-height: 44px; padding: 10px 16px; font-size: 15px; }
}

/* --- Режим поддержки --- */
.support-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin: 12px auto 0; width: calc(100% - 64px); max-width: 1136px; padding: 10px 14px; border-radius: var(--radius);
  background: var(--bad-bg); color: var(--text); font-weight: 600;
}
.support-bar form { margin-left: auto; }
.support-row { flex-wrap: wrap; gap: 10px; }
.support-forms { display: flex; gap: 8px; flex-wrap: wrap; }
.inline-form { display: flex; gap: 6px; align-items: center; margin: 0; }
.inline-form input[type="password"] { width: 150px; }
@media (max-width: 860px) { .support-bar { width: calc(100% - 32px); } }
.support-ended { margin: 12px auto 0; width: calc(100% - 64px); max-width: 1136px; }

/* --- Оттенки блоков и цветные иконки. Оттенок блока — по иконке его заголовка (:has), страницы не меняются. --- */
.card:has(> h2 > .ic use[href$="#i-clock"]), .card:has(> h2 > .ic use[href$="#i-check"]), .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #f1faf6; --tint-border: #d8efe5; --chip-bg: #dcf2e9; --chip-fg: #2e8a6c; }
.card:has(> h2 > .ic use[href$="#i-tasks"]), .card:has(> h2 > .ic use[href$="#i-calendar"]), .card:has(> h2 > .ic use[href$="#i-send"]), .card:has(> h2 > .ic use[href$="#i-info"]), .card:has(> h2 > .ic use[href$="#i-download"]), .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #f1f6fd; --tint-border: #d9e6f6; --chip-bg: #dde9f8; --chip-fg: #2f6fae; }
.card:has(> h2 > .ic use[href$="#i-clients"]), .card:has(> h2 > .ic use[href$="#i-wallet"]), .card:has(> h2 > .ic use[href$="#i-phone"]), .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #f7f2fc; --tint-border: #e7ddf5; --chip-bg: #ece2f8; --chip-fg: #7a4fb0; }
.card:has(> h2 > .ic use[href$="#i-bell"]), .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #fdf5f0; --tint-border: #f5e1d5; --chip-bg: #fbe5d8; --chip-fg: #bb5b31; }
.card:has(> h2 > .ic use[href$="#i-deadlines"]), .card:has(> h2 > .ic use[href$="#i-server"]), .card:has(> h2 > .ic use[href$="#i-chart"]), .card:has(> h2 > .ic use[href$="#i-pulse"]), .card:has(> h2 > .ic use[href$="#i-projects"]), .card:has(> h2 > .ic use[href$="#i-settings"]), .card:has(> h2 > .ic use[href$="#i-lock"]), .card:has(> h2 > .ic use[href$="#i-admin"]), .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #fbf8f0; --tint-border: #efe6d0; --chip-bg: #f4ead2; --chip-fg: #8f6a1e; }

:root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-check"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #36443f; --tint-border: #47584f; --chip-bg: #3f5a4f; --chip-fg: #9fdcc4; }
:root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-send"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-info"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-download"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #363f49; --tint-border: #46525f; --chip-bg: #3c4d61; --chip-fg: #a6c8ee; }
:root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #3d3a47; --tint-border: #4d495a; --chip-bg: #4a4360; --chip-fg: #cdb6ef; }
:root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #463c38; --tint-border: #584b45; --chip-bg: #5a463d; --chip-fg: #f2b79c; }
:root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-server"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #433f37; --tint-border: #554f44; --chip-bg: #564d3b; --chip-fg: #e6cf98; }
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-check"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #36443f; --tint-border: #47584f; --chip-bg: #3f5a4f; --chip-fg: #9fdcc4; }
  :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-send"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-info"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-download"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #363f49; --tint-border: #46525f; --chip-bg: #3c4d61; --chip-fg: #a6c8ee; }
  :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #3d3a47; --tint-border: #4d495a; --chip-bg: #4a4360; --chip-fg: #cdb6ef; }
  :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #463c38; --tint-border: #584b45; --chip-bg: #5a463d; --chip-fg: #f2b79c; }
  :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-server"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #433f37; --tint-border: #554f44; --chip-bg: #564d3b; --chip-fg: #e6cf98; }
}

.card { background: var(--tint-bg, var(--surface)); border-color: var(--tint-border, var(--line)); }
.card-bad { --tint-bg: var(--bad-bg); --chip-bg: var(--surface); --chip-fg: var(--bad); }
/* Иконка заголовка блока — в цветной плашке. */
h2 > .ic:first-child {
  width: 30px; height: 30px; padding: 6px; margin-right: 10px; vertical-align: -9px; box-sizing: border-box;
  border-radius: 9px; background: var(--chip-bg, var(--accent-soft)); color: var(--chip-fg, var(--accent));
}
.card-bad h2 > .ic:first-child { color: var(--bad); }
/* Главный заголовок страницы — иконка в цвете пространства. */
h1 > .ic:first-child {
  width: 44px; height: 44px; padding: 9px; margin-right: 12px; vertical-align: -10px; box-sizing: border-box;
  border-radius: 13px; background: var(--accent); color: var(--accent-text);
}
/* Лёгкий оттенок цвета пространства сверху страницы. */
body { background: linear-gradient(180deg, var(--accent-soft) 0, var(--bg) 360px) no-repeat, var(--bg); }
.stat { background: var(--surface); }
.stat-good { --chip: var(--good); background: var(--good-bg); border-color: transparent; }
.stat-bad { background: var(--bad-bg); }
/* Записи студии: состояние — оттенком карточки. */
.booking.booking-confirmed { background: var(--surface); background: color-mix(in srgb, var(--accent-soft) 55%, var(--surface)); }
.booking.booking-done { background: var(--good-bg); }
.booking.booking-no_show { background: var(--bad-bg); }
.week-day.cal-today { --tint-bg: var(--accent-soft); --tint-border: var(--accent); }

/* --- Палитра студии: роза + мята (как в логотипе) для пространств с цветом «Пудровая роза» и «Мята». --- */
:root.accent-rose .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-today"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #f1faf6; --tint-border: #d8efe5; --chip-bg: #dcf2e9; --chip-fg: #2e8a6c; }
:root.accent-rose .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-offline"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #fdf2f6; --tint-border: #f5dbe5; --chip-bg: #f9e0ea; --chip-fg: #b4436c; }
:root.accent-rose .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-key"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #eff8f7; --tint-border: #d3ebe8; --chip-bg: #d6efec; --chip-fg: #1f7f7a; }
:root.accent-rose .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-upload"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #fdf1f0; --tint-border: #f5d9d6; --chip-bg: #fadcda; --chip-fg: #b8465a; }
:root.accent-rose .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-rose .card:has(> h2 > .ic use[href$="#i-inbox"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-mint .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #faf5f6; --tint-border: #ecdfe3; --chip-bg: #f2e4e9; --chip-fg: #8e5a6c; }
:root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-today"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #36443f; --tint-border: #47584f; --chip-bg: #3f5a4f; --chip-fg: #9fdcc4; }
:root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-offline"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #46393f; --tint-border: #5a4750; --chip-bg: #5e4552; --chip-fg: #f0a6bf; }
:root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-key"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #354544; --tint-border: #46595a; --chip-bg: #3d5a59; --chip-fg: #95d8d2; }
:root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-upload"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #473a3a; --tint-border: #5a4949; --chip-bg: #5f4446; --chip-fg: #f3a9b2; }
:root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-rose[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-inbox"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-mint[data-theme="dark"] .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #423b3e; --tint-border: #54494e; --chip-bg: #574a50; --chip-fg: #dcbac6; }
@media (prefers-color-scheme: dark) {
  :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-today"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clock"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-check"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-today"]) { --tint-bg: #36443f; --tint-border: #47584f; --chip-bg: #3f5a4f; --chip-fg: #9fdcc4; }
  :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-offline"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-tasks"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-calendar"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-send"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-info"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-download"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-offline"]) { --tint-bg: #46393f; --tint-border: #5a4750; --chip-bg: #5e4552; --chip-fg: #f0a6bf; }
  :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-key"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-clients"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-wallet"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-phone"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-key"]) { --tint-bg: #354544; --tint-border: #46595a; --chip-bg: #3d5a59; --chip-fg: #95d8d2; }
  :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-upload"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-bell"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-upload"]) { --tint-bg: #473a3a; --tint-border: #5a4949; --chip-bg: #5f4446; --chip-fg: #f3a9b2; }
  :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-rose[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-inbox"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-deadlines"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-server"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-chart"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-pulse"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-projects"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-settings"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-lock"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-admin"]), :root.accent-mint[data-theme="auto"] .card:has(> h2 > .ic use[href$="#i-inbox"]) { --tint-bg: #423b3e; --tint-border: #54494e; --chip-bg: #574a50; --chip-fg: #dcbac6; }
}

/* --- Бронь столов --- */
.hall-columns { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); align-items: start; margin-top: 12px; }
.resv { border-top: 1px solid var(--line); padding: 10px 0; display: grid; gap: 3px; }
.resv:first-of-type { border-top: 0; padding-top: 0; }
.resv-head { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.resv-time { font-weight: 700; }
.resv-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.resv-actions form, .resv-deposit { margin: 0; }
.resv-cancelled, .resv-no_show, .resv-done { opacity: .6; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; cursor: pointer; text-decoration: underline; }
.choice-list { display: grid; gap: 10px; }
.choice-hall { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.choice-hall legend { font-weight: 600; padding: 0 4px; }
.weekday { width: 28px; align-self: center; font-weight: 600; }
@media (max-width: 640px) {
  .hall-columns { grid-template-columns: 1fr; }
  .resv-actions .btn { min-height: 44px; padding: 10px 14px; font-size: 15px; }
}
.hall-jump { display: flex; gap: 6px; overflow-x: auto; margin: 4px 0 4px; padding-bottom: 4px; scrollbar-width: none; }
.hall-jump .btn { white-space: nowrap; }
.hall-column { scroll-margin-top: 12px; }
@media (min-width: 900px) { .hall-jump { display: none; } }

/* Памятка броней: нумерованные шаги */
.help-steps { margin: 0; padding-left: 22px; display: grid; gap: 8px; }
.help-steps ul { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 4px; }

/* Неделя броней: залы × дни, таблица прокручивается вбок на телефоне */
.week-wrap { overflow-x: auto; padding: 0; }
.week-table { border-collapse: collapse; width: 100%; min-width: 640px; font-variant-numeric: tabular-nums; }
.week-table th, .week-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: center; vertical-align: top; }
.week-table th[scope="row"] { text-align: left; white-space: nowrap; }
.week-table thead a { color: inherit; text-decoration: none; }
.week-table .is-today { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.week-cell { display: grid; gap: 2px; justify-items: center; color: inherit; text-decoration: none; }
.week-count { font-weight: 700; font-size: 1.1em; }

/* Команда пространства */
.team-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; }
.team-who { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; }
.team-who strong { overflow-wrap: anywhere; }
.team-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.team-actions form { margin: 0; }
.team-pass summary { list-style: none; cursor: pointer; }
.team-pass summary::-webkit-details-marker { display: none; }
.team-pass[open] form { margin-top: 6px; }
.resv-by { font-size: .8em; }

/* Карточка клиентки студии */
.pre { white-space: pre-line; }
.actions-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 16px; }
.actions-row form { margin: 0; }
.health-link { display: block; color: inherit; text-decoration: none; }
.health-link:hover { border-color: var(--accent); }
.visits li { display: grid; gap: 4px; }
.visits p { margin: 0; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-top: 16px; }
.photo { margin: 0; display: grid; gap: 6px; min-width: 0; }
.photo img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 10px; background: var(--accent-soft); }
.photo figcaption { font-size: 13px; display: grid; gap: 2px; }
.photo form { margin: 0; }
.field-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: center; }
.field-edit { flex: 1 1 320px; flex-wrap: wrap; min-width: 0; }
.field-edit input[name="name"] { flex: 1 1 180px; min-width: 0; }
.field-edit textarea { flex: 1 1 100%; }
.field-tools { display: flex; gap: 4px; }
.field-tools form { margin: 0; }
@media (max-width: 520px) {
  .facts { grid-template-columns: 1fr; gap: 2px; }
  .facts dd { margin-bottom: 8px; }
}
.alert .ic { margin-right: 6px; vertical-align: -2px; }

/* Кнопки «Написать» в карточке клиента — цвета сервисов приглушены под тему */
.social-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.social { --brand: var(--accent); border-color: color-mix(in srgb, var(--brand) 55%, transparent);
          background: color-mix(in srgb, var(--brand) 14%, transparent); }
.social-telegram { --brand: #2aabee; }
.social-vk { --brand: #0077ff; }
.social-max { --brand: #8b5cf6; }
.social-whatsapp { --brand: #25d366; }
.socials-edit { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; min-width: 0; }
.socials-edit legend { font-weight: 600; margin-bottom: 4px; }
@media (max-width: 520px) { .social-buttons .btn { flex: 1 1 calc(50% - 8px); justify-content: center; } }

/* Заявки с сайта */
.nav-badge { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 4px;
             border-radius: 9px; background: var(--bad); color: #fff; font-size: 11px; font-weight: 700; line-height: 1; }
.btn-attention { border-color: var(--bad); }
.request-list { display: grid; gap: 12px; margin-bottom: 16px; }
.request { display: grid; gap: 6px; }
.request p { margin: 0; }
.request-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; align-items: center; }
.request-name { font-size: 1.1em; overflow-wrap: anywhere; }
.request-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; margin-top: 4px; }
.request-actions form { margin: 0; }
.btn-call { font-size: 1.05em; font-weight: 700; font-variant-numeric: tabular-nums; }
.request-decline summary { list-style: none; cursor: pointer; }
.request-decline summary::-webkit-details-marker { display: none; }
.request-decline[open] form { margin-top: 8px; flex-wrap: wrap; }
.request-booked, .request-declined { opacity: .85; }
.hook-url { overflow-wrap: anywhere; user-select: all; }
@media (max-width: 520px) { .request-actions .btn-call, .request-actions .btn-primary { flex: 1 1 100%; justify-content: center; } }

/* ================= Стили оформления пространства (Админка → «Стиль») ================= */

/* --- Нежный: косметология. Пудровая роза и мята, тонкие веточки на фоне, стекло карточек. --- */
:root.skin-beauty {
  --bg: #fcf6f8; --surface: rgba(255, 255, 255, 0.86); --surface-2: #f7edf1; --line: #f0dfe6;
  --muted: #8a7a81; --radius: 18px;
  --shadow: 0 1px 3px rgba(180, 67, 108, 0.05), 0 12px 32px rgba(46, 138, 108, 0.06);
  --rose: #c25a80; --rose-2: #e997b3; --mint: #3f9c7c; --mint-2: #a6e0ca;
}
:root.skin-beauty[data-theme="dark"] {
  --bg: #2b2528; --surface: rgba(58, 49, 54, 0.88); --surface-2: #463b41; --line: #574a51; --muted: #bba9b1;
  --rose: #f0a6bf; --rose-2: #c56e8f; --mint: #93dcc2; --mint-2: #3e7a66;
}
@media (prefers-color-scheme: dark) {
  :root.skin-beauty[data-theme="auto"] {
    --bg: #2b2528; --surface: rgba(58, 49, 54, 0.88); --surface-2: #463b41; --line: #574a51; --muted: #bba9b1;
    --rose: #f0a6bf; --rose-2: #c56e8f; --mint: #93dcc2; --mint-2: #3e7a66;
  }
}
:root.skin-beauty body {
  background:
    radial-gradient(900px 520px at -10% -10%, color-mix(in srgb, var(--rose-2) 32%, transparent), transparent 70%),
    radial-gradient(800px 560px at 110% 105%, color-mix(in srgb, var(--mint-2) 34%, transparent), transparent 70%),
    var(--bg);
  background-attachment: fixed;
}
:root.skin-beauty body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: url("skins/botanical.svg") 0 0 / 420px 420px repeat; opacity: 0.55;
}
:root.skin-beauty[data-theme="dark"] body::before { opacity: 0.22; }
@media (prefers-color-scheme: dark) { :root.skin-beauty[data-theme="auto"] body::before { opacity: 0.22; } }
:root.skin-beauty .card { border-radius: var(--radius); box-shadow: var(--shadow); backdrop-filter: blur(6px); }
:root.skin-beauty .topbar { background: color-mix(in srgb, var(--bg) 72%, transparent); }
:root.skin-beauty h1 { font-family: "Didot", "Bodoni 72", "Playfair Display", Georgia, serif; font-weight: 600; letter-spacing: 0; }
:root.skin-beauty .brand strong { font-family: "Didot", "Bodoni 72", Georgia, serif; font-weight: 700; letter-spacing: 0.02em; }
:root.skin-beauty h1 > .ic:first-child, :root.skin-beauty .brand-mark {
  background: linear-gradient(135deg, var(--rose) 0%, var(--rose-2) 55%, var(--mint-2) 100%); color: #fff;
}
:root.skin-beauty .btn { border-radius: 999px; }
:root.skin-beauty .btn-primary {
  background: linear-gradient(135deg, var(--rose), var(--rose-2)); border-color: transparent; color: #fff;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--rose) 28%, transparent);
}
:root.skin-beauty .btn:not(.btn-primary):not(.btn-danger):not(.social) {
  background: color-mix(in srgb, var(--mint-2) 22%, var(--surface)); border-color: color-mix(in srgb, var(--mint) 30%, var(--line));
}
:root.skin-beauty .btn-ghost:not(.btn-danger) { background: transparent; }
:root.skin-beauty nav.main-nav a.active { background: linear-gradient(135deg, color-mix(in srgb, var(--rose-2) 30%, var(--surface)), color-mix(in srgb, var(--mint-2) 30%, var(--surface))); }

/* --- Дерево: ресторан. Цвета сайта kplennica73.ru (карамель #b48454, янтарь #aa7213, крем #ffeabf). --- */
:root.skin-wood {
  --accent: #9a6418; --accent-soft: #f5e9d4; --accent-text: #fff8e8;
  --bg: #f8f3ea; --surface: #fffdf8; --surface-2: #f1e7d6; --line: #e6d8bf; --muted: #7d6a55;
  --wood: url("skins/wood.svg"); --wood-ink: #3e2610; --cream: #fff3d6;
}
:root.skin-wood[data-theme="dark"] {
  --accent: #e2b36a; --accent-soft: #4a3a28; --accent-text: #2a1c0e;
  --bg: #221b15; --surface: #2e251d; --surface-2: #3a2f25; --line: #4b3d30; --muted: #bba78c;
}
@media (prefers-color-scheme: dark) {
  :root.skin-wood[data-theme="auto"] {
    --accent: #e2b36a; --accent-soft: #4a3a28; --accent-text: #2a1c0e;
    --bg: #221b15; --surface: #2e251d; --surface-2: #3a2f25; --line: #4b3d30; --muted: #bba78c;
  }
}
/* Шапка — тёмный орех. */
:root.skin-wood .topbar {
  background: linear-gradient(rgba(38, 22, 9, 0.84), rgba(38, 22, 9, 0.88)), var(--wood) center / 640px 240px;
  border-bottom: 2px solid #aa7213; backdrop-filter: none;
}
:root.skin-wood .topbar .brand, :root.skin-wood .topbar .brand small { color: var(--cream); }
:root.skin-wood nav.main-nav a { color: #e9d6b4; }
:root.skin-wood nav.main-nav a:hover { color: #fff; background: rgba(255, 234, 191, 0.12); }
:root.skin-wood nav.main-nav a.active { color: #fff; background: rgba(255, 234, 191, 0.2); }
:root.skin-wood .topbar .theme-switch { background: rgba(255, 234, 191, 0.14); }
:root.skin-wood .topbar .theme-switch button { color: #e9d6b4; }
:root.skin-wood .topbar .theme-switch button[aria-pressed="true"] { background: rgba(255, 234, 191, 0.9); color: var(--wood-ink); }
:root.skin-wood .topbar .btn { background: rgba(255, 234, 191, 0.12); border-color: rgba(255, 234, 191, 0.3); color: var(--cream); text-shadow: none; }
:root.skin-wood .brand-mark, :root.skin-wood h1 > .ic:first-child {
  background: linear-gradient(rgba(120, 70, 20, 0.15), rgba(60, 30, 8, 0.3)), var(--wood) center / 320px 120px;
  color: var(--cream); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 2px 6px rgba(60, 30, 5, 0.25);
}
/* Кнопки — дерево: светлая берёза для обычных, карамельный орех для главных (как «ЗАБРОНИРОВАТЬ СТОЛ» на сайте). */
:root.skin-wood .btn:not(.btn-danger):not(.social) {
  background: linear-gradient(rgba(255, 246, 228, 0.72), rgba(255, 238, 205, 0.6)), var(--wood) center / 640px 240px;
  border: 1px solid #c9a676; color: var(--wood-ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), 0 1px 2px rgba(80, 45, 10, 0.18);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
}
:root.skin-wood .btn-primary:not(.btn-danger) {
  background: linear-gradient(rgba(190, 120, 40, 0.18), rgba(70, 35, 8, 0.32)), var(--wood) center / 640px 240px !important;
  border-color: #7a4a1c !important; color: #fff6df !important;
  text-transform: uppercase; letter-spacing: 0.06em; font-size: 13px;
  text-shadow: 0 1px 1px rgba(40, 18, 2, 0.55) !important;
  box-shadow: inset 0 1px 0 rgba(255, 230, 180, 0.35), 0 2px 6px rgba(70, 35, 5, 0.3) !important;
}
:root.skin-wood .btn:hover { filter: brightness(1.06) saturate(1.05); }
:root.skin-wood .btn-ghost:not(.btn-primary) { background: transparent; box-shadow: none; text-shadow: none; }
:root.skin-wood[data-theme="dark"] .btn:not(.btn-danger):not(.social):not(.btn-primary) {
  background: linear-gradient(rgba(40, 24, 10, 0.55), rgba(30, 18, 8, 0.65)), var(--wood) center / 640px 240px;
  border-color: #6b4b2c; color: #f3dfbd; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.4);
}
@media (prefers-color-scheme: dark) {
  :root.skin-wood[data-theme="auto"] .btn:not(.btn-danger):not(.social):not(.btn-primary) {
    background: linear-gradient(rgba(40, 24, 10, 0.55), rgba(30, 18, 8, 0.65)), var(--wood) center / 640px 240px;
    border-color: #6b4b2c; color: #f3dfbd; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.4);
  }
}
:root.skin-wood body { background: linear-gradient(180deg, color-mix(in srgb, #ffeabf 55%, var(--bg)) 0, var(--bg) 320px) no-repeat, var(--bg); }
:root.skin-wood[data-theme="dark"] body { background: var(--bg); }
:root.skin-wood .card { border-radius: 12px; }

/* --- Цветные иконки меню и заголовков в стилях «Нежный» и «Дерево»: у каждого раздела свой цвет. --- */
:root.skin-beauty, :root.skin-wood {
  --ic-today: #e08a1e; --ic-calendar: #d0456b; --ic-clock: #2e9a78; --ic-tasks: #5b6fd6; --ic-clients: #9b59c9;
  --ic-settings: #6f7f8f; --ic-inbox: #e0583a; --ic-projects: #2f8bc9; --ic-deadlines: #c7871e; --ic-wallet: #2f9d6b;
  --ic-admin: #6a5acd; --ic-chart: #2f8bc9;
}
:root.skin-beauty { --ic-calendar: #c25a80; --ic-clock: #3f9c7c; --ic-clients: #a05ab8; --ic-today: #e39a6a; --ic-tasks: #7c86d6; }
:root.skin-wood { --ic-calendar: #b5452f; --ic-today: #d18a1a; --ic-tasks: #4f7a4a; --ic-clients: #8a5a2b; }
:is(.skin-beauty, .skin-wood) nav.main-nav a .ic { opacity: 1; }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-today"]) { color: var(--ic-today); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-calendar"]) { color: var(--ic-calendar); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-clock"]) { color: var(--ic-clock); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-tasks"]) { color: var(--ic-tasks); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-clients"]) { color: var(--ic-clients); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-settings"]) { color: var(--ic-settings); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-inbox"]) { color: var(--ic-inbox); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-projects"]) { color: var(--ic-projects); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-deadlines"]) { color: var(--ic-deadlines); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-wallet"]) { color: var(--ic-wallet); }
:is(.skin-beauty, .skin-wood) .ic:has(use[href$="#i-chart"]) { color: var(--ic-chart); }
:is(.skin-wood) .topbar nav.main-nav .ic { filter: brightness(1.35) saturate(1.1); }
/* В кнопках и в плашке главного заголовка цвет иконки — от кнопки. */
:is(.skin-beauty, .skin-wood) .btn .ic, :is(.skin-beauty, .skin-wood) h1 > .ic:first-child { color: inherit; }
:is(.skin-beauty, .skin-wood) h1 > .ic:first-child { color: #fff; }
:root.skin-wood h1 > .ic:first-child { color: var(--cream); }

/* --- Погода на «Сегодня» --- */
.weather {
  display: grid; grid-template-columns: auto 1fr auto; gap: 14px 22px; align-items: center;
  padding: 16px 20px; margin-bottom: 18px; border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(120deg, color-mix(in srgb, #ffd98a 26%, var(--surface)), color-mix(in srgb, #9fd3f5 24%, var(--surface)));
  box-shadow: var(--shadow);
}
:root.skin-beauty .weather { background: linear-gradient(120deg, color-mix(in srgb, var(--rose-2) 22%, var(--surface)), color-mix(in srgb, var(--mint-2) 30%, var(--surface))); }
:root.skin-wood .weather { background: linear-gradient(120deg, color-mix(in srgb, #ffeabf 60%, var(--surface)), var(--surface)); }
.weather-now { display: flex; align-items: center; gap: 12px; }
.weather-icon { width: 64px; height: 64px; flex-shrink: 0; filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.08)); }
.weather-temp { font-size: 34px; font-weight: 700; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.weather-text { color: var(--muted); font-size: 13px; margin-top: 4px; }
.weather-info { min-width: 0; display: grid; gap: 6px; }
.weather-city { font-weight: 600; }
.weather-facts { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--muted); }
.weather-facts span { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.weather-mini { width: 16px; height: 16px; }
.weather-days { list-style: none; margin: 0; padding: 0; display: flex; gap: 10px; }
.weather-days li { display: grid; justify-items: center; gap: 2px; padding: 6px 8px; border-radius: 12px;
  background: color-mix(in srgb, var(--surface) 70%, transparent); min-width: 58px; }
.weather-day-icon { width: 30px; height: 30px; }
@media (max-width: 720px) {
  .weather { grid-template-columns: minmax(0, 1fr); padding: 14px 16px; gap: 12px; }
  .weather-days { grid-column: 1 / -1; justify-content: space-between; }
  .weather-days li { flex: 1; }
}
.page-head .actions { flex-wrap: wrap; }
/* Дерево: карточки — тёплая бумага, без холодных оттенков блоков. */
:root.skin-wood .card { --tint-bg: var(--surface) !important; --tint-border: var(--line) !important; }
:root.skin-wood .card h2 > .ic:first-child { background: color-mix(in srgb, #ffeabf 70%, var(--surface)); }
:root.skin-wood[data-theme="dark"] .card h2 > .ic:first-child { background: var(--surface-2); }
.weather-more { margin-left: 8px; font-weight: 500; white-space: nowrap; }
/* Компактная погода (по отзыву): меньше высота, прогноз на 3 дня — одной строкой. */
.weather { padding: 10px 14px; gap: 6px 16px; margin-bottom: 14px; }
.weather-icon { width: 46px; height: 46px; }
.weather-temp { font-size: 26px; }
.weather-text { font-size: 12px; margin-top: 2px; }
.weather-info { gap: 3px; }
.weather-city { font-size: 14px; }
.weather-facts { font-size: 12px; gap: 2px 12px; }
.weather-mini { width: 14px; height: 14px; }
.weather-days { gap: 6px; }
.weather-days li { display: flex; align-items: center; gap: 4px; padding: 3px 8px; min-width: 0; border-radius: 999px; }
.weather-day-icon { width: 22px; height: 22px; }
@media (max-width: 720px) {
  .weather { grid-template-columns: auto minmax(0, 1fr); padding: 10px 12px; gap: 6px 12px; }
  .weather-now { grid-row: 1; }
  .weather-info { grid-row: 1; }
  .weather-text { display: none; }
  .weather-days { grid-column: 1 / -1; }
  .weather-days li { flex: 1; justify-content: center; }
}
.weather-days li > span { white-space: nowrap; }
@media (max-width: 720px) {
  .weather-extra { display: none !important; }
  .weather-city { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; }
  .weather-more { margin-left: 0; }
  .weather-days li { font-size: 12px; padding: 2px 6px; }
}

/* Фото клиентки */
.avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; flex-shrink: 0; vertical-align: middle;
  background: var(--accent-soft); }
.avatar-empty { display: inline-grid; place-items: center; font-weight: 700; font-size: 13px; color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, var(--surface)); }
.avatar-lg { width: 52px; height: 52px; margin-right: 12px; vertical-align: -12px; box-shadow: 0 0 0 3px var(--surface), 0 2px 8px rgba(0,0,0,.12); }
.avatar-xl { width: 96px; height: 96px; font-size: 34px; }
:root.skin-beauty .avatar-empty { background: linear-gradient(135deg, color-mix(in srgb, var(--rose-2) 45%, var(--surface)), color-mix(in srgb, var(--mint-2) 45%, var(--surface))); color: var(--rose); }
.client-link { display: inline-flex; align-items: center; gap: 8px; }
.avatar-edit { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.avatar-actions { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.avatar-actions form { margin: 0; }
.avatar-actions .hint:empty { display: none; }
.file-btn { position: relative; overflow: hidden; cursor: pointer; }
.file-btn input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

/* --- Штаб: главный адрес ProfiSkills. Глубокий синий, бирюзовое свечение, шапка — ночная панель. --- */
.brand-logo-own { background: transparent; }
:root.skin-pro {
  --accent: #1d4ed8; --accent-soft: #e4ebfd; --accent-text: #ffffff;
  --bg: #f3f6fc; --surface: #ffffff; --surface-2: #eaf0fb; --line: #dde5f4; --muted: #66728f;
  --navy: #0b1230; --navy-2: #1d3a9e; --cyan: #22d3ee; --mint-dot: #6ee7b7;
}
:root.skin-pro[data-theme="dark"] {
  --accent: #60a5fa; --accent-soft: #1e2a4a; --accent-text: #0b1230;
  --bg: #0d1326; --surface: #151d35; --surface-2: #1e2844; --line: #2a3657; --muted: #9aa7c7;
}
@media (prefers-color-scheme: dark) {
  :root.skin-pro[data-theme="auto"] {
    --accent: #60a5fa; --accent-soft: #1e2a4a; --accent-text: #0b1230;
    --bg: #0d1326; --surface: #151d35; --surface-2: #1e2844; --line: #2a3657; --muted: #9aa7c7;
  }
}
:root.skin-pro body {
  background:
    radial-gradient(700px 380px at 100% -5%, color-mix(in srgb, var(--cyan) 18%, transparent), transparent 70%),
    radial-gradient(800px 420px at -10% -10%, color-mix(in srgb, var(--navy-2) 16%, transparent), transparent 70%),
    var(--bg);
  background-attachment: fixed;
}
:root.skin-pro .topbar {
  background: linear-gradient(100deg, rgba(11, 18, 48, 0.96), rgba(29, 58, 158, 0.94));
  border-bottom: 1px solid rgba(34, 211, 238, 0.35); backdrop-filter: saturate(140%) blur(10px);
}
:root.skin-pro .topbar .brand, :root.skin-pro .topbar .brand small { color: #eef3ff; }
:root.skin-pro .topbar .brand small { opacity: 0.7; }
:root.skin-pro nav.main-nav a { color: #b9c6ea; }
:root.skin-pro nav.main-nav a:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
:root.skin-pro nav.main-nav a.active { color: #fff; background: rgba(34, 211, 238, 0.18); box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.35); }
:root.skin-pro .topbar .theme-switch { background: rgba(255, 255, 255, 0.08); }
:root.skin-pro .topbar .theme-switch button { color: #b9c6ea; }
:root.skin-pro .topbar .theme-switch button[aria-pressed="true"] { background: rgba(255, 255, 255, 0.92); color: var(--navy); }
:root.skin-pro .topbar .btn, :root.skin-pro .topbar select { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.18); color: #eef3ff; }
:root.skin-pro .topbar .ws-name { color: #b9c6ea; }
:root.skin-pro .card { border-radius: 16px; box-shadow: 0 1px 2px rgba(11, 18, 48, 0.05), 0 8px 24px rgba(29, 58, 158, 0.06); }
:root.skin-pro .btn-primary {
  background: linear-gradient(120deg, #2563eb, #06b6d4); border-color: transparent; color: #fff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.28);
}
:root.skin-pro h1 > .ic:first-child, :root.skin-pro .brand-mark {
  background: linear-gradient(135deg, var(--navy-2), #0891b2); color: #fff;
}
:root.skin-pro .weather { background: linear-gradient(120deg, color-mix(in srgb, #93c5fd 26%, var(--surface)), color-mix(in srgb, var(--cyan) 18%, var(--surface))); }
/* цветные иконки разделов — как в стилях клиентов */
:root.skin-pro {
  --ic-today: #f59e0b; --ic-calendar: #ec4899; --ic-clock: #10b981; --ic-tasks: #6366f1; --ic-clients: #a855f7;
  --ic-settings: #94a3b8; --ic-inbox: #f97316; --ic-projects: #38bdf8; --ic-deadlines: #eab308; --ic-wallet: #22c55e;
  --ic-chart: #38bdf8;
}
.skin-pro nav.main-nav a .ic { opacity: 1; }
.skin-pro .ic:has(use[href$="#i-today"]) { color: var(--ic-today); }
.skin-pro .ic:has(use[href$="#i-calendar"]) { color: var(--ic-calendar); }
.skin-pro .ic:has(use[href$="#i-clock"]) { color: var(--ic-clock); }
.skin-pro .ic:has(use[href$="#i-tasks"]) { color: var(--ic-tasks); }
.skin-pro .ic:has(use[href$="#i-clients"]) { color: var(--ic-clients); }
.skin-pro .ic:has(use[href$="#i-settings"]) { color: var(--ic-settings); }
.skin-pro .ic:has(use[href$="#i-inbox"]) { color: var(--ic-inbox); }
.skin-pro .ic:has(use[href$="#i-projects"]) { color: var(--ic-projects); }
.skin-pro .ic:has(use[href$="#i-deadlines"]) { color: var(--ic-deadlines); }
.skin-pro .ic:has(use[href$="#i-wallet"]) { color: var(--ic-wallet); }
.skin-pro .ic:has(use[href$="#i-chart"]), .skin-pro .ic:has(use[href$="#i-server"]), .skin-pro .ic:has(use[href$="#i-pulse"]) { color: var(--ic-chart); }
.skin-pro .btn .ic, .skin-pro h1 > .ic:first-child { color: inherit; }
.skin-pro h1 > .ic:first-child { color: #fff; }
:root.skin-pro[data-theme="dark"] .card:not(.card-bad) { --tint-bg: var(--surface) !important; --tint-border: var(--line) !important; }
@media (prefers-color-scheme: dark) {
  :root.skin-pro[data-theme="auto"] .card:not(.card-bad) { --tint-bg: var(--surface) !important; --tint-border: var(--line) !important; }
}
:root.skin-pro[data-theme="dark"] .card h2 > .ic:first-child { background: var(--surface-2); }
@media (prefers-color-scheme: dark) { :root.skin-pro[data-theme="auto"] .card h2 > .ic:first-child { background: var(--surface-2); } }

/* --- Хлебные крошки: на странице раздела — метка с цветной точкой, на вложенной — кнопка «‹ Раздел». --- */
.eyebrow {
  display: flex; align-items: center; gap: 8px; margin: 0 0 10px; min-width: 0;
  font-size: 11.5px; font-weight: 650; letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted);
}
.eyebrow::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; background: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}
.eyebrow:has(a)::before { display: none; }
.eyebrow a {
  display: inline-flex; align-items: center; gap: 7px; max-width: 100%; min-height: 30px;
  padding: 4px 13px 4px 11px; border-radius: 999px; color: var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--line));
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: background 0.15s;
}
.eyebrow a::before {
  content: ""; width: 6px; height: 6px; flex-shrink: 0; margin-left: 2px;
  border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg);
}
.eyebrow a:hover { text-decoration: none; background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
/* стили пространств */
:root.skin-beauty .eyebrow::before { background: linear-gradient(135deg, var(--rose), var(--mint)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--rose-2) 30%, transparent); }
:root.skin-beauty .eyebrow a { color: var(--rose); background: color-mix(in srgb, var(--rose-2) 16%, var(--surface)); border-color: color-mix(in srgb, var(--rose-2) 40%, var(--line)); }
:root.skin-wood .eyebrow { color: #8a6a44; }
:root.skin-wood .eyebrow::before { background: #aa7213; box-shadow: 0 0 0 3px rgba(170, 114, 19, 0.2); }
:root.skin-wood .eyebrow a {
  color: #4a2f14; border-color: #c9a676; text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
  background: linear-gradient(rgba(255, 246, 228, 0.72), rgba(255, 238, 205, 0.6)), var(--wood) center / 640px 240px;
}
:root.skin-wood[data-theme="dark"] .eyebrow a { color: #f3dfbd; border-color: #6b4b2c; text-shadow: none;
  background: linear-gradient(rgba(40, 24, 10, 0.55), rgba(30, 18, 8, 0.65)), var(--wood) center / 640px 240px; }
:root.skin-pro .eyebrow::before { background: var(--cyan); box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.22), 0 0 10px rgba(34, 211, 238, 0.6); }
:root.skin-pro .eyebrow a { color: var(--accent); }

/* «Подробная задача» — под быстрым добавлением */
.quick-more { margin: -8px 0 0; display: flex; justify-content: flex-end; }

/* --- Календарь: записи студии и брони столов рядом с задачами --- */
.cal-ev {
  display: block; font-size: 12px; line-height: 1.3; padding: 3px 6px; margin-bottom: 3px; border-radius: 6px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text);
  background: color-mix(in srgb, var(--ev) 14%, var(--surface)); border-left: 3px solid var(--ev);
}
.cal-ev:hover { text-decoration: none; filter: brightness(0.97); }
.cal-ev .mono { font-weight: 600; color: color-mix(in srgb, var(--ev) 75%, var(--text)); }
.ev-sub { color: var(--muted); }
.ev-booking { --ev: #c25a80; }
.ev-reservation { --ev: #b5452f; }
.ev-banquet { --ev: #aa7213; font-weight: 600; }
.ev-done, .ev-seated { opacity: 0.7; }
.cal-more { display: block; font-size: 11px; color: var(--muted); padding: 0 6px 3px; }
.cal-legend { display: flex; flex-wrap: wrap; gap: 6px; margin: -4px 0 10px; }
.cal-legend > * { display: inline-block; margin: 0; font-size: 12px; cursor: default; }
.week-day .cal-ev { white-space: normal; }
@media (max-width: 720px) { .cal-ev { font-size: 11px; padding: 2px 4px; } }

/* --- Программы и абонементы --- */
.program-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-bottom: 16px; }
.tier-list { list-style: none; margin: 8px 0; padding: 0; display: grid; gap: 4px; }
.program-edit summary, .sub-new summary { list-style: none; cursor: pointer; }
.program-edit summary::-webkit-details-marker, .sub-new summary::-webkit-details-marker { display: none; }
.program-edit[open] form, .sub-new[open] form { margin-top: 10px; }
.sub-progress { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; margin-bottom: 12px; }
.sub-progress span { height: 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); }
.sub-progress .is-done { background: var(--accent); border-color: var(--accent); }
.sub-progress .is-planned { background: color-mix(in srgb, var(--accent) 30%, var(--surface)); border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
:root.skin-beauty .sub-progress .is-done { background: linear-gradient(90deg, var(--rose), var(--rose-2)); border-color: transparent; }
.sub-progress-sm { margin: 6px 0 4px; }
.sub-progress-sm span { height: 6px; }
.sub-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.sub-facts div { display: grid; gap: 2px; }
.sub-facts strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.sub-facts span { font-size: 12px; color: var(--muted); }
.sub-facts .is-warn strong { color: var(--warn); }
.sub-facts .is-bad strong, .text-bad { color: var(--bad); }
.sub-facts .is-good span { color: var(--good); }
.sub-visits { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.sub-visits li { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.sub-num { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; font-weight: 700; font-size: 12px;
  background: var(--accent-soft); color: var(--accent); flex-shrink: 0; }
.sub-row { display: grid; gap: 2px; padding: 10px 0; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.sub-row:hover { text-decoration: none; }
.sub-row:last-of-type { margin-bottom: 10px; }
.weekday-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span { display: inline-block; min-width: 42px; text-align: center; padding: 6px 10px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface); cursor: pointer; font-weight: 600; font-size: 13px; }
.chip input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.sub-plan { margin-top: 14px; }
.sub-plan-row { display: grid; grid-template-columns: auto minmax(0, 1.3fr) minmax(0, 1fr); gap: 8px; align-items: center; }
.sub-plan-row .small { grid-column: 2 / -1; margin-top: -4px; }
.sub-plan-row input[type="checkbox"] { width: 20px; height: 20px; }
.course-badge { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; font-size: 12px; font-weight: 600;
  padding: 2px 9px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); width: fit-content; }
.course-badge:hover { text-decoration: none; }
.course-badge .ic { width: 13px !important; height: 13px !important; }
.no-show-ask { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; width: 100%; padding: 8px; border-radius: 10px; background: var(--warn-bg); }
.no-show-ask form { margin: 0; }
.pay-form { margin-top: 8px; flex-wrap: wrap; }
.sub-facts strong small { font-size: 13px; font-weight: 500; color: var(--muted); }

/* Прайс по категориям */
.price-group { display: flex; align-items: center; gap: 8px; margin: 18px 0 8px; font-size: 13px; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--muted); }
.price-group:first-of-type { margin-top: 4px; }
h2.price-group { font-size: 13px; }
.service-item { border-bottom: 1px solid var(--line); }
.service-item summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; }
.service-item summary::-webkit-details-marker { display: none; }
.service-meta { color: var(--muted); font-size: 13px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.service-item[open] summary { font-weight: 600; }
.service-item form { padding-bottom: 12px; }
.course-note { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; border-radius: 12px;
  background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.sub-visit-btn { margin: -4px 0 10px; }

/* ================= Школа ================= */
.school-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; margin: -4px 0 14px; padding-bottom: 2px; }
.school-tabs::-webkit-scrollbar { display: none; }
.school-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 999px; white-space: nowrap;
  color: var(--muted); font-weight: 600; font-size: 14px; border: 1px solid var(--line); background: var(--surface); }
.school-tabs a:hover { text-decoration: none; color: var(--text); }
.school-tabs a.is-active { color: var(--accent-text); background: var(--accent); border-color: var(--accent); }
.school-tabs .ic { width: 16px; height: 16px; }
.lesson-list, .student-list, .pay-list { display: grid; gap: 10px; margin-bottom: 16px; }
.lesson { display: grid; grid-template-columns: auto 1fr; gap: 14px; color: inherit; text-decoration: none; align-items: start; }
.lesson:hover { text-decoration: none; border-color: var(--accent); }
.lesson-time { font-size: 20px; font-weight: 700; line-height: 1.1; }
.lesson-time span { display: block; font-size: 12px; font-weight: 500; color: var(--muted); }
.lesson-body { display: grid; gap: 4px; min-width: 0; }
.lesson.is-cancelled { opacity: 0.6; }
.lesson-head { margin: -6px 0 14px; color: var(--muted); }
.attendance h2 { margin-bottom: 6px; }
.att-row { border: 0; border-bottom: 1px solid var(--line); margin: 0; padding: 10px 0; display: flex; flex-wrap: wrap; gap: 8px 12px;
  align-items: center; justify-content: space-between; min-width: 0; }
.att-row legend { float: left; display: inline-flex; align-items: center; gap: 8px; padding: 0; font-weight: 600; }
.att-row legend a { color: inherit; }
.att-choice { display: flex; gap: 6px; }
.att-opt { position: relative; }
.att-opt input { position: absolute; opacity: 0; pointer-events: none; }
.att-opt span { display: inline-block; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  font-size: 13px; font-weight: 600; cursor: pointer; min-width: 64px; text-align: center; }
.att-opt input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.att-present input:checked + span { background: var(--good); border-color: var(--good); color: #fff; }
.att-absent input:checked + span { background: var(--bad); border-color: var(--bad); color: #fff; }
.att-sick input:checked + span { background: var(--warn); border-color: var(--warn); color: #fff; }
.attendance .actions { margin-top: 14px; flex-wrap: wrap; }
.att-grid-wrap { overflow-x: auto; }
.att-grid { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
.att-grid th, .att-grid td { padding: 6px 6px; border-bottom: 1px solid var(--line); text-align: center; font-size: 13px; }
.att-grid th[scope="row"] { text-align: left; white-space: nowrap; font-weight: 600; }
.att-grid thead a { color: var(--muted); font-weight: 500; font-size: 11px; }
.att-cell { font-size: 15px; }
.att-present { color: var(--good); } .att-absent { color: var(--bad); } .att-sick { color: var(--warn); } .att-none { color: var(--line); }
.att-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 8px; background: currentColor; }
.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; margin-bottom: 16px; }
.group-card { display: grid; gap: 4px; color: inherit; text-decoration: none; }
.group-card:hover { text-decoration: none; border-color: var(--accent); }
.group-fill { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.add-member { margin-top: 12px; flex-wrap: wrap; }
.add-member select { flex: 1 1 180px; min-width: 0; }
.student-row { display: flex; gap: 12px; align-items: center; color: inherit; text-decoration: none; padding-block: 12px; }
.student-row:hover { text-decoration: none; border-color: var(--accent); }
.student-main { display: grid; gap: 2px; min-width: 0; }
.student-groups { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.avatar-md { width: 44px; height: 44px; font-size: 17px; }
.pay-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 14px; align-items: center; }
.pay-who { display: grid; gap: 2px; min-width: 0; }
.pay-sum { display: grid; justify-items: end; gap: 2px; font-variant-numeric: tabular-nums; }
.pay-actions { grid-column: 1 / -1; display: flex; gap: 6px; justify-content: flex-end; }
.pay-actions form { margin: 0; }
.pay-row.is-overdue { border-color: color-mix(in srgb, var(--bad) 45%, var(--line)); }
.ev-lesson { --ev: #b7aaff; }
.ev-cancelled { text-decoration: line-through; opacity: 0.6; }
a.stat { color: inherit; text-decoration: none; }

/* --- Луна: тёмная сцена, как сайт ULA.DANCE.FAMILY (один вид в обеих темах) --- */
:root.skin-luna, :root.skin-luna[data-theme] {
  --bg: #0d0c10; --surface: #17161c; --surface-2: #221f29; --line: rgba(236, 232, 242, 0.14);
  --text: #f4f1f6; --muted: #a9a5b2; --accent: #f2445c; --accent-soft: #2a1a20; --accent-text: #ffffff;
  --lilac: #b7aaff; --good: #4fd1a0; --good-bg: #16302a; --bad: #ff7a8a; --bad-bg: #3a1c22; --warn: #f4c06a; --warn-bg: #3a3020;
  --radius: 18px; --shadow: none; color-scheme: dark;
}
:root.skin-luna body {
  background:
    radial-gradient(700px 420px at 85% -10%, rgba(183, 170, 255, 0.16), transparent 70%),
    radial-gradient(640px 400px at -10% 0%, rgba(242, 68, 92, 0.14), transparent 70%), var(--bg);
  background-attachment: fixed;
}
:root.skin-luna .card { --tint-bg: var(--surface) !important; --tint-border: var(--line) !important; border-radius: var(--radius); }
:root.skin-luna .card h2 > .ic:first-child { background: var(--surface-2); color: var(--lilac); }
:root.skin-luna .topbar { background: rgba(13, 12, 16, 0.86); border-bottom-color: var(--line); }
:root.skin-luna h1 { font-family: "Prata", "Didot", "Bodoni 72", Georgia, serif; font-weight: 400; letter-spacing: 0.01em; }
:root.skin-luna .brand strong { letter-spacing: 0.12em; text-transform: uppercase; font-size: 13px; }
:root.skin-luna h1 > .ic:first-child, :root.skin-luna .brand-mark { background: linear-gradient(135deg, #f2445c, #b7aaff); color: #fff; }
:root.skin-luna .btn { border-radius: 999px; background: var(--surface-2); border-color: var(--line); color: var(--text); }
:root.skin-luna .btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 6px 20px rgba(242, 68, 92, 0.28); }
:root.skin-luna .btn-ghost { background: transparent; }
:root.skin-luna nav.main-nav a.active { background: var(--surface-2); color: var(--text); }
:root.skin-luna .theme-switch { display: none; }
:root.skin-luna input, :root.skin-luna select, :root.skin-luna textarea { background: var(--surface-2); color: var(--text); border-color: var(--line); }
:root.skin-luna .eyebrow::before { background: var(--accent); box-shadow: 0 0 0 3px rgba(242, 68, 92, 0.25), 0 0 12px rgba(242, 68, 92, 0.5); }
:root.skin-luna .eyebrow a { color: var(--lilac); background: rgba(183, 170, 255, 0.1); border-color: rgba(183, 170, 255, 0.3); }
:root.skin-luna .school-tabs a.is-active { background: var(--accent); }
:root.skin-luna .badge-good { background: var(--good-bg); color: var(--good); }
:root.skin-luna .badge-warn { background: var(--warn-bg); color: var(--warn); }
:root.skin-luna .badge-bad { background: var(--bad-bg); color: var(--bad); }
:root.skin-luna .alert { background: var(--surface-2); color: var(--text); }
:root.skin-luna .stat { background: var(--surface); border-color: var(--line); }
:root.skin-luna {
  --ic-today: #f4c06a; --ic-calendar: #f2445c; --ic-clock: #4fd1a0; --ic-tasks: #b7aaff; --ic-clients: #e7b3cf;
  --ic-settings: #a9a5b2; --ic-inbox: #ff9f6b; --ic-wallet: #4fd1a0;
}
.skin-luna nav.main-nav a .ic { opacity: 1; }
.skin-luna .ic:has(use[href$="#i-today"]) { color: var(--ic-today); }
.skin-luna .ic:has(use[href$="#i-calendar"]) { color: var(--ic-calendar); }
.skin-luna .ic:has(use[href$="#i-clock"]) { color: var(--ic-clock); }
.skin-luna .ic:has(use[href$="#i-tasks"]) { color: var(--ic-tasks); }
.skin-luna .ic:has(use[href$="#i-clients"]) { color: var(--ic-clients); }
.skin-luna .ic:has(use[href$="#i-settings"]) { color: var(--ic-settings); }
.skin-luna .ic:has(use[href$="#i-inbox"]) { color: var(--ic-inbox); }
.skin-luna .ic:has(use[href$="#i-wallet"]) { color: var(--ic-wallet); }
.skin-luna .btn .ic, .skin-luna .school-tabs a.is-active .ic { color: inherit; }
.skin-luna h1 > .ic:first-child { color: #fff; }
:root.skin-luna a { color: #cfc6ff; }
.pay-who a { color: var(--text); }

/* Луна: шапка как на сайте — круглая эмблема со свечением и надпись Unbounded с красными точками */
@font-face { font-family: "Unbounded"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("fonts/unbounded-600-cyrillic.woff") format("woff");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Unbounded"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("fonts/unbounded-600-latin.woff") format("woff");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
                 U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
.brand-logo-wrap { display: inline-flex; flex-shrink: 0; }
:root.skin-luna .brand-logo-wrap { width: 40px; height: 40px; border-radius: 50%; overflow: hidden;
  box-shadow: 0 0 0 1px var(--line), 0 0 24px -4px rgba(242, 68, 92, 0.45); }
:root.skin-luna .brand-logo-wrap .brand-logo { width: 100%; height: 100%; border-radius: 0; background: transparent;
  object-fit: cover; transform: scale(1.42); }
:root.skin-luna .brand .wordmark { font-family: "Unbounded", "Arial Black", system-ui, sans-serif; font-weight: 600;
  font-size: 15px; letter-spacing: 0.06em; text-transform: none; white-space: nowrap; color: var(--text); }
:root.skin-luna .brand .wordmark i { font-style: normal; color: var(--accent); }
:root.skin-luna h1 { font-family: "Unbounded", "Arial Black", system-ui, sans-serif; font-weight: 600; letter-spacing: 0; font-size: 26px; }
@media (max-width: 400px) {
  :root.skin-luna .brand .wordmark { font-size: 12.5px; letter-spacing: 0.03em; }
  :root.skin-luna .brand-logo-wrap { width: 34px; height: 34px; }
}
:root.skin-luna .login-card .brand-logo-wrap { width: 52px; height: 52px; }
