/* blessbible.app — /calendar/** and /today/ (gen/calendar.py). Built on site.css tokens.
   Liturgical colours: --s-* for text, --sw-* for fills. Edges fade; nothing animates but
   transform/opacity; a month prints on one or two pages. */

/* ---------- shared: colour of a day ---------- */
.cal-r--green, .mg__d--green, .td-panel--green, .td-orb--green, .td-dot--green, .cal-day--green { --sc: var(--s-green); --sf: var(--sw-green); }
.cal-r--violet, .mg__d--violet, .td-panel--violet, .td-orb--violet, .td-dot--violet, .cal-day--violet { --sc: var(--s-violet); --sf: var(--sw-violet); }
.cal-r--white, .mg__d--white, .td-panel--white, .td-orb--white, .td-dot--white, .cal-day--white { --sc: var(--s-white); --sf: var(--sw-white); }
.cal-r--red, .mg__d--red, .td-panel--red, .td-orb--red, .td-dot--red, .cal-day--red { --sc: var(--s-red); --sf: var(--sw-red); }
.cal-r--rose, .mg__d--rose, .td-panel--rose, .td-orb--rose, .td-dot--rose, .cal-day--rose { --sc: var(--s-rose); --sf: var(--sw-rose); }
.cal-r--white, .mg__d--white, .td-panel--white, .cal-day--white { --st: var(--gold-fill); }
/* kicker dots in the liturgical colours (core.kicker gives green / gold itself) */
.dot--violet { background: var(--sw-violet); box-shadow: 0 0 10px rgb(107 78 142 / .6); }
.dot--red { background: var(--sw-red); box-shadow: 0 0 10px rgb(180 64 78 / .5); }
.dot--rose { background: var(--sw-rose); box-shadow: 0 0 10px rgb(201 138 158 / .55); }
.cal-after { margin-top: 18px; }
.cal-hub-today { margin-bottom: clamp(56px, 8vw, 96px); }
.cal-hub-today .day { max-width: 980px; }

