:root {
  color-scheme: light;
  --ink: #1e293b;
  --accent: #c25e3e;
  --muted: #64748b;
  --border: #cbd5e1;
  font-family: Calibri, Aptos, Arial, sans-serif;
  color: var(--ink);
  background: #f2f1ed;
}
* { box-sizing: border-box; }
body { margin: 0; background: #f2f1ed; }
/* Keep shared navigation styles independent of the calendar controls. */
.site-navigation { position: sticky; top: 0; z-index: 1020; }
.site-navigation > .sticky-top { position: static; }
.site-navigation nav.container-xxl {
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: 30px;
}
/* This standalone tool has no documentation sidebar to open. */
.site-navigation .bd-navbar-toggle { display: none !important; }
.team-calendar { font-family: Calibri, Aptos, Arial, sans-serif; font-size: 16px; line-height: normal; color: var(--ink); }
/* Restore the calendar's original defaults after Bootstrap's screen reset. */
:where(.team-calendar) p { margin: 1em 0; }
:where(.team-calendar) h1, :where(.team-calendar) h2 { font-weight: 700; line-height: normal; }
:where(.team-calendar) h2 { margin: .83em 0; }
.team-calendar .view-switch legend { float: none; width: auto; line-height: normal; }
.team-calendar .calendar th { text-align: center; }

main.team-calendar { max-width: 1240px; margin: 0 auto; padding: 28px 30px 45px; }
:where(.team-calendar) a { color: inherit; }
.intro .eyebrow { margin-top: 0; }
.eyebrow { font-size: 11px; letter-spacing: .15em; font-weight: 700; color: var(--accent); margin: 0 0 7px; }
:where(.team-calendar) h1 { font-size: clamp(28px, 4vw, 43px); letter-spacing: -.035em; margin: 0 0 8px; }
.intro > p:last-child { color: var(--muted); margin: 0 0 22px; font-size: 16px; }
.controls { border: 1px solid #dddcd6; padding: 18px 20px 10px; border-radius: 12px; background: white; margin-bottom: 23px; }
.control-row, .action-row { display: flex; align-items: end; flex-wrap: wrap; gap: 12px; }
.control-row label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 700; }
.location-field { flex: 1; min-width: 190px; }
:where(.team-calendar) select, :where(.team-calendar) input, :where(.team-calendar) button { font: inherit; }
:where(.team-calendar) select, :where(.team-calendar) input { height: 39px; border: 1px solid var(--border); border-radius: 6px; background: white; color: var(--ink); padding: 7px 10px; min-width: 0; font-size: 14px; }
:where(.team-calendar) button { cursor: pointer; border: 1px solid var(--border); border-radius: 6px; padding: 9px 14px; font-size: 14px; font-weight: 700; min-height: 39px; }
:where(.team-calendar) button:disabled { cursor: wait; opacity: .6; }
:where(.team-calendar) button:focus-visible, :where(.team-calendar) select:focus-visible, :where(.team-calendar) input:focus-visible, :where(.team-calendar) textarea:focus-visible, :where(.team-calendar) summary:focus-visible { outline: 3px solid #c25e3e77; outline-offset: 2px; }
.secondary { background: white; color: var(--ink); }
.primary { background: var(--ink); color: white; border-color: var(--ink); }
.refresh { background: #fbefe9; color: #a1462c; border-color: #ebc6b8; margin-left: auto; }
.view-switch { margin: 0; border: 0; padding: 0; display: flex; gap: 3px; }
.view-switch legend { font-size: 12px; font-weight: 700; margin-bottom: 5px; }
.view-switch button { background: #f1f5f9; }
.view-switch button[aria-pressed="true"] { background: var(--ink); color: white; border-color: var(--ink); }
:where(.team-calendar) details { margin-top: 14px; }
:where(.team-calendar) summary { font-size: 12px; color: var(--muted); cursor: pointer; }
.custom-fields { margin-top: 12px; }
.custom-fields input { width: 155px; }
.custom-fields select { max-width: 215px; }
.helper { font-size: 12px; color: var(--muted); }
.action-row { margin-top: 17px; border-top: 1px solid #e7e9ed; padding-top: 15px; }
.navigation { display: flex; gap: 5px; }
#status { font-size: 12px; color: var(--muted); min-height: 16px; margin: 12px 0 0; }
#status.error { color: #a73a25; }
.coverage { font-size: 12px; color: var(--ink); margin: 6px 0 2px; }
.coverage:empty { display: none; }
.paper-scroll { overflow-x: auto; padding: 2px 2px 14px; }
.paper { background: white; padding: 30px 32px 25px; min-width: 860px; box-shadow: 0 4px 25px #1e293b0d; border: 1px solid #e4e4df; }
.paper-header { display: flex; align-items: start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.paper-header h2 { margin: 0 0 5px; font-size: 29px; line-height: 1.1; letter-spacing: -.025em; }
.year { color: var(--accent); background: #fbefe9; padding: 2px 7px; font-size: .72em; margin-left: 6px; vertical-align: middle; }
#place-caption { color: var(--muted); font-size: 12px; margin: 8px 0 0; }
.quarter { font-size: 11px; color: var(--muted); margin-top: 23px; white-space: nowrap; }
.planning-bar { display: grid; grid-template-columns: repeat(3, 1fr); background: #f8fafc; border: 1px solid var(--border); margin-bottom: 12px; }
.planning-bar label { padding: 9px 10px 5px; display: block; }
.planning-bar label + label { border-left: 1px solid var(--border); }
.planning-bar span { font-size: 11px; font-weight: 700; display: block; margin-bottom: 4px; }
.planning-bar b { color: var(--accent); font-size: 14px; margin-right: 5px; }
:where(.team-calendar) textarea { font: inherit; color: var(--ink); background: transparent; border: 0; border-radius: 0; padding: 0; resize: none; width: 100%; display: block; }
:where(.team-calendar) textarea::placeholder { color: #94a3b8; }
.planning-bar textarea { font-size: 12px; height: 33px; line-height: 16px; }
.calendar { width: 100%; table-layout: fixed; border-collapse: collapse; }
.calendar th { background: var(--ink); color: white; font-size: 11px; height: 30px; font-weight: 700; border: 1px solid var(--border); }
.calendar th:nth-child(n+6) { background: #334155; }
.calendar td { border: 1px solid var(--border); padding: 7px; vertical-align: top; height: 114px; overflow-wrap: anywhere; }
.calendar td.weekend { background: #f8fafc; }
.calendar td.overflow { background: #f1f5f9; }
.date-number { text-align: right; font-size: 15px; font-weight: 700; line-height: 19px; }
.overflow .date-number { font-weight: 400; color: #94a3b8; }
.is-today .date-number span { background: #fbefe9; color: #b35132; border-radius: 3px; padding: 0 5px; }
.weather-line { display: flex; align-items: center; gap: 5px; min-height: 25px; margin: 3px 0 0; }
.weather-line svg { width: 25px; height: 25px; flex: none; }
.temperature { font-weight: 700; font-size: 13px; }
.forecast-time { font-size: 9px; color: var(--muted); margin: 0 0 5px 30px; min-height: 12px; }
.day-notes { font-size: 12px; line-height: 16px; height: 46px; }
.week-view .calendar td { height: 340px; }
.week-view .day-notes { height: 240px; line-height: 20px; background-image: repeating-linear-gradient(transparent, transparent 19px, #e8edf2 19px, #e8edf2 20px); }
.six-weeks .calendar td { height: 98px; }
.six-weeks .day-notes { height: 29px; }
.paper-footer { margin-top: 11px; font-size: 10px; line-height: 1.4; color: var(--muted); }
.paper-footer p { margin: 2px 0; }
.footnote { margin: 7px 3px 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.print-notes, .print-planning { display: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
/* Embedded view shares the article's heading and uses the available width. */
@media screen {
  .embedded-calendar, .embedded-calendar body { background: white; }
  .embedded-calendar main { max-width: none; padding: 2px 0 12px; }
  .embedded-calendar .intro { display: none; }
  .embedded-calendar .controls { border-color: var(--border); }
  .embedded-calendar .paper-scroll { margin: 0; }
  .embedded-calendar .paper-scroll:focus-visible { outline: 3px solid #c25e3e77; outline-offset: -3px; }
}
@media (max-width: 680px) {
  main.team-calendar { padding: 22px 13px; }
  .site-navigation nav.container-xxl { padding-inline: 13px; }
  .controls { padding: 15px; }
  .location-field { flex-basis: 100%; }
  .refresh { margin-left: 0; }
  .action-row { gap: 8px; }
  .paper-scroll { margin-right: -13px; }
}
@page { size: letter landscape; margin: .4in .5in; }
@media print {
  :root, body { background: white; }
  .no-print, .offcanvas-backdrop { display: none !important; }
  main.team-calendar { width: auto; max-width: none; padding: 0; margin: 0; }
  .paper-scroll { overflow: visible; padding: 0; margin: 0; }
  .paper { width: 10in; min-width: 0; max-width: 100%; border: 0; padding: 0; box-shadow: none; }
  * { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .paper-header { margin-bottom: 9pt; }
  .paper-header h2 { font-size: 22pt; }
  .paper-header .eyebrow { font-size: 7pt; margin-bottom: 3pt; }
  #place-caption { font-size: 8pt; margin-top: 4pt; }
  .quarter { font-size: 8pt; margin-top: 15pt; }
  .planning-bar { margin-bottom: 7pt; }
  .planning-bar label { padding: 4pt 5pt; }
  .planning-bar span { font-size: 8pt; margin-bottom: 3pt; }
  :where(.team-calendar) textarea { display: none; }
  .print-notes, .print-planning { display: block; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 8pt; line-height: 10pt; }
  .print-planning { height: 22pt; overflow: hidden; }
  .calendar th { height: 22pt; font-size: 9pt; }
  .calendar td { height: 74pt; padding: 3pt 4pt; }
  .six-weeks .calendar td { height: 62pt; }
  .week-view .calendar td { height: 330pt; }
  .date-number { font-size: 10.5pt; line-height: 11pt; }
  .overflow .date-number { font-size: 9.5pt; }
  .weather-line { min-height: 16pt; margin-top: 2pt; gap: 3pt; }
  .weather-line svg { height: 16pt; width: 16pt; }
  .temperature { font-size: 9pt; }
  .forecast-time { font-size: 6.5pt; line-height: 8pt; min-height: 8pt; margin: 0 0 2pt 19pt; }
  .print-notes { font-size: 7.5pt; line-height: 8.5pt; min-height: 17pt; }
  .week-view .print-notes { max-height: 270pt; }
  .paper-footer { font-size: 6.5pt; line-height: 1.2; margin-top: 6pt; }
  .paper-footer a { text-decoration: none; }
  :where(.team-calendar) tr { break-inside: avoid; page-break-inside: avoid; }
}
/* Global team controls and holiday markers. Flag artwork is hosted locally. */
.control-title { font-size: 19px; margin: 0 0 14px; }
.search-field { width: 170px; }
.region-field { flex: 1; min-width: 230px; }
.selected-countries { display: flex; flex-wrap: wrap; gap: 8px; margin: 15px 0 0; padding: 0; list-style: none; }
.selected-countries li { display: flex; align-items: center; gap: 7px; padding: 7px 8px 7px 11px; border: 1px solid #cbd5e1; border-radius: 7px; background: #f8fafc; font-size: 12px; }
.flag { width: 20px; height: 15px; object-fit: contain; vertical-align: middle; flex: none; }
.remove-location { border: 0; background: transparent; padding: 1px 5px; min-height: 28px; color: #64748b; font-size: 18px; }
.check-label { display: flex; gap: 8px; align-items: center; margin-right: auto; max-width: 490px; font-size: 13px; line-height: 1.4; }
.check-label input { height: 18px; width: 18px; flex: none; }
.date-field { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 700; }
.summary-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 0 0 20px; }
.summary-strip div { display: flex; gap: 10px; align-items: center; padding: 13px 16px; border: 1px solid #deded8; border-radius: 8px; background: #fff; }
.summary-strip strong { color: #a1462c; font-size: 25px; }
.summary-strip span { font-size: 12px; color: #64748b; }
.calendar td { height: 112px; }
.six-weeks .calendar td { height: 100px; }
.date-number { display: flex; align-items: center; justify-content: flex-end; }
.holiday-day { margin: 0; padding: 0; width: 100%; background: none; border: none; border-radius: 0; text-align: right; min-height: 22px; font: inherit; color: inherit; }
.holiday-day:hover { color: #a1462c; }
.holiday-day .day-cue { float: left; font-size: 9px; font-weight: 400; color: #9e492e; }
.holiday-flags { display: grid; grid-template-columns: repeat(3, max-content); align-content: start; gap: 4px 3px; margin: 5px 0; min-height: 49px; }
.holiday-badge { display: inline-flex; align-items: center; gap: 2px; white-space: nowrap; font-size: 8.5px; font-weight: 700; }
.holiday-badge .flag { width: 14px; height: 10.5px; }
.calendar .day-notes { height: 25px; font-size: 11px; line-height: 13px; }
.week-view .calendar .day-notes { height: 230px; line-height: 20px; }
.calendar td.has-holiday { box-shadow: inset 0 3px #c25e3e; }
.calendar td.overlap-day { background: #fff8f3; }
.paper-footer #country-legend { line-height: 1.5; }
.legend-item { display: inline-block; margin-right: 12px; }
.holiday-detail { margin-top: 24px; padding: 23px 25px; border: 1px solid #dddcd6; border-radius: 10px; background: #fff; }
.detail-heading { display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.detail-heading h2 { margin: 0; font-size: 23px; }
.list-context { color: #64748b; font-size: 13px; }
.holiday-table-scroll { overflow-x: auto; }
.holiday-list { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 600px; }
.holiday-list th { text-align: left; background: #f1f5f9; color: #475569; font-size: 11px; padding: 9px 10px; }
.holiday-list td { border-bottom: 1px solid #e2e8f0; padding: 10px; vertical-align: top; }
.holiday-list td:first-child { white-space: nowrap; }
.holiday-list td:nth-child(2) { min-width: 115px; }
.holiday-list td:nth-child(4) { max-width: 320px; color: #64748b; }
.holiday-list .tag { display: inline-block; font-size: 10px; padding: 2px 5px; background: #fbefe9; color: #9e492e; border-radius: 3px; margin-left: 5px; }
.holiday-options { border-top: 1px solid #e2e8f0; padding-top: 12px; margin-top: 12px; }
.holiday-options .check-label { max-width: none; }
.holiday-options .helper { line-height: 1.5; margin-bottom: 0; }
#observance-coverage:empty { display: none; }
.public-badge { background: #fbefe9; border-radius: 2px; }
.observance-badge { border: 1px solid #64748b; border-radius: 2px; color: #0369a1; }
.event-type, .work-impact { display: block; }
.event-type { font-size: 11px; }
.work-impact { margin-top: 3px; color: #64748b; font-size: 11px; }
.observance-row .event-type { color: #0369a1; }
.holiday-list { min-width: 740px; }
.holiday-list td:nth-child(4) { min-width: 140px; }
.holiday-list td:nth-child(5) { color: #64748b; }
/* Annual overview uses compact months; daily notes remain in Week / Month. */
.team-calendar [hidden] { display: none !important; }
.year-field select { min-width: 95px; }
.year-calendar { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.paper.year-view { min-width: 0; }
.mini-month { border: 1px solid var(--border); border-radius: 7px; overflow: hidden; }
.mini-month h3 { margin: 0; background: #f8fafc; }
.mini-month h3 button { width: 100%; text-align: left; border: 0; border-radius: 0; background: transparent; color: var(--ink); padding: 10px 12px; font-size: 15px; }
.mini-month h3 button:hover { background: #fbefe9; color: #a1462c; }
.mini-month table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.mini-month th { padding: 6px 0; font-size: 10px; text-align: center; color: var(--muted); }
.mini-month abbr { text-decoration: none; }
.mini-month td { height: 35px; padding: 2px; text-align: center; border-top: 1px solid #f1f5f9; }
.mini-weekend { background: #f8fafc; }
.mini-day { display: flex; align-items: center; justify-content: center; gap: 2px; width: 100%; min-height: 29px; padding: 2px 0; border: 1px solid transparent; border-radius: 4px; font-size: 12px; font-weight: 400; background: transparent; color: var(--ink); }
.mini-day small { font-size: 8px; }
.mini-holiday .mini-day { background: #fbefe9; color: #8e3e26; border-color: #f1d5c9; font-weight: 700; }
.mini-clash .mini-day { background: #a1462c; color: #fff; border-color: #a1462c; }
.mini-observance .mini-day { border-color: #0369a1; color: #0369a1; }
.mini-day:is(button):hover { outline: 2px solid #c25e3e; outline-offset: 1px; }
.year-legend { margin: 15px 0 0; font-size: 11px; line-height: 1.5; color: var(--muted); }
.year-view .paper-footer > p:nth-child(2) { display: none; }
@media screen and (max-width: 950px) {
  .year-calendar { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}
@media screen and (max-width: 560px) {
  .year-calendar { grid-template-columns: minmax(0, 1fr); }
  .paper.year-view { padding: 20px 15px; }
  .year-view .paper-header { display: block; }
  .year-view .quarter { margin: 8px 0; }
  .year-view .planning-bar { grid-template-columns: 1fr; }
  .year-view .planning-bar label + label { border-left: 0; border-top: 1px solid var(--border); }
}
@media (max-width: 680px) {
  .summary-strip div { display: block; padding: 12px; }
  .summary-strip span { display: block; margin-top: 4px; }
  .search-field, .region-field { width: 100%; flex-basis: 100%; }
  .holiday-detail { padding: 18px 14px; }
}
@media print {
  .paper { break-after: page; page-break-after: always; }
  body.without-list .paper { break-after: auto; page-break-after: auto; }
  body.without-list .holiday-detail { display: none; }
  .paper-header { margin-bottom: 6pt; }
  .paper-header h2 { font-size: 21pt; }
  .planning-bar { margin-bottom: 6pt; }
  .calendar td { height: 69pt; padding: 3pt 4pt; }
  .six-weeks .calendar td { height: 57pt; }
  .week-view .calendar td { height: 340pt; }
  .holiday-day { min-height: 11pt; font-size: 10.5pt; text-align: right; display: block; padding: 0; border: 0; }
  .holiday-day .day-cue { display: none; }
  .holiday-flags { gap: 2pt 3pt; min-height: 27pt; margin: 2pt 0; }
  .holiday-badge { font-size: 6.5pt; gap: 2pt; }
  .holiday-badge .flag { width: 10pt; height: 7.5pt; }
  .calendar .print-notes { min-height: 8pt; font-size: 7pt; line-height: 8pt; }
  .paper-footer { margin-top: 5pt; font-size: 6.5pt; }
  .paper-footer #country-legend { line-height: 1.3; }
  .holiday-detail { margin: 0; padding: 0; border: 0; border-radius: 0; }
  .detail-heading h2 { font-size: 19pt; }
  .detail-heading .eyebrow { font-size: 8pt; }
  .list-context { font-size: 9pt; }
  .holiday-table-scroll { overflow: visible; }
  .holiday-list { min-width: 0; width: 100%; font-size: 9pt; }
  .holiday-list th { font-size: 8pt; }
  .holiday-list td, .holiday-list th { padding: 5pt; }
  .holiday-list .tag { font-size: 7pt; }
  .holiday-list td:nth-child(2) { min-width: 0; }
  .holiday-list .flag { width: 14pt; height: 10.5pt; }
  .holiday-list thead { display: table-header-group; }
  .holiday-list tr { break-inside: avoid; }
  .year-calendar { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7pt; }
  .mini-month { border-radius: 0; break-inside: avoid; }
  .mini-month h3 button { min-height: 0; padding: 3pt 5pt; font-size: 10pt; }
  .mini-month th { font-size: 7pt; padding: 2pt 0; }
  .mini-month td { height: 15pt; padding: 1pt; }
  .mini-day { min-height: 12pt; padding: 0; font-size: 8pt; gap: 1pt; }
  .mini-day small { font-size: 5.5pt; }
  .year-legend { margin: 5pt 0 0; font-size: 6.5pt; line-height: 1.2; }
}
