
:root {
  --red: #be1e2d;
  --red-dark: #9f1421;
  --ink: #252b33;
  --text: #39414c;
  --muted: #75808d;
  --chrome: #464d57;
  --chrome-dark: #343a42;
  --line: #c7cdd4;
  --line-dark: #9da5ae;
  --surface: #ffffff;
  --surface-soft: #f4f6f8;
  --canvas: #e9edf1;
  --shadow: 0 18px 60px rgba(25, 31, 39, 0.18);
}

* { box-sizing: border-box; }

html,
body { min-height: 100%; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
}

button,
input,
select,
textarea { font: inherit; }

button { color: inherit; }

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid rgba(190, 30, 45, 0.25);
  outline-offset: 1px;
}

button,
[role="button"] { -webkit-tap-highlight-color: transparent; }

.app-shell {
  min-height: 100vh;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.topbar {
  height: 58px;
  flex: 0 0 58px;
  background: var(--chrome);
  color: #fff;
  border-bottom: 3px solid var(--red);
  display: grid;
  grid-template-columns: 188px minmax(340px, 1fr) auto;
  align-items: center;
  padding: 0 12px 0 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  z-index: 10;
}

.brand {
  height: 44px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.brand img {
  max-width: 165px;
  max-height: 41px;
  object-fit: contain;
  object-position: left center;
}

.wordmark { display: flex; align-items: baseline; font-size: 25px; letter-spacing: -1.2px; }
.wordmark b { background: var(--red); color: #fff; padding: 2px 5px; transform: skew(-8deg); }
.wordmark em { font-style: normal; font-weight: 300; margin-left: 3px; }
.wordmark small { font-size: 8px; margin-left: 5px; color: #d7dbe0; letter-spacing: 0; }

.main-nav { display: flex; align-self: stretch; }
.main-nav button {
  border: 0;
  background: transparent;
  color: #dfe3e7;
  padding: 0 18px;
  position: relative;
  cursor: pointer;
  font-size: 12px;
  letter-spacing: 0.02em;
}
.main-nav button:hover { background: rgba(255,255,255,.07); color: #fff; }
.main-nav button.active { color: #fff; font-weight: 700; background: rgba(0,0,0,.12); }
.main-nav button.active::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: 0; height: 3px; background: #fff; }

.top-actions { display: flex; align-items: center; gap: 9px; height: 100%; }
.build-version {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 6px;
  border: 1px solid #777d85;
  background: #30343a;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .05em;
}
.cloud-state { font-size: 10px; color: #dce1e6; display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.cloud-state i,
.settings-save-state i { width: 7px; height: 7px; border-radius: 50%; background: #8d98a4; display: inline-block; }
.cloud-saved i,
i.cloud-saved { background: #55b978; box-shadow: 0 0 0 3px rgba(85,185,120,.13); }
.cloud-saving i,
i.cloud-saving,
.cloud-loading i,
i.cloud-loading { background: #e0ad45; animation: pulse 1.1s infinite; }
.cloud-offline i,
i.cloud-offline { background: #ef6e73; }
@keyframes pulse { 50% { opacity: .35; } }

.read-button,
.icon-button {
  background: #555d68;
  color: #fff;
  border: 1px solid #777f89;
  min-height: 30px;
  padding: 0 10px;
  cursor: pointer;
}
.read-button:hover,
.icon-button:hover { background: #626b76; }
.icon-button { width: 32px; padding: 0; font-size: 14px; }

.account-button {
  height: 42px;
  border: 0;
  border-left: 1px solid #626a74;
  background: transparent;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 3px 0 11px;
  cursor: pointer;
  text-align: left;
}
.account-button > span:last-child { display: flex; flex-direction: column; gap: 1px; }
.account-button b { font-size: 11px; }
.account-button small { color: #c8ced4; font-size: 9px; }

.avatar {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .03em;
}
.avatar.small { width: 28px; height: 28px; flex-basis: 28px; }
.avatar.large { width: 42px; height: 42px; flex-basis: 42px; font-size: 12px; }

.workspace {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(390px, 44%) 9px minmax(500px, 1fr);
  padding: 9px;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line-dark);
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(34, 40, 48, .09);
}

.splitter { position: relative; }
.splitter i { position: absolute; top: 0; bottom: 0; left: 4px; width: 1px; background: #a9b0b8; box-shadow: 2px 0 #fff; }

.panel-titlebar {
  min-height: 56px;
  background: var(--chrome);
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 13px 8px 15px;
  border-bottom: 1px solid #2e333a;
}
.panel-titlebar h1 { margin: 2px 0 0; font-size: 18px; line-height: 1.1; font-weight: 500; }
.eyebrow { display: block; text-transform: uppercase; letter-spacing: .12em; font-size: 9px; font-weight: 700; color: var(--muted); }
.panel-titlebar .eyebrow,
.schedule-head .eyebrow { color: #cdd2d8; }
.panel-count { min-width: 31px; height: 25px; padding: 0 8px; background: #5d6570; border: 1px solid #737b85; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; }

.toolbar {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) auto auto;
  gap: 6px;
  padding: 8px;
  background: #dce1e6;
  border-bottom: 1px solid var(--line-dark);
}

.search-box { position: relative; height: 32px; min-width: 0; display: flex; align-items: center; }
.search-box > span { position: absolute; left: 9px; top: 5px; font-size: 20px; color: #6d7782; transform: rotate(-15deg); pointer-events: none; }
.search-box input { width: 100%; height: 32px; border: 1px solid #8f98a2; background: #fff; padding: 0 30px 0 30px; color: var(--ink); }
.search-box input::placeholder { color: #9aa2aa; }
.search-box button { position: absolute; right: 4px; top: 4px; width: 24px; height: 24px; border: 0; background: transparent; font-size: 18px; cursor: pointer; color: #76808a; }

.filter-button,
.secondary-button,
.danger-button {
  border: 1px solid #8e97a1;
  background: #f8f9fa;
  min-height: 32px;
  padding: 0 11px;
  cursor: pointer;
}
.filter-button { position: relative; }
.filter-button:hover,
.filter-button.active,
.secondary-button:hover { background: #e9edf1; }
.filter-button i { width: 6px; height: 6px; border-radius: 50%; position: absolute; right: 4px; top: 4px; background: var(--red); }

.primary-button {
  min-height: 32px;
  border: 1px solid var(--red-dark);
  background: var(--red);
  color: #fff;
  padding: 0 14px;
  cursor: pointer;
  font-weight: 700;
  box-shadow: inset 0 1px rgba(255,255,255,.18);
}
.primary-button:hover { background: var(--red-dark); }
.primary-button b { font-size: 16px; vertical-align: -1px; }

.filter-drawer {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 8px;
  align-items: end;
  padding: 9px;
  background: #eef1f4;
  border-bottom: 1px solid var(--line);
}
.filter-drawer label { display: flex; flex-direction: column; gap: 4px; }
.filter-drawer select,
.filter-drawer button { height: 30px; border: 1px solid #a7afb8; background: #fff; padding: 0 8px; }
.filter-drawer button { cursor: pointer; }
.field-label { text-transform: uppercase; font-size: 9px; letter-spacing: .08em; color: #69737f; font-weight: 700; }

.list-summary {
  min-height: 29px;
  background: #f0f2f4;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  font-size: 10px;
  color: #707a85;
}
.list-summary span:first-child { color: #4b5661; font-weight: 700; }

.story-list { flex: 1; min-height: 0; overflow: auto; padding: 8px 8px 36px; background: #fafafa; }
.story-card {
  --story-color: #8b949e;
  min-height: 83px;
  margin-bottom: 7px;
  display: grid;
  grid-template-columns: 22px minmax(0,1fr) auto;
  border: 1px solid #adb4bc;
  border-left: 8px solid var(--story-color);
  background: #fff;
  cursor: grab;
  color: var(--text);
  transition: border-color .12s, background .12s, transform .12s;
}
.story-card:hover { border-color: #7f8994; background: #fbfcfd; transform: translateX(1px); }
.story-card:active { cursor: grabbing; }
.drag-handle { display: flex; align-items: center; justify-content: center; color: #abb2ba; font-size: 16px; border-right: 1px solid #e0e3e6; }
.story-copy { padding: 11px 10px 9px; min-width: 0; }
.story-copy h3 { margin: 0 0 9px; font-size: 14px; line-height: 1.25; color: #343b44; font-weight: 600; }
.story-meta { display: flex; align-items: center; gap: 7px; font-size: 10px; color: #7a838c; min-width: 0; }
.story-meta > span:nth-child(2) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.type-badge { color: #fff; min-width: 70px; max-width: 92px; padding: 3px 7px; font-size: 9px; line-height: 1; text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.status { border-left: 1px solid #d4d8dc; padding-left: 7px; white-space: nowrap; }
.status-bereit { color: #368154; }
.status-entwurf { color: #a27024; }
.status-gesendet { color: #71808f; }
.story-side { min-width: 74px; border-left: 1px solid #e2e5e8; background: #f7f8f9; padding: 10px 8px; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; }
.duration { font-size: 10px; color: #596571; white-space: nowrap; }
.planned-mark { text-transform: uppercase; font-size: 8px; color: #65717c; border: 1px solid #b8c0c8; padding: 3px 5px; background: #fff; letter-spacing: .05em; }

.empty-state { height: 280px; display: flex; align-items: center; justify-content: center; flex-direction: column; color: #7a838e; }
.empty-state > span { font-size: 38px; color: #bcc2c8; transform: rotate(-15deg); }
.empty-state b { margin-top: 8px; color: #535e69; }
.empty-state p { margin: 5px 0; font-size: 11px; }

.schedule-head {
  min-height: 72px;
  background: var(--chrome);
  color: #fff;
  border-bottom: 1px solid #2d3238;
  padding: 9px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.date-navigation { display: flex; align-items: center; gap: 8px; min-width: 0; }
.date-navigation > button { width: 30px; height: 32px; border: 1px solid #737b85; color: #fff; background: #575f69; cursor: pointer; font-size: 22px; line-height: 1; }
.date-navigation > button:hover { background: #66707b; }
.date-navigation label { min-width: 250px; position: relative; cursor: pointer; }
.date-navigation strong { display: block; font-size: 17px; font-weight: 500; margin-top: 3px; text-transform: capitalize; white-space: nowrap; }
.date-navigation input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }
.date-navigation .today-button { width: auto; padding: 0 9px; font-size: 10px; }
.day-stats { display: flex; gap: 16px; font-size: 9px; color: #cbd1d7; text-align: right; white-space: nowrap; }
.day-stats span { display: flex; flex-direction: column; gap: 3px; }
.day-stats b { color: #fff; font-size: 12px; font-weight: 500; }

.schedule-hint { min-height: 31px; border-bottom: 1px solid var(--line); background: #e9edf0; color: #68737e; display: flex; align-items: center; justify-content: center; gap: 7px; font-size: 10px; }
.schedule-hint span { width: 17px; height: 17px; border-radius: 50%; border: 1px solid #a2aab3; display: inline-flex; align-items: center; justify-content: center; background: #fff; font-size: 13px; }
.schedule-scroll { flex: 1; min-height: 0; overflow: auto; padding: 9px 10px 40px; background: #f7f8f9; }
.template-block { margin-bottom: 13px; border: 1px solid #b7bec6; background: #fff; }
.template-block > header { min-height: 31px; display: flex; align-items: center; justify-content: space-between; background: #dfe3e7; border-bottom: 1px solid #b7bec6; padding: 0 10px; }
.template-block > header div { display: flex; align-items: center; gap: 7px; }
.template-block > header i { width: 6px; height: 6px; background: var(--red); border-radius: 50%; }
.template-block > header b { text-transform: uppercase; font-size: 10px; letter-spacing: .07em; color: #414a54; }
.template-block > header span { color: #7c858f; font-size: 9px; border-left: 1px solid #b9bfc5; padding-left: 7px; }
.template-block > header time { color: #5e6873; font-size: 10px; }
.slot-list { padding: 6px; }
.broadcast-slot {
  --slot-color: #8b949e;
  display: grid;
  grid-template-columns: 61px minmax(0, 1fr);
  border: 1px solid #c6cbd1;
  border-left: 5px solid var(--slot-color);
  min-height: 76px;
  margin-bottom: 6px;
  transition: background .12s, border-color .12s;
}
.broadcast-slot:last-child { margin-bottom: 0; }
.broadcast-slot.drop-active { background: #fff8f8; border-color: var(--red); box-shadow: inset 0 0 0 1px var(--red); }
.slot-time { background: #f0f2f4; border-right: 1px solid #d1d6db; display: flex; align-items: center; flex-direction: column; padding-top: 14px; }
.slot-time time { font-size: 15px; font-weight: 700; color: #343d46; }
.slot-time span { font-size: 9px; color: #8a939c; margin-top: 3px; }
.slot-body { min-width: 0; }
.slot-label { height: 26px; padding: 0 8px; display: flex; align-items: center; gap: 6px; border-bottom: 1px solid #e0e3e6; background: #fafbfb; }
.slot-label i { width: 6px; height: 6px; background: var(--slot-color); }
.slot-label b { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; color: #5d6670; }
.slot-items { padding: 5px; }
.empty-slot { height: 35px; border: 1px dashed #c7cdd3; background: #fbfcfc; display: flex; align-items: center; justify-content: center; flex-direction: column; color: #8c959e; }
.empty-slot b { font-size: 9px; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.empty-slot span { font-size: 9px; margin-top: 2px; }
.scheduled-story { min-height: 42px; display: grid; grid-template-columns: minmax(0, 1fr) 30px; border: 1px solid #c7ccd1; background: #fff; margin-bottom: 4px; cursor: grab; }
.scheduled-story:last-child { margin-bottom: 0; }
.scheduled-story:hover { border-color: #979fa8; }
.scheduled-open { min-width: 0; border: 0; background: transparent; display: grid; grid-template-columns: 4px minmax(0,1fr); gap: 8px; align-items: stretch; text-align: left; padding: 0 7px 0 0; cursor: pointer; }
.scheduled-open > i { display: block; }
.scheduled-open > span { display: flex; flex-direction: column; min-width: 0; justify-content: center; }
.scheduled-open b { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #39434d; }
.scheduled-open small { font-size: 9px; color: #87909a; margin-top: 2px; }
.remove-scheduled { border: 0; border-left: 1px solid #e0e3e6; background: #f7f8f9; color: #818a94; cursor: pointer; font-size: 17px; }
.remove-scheduled:hover { background: #f6e2e4; color: var(--red); }

.modal-backdrop { position: fixed; inset: 0; z-index: 50; background: rgba(29,34,40,.58); display: flex; align-items: center; justify-content: center; padding: 24px; }
.editor-modal { width: min(790px, 100%); max-height: calc(100vh - 48px); background: #fff; border: 1px solid #737b85; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.modal-head { min-height: 75px; background: var(--chrome); color: #fff; display: flex; justify-content: space-between; align-items: center; padding: 13px 16px 12px 20px; border-bottom: 3px solid var(--red); }
.modal-head .eyebrow { color: #d1d6db; }
.modal-head h2 { margin: 4px 0 0; font-size: 17px; font-weight: 500; max-width: 660px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.close-button { width: 34px; height: 34px; border: 1px solid #747d87; background: #555d67; color: #fff; font-size: 22px; cursor: pointer; }
.editor-body { min-height: 0; overflow: auto; padding: 20px; }
.wide-field,
.form-row label { display: flex; flex-direction: column; gap: 5px; }
.wide-field > input,
.form-row input,
.form-row select,
.settings-content input,
.settings-content select { height: 36px; border: 1px solid #abb2ba; background: #fff; padding: 0 10px; color: #303944; }
.wide-field > input { height: 43px; font-size: 16px; font-weight: 600; }
.wide-field textarea { min-height: 240px; resize: vertical; border: 1px solid #9fa7b0; background: #fff; padding: 13px; font-size: 15px; line-height: 1.55; color: #303842; }
.text-stats { text-align: right; font-size: 9px; color: #89929c; margin-top: -1px; }
.form-row { display: grid; gap: 12px; margin: 15px 0; }
.form-row.thirds { grid-template-columns: 1fr 1fr 1fr; }
.editor-assignments { border: 1px solid #c5cbd1; margin: 18px 0 0; padding: 12px; }
.editor-assignments legend { text-transform: uppercase; letter-spacing: .08em; font-size: 9px; color: #68737e; font-weight: 700; padding: 0 5px; }
.account-checks { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px; }
.account-checks > label { border: 1px solid #d1d6db; display: grid; grid-template-columns: auto 28px minmax(0,1fr); align-items: center; gap: 8px; padding: 7px; cursor: pointer; background: #fafbfb; }
.account-checks > label.selected { border-color: #a2abb4; background: #f0f3f5; }
.account-checks input { accent-color: var(--red); }
.account-checks > label > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.account-checks b { font-size: 11px; }
.account-checks small { font-size: 9px; color: #7c8690; margin-top: 2px; }
.modal-footer { min-height: 62px; border-top: 1px solid #c5cbd1; background: #eef1f3; display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; }
.modal-footer > div { display: flex; gap: 8px; }
.danger-button { color: var(--red); border-color: #d3a4a9; background: #fff; }
.danger-button:hover { background: #fbecee; }

.settings-page { position: fixed; inset: 0; z-index: 40; background: #f1f3f5; display: flex; flex-direction: column; }
.settings-top { height: 56px; flex: 0 0 56px; background: var(--chrome); color: #fff; border-bottom: 3px solid var(--red); display: flex; align-items: center; justify-content: space-between; padding: 0 18px; }
.settings-top > div { display: flex; align-items: center; gap: 16px; color: #d2d7dc; font-size: 11px; }
.settings-mark { color: #fff; font-size: 21px; letter-spacing: -1px; border-right: 1px solid #6c737c; padding-right: 16px; }
.settings-mark b { color: #fff; background: var(--red); padding: 2px 5px; font-weight: 500; }
.settings-top > button { height: 30px; border: 1px solid #737b85; background: #555d67; color: #fff; padding: 0 10px; cursor: pointer; font-size: 10px; }
.settings-top > button b { font-size: 16px; margin-left: 7px; }
.settings-layout { flex: 1; min-height: 0; display: grid; grid-template-columns: 245px minmax(0,1fr); }
.settings-layout > aside { background: #fff; border-right: 1px solid #bbc2ca; padding: 25px 12px 14px; display: flex; flex-direction: column; }
.settings-layout > aside > div:first-child { padding: 0 12px 21px; border-bottom: 1px solid #e0e3e6; }
.settings-layout > aside h2 { margin: 5px 0 0; color: #323a43; font-size: 18px; font-weight: 500; }
.settings-layout aside nav { display: flex; flex-direction: column; gap: 3px; margin-top: 12px; }
.settings-layout aside nav button { min-height: 58px; display: grid; grid-template-columns: 28px minmax(0,1fr); grid-template-rows: 1fr 1fr; border: 1px solid transparent; background: transparent; text-align: left; padding: 8px 10px; cursor: pointer; color: #4f5a65; }
.settings-layout aside nav button > span { grid-row: 1 / 3; align-self: center; font-size: 16px; color: #7b858f; }
.settings-layout aside nav button b { font-size: 11px; align-self: end; }
.settings-layout aside nav button small { font-size: 9px; color: #929aa2; align-self: start; margin-top: 2px; }
.settings-layout aside nav button:hover { background: #f4f6f7; }
.settings-layout aside nav button.active { background: #eef1f3; border-color: #c9cfd5; border-left: 4px solid var(--red); padding-left: 7px; color: #303944; }
.settings-layout aside nav button.active > span { color: var(--red); }
.settings-save-state { margin-top: auto; border-top: 1px solid #e1e4e7; padding: 14px 7px 0; color: #7e8791; font-size: 9px; display: flex; align-items: center; gap: 7px; }
.settings-content { overflow: auto; padding: 32px clamp(24px, 4vw, 60px) 70px; }
.settings-heading { max-width: 1120px; margin: 0 auto 24px; display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.settings-heading h1 { margin: 5px 0 5px; font-size: 26px; color: #2f3740; font-weight: 500; }
.settings-heading p { margin: 0; color: #76818c; max-width: 620px; line-height: 1.4; }
.settings-heading .primary-button { min-height: 36px; }
.settings-cards,
.settings-table,
.type-settings-grid,
.account-summary,
.accounts-list { max-width: 1120px; margin-left: auto; margin-right: auto; }
.settings-cards { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
.settings-card { border: 1px solid #b8c0c8; background: #fff; padding: 16px; box-shadow: 0 1px 2px rgba(32,39,47,.06); }
.settings-card-head { display: grid; grid-template-columns: 36px minmax(0,1fr) 28px; gap: 10px; align-items: center; padding-bottom: 13px; border-bottom: 1px solid #e0e3e6; }
.settings-card-head .color-icon { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; color: var(--red); background: #f6e8ea; font-size: 17px; }
.settings-card-head > div { display: flex; flex-direction: column; }
.settings-card-head input { height: 29px; border: 0; padding: 0; font-size: 14px; font-weight: 700; color: #343d47; }
.settings-card-head small { color: #8a939c; font-size: 9px; }
.delete-icon { width: 28px; height: 28px; border: 1px solid #c9ced4; background: #fff; color: #8b949d; cursor: pointer; font-size: 17px; }
.delete-icon:hover { color: var(--red); border-color: #d7a5aa; background: #fdf6f7; }
.settings-form-grid { display: grid; gap: 9px; padding: 13px 0; }
.settings-form-grid.three { grid-template-columns: repeat(3, 1fr); }
.settings-form-grid label { display: flex; flex-direction: column; gap: 4px; }
.settings-form-grid input { width: 100%; }
.slot-assignment { border-top: 1px solid #e1e4e7; padding-top: 12px; }
.slot-assignment > div { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; max-height: 116px; overflow: auto; }
.slot-assignment label { border: 1px solid #d2d7dc; background: #fafbfb; padding: 5px 7px; display: flex; align-items: center; gap: 5px; font-size: 9px; cursor: pointer; }
.slot-assignment label.selected { border-color: #9ea7b0; background: #eef1f3; color: #313a43; }
.slot-assignment input { display: none; }
.slot-assignment i { width: 6px; height: 12px; }

.settings-table { border: 1px solid #b9c0c8; background: #fff; }
.settings-table-head,
.settings-table-row { display: grid; grid-template-columns: 74px minmax(230px,1fr) 130px 140px 44px; align-items: center; }
.settings-table-head { min-height: 34px; background: #dfe3e7; border-bottom: 1px solid #b9c0c8; color: #5e6872; text-transform: uppercase; font-size: 9px; font-weight: 700; letter-spacing: .06em; }
.settings-table-head span,
.settings-table-row > * { padding-left: 11px; padding-right: 11px; }
.settings-table-row { min-height: 56px; border-bottom: 1px solid #e0e3e6; }
.settings-table-row:last-child { border-bottom: 0; }
.settings-table-row:hover { background: #fafbfb; }
.settings-table-row > input { width: calc(100% - 16px); margin: 0 8px; }
.settings-table-row .delete-icon { padding: 0; margin-left: 3px; }
.color-picker { display: flex; cursor: pointer; }
.color-picker input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.color-picker i { width: 32px; height: 26px; display: block; border: 1px solid rgba(0,0,0,.13); }
.duration-input { position: relative; display: block; }
.duration-input input { width: 100%; padding-right: 38px; }
.duration-input span { position: absolute; right: 19px; top: 12px; font-size: 9px; color: #7a848e; }

.type-settings-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; }
.type-settings-grid > article { --type-color: #5d6f82; border: 1px solid #bac1c8; background: #fff; padding: 14px; }
.type-preview { height: 70px; border: 1px solid #ccd1d6; border-left: 7px solid var(--type-color); background: #f8f9fa; margin-bottom: 15px; display: grid; grid-template-columns: 1fr auto; grid-template-rows: 1fr 1fr; padding: 12px; gap: 2px 8px; position: relative; }
.type-preview > i { position: absolute; left: -1px; top: -1px; right: -1px; height: 3px; background: var(--type-color); }
.type-preview > span { grid-row: 1 / 3; align-self: center; color: #424b55; font-weight: 600; }
.type-preview > small { align-self: end; background: var(--type-color); color: #fff; padding: 3px 6px; font-size: 8px; text-align: center; }
.type-settings-grid article > label { display: flex; flex-direction: column; gap: 5px; margin-bottom: 10px; }
.color-value { display: grid; grid-template-columns: 42px 1fr; height: 36px; border: 1px solid #abb2ba; }
.color-value input { width: 42px; height: 34px; border: 0; padding: 2px; }
.color-value code { align-self: center; color: #65707b; padding-left: 9px; }
.type-settings-grid footer { border-top: 1px solid #e2e5e8; padding-top: 11px; display: flex; align-items: center; justify-content: space-between; color: #7f8993; font-size: 9px; }
.type-settings-grid footer button { border: 0; background: transparent; color: var(--red); cursor: pointer; font-size: 9px; }
.type-settings-grid footer button:disabled { color: #adb4bb; cursor: not-allowed; }

.account-summary { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid #bcc3ca; background: #fff; margin-bottom: 14px; }
.account-summary > div { min-height: 72px; display: flex; align-items: center; justify-content: center; flex-direction: column; border-right: 1px solid #d7dce0; }
.account-summary > div:last-child { border-right: 0; }
.account-summary span { color: #343d46; font-size: 22px; }
.account-summary small { color: #858f99; font-size: 9px; text-transform: uppercase; letter-spacing: .06em; margin-top: 4px; }
.accounts-list { border: 1px solid #b9c0c8; background: #fff; }
.accounts-list article { min-height: 84px; display: grid; grid-template-columns: 52px minmax(150px,1fr) minmax(190px,1.2fr) 130px 130px; gap: 8px; align-items: center; padding: 10px 13px; border-bottom: 1px solid #e0e4e7; }
.accounts-list article:last-child { border-bottom: 0; }
.accounts-list article > label { display: flex; flex-direction: column; gap: 4px; }
.accounts-list input,
.accounts-list select { width: 100%; height: 33px; }

.read-mode { position: fixed; inset: 0; z-index: 70; background: #20242a; color: #f3f5f6; overflow: auto; }
.read-mode > header { height: 66px; position: sticky; top: 0; z-index: 2; background: #343a42; border-bottom: 3px solid var(--red); display: flex; align-items: center; justify-content: space-between; padding: 0 24px; }
.read-mode > header > div { display: flex; align-items: center; gap: 10px; }
.read-mode > header > div:first-child { font-size: 18px; }
.read-mode > header span { color: #cbd1d7; font-size: 11px; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 5px rgba(190,30,45,.14); }
.read-mode > header button { height: 32px; border: 1px solid #6f7781; background: #4a525c; color: #fff; cursor: pointer; padding: 0 11px; }
.read-content { max-width: 1280px; margin: 0 auto; display: grid; grid-template-columns: 150px minmax(0,1fr); gap: 35px; padding: 35px 26px 80px; }
.read-content > aside { position: sticky; top: 100px; align-self: start; border-top: 3px solid var(--red); padding: 16px 0; display: flex; flex-direction: column; }
.read-content > aside > span { text-transform: uppercase; letter-spacing: .13em; color: #989fa7; font-size: 10px; margin-bottom: 22px; }
.read-content > aside b { font-size: 24px; font-weight: 400; margin-top: 12px; }
.read-content > aside small { color: #8f979f; margin-top: 3px; }
.read-content > section > article { display: grid; grid-template-columns: 82px minmax(0,1fr); border-bottom: 1px solid #454b53; padding: 5px 0 36px; margin-bottom: 31px; }
.read-number { display: flex; flex-direction: column; gap: 9px; color: #8e969e; }
.read-number > span { font-size: 12px; }
.read-number time { font-size: 20px; color: #f1f3f4; }
.read-story { max-width: 920px; }
.read-kicker { display: block; text-transform: uppercase; letter-spacing: .1em; font-size: 10px; font-weight: 700; margin-bottom: 9px; }
.read-story h2 { font-size: 28px; line-height: 1.18; margin: 0 0 16px; font-weight: 500; }
.read-story p { font-family: Georgia, "Times New Roman", serif; font-size: 23px; line-height: 1.55; margin: 0; color: #edf0f2; }
.read-story footer { margin-top: 18px; color: #8f979f; display: flex; justify-content: space-between; font-size: 10px; }
.read-story footer span { color: #c9ced3; }
.read-empty { color: #9aa2aa; font-size: 18px; padding: 70px 0; }

.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 100; min-height: 42px; background: #30363e; color: #fff; border: 1px solid #5a626c; border-bottom: 3px solid var(--red); box-shadow: 0 10px 30px rgba(0,0,0,.25); display: flex; align-items: center; gap: 9px; padding: 0 16px; font-size: 11px; }
.toast span { color: #73ce90; font-size: 15px; }

@media (max-width: 1180px) {
  .topbar { grid-template-columns: 170px 1fr auto; }
  .main-nav button { padding: 0 10px; }
  .cloud-state { display: none; }
  .workspace { grid-template-columns: minmax(350px, 42%) 7px minmax(440px, 1fr); padding: 7px; }
  .toolbar { grid-template-columns: 1fr auto; }
  .toolbar .primary-button { grid-column: 1 / 3; }
  .settings-cards { grid-template-columns: 1fr; }
  .type-settings-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .accounts-list article { grid-template-columns: 52px 1fr 1.2fr; }
  .accounts-list article label:nth-of-type(3),
  .accounts-list article label:nth-of-type(4) { grid-column: auto; }
}

@media (max-width: 880px) {
  .app-shell { height: auto; min-height: 100vh; overflow: visible; }
  .topbar { position: sticky; top: 0; height: auto; min-height: 58px; grid-template-columns: 145px 1fr; padding-left: 10px; }
  .brand img { max-width: 132px; }
  .main-nav { display: none; }
  .top-actions { justify-self: end; }
  .read-button,
  .account-button > span:last-child { display: none; }
  .workspace { display: flex; flex-direction: column; padding: 6px; overflow: visible; }
  .panel { overflow: visible; min-height: 650px; }
  .contributions-panel { max-height: 72vh; }
  .story-list,
  .schedule-scroll { min-height: 500px; }
  .splitter { height: 7px; }
  .splitter i { top: 3px; bottom: auto; left: 0; right: 0; height: 1px; width: auto; }
  .settings-layout { grid-template-columns: 1fr; }
  .settings-layout > aside { padding: 9px; border-right: 0; border-bottom: 1px solid #bbc2ca; }
  .settings-layout > aside > div:first-child,
  .settings-save-state { display: none; }
  .settings-layout aside nav { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 0; }
  .settings-layout aside nav button { min-height: 45px; display: flex; align-items: center; justify-content: center; padding: 5px; text-align: center; }
  .settings-layout aside nav button span,
  .settings-layout aside nav button small { display: none; }
  .settings-layout aside nav button.active { border-left: 1px solid #c9cfd5; border-bottom: 3px solid var(--red); padding-left: 5px; }
  .settings-content { padding: 22px 14px 60px; }
  .settings-page { overflow: auto; }
  .settings-layout { overflow: visible; }
  .settings-table { overflow-x: auto; }
  .settings-table-head,
  .settings-table-row { min-width: 760px; }
}

@media (max-width: 620px) {
  .top-actions .icon-button { display: none; }
  .toolbar { grid-template-columns: 1fr auto; }
  .list-summary span:last-child { display: none; }
  .schedule-head { align-items: flex-start; flex-direction: column; }
  .date-navigation label { min-width: 200px; }
  .day-stats { padding-left: 40px; }
  .form-row.thirds,
  .account-checks,
  .settings-form-grid.three { grid-template-columns: 1fr; }
  .modal-backdrop { padding: 0; }
  .editor-modal { max-height: 100vh; height: 100vh; border: 0; }
  .modal-head h2 { max-width: 250px; }
  .settings-top > div > span:last-child { display: none; }
  .settings-heading { align-items: stretch; flex-direction: column; }
  .settings-heading .primary-button { align-self: flex-start; }
  .type-settings-grid { grid-template-columns: 1fr; }
  .account-summary { grid-template-columns: 1fr; }
  .account-summary > div { min-height: 58px; border-right: 0; border-bottom: 1px solid #d7dce0; }
  .accounts-list article { grid-template-columns: 45px 1fr; }
  .accounts-list article label { grid-column: 2; }
  .read-content { grid-template-columns: 1fr; }
  .read-content > aside { display: none; }
  .read-content > section > article { grid-template-columns: 54px minmax(0,1fr); }
  .read-story h2 { font-size: 22px; }
  .read-story p { font-size: 19px; }
}

/* CMS Verkehr v7 reference geometry */
:root {
  --canvas: #e7eaee;
  --surface-soft: #f5f5f5;
  --chrome: #4a4f57;
  --chrome-dark: #424751;
  --line: #c8ccd2;
  --line-dark: #8e9197;
  --text: #474747;
  --muted: #6a6f76;
}

html,
body {
  height: 100%;
  font-family: "Lucida Grande", "Lucida Sans Unicode", Tahoma, Verdana, Arial, Helvetica, sans-serif;
  font-size: 12px;
  line-height: 1.28;
}

.startup-error {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 8px;
  padding: 30px;
  background: #e7eaee;
  color: #474747;
  text-align: center;
}
.startup-error b { font-size: 16px; }
.startup-error span { max-width: 560px; color: #6a6f76; }

.topbar {
  height: 30px;
  min-height: 30px;
  flex: 0 0 30px;
  grid-template-columns: 1fr auto;
  padding: 0 10px;
  background: #424751;
  border-bottom: 1px solid #333840;
  box-shadow: none;
}
.brand { height: 30px; }
.brand img { height: 30px; max-height: 30px; max-width: 230px; }
.wordmark { font-size: 20px; }
.wordmark small { font-size: 7px; }
.main-nav { display: none; }
.top-actions { gap: 7px; }
.cloud-state { font-size: 10px; min-width: 130px; justify-content: flex-end; }
.read-button,
.icon-button {
  min-height: 22px;
  height: 22px;
  border: 1px solid #8e9197;
  background: transparent;
  padding: 2px 8px;
  font-size: 10px;
  text-transform: uppercase;
}
.icon-button { width: 26px; padding: 0; }
.account-button {
  height: 26px;
  padding: 0 2px 0 7px;
  gap: 5px;
}
.account-button .avatar { width: 20px; height: 20px; flex-basis: 20px; font-size: 8px; }
.account-button b { font-size: 9px; }
.account-button small { display: none; }

.workspace {
  display: grid;
  grid-template-columns: minmax(320px, 58%) 8px minmax(320px, 1fr);
  gap: 0;
  padding: 8px;
}
.panel {
  border: 1px solid #8e9197;
  box-shadow: none;
}
.splitter { cursor: col-resize; }
.splitter i {
  left: 3px;
  width: 2px;
  background: #8e9197;
  box-shadow: none;
}
.panel-titlebar { display: none; }
.toolbar {
  min-height: 32px;
  grid-template-columns: minmax(160px, 240px) 72px minmax(112px, auto);
  gap: 6px;
  align-items: center;
  padding: 3px 8px;
  background: #4a4f57;
  border-bottom: 1px solid #2c3036;
}
.search-box,
.search-box input { height: 24px; }
.search-box > span { display: none; }
.search-box input {
  border: 1px solid #767a81;
  border-radius: 0;
  background: #f5f7f8;
  padding: 0 8px;
  font-size: 12px;
}
.search-box button { top: 0; right: 1px; height: 22px; }
.filter-button,
.secondary-button,
.danger-button,
.primary-button {
  min-height: 24px;
  height: 24px;
  border-radius: 0;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 400;
  box-shadow: none;
}
.filter-button { background: #e4e9ed; border-color: #767a81; }
.primary-button { background: #be1e2d; border-color: #941621; font-weight: 600; }
.primary-button b { font-size: 13px; }
.filter-drawer {
  gap: 8px;
  padding: 7px 10px;
  background: #c5ccd3;
  border-color: #8e9197;
}
.filter-drawer select,
.filter-drawer button { height: 24px; border-radius: 0; }
.list-summary {
  min-height: 26px;
  height: 26px;
  background: #cbd1d7;
  border-color: #8e9197;
  padding: 0 8px;
  font-size: 11px;
}
.story-list { padding: 8px 8px 40px; background: #fff; }
.story-card {
  min-height: 62px;
  margin-bottom: 8px;
  grid-template-columns: 12px minmax(0, 1fr) 96px;
  border: 1px solid #8e9197;
  border-left: 0;
  border-radius: 2px;
  background: #f5f5f5;
  transition: background .1s;
}
.story-card:hover { transform: none; background: #efefef; border-color: #8e9197; }
.drag-handle {
  color: transparent;
  background: var(--story-color);
  border-right: 1px solid #d3d7dc;
  font-size: 0;
}
.story-copy { padding: 6px 12px 5px; }
.story-copy h3 {
  margin: 0 0 7px;
  font-size: 13px;
  line-height: 1.22;
  color: #474747;
  font-weight: 600;
}
.story-meta { gap: 6px; font-size: 10px; color: #6a6f76; }
.type-badge {
  min-width: 96px;
  max-width: 96px;
  padding: 2px 5px;
  font-size: 10px;
  font-weight: 600;
  border: 1px solid rgba(0,0,0,.12);
}
.story-side {
  width: 96px;
  min-width: 96px;
  padding: 6px 8px;
  background: transparent;
  border-left: 0;
}
.planned-mark { padding: 2px 4px; font-size: 8px; }

.schedule-head {
  min-height: 32px;
  height: 32px;
  padding: 3px 8px;
  background: #4a4f57;
  border-color: #2c3036;
}
.date-navigation { gap: 5px; }
.date-navigation > button {
  width: 24px;
  height: 24px;
  font-size: 17px;
  border-color: #767a81;
  background: #e4e9ed;
  color: #474747;
}
.date-navigation label { min-width: 220px; }
.date-navigation .eyebrow { display: none; }
.date-navigation strong { margin: 0; font-size: 12px; font-weight: 400; }
.date-navigation .today-button { font-size: 9px; }
.day-stats { gap: 12px; font-size: 9px; }
.day-stats span { flex-direction: row; align-items: baseline; gap: 3px; }
.day-stats b { font-size: 11px; }
.schedule-hint {
  min-height: 26px;
  height: 26px;
  justify-content: flex-start;
  padding: 0 8px;
  background: #cbd1d7;
  border-color: #8e9197;
  font-size: 11px;
}
.schedule-hint span { width: 15px; height: 15px; font-size: 11px; }
.schedule-scroll { padding: 8px 8px 40px; background: #fff; }
.template-block { margin-bottom: 8px; border-color: #8e9197; }
.template-block > header {
  min-height: 26px;
  height: 26px;
  padding: 0 8px;
  background: #dfe3e7;
  border-color: #8e9197;
}
.template-block > header b { font-size: 10px; }
.slot-list { padding: 6px; }
.broadcast-slot {
  grid-template-columns: 54px minmax(0,1fr);
  min-height: 58px;
  margin-bottom: 6px;
  border-color: #aeb4bb;
}
.slot-time { padding-top: 9px; }
.slot-time time { font-size: 13px; }
.slot-label { min-height: 23px; padding: 0 8px; }
.slot-items { padding: 4px 6px 6px; }
.empty-slot { min-height: 25px; }
.scheduled-story { min-height: 32px; }
.scheduled-open { padding: 4px 6px; }

@media (max-width: 1200px) {
  .workspace { display: flex; flex-direction: column; overflow: visible; }
  .app-shell { height: auto; overflow: visible; }
  .panel { min-height: 590px; }
  .splitter { height: 8px; }
  .splitter i { top: 3px; bottom: auto; left: 0; right: 0; width: auto; height: 2px; }
}

@media (max-width: 720px) {
  .cloud-state,
  .account-button { display: none; }
  .toolbar { grid-template-columns: minmax(0,1fr) 70px; }
  .toolbar .primary-button { grid-column: 1 / 3; }
  .story-card { grid-template-columns: 10px minmax(0,1fr); }
  .story-side { display: none; }
}

/* CMS Red – robust editorial controls and radio planning layout */
body.is-resizing,
body.is-resizing * {
  cursor: col-resize !important;
  user-select: none !important;
}

@media (min-width: 901px) {
  .workspace {
    display: grid;
    grid-template-columns: minmax(320px, var(--left-column, 58%)) 8px minmax(320px, 1fr);
    overflow: hidden;
  }

  .app-shell { height: 100vh; overflow: hidden; }
  .panel { min-height: 0; }
}

.splitter {
  position: relative;
  cursor: col-resize;
  touch-action: none;
  outline: 0;
}
.splitter i {
  left: 2px;
  width: 4px;
  background: #8b9097;
  border-left: 1px solid #fff;
  border-right: 1px solid #fff;
  box-shadow: none;
  transition: background .12s, width .12s, left .12s;
}
.splitter:hover i,
.splitter:focus-visible i {
  left: 1px;
  width: 6px;
  background: var(--red);
}

.toolbar {
  grid-template-columns: minmax(240px, 1fr) 74px 82px;
}
.toolbar .primary-button {
  width: 82px;
  white-space: nowrap;
  padding: 0 6px;
}

.story-card {
  min-height: 76px;
  grid-template-columns: 30px minmax(0, 1fr);
  border: 1px solid #858a91;
  background: #f5f5f5;
}
.drag-handle {
  min-width: 30px;
  color: #fff;
  background: var(--story-color);
  border-right: 1px solid rgba(0, 0, 0, .22);
  padding: 5px 3px;
  font-size: 9px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .045em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.story-copy { padding: 8px 12px 7px; }
.story-copy h3 {
  min-height: 30px;
  margin: 0 0 6px;
  font-size: 14px;
  line-height: 1.22;
  color: #3f444a;
}
.story-meta {
  min-height: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #5f666e;
}
.type-badge,
.story-side,
.duration { display: none; }
.card-editors {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  margin-right: auto;
}
.card-editors > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
}
.card-avatar-stack { display: flex; align-items: center; padding-left: 3px; }
.avatar.card-avatar {
  width: 25px;
  height: 25px;
  flex: 0 0 25px;
  margin-left: -4px;
  border: 2px solid #f5f5f5;
  background: #555d67;
  box-shadow: 0 0 0 1px #9ca2a8;
  font-size: 8px;
}
.avatar.card-avatar.muted { background: #a7adb3; }
.traffic-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding-left: 10px;
  border-left: 1px solid #c8ccd0;
  white-space: nowrap;
}
.status-light {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1px solid #9b9fa4;
  background: #c8cbce;
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, .13);
}
.status-light.red.active { background: #c92933; border-color: #8f151d; box-shadow: 0 0 0 2px rgba(201, 41, 51, .15); }
.status-light.yellow.active { background: #e2b629; border-color: #9e7910; box-shadow: 0 0 0 2px rgba(226, 182, 41, .18); }
.status-light.green.active { background: #35a15d; border-color: #216c3d; box-shadow: 0 0 0 2px rgba(53, 161, 93, .16); }
.traffic-status b { margin-left: 3px; font-size: 9px; color: #555c64; }
.planned-mark { flex: 0 0 auto; }

.schedule-scroll { padding: 8px 8px 40px; }
.template-block {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  min-height: 118px;
  margin-bottom: 10px;
  border: 1px solid #858a91;
  background: #e8ebee;
}
.template-block > header { display: none; }
.template-rail {
  min-width: 50px;
  padding: 7px 4px;
  background: #4a4f57;
  color: #fff;
  border-right: 3px solid var(--red);
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 5px;
  overflow: hidden;
}
.template-rail b {
  min-height: 0;
  flex: 1;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  text-transform: uppercase;
  letter-spacing: .065em;
  font-size: 11px;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.template-rail span {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  color: #eef0f2;
  font-size: 9px;
  white-space: nowrap;
}
.template-rail small {
  width: 38px;
  padding-top: 5px;
  border-top: 1px solid #747981;
  color: #d2d6da;
  font-size: 8px;
  text-align: center;
}
.template-block .slot-list {
  min-width: 0;
  padding: 7px;
  background: #e4e7ea;
}
.broadcast-slot {
  grid-template-columns: 62px minmax(0, 1fr);
  min-height: 68px;
  margin-bottom: 7px;
  border: 1px solid #9da3aa;
  border-left: 8px solid var(--slot-color);
  background: #fff;
}
.slot-time {
  justify-content: center;
  padding: 0;
  background: #dfe3e6;
  border-right: 1px solid #aeb4ba;
}
.slot-time time { font-size: 15px; color: #34383d; }
.slot-body {
  display: grid;
  grid-template-columns: minmax(112px, 28%) minmax(0, 1fr);
}
.slot-label {
  height: auto;
  min-height: 66px;
  padding: 8px 10px;
  border: 0;
  border-right: 1px solid #c9cdd1;
  background: color-mix(in srgb, var(--slot-color) 10%, #f4f5f6);
}
.slot-label i {
  width: 8px;
  height: 32px;
  flex: 0 0 8px;
  background: var(--slot-color);
}
.slot-label b {
  font-size: 11px;
  line-height: 1.25;
  color: #454b51;
}
.slot-items {
  min-width: 0;
  padding: 6px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.empty-slot {
  min-height: 44px;
  height: auto;
  border: 2px dashed #b4bac0;
  background: #f7f8f9;
}
.empty-slot b { font-size: 10px; }
.scheduled-story { min-height: 44px; border-color: #9fa5ab; }
.scheduled-open { padding: 5px 7px 5px 0; }
.scheduled-open b { font-size: 11px; }
.remove-scheduled { min-width: 34px; }

.editor-modal {
  width: min(1080px, calc(100vw - 40px));
  height: min(820px, calc(100vh - 40px));
  max-height: none;
  border: 2px solid #636970;
}
.modal-head {
  min-height: 84px;
  padding: 15px 22px;
  border-bottom-width: 4px;
}
.modal-head h2 { max-width: 900px; font-size: 21px; }
.close-button { width: 40px; height: 40px; font-size: 25px; }
.editor-body {
  display: flex;
  min-height: 0;
  flex-direction: column;
  padding: 24px 28px;
  background: #f0f2f4;
}
.wide-field > input,
.form-row input,
.form-row select { height: 42px; border: 1px solid #858c94; }
.wide-field > input { height: 48px; font-size: 17px; }
.form-row.halves { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.wide-field:has(textarea) { flex: 1; min-height: 250px; }
.wide-field textarea {
  flex: 1;
  min-height: 270px;
  border: 1px solid #858c94;
  font-size: 16px;
  line-height: 1.52;
}
.editor-assignments {
  margin-top: 14px;
  padding: 13px;
  border: 1px solid #9fa5ab;
  background: #fff;
}
.account-checks > label {
  min-height: 48px;
  border-color: #aeb4ba;
  padding: 8px 10px;
}
.modal-footer { min-height: 70px; padding: 12px 18px; border-top-color: #999fa6; }
.modal-footer button { min-height: 38px; height: 38px; padding: 0 15px; font-size: 12px; }

.settings-page { background: #dfe3e7; }
.settings-top {
  height: 46px;
  flex-basis: 46px;
  padding: 0 14px;
  border-bottom: 3px solid var(--red);
}
.settings-mark { font-size: 19px; }
.settings-top > button { height: 32px; font-size: 11px; }
.settings-layout { grid-template-columns: 270px minmax(0, 1fr); }
.settings-layout > aside {
  padding: 18px 12px 14px;
  background: #cfd5db;
  border-right: 2px solid #8d949c;
}
.settings-layout > aside > div:first-child {
  padding: 4px 10px 18px;
  border-bottom: 1px solid #959ca4;
}
.settings-layout > aside h2 { font-size: 20px; font-weight: 600; }
.settings-layout aside nav { gap: 7px; margin-top: 14px; }
.settings-layout aside nav button {
  min-height: 66px;
  grid-template-columns: 34px minmax(0, 1fr);
  border: 1px solid #9da4ab;
  background: #e8ebee;
  padding: 10px 12px;
}
.settings-layout aside nav button > span { font-size: 20px; }
.settings-layout aside nav button b { font-size: 13px; }
.settings-layout aside nav button small { font-size: 10px; color: #707981; }
.settings-layout aside nav button:hover { background: #f4f5f6; }
.settings-layout aside nav button.active {
  padding-left: 8px;
  border-color: #737a82;
  border-left: 5px solid var(--red);
  background: #fff;
}
.settings-save-state { border-top-color: #969da5; color: #525a62; font-size: 10px; }
.settings-content { padding: 24px clamp(22px, 3vw, 46px) 60px; }
.settings-heading {
  max-width: 1240px;
  margin-bottom: 16px;
  padding: 17px 19px;
  align-items: center;
  border: 1px solid #8f969e;
  border-left: 7px solid var(--red);
  background: #fff;
}
.settings-heading h1 { margin: 4px 0; font-size: 23px; font-weight: 600; }
.settings-heading p { font-size: 12px; color: #5f6871; }
.settings-heading .primary-button { min-height: 38px; height: 38px; padding: 0 13px; }
.settings-cards,
.settings-table,
.type-settings-grid,
.account-summary,
.accounts-list { max-width: 1240px; }
.settings-card,
.type-settings-grid > article,
.settings-table,
.account-summary,
.accounts-list { border-color: #8f969d; box-shadow: none; }
.settings-card { padding: 18px; }
.settings-card-head { min-height: 54px; border-bottom-color: #aeb4ba; }
.settings-card-head .color-icon { width: 40px; height: 40px; }
.settings-card-head input { font-size: 15px; }
.settings-content input,
.settings-content select { height: 40px; border-color: #8f969d; font-size: 12px; }
.slot-assignment { border-top-color: #aeb4ba; }
.slot-assignment label { min-height: 30px; border-color: #a4abb2; font-size: 10px; }
.settings-table-head,
.settings-table-row {
  grid-template-columns: 90px minmax(260px, 1fr) 170px 58px;
}
.settings-table-head { min-height: 42px; font-size: 10px; background: #cbd1d7; border-bottom-color: #858c94; }
.settings-table-row { min-height: 66px; border-bottom-color: #b9bec4; }
.settings-table-row > input { height: 42px; }
.color-picker i { width: 40px; height: 34px; }
.delete-icon { width: 34px; height: 34px; font-size: 20px; border-color: #9fa6ad; }
.type-settings-grid { grid-template-columns: repeat(3, minmax(240px, 1fr)); gap: 16px; }
.type-settings-grid > article { padding: 16px; }
.type-preview {
  height: 82px;
  display: flex;
  align-items: center;
  margin-bottom: 16px;
  padding: 12px 12px 12px 42px;
  border: 1px solid #9299a0;
  background: #f4f5f6;
}
.type-preview > i { display: none; }
.type-preview > span { font-size: 13px; font-weight: 600; }
.type-preview > small {
  position: absolute;
  inset: -1px auto -1px -1px;
  width: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 2px;
  background: var(--type-color);
  color: #fff;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 9px;
  font-weight: 700;
}
.color-value { height: 40px; border-color: #8f969d; }
.color-value input { height: 38px; }
.account-summary > div { min-height: 88px; }
.account-summary span { font-size: 25px; font-weight: 600; }
.account-summary small { font-size: 10px; }
.accounts-list article {
  min-height: 100px;
  grid-template-columns: 62px minmax(180px, 1fr) minmax(220px, 1.25fr) 150px 150px;
  gap: 12px;
  padding: 13px 16px;
  border-bottom-color: #b9bec4;
}
.accounts-list .avatar.large { width: 48px; height: 48px; flex-basis: 48px; }

@media (max-width: 900px) {
  .workspace { display: flex; flex-direction: column; }
  .splitter { height: 10px; cursor: row-resize; }
  .splitter i { top: 3px; right: 0; bottom: auto; left: 0; width: auto; height: 4px; }
  .toolbar { grid-template-columns: minmax(0, 1fr) 74px 82px; }
  .template-block { grid-template-columns: 46px minmax(0, 1fr); }
  .settings-layout { grid-template-columns: 1fr; }
  .settings-layout > aside { border-right: 0; border-bottom: 2px solid #8d949c; }
  .settings-layout aside nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .settings-layout aside nav button { min-height: 54px; }
  .settings-layout aside nav button small { display: none; }
  .settings-table-head,
  .settings-table-row { min-width: 620px; }
  .type-settings-grid { grid-template-columns: repeat(2, minmax(240px, 1fr)); }
}

@media (max-width: 620px) {
  .toolbar { grid-template-columns: minmax(0, 1fr) 72px; }
  .toolbar .primary-button { grid-column: 1 / 3; width: 100%; }
  .story-card { grid-template-columns: 28px minmax(0, 1fr); }
  .traffic-status b,
  .card-editors > span:last-child,
  .planned-mark { display: none; }
  .slot-body { grid-template-columns: 1fr; }
  .slot-label { min-height: 34px; border-right: 0; border-bottom: 1px solid #c9cdd1; }
  .template-rail span { display: none; }
  .editor-modal { width: 100%; height: 100vh; }
  .form-row.halves { grid-template-columns: 1fr; }
  .type-settings-grid { grid-template-columns: 1fr; }
}

/* UI 5 – compact radio desk */
@media (min-width: 901px) {
  .workspace {
    grid-template-columns: minmax(320px, var(--left-column, 50%)) 8px minmax(320px, 1fr);
  }
}

.story-list { padding-top: 6px; }
.story-card {
  min-height: 58px;
  margin-bottom: 5px;
  grid-template-columns: 26px minmax(0, 1fr);
}
.drag-handle {
  min-width: 26px;
  padding: 4px 2px;
  font-size: 8px;
}
.story-copy { padding: 5px 9px 4px; }
.story-copy h3 {
  min-height: 0;
  margin: 0 0 3px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 13px;
  line-height: 1.16;
}
.story-meta { min-height: 22px; gap: 8px; }
.avatar.card-avatar {
  width: 20px;
  height: 20px;
  flex-basis: 20px;
  border-width: 1px;
  font-size: 7px;
}
.card-editors { gap: 5px; }
.status-light {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
}
.traffic-status { gap: 5px; padding-left: 8px; }
.traffic-status b { display: none; }
.planned-mark { padding: 1px 4px; }

.date-navigation { gap: 5px; }
.date-navigation label {
  width: auto;
  min-width: 0;
  flex: 0 0 auto;
  padding: 0 5px;
}
.date-navigation strong { min-width: 0; white-space: nowrap; }

.schedule-scroll { padding: 6px 6px 32px; }
.template-block {
  grid-template-columns: 34px minmax(0, 1fr);
  min-height: 0;
  margin-bottom: 7px;
}
.template-rail {
  min-width: 34px;
  padding: 5px 3px;
  border-right-width: 2px;
}
.template-rail > span {
  flex: 1;
  display: block;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  color: #fff;
  font-size: 11px;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.template-rail > span b { font-size: 12px; }
.template-block .slot-list { padding: 5px; }
.broadcast-slot {
  display: block;
  min-height: 0;
  margin-bottom: 5px;
  border: 0;
  background: transparent;
}
.broadcast-slot.drop-active {
  background: transparent;
  border: 0;
  box-shadow: 0 0 0 2px var(--red);
}
.slot-label {
  min-height: 23px;
  height: 23px;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0;
  border: 0;
  background: var(--slot-color);
  color: #fff;
}
.slot-label time {
  width: 50px;
  flex: 0 0 50px;
  height: 23px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid rgba(255,255,255,.45);
  background: rgba(0,0,0,.13);
  font-size: 11px;
  font-weight: 700;
}
.slot-label b {
  min-width: 0;
  padding: 0 8px;
  color: inherit;
  font-size: 11px;
  line-height: 1;
  text-transform: none;
  letter-spacing: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.slot-label i,
.slot-time,
.slot-body { display: none; }
.slot-items {
  min-height: 34px;
  padding: 3px;
  display: flex;
  justify-content: center;
  border: 1px solid #9ca2a8;
  border-top: 0;
  background: #fff;
}
.empty-slot {
  min-height: 27px;
  height: 27px;
  border: 1px dashed #b5bbc1;
  background: #f8f9f9;
}
.empty-slot b { font-size: 9px; }
.empty-slot span { display: none; }
.scheduled-story { min-height: 30px; margin-bottom: 2px; }
.scheduled-open { padding-top: 2px; padding-bottom: 2px; }
.scheduled-open small { display: none; }

.settings-top {
  height: 30px;
  flex-basis: 30px;
  padding: 0 10px;
  border-bottom-width: 1px;
}
.settings-top > div { gap: 10px; font-size: 10px; }
.settings-mark { padding-right: 10px; font-size: 16px; }
.settings-top > button { height: 22px; font-size: 9px; }
.settings-top > button b { font-size: 13px; }
.settings-layout { grid-template-columns: 235px minmax(0, 1fr); }
.settings-layout > aside { padding: 12px 9px 10px; }
.settings-layout > aside > div:first-child { padding: 2px 8px 11px; }
.settings-layout > aside h2 { margin-top: 3px; font-size: 16px; }
.settings-layout aside nav { gap: 4px; margin-top: 9px; }
.settings-layout aside nav button {
  min-height: 49px;
  grid-template-columns: 28px minmax(0, 1fr);
  padding: 6px 8px;
}
.settings-layout aside nav button > span { font-size: 16px; }
.settings-layout aside nav button b { font-size: 11px; }
.settings-layout aside nav button small { font-size: 9px; }
.settings-content { padding: 14px 18px 38px; }
.settings-heading {
  margin-bottom: 10px;
  padding: 9px 12px;
  border-left-width: 5px;
}
.settings-heading h1 { margin: 2px 0; font-size: 18px; }
.settings-heading p { font-size: 10px; }
.settings-heading .primary-button { min-height: 30px; height: 30px; }
.settings-cards { gap: 8px; }
.settings-card { padding: 11px; }
.settings-card-head { min-height: 42px; padding-bottom: 8px; }
.settings-card-head .color-icon { width: 32px; height: 32px; }
.settings-card-head input { font-size: 13px; }
.settings-form-grid { padding: 8px 0; }
.settings-content input,
.settings-content select { height: 33px; }
.slot-assignment { padding-top: 8px; }
.slot-assignment label { min-height: 25px; }
.settings-table-head { min-height: 30px; }
.settings-table-row { min-height: 47px; }
.settings-table-row > input { height: 33px; }
.color-picker i { width: 34px; height: 28px; }
.delete-icon { width: 28px; height: 28px; font-size: 17px; }
.type-settings-grid { gap: 9px; }
.type-settings-grid > article { padding: 10px; }
.type-preview { height: 58px; margin-bottom: 10px; }
.account-summary { margin-bottom: 9px; }
.account-summary > div { min-height: 58px; }
.account-summary span { font-size: 20px; }
.accounts-list article {
  min-height: 72px;
  grid-template-columns: 50px minmax(160px, 1fr) minmax(200px, 1.25fr) 130px 130px;
  gap: 8px;
  padding: 8px 11px;
}
.accounts-list .avatar.large { width: 38px; height: 38px; flex-basis: 38px; }

.editor-modal {
  width: min(1040px, calc(100vw - 36px));
  height: min(760px, calc(100vh - 36px));
}
.modal-head {
  min-height: 48px;
  padding: 7px 12px 7px 16px;
  border-bottom-width: 2px;
}
.modal-head h2 { margin-top: 2px; font-size: 15px; }
.close-button { width: 30px; height: 30px; font-size: 19px; }
.editor-body { padding: 13px 16px; }
.wide-field > input,
.form-row input,
.form-row select { height: 34px; }
.wide-field > input { height: 38px; font-size: 14px; }
.form-row { gap: 8px; margin: 9px 0; }
.wide-field textarea { min-height: 230px; padding: 9px; font-size: 14px; }
.editor-assignments { margin-top: 8px; padding: 8px; }
.account-checks { gap: 4px; }
.account-checks > label { min-height: 38px; padding: 4px 7px; }
.modal-footer { min-height: 50px; padding: 7px 10px; }
.modal-footer button { min-height: 30px; height: 30px; padding: 0 10px; }

.logout-button {
  height: 22px;
  padding: 0 8px;
  border: 1px solid #858b92;
  background: #34383e;
  color: #fff;
  cursor: pointer;
  font-size: 9px;
  text-transform: uppercase;
}
.logout-button:hover { background: #5a2026; border-color: #b74b54; }

.login-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: #dfe3e7;
  color: #41474e;
}
.login-panel {
  width: min(390px, 100%);
  border: 1px solid #777d84;
  background: #fff;
  box-shadow: 0 12px 35px rgba(28, 33, 39, .2);
}
.login-panel > header {
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  border-bottom: 2px solid var(--red);
  background: #424751;
  color: #fff;
}
.login-panel .wordmark { font-size: 19px; }
.login-panel > header > span:last-child { font-size: 9px; font-weight: 700; }
.login-panel form { padding: 22px 24px 24px; }
.login-panel h1 { margin: 3px 0; font-size: 21px; }
.login-panel p { margin: 0 0 18px; color: #747c84; font-size: 11px; }
.login-panel form > label { display: flex; flex-direction: column; gap: 4px; margin-bottom: 10px; }
.login-panel input { height: 36px; border: 1px solid #858c94; padding: 0 9px; }
.login-panel .primary-button { width: 100%; height: 34px; margin-top: 5px; }
.login-error { margin: 2px 0 8px; padding: 7px 9px; border: 1px solid #cf9298; background: #f8e8ea; color: #941f29; font-size: 10px; }
.login-check { min-height: 150px; display: flex; align-items: center; justify-content: center; gap: 8px; color: #687079; }
.login-check i { width: 9px; height: 9px; border-radius: 50%; background: #d2a13d; animation: pulse 1.1s infinite; }

/* UI 6 – exact header, profile menu and stronger drag interaction */
.topbar {
  height: 30px;
  min-height: 30px;
  flex-basis: 30px;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 0 10px;
  overflow: visible;
  background: #424751;
  border-bottom: 1px solid #333840;
}
.brand { height: 30px; padding: 0; }
.brand img { height: 100%; max-height: 30px; width: auto; max-width: 230px; object-fit: contain; }
.top-actions { gap: 10px; }
.cloud-state { min-width: 68px; justify-content: flex-end; color: #f1f3f5; }
.read-button {
  height: 22px;
  min-height: 22px;
  margin: 1px;
  padding: 2px 8px;
  border: 1px solid #8e9197;
  border-radius: 2px;
  background: transparent;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}
.profile-menu-wrap { position: relative; height: 24px; z-index: 30; }
.profile-menu-wrap .account-button {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
}
.profile-menu-wrap .account-button .avatar {
  width: 22px;
  height: 22px;
  flex-basis: 22px;
  border: 1px solid rgba(255,255,255,.7);
  font-size: 8px;
}
.profile-menu-wrap .account-button:hover .avatar,
.profile-menu-wrap .account-button[aria-expanded="true"] .avatar { box-shadow: 0 0 0 2px rgba(255,255,255,.28); }
.profile-menu-scrim {
  position: fixed;
  inset: 0;
  z-index: 1;
  border: 0;
  background: transparent;
  cursor: default;
}
.profile-dropdown {
  position: absolute;
  top: 28px;
  right: 0;
  z-index: 2;
  width: 210px;
  border: 1px solid #747a81;
  background: #fff;
  color: #3e454d;
  box-shadow: 0 8px 22px rgba(25,30,36,.24);
}
.profile-dropdown > header {
  min-height: 55px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-bottom: 1px solid #aeb4ba;
  background: #e2e6e9;
}
.profile-dropdown > header > span:last-child { min-width: 0; display: flex; flex-direction: column; }
.profile-dropdown > header b { font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-dropdown > header small { margin-top: 2px; color: #767f88; font-size: 9px; }
.profile-dropdown > button {
  width: 100%;
  height: 34px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 10px;
  border: 0;
  border-bottom: 1px solid #d2d6da;
  background: #fff;
  color: #424a52;
  text-align: left;
  cursor: pointer;
  font-size: 11px;
}
.profile-dropdown > button:last-child { border-bottom: 0; }
.profile-dropdown > button:hover { background: #eef1f3; }
.profile-dropdown > button span { width: 18px; color: #6c747c; text-align: center; }

.story-card { min-height: 64px; }
.story-copy {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 5px 9px 4px;
}
.story-copy h3 {
  margin-bottom: 4px;
  padding-right: 0;
  font-size: 15px;
  line-height: 1.14;
}
.story-card.is-scheduled .story-copy h3 { padding-right: 70px; }
.story-meta {
  min-height: 24px;
  margin-top: auto;
  align-items: flex-end;
}
.avatar.card-avatar {
  width: 24px;
  height: 24px;
  flex-basis: 24px;
  border-radius: 50%;
  font-size: 8px;
}
.traffic-status { align-self: flex-end; padding-bottom: 2px; }
.planned-mark {
  position: absolute;
  top: 5px;
  right: 7px;
  padding: 2px 4px;
  background: #fff;
  font-size: 8px;
}
.scheduled-open b { font-size: 13px; line-height: 1.15; }
.scheduled-story { min-height: 33px; }

.story-card.dragging,
.scheduled-story.dragging {
  opacity: .4;
  cursor: grabbing;
}
.story-card.dragging { border-style: dashed; }
.drag-handle { cursor: grab; }
.broadcast-slot .slot-items { transition: background .12s, box-shadow .12s, min-height .12s; }
.broadcast-slot.drop-active { box-shadow: none; }
.broadcast-slot.drop-active .slot-items {
  min-height: 43px;
  background: #fff1f2;
  box-shadow: inset 0 0 0 2px var(--red);
}
.broadcast-slot.drop-active .empty-slot {
  border-color: var(--red);
  color: var(--red);
}

.login-panel > header {
  height: 46px;
  justify-content: flex-start;
  overflow: hidden;
}
.login-panel > header img {
  height: 100%;
  max-height: 46px;
  width: auto;
  max-width: 250px;
  object-fit: contain;
  object-position: left center;
}

/* UI 7 – persistent planning links, native drag flow and rebuilt settings */
.planned-mark {
  cursor: pointer;
  font-family: inherit;
  line-height: 1.2;
}
.planned-mark:hover { border-color: var(--red); color: var(--red); background: #fff4f5; }
.scheduled-story.jump-highlight {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(190,30,45,.24);
  animation: placementJump 1.7s ease-out;
}
@keyframes placementJump {
  0%, 35% { background: #ffe3e6; }
  100% { background: #fff; }
}
body.is-dragging-story .broadcast-slot .slot-items {
  border-style: dashed;
  border-color: #7f878f;
}
body.is-dragging-story .broadcast-slot .empty-slot { color: #666f77; }

.placement-backdrop { z-index: 58; }
.placement-picker {
  width: min(680px, calc(100vw - 36px));
  max-height: min(620px, calc(100vh - 36px));
  display: flex;
  flex-direction: column;
  border: 2px solid #60666d;
  background: #eef1f3;
  box-shadow: 0 16px 45px rgba(25,30,36,.3);
}
.placement-picker > header {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 8px 10px 8px 15px;
  border-bottom: 3px solid var(--red);
  background: #424751;
  color: #fff;
}
.placement-picker > header .eyebrow { color: #d5d9dd; }
.placement-picker > header h2 { margin: 2px 0 0; font-size: 15px; font-weight: 600; }
.placement-picker > p { margin: 0; padding: 12px 15px; border-bottom: 1px solid #a8afb6; color: #555e67; }
.placement-picker > div { min-height: 0; overflow: auto; padding: 10px; }
.placement-picker > div > button {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 130px minmax(0,1fr) 90px;
  align-items: center;
  gap: 12px;
  margin-bottom: 7px;
  padding: 7px 10px;
  border: 1px solid #8d949b;
  border-left: 7px solid var(--red);
  background: #fff;
  color: #3e464e;
  text-align: left;
  cursor: pointer;
}
.placement-picker > div > button:hover { background: #f8e9eb; border-color: #7a8087; border-left-color: var(--red); }
.placement-picker time { font-size: 12px; font-weight: 700; text-transform: capitalize; }
.placement-picker button > span { min-width: 0; display: flex; flex-direction: column; }
.placement-picker button > span b { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.placement-picker button > span small { margin-top: 3px; color: #727b84; }
.placement-picker button > strong { color: var(--red); font-size: 10px; text-align: right; text-transform: uppercase; }

.settings-top {
  height: 30px;
  min-height: 30px;
  flex-basis: 30px;
  padding: 0 10px;
  border-bottom: 1px solid #333840;
  background: #424751;
}
.settings-brand { height: 30px; display: flex; align-items: center; gap: 11px; }
.settings-brand img { height: 30px; max-height: 30px; width: auto; max-width: 230px; object-fit: contain; }
.settings-brand .wordmark { font-size: 19px; }
.settings-brand > strong {
  height: 20px;
  display: inline-flex;
  align-items: center;
  padding-left: 11px;
  border-left: 1px solid #737982;
  color: #f1f3f5;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.settings-top > button { height: 22px; padding: 0 8px; border-color: #8e9197; background: transparent; }
.settings-layout { grid-template-columns: 270px minmax(0,1fr); background: #d9dee2; }
.settings-layout > aside {
  padding: 0 10px 12px;
  border-right: 2px solid #777f87;
  background: #bfc6cc;
}
.settings-layout > aside > .settings-side-head {
  margin: 0 -10px;
  padding: 18px 17px 16px;
  border-bottom: 2px solid #7d858d;
  background: #e7eaed;
}
.settings-side-head h2 { margin: 3px 0 6px !important; font-size: 19px !important; font-weight: 700 !important; }
.settings-side-head p { margin: 0; color: #5e6871; font-size: 11px; line-height: 1.38; }
.settings-layout aside nav { gap: 5px; margin-top: 0; }
.settings-nav-group {
  display: block;
  margin: 13px 2px 2px;
  color: #454d55;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.settings-layout aside nav button {
  min-height: 61px;
  grid-template-columns: 38px minmax(0,1fr);
  padding: 8px 10px;
  border: 1px solid #7e868e;
  background: #e8ebed;
  color: #343c44;
}
.settings-layout aside nav button > span {
  width: 30px;
  height: 30px;
  grid-row: 1 / 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  border: 1px solid #8c939a;
  background: #cbd1d6;
  color: #4a535b;
  font-size: 10px;
  font-weight: 800;
}
.settings-layout aside nav button b { align-self: end; font-size: 13px; }
.settings-layout aside nav button small { align-self: start; margin-top: 2px; color: #68727b; font-size: 10px; }
.settings-layout aside nav button.active {
  padding-left: 7px;
  border: 2px solid #666e76;
  border-left: 6px solid var(--red);
  background: #fff;
}
.settings-layout aside nav button.active > span { border-color: #9a1b26; background: var(--red); color: #fff; }
.settings-save-state { border-top: 2px solid #858d94; color: #414a52; font-size: 10px; }

.settings-content { padding: 18px 22px 48px; background: #e1e5e8; }
.settings-heading {
  max-width: 1300px;
  min-height: 88px;
  margin-bottom: 14px;
  padding: 15px 18px;
  border: 2px solid #767e86;
  border-left: 9px solid var(--red);
  background: #fff;
}
.settings-heading h1 { margin: 3px 0 4px; color: #2f3740; font-size: 23px; font-weight: 750; }
.settings-heading p { max-width: 720px; color: #59636c; font-size: 12px; }
.settings-heading .primary-button { min-height: 38px; height: 38px; padding: 0 14px; font-size: 12px; }
.settings-cards,
.settings-table,
.type-settings-grid,
.account-summary,
.accounts-list { max-width: 1300px; }
.settings-cards { grid-template-columns: 1fr; gap: 12px; }
.settings-card {
  padding: 16px 18px;
  border: 2px solid #7e868e;
  background: #fff;
}
.settings-card-head {
  min-height: 68px;
  grid-template-columns: 52px minmax(0,1fr) 36px;
  gap: 13px;
  padding-bottom: 13px;
  border-bottom: 2px solid #b1b7bd;
}
.settings-item-index {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #4a5058;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}
.settings-card-head > div { gap: 3px; }
.settings-card-head input { height: 38px; border: 1px solid #858d95; padding: 0 9px; font-size: 15px; }
.settings-card-head small { font-size: 10px; }
.settings-form-grid { gap: 13px; padding: 14px 0; }
.settings-content input,
.settings-content select { height: 40px; border: 1px solid #7f878f; padding: 0 10px; font-size: 13px; }
.field-label { font-size: 10px; }
.slot-assignment { padding-top: 13px; border-top: 2px solid #b1b7bd; }
.slot-assignment > div { max-height: 170px; gap: 7px; }
.slot-assignment label { min-height: 34px; padding: 6px 9px; border: 1px solid #858d95; font-size: 11px; }
.settings-table { border: 2px solid #767e86; }
.settings-table-head { min-height: 44px; border-bottom: 2px solid #767e86; background: #bfc6cc; font-size: 10px; }
.settings-table-row { min-height: 64px; border-bottom: 1px solid #9ba2a9; }
.settings-table-row > input { height: 42px; font-size: 13px; }
.color-picker i { width: 44px; height: 36px; border: 2px solid rgba(0,0,0,.18); }
.delete-icon { width: 34px; height: 34px; border: 1px solid #858d95; font-size: 20px; }
.type-settings-grid { grid-template-columns: repeat(2, minmax(300px,1fr)); gap: 12px; }
.type-settings-grid > article { padding: 15px; border: 2px solid #7e868e; }
.type-preview { height: 76px; margin-bottom: 14px; border: 1px solid #858d95; }
.type-settings-grid article > label { margin-bottom: 12px; }
.color-value { height: 40px; border: 1px solid #7f878f; }
.account-summary { margin-bottom: 12px; border: 2px solid #767e86; }
.account-summary > div { min-height: 78px; border-right: 2px solid #adb3b9; }
.account-summary span { font-size: 26px; font-weight: 800; }
.account-summary small { font-size: 10px; }
.accounts-list { border: 2px solid #767e86; }
.accounts-list article {
  min-height: 94px;
  grid-template-columns: 62px minmax(170px,1fr) minmax(220px,1.25fr) 145px 145px;
  gap: 12px;
  padding: 12px 15px;
  border-bottom: 1px solid #9ba2a9;
}
.accounts-list .avatar.large { width: 48px; height: 48px; flex-basis: 48px; font-size: 12px; }

@media (max-width: 900px) {
  .settings-layout { grid-template-columns: 1fr; }
  .settings-layout > aside { border-right: 0; border-bottom: 2px solid #777f87; }
  .settings-layout > aside > .settings-side-head { display: none; }
  .settings-layout aside nav { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; padding-top: 8px; }
  .settings-nav-group { display: none; }
  .type-settings-grid { grid-template-columns: 1fr; }
}
