:root {
    color-scheme: light dark;
    --canvas: light-dark(#eef2f5, #111921);
    --surface: light-dark(#fff, #192530);
    --text: light-dark(#152437, #f0f4f9);
    --muted: light-dark(#445970, #b8c9db);
    --border: light-dark(#becbd8, #4c6073);
    --accent: light-dark(#1e506e, #9cd1f1);
    --button: light-dark(#1e506e, #9cd1f1);
    --button-text: light-dark(#fff, #132635);
    font: 16px/1.55 system-ui, sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; color: var(--text); background: var(--canvas); }
header, main { width: min(100% - 32px, 720px); margin-inline: auto; }
header { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 24px 0; }
header a { flex-shrink: 0; }
header .brand { min-width: 0; flex-shrink: 1; font-weight: 750; overflow-wrap: anywhere; }
a { color: var(--accent); text-underline-offset: .22em; }
main { margin-bottom: 32px; padding: clamp(18px, 4vw, 40px); background: var(--surface); border: 1px solid var(--border); border-radius: 16px; }
.intro { margin-bottom: 26px; }
h1 { margin: 0; font-size: clamp(26px, 5vw, 36px); }
p { margin: 8px 0 0; }
.intro p, .episode, .actions span { color: var(--muted); }
form { display: grid; gap: 16px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label { display: grid; min-width: 0; gap: 6px; font-weight: 600; }
input, select, textarea { font: inherit; width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; color: var(--text); background: var(--surface); }
textarea { resize: vertical; }
.episode { margin-top: -8px; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 16px; }
.actions span { font-size: .875rem; }
.primary { display: inline-flex; min-height: 44px; align-items: center; font: inherit; font-weight: 700; background: var(--button); color: var(--button-text); border: 0; border-radius: 8px; padding: 9px 20px; text-decoration: none; cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.notice { padding: 12px 16px; margin: 0 0 18px; border: 1px solid var(--border); border-radius: 8px; }
.error { color: light-dark(#9c241e, #ffb6a8); }
@media (max-width: 550px) { .fields { grid-template-columns: minmax(0, 1fr); } }
