/* Шрифт Inter подключается через <link> в <head> index.php (быстрее, чем
   @import здесь: избегаем последовательной цепочки CSS -> @import -> шрифт). */

/* ── design tokens ─────────────────────────────────────────────────────── */
:root {
  --bg: #f2efe7;
  --bg2: #e8e4d8;
  --panel: #f8f5ed;
  --panel2: #efeadd;
  --ink: #17181b;
  --ink2: #474640;
  --muted: #7c796f;
  --line: rgba(23, 24, 27, 0.1);
  --line2: rgba(23, 24, 27, 0.22);
  --accent: #17181b;
  --on-accent: #f2efe7;
  --red: #e0503a;
  --amber: #a9700a;
  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

.dark {
  --bg: #141518;
  --bg2: #0f1013;
  --panel: #1a1c20;
  --panel2: #222429;
  --ink: #ece8de;
  --ink2: #b7b3a8;
  --muted: #8b877c;
  --line: rgba(236, 232, 222, 0.09);
  --line2: rgba(236, 232, 222, 0.2);
  --accent: #ece8de;
  --on-accent: #141518;
  --red: #ff6b52;
  --amber: #d99a2b;
}

* { box-sizing: border-box; }
img, svg { max-width: 100%; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; scroll-behavior: smooth; overflow-x: hidden; }
body {
  margin: 0;
  overflow-x: hidden;
  touch-action: pan-y;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-feature-settings: "ss01", "cv11";
  transition: background-color .35s ease, color .35s ease;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }
::selection { background: var(--ink); color: var(--bg); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line2); border-radius: 8px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }
input[type=number]::-webkit-outer-spin-button, input[type=number]::-webkit-inner-spin-button { -webkit-appearance:none; margin:0; }
input[type=date]::-webkit-calendar-picker-indicator { opacity:.55; cursor:pointer; filter: var(--date-icon-filter, none); }
.dark input[type=date]::-webkit-calendar-picker-indicator { filter: invert(1); }

/* ── keyframes ─────────────────────────────────────────────────────────── */
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes pulse-dot { 0%,100% { opacity:1; transform:scale(1);} 50% { opacity:.45; transform:scale(.8);} }
@keyframes fade-up { from { opacity:0; transform:translateY(14px);} to { opacity:1; transform:translateY(0);} }
@keyframes fade-in { from { opacity:0;} to { opacity:1;} }
@keyframes spin { to { transform:rotate(360deg);} }

.animate-marquee { animation: marquee 36s linear infinite; }
.animate-marquee:hover { animation-play-state: paused; }
.animate-pulse-dot { animation: pulse-dot 1.6s ease-in-out infinite; }
.animate-fade-up { animation: fade-up .7s cubic-bezier(.22,1,.36,1) both; }
.animate-fade-in { animation: fade-in .5s ease both; }
.animate-spin-slow { animation: spin .9s linear infinite; }
.delay-1 { animation-delay: .08s; } .delay-2 { animation-delay: .16s; } .delay-3 { animation-delay: .24s; }
.delay-4 { animation-delay: .32s; } .delay-5 { animation-delay: .4s; }

/* ── grain ─────────────────────────────────────────────────────────────── */
.grain::after {
  content: ""; position: fixed; inset: -50%; width: 200%; height: 200%;
  pointer-events: none; z-index: 90; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 220px 220px;
}
.dark .grain::after { opacity: .07; }

/* ── layout helpers ────────────────────────────────────────────────────── */
.wrap { max-width: 1320px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 640px) { .wrap { padding: 0 32px; } }
.wrap-narrow { max-width: 960px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 640px) { .wrap-narrow { padding: 0 32px; } }
.hairline-b { border-bottom: 1px solid var(--line); }
.hairline-t { border-top: 1px solid var(--line); }

.display { font-family: var(--font-sans); letter-spacing: -.035em; font-weight: 650; line-height: .96; }
.eyebrow { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; font-weight: 500; }
.tnum { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

.link-sweep { position: relative; }
.link-sweep::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 1px; width: 100%;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform .35s cubic-bezier(.22,1,.36,1);
}
.link-sweep:hover::after { transform: scaleX(1); transform-origin: left; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ── buttons ───────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  white-space: nowrap; border-radius: 999px; font-weight: 500; letter-spacing: .01em;
  transition: all .2s; cursor: pointer; border: 1px solid transparent; user-select: none;
  height: 44px; padding: 0 24px; font-size: 14px;
}
.btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.btn:disabled { pointer-events: none; opacity: .4; }
.btn-primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.btn-primary:hover { opacity: .85; }
.btn-inverse { background: var(--panel); color: var(--ink); border-color: var(--line2); }
.btn-inverse:hover { background: var(--panel2); }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--line2); }
.btn-outline:hover { border-color: var(--ink); background: var(--panel); }
.btn-ghost { background: transparent; color: var(--ink); border-color: transparent; }
.btn-ghost:hover { background: var(--panel2); }
.btn-danger { background: transparent; color: var(--ink); border-color: var(--line2); }
.btn-danger:hover { border-color: rgba(224,80,58,.6); color: var(--red); }
.btn-sm { height: 36px; padding: 0 16px; font-size: 12px; }
.btn-lg { height: 52px; padding: 0 32px; font-size: 14px; }
.btn-block { width: 100%; }
.spinner-btn {
  height: 14px; width: 14px; border-radius: 999px; border: 1.5px solid currentColor;
  border-top-color: transparent; animation: spin .9s linear infinite; display:inline-block;
}

/* ── form fields ───────────────────────────────────────────────────────── */
.field { display: block; margin-bottom: 20px; }
.field:last-child { margin-bottom: 0; }
.field-label {
  margin-bottom: 8px; display: flex; align-items: baseline; justify-content: space-between;
  color: var(--muted);
}
.field-label .req { margin-left: 4px; color: var(--ink2); }
.field-hint { text-transform: none; letter-spacing: normal; font-size: 11px; }
.field-error { margin-top: 6px; display: block; font-size: 12px; color: var(--red); }