/* ---------- year strips: one bar per day ---------- */
.ys { display: grid; gap: 6px; }
.ys__row { display: grid; grid-template-columns: 38px minmax(0, 1fr); align-items: end; gap: 10px; min-height: 44px; padding: 6px 8px 6px 4px; border-radius: 12px; text-decoration: none; color: var(--fg-2); transition: background-color .25s; }
.ys__row:hover { background: var(--card-2); }
.ys__row:hover .ys__m { color: var(--gold); }
.ys__m { font: 650 13px/1 var(--sans); letter-spacing: .04em; color: var(--dim); padding-bottom: 2px; white-space: nowrap; }
.ys__cells { display: grid; grid-template-columns: repeat(31, minmax(0, 1fr)); gap: 2px; align-items: end; height: 26px; }
.ys i, .ys-key i { display: block; border-radius: 2px; background: var(--c); }
.ys .x { visibility: hidden; }
.g { --c: var(--sw-green); } .v { --c: var(--sw-violet); } .r { --c: var(--sw-red); } .p { --c: var(--sw-rose); }
.w { --c: var(--sw-white); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold-fill) 60%, transparent); }
:root[data-theme="light"] .w { --c: #FFFEFA; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .w { --c: #FFFEFA; } }
.h0 { height: 38%; } .h1 { height: 56%; } .h2 { height: 80%; } .h3 { height: 100%; }
.ys i.is-today { outline: 2px solid var(--gold-fill); outline-offset: 1px; }
.ys--lg .ys__cells { height: 34px; gap: 3px; }
@media (min-width: 900px) { .ys__cells { height: 30px; gap: 3px; } .ys--lg .ys__cells { height: 40px; } .ys__row { grid-template-columns: 52px minmax(0, 1fr); } }
.ys-key { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px; margin-bottom: 18px; font-size: 13.5px; color: var(--dim); }
.ys-key ul { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.ys-key li { display: inline-flex; align-items: center; gap: 7px; }
.ys-key li i { width: 9px; height: 16px; }
.ys-key p { display: inline-flex; align-items: flex-end; gap: 3px; height: 18px; }
.ys-key p i { width: 7px; }
.ys-key p span { margin-left: 8px; align-self: center; }
.cal-yrs { display: grid; gap: clamp(28px, 4vw, 40px); }
.cal-yr__h { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 0 8px 6px 4px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.cal-yr__h .h4 { font: 600 1.6rem/1 var(--serif); }
.cal-yr__h .h4 a { text-decoration: none; }
.cal-months { display: grid; gap: 18px 32px; margin-top: clamp(32px, 4vw, 44px); padding-top: 24px; border-top: 1px solid var(--line); }
@media (min-width: 760px) { .cal-months { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.cal-mi__y { font: 700 12px/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.cal-mi__y a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.cal-mi ul { display: flex; flex-wrap: wrap; gap: 6px; }
.cal-mi li a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 13px; border-radius: 999px; font: 550 14.5px/1 var(--sans); color: var(--fg-2); text-decoration: none; background: var(--card-2); box-shadow: inset 0 0 0 1px var(--rim-dim); }
.cal-mi li a:hover { color: var(--fg); }

/* ---------- hub: key-date cards, colours ---------- */
.cal-kd__l { margin-top: 12px; }
.cal-kd__l li { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 44px; border-top: 1px solid var(--line); font-size: 15px; color: var(--fg-2); }
.cal-kd__l a { position: relative; z-index: 1; font-weight: 650; color: var(--gold); text-decoration: none; white-space: nowrap; }
.cal-kd__l a:hover { text-decoration: underline; }
.cal-kd .card__t a::after { display: none; }
.cal-cols { display: grid; gap: 10px; }
@media (min-width: 900px) { .cal-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 20px; } }
.cal-col { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 14px; padding: 18px 20px; border-radius: 18px; background: var(--card); box-shadow: inset 0 0 0 1px var(--rim-dim); }
.cal-col__sw i { width: 26px; height: 26px; }
.cal-col__n { font: 600 1.3rem/1.2 var(--serif); color: var(--fg); }
.cal-col__n span { margin-left: 8px; font: 600 13.5px/1 var(--sans); color: var(--dim); }
.cal-col__b { margin-top: 4px; font-size: 15px; line-height: 1.55; color: var(--fg-2); }

/* ---------- year page ---------- */
.cal-cyc { display: inline-flex; align-items: center; gap: 10px; margin: -12px 0 clamp(36px, 5vw, 56px); padding: 10px 16px; border-radius: 999px; font-size: 15px; color: var(--fg-2); background: var(--card); box-shadow: inset 0 0 0 1px var(--rim-dim); }
.cal-cyc .i { color: var(--gold); }
.cal-kt td:nth-child(2) { white-space: nowrap; font-variant-numeric: tabular-nums; color: var(--fg); font-weight: 600; }
.cal-kt th a { text-decoration: none; color: var(--fg); }
.cal-kt th a:hover { color: var(--gold); }
.cal-kt__d { display: block; margin-top: 2px; font-size: 13.5px; font-weight: 450; color: var(--dim); }
.cal-cy__a { display: inline-block; white-space: nowrap; }
.cal-cyt td:nth-child(2) { color: var(--fg); }
.cal-cy__g { display: block; margin-top: 2px; font-size: 13.5px; color: var(--dim); }
.cal-cyt b { color: var(--fg); font-weight: 650; }
.cal-cyt .pill { display: table; margin-top: 6px; }
.cal-cyt thead th { white-space: normal; }
@media (max-width: 559.98px) {
  .cal-kt th, .cal-kt td, .cal-cyt th, .cal-cyt td { padding: 12px 9px; font-size: 15px; }
  .cal-kt th:first-child, .cal-kt td:first-child, .cal-cyt th:first-child, .cal-cyt td:first-child { padding-left: 16px; }
  .cal-kt tr > :last-child, .cal-cyt tr > :last-child { padding-right: 14px; }
  .cal-kt .swatch { gap: 6px; }
}
.cal-kt__n { display: block; margin-top: 3px; font-size: 13.5px; font-weight: 450; color: var(--dim); }
.cal-mcs { margin-top: clamp(28px, 4vw, 40px); }
.cal-mc .card__k { min-height: 1.3em; }

/* ---------- month: nav, grid, summary ---------- */
.cal-month .page-head { margin-bottom: clamp(24px, 3.4vw, 36px); }
.cal-month .page-title { max-width: calc(16 * var(--ch-serif)); }
.cal-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: clamp(24px, 3vw, 36px); }
.cal-nav a { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border-radius: 999px; text-decoration: none; white-space: nowrap; font: 600 14.5px/1 var(--sans); color: var(--fg-2); background: var(--card-2); box-shadow: inset 0 0 0 1px var(--rim-dim); }
@media (max-width: 379.98px) { .cal-nav { gap: 8px; } .cal-nav a { padding: 0 12px; } .cal-nav__yr { display: none; } }
.cal-nav a:hover { color: var(--fg); }
.cal-nav .i { color: var(--gold); }
.cal-nav__y { background: none !important; box-shadow: none !important; color: var(--gold) !important; }
.cal-top { display: grid; gap: 22px; }
@media (min-width: 1024px) { .cal-top { grid-template-columns: minmax(0, 1fr) 260px; gap: 40px; align-items: start; } }
.mg__h, .mg__g { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.mg__h { margin-bottom: 6px; }
.mg__h li { text-align: center; font: 700 11px/1.3 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.mg__h li:first-child { color: var(--gold); }
.mg__d { position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; gap: 4px; min-height: 52px; height: 100%; padding: 7px 7px 12px; border-radius: 12px; text-decoration: none; color: var(--fg-2);
  background: var(--card); box-shadow: inset 0 0 0 1px var(--rim-dim); transition: transform .25s var(--ease), background-color .25s; }
.mg__d::after { content: ""; position: absolute; left: 7px; right: 7px; bottom: 5px; height: 3px; border-radius: 3px; background: linear-gradient(90deg, transparent, var(--sf) 22%, var(--sf) 78%, transparent); opacity: .9; }
.mg__d--white::after { background: linear-gradient(90deg, transparent, var(--gold-fill) 22%, var(--gold-fill) 78%, transparent); opacity: .7; }
.mg__d--t2, .mg__d--t3 { background: radial-gradient(130% 110% at 0% 0%, color-mix(in srgb, var(--st, var(--sf)) 22%, transparent), transparent 70%), var(--card-2); }
.mg__d--t3 { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--sc) 45%, transparent); }
.mg__d:hover { transform: translateY(-2px); background-color: var(--card-2); }
.mg__n { font: 600 1.05rem/1 var(--serif); color: var(--fg); font-variant-numeric: lining-nums; }
.mg__d--t2 .mg__n, .mg__d--t3 .mg__n { color: var(--sc); }
.mg__t { display: none; font: 550 11.5px/1.25 var(--sans); color: var(--dim); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
@media (max-width: 759.98px) { .mg__t { display: none; } }
@media (min-width: 760px) { .mg__d { min-height: 84px; padding: 9px 10px 14px; } .mg__n { font-size: 1.3rem; } .mg__h, .mg__g { gap: 6px; } }
.mg__d.is-today { box-shadow: inset 0 0 0 2px var(--gold-fill), 0 0 22px -6px rgb(201 164 76 / .6); }
.mg__d.is-today .mg__n::after { content: "Today"; margin-left: 6px; font: 700 9.5px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); vertical-align: 2px; }
.cal-sum { padding: 18px 20px; border-radius: var(--radius); background: var(--card); box-shadow: inset 0 0 0 1px var(--rim-dim); }
.cal-sum__k { font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.cal-sum__k + ul { margin: 8px 0 18px; }
.cal-sum ul:last-child { margin-bottom: 0; }
.cal-sum__r { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.cal-sum__r li { display: flex; flex-direction: column; font-size: 13.5px; color: var(--dim); }
.cal-sum__r b { font: 600 1.9rem/1 var(--serif); color: var(--gold); }
.cal-sum__c { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 14.5px; color: var(--fg-2); }
.cal-sum__c li { display: inline-flex; align-items: center; gap: 6px; }
.cal-sum__c b { color: var(--fg); font-weight: 650; }
@media (min-width: 1024px) { .cal-sum { position: sticky; top: calc(var(--head-h) + 24px); } .cal-sum__r { display: grid; grid-template-columns: 1fr 1fr; } }

/* ---------- month: day-by-day table ---------- */
.cal-days { margin-top: clamp(48px, 7vw, 80px) !important; }
.cal-days__h { margin-bottom: 18px; }
.cal-tw { border-radius: var(--radius); background: var(--card); box-shadow: inset 0 0 0 1px var(--rim-dim); overflow: clip; overflow-clip-margin: 0; }
.cal-t { font-size: 15px; }
@media (min-width: 1200px) {
  .cal-t { table-layout: fixed; }
  .cal-t thead th:nth-child(1) { width: 76px; } .cal-t thead th:nth-child(3) { width: 124px; }
  .cal-t thead th:nth-child(4) { width: 112px; } .cal-t thead th:nth-child(5) { width: 104px; }
  .cal-t thead th:nth-child(6) { width: 15%; } .cal-t thead th:nth-child(7) { width: 29%; }
  .cal-co .swatch { align-items: flex-start; }
  .cal-co .swatch i { margin-top: 4px; }
  .cal-co__or { display: block; margin-top: 1px; font-size: 12.5px; line-height: 1.3; }
}
.cal-t thead th { position: sticky; top: calc(var(--head-h) - 6px); z-index: 2; background: linear-gradient(180deg, var(--bg) 70%, color-mix(in srgb, var(--bg) 0%, transparent)); padding-top: 16px; }
.cal-t thead th:first-child { border-top-left-radius: var(--radius); }
.cal-t thead th:last-child { border-top-right-radius: var(--radius); }
.cal-r { scroll-margin-top: calc(var(--head-h) + 60px); }
.cal-r > * { padding: 14px 14px; }
.cal-r--t2, .cal-r--t3 { background: linear-gradient(90deg, color-mix(in srgb, var(--st, var(--sf)) 12%, transparent), transparent 62%); }
.cal-dt { position: relative; width: 64px; padding-left: 20px !important; }
.cal-dt::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: linear-gradient(180deg, transparent, var(--sf) 24%, var(--sf) 76%, transparent); }
.cal-r--white .cal-dt::before { background: linear-gradient(180deg, transparent, var(--gold-fill) 24%, var(--gold-fill) 76%, transparent); }
.cal-dt time { display: flex; flex-direction: column; align-items: flex-start; }
.cal-dt b { font: 600 1.55rem/1 var(--serif); color: var(--fg); font-variant-numeric: lining-nums; }
.cal-r--t2 .cal-dt b, .cal-r--t3 .cal-dt b { color: var(--sc); }
.cal-dt span { margin-top: 3px; font: 700 11px/1.2 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.cal-cel__n { display: block; font: 600 1.12rem/1.3 var(--serif); color: var(--fg); text-wrap: pretty; }
.cal-cel__a { color: inherit; text-decoration: underline 1px var(--line-2); text-underline-offset: .2em; }
.cal-cel__a:hover { color: var(--gold); text-decoration-color: currentColor; }
.cal-r--t0 .cal-cel__n { font-weight: 500; color: var(--fg-2); }
.cal-r--t3 .cal-cel__n { font-size: 1.24rem; }
.cal-cel__s { display: block; margin-top: 2px; font-size: 13.5px; color: var(--dim); }
.cal-rk, .cal-cy { white-space: nowrap; font-size: 14px; color: var(--dim) !important; }
.cal-r--t3 .cal-rk, .cal-r--t2 .cal-rk { color: var(--sc) !important; font-weight: 650; }
.cal-co { white-space: nowrap; font-size: 14px; }
.cal-co__or { color: var(--dim); }
.cal-nw { white-space: nowrap; }
.cal-sa { font-size: 14.5px; }
.cal-sa a { text-decoration: none; }
.cal-sa a:hover { text-decoration: underline; }
.cal-k { display: none; }
.cal-reads li { display: flex; gap: 8px; align-items: baseline; font-size: 14.5px; line-height: 1.4; padding: 1px 0; }
.cal-reads a { color: var(--fg); text-decoration-color: var(--line-2); }
.cal-reads a:hover { color: var(--gold); }
.cal-rl { flex: none; min-width: 52px; font: 700 10.5px/1.4 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.cal-na span:last-child { font-style: italic; color: var(--dim); }
.cal-also { margin-top: 6px; font-size: 13px; line-height: 1.4; color: var(--dim); }
/* the badge is ink on the constant gold fill in both themes (as .btn--gold); `.table a` must not recolour it */
.cal-fn, .cal-t a.cal-fn { position: relative; display: inline-grid; place-items: center; width: 20px; height: 20px; margin-left: 6px; border-radius: 50%; vertical-align: 2px; font: 700 11px/1 var(--sans); color: #15121C; background: var(--gold-fill); text-decoration: none; }
a.cal-fn::after { content: ""; position: absolute; inset: -12px -8px; }
.cal-notes { display: grid; gap: 8px; margin-top: 18px; font-size: 14.5px; color: var(--fg-2); }
.cal-notes li { display: flex; gap: 10px; align-items: baseline; scroll-margin-top: calc(var(--head-h) + 24px); }
.cal-notes .cal-fn { flex: none; margin: 0; }
.cal-prov { margin-top: 22px; }
.cal-r.is-today { background: linear-gradient(90deg, color-mix(in srgb, var(--gold-fill) 18%, transparent), transparent 70%); outline: 2px solid color-mix(in srgb, var(--gold-fill) 70%, transparent); outline-offset: -2px; }
.cal-r.is-today .cal-dt span::after { content: " · Today"; color: var(--gold); }
.cal-r:target { outline: 2px solid color-mix(in srgb, var(--gold-fill) 55%, transparent); outline-offset: -2px; }
.page-actions .btn { background: var(--card-2); box-shadow: inset 0 0 0 1px var(--rim-dim), inset 0 1px 0 var(--rim); font-size: 15px; }
.page-actions .btn .i { color: var(--gold); }

/* phones and small tablets: each day becomes a block (no sideways scroll) */
@media screen and (max-width: 1199.98px) {
  .cal-t, .cal-t tbody { display: block; }
  .cal-t thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .cal-r { display: grid; grid-template-columns: 50px auto auto minmax(0, 1fr); grid-template-areas: "d c c c" "d k r y" "d s s s" "d x x x"; column-gap: 0; row-gap: 6px; padding: 16px 16px 16px 0; }
  .cal-tw .cal-r + .cal-r { border-top: 1px solid var(--line); }
  .cal-t tbody tr + tr > * { border-top: 0; }
  .cal-r > * { display: block; padding: 0 !important; border: 0; }
  .cal-dt { grid-area: d; width: auto; padding-left: 16px !important; }
  .cal-dt::before { top: 2px; bottom: 2px; }
  .cal-dt b { font-size: 1.45rem; }
  .cal-cel { grid-area: c; padding-left: 12px !important; }
  .cal-co { grid-area: k; padding-left: 12px !important; }
  .cal-rk { grid-area: r; }
  .cal-cy { grid-area: y; }
  .cal-rk::before, .cal-cy::before { content: "·"; margin: 0 8px; color: var(--faint); }
  .cal-sa { grid-area: s; padding-left: 12px !important; font-size: 14.5px; }
  .cal-k { display: inline; margin-right: 6px; font: 700 10.5px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
  .cal-re { grid-area: x; padding-left: 12px !important; }
  .cal-reads { display: block; margin-top: 2px; }
  .cal-reads li { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0; line-height: 1.35; }
  .cal-reads li + li { background: linear-gradient(90deg, var(--line), transparent 80%) top left / 100% 1px no-repeat; }
  .cal-rl { flex: none; width: 52px; min-width: 0; }
  .cal-ra { flex: 1 1 auto; align-self: stretch; display: flex; align-items: center; min-width: 0; padding: 6px 0; text-decoration: none; }
  a.cal-ra .cal-ct { text-decoration: underline 1px var(--line-2); text-underline-offset: .2em; }
  a.cal-ra:hover .cal-ct { text-decoration-color: currentColor; }
  .cal-na span:last-child { padding: 6px 0; }
  .cal-also { margin-top: 8px; }
  .cal-r.is-today, .cal-r:target { border-radius: 14px; }
}

@media screen and (min-width: 760px) and (max-width: 1199.98px) {
  .cal-r { grid-template-columns: 58px auto auto minmax(0, 1fr) minmax(260px, 40%); grid-template-rows: auto auto auto 1fr; grid-template-areas: "d c c c x" "d k r y x" "d s s s x" "d . . . x"; align-content: start; }
  .cal-re { padding-left: 24px !important; }
}

/* ---------- /today/ ---------- */
.td-head { margin-bottom: clamp(28px, 4vw, 40px); }
.td-dot { background: var(--sf); box-shadow: 0 0 10px color-mix(in srgb, var(--sf) 70%, transparent); }
.td-dot--white { background: var(--gold-fill); }
.td-h1 { max-width: calc(22 * var(--ch-serif)) !important; font-size: clamp(2.3rem, 1.5rem + 2.6vw, 3.7rem) !important; }
.td-hero { display: grid; gap: 0; }
@media (min-width: 1100px) {
  .td-hero { grid-template-columns: minmax(0, 1fr) 380px; gap: clamp(48px, 5vw, 80px); align-items: end; }
  .td-hero .td-head { margin-bottom: 0; }
}
.td-h1__date { display: block; margin-bottom: .32em; font: italic 500 clamp(1.3rem, 1.05rem + 1vw, 1.85rem)/1.2 var(--serif); letter-spacing: 0; color: var(--gold); }
.td-h1__cel { display: block; }
.td-sub { margin-top: 12px; font: italic 500 clamp(1.15rem, 1.05rem + .4vw, 1.4rem)/1.35 var(--serif); color: var(--fg-2); }
.td-meta .js-only { color: var(--dim); }
.td-stale:not([hidden]) { margin-top: 18px; }
.td-panel { position: relative; isolation: isolate; overflow: hidden; display: grid; gap: 22px; padding: clamp(22px, 3.2vw, 34px); border-radius: 28px;
  background: linear-gradient(180deg, var(--glass-hi), transparent 50%), var(--card-2);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--sc) 30%, transparent), inset 0 1px 0 var(--rim), 0 24px 60px -34px var(--shadow); }
.td-panel__glow { position: absolute; inset: 0; z-index: -1; background: radial-gradient(90% 120% at 0% 0%, color-mix(in srgb, var(--sf) 30%, transparent), transparent 66%); }
.td-panel--white .td-panel__glow { background: radial-gradient(90% 120% at 0% 0%, rgb(201 164 76 / .22), transparent 66%); }
.td-panel__color { display: flex; align-items: center; gap: 18px; }
.td-orb { position: relative; flex: none; width: 64px; height: 64px; border-radius: 50%; background: radial-gradient(circle at 34% 30%, color-mix(in srgb, #fff 28%, var(--sf)), var(--sf) 62%);
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / .18), inset 0 -6px 14px rgb(0 0 0 / .18), 0 0 0 1px var(--rim-dim); }
.td-orb--white { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold-fill) 70%, transparent), inset 0 -6px 14px rgb(120 90 30 / .16); }
.td-orb::after { content: ""; position: absolute; inset: -18px; z-index: -1; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--sf) 55%, transparent), transparent); opacity: .7; }
.td-orb--white::after { background: radial-gradient(closest-side, rgb(201 164 76 / .45), transparent); }
@media (prefers-reduced-motion: no-preference) { .td-orb::after { animation: td-breathe 5.5s ease-in-out infinite alternate; } }
@keyframes td-breathe { from { opacity: .45; transform: scale(.92); } to { opacity: .85; transform: scale(1.06); } }
.td-k, .td-facts dt { font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.td-v { font-size: 16px; color: var(--fg); }
.td-v--lg { margin-top: 4px; font: 600 clamp(1.7rem, 1.4rem + 1.2vw, 2.35rem)/1.05 var(--serif); color: var(--sc); }
.td-panel--white .td-v--lg { color: var(--fg); }
.td-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.td-facts dd { margin-top: 4px; font-size: 16px; line-height: 1.4; color: var(--fg); }
.td-facts a { color: var(--gold); }
@media (min-width: 900px) and (max-width: 1099.98px) {
  .td-panel { grid-template-columns: minmax(220px, .8fr) 2.4fr; align-items: center; gap: 36px; }
  .td-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 0 0 0 36px; border-top: 0; border-left: 1px solid var(--line); }
}
.td-cols { display: grid; gap: clamp(40px, 6vw, 56px); margin-top: clamp(40px, 6vw, 64px); }
@media (min-width: 1024px) { .td-cols { grid-template-columns: minmax(0, 1fr) 360px; gap: clamp(48px, 5vw, 80px); align-items: start; } .td-side { position: sticky; top: calc(var(--head-h) + 24px); } }
.td-sec + .td-sec { margin-top: 36px; }
.td-readings > .h3 { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.td-us { font: 700 11px/1 var(--sans); letter-spacing: .12em; padding: 5px 8px; border-radius: 999px; color: var(--marian); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--marian) 45%, transparent); }
.td-notes { display: grid; gap: 6px; margin: 4px 0 8px; font-size: 14.5px; color: var(--fg-2); }
.td-notes p { padding-left: 14px; border-left: 2px solid var(--gold-fill); }
.td-mass--alt { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line-2); }
.td-mass__h { font: 700 12.5px/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 4px; }
.td-reads { counter-reset: none; }
.td-r { display: grid; gap: 2px 18px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.td-r__slot { font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.td-r__cit { font: 600 clamp(1.35rem, 1.2rem + .6vw, 1.65rem)/1.25 var(--serif); color: var(--fg); overflow-wrap: anywhere; font-variant-numeric: lining-nums; }
.td-r__cit--na { font-style: italic; font-weight: 500; color: var(--dim); }
.td-r__or { display: block; margin-top: 2px; font: 500 15px/1.4 var(--sans); color: var(--dim); }
.td-r__go { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.td-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 0 16px; border-radius: 999px; font: 600 14.5px/1 var(--sans); color: var(--gold); text-decoration: none; background: var(--card-2); box-shadow: inset 0 0 0 1px var(--rim-dim), inset 0 1px 0 var(--rim); transition: transform .25s var(--ease); }
.td-chip:hover { transform: translateX(2px); }
@media (max-width: 759.98px) {
  .td-r { grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 14px; }
  .td-r__slot { grid-column: 1 / -1; }
  .td-r__go { grid-column: 2; grid-row: 2; margin-top: 0; flex-direction: column; align-items: flex-end; gap: 6px; }
  .td-chip { padding: 0 14px; font-size: 14px; }
}
@media (min-width: 760px) { .td-r { grid-template-columns: 150px minmax(0, 1fr) auto; align-items: baseline; } .td-r__slot { padding-top: .5em; } .td-r__go { margin-top: 0; justify-content: flex-end; } }
.td-prov { margin-top: 18px; font-size: 14px; color: var(--marian); }
.td-fine { margin-top: 10px; }
.td-sec__k { font: 700 12.5px/1.3 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--dim); margin-bottom: 12px; }
.td-saint__card { position: relative; isolation: isolate; overflow: hidden; padding: 22px; border-radius: 24px; background: var(--card-2); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crimson-fill) 28%, transparent), inset 0 1px 0 var(--rim); }
.td-saint__card::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(110% 80% at 100% 0%, rgb(180 64 78 / .16), transparent 64%); }
.td-saint__top { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: center; }
.td-saint__av { width: 44px; height: 44px; font-size: 21px; }
.td-saint__n { font: 600 1.45rem/1.15 var(--serif); }
.td-saint__n a { text-decoration: none; }
.td-saint__n a:hover { color: var(--gold); }
.td-saint__m { margin-top: 3px; font-size: 14px; color: var(--dim); }
.td-saint__p { margin-top: 14px; font-size: 14.5px; color: var(--fg-2); }
.td-saint__p span { font: 700 11px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--crimson); margin-right: 6px; }
.td-saint__x { margin-top: 12px; font-size: 15.5px; line-height: 1.6; color: var(--fg-2); }
.td-saint__card .more { margin-top: 8px; }
.td-wk__l { border-top: 1px solid var(--line); }
.td-wk__a { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px; min-height: 58px; padding: 8px 4px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--fg-2); transition: background-color .2s; }
.td-wk__a:hover { background: var(--card); }
.td-wk__d { display: flex; flex-direction: column; font: 700 10.5px/1.2 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.td-wk__d b { font: 600 1.3rem/1 var(--serif); letter-spacing: 0; color: var(--fg); }
.td-wk__t { font-size: 14.5px; line-height: 1.35; color: var(--fg); }
.td-wk__a .swatch__l { display: none; }
.td-wk__more { margin-top: 6px; }
.td-wk__none { padding: 6px 0; }
.td-full { margin-top: 20px; }
.td-full .btn { gap: 10px; }
.td-nav { margin: clamp(28px, 4vw, 40px) 0 0; }
@media (max-width: 429.98px) { .td-nav .cal-nav__y { display: none; } }
.td-more { margin-top: 6px; }
.td-wk__more + .td-wk__more { margin-top: 0; }

/* ---------- day pages /calendar/YYYY/MM/DD/ ---------- */
.cal-day .page-head { margin-bottom: clamp(22px, 3vw, 32px); }
.cal-day .page-title { max-width: calc(17 * var(--ch-serif)); font-size: clamp(2.3rem, 1.4rem + 3.2vw, 3.9rem); }
.cal-day .page-title em { display: block; margin-top: .12em; font-size: .62em; line-height: 1.15; }
.dy-nav { margin-bottom: clamp(24px, 3vw, 32px); }
/* one grid for the whole page: header | the day, the readings | saint and links (no wrapper, so a phone reads
   header → days nav → the day → readings → saint, and a desktop puts the day beside the header) */
.cal-day .page { display: grid; grid-template-columns: minmax(0, 1fr); }
.cal-day .dy-box { margin-bottom: clamp(36px, 5vw, 48px); }
.cal-day .dy-side { margin-top: clamp(40px, 6vw, 56px); }
@media (min-width: 1024px) {
  .cal-day .page { grid-template-columns: minmax(0, 1fr) 340px; grid-template-areas: "head box" "nav nav" "main side" "pager pager"; column-gap: clamp(48px, 5vw, 80px); }
  .cal-day .page > .page-head { grid-area: head; min-width: 0; }
  .cal-day .dy-box { grid-area: box; align-self: end; margin-bottom: clamp(22px, 3vw, 32px); }
  .cal-day .dy-nav { grid-area: nav; }
  .cal-day .dy-main { grid-area: main; min-width: 0; }
  .cal-day .dy-side { grid-area: side; align-self: start; margin-top: 0; position: sticky; top: calc(var(--head-h) + 24px); }
  .cal-day .page > .pager { grid-area: pager; }
}
.dy-jump { margin: 14px 0 6px; }
/* the day: its colour as a soft glow, never a solid block */
.dy-panel { position: relative; isolation: isolate; overflow: hidden; display: grid; gap: 18px; padding: clamp(20px, 3vw, 28px); border-radius: 26px;
  background: linear-gradient(180deg, var(--glass-hi), transparent 50%), var(--card-2);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--sc) 28%, transparent), inset 0 1px 0 var(--rim), 0 24px 60px -34px var(--shadow); }
