:root {
  color-scheme: dark;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  background: #100e18;
  color: #f4efff;
  --panel: #1c1728;
  --line: #392e4c;
  --muted: #c4b8d4;
  --accent: #d2b4ff;
  --solid: #bd97ff;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; line-height: 1.55; }
[hidden] { display: none !important; }
a { color: var(--accent); text-underline-offset: .2em; }
a:hover { color: #efe1ff; }
:focus-visible { outline: 2px solid #e0c7ff; outline-offset: 3px; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(1.9rem, 5vw, 3rem); letter-spacing: -.045em; line-height: 1.15; overflow-wrap: anywhere; }
h2 { font-size: 1.18rem; line-height: 1.3; }
p, small, time { color: var(--muted); }
p { margin-top: .55rem; }
code { color: var(--accent); overflow-wrap: anywhere; }
.dashboard { display: grid; grid-template-columns: 236px minmax(0, 1fr); }
.sidebar { background: #171220; border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 1.45rem 1rem; }
.brand { display: flex; align-items: center; gap: .65rem; color: #f4efff; text-decoration: none; font-weight: 750; letter-spacing: -.02em; }
.mark { background: #34224d; color: #e0c7ff; display: grid; place-items: center; height: 2.2rem; width: 2.2rem; border-radius: .65rem; font-size: 1.3rem; flex: none; }
.sidebar nav { display: grid; gap: .2rem; margin: 1.6rem 0; }
.sidebar nav a { text-decoration: none; padding: .52rem .7rem; border-radius: .5rem; color: var(--muted); }
.sidebar nav a:hover, .sidebar nav a[aria-current] { background: #32234a; color: #f5eaff; }
.nav-label { padding-left: .7rem; margin-top: .85rem; font-size: .78rem; font-weight: 650; }
.sidebar-footer { margin-top: auto; border-top: 1px solid var(--line); padding: 1rem .25rem 0; display: grid; gap: .4rem; overflow-wrap: anywhere; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: .7rem; padding: .85rem clamp(1rem, 4vw, 2.75rem); border-bottom: 1px solid var(--line); color: var(--muted); min-height: 60px; }
.content { width: min(100%, 1240px); margin: 0 auto; padding: clamp(1rem, 4vw, 2.75rem); display: grid; gap: 1.1rem; }
.page-head, .section-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .85rem; }
.page-head { margin-bottom: .35rem; }
.panel { min-width: 0; padding: clamp(1rem, 3vw, 1.45rem); background: var(--panel); border: 1px solid var(--line); border-radius: .9rem; }
.stats, .feature-grid, .form-grid { display: grid; gap: .9rem; }
.stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.feature-grid, .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat { display: grid; gap: .4rem; color: var(--muted); }
.stat strong { font-size: 2rem; color: var(--accent); line-height: 1.2; }
.feature-link { text-decoration: none; color: #f4efff; display: grid; gap: .25rem; }
.feature-link strong { display: flex; justify-content: space-between; }
.feature-link:hover { border-color: var(--accent); }
.feature-grid article code { display: block; margin-top: .6rem; }
.rows { padding: 0; margin: .5rem 0 0; list-style: none; }
.rows li { display: flex; gap: .7rem; justify-content: space-between; flex-wrap: wrap; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.rows li:last-child { border-bottom: 0; }
button, .button { border: 1px solid transparent; border-radius: .52rem; background: var(--solid); color: #170e24; padding: .55rem .8rem; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-block; }
button:hover, .button:hover { background: #dec3ff; color: #170e24; }
button:disabled { cursor: wait; opacity: .65; }
button.secondary { background: #262033; color: #f4efff; border-color: var(--line); }
button.secondary:hover { background: #36294a; }
label { display: grid; gap: .3rem; min-width: 0; font-size: .92rem; font-weight: 650; }
input, select, textarea { width: 100%; min-width: 0; padding: .55rem .62rem; border: 1px solid #5c4d70; border-radius: .48rem; background: #15101f; color: #f4efff; font: inherit; }
textarea { resize: vertical; }
.stack { display: grid; gap: .9rem; margin-top: 1rem; }
.stack > button { justify-self: start; }
.inline { display: flex; align-items: center; gap: .5rem; }
.inline select { width: auto; }
.form-panel { width: min(100%, 720px); }
.public { background: radial-gradient(ellipse at 50% 0, #29203e, #100e18 65%); }
.public main { padding: 6vh 0; }
.public-brand { justify-content: center; margin-bottom: .5rem; }
.public .content { width: min(100%, 520px); }
.auth-panel h1 { font-size: 2rem; }
.notice, .setup-key { padding: .68rem .8rem; background: #33234d; border-radius: .5rem; color: #fff; }
.notice.danger { background: #4a223b; }
.spaced { margin-top: 1rem; }
.table-wrap { width: 100%; overflow-x: auto; margin-top: .65rem; }
table { width: 100%; border-collapse: collapse; text-align: left; }
td, th { padding: .62rem .7rem; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-size: .84rem; }
.pill { display: inline-block; border-radius: 999px; padding: .12rem .56rem; background: #302741; color: #e9d8ff; font-size: .83rem; }
.pill.completed { background: #16372e; color: #b2f2d2; }
.pill.cancelled { background: #4c2338; color: #ffd1e3; }
.pill.scheduled { background: #402968; color: #eedcff; }
.details > div { display: grid; grid-template-columns: minmax(100px, .5fr) 1fr; gap: .7rem; padding: .4rem 0; }
.details dt { color: var(--muted); }
.details dd { margin: 0; overflow-wrap: anywhere; }
.preserve { white-space: pre-wrap; overflow-wrap: anywhere; }
.skip { position: absolute; left: 1rem; top: -5rem; padding: .5rem; background: var(--panel); z-index: 2; }
.skip:focus { top: .6rem; }
@media (max-width: 760px) {
  .dashboard { display: block; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .dashboard.menu-enabled { display: flex; flex-direction: column; }
  .dashboard.menu-enabled .sidebar { display: none; }
  .dashboard.menu-enabled.menu-open .sidebar { display: flex; order: 1; }
  .dashboard.menu-enabled main { display: contents; }
  .dashboard.menu-enabled .topbar { order: 0; }
  .dashboard.menu-enabled .content { order: 2; }
}
@media (max-width: 520px) {
  .stats { grid-template-columns: 1fr; }
  .feature-grid, .form-grid { grid-template-columns: 1fr; }
  .topbar span { font-size: .85rem; }
}

