/* /exam-dates: web/templates/exam_dates/. Not bundled; only these pages load it.
   Design pass 11-24 (owner: no small grey text on dark blue, icons in colour): each level
   has its own accent (--xd), subjects are tiles with a calendar badge in that accent,
   and notes, sources and paper lists read at 14 px in slate-300. */
.xd { max-width: 60rem; margin: 0 auto; padding: 0 1rem 3rem; }
.xd-back, .xd-mine { margin: 0.25rem 0 1rem; font-size: 0.95rem; }
.xd-back a, .xd-mine a { color: rgb(125 211 252); font-weight: 500; }
.xd-mine span { color: rgb(203 213 225); }
.xd-level { --xd: 167 139 250; margin-top: 2rem; }
.xd-level:nth-of-type(5n+1) { --xd: 56 189 248; }
.xd-level:nth-of-type(5n+2) { --xd: 167 139 250; }
.xd-level:nth-of-type(5n+3) { --xd: 251 146 60; }
.xd-level:nth-of-type(5n+4) { --xd: 52 211 153; }
.xd-level:nth-of-type(5n+5) { --xd: 244 114 182; }
.xd-level h2 { display: flex; align-items: center; gap: 0.6rem; margin: 0 0 0.75rem; font-size: 1.15rem; font-weight: 700; color: rgb(241 245 249); }
.xd-level h2::before { content: ""; width: 0.3rem; height: 1.15em; border-radius: 99rem; background: linear-gradient(180deg, rgb(var(--xd)), rgb(var(--xd) / 0.35)); }
.xd-subjects { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); gap: 0.55rem; margin: 0; padding: 0; list-style: none; }
.xd-subjects a { display: flex; align-items: center; gap: 0.7rem; min-height: 3rem; padding: 0.55rem 0.8rem; border: 1px solid rgb(var(--xd) / 0.22); border-radius: 0.8rem;
  background: linear-gradient(135deg, rgb(var(--xd) / 0.09), rgb(255 255 255 / 0.02)); color: rgb(226 232 240); font-size: 0.95rem; font-weight: 500; text-decoration: none;
  transition: border-color 0.15s ease, transform 0.15s ease; }
