/* Keep the existing editorial board; only program-specific controls and modals. */
.cast-program-selector { display: flex; flex-wrap: wrap; gap: 4px; width: fit-content; margin: 0 0 14px; padding: 4px; border: 1px solid #ccd6dc; border-radius: 9px; background: #eef2f4; }
.cast-program-selector button { min-height: 40px; padding: 0 22px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: #415763; font: inherit; font-weight: 800; cursor: pointer; }
.cast-program-selector button.active { background: #0b3548; color: #fff; }
.cast-program-selector button:focus-visible, .cast-program-modal button:focus-visible { outline: 3px solid #2679ee; outline-offset: 2px; }
.cast-program-unscheduled { margin-bottom: 15px; border: 1px solid #ccd6dc; border-radius: 8px; background: #fff; overflow: hidden; }
.cast-program-unscheduled > header { padding: 14px 18px; border-bottom: 1px solid #e3e9e9; }
.cast-program-unscheduled > .cast-planning-card-lane { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; padding: 12px; }
.cast-program-card { border-left: 4px solid #168675; }
.cast-program-plan .cast-planning-week > .cast-planning-card-lane.is-date-ordered { grid-template-columns: repeat(auto-fill, minmax(min(100%, max(250px, calc((100% - 40px) / 5))), 1fr)); }
.cast-program-card .cast-role-badge { white-space: nowrap; }
.cast-program-card > button > strong { white-space: normal; overflow-wrap: anywhere; }
.cast-program-card > button > strong { font-size: 17px; line-height: 1.45; }
.cast-program-card > button > span { font-size: 14px; }
.cast-program-card.is-recurring-placeholder { border-style: dashed; background: #f8fbfa; }
.cast-program-modal { width: min(900px, calc(100vw - 40px)); }
.cast-program-modal .cast-period-choice > div { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.cast-program-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 16px 0; }
.cast-program-fields > .full { grid-column: 1 / -1; }
.cast-program-fields label { display: grid; gap: 7px; font-size: 14px; color: #28434e; }
.cast-program-fields label > span { font-weight: 750; }
.cast-program-fields small { color: #71828a; font-size: 12px; font-weight: 400; }
.cast-program-fields input:not([type="checkbox"]), .cast-program-fields select, .cast-program-fields textarea { width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid #cad6dd; border-radius: 7px; background: #fff; font: inherit; color: #172b36; box-sizing: border-box; }
.cast-program-fields textarea { resize: vertical; }
.cast-program-detail { border-top: 1px solid #dfe7e9; padding: 14px 0; }
.cast-program-detail > summary { color: #244b57; font-weight: 750; cursor: pointer; }
.cast-program-confirm-shoot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; color: #667b85; font-size: 13px; }
.cast-program-modal .cast-slot-role-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cast-focus-settings-modal { width: min(580px, calc(100vw - 40px)); }
.cast-program-fields .cast-focus-enabled { display: flex; align-items: center; gap: 10px; }
@media (max-width: 650px) {
  .cast-program-selector { width: 100%; }
  .cast-program-selector button { flex: 1; padding: 0 10px; }
  .cast-program-fields, .cast-program-modal .cast-slot-role-grid { grid-template-columns: 1fr; }
  .cast-program-modal { width: calc(100vw - 20px); }
}

/* Two compact header rows keep the weekly board close to the page title. */
.cast-management-shell { gap: 12px; }
.cast-management-shell .cast-month-plan-dashboard { padding: 0; margin: 0; }
.cast-management-shell .cast-management-head { margin-bottom: 0; }
.cast-management-head { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; padding: 18px 22px; margin-bottom: 12px; }
.cast-management-head > div:first-child { flex: 0 0 auto; }
.cast-management-head h2 { font-size: 21px; letter-spacing: -.6px; white-space: nowrap; }
.cast-management-head .cast-management-eyebrow { display: none; }
.cast-management-head .cast-program-selector { margin: 0; padding: 3px; border: 0; background: #edf3f2; }
.cast-management-head .cast-program-selector button { min-height: 36px; padding: 0 14px; font-size: 13px; }
.cast-management-head-actions { margin-left: auto; }
.cast-management-head .cast-month-controls { gap: 6px; }
.cast-management-head .cast-month-controls button { min-width: 30px; padding: 6px 9px; }
.cast-month-plan-dashboard { margin: 0 0 12px; border-radius: 12px; box-shadow: none; }
.cast-month-plan-dashboard > header { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; padding: 14px 20px; }
.cast-month-plan-dashboard > header h3 { margin: 0; font-size: 16px; white-space: nowrap; }
.cast-month-plan-dashboard > header > div:first-child > p, .cast-dashboard-kicker { display: none; }
.cast-month-plan-dashboard .cast-schedule-view-tabs { padding: 3px; gap: 3px; background: #f0f4f4; border: none; border-radius: 8px; }
.cast-month-plan-dashboard .cast-schedule-view-tabs button { min-height: 34px; padding: 7px 13px; font-size: 13px; box-shadow: none; border-radius: 6px; }
.cast-month-plan-dashboard .cast-dashboard-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.cast-report-filters { position: relative; font-size: 12px; }
.cast-report-filters > summary { cursor: pointer; padding: 9px; color: #49636b; }
.cast-report-filters > .cast-content-filters { position: absolute; z-index: 15; top: 100%; right: 0; min-width: 280px; padding: 10px; border: 1px solid #dbe5e5; background: white; box-shadow: 0 10px 30px #173a491a; border-radius: 8px; }
.cast-management-shell .cast-planning-week { border-radius: 12px; overflow: hidden; }
.cast-management-shell .cast-planning-card-lane { gap: 12px; }
.cast-failure-action { display: block; flex: 0 0 auto; align-self: flex-start; margin: 0 16px 12px; padding: 5px 0; border: 0; background: transparent; color: #8a6e6e; font: inherit; font-size: 11px; cursor: pointer; }
.cast-failure-action:hover { color: #9a3434; text-decoration: underline; }
.cast-planning-card > .cast-failure-action, .cast-planning-live-card > .cast-failure-action { display: block; flex: none; width: auto; height: auto; min-height: 0; padding: 5px 0; margin: 0 18px 14px; font-size: 11px; color: #8a6e6e; background: transparent; text-align: left; }
.modal-foot .cast-failure-action { margin: 0; padding: 10px; }
.cast-failed-card { border-left: 3px solid #b79999; background: #f9f5f5; min-height: 220px; }
.cast-failed-card > header > b { color: #8e4d4d; background: #efe3e3; }
.cast-failed-card > button:not(.cast-failure-action) { display: grid; gap: 12px; text-align: left; padding: 16px; }
.cast-failed-card > button > strong { font-size: 17px; color: #665455; }
.cast-failed-card > button > span, .cast-failed-card > button > small { color: #8a7676; font-size: 12px; }
.cast-solo-card { min-height: 230px; border: 1px solid #dce7e5; border-top: 3px solid #238877; border-radius: 12px; box-shadow: 0 3px 9px #29483d06; }
.cast-solo-card > header { justify-content: flex-start; padding: 16px 18px 0; }
.cast-solo-card > button:not(.cast-failure-action) { padding: 18px; gap: 10px; }
.cast-solo-card > button > strong { font-size: 16px; font-weight: 750; line-height: 1.5; white-space: normal; word-break: keep-all; }
.cast-solo-card > button > span { color: #6a7d82; font-size: 13px; }
.cast-solo-onair { display: flex; align-items: center; justify-content: space-between; margin-top: 18px; padding-top: 12px; border-top: 1px solid #e8efed; }
.cast-solo-onair > small { color: #728983; font-size: 12px; }
.cast-solo-onair > b { color: #146859; font-size: 20px; letter-spacing: -.5px; }
.modal.cast-slot-modal.cast-solo-editorial { display: flex; flex-direction: column; overflow: hidden; width: min(760px, calc(100vw - 32px)); border-radius: 18px; }
.cast-solo-editorial > .modal-head, .cast-solo-editorial > .modal-foot { flex-shrink: 0; }
.cast-management-shell .cast-month-plan-dashboard > header { min-height: 0; padding: 14px 20px; flex-direction: row; }
.cast-solo-editorial > .modal-head { padding: 24px 28px 18px; border-bottom: 1px solid #edf1f0; }
.cast-solo-editorial > .modal-head h2 { margin: 6px 0 0; font-size: 24px; letter-spacing: -.6px; }
.cast-solo-editorial > .modal-body { min-height: 0; overflow-y: auto; padding: 22px 28px; }
.cast-solo-weeks { margin: 0 0 24px; padding: 0; border: 0; }
.cast-solo-weeks > legend { margin-bottom: 10px; font-weight: 700; font-size: 13px; color: #637970; }
.cast-solo-weeks > div { display: flex; flex-wrap: wrap; gap: 6px; }
.cast-solo-weeks label { position: relative; cursor: pointer; }
.cast-solo-weeks input { position: absolute; opacity: 0; width: 1px; }
.cast-solo-weeks label > span { display: block; padding: 9px 11px; border-radius: 7px; border: 1px solid #dce5e1; color: #65776f; font-size: 12px; }
.cast-solo-weeks input:checked + span { background: #e6f4ee; border-color: #38937c; color: #145c49; font-weight: 700; }
.cast-solo-weeks input:focus-visible + span { outline: 2px solid #2679ee; outline-offset: 2px; }
.cast-solo-topic { display: grid; gap: 10px; font-size: 15px; font-weight: 700; color: #294c41; }
.cast-solo-topic input { width: 100%; box-sizing: border-box; padding: 15px; border: 1px solid #cfded6; border-radius: 10px; font: inherit; font-size: 18px; color: #193c2e; background: #fbfdfc; }
.cast-solo-topic input::placeholder { font-size: 15px; font-weight: 400; color: #8ba096; }
.cast-solo-air { margin: 26px 0 18px; padding: 18px; border-radius: 12px; background: #f3f7f5; }
.cast-solo-air-heading { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.cast-solo-air-heading > span, .cast-solo-air-hint { color: #819188; font-size: 12px; }
.cast-air-days { display: grid; grid-template-columns: repeat(7, 1fr) 1.2fr; gap: 6px; }
.cast-air-days button { display: grid; gap: 5px; align-content: center; min-height: 58px; padding: 8px 0; background: white; border: 1px solid #dbe6df; border-radius: 8px; color: #708276; font: inherit; font-size: 12px; cursor: pointer; }
.cast-air-days button strong { font-size: 18px; color: #325a45; }
.cast-air-days button.active { background: #175f4b; border-color: #175f4b; color: #d0e7db; }
.cast-air-days button.active strong { color: white; }
.cast-solo-reverse-guide { display: flex; justify-content: space-between; gap: 8px; margin-top: 15px; font-size: 11px; color: #738779; }
.cast-solo-reverse-guide b { display: block; margin-top: 5px; font-size: 13px; color: #38634c; }
.cast-solo-reverse-guide i { align-self: center; font-style: normal; }
.cast-solo-matching, .cast-solo-more { border-top: 1px solid #e5ebe7; padding: 15px 0; }
.cast-solo-matching > summary, .cast-solo-more > summary { cursor: pointer; font-size: 14px; font-weight: 700; color: #3f6050; }
.cast-solo-matching > summary > span { margin-left: 12px; font-size: 12px; font-weight: 400; color: #8b9c91; }
.cast-solo-matching > .cast-slot-role-grid { margin-top: 16px; }
.cast-solo-editorial > .modal-foot { padding: 16px 28px; background: #fbfcfb; }
@media (max-width: 1200px) {
  .cast-management-head h2 { font-size: 18px; }
  .cast-management-head { gap: 12px; }
  .cast-management-head .cast-program-selector button { padding: 0 10px; font-size: 12px; }
  .cast-month-plan-dashboard > header { gap: 10px; }
  .cast-month-plan-dashboard .cast-dashboard-actions { flex-wrap: wrap; }
}
@media (max-width: 650px) {
  .cast-management-head .cast-program-selector { width: auto; }
  .cast-management-head-actions { margin: 0; }
  .cast-month-plan-dashboard .cast-schedule-view-tabs { width: 100%; }
  .cast-month-plan-dashboard .cast-schedule-view-tabs button { flex: 1; padding: 7px 6px; }
  .cast-solo-editorial > .modal-head, .cast-solo-editorial > .modal-body, .cast-solo-editorial > .modal-foot { padding: 16px; }
  .cast-solo-air { padding: 12px; }
  .cast-air-days { gap: 3px; }
}

/* Preserve existing information hierarchy while improving text contrast and size. */
.cast-management-shell .cast-planning-card, .cast-management-shell .cast-planning-live-card { position: relative; overflow: visible; height: 100%; min-height: 260px; align-self: stretch; }
.cast-management-shell .cast-planning-ordered-item { align-self: stretch; }
.cast-management-shell .cast-planning-card-lane { align-items: stretch; grid-auto-rows: 1fr; }
.cast-management-shell .cast-planning-card { display: flex; flex-direction: column; }
.cast-management-shell .cast-planning-card > button > strong, .cast-management-shell .cast-planning-live-card > button > strong { display: block; max-height: none; overflow: visible; white-space: normal; text-overflow: clip; word-break: keep-all; overflow-wrap: anywhere; font-size: 18px; font-weight: 800; line-height: 1.4; letter-spacing: -.4px; color: #173b48; }
.cast-management-shell .cast-program-card > button > span, .cast-management-shell .cast-planning-card .cast-card-person, .cast-management-shell .cast-planning-live-card .cast-card-person { color: #123e4a; font-size: 19px; font-weight: 750; line-height: 1.5; word-break: keep-all; }
.cast-management-shell .cast-planning-card .cast-card-category { color: #173b48; font-size: 18px; font-weight: 800; }
.cast-management-shell .cast-planning-card > button > .cast-card-topic { color: #315863; font-size: 14px; font-weight: 650; line-height: 1.45; white-space: normal; }
.cast-management-shell .cast-planning-card .cast-card-meta { display: block; min-width: 0; }
.cast-management-shell .cast-planning-card .cast-card-meta > span { white-space: normal; }
.cast-management-shell .cast-planning-card > button { grid-template-columns: minmax(0, 1fr); }
.cast-management-shell .cast-planning-card .cast-card-importance { color: #48606b; font-size: 13px; font-weight: 500; }
.cast-management-shell .cast-planning-card > button { display: flex; flex: none; flex-direction: column; align-items: stretch; height: auto; min-height: 0; }
.cast-management-shell .cast-planning-card .cast-card-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; }
.cast-management-shell .cast-planning-card .cast-card-importance { flex: 0 1 auto; min-width: 0; font-size: 12px; line-height: 1.4; text-align: right; }
.cast-management-shell .cast-planning-live-card { display: flex; flex-direction: column; }
.cast-management-shell .cast-planning-live-card > button { display: flex; flex: none; flex-direction: column; box-sizing: border-box; height: auto; min-height: 0; gap: 10px; padding: 24px 20px 16px; }
.cast-management-shell .cast-planning-live-card > button > b { order: 1; }
.cast-management-shell .cast-planning-live-card > button > .cast-card-person { order: 2; margin: 10px 0 0; }
.cast-management-shell .cast-program-card > button > span { order: 2; margin-top: 8px; }
.cast-management-shell .cast-planning-card .cast-card-person,
.cast-management-shell .cast-planning-live-card .cast-card-person,
.cast-management-shell .cast-program-card > button > span,
.cast-management-shell .cast-card-simple-content > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-self: start;
  align-self: flex-start;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0 8px;
  border-radius: 6px;
  background: #edf4f1;
  box-shadow: inset 0 0 0 1px #d5e4dd;
  color: #214f43;
  font-size: 17px;
  font-weight: 750;
  line-height: 28.5px;
  white-space: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
}
.cast-management-shell .cast-planning-card .cast-card-person::before,
.cast-management-shell .cast-planning-live-card .cast-card-person::before,
.cast-management-shell .cast-program-card > button > span::before,
.cast-management-shell .cast-card-simple-content > span::before {
  content: "";
  flex: 0 0 14px;
  width: 14px;
  height: 14px;
  background: #527d6b;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='8' r='4' fill='none' stroke='black' stroke-width='1.8'/%3E%3Cpath d='M4 21v-2a8 8 0 0 1 16 0v2' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.cast-management-shell .cast-planning-card > header b, .cast-management-shell .cast-planning-card .cast-role-badge { font-size: 12px; }
.cast-management-shell .cast-planning-card > button dl { min-height: 0; gap: 4px; margin: 5px 0; }
.cast-management-shell .cast-planning-card > button dl div { grid-template-columns: 90px minmax(0, 1fr); }
.cast-management-shell .cast-planning-card > button dt { color: #45626b; font-size: 13px; }
.cast-management-shell .cast-planning-card > button dd { color: #224e59; font-size: 14px; }
.cast-management-shell .cast-planning-card > button > small, .cast-management-shell .cast-planning-live-card > button > small { color: #48606b; font-size: 13px; line-height: 1.5; }
.cast-management-shell .cast-planning-live-card > button > b { font-size: 16px; line-height: 1.5; color: #58343b; }
.cast-management-shell .cast-planning-live-card > button > header { padding-right: 60px; }
.cast-management-shell .cast-planning-drag-handle { opacity: .45; }
.cast-management-shell .cast-planning-ordered-item:hover .cast-planning-drag-handle { opacity: 1; }
.modal-foot .cast-modal-failure { display: inline-flex; flex: 0 0 auto; }
.modal-foot .cast-modal-failure .cast-failure-action { position: static; min-height: 42px; padding: 9px 14px; margin: 0; width: fit-content; border: 1px solid #b5bec5; border-radius: 7px; color: #46515b; background: #f2f4f6; font-size: 13px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.modal-foot .cast-modal-failure .cast-failure-action:hover { color: #29343d; background: #e5e9ed; text-decoration: none; }
.modal-foot .cast-modal-failure .cast-failure-action[aria-pressed="true"] { border-color: #89959f; background: #e5e9ed; color: #35424c; }
.cast-program-modal [data-cast-delete-slot] { color: #b03545; border: 1px solid #e5b9bf; background: #fff7f8; }
.cast-program-modal [data-cast-delete-slot]:hover { background: #fbe8eb; }
.cast-slot-modal .modal-foot > div, .cast-program-info-modal .modal-foot > div { flex-wrap: wrap; }
.modal-body > .cast-failure-reason { display: grid; gap: 10px; width: 100%; box-sizing: border-box; margin: 0 0 16px; padding: 16px; border: 1px solid #cbd2d8; border-left: 4px solid #89959f; border-radius: 8px; background: #f2f4f6; }
.cast-failure-summary-title { color: #35424c; font-size: 16px; font-weight: 800; }
.cast-failure-reason small { color: #66727c; font-size: 12px; line-height: 1.5; }
.modal-body > .cast-failure-reason[hidden] { display: none; }
.cast-failure-reason label { display: grid; gap: 8px; }
.cast-failure-reason label > span { color: #46515b; font-size: 14px; font-weight: 800; }
.cast-failure-reason textarea { box-sizing: border-box; width: 100%; min-height: 82px; padding: 12px; border: 1px solid #b5bec5; border-radius: 7px; background: white; color: #283d47; font: inherit; font-size: 15px; line-height: 1.5; resize: vertical; }
.cast-failure-reason textarea:focus-visible, .cast-modal-failure button:focus-visible { outline: 3px solid #317fbb; outline-offset: 2px; }
.cast-management-shell .is-planning-failed { border: 2px solid #aeb5bb; background: #f1f3f4; filter: grayscale(1); opacity: 1; }
.cast-failure-banner { flex-shrink: 0; margin-top: auto; padding: 6px 12px; border-top: 1px solid #d2d7db; border-radius: 0 0 9px 9px; color: #505a63; background: #e2e6e9; font-size: 14px; font-weight: 800; }
.cast-planning-live-card > .cast-failure-banner { margin: auto 12px 12px; }
.cast-management-shell .cast-planning-live-card.is-planning-failed > button { padding-bottom: 16px; }
.cast-management-shell .cast-board-view-toggle { min-height: 36px; padding: 8px 14px; border: 1px solid #307b6a; border-radius: 8px; background: #eaf5f0; color: #165746; font-size: 14px; font-weight: 750; cursor: pointer; }
.cast-management-shell .cast-board-view-toggle.active { background: #195f4d; color: white; }
/* Switching content keeps the original cards, grid, heights and week expansion. */
.cast-card-simple-content { display: none; position: absolute; inset: 50px 16px 16px; pointer-events: none; overflow: hidden; }
.is-simple-content .cast-card-simple-content { display: flex; flex-direction: column; gap: 14px; }
.is-simple-content .cast-planning-card > header,
.is-simple-content .cast-planning-card > button > *,
.is-simple-content .cast-planning-live-card > button > * { visibility: hidden; }
.cast-card-simple-content > strong { color: #173b48; font-size: 18px; font-weight: 800; line-height: 1.4; word-break: keep-all; overflow-wrap: anywhere; }
.cast-card-simple-content > span { color: #123e4a; font-size: 16px; font-weight: 750; line-height: 1.5; word-break: keep-all; }
.is-planning-failed > .cast-card-simple-content { bottom: 52px; }
.cast-board-view-toggle:focus-visible { outline: 3px solid #3687cc; outline-offset: 2px; }

/* Double-click opens card details; keep the same arrow as recorded cards. */
.cast-management-shell .cast-planning-live-card > button { cursor: default; }
