:root {
  color-scheme: light;
  --font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: #f5f6f8; --surface: #fff; --surface-2: #f8f9fb; --surface-3: #eef0f3;
  --text: #17191d; --text-2: #5d626b; --text-3: #8a909a; --border: #dfe2e7;
  --accent: #f97316; --accent-hover: #ea580c; --accent-soft: #fff1e8; --accent-ink: #8f3208;
  --success: #16a36a; --success-soft: #e9f8f1; --warning: #d88906; --warning-soft: #fff6df;
  --danger: #dc3f4f; --danger-soft: #fff0f2; --focus: rgba(249,115,22,.35);
  --shadow-sm: 0 1px 2px rgba(15,18,24,.05); --shadow-md: 0 12px 30px rgba(15,18,24,.1);
  --radius-sm: 8px; --radius-md: 12px; --radius-lg: 16px; --radius-xl: 22px;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 20px; --space-6: 24px; --space-8: 32px;
  --sidebar-width: 248px; --sidebar-compact: 78px; --header-height: 68px;
  --gray-100: var(--surface-2); --gray-200: var(--border); --gray-400: var(--text-3); --gray-500: var(--text-3); --gray-600: var(--text-2); --gray-700: var(--text); --gray-900: var(--text);
  --spacing-xs: var(--space-1); --spacing-sm: var(--space-2); --spacing-md: var(--space-4); --spacing-lg: var(--space-6); --spacing-xl: var(--space-8);
}
:root[data-theme="dark"] { color-scheme: dark; --bg:#0f1012; --surface:#17181b; --surface-2:#1c1e22; --surface-3:#24272c; --text:#f4f5f6; --text-2:#a8adb6; --text-3:#747a84; --border:#2b2e34; --accent-soft:#331b0d; --accent-ink:#ffb27a; --success-soft:#102a20; --warning-soft:#30240c; --danger-soft:#321318; --shadow-sm:0 1px 2px rgba(0,0,0,.3); --shadow-md:0 18px 50px rgba(0,0,0,.35); }
* { box-sizing: border-box; }
html { font-family: var(--font-sans); background: var(--bg); color: var(--text); }
body { margin: 0; min-width: 320px; background: var(--bg); color: var(--text); -webkit-font-smoothing: antialiased; }
button,input,select,textarea { font: inherit; }

/* Общий подвал сайта */
.site-footer { border-top: 1px solid var(--border); background: var(--surface); color: var(--text-2); padding: 20px 24px; display: flex; flex-direction: column; gap: 8px; align-items: center; text-align: center; font-size: 13px; }
.site-footer__links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; }
.site-footer__links a { color: var(--text-2); text-decoration: none; }
.site-footer__links a:hover { color: var(--accent); text-decoration: underline; }
.site-footer__requisites { color: var(--text-3); display: flex; flex-direction: column; gap: 3px; }
.site-footer__requisites a { color: var(--text-2); text-decoration: none; }
.site-footer__requisites a:hover { color: var(--accent); text-decoration: underline; }
.site-footer__support { color: var(--text-2); }
.site-footer__support a { color: var(--accent); text-decoration: none; }
.site-footer__support a:hover { text-decoration: underline; }

/* Cookie-баннер */
.cookie-banner { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 1100; max-width: 720px; margin: 0 auto; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: 18px 20px; display: flex; flex-wrap: wrap; gap: 14px 20px; align-items: center; justify-content: space-between; }
.cookie-banner__body { flex: 1 1 320px; }
.cookie-banner__title { margin: 0 0 6px; font-size: 15px; }
.cookie-banner__text { margin: 0; font-size: 13px; line-height: 1.5; color: var(--text-2); }
.cookie-banner__text a { color: var(--accent); }
.cookie-banner__actions { display: flex; gap: 10px; flex: 0 0 auto; }
.cookie-banner .btn-secondary { background: var(--surface-3); color: var(--text); border: 1px solid var(--border); }