.xd-subjects a::before { content: ""; flex: none; width: 1.9rem; height: 1.9rem; border-radius: 0.55rem;
  background: linear-gradient(145deg, rgb(var(--xb, var(--xd))), color-mix(in srgb, rgb(var(--xb, var(--xd))) 55%, #0b1020)); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.3); }
/* Badge hue: by exam board where the subject names one (Cambridge, Pearson, AQA …), else a
   cycle, so no group of tiles is one flat colour. */
.xd-subjects li:nth-child(6n+1) { --xb: 56 189 248; }
.xd-subjects li:nth-child(6n+2) { --xb: 167 139 250; }
.xd-subjects li:nth-child(6n+3) { --xb: 251 146 60; }
.xd-subjects li:nth-child(6n+4) { --xb: 52 211 153; }
.xd-subjects li:nth-child(6n+5) { --xb: 244 114 182; }
.xd-subjects li:nth-child(6n+6) { --xb: 250 204 21; }
.xd-subjects li[data-board="cambridge"] { --xb: 56 189 248; }
.xd-subjects li[data-board="pearson"] { --xb: 167 139 250; }
.xd-subjects li[data-board="oxfordaqa"], .xd-subjects li[data-board="aqa"] { --xb: 251 146 60; }
.xd-subjects li[data-board="international"] { --xb: 52 211 153; }
.xd-subjects li { position: relative; }
.xd-subjects li::before { content: ""; position: absolute; left: calc(0.8rem + 0.4rem); top: 50%; width: 1.1rem; height: 1.1rem; margin-top: -0.55rem; background: #fff; pointer-events: none; z-index: 1;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18M8 14h.01M12 14h.01M16 14h.01M8 18h.01M12 18h.01'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18M8 14h.01M12 14h.01M16 14h.01M8 18h.01M12 18h.01'/%3E%3C/svg%3E") center / contain no-repeat; }
.xd-subjects a:hover { border-color: rgb(var(--xd) / 0.65); color: #fff; transform: translateY(-1px); }
.xd-region { display: grid; gap: 0.35rem; max-width: 24rem; margin: 0 0 1.25rem; }
.xd-region label { font-size: 0.9rem; font-weight: 600; color: rgb(226 232 240); }
.xd-region select { width: 100%; min-height: 2.75rem; padding: 0.5rem 0.6rem; border: 1px solid rgb(255 255 255 / 0.18); border-radius: 0.5rem; background: var(--space-deep, #0b1020); color: rgb(226 232 240); font-size: 0.95rem; }
.xd-region-note, .xd-variant-name { margin: 0 0 0.75rem; color: rgb(203 213 225); font-size: 0.875rem; }
.xd-region-note:empty { display: none; }
.xd-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: 1rem; }
.xd-card { position: relative; padding: 1.15rem 1.2rem 1.2rem; border: 1px solid rgb(167 139 250 / 0.22); border-radius: 1rem;
  background: linear-gradient(160deg, rgb(167 139 250 / 0.09), rgb(255 255 255 / 0.02) 55%); box-shadow: inset 3px 0 rgb(167 139 250 / 0.8); }
.xd-cards > .xd-card:nth-child(2) { border-color: rgb(56 189 248 / 0.22); background: linear-gradient(160deg, rgb(56 189 248 / 0.09), rgb(255 255 255 / 0.02) 55%); box-shadow: inset 3px 0 rgb(56 189 248 / 0.8); }
.xd-card[hidden], .xd-variant[hidden], .xd-mine[hidden], .xd-papers li[hidden] { display: none; }
.xd-card--solo { max-width: 36rem; color: rgb(203 213 225); }
.xd-icon { flex: none; display: grid; place-items: center; width: 2.1rem; height: 2.1rem; border-radius: .65rem;
  color: rgb(var(--accent-rgb)); background: rgba(var(--accent-rgb), .14); border: 1px solid rgba(var(--accent-rgb), .32); }
.xd-icon svg { width: 1.15rem; height: 1.15rem; }
.xd-card-head .xd-icon + h2 { margin-right: auto; }
html[data-theme="light"] .xd-icon { color: color-mix(in srgb, rgb(var(--accent-rgb)) 60%, #0f172a); background: rgba(var(--accent-rgb), .16); }
.xd-card-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.xd-card h2 { margin: 0; font-size: 1.1rem; font-weight: 700; color: rgb(241 245 249); }
.xd-status { padding: 0.15rem 0.6rem; border-radius: 99rem; font-size: 0.78rem; font-weight: 700; }
.xd-status--final { background: rgb(56 189 248 / 0.15); color: rgb(125 211 252); }
.xd-status--provisional { background: rgb(251 191 36 / 0.15); color: rgb(252 211 77); }
.xd-status--expected { background: rgb(148 163 184 / 0.15); color: rgb(226 232 240); }
.xd-date { margin: 0.75rem 0 0.2rem; font-size: 1.3rem; font-weight: 700; line-height: 1.35; color: #fff; }
.xd-date--soft { font-size: 1.05rem; font-weight: 500; }
.xd-to { color: rgb(203 213 225); font-weight: 400; }
.xd-count { min-height: 1.1rem; margin: 0; color: rgb(196 181 253); font-size: 0.95rem; font-weight: 600; }
.xd-papers { margin-top: 0.85rem; font-size: 0.875rem; color: rgb(226 232 240); }
.xd-papers summary { cursor: pointer; color: rgb(203 213 225); font-weight: 600; }
.xd-papers ul { margin: 0.5rem 0 0; padding: 0; list-style: none; }
.xd-papers li { display: grid; grid-template-columns: 7.4rem 1fr auto; gap: 0.5rem; padding: 0.4rem 0; border-top: 1px solid rgb(255 255 255 / 0.08); }
.xd-papers li time { font-weight: 600; color: rgb(241 245 249); }
.xd-papers code { color: rgb(203 213 225); font-size: 0.8rem; }
.xd-paper-session { color: rgb(203 213 225); }
.xd-note { margin: 0.7rem 0 0; color: rgb(203 213 225); font-size: 0.875rem; line-height: 1.5; }
.xd-source { margin: 0.7rem 0 0; font-size: 0.875rem; }
.xd-source a { color: rgb(125 211 252); font-weight: 500; }
.xd-foot { margin-top: 2rem; padding: 0.8rem 1rem; border: 1px solid rgb(255 255 255 / 0.08); border-left: 3px solid rgb(251 191 36 / 0.8); border-radius: 0.75rem; background: rgb(251 191 36 / 0.05); color: rgb(203 213 225); font-size: 0.875rem; line-height: 1.55; }
@media (max-width: 30rem) {
  .xd-papers li { grid-template-columns: 1fr auto; }
  .xd-paper-title { grid-column: 1 / -1; grid-row: 2; }
}
html[data-theme="light"] .xd .xd-subjects li::before { background: #fff; }
html[data-theme="light"] .xd .xd-foot { border-left-color: rgb(217 119 6); }
html[data-theme="light"] .xd .xd-card { box-shadow: inset 3px 0 rgb(139 92 246); }
html[data-theme="light"] .xd .xd-cards > .xd-card:nth-child(2) { box-shadow: inset 3px 0 rgb(14 165 233); }
html[data-theme="light"] .xd .xd-subjects a::before { background: linear-gradient(145deg, rgb(var(--xb, var(--xd))), color-mix(in srgb, rgb(var(--xb, var(--xd))) 60%, #0f172a)); }
html[data-theme="light"] .xd .xd-region select { background: #fff; color: rgb(15 23 42); }

/* ▼▼ LIGHT THEME — GENERATED by scripts/build_light_theme.py from the rules above. Do not edit by hand: run the builder. Hand tuning goes in 36-theme-light.css. ▼▼ */
html[data-theme="light"] .xd-back a,html[data-theme="light"] .xd-mine a{color:rgb(0 90 133)}
html[data-theme="light"] .xd-mine span{color:rgb(48 65 85)}
html[data-theme="light"] .xd-level h2{color:rgb(38 66 94)}
html[data-theme="light"] .xd-subjects a{background-image:linear-gradient(135deg, rgb(var(--xd) / 0.09), rgb(15 23 42/0.02));color:rgb(44 63 88)}
html[data-theme="light"] .xd-subjects a::before{background-image:linear-gradient(145deg, rgb(var(--xb, var(--xd))), color-mix(in srgb, rgb(var(--xb, var(--xd))) 55%, rgb(247 247 251)));box-shadow:none}
html[data-theme="light"] .xd-subjects a:hover{color:rgb(51 63 82)}
html[data-theme="light"] .xd-region label{color:rgb(44 63 88)}
html[data-theme="light"] .xd-region select{border-color:rgb(15 23 42/0.18);background:var(--space-deep, rgb(247 247 251));color:rgb(44 63 88)}
html[data-theme="light"] .xd-region-note,html[data-theme="light"] .xd-variant-name{color:rgb(48 65 85)}
html[data-theme="light"] .xd-card{background-image:linear-gradient(160deg, rgb(167 139 250 / 0.09), rgb(15 23 42/0.02) 55%);box-shadow:inset 3px 0px rgb(15 23 42/0.2)}
html[data-theme="light"] .xd-cards > .xd-card:nth-child(2){background-image:linear-gradient(160deg, rgb(56 189 248 / 0.09), rgb(15 23 42/0.02) 55%);box-shadow:inset 3px 0px rgb(15 23 42/0.2)}
html[data-theme="light"] .xd-card--solo{color:rgb(48 65 85)}
html[data-theme="light"] .xd-icon{color:color-mix(in srgb,rgb(var(--accent-rgb)) 44%,#0f172a)}
html[data-theme="light"] .xd-card h2{color:rgb(38 66 94)}
html[data-theme="light"] .xd-status--final{color:rgb(0 90 133)}
html[data-theme="light"] .xd-status--provisional{color:rgb(126 96 0)}
html[data-theme="light"] .xd-status--expected{color:rgb(44 63 88)}
html[data-theme="light"] .xd-date{color:rgb(51 63 82)}
html[data-theme="light"] .xd-to{color:rgb(48 65 85)}
html[data-theme="light"] .xd-count{color:rgb(28 0 132)}
html[data-theme="light"] .xd-papers{color:rgb(44 63 88)}
html[data-theme="light"] .xd-papers summary{color:rgb(48 65 85)}
html[data-theme="light"] .xd-papers li{border-top-color:rgb(15 23 42/0.112)}
html[data-theme="light"] .xd-papers li time{color:rgb(38 66 94)}
html[data-theme="light"] .xd-papers code{color:rgb(48 65 85)}
html[data-theme="light"] .xd-paper-session{color:rgb(48 65 85)}
html[data-theme="light"] .xd-note{color:rgb(48 65 85)}
html[data-theme="light"] .xd-source a{color:rgb(0 90 133)}
html[data-theme="light"] .xd-foot{border-color:rgb(15 23 42/0.112);color:rgb(48 65 85)}
/* ▲▲ LIGHT THEME END ▲▲ */