.dy-panel__glow { position: absolute; inset: 0; z-index: -1; background: radial-gradient(100% 90% at 0% 0%, color-mix(in srgb, var(--sf) 28%, transparent), transparent 68%); }
.cal-day--white .dy-panel__glow { background: radial-gradient(100% 90% at 0% 0%, rgb(201 164 76 / .2), transparent 68%); }
.dy-panel__color { display: flex; align-items: center; gap: 16px; }
.dy-panel .td-orb { width: 52px; height: 52px; }
.dy-color { margin-top: 3px; font: 600 clamp(1.6rem, 1.35rem + 1vw, 2.1rem)/1.05 var(--serif); color: var(--sc); }
.cal-day--white .dy-color { color: var(--fg); }
.dy-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.dy-facts dt { font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.dy-facts dd { margin-top: 4px; font-size: 16px; line-height: 1.4; color: var(--fg); }
.dy-facts__w { grid-column: 1 / -1; }
.dy-facts__w dd { font: 600 1.15rem/1.3 var(--serif); }
/* readings */
.dy-h2 { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.dy-notes { margin: 10px 0 4px; }
.dy-mass + .dy-mass { margin-top: clamp(36px, 5vw, 52px); }
.dy-mass__h { position: relative; margin-top: 8px; padding-top: 22px; font: 700 12.5px/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); scroll-margin-top: calc(var(--head-h) + 20px); }
.dy-mass + .dy-mass .dy-mass__h::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, var(--line-2), transparent 85%); }
.dy-r { position: relative; padding: 24px 0 26px; }
.dy-r + .dy-r::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, var(--line), transparent 85%); }
.dy-r__h { display: grid; gap: 4px; scroll-margin-top: calc(var(--head-h) + 20px); }
.dy-r__slot { font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.dy-r--gospel .dy-r__slot, .dy-r--procession-gospel .dy-r__slot { color: var(--sc); }
.cal-day--white .dy-r--gospel .dy-r__slot, .cal-day--white .dy-r--procession-gospel .dy-r__slot { color: var(--gold); }
.dy-r__cit { font: 600 clamp(1.35rem, 1.2rem + .6vw, 1.7rem)/1.25 var(--serif); color: var(--fg); overflow-wrap: anywhere; }
.dy-r__cit--na { font-style: italic; font-weight: 500; color: var(--dim); }
.dy-r__or { margin-top: 3px; font: 500 15px/1.45 var(--sans); color: var(--dim); }
.dy-r__go { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.dy-r__src { margin-top: 10px; font-size: 13.5px; line-height: 1.5; color: var(--dim); }
.dy-r--na .dy-r__src { max-width: calc(52 * var(--ch)); }
/* the text: chapter-page reading type, a soft rail in the day's colour (fading at both ends) */
.dy-vl { position: relative; margin-top: 16px; padding-left: 20px; max-width: calc(62 * var(--ch)); }
.dy-vl::before { content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 2px; border-radius: 2px;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--sf) 75%, transparent) 14%, color-mix(in srgb, var(--sf) 75%, transparent) 86%, transparent); }
.cal-day--white .dy-vl::before { background: linear-gradient(180deg, transparent, rgb(201 164 76 / .7) 14%, rgb(201 164 76 / .7) 86%, transparent); }
.dy-vl .vlist__v { padding: 3px 0; }
.dy-vl .vlist__t { font-size: 1.24rem; line-height: 1.58; }
.dy-r--gospel .dy-vl .vlist__t { font-size: 1.3rem; }
.dy-gap { height: 22px; position: relative; }
.dy-gap::before { content: "· · ·"; position: absolute; left: 0; top: 2px; font: 700 14px/1 var(--sans); letter-spacing: .3em; color: var(--faint); }
.dy-prov { margin-top: 18px; padding-top: 18px; display: grid; gap: 8px; position: relative; }
.dy-prov::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, var(--line-2), transparent 85%); }
.dy-prov .td-prov { margin-top: 0; }
.dy-prov .fine { max-width: calc(66 * var(--ch)); }
/* the side: saint of the day, the calendar around it */
.dy-saint .td-saint__card { padding: 20px; }
.dy-saint__mass { margin-top: 12px; font-size: 14.5px; line-height: 1.55; color: var(--fg-2); }
.dy-links { display: grid; margin-top: 18px; }
.dy-side .dy-links { margin-top: 22px; }