/* Правовые документы */
.legal-page { max-width: 860px; margin: 0 auto; padding: 32px 20px 64px; line-height: 1.65; color: var(--text); }
.legal-page h1 { font-size: 26px; margin-bottom: 4px; }
.legal-page h2 { font-size: 19px; margin-top: 32px; }
.legal-page .legal-meta { color: var(--text-3); font-size: 13px; margin-bottom: 24px; }
.legal-page a { color: var(--accent); }
.legal-page ul { padding-left: 22px; }
.legal-page .legal-back { display: inline-block; margin-bottom: 16px; color: var(--text-2); text-decoration: none; }
a { color: inherit; }
button { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
::selection { background: var(--accent); color: white; }
.sr-only { position:absolute!important; width:1px!important; height:1px!important; padding:0!important; margin:-1px!important; overflow:hidden!important; clip:rect(0,0,0,0)!important; white-space:nowrap!important; border:0!important; }
.hidden { display:none!important; }
.btn { display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:40px; padding:9px 15px; border:1px solid transparent; border-radius:10px; font-weight:650; cursor:pointer; transition:background .18s,border-color .18s,transform .18s,box-shadow .18s; text-decoration:none; }
.btn:hover { transform:translateY(-1px); }
.btn:active { transform:none; }
.btn:disabled { opacity:.58; cursor:not-allowed; transform:none; }
.btn-primary { background:var(--accent); border-color:var(--accent); color:#fff; box-shadow:0 6px 18px rgba(249,115,22,.2); }
.btn-primary:hover { background:var(--accent-hover); border-color:var(--accent-hover); }
.btn-secondary { background:var(--surface); border-color:var(--border); color:var(--text); box-shadow:var(--shadow-sm); }
.btn-secondary:hover { background:var(--surface-2); }
.btn-danger { background:var(--danger); border-color:var(--danger); color:#fff; box-shadow:0 6px 18px rgba(220,63,79,.18); }
.btn-danger:hover { background:#c92f40; border-color:#c92f40; }
.btn-warning { background:var(--warning); border-color:var(--warning); color:#fff; box-shadow:0 6px 18px rgba(216,137,6,.18); }
.btn-warning:hover { background:#bd7600; border-color:#bd7600; }
.btn-ghost { background:transparent; border-color:transparent; color:var(--text-2); }
.btn-ghost:hover { background:var(--surface-2); color:var(--text); }
.btn-sm { min-height:34px; padding:7px 11px; font-size:13px; }
.btn-lg { min-height:48px; padding:12px 20px; font-size:15px; }
.btn-block { width:100%; }
.form-group { display:grid; gap:7px; margin:0; }
.form-group > label:not(.checkbox-label):not(.switch):not(.checkbox-chip) { color:var(--text); font-size:13px; font-weight:650; }
.form-group small { color:var(--text-3); font-size:12px; line-height:1.45; }
input:not([type="checkbox"]):not([type="radio"]),select,textarea { width:100%; border:1px solid var(--border); background:var(--surface); color:var(--text); border-radius:10px; padding:10px 12px; transition:border-color .18s,box-shadow .18s,background .18s; }
input:not([type="checkbox"]):not([type="radio"]),select { min-height:42px; }
textarea { resize:vertical; line-height:1.5; }
input:not([type="checkbox"]):not([type="radio"]):hover,select:hover,textarea:hover { border-color:color-mix(in srgb,var(--border),var(--text) 20%); }
input:not([type="checkbox"]):not([type="radio"]):focus,select:focus,textarea:focus { border-color:var(--accent); outline:0; box-shadow:0 0 0 3px var(--focus); }
input::placeholder,textarea::placeholder { color:var(--text-3); }
select { cursor:pointer; color-scheme:light; }
select option,select optgroup { background:var(--surface); color:var(--text); }
:root[data-theme="dark"] select { color-scheme:dark; }
input[type="checkbox"],input[type="radio"] { width:16px; height:16px; min-height:0; margin:0; padding:0; flex:0 0 auto; accent-color:var(--accent); cursor:pointer; }
.checkbox-label { display:inline-flex; align-items:center; gap:9px; color:var(--text-2); font-size:13px; font-weight:600; cursor:pointer; }
.checkbox-chip { position:relative; display:inline-flex; cursor:pointer; }
.checkbox-chip input { position:absolute; opacity:0; pointer-events:none; }
.checkbox-chip span { display:grid; place-items:center; min-width:38px; min-height:34px; padding:6px 10px; border:1px solid var(--border); border-radius:9px; background:var(--surface); color:var(--text-2); font-size:12px; font-weight:650; transition:background .18s,border-color .18s,color .18s,box-shadow .18s; }
.checkbox-chip input:checked + span { border-color:var(--accent); background:var(--accent-soft); color:var(--accent-ink); }
.checkbox-chip input:focus-visible + span { outline:3px solid var(--focus); outline-offset:2px; }
.switch { display:inline-flex; align-items:center; gap:10px; color:var(--text-2); font-size:13px; font-weight:600; cursor:pointer; }
.switch input { position:absolute; opacity:0; pointer-events:none; }
.switch-control { position:relative; width:38px; height:22px; flex:0 0 auto; border:1px solid var(--border); border-radius:999px; background:var(--surface-3); transition:background .18s,border-color .18s; }
.switch-control::after { content:""; position:absolute; top:3px; left:3px; width:14px; height:14px; border-radius:50%; background:var(--surface); box-shadow:0 1px 3px rgba(0,0,0,.25); transition:transform .18s; }
.switch input:checked + .switch-control { border-color:var(--accent); background:var(--accent); }
.switch input:checked + .switch-control::after { transform:translateX(16px); }
.switch input:focus-visible + .switch-control { outline:3px solid var(--focus); outline-offset:2px; }
.modal { position:fixed; inset:0; z-index:1000; display:flex; align-items:center; justify-content:center; padding:15px; }
.modal[style*="display: none"],.modal.hidden { display:none!important; }
.modal-overlay { position:absolute; inset:0; z-index:0; background:rgba(3,4,6,.72); backdrop-filter:blur(4px); }
.modal-content { position:relative; z-index:1; width:min(720px,100%); max-height:calc(100dvh - 30px); display:flex; flex-direction:column; overflow:hidden; background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-xl); box-shadow:0 30px 90px rgba(0,0,0,.4); animation:modal-in .2s ease-out; }
.modal-header,.modal-footer { display:flex; align-items:center; padding:17px 20px; }
.modal-header { justify-content:space-between; gap:16px; border-bottom:1px solid var(--border); }
.modal-header h2 { margin:0; font-size:18px; }
.modal-body { overflow:auto; padding:20px; }
.modal-footer { justify-content:flex-end; gap:9px; border-top:1px solid var(--border); }
.modal-close { width:34px; height:34px; display:grid; place-items:center; flex:0 0 auto; padding:0; border:0; border-radius:9px; background:transparent; color:var(--text-2); cursor:pointer; }
.modal-close:hover { background:var(--surface-2); }
@keyframes modal-in { from { opacity:0; transform:translateY(10px) scale(.985); } to { opacity:1; transform:none; } }
.card { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-lg); box-shadow:var(--shadow-sm); }
.card-header { padding:18px 20px; border-bottom:1px solid var(--border); }
.card-header h2 { margin:0; font-size:16px; }
.card-body { padding:20px; }
@media (prefers-reduced-motion: reduce) { *,*::before,*::after { scroll-behavior:auto!important; animation-duration:.01ms!important; animation-iteration-count:1!important; transition-duration:.01ms!important; } }