.input, .select, .textarea {
  width: 100%; border-radius: 8px; border: 1px solid var(--line2); background: var(--panel);
  padding: 0 14px; font-size: 14px; color: var(--ink); transition: border-color .2s; outline: none;
  font-family: inherit;
}
.input::placeholder, .textarea::placeholder { color: var(--muted); opacity: .7; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--ink); }
.input { height: 44px; }
.textarea { min-height: 92px; padding-top: 10px; padding-bottom: 10px; line-height: 1.6; resize: vertical; }
.select {
  height: 44px; cursor: pointer; appearance: none; padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.input:disabled { opacity: .6; }

/* checkbox card */
.check-card {
  display: flex; width: 100%; align-items: flex-start; gap: 12px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--panel); padding: 16px; text-align: left;
  transition: all .2s; cursor: pointer;
}
.check-card:hover { border-color: var(--line2); }
.check-card.active { border-color: var(--ink); }
.check-card .box {
  margin-top: 2px; display: flex; height: 18px; width: 18px; flex-shrink: 0; align-items: center;
  justify-content: center; border-radius: 5px; border: 1px solid var(--line2); color: transparent;
  transition: all .2s;
}
.check-card.active .box { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.check-card .label { display: block; font-size: 14px; font-weight: 500; line-height: 1.2; }
.check-card .sub { display: block; margin-top: 2px; font-size: 12px; color: var(--muted); }

/* switch */
.switch-card {
  display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 16px;
  border-radius: 10px; border: 1px solid var(--line); background: var(--panel); padding: 16px;
  text-align: left; cursor: pointer; transition: border-color .2s;
}
.switch-card:hover { border-color: var(--line2); }
.switch-track {
  position: relative; height: 24px; width: 44px; flex-shrink: 0; border-radius: 999px;
  border: 1px solid var(--line2); background: var(--panel2); transition: background-color .3s;
}
.switch-track.on { background: var(--ink); }
.switch-thumb {
  position: absolute; top: 50%; height: 16px; width: 16px; transform: translateY(-50%);
  border-radius: 999px; background: var(--muted); left: 4px; transition: all .3s;
}
.switch-track.on .switch-thumb { left: calc(100% - 20px); background: var(--on-accent); }

/* badges */
.badge {
  display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; border: 1px solid;
  padding: 4px 10px; font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .12em;
}
.badge-neutral { border-color: var(--line2); color: var(--ink2); }
.badge-solid { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.badge-muted { border-color: var(--line); color: var(--muted); }
.badge-danger { border-color: rgba(224,80,58,.4); color: var(--red); }
.badge-amber { border-color: rgba(169,112,10,.4); color: var(--amber); }
.badge .dot { height: 6px; width: 6px; border-radius: 999px; background: currentColor; animation: pulse-dot 1.6s ease-in-out infinite; }

/* cards */
.card { border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 24px; transition: border-color .3s, background-color .3s; }

.section-header { margin-bottom: 32px; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }

.spinner { display: inline-block; border-radius: 999px; border: 2px solid var(--line2); border-top-color: var(--ink); animation: spin .9s linear infinite; }

.empty-state {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  border-radius: 16px; border: 1px dashed var(--line2); padding: 64px 24px; text-align: center;
}
.empty-state .body { margin-top: 8px; max-width: 380px; font-size: 14px; color: var(--muted); }

/* modal */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100; display: flex; align-items: flex-end; justify-content: center;
  background: rgba(0,0,0,.4); padding: 16px; backdrop-filter: blur(4px); animation: fade-in .5s ease both;
}
@media (min-width: 640px) { .modal-overlay { align-items: center; } }
.modal-box {
  width: 100%; max-width: 420px; border-radius: 16px; border: 1px solid var(--line); background: var(--panel);
  padding: 24px; box-shadow: 0 25px 50px -12px rgba(0,0,0,.4); animation: fade-up .5s cubic-bezier(.22,1,.36,1) both;
}
.modal-box.wide { max-width: 640px; }
.modal-head { margin-bottom: 20px; display: flex; align-items: center; justify-content: space-between; }
.modal-head h3 { font-size: 18px; font-weight: 600; letter-spacing: -.01em; margin: 0; }
.modal-close {
  display: flex; height: 32px; width: 32px; align-items: center; justify-content: center; border-radius: 999px;
  color: var(--muted); transition: all .2s; border: none; background: transparent; cursor: pointer;
}
.modal-close:hover { background: var(--panel2); color: var(--ink); }
.notifications-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.notifications-modal-head p { margin: 0; color: var(--muted); font-size: 13px; }
.notifications-list { display: flex; max-height: min(620px, 70vh); flex-direction: column; gap: 10px; overflow-y: auto; padding: 2px 4px 4px 0; }
.notification-card { position: relative; display: flex; gap: 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; padding: 18px; background: var(--panel); animation: fade-up .45s cubic-bezier(.22,1,.36,1) both; transition: border-color .25s, background-color .25s, transform .25s; }
.notification-card:hover { border-color: var(--line2); transform: translateY(-1px); }
.notification-card.unread { border-color: color-mix(in srgb, var(--ink) 28%, var(--line)); background: color-mix(in srgb, var(--panel2) 55%, var(--panel)); }
.notification-card-main { min-width: 0; flex: 1; }
.notification-card-meta { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .12em; }
.notification-new { color: var(--red); }
.notification-card h4 { margin: 8px 0 0; font-size: 18px; line-height: 1.2; font-weight: 650; letter-spacing: -.02em; }
.notification-card-body { margin-top: 10px; color: var(--ink2); font-size: 13px; line-height: 1.65; }
.notification-card-body p { margin: 0 0 8px; }
.notification-card-body p:last-child { margin-bottom: 0; }
.notification-card-body a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.notification-image { width: 116px; height: 116px; flex: 0 0 116px; border-radius: 10px; object-fit: cover; }
.notification-audio { width: min(100%, 360px); height: 34px; margin-top: 14px; }
.notification-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; color: var(--ink); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; }
.notification-link span { font-size: 16px; }
.notifications-empty { display: flex; min-height: 220px; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--muted); text-align: center; }
.notifications-empty strong { color: var(--ink); font-size: 16px; }
.notifications-empty span { font-size: 13px; }
.notifications-empty-icon { display: flex; width: 42px; height: 42px; align-items: center; justify-content: center; margin-bottom: 4px; border: 1px solid var(--line2); border-radius: 50%; font-size: 24px; }

/* theme toggle / icon button */
.icon-btn {
  display: flex; height: 40px; width: 40px; align-items: center; justify-content: center; border-radius: 999px;
  border: 1px solid var(--line2); color: var(--ink); transition: all .3s; background: transparent; cursor: pointer;
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn-sm { height: 36px; width: 36px; border: 1px solid var(--line); color: var(--muted); }
.icon-btn-sm:hover { border-color: var(--line2); background: var(--panel2); color: var(--ink); }
.icon-btn-sm.danger:hover { border-color: rgba(224,80,58,.6); color: var(--red); }

/* segmented tabs */
.seg-tabs { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px; border-radius: 999px; border: 1px solid var(--line2); background: var(--panel); padding: 4px; }
.seg-tab { min-width: 0; border-radius: 999px; padding: 6px 16px; font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: .12em; line-height: 1.2; transition: all .2s; border: none; background: transparent; color: var(--muted); cursor: pointer; }
.seg-tab.active { background: var(--ink); color: var(--on-accent); }
.seg-tab:not(.active):hover { color: var(--ink); }

/* player range */
.player-range { -webkit-appearance: none; appearance: none; height: 3px; border-radius: 2px; background: var(--line2); cursor: pointer; outline: none; }
.player-range::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 12px; height: 12px; border-radius: 999px; background: var(--ink); border: none; transition: transform .15s ease; }
.player-range::-webkit-slider-thumb:hover { transform: scale(1.25); }
.player-range::-moz-range-thumb { width: 12px; height: 12px; border-radius: 999px; background: var(--ink); border: none; }

/* ── app chrome ────────────────────────────────────────────────────────── */
#app { min-height: 100vh; }
.hidden { display: none !important; }

