/* Die ruhige, helle Farbfamilie des Podcast-Covers. */
:root {
  color-scheme: light;
  /* Die Textgrösse folgt der Browser-Einstellung statt einem festen Pixelwert. */
  font-size: 100%;
  --ink: #163c4c;
  --ink-soft: #425e68;
  --navy: #285867;
  --navy-deep: #173d4b;
  /* Bestehende Komponenten verwenden diese Variablen für Alltagsaktionen. */
  --red: #285867;
  --red-dark: #1d4553;
  --paper: #f4f7f6;
  --surface: #fcfdfc;
  --line: #d3e0e1;
  --focus: #a5343e;
  color: var(--ink);
  background: var(--paper);
}
.main { background: radial-gradient(ellipse 80% 28rem at 88% 0%, #eaf1f1, transparent 72%), var(--paper); }
.sidebar { background: linear-gradient(165deg, #173d4b, #214b59); color: #f8fbfa; }
.sidebar nav.studio-compact-nav { background: #254b58; border-color: #63828a; }
.sidebar nav a { color: #edf6f6; }
.sidebar nav a:hover { color: #fff; background: #315e6c; }
.sidebar nav a[aria-current] { color: #fff; background: #426a77; border-color: #b0ced3; }
.sidebar .studio-compact-nav a[aria-current] { box-shadow: inset .24rem 0 #e9b1b5; }
.sidebar .local, .sidebar .local span { color: #d9e8e9; }
.sidebar .studio-nav-search label, .sidebar .studio-nav-status { color: #edf6f6; }
.top { background: #f8faf9; border-bottom-color: #d4e1e2; }
.card, .card:focus-within { background: var(--surface); border-color: var(--line); }
.card:focus-within { border-color: #91afb5; }
.eyebrow { color: #456671; }
a { color: #205970; text-decoration-color: #88afb9; }
a:hover { color: #113e50; }
.list-row { color: var(--ink); }
.list-row:hover { color: #205970; }
.number, .onboarding-step-number, .workflow-step-number { background: #e8f0f1; color: #255d70; }
.badge { background: #edf4f4; border-color: #c7dcdc; color: #315f6b; }
.empty { background: #f1f7f6; border-color: #bfd5d8; color: #365f69; }
input, select, textarea { border-color: #a9c4cb; background-color: #fff; }
input::placeholder, textarea::placeholder { color: #58717a; opacity: 1; }
input[type="checkbox"], input[type="radio"] { accent-color: #a5343e; }
input[type="file"]::file-selector-button {
  margin-inline-end: .7rem; padding: .42rem .7rem; border: 1px solid #b7cfd1;
  border-radius: .5rem; background: #f2f7f6; color: #173d4b; font: inherit; cursor: pointer;
}
button, button.subtle, .subtle { background: #f2f7f6; border-color: #b7cfd1; color: #173d4b; }
button:hover, button.subtle:hover, .subtle:hover { background: #e3efee; border-color: #81aab1; color: #103441; }
button:disabled, button:disabled:hover, button.subtle:disabled, button.subtle:disabled:hover {
  opacity: 1; background: #e8eeee; border-color: #c6d5d6; color: #536b72; cursor: not-allowed; box-shadow: none;
}
input:disabled, select:disabled, textarea:disabled { background-color: #eef3f3; color: #536b72; cursor: not-allowed; }
/* Hauptaktionen erhalten eine ruhigere, aber klare Gewichtung. */
form:has(input[name="action"][value="episode_create"]) > button[type="submit"],
button[name="mode"][value="start"] { background: #285867; border-color: #285867; color: #fff; }
form:has(input[name="action"][value="episode_create"]) > button[type="submit"]:hover,
button[name="mode"][value="start"]:hover { background: #1d4553; border-color: #1d4553; }
.sidebar .studio-nav-search input[type="search"] { background: #fcfdfc; color: #173d4b; border-color: #a9c4cb; }
.sidebar .studio-nav-search button { background: #edf5f4; border-color: #b7cfd1; color: #173d4b; }
.sidebar .studio-nav-search button:hover { background: #dcebea; color: #103441; }
.help-details { background: #f2f7f6; border-color: #c6dada; color: #365f69; }
.studio-chat-drawer, .onboarding-dialog { background: var(--surface); border-color: #c9dcdd; }
.studio-chat-drawer .studio-chat-body { background: #fff; border-color: #d3e0e1; }
.studio-path-bar { background: #f8faf9; border-top-color: #c9dcdd; color: #365f69; }
.studio-path-bar a { color: #205970; }
.story-info > summary { background: #f2f7f6; border-color: #b7cfd1; color: #173d4b; }
.story-info > summary:hover, .story-info[open] > summary { background: #e3efee; border-color: #81aab1; }
.story-info-text, .story-info-preview { background: #fcfdfc; border-color: #b7cfd1; color: #173d4b; }
.top .studio-header-badge { background: #285867; color: #fff; }
.studio-chat-badge { color: #173d4b; }
.notice.error, .auth-error { color: #173d4b; background: #edf4f4; border-color: #6e99a5; }
/* Login und Einladungsansicht nutzen dieselbe Farb- und Materialfamilie. */
.auth-intro { background: radial-gradient(ellipse 80% 48% at 85% 15%, #e5eff0, transparent 70%), #eff5f4; }
.auth-panel { background: #f4f7f6; }
.auth-card { background: #fcfdfc; border-color: #d3e0e1; }
.auth-card:focus-within { border-color: #91afb5; }
.auth-kicker { color: #456671; }
.auth-card button:not(.auth-secondary) { background: #285867; color: #fff; }
.auth-card button:not(.auth-secondary):hover { background: #1d4553; }
.auth-card .auth-secondary { background: #f2f7f6; border-color: #b7cfd1; color: #173d4b; }
.auth-card .auth-secondary:hover { background: #e3efee; color: #103441; }
.auth-link { color: #205970; }
.auth-mark { background: #173d4b; }
.auth-invite, .auth-notice { color: #173d4b; background: #edf4f4; border-color: #8bafb5; }
.auth-members, .auth-member, .auth-privacy { border-color: #d3e0e1; }
/* Später geladene Modul-Styles bleiben in derselben Farbfamilie. */
.overview-widgets .overview-widget-arrow,
.countdown-widget .countdown-widget-clock { color: #285867; }
.calendar-list .calendar-date { background: #e8f0f1; color: #255d70; }
@media (hover: hover) {
  .sidebar .studio-compact-nav a:hover { background: #315e6c; }
  .sidebar .studio-compact-nav a[aria-current]:hover { box-shadow: inset .24rem 0 #e9b1b5; }
  input[type="file"]:not(:disabled)::file-selector-button:hover { background: #e3efee; border-color: #81aab1; }
  .overview-widgets .overview-widget:hover { border-color: #81aab1; background: #f5f9f8; }
  .story-info > summary:hover, .help-details summary:hover { color: #205970; }
}
/* Rot ist für bewusste Auswahl, Tastaturfokus und den Cursor reserviert. */
:focus-visible { outline: 3px solid #a5343e; outline-offset: 3px; }
.sidebar :focus-visible { outline-color: #f3c5c8; }
.studio-path-bar a:focus-visible { outline-color: #a5343e; }
input:focus-visible, select:focus-visible, textarea:focus-visible,
.auth-card input:focus-visible, .auth-card button:focus-visible, .auth-brand:focus-visible {
  outline: 3px solid #a5343e; outline-offset: 3px; border-color: #a5343e;
}
.heading h1::after, .auth-intro h1::after { background: #a5343e; }
input:focus, textarea:focus, .auth-card input:focus { caret-color: #a5343e; }
input:focus, select:focus, textarea:focus { outline-color: #a5343e; }
@media (max-width: 880px) {
  /* Mindestens 16px bei Standardeinstellung verhindert ungewolltes Eingabe-Zoomen auf dem iPhone. */
  input:not([type="checkbox"]):not([type="radio"]), select, textarea,
  .sidebar .studio-nav-search input[type="search"] { font-size: 1rem; }
}
@media (forced-colors: active) {
  :focus-visible { outline-color: Highlight; }
  .sidebar nav a[aria-current] { border: 2px solid Highlight; }
}
@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .sidebar nav.studio-compact-nav { background: rgb(37 75 88 / 94%); }
  .top, .studio-path-bar { background: rgb(248 250 249 / 96%); }
  button.subtle { background: rgb(242 247 246 / 96%); }
}
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .sidebar nav.studio-compact-nav { background: #254b58; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .top, .studio-path-bar { background: #f8faf9; -webkit-backdrop-filter: none; backdrop-filter: none; }
  button.subtle, .help-details { background: #f2f7f6; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .auth-card, .onboarding-dialog, .studio-chat-drawer { background: #fcfdfc; -webkit-backdrop-filter: none; backdrop-filter: none; }
}