/* ---------- print: a month on one or two pages ---------- */
@media print {
  @page { margin: 12mm 11mm; }
  .cal-nav, .cal-top, .page-actions, .crumbs, .cal-days__h, .ys-key, .cal-k, .td-chip, .td-side .more { display: none !important; }
  .page-head { margin-bottom: 8pt; }
  .page-title { font-size: 20pt !important; max-width: none !important; }
  .page-lede { font-size: 8.5pt; line-height: 1.4; max-width: none; margin-top: 4pt; }
  .page-meta { font-size: 8pt; margin-top: 2pt; }
  .kicker { margin-bottom: 4pt; font-size: 7.5pt; }
  .cal-days { margin-top: 6pt !important; }
  .cal-tw { box-shadow: none; background: none; border-radius: 0; }
  html, body { background: #fff !important; }
  .site-foot__src, .site-foot__legal { font-size: 6.8pt !important; margin-top: 4pt !important; padding-top: 4pt !important; }
  .site-foot { padding-top: 6pt !important; }
  .cal-t { font-size: 8pt; line-height: 1.22; table-layout: fixed; }
  .cal-t thead th:nth-child(1) { width: 7%; } .cal-t thead th:nth-child(2) { width: 24.5%; } .cal-t thead th:nth-child(3) { width: 9%; }
  .cal-t thead th:nth-child(4) { width: 9.5%; } .cal-t thead th:nth-child(5) { width: 9%; } .cal-t thead th:nth-child(6) { width: 13%; }
  .cal-t thead th:nth-child(7) { width: 28%; }
  .cal-cel__n { font-family: var(--sans) !important; font-weight: 500; }
  .cal-t thead th { position: static; background: none; padding: 3pt 3.5pt; font-size: 6.4pt; letter-spacing: .05em; white-space: normal; }
  .cal-rk, .cal-co, .cal-cy { white-space: normal !important; }
  .cal-r > * { padding: 2.2pt 3.5pt !important; }
  .cal-r { break-inside: avoid; background: none !important; box-shadow: none !important; }
  .cal-r--t2 .cal-cel__n, .cal-r--t3 .cal-cel__n { font-weight: 700; }
  .cal-dt { width: auto; padding-left: 6pt !important; }
  .cal-dt::before { top: 2pt; bottom: 2pt; width: 2.5pt; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cal-dt time { flex-direction: row; gap: 4pt; align-items: baseline; }
  .cal-dt b { font-size: 9pt; color: #111 !important; }
  .cal-dt span { font-size: 6.5pt; margin: 0; }
  .cal-cel__n { font-size: 8.2pt !important; line-height: 1.22; }
  .cal-cel__s { font-size: 7.4pt; margin: 0; }
  .cal-rk, .cal-cy, .cal-co, .cal-sa { font-size: 7.4pt !important; }
  .cal-co .swatch { gap: 3pt; }
  .swatch i { width: 7pt; height: 7pt; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cal-reads li { display: inline; font-size: 7.4pt; padding: 0; }
  .cal-reads li + li::before { content: " · "; }
  .cal-rl { display: none; }
  .cal-also { font-size: 7pt; margin-top: 1pt; }
  .cal-fn, .cal-t a.cal-fn { width: auto; height: auto; padding: 0 2pt; background: none; color: #111; vertical-align: super; font-size: 6.5pt; }
  .cal-notes { font-size: 7.6pt; gap: 2pt; margin-top: 6pt; }
  .cal-prov .notice { font-size: 7.4pt; padding: 4pt 8pt; }
  .cal-prov .notice__t { font-size: 7pt; }
  .cal-reads a, .cal-sa a { text-decoration: none; color: #111; }
  .td-panel, .td-saint__card, .dy-panel { box-shadow: 0 0 0 1px #ccc; }
  .dy-nav, .dy-r__go, .dy-links, .pager, .report-line { display: none !important; }
  .dy-r { break-inside: avoid-page; padding: 10pt 0; }
  .dy-vl .vlist__t { font-size: 10.5pt; line-height: 1.45; }
}