/* site header */
.site-header {
  position: fixed; inset-inline: 0; top: 0; z-index: 50; transition: all .5s; border-bottom: 1px solid transparent;
}
.site-header.scrolled { border-color: var(--line); background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(8px); }
.site-header .bar { display: flex; height: 72px; align-items: center; justify-content: space-between; }
.logo { font-size: 20px; font-weight: 800; letter-spacing: .18em; }
.logo .r { color: var(--muted); }
.site-nav { display: none; align-items: center; gap: 32px; }
.site-nav a { font-size: 13px; font-weight: 500; text-transform: uppercase; letter-spacing: .14em; color: var(--ink2); transition: color .2s; }
.site-nav a:hover { color: var(--ink); }
.header-actions { display: none; align-items: center; gap: 12px; }
.mobile-actions { display: flex; align-items: center; gap: 8px; }
.burger { display: flex; height: 40px; width: 40px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); background: transparent; cursor: pointer; }
.burger-lines { display: flex; flex-direction: column; gap: 5px; }
.burger-lines span { display: block; height: 1px; width: 16px; background: var(--ink); transition: transform .3s; }
.burger.open .l1 { transform: translateY(3px) rotate(45deg); }
.burger.open .l2 { transform: translateY(-3px) rotate(-45deg); }
.mobile-drawer { overflow: hidden; border-bottom: 1px solid var(--line); background: var(--bg); max-height: 0; transition: max-height .5s ease-out; }
.mobile-drawer.open { max-height: 480px; }
.mobile-drawer nav { display: flex; flex-direction: column; padding: 16px 24px; }
.mobile-drawer nav a { border-bottom: 1px solid var(--line); padding: 16px 0; font-size: 14px; font-weight: 500; text-transform: uppercase; letter-spacing: .16em; color: var(--ink2); }
.mobile-drawer nav a:last-of-type { border-bottom: 0; }
.mobile-drawer .drawer-actions { display: flex; gap: 12px; padding: 20px 0; }
@media (min-width: 1024px) {
  .site-nav { display: flex; }
  .header-actions { display: flex; }
  .mobile-actions { display: none; }
  .mobile-drawer { display: none; }
}

