:root {
  --ink: #1a1814;
  --paper: #f3efe6;
  --surface: #fffcf7;
  --muted: #5e584f;
  --line: #e3dcd0;
  --vpp: #b42318;
  --vpd: #1a4f8b;
  --accent: #1a1814;
  --accent-soft: #efeae1;
}
[data-theme="vpp"] { --accent: var(--vpp); --accent-soft: #f8e8e6; }
[data-theme="vpd"] { --accent: var(--vpd); --accent-soft: #e7eef6; }
* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
}
a { color: inherit; text-decoration: none; }
button, .btn { font-family: inherit; cursor: pointer; }
h1, h2 { text-wrap: balance; font-weight: 700; }
.login { min-height: 100vh; display: grid; }
@media (min-width: 900px) { .login { grid-template-columns: 1fr 1fr; } }
.login-side { background: var(--ink); color: var(--paper); padding: 40px 32px; display: flex; flex-direction: column; justify-content: space-between; min-height: 280px; }
.kicker { letter-spacing: 0.16em; text-transform: uppercase; font-size: 12px; font-weight: 700; }
.login-side h1 { font-size: 48px; margin: 0; line-height: 1; }
.login-side p { color: rgba(255,252,247,0.8); font-size: 18px; max-width: 24rem; line-height: 1.45; }
.bar { display: flex; height: 8px; width: 160px; border-radius: 999px; overflow: hidden; }
.bar span { width: 50%; }
.bg-vpp { background: var(--vpp); }
.bg-vpd { background: var(--vpd); }
.login-form { display: flex; align-items: center; padding: 48px 24px; }
.login-form form { width: 100%; max-width: 24rem; margin: 0 auto; }
label { display: block; font-size: 14px; font-weight: 700; margin-top: 28px; }
input[type="password"], input[type="search"], select {
  width: 100%; min-height: 48px; margin-top: 8px; border: 1px solid var(--line);
  background: var(--surface); border-radius: 8px; padding: 0 12px; font: inherit; font-size: 16px;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface);
  padding: 0 16px; font-size: 14px; font-weight: 700; color: var(--ink);
}
.btn-solid { background: var(--accent); color: var(--surface); border-color: transparent; }
.btn-ink { background: var(--ink); color: var(--paper); border-color: transparent; width: 100%; margin-top: 16px; min-height: 48px; }
.err { color: var(--vpp); font-size: 14px; }
.muted { color: var(--muted); }
.app { min-height: 100vh; display: flex; }
.side {
  width: 288px; flex: none; background: var(--surface); border-right: 1px solid var(--line);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
}
.side nav { overflow: auto; padding: 12px; flex: 1; }
.brand { display: flex; gap: 12px; align-items: center; height: 64px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.mark { width: 36px; height: 36px; display: grid; grid-template-columns: 1fr 1fr; border-radius: 6px; overflow: hidden; }
.nav a, .nav button {
  display: flex; align-items: center; min-height: 44px; width: 100%; border: 0; background: transparent;
  border-radius: 8px; padding: 0 12px; text-align: left; font-size: 14px; color: var(--ink);
}
.nav a.active, .nav a:hover { background: var(--accent-soft); color: var(--accent); }
.nav a.group-on { background: var(--accent); color: var(--surface); font-weight: 700; }
.nav .sub { padding-left: 28px; }
.nav .deep { padding-left: 40px; color: var(--muted); }
.top {
  height: 64px; display: flex; align-items: center; gap: 12px; padding: 0 16px;
  border-bottom: 1px solid var(--line); position: sticky; top: 0; background: rgba(243,239,230,0.92);
}
.main { max-width: 960px; margin: 0 auto; padding: 32px 24px 64px; }
.content { min-width: 0; flex: 1; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px;
  display: block; margin-top: 12px;
}
.row {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center;
  padding: 16px; border-bottom: 1px solid var(--line);
}
.row:last-child { border-bottom: 0; }
.list { border: 1px solid var(--line); border-radius: 16px; background: var(--surface); overflow: hidden; margin-top: 16px; }
.actions { display: flex; gap: 8px; }
.videos { display: grid; gap: 16px; margin-top: 16px; }
@media (min-width: 700px) { .videos { grid-template-columns: 1fr 1fr; } }
.poster {
  aspect-ratio: 16/9; background: var(--ink); color: var(--paper); display: grid; place-items: center;
  position: relative; border-radius: 16px 16px 0 0;
}
.slide {
  min-height: 320px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 32px; margin-top: 24px;
}
.menu-btn { display: none; }
@media (max-width: 899px) {
  .side { position: fixed; z-index: 20; transform: translateX(-100%); transition: transform .2s; }
  .side.open { transform: none; }
  .menu-btn { display: inline-flex; }
  .backdrop { position: fixed; inset: 0; background: rgba(26,24,20,.4); z-index: 10; }
}
.tools { display: flex; gap: 12px; align-items: end; justify-content: space-between; flex-wrap: wrap; }
select { width: auto; margin: 0; }