/* dashboard shell */
.shell { min-height: 100vh; }
.sidebar {
  position: fixed; inset-block: 0; left: 0; z-index: 40; width: 264px; border-right: 1px solid var(--line);
  background: var(--bg); padding: 28px 20px; display: none;
}
@media (min-width: 1024px) { .sidebar { display: block; } .main-col { padding-left: 264px; } }
.sidebar-inner { display: flex; height: 100%; flex-direction: column; }
.sidebar .logo-link { display: flex; align-items: center; gap: 8px; padding: 4px 8px 32px; }
.side-nav { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.side-nav a {
  display: flex; align-items: center; gap: 12px; border-radius: 8px; padding: 10px 14px; font-size: 14px;
  color: var(--ink2); transition: all .2s;
}
.side-nav a:hover { background: var(--panel2); color: var(--ink); }
.side-nav a.active { background: var(--ink); color: var(--on-accent); }
.side-nav a svg { color: var(--muted); transition: color .2s; }
.side-nav a.active svg { color: var(--on-accent); }
.side-nav a:hover svg { color: var(--ink); }
.sidebar-notifications { margin: 0 0 16px; }
.notification-trigger { position: relative; display: flex; width: 100%; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px; color: var(--ink2); background: transparent; cursor: pointer; text-align: left; transition: all .25s; }
.notification-trigger:hover { border-color: var(--line2); background: var(--panel2); color: var(--ink); }
.notification-trigger svg { flex-shrink: 0; }
.notification-dot { width: 7px; height: 7px; margin-left: auto; border-radius: 50%; background: var(--red); opacity: 0; transform: scale(.5); transition: opacity .25s, transform .25s; }
.notification-trigger.has-unread .notification-dot { opacity: 1; transform: scale(1); animation: pulse-dot 1.6s ease-in-out infinite; }
.new-release-link {
  margin-top: 16px; display: flex; align-items: center; gap: 12px; border-radius: 8px;
  border: 1px dashed var(--line2); padding: 10px 14px; font-size: 14px; color: var(--muted);
  transition: all .2s;
}
.new-release-link:hover { border-color: var(--ink); color: var(--ink); }
.sidebar-user { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.user-btn { display: flex; width: 100%; align-items: center; gap: 12px; border-radius: 8px; padding: 8px; text-align: left; background: transparent; border: none; cursor: pointer; transition: background-color .2s; }
.user-btn:hover { background: var(--panel2); }
.user-avatar { display: flex; height: 36px; width: 36px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 999px; background: var(--ink); font-size: 12px; font-weight: 700; color: var(--on-accent); }
.user-btn .info { min-width: 0; flex: 1; }
.user-btn .name { display: block; font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-btn .email { display: block; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-btn svg { color: var(--muted); transition: transform .3s; flex-shrink: 0; }
.user-btn.open svg { transform: rotate(180deg); }
.user-menu { max-height: 0; opacity: 0; overflow: hidden; transition: all .3s ease-out; }
.user-menu.open { max-height: 200px; opacity: 1; padding-top: 8px; }
.user-menu a, .user-menu button { display: flex; align-items: center; gap: 8px; width: 100%; border-radius: 6px; padding: 8px 12px; text-align: left; font-size: 14px; color: var(--ink2); background: transparent; border: none; cursor: pointer; transition: all .2s; }
.user-menu a:hover, .user-menu button:hover { background: var(--panel2); color: var(--ink); }

.mobile-sidebar-overlay { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,.4); backdrop-filter: blur(4px); transition: opacity .3s; opacity: 0; pointer-events: none; }
.mobile-sidebar-overlay.open { opacity: 1; pointer-events: auto; }
.mobile-sidebar { position: fixed; inset-block: 0; left: 0; z-index: 51; width: 280px; border-right: 1px solid var(--line); background: var(--bg); padding: 28px 20px; transform: translateX(-100%); transition: transform .4s; }
.mobile-sidebar.open { transform: translateX(0); }
@media (min-width: 1024px) { .mobile-sidebar, .mobile-sidebar-overlay { display: none; } }

.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; height: 68px; align-items: center;
  justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 85%, transparent); padding: 0 20px; backdrop-filter: blur(6px);
}
@media (min-width: 640px) { .topbar { padding: 0 32px; } }
.topbar .title { font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.mobile-menu-btn { display: flex; height: 40px; width: 40px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); background: transparent; cursor: pointer; }
@media (min-width: 1024px) { .mobile-menu-btn { display: none; } }
.topbar-artist { display: none; margin-right: 8px; color: var(--muted); }
@media (min-width: 768px) { .topbar-artist { display: inline; } }

.dash-main { max-width: 1180px; margin: 0 auto; padding: 32px 20px; }
@media (min-width: 640px) { .dash-main { padding: 40px 32px; } }

/* stat grid */
.grid-lines { display: grid; overflow: hidden; border-radius: 12px; border: 1px solid var(--line); background: var(--line); gap: 1px; }
.stat-cell { min-width: 0; background: var(--panel); padding: 28px 24px; }
.stat-cell .tnum { min-width: 0; overflow-wrap: anywhere; }

/* generic grid helpers */
.grid-2 { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
.grid-3 { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-3 { grid-template-columns: repeat(2,1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3,1fr); } }
.grid-4 { display: grid; gap: 1px; grid-template-columns: repeat(2,1fr); }
@media (min-width: 1024px) { .grid-4 { grid-template-columns: repeat(4,1fr); } }

/* release cards */
.release-card { overflow: hidden; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); transition: all .3s; display: block; }
.release-card:hover { transform: translateY(-2px); border-color: var(--line2); }
.release-cover { position: relative; aspect-ratio: 1; overflow: hidden; background: var(--panel2); }
.release-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.release-card:hover .release-cover img { transform: scale(1.03); }
.release-cover .placeholder { display: flex; height: 100%; width: 100%; align-items: center; justify-content: center; color: var(--muted); }
.release-cover .status-pin { position: absolute; left: 12px; top: 12px; }
.release-cover .explicit-pin { position: absolute; bottom: 12px; right: 12px; border-radius: 4px; border: 1px solid var(--line2); background: color-mix(in srgb, var(--bg) 90%, transparent); padding: 2px 6px; font-size: 10px; font-weight: 700; letter-spacing: .05em; backdrop-filter: blur(4px); }
.release-body { padding: 16px; }
.release-body .row1 { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.release-body .title { font-size: 14px; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.release-body .meta { margin-top: 4px; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.release-body .date { margin-top: 2px; font-size: 11px; color: var(--muted); }

/* release row (dashboard list) */
.release-row-list { border-radius: 12px; border: 1px solid var(--line); background: var(--panel); overflow: hidden; }
.release-row { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--line); transition: background-color .2s; }
.release-row:last-child { border-bottom: none; }
.release-row:hover { background: var(--panel2); }
.release-row .thumb { height: 48px; width: 48px; flex-shrink: 0; overflow: hidden; border-radius: 6px; background: var(--panel2); }
.release-row .thumb img { width: 100%; height: 100%; object-fit: cover; }
.release-row .info { min-width: 0; flex: 1; }
.release-row .info .t { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.release-row .info .m { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.release-row > .badge { flex-shrink: 0; }

/* progress bars */
.bar-track { height: 3px; overflow: hidden; border-radius: 999px; background: var(--line); }
.bar-fill { height: 100%; border-radius: 999px; background: var(--ink); transition: width .7s; }

/* auth */
.auth-page { display: flex; min-height: 100vh; flex-direction: column; background: var(--bg); }
.auth-topbar { display: flex; align-items: center; justify-content: space-between; padding: 20px; }
@media (min-width: 640px) { .auth-topbar { padding: 20px 32px; } }
.auth-grid { margin: 0 auto; display: grid; width: 100%; max-width: 1180px; flex: 1; align-items: center; gap: 48px; padding: 40px 20px; }
@media (min-width: 640px) { .auth-grid { padding: 40px 32px; } }
@media (min-width: 1024px) { .auth-grid { grid-template-columns: 1fr 1fr; } }
.auth-editorial { display: none; }
@media (min-width: 1024px) { .auth-editorial { display: block; } }
.auth-steps { margin-top: 48px; display: flex; flex-direction: column; gap: 16px; }
.auth-steps .step { display: flex; align-items: center; gap: 16px; }
.auth-steps .step .n { font-size: 12px; color: var(--muted); }
.auth-steps .step .line { height: 1px; flex: 1; background: var(--line); }
.auth-steps .step .t { font-size: 14px; color: var(--ink2); }
.auth-form-wrap { margin: 0 auto; width: 100%; max-width: 440px; }
.auth-box { border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 32px; }
@media (min-width: 640px) { .auth-box { padding: 40px; } }
.auth-divider { margin: 24px 0; display: flex; align-items: center; gap: 16px; }
.auth-divider .l { height: 1px; flex: 1; background: var(--line); }
.auth-divider span:not(.l) { font-size: 11px; text-transform: uppercase; letter-spacing: .18em; color: var(--muted); }
.error-banner { border-radius: 8px; border: 1px solid rgba(224,80,58,.3); background: rgba(224,80,58,.1); padding: 12px 16px; font-size: 12px; color: var(--red); margin-bottom: 20px; }
.error-banner-flex { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; border-radius: 12px; border: 1px solid rgba(224,80,58,.3); background: rgba(224,80,58,.1); padding: 16px 20px; font-size: 14px; color: var(--red); margin-bottom: 24px; }
.error-banner-flex button { background: none; border: none; color: inherit; cursor: pointer; opacity: .7; }
.error-banner-flex button:hover { opacity: 1; }

/* landing platform grid, principles, steps */
.platform-cell { display: flex; align-items: baseline; justify-content: space-between; background: var(--panel); padding: 28px 24px; transition: background-color .3s; }
.platform-cell:hover { background: var(--panel2); }
.bento-grid { display: grid; gap: 1px; grid-template-columns: 1fr; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--line); }
.principle-card { min-width: 0; min-height: 220px; display: flex; flex-direction: column; justify-content: space-between; background: var(--panel); padding: 28px; transition: background-color .3s; }
.principle-card:hover { background: var(--panel2); }
@media (min-width: 640px) {
  .bento-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: minmax(190px, auto); }
  .principle-card { min-height: 0; }
  .principle-card:nth-child(1) { grid-row: span 2; }
  .principle-card:nth-child(4) { grid-column: span 2; }
}
@media (min-width: 1024px) {
  .bento-grid { grid-template-columns: 2fr 1fr 1fr; grid-auto-rows: minmax(180px, auto); }
  .principle-card { padding: 32px; }
  .principle-card:nth-child(1) { grid-row: span 2; }
  .principle-card:nth-child(4) { grid-column: span 2; }
}

.marquee-wrap { position: relative; overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--panel) 60%, transparent); padding: 20px 0; }
.marquee-track { display: flex; width: max-content; align-items: center; gap: 40px; padding-right: 40px; }
.marquee-item { display: flex; align-items: center; gap: 40px; white-space: nowrap; }
.marquee-item .name { font-size: 14px; font-weight: 500; text-transform: uppercase; letter-spacing: .2em; color: var(--ink2); }
.marquee-item .dot { height: 4px; width: 4px; border-radius: 999px; background: var(--muted); }
.marquee-fade { pointer-events: none; position: absolute; inset-block: 0; width: 96px; }
.marquee-fade.left { left: 0; background: linear-gradient(to right, var(--bg), transparent); }
.marquee-fade.right { right: 0; background: linear-gradient(to left, var(--bg), transparent); }

/* faq */
.faq-list { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item:last-child { border-bottom: none; }
.faq-q { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 0; text-align: left; background: none; border: none; cursor: pointer; }
.faq-q .left { display: flex; align-items: baseline; gap: 20px; }
.faq-q .num { font-size: 12px; color: var(--muted); }
.faq-q .q { font-size: 18px; font-weight: 500; letter-spacing: -.01em; }
@media (min-width: 640px) { .faq-q .q { font-size: 20px; } }
.faq-plus { display: flex; height: 32px; width: 32px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); transition: all .3s; }
.faq-plus.open { transform: rotate(45deg); border-color: var(--ink); }
.faq-a { display: grid; grid-template-rows: 0fr; opacity: 0; transition: all .5s ease-out; }
.faq-a.open { grid-template-rows: 1fr; opacity: 1; padding-bottom: 24px; }
.faq-a .inner { overflow: hidden; }
.faq-a p { max-width: 640px; padding-left: 36px; font-size: 14px; line-height: 1.7; color: var(--ink2); margin: 0; }

/* pricing */
.plan-card { display: flex; flex-direction: column; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 32px; transition: transform .3s; }
@media (min-width: 1024px) { .plan-card { padding: 40px; } }
.plan-card:hover { transform: translateY(-4px); }
.plan-card.featured { border-color: var(--ink); background: var(--ink); color: var(--on-accent); transform: none; }
.plan-card.featured:hover { transform: none; }
.plan-head { display: flex; align-items: baseline; justify-content: space-between; }
.plan-tag { border-radius: 999px; border: 1px solid color-mix(in srgb, var(--on-accent) 40%, transparent); padding: 4px 12px; font-size: 10px; text-transform: uppercase; letter-spacing: .18em; opacity: .8; }
.plan-price { margin-top: 32px; display: flex; align-items: baseline; gap: 12px; }
.plan-price .num { font-size: clamp(36px, 8vw, 56px); }
.plan-price .per { font-size: 14px; opacity: .6; }
.plan-desc { margin-top: 12px; font-size: 14px; opacity: .7; }
.plan-features { margin-top: 32px; flex: 1; display: flex; flex-direction: column; gap: 14px; padding: 0; list-style: none; }
.plan-features li { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; }
.plan-features svg { margin-top: 4px; flex-shrink: 0; opacity: .8; }
.pricing-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
.pricing-grid .plan-card { padding: 22px 20px; border-radius: 12px; }
.pricing-grid .plan-price { margin-top: 20px; gap: 6px; }
.pricing-grid .plan-price .num { font-size: clamp(24px, 3vw, 36px); white-space: nowrap; letter-spacing: -.02em; }
.pricing-grid .plan-price .per { font-size: 12px; }
.pricing-grid .plan-desc { margin-top: 8px; font-size: 12px; line-height: 1.45; }
.pricing-grid .plan-features { margin-top: 20px; gap: 8px; }
.pricing-grid .plan-features li { gap: 8px; font-size: 12px; line-height: 1.35; }
.pricing-grid .plan-features svg { width: 11px; height: 11px; margin-top: 2px; }
.pricing-grid .btn { height: 40px; padding: 0 12px; font-size: 12px; }
.pricing-grid .label-plan { background: var(--panel2); color: var(--ink); border: 2px solid var(--ink); }
.pricing-grid .label-plan .plan-tag { border-color: var(--ink); background: var(--ink); color: var(--on-accent); opacity: 1; }
@media (min-width: 640px) { .pricing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .pricing-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

/* Узкие экраны: текстовые элементы должны сжиматься внутри своего блока,
   а не раздвигать страницу горизонтальным overflow. */
@media (max-width: 639px) {
  .dash-main { padding: 24px 16px; }
  .card, .plan-card, .grid-lines, .release-row-list { min-width: 0; }

  .seg-tabs {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-radius: 12px;
    gap: 4px;
  }
  .seg-tab {
    width: 100%;
    min-height: 34px;
    padding: 7px 8px;
    white-space: normal;
    text-transform: none;
    letter-spacing: .02em;
  }
  .seg-tab:last-child { grid-column: 1 / -1; }

  .plan-card { padding: 24px 20px; }
  .plan-head { gap: 10px; }
  .plan-head .badge { flex-shrink: 0; }
  .plan-price { flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
  .plan-card .plan-price .num { font-size: clamp(30px, 11vw, 42px) !important; line-height: 1; }
  .plan-price .per { max-width: 100%; font-size: 12px; line-height: 1.35; }
  .plan-desc, .plan-features, .plan-features li { min-width: 0; overflow-wrap: anywhere; }
  .plan-card .btn { height: auto; min-height: 44px; padding: 10px 12px; white-space: normal; line-height: 1.25; }

  .topbar { gap: 8px; padding-inline: 16px; }
  .topbar > div { min-width: 0; }
  .topbar .title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .topbar-wallet-pill { min-width: 0; }
  .topbar-wallet-pill .btn { min-width: 0; padding-inline: 9px; }
  .topbar-wallet-pill .btn svg { flex-shrink: 0; }
  .topbar-wallet-label { display: none; }

  .release-row { gap: 10px; padding-inline: 14px; }
  .release-row > .badge { max-width: 45%; white-space: normal; text-align: right; line-height: 1.25; }
  .release-row .info .m { max-width: 100%; }
  .stat-cell { padding: 20px 16px; }

  .modal-overlay { padding: 8px; }
  .modal-box { max-height: calc(100dvh - 16px); overflow-y: auto; padding: 20px 16px; }
  .modal-head h3 { min-width: 0; overflow-wrap: anywhere; }
}

/* notification composer */
.notification-admin { padding: 24px; }
.notification-admin-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.notification-admin-head h3 { margin: 0; font-size: 22px; font-weight: 650; }
.notification-admin-head p:not(.eyebrow) { max-width: 580px; margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.notification-admin-mark { border: 1px solid var(--line2); border-radius: 999px; padding: 6px 10px; color: var(--muted); font-size: 10px; letter-spacing: .14em; white-space: nowrap; }
.notification-composer { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(240px, .7fr); gap: 28px; padding-top: 24px; }
.notification-composer-main .field { margin-bottom: 16px; }
.editor-toolbar { display: flex; align-items: center; gap: 4px; border: 1px solid var(--line2); border-bottom: 0; border-radius: 8px 8px 0 0; padding: 6px; background: var(--panel2); }
.editor-toolbar button { height: 28px; min-width: 28px; border: 0; border-radius: 5px; padding: 0 7px; color: var(--ink2); background: transparent; cursor: pointer; }
.editor-toolbar button:hover { color: var(--ink); background: var(--panel); }
.editor-toolbar-hint { margin-left: auto; color: var(--muted); font-size: 11px; }
.notification-editor { min-height: 150px; border: 1px solid var(--line2); border-radius: 0 0 8px 8px; padding: 12px 14px; color: var(--ink); background: var(--panel); font-size: 14px; line-height: 1.6; outline: none; }
.notification-editor:focus { border-color: var(--ink); }
.notification-editor:empty::before { content: attr(data-placeholder); color: var(--muted); opacity: .7; pointer-events: none; }
.notification-form-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; }
.notification-attachments { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.notification-upload { display: flex; min-height: 94px; flex-direction: column; justify-content: center; gap: 3px; border: 1px dashed var(--line2); border-radius: 10px; padding: 12px; cursor: pointer; transition: border-color .2s, background-color .2s; }
.notification-upload:hover { border-color: var(--ink); background: var(--panel2); }
.notification-upload input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.notification-upload-icon { color: var(--muted); font-size: 21px; line-height: 1; }
.notification-upload strong { font-size: 12px; }
.notification-upload small { color: var(--muted); font-size: 10px; }
.notification-publish { display: flex; align-items: flex-start; gap: 10px; margin-top: 4px; color: var(--ink2); cursor: pointer; }
.notification-publish input { margin-top: 3px; accent-color: var(--ink); }
.notification-publish span { display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.notification-publish small { color: var(--muted); font-size: 11px; }
.notification-composer-actions { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.notification-live-preview { min-width: 0; }
.notification-preview-card { margin-top: 12px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; padding: 14px; background: var(--panel2); }
.notification-preview-image { display: flex; height: 120px; align-items: center; justify-content: center; overflow: hidden; border-radius: 9px; background: var(--ink); color: var(--on-accent); font-size: 11px; letter-spacing: .18em; }
.notification-preview-image img { width: 100%; height: 100%; object-fit: cover; }
.notification-preview-date { margin: 14px 0 0; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .12em; }
.notification-preview-card h4 { margin: 7px 0 0; font-size: 17px; line-height: 1.2; }
#notification-preview-body { margin-top: 8px; color: var(--ink2); font-size: 12px; line-height: 1.55; }
.notification-history-empty { color: var(--muted); text-align: center; }
.notification-history-list { display: flex; flex-direction: column; gap: 8px; }
.notification-history-item { display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; background: var(--panel); }
.notification-history-item h4 { margin: 8px 0 0; font-size: 14px; }
.notification-history-item p { max-width: 620px; margin: 5px 0 0; overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.notification-history-actions { display: flex; flex-shrink: 0; align-items: center; gap: 8px; }
@media (max-width: 767px) {
  .notifications-modal-head { align-items: flex-start; flex-direction: column; gap: 10px; }
  .notification-card { flex-direction: column-reverse; }
  .notification-image { width: 100%; height: 150px; flex-basis: 150px; }
  .notification-composer { grid-template-columns: 1fr; }
  .notification-admin-head { flex-direction: column; }
  .notification-form-grid, .notification-attachments { grid-template-columns: 1fr; }
  .notification-history-item { align-items: flex-start; flex-direction: column; }
}

/* footer */
.site-footer { margin: 0 auto; max-width: 1320px; padding: 64px 20px 40px; }
@media (min-width: 640px) { .site-footer { padding: 64px 32px 40px; } }
.footer-grid { display: grid; gap: 40px; grid-template-columns: repeat(12,1fr); }
.footer-col-5 { grid-column: span 12; } .footer-col-3 { grid-column: span 12; } .footer-col-2 { grid-column: span 6; }
@media (min-width: 768px) { .footer-col-5 { grid-column: span 5; } .footer-col-3 { grid-column: span 3; } .footer-col-2 { grid-column: span 2; } }
.footer-brand-text { margin-top: 16px; max-width: 300px; font-size: 14px; line-height: 1.6; color: var(--muted); }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.footer-col ul a { color: var(--ink2); }
.footer-col ul a:hover { color: var(--ink); }
.footer-bottom { margin-top: 56px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line); padding-top: 24px; font-size: 12px; color: var(--muted); }

/* hero */
.hero { position: relative; overflow: hidden; }
.hero-inner { padding: 140px 20px 64px; }
@media (min-width: 640px) { .hero-inner { padding-right: 32px; padding-left: 32px; } }
@media (min-width: 1024px) { .hero-inner { padding: 170px 32px 96px; } }
.hero-grid { display: grid; align-items: center; gap: 56px; grid-template-columns: 1fr; }
@media (min-width: 1024px) { .hero-grid { grid-template-columns: 7fr 5fr; } }
.hero-eyebrow { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; color: var(--muted); }
.hero-eyebrow .ln { height: 1px; width: 40px; background: color-mix(in srgb, var(--ink) 40%, transparent); }
.hero h1 { font-size: clamp(2.6rem,7.5vw,6.4rem); margin: 0; }
.hero h1 .muted { color: var(--muted); }
.hero p.lead { margin-top: 32px; max-width: 420px; font-size: 16px; line-height: 1.7; color: var(--ink2); }
.hero-ctas { margin-top: 40px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.hero-stats { margin-top: 64px; display: grid; overflow: hidden; border-radius: 12px; border: 1px solid var(--line); background: var(--line); gap: 1px; grid-template-columns: repeat(2,1fr); }
@media (min-width: 640px) { .hero-stats { grid-template-columns: repeat(4,1fr); } }
.hero-stats .cell { background: var(--panel); padding: 24px 20px; }
.hero-stats .cell .n { font-size: 30px; }
.hero-visual { position: relative; display: none; }
@media (min-width: 1024px) { .hero-visual { display: block; } }
.hero-visual-inner { position: relative; margin: 0 auto; aspect-ratio: 1; width: 100%; max-width: 460px; }
.hero-visual img { border-radius: 8px; border: 1px solid var(--line2); object-fit: cover; }
.hero-img-main { position: absolute; inset: 0; }
.hero-img-main img { width: 100%; height: 100%; box-shadow: 0 40px 80px -30px rgba(0,0,0,.35); }
.hero-img-2 { position: absolute; right: -40px; top: -40px; width: 55%; transform: rotate(-6deg); }
.hero-img-2 img { width: 100%; aspect-ratio: 1; box-shadow: 0 30px 60px -25px rgba(0,0,0,.4); }
.hero-img-3 { position: absolute; bottom: -32px; left: -40px; width: 42%; transform: rotate(3deg); }
.hero-img-3 img { width: 100%; aspect-ratio: 1; box-shadow: 0 30px 60px -25px rgba(0,0,0,.4); }
.hero-live-pill { position: absolute; bottom: -16px; right: 8px; border-radius: 999px; border: 1px solid var(--line2); background: color-mix(in srgb, var(--panel) 90%, transparent); padding: 8px 16px; backdrop-filter: blur(4px); font-size: 12px; }

section.section { padding: 80px 0; }
@media (min-width: 1024px) { section.section { padding: 112px 0; } }
.section-band { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--panel) 50%, transparent); }

.steps-grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .steps-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .steps-grid { grid-template-columns: repeat(4,1fr); } }
.step-item { position: relative; }
.step-item .n { font-size: 60px; color: var(--line2); font-family: var(--font-sans); font-weight: 650; letter-spacing: -.035em; line-height: .96; }
.step-item h3 { margin: 20px 0 0; font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.step-item p { margin-top: 10px; font-size: 14px; line-height: 1.6; color: var(--ink2); }

/* pricing intent classes reused */

/* wizard */
.wiz-wrap { max-width: 880px; margin: 0 auto; }
.wiz-head { margin-bottom: 32px; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.wiz-head > div:first-child { min-width: 0; }
.wiz-save-status { display: block; min-height: 16px; margin-top: 8px; color: var(--muted); font-size: 11px; }
.wiz-save-status.saving { color: var(--amber); }
.wiz-save-status.error { color: var(--red); }
.wiz-review-note { display: flex; flex-direction: column; gap: 6px; margin-bottom: 24px; border-left: 4px solid var(--red); border-radius: 8px; background: color-mix(in srgb, var(--red) 8%, var(--panel)); padding: 14px 16px; color: var(--ink2); font-size: 13px; line-height: 1.5; }
.wiz-review-note strong { color: var(--red); }
.wiz-steps { margin-bottom: 32px; display: flex; align-items: center; overflow-x: auto; padding-bottom: 4px; }
.wiz-step-item { display: flex; align-items: center; flex-shrink: 0; }
.wiz-dot { display: flex; height: 32px; width: 32px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); font-size: 12px; font-weight: 600; color: var(--muted); transition: all .3s; background: transparent; cursor: default; flex-shrink:0; }
.wiz-dot.done { border-color: var(--ink); background: var(--ink); color: var(--on-accent); cursor: pointer; }
.wiz-dot.current { border-color: var(--ink); color: var(--ink); }
.wiz-connector { margin: 0 8px; height: 1px; width: 24px; background: var(--line2); transition: background-color .3s; flex-shrink: 0; }
@media (min-width: 640px) { .wiz-connector { width: 40px; } }
.wiz-connector.done { background: var(--ink); }
.wiz-section { animation: fade-up .5s cubic-bezier(.22,1,.36,1) both; }
.wiz-eyebrow { margin-bottom: 8px; color: var(--muted); }
.wiz-h3 { margin: 0 0 24px; font-size: 24px; font-weight: 600; letter-spacing: -.01em; }
.wiz-panel { border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 24px; }
@media (min-width: 640px) { .wiz-panel { padding: 32px; } }
.wiz-footer { margin-top: 40px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 24px; }

.type-card { position: relative; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 24px; text-align: left; cursor: pointer; transition: all .3s; }
.type-card:hover { border-color: var(--line2); }
.type-card.active { border-color: var(--ink); background: var(--panel2); }
.type-card .top { margin-bottom: 32px; display: flex; align-items: center; justify-content: space-between; }
.type-card .check { display: flex; height: 20px; width: 20px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); color: transparent; transition: all .3s; }
.type-card.active .check { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.type-card .label { font-size: 24px; font-family: var(--font-sans); font-weight: 650; letter-spacing: -.035em; }
.type-card .desc { margin-top: 12px; font-size: 14px; line-height: 1.6; color: var(--muted); }

.chip { border-radius: 999px; border: 1px solid var(--line2); padding: 8px 16px; font-size: 12px; font-weight: 500; color: var(--ink2); transition: all .2s; cursor: pointer; background: transparent; }
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.active { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }

.track-row { display: flex; flex-direction: column; gap: 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); padding: 16px; transition: border-color .2s; }
@media (min-width: 640px) { .track-row { flex-direction: row; align-items: center; } }
.track-row.has-error { border-color: rgba(224,80,58,.4); }
.track-row .left { display: flex; align-items: center; gap: 16px; flex: 1; min-width: 0; }
.track-row .idx { width: 24px; flex-shrink: 0; text-align: center; font-size: 14px; color: var(--muted); }
.track-row .mid { min-width: 0; flex: 1; }
.track-title-input { height: 36px; border: none; background: transparent; padding: 0 4px; font-weight: 500; width: 100%; font-size: 14px; border-radius: 6px; }
.track-title-input:focus { background: var(--panel2); outline: none; }
.track-meta { margin-top: 4px; display: flex; align-items: center; gap: 8px; padding: 0 4px; font-size: 12px; color: var(--muted); }
.track-meta .ok { color: var(--ink); }
.track-progress { margin: 8px 4px 0; height: 3px; overflow: hidden; border-radius: 999px; background: var(--line); }
.track-actions { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-left: 40px; }
@media (min-width: 640px) { .track-actions { padding-left: 0; } }
.explicit-toggle { display: flex; height: 36px; width: 36px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); font-size: 10px; font-weight: 700; letter-spacing: .05em; color: var(--muted); transition: all .2s; background: transparent; cursor: pointer; }
.explicit-toggle.active { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.feat-select-wrap { position: relative; }
.feat-btn { display: flex; height: 36px; align-items: center; gap: 6px; white-space: nowrap; border-radius: 999px; border: 1px solid var(--line2); padding: 0 12px; font-size: 12px; font-weight: 500; transition: all .2s; background: transparent; cursor: pointer; color: var(--muted); }
.feat-btn.active { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.feat-btn:hover:not(.active) { border-color: var(--ink); color: var(--ink); }
.feat-dropdown { position: absolute; right: 0; z-index: 30; margin-top: 8px; max-height: 256px; width: 240px; overflow-y: auto; border-radius: 12px; border: 1px solid var(--line2); background: var(--panel); padding: 6px; box-shadow: 0 25px 50px -12px rgba(0,0,0,.4); }
.feat-dropdown label { display: flex; cursor: pointer; align-items: center; gap: 12px; border-radius: 8px; padding: 10px 12px; transition: background-color .2s; font-size: 14px; }
.feat-dropdown label:hover { background: var(--panel2); }
.feat-empty { padding: 16px 12px; font-size: 12px; color: var(--muted); }

.cover-drop { display: flex; aspect-ratio: 1; cursor: pointer; flex-direction: column; align-items: center; justify-content: center; gap: 16px; border-radius: 16px; border: 2px dashed var(--line2); background: var(--panel); padding: 32px; text-align: center; transition: all .3s; }
.cover-drop:hover, .cover-drop.dragover { border-color: var(--ink); background: var(--panel2); }
.cover-drop svg { color: var(--muted); }
.cover-preview { position: relative; flex: 1; overflow: hidden; border-radius: 16px; border: 1px solid var(--line); }
.cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.cover-preview .badges { position: absolute; bottom: 12px; left: 12px; display: flex; gap: 8px; }
.cover-preview .replace-btn { position: absolute; right: 12px; top: 12px; border-radius: 999px; border: 1px solid var(--line2); background: color-mix(in srgb, var(--panel) 90%, transparent); padding: 8px 16px; font-size: 12px; font-weight: 500; backdrop-filter: blur(4px); cursor: pointer; }
.cover-placeholder { display: flex; flex: 1; align-items: center; justify-content: center; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); padding: 32px; text-align: center; }
.cover-placeholder p { font-size: 14px; line-height: 1.6; color: var(--muted); }

.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.checklist li { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.checklist .tick { display: flex; height: 20px; width: 20px; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); color: transparent; flex-shrink: 0; }
.checklist .tick.ok { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.summary-dl { display: flex; flex-direction: column; gap: 10px; font-size: 14px; margin: 0; }
.summary-dl .row { display: flex; justify-content: space-between; gap: 16px; }
.summary-dl dt { color: var(--muted); margin: 0; }
.summary-dl dd { margin: 0; font-weight: 500; text-align: right; }

/* release detail */
.back-link { margin-bottom: 24px; display: inline-flex; align-items: center; gap: 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .16em; color: var(--muted); transition: color .2s; }
.back-link:hover { color: var(--ink); }
.rd-head { display: flex; flex-direction: column; gap: 32px; }
@media (min-width: 768px) { .rd-head { flex-direction: row; } }
.rd-cover { width: 100%; flex-shrink: 0; }
@media (min-width: 768px) { .rd-cover { width: 280px; } }
.rd-cover-inner { aspect-ratio: 1; overflow: hidden; border-radius: 16px; border: 1px solid var(--line2); background: var(--panel2); box-shadow: 0 30px 60px -30px rgba(0,0,0,.35); }
.rd-cover-inner img { width: 100%; height: 100%; object-fit: cover; }
.rd-cover-inner .ph { display: flex; height: 100%; width: 100%; align-items: center; justify-content: center; color: var(--muted); }
.rd-info { min-width: 0; flex: 1; }
.rd-badges { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.rd-title { margin: 16px 0 0; font-size: 40px; }
@media (min-width: 640px) { .rd-title { font-size: 48px; } }
.rd-artist { margin-top: 12px; font-size: 18px; color: var(--ink2); }
.rd-dl { margin-top: 24px; display: grid; max-width: 560px; grid-template-columns: repeat(2,1fr); gap: 12px 32px; font-size: 14px; }
@media (min-width: 640px) { .rd-dl { grid-template-columns: repeat(3,1fr); } }
.rd-dl dt { margin: 0; }
.rd-dl dd { margin: 4px 0 0; }
.rd-actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }
.checklist-card { margin-top: 32px; border-color: rgba(169,112,10,.3); }

/* platform rows on detail page */
.platform-row { display: flex; align-items: center; gap: 16px; background: var(--panel); padding: 16px 20px; }
.platform-icon { display: flex; height: 40px; width: 40px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); font-size: 12px; font-weight: 700; }

/* player */
.player-list { border-radius: 12px; border: 1px solid var(--line); background: var(--panel); overflow: hidden; }
.player-track { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--line); transition: background-color .2s; }
.player-track:last-child { border-bottom: none; }
.player-track:hover { background: color-mix(in srgb, var(--panel2) 60%, transparent); }
.player-track.current { background: var(--panel2); }
.play-btn { display: flex; height: 36px; width: 36px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--line2); color: var(--ink); transition: all .2s; background: transparent; cursor: pointer; }
.play-btn.current { border-color: var(--ink); background: var(--ink); color: var(--on-accent); }
.play-btn:disabled { cursor: not-allowed; opacity: .4; }
.player-track .idx { width: 24px; flex-shrink: 0; text-align: center; font-size: 12px; color: var(--muted); }
.player-track .info { min-width: 0; flex: 1; }
.player-track .info .t { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-track .info .sub { margin-top: 2px; display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.player-track .info .sub .x18 { border-radius: 3px; border: 1px solid currentColor; padding: 0 4px; font-size: 9px; font-weight: 700; line-height: 14px; }
.eq-bars { display: none; align-items: flex-end; gap: 3px; }
@media (min-width: 640px) { .eq-bars { display: flex; } }
.eq-bars span { width: 3px; border-radius: 999px; background: var(--ink); animation: pulse-dot 1.6s ease-in-out infinite; }
.player-track .dur { flex-shrink: 0; font-size: 12px; color: var(--muted); }
.player-bar-wrap { position: sticky; bottom: 20px; z-index: 30; margin-top: 24px; }
.player-bar { display: flex; align-items: center; gap: 16px; border-radius: 16px; border: 1px solid var(--line2); background: color-mix(in srgb, var(--panel) 95%, transparent); padding: 14px 20px; box-shadow: 0 25px 50px -12px rgba(0,0,0,.4); backdrop-filter: blur(6px); }
.player-bar .cover { height: 40px; width: 40px; flex-shrink: 0; overflow: hidden; border-radius: 6px; background: var(--panel2); }
.player-bar .cover img { width: 100%; height: 100%; object-fit: cover; }
.player-bar .meta { min-width: 0; width: 160px; }
.player-bar .meta .t { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-bar .meta .s { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-bar-play { display: flex; height: 40px; width: 40px; flex-shrink: 0; align-items: center; justify-content: center; border-radius: 999px; background: var(--ink); color: var(--on-accent); border: none; cursor: pointer; transition: transform .15s; }
.player-bar-play:hover { transform: scale(1.05); }
.player-bar .time { display: none; flex-shrink: 0; width: 40px; font-size: 11px; color: var(--muted); }
@media (min-width: 640px) { .player-bar .time { display: block; } }
.player-bar .time.right { text-align: left; }
.player-bar .time.left { text-align: right; }
.player-bar input[type=range] { min-width: 0; flex: 1; }

/* stream breakdown */
.stream-bar-item { margin-bottom: 16px; }
.stream-bar-item:last-child { margin-bottom: 0; }
.stream-bar-head { margin-bottom: 6px; display: flex; align-items: baseline; justify-content: space-between; font-size: 14px; }

.tag-danger-bg { border-radius: 4px; border: 1px solid var(--line2); background: color-mix(in srgb, var(--bg) 90%, transparent); padding: 2px 6px; font-size: 10px; font-weight: 700; letter-spacing: .05em; backdrop-filter: blur(4px); }

/* toast */
#toast-root { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { pointer-events: auto; border-radius: 999px; border: 1px solid var(--line2); background: var(--panel); color: var(--ink); padding: 10px 20px; font-size: 13px; box-shadow: 0 20px 40px -15px rgba(0,0,0,.4); animation: fade-up .3s ease both; }
.toast.error { border-color: rgba(224,80,58,.4); color: var(--red); }

/* utility */
.text-muted { color: var(--muted); }
.text-ink2 { color: var(--ink2); }
.mt-0 { margin-top: 0; }
.center-loading { display: flex; align-items: center; justify-content: center; min-height: 50vh; }

/* ── Стили для Drag & Drop треков и улучшенного плеера ─────────────────── */

.track-drop-zone {
  margin-top: 6px;
  border-radius: 8px;
  border: 1px dashed var(--line2);
  padding: 8px 12px;
  cursor: pointer;
  background: var(--panel2);
  transition: all .2s ease;
  font-size: 13px;
}
.track-drop-zone:hover, .track-drop-zone.dragover {
  border-color: var(--ink);
  background: var(--panel);
}
.track-drop-zone.has-file {
  border-style: solid;
  border-color: var(--line);
  background: transparent;
}
.track-drop-zone .drop-hint {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}
.track-drop-zone .reupload-hint {
  font-size: 11px;
  color: var(--muted);
  margin-left: 6px;
}

.batch-upload-drop {
  border: 2px dashed var(--line2);
  border-radius: 12px;
  background: var(--panel);
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all .2s;
  font-size: 14px;
  font-weight: 500;
}
.batch-upload-drop:hover, .batch-upload-drop.dragover {
  border-color: var(--ink);
  background: var(--panel2);
}

.feat-notice {
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
  background: var(--panel2);
  padding: 8px 10px;
  border-radius: 6px;
  margin-bottom: 8px;
}

/* Фиксированный нижний плеер */
#mono-persistent-player {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 40px);
  max-width: 820px;
  z-index: 99;
}

/* ── Стили баланса и кнопки «Кошелёк» в шапке ─────────────────────────── */

.topbar-wallet-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--panel);
  border: 1px solid var(--line2);
  border-radius: 999px;
  padding: 4px 6px 4px 14px;
}

.topbar-balance-amount {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em;
}

@media (max-width: 640px) {
  .topbar-wallet-pill {
    padding: 3px 5px 3px 10px;
    gap: 6px;
  }
  .topbar-balance-amount {
    font-size: 12px;
  }
}
