/* The "Our Year" photo calendar (D30; docs/plan/calendars.md): the editor's chrome (cal- classes on the site's tokens, the panel's --u-gap scale from
   studio.css) and the calendar's pages, which the editor, "Check every page" and the print file (engine/templates/render_calendar.py) all draw. */
/* the photo book's faces (app/static/book/fonts, OFL, each with its licence there), under the book's names: a Style's faces are the book's */
@font-face { font-family: 'BK Serif'; src: url(/p/photo-book/fonts/instrument-serif-latin-400-normal.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: 'BK Serif'; font-style: italic; src: url(/p/photo-book/fonts/instrument-serif-latin-400-italic.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: 'BK Classic'; src: url(/p/photo-book/fonts/marcellus-latin-400-normal.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: 'BK Sans'; src: url(/p/photo-book/fonts/jost-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'BK Sans'; src: url(/p/photo-book/fonts/jost-latin-500-normal.woff2) format('woff2'); font-weight: 500; font-display: swap; }

/* ---- a calendar page: laid out in % of the trim; --mm is one millimetre of it, so type keeps its printed size at any width ---- */
.cal-pg { position: relative; width: 100%; container-type: inline-size; overflow: hidden; background: var(--pp); color: var(--pi);
  --mm: calc(100cqw / var(--W)); font-family: var(--body), sans-serif; line-height: 1.15; font-variant-numeric: lining-nums;
  -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.cal-pg > div { position: absolute; box-sizing: border-box; }
.cal-ph { overflow: hidden; background: color-mix(in srgb, var(--pi) 8%, var(--pp)); }
.cal-ph img { position: absolute; display: block; max-width: none; user-select: none; -webkit-user-drag: none; pointer-events: none; }
.cal-title, .cal-sub, .cal-year, .cal-cap { display: flex; align-items: flex-end; overflow: hidden; white-space: nowrap; line-height: 1.05; }
.cal-title { font-family: var(--face), serif; font-weight: 400; }
.cal-ctitle, .cal-sub, .cal-year, .cal-btitle { justify-content: center; text-align: center; }
.cal-sub { font-family: var(--body), sans-serif; color: var(--pa); align-items: center; }
.cal-year { font-family: var(--face), serif; align-items: flex-start; }
.cal-cap { font-family: var(--face), serif; font-style: italic; align-items: center; white-space: normal; }
.cal-cap span { overflow-wrap: anywhere; }
.cal-right { justify-content: flex-end; text-align: right; }

.cal-grid { display: grid; column-gap: calc(var(--mm) * 1); }
.cal-wd { font-weight: 500; align-self: end; padding: 0 0 calc(var(--mm) * 1) calc(var(--mm) * 1); }
.cal-wd.cal-we, .cal-sd.cal-we small { color: var(--pa); }
.cal-d { min-width: 0; min-height: 0; overflow: hidden; display: flex; flex-direction: column; gap: calc(var(--mm) * .6); padding: calc(var(--mm) * 1);
  border-top: calc(var(--mm) * .25) solid color-mix(in srgb, var(--pi) 24%, transparent); }
.cal-d.cal-out { border-top-color: color-mix(in srgb, var(--pi) 8%, transparent); }
.cal-d.cal-we, .cal-sd.cal-we, .cal-ld.cal-we { background: color-mix(in srgb, var(--pa) 7%, transparent); }
.cal-d b, .cal-sd b, .cal-ld b { font-weight: 500; line-height: 1; font-variant-numeric: lining-nums tabular-nums; }
.cal-hol > b, .cal-hol b { color: var(--pa); }
.cal-m { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; line-height: 1.1; hyphens: auto; overflow-wrap: break-word; }  /* whole words, hyphenated in English where a box is narrow; 3 lines at most */
.cal-holiday { color: var(--pa); }
.cal-own { font-weight: 500; }
.cal-wk { font-style: normal; align-self: start; padding-top: calc(var(--mm) * 1.2); color: color-mix(in srgb, var(--pi) 55%, transparent); }
.cal-strip { display: flex; flex-direction: column; }
.cal-sdays { display: grid; border-top: calc(var(--mm) * .25) solid color-mix(in srgb, var(--pi) 24%, transparent); }
.cal-sd { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: calc(var(--mm) * 1); min-width: 0; }
.cal-sd small { font-size: inherit; color: color-mix(in srgb, var(--pi) 60%, transparent); }
.cal-sd.cal-own b, .cal-d.cal-own > b { text-decoration: underline; text-decoration-color: var(--pa); text-underline-offset: .2em; }
.cal-notes { flex: 1; min-height: 0; overflow: hidden; display: flex; flex-wrap: wrap; align-content: flex-start; column-gap: calc(var(--mm) * 4); row-gap: calc(var(--mm) * .8); padding-top: calc(var(--mm) * 1.5); }
.cal-notes b { font-weight: 500; }
.cal-list { display: grid; }
.cal-ld { display: grid; grid-template-columns: 2.1em 2.4em minmax(0, 1fr); align-items: center; min-height: 0; overflow: hidden; white-space: nowrap;
  border-top: calc(var(--mm) * .2) solid color-mix(in srgb, var(--pi) 18%, transparent); padding-left: calc(var(--mm) * 1); }
.cal-ld small { font-size: max(.8em, calc(var(--mm) * 2.47));  /* never under 7 pt in print (Gelato, support 8996349) */  color: color-mix(in srgb, var(--pi) 60%, transparent); }
.cal-ld em { font-style: normal; overflow: hidden; text-overflow: ellipsis; }
.cal-mini { display: flex; flex-direction: column; }
.cal-mini h3 { margin: 0 0 .2em; font-family: var(--face), serif; font-weight: 400; line-height: 1.25; }
.cal-mini > div { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; align-items: center; justify-items: center; font-variant-numeric: lining-nums tabular-nums; }
.cal-mini > div > * { width: 1.9em; line-height: 1.9em; }
.cal-mini b { font-weight: 500; color: color-mix(in srgb, var(--pi) 60%, transparent); }
.cal-mini b.cal-we, .cal-mini .cal-hol { color: var(--pa); }
.cal-mini .cal-own { background: var(--pa); color: var(--pp); border-radius: 50%; }

/* school terms; the moon's phases as small drawn discs (lit part paper, the rest ink; the southern hemisphere sees a quarter's other side lit);
   a photo on a date, small above the day's words */
.cal-term { color: color-mix(in srgb, var(--pi) 70%, transparent); font-style: italic; }
.cal-d > b { display: flex; align-items: center; gap: .35em; }  /* the moon sits beside its own number, never out by the next day's */
.cal-moon { display: inline-block; flex: none; vertical-align: -.08em; margin-left: .3em; border-radius: 50%; box-sizing: border-box;
  border: calc(var(--mm) * .25) solid var(--pi); }
.cal-moon-new { background: var(--pi); }
.cal-moon-first, .cal-south.cal-moon-last { background: linear-gradient(90deg, var(--pi) 50%, transparent 50%); }
.cal-moon-last, .cal-south.cal-moon-first { background: linear-gradient(270deg, var(--pi) 50%, transparent 50%); }
.cal-d > b .cal-moon { margin-left: 0; }
.cal-sd { position: relative; }
.cal-sd .cal-moon { position: absolute; left: 50%; bottom: calc(var(--mm) * .6); margin: 0; transform: translateX(-50%); }  /* under the number, which stays in line */
.cal-ld em .cal-moon { margin: 0 .4em 0 0; }
.cal-d.cal-pic { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); grid-auto-rows: auto; column-gap: calc(var(--mm) * 1); row-gap: calc(var(--mm) * .6); }
.cal-pic > b { align-self: start; flex-direction: column; align-items: flex-start; }
.cal-pic > b .cal-moon { margin: calc(var(--mm) * .8) 0 0; }
.cal-dph { display: block; min-height: 0; overflow: hidden; }
.cal-dph img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cal-pic .cal-m { grid-column: 1 / -1; -webkit-line-clamp: 1; }

/* the editor only: an empty frame, the chosen frame, and the hook's band at the top (never printed) */
.cal-edit .cal-ph.cal-target, .cal-drop.cal-target, .cal-tray.cal-target { outline: 3px dashed var(--focus); outline-offset: -3px; }
.cal-edit .cal-ph:not(.cal-empty) { cursor: grab; touch-action: none; }
.cal-edit .cal-ph:not(.cal-empty):active { cursor: grabbing; }
.cal-edit .cal-ph, .cal-thumb { -webkit-tap-highlight-color: transparent; }
.cal-empty { display: flex; align-items: center; justify-content: center; outline: 1px dashed color-mix(in srgb, var(--pi) 40%, transparent); outline-offset: -1px; }
.cal-edit .cal-empty { cursor: pointer; }
.cal-add { font: 500 max(12px, calc(var(--mm) * 3.2))/1.2 var(--font); color: color-mix(in srgb, var(--pi) 70%, transparent); text-align: center; padding: 4px; }
.cal-thumb .cal-add { display: none; }
.cal-ph.cal-sel { outline: 3px solid var(--focus); outline-offset: -3px; }
.cal-ph:focus-visible { outline: 3px solid var(--focus); outline-offset: -3px; }
.cal-guide { position: absolute; left: 0; right: 0; top: 0; pointer-events: none; border-bottom: 1px dashed rgb(28 28 28 / .45);
  background: rgb(28 28 28 / .05); }
.cal-guide i { position: absolute; left: 50%; top: 0; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; border: 1px dashed rgb(28 28 28 / .55); background: rgb(255 255 255 / .35); }
/* the two-page calendar's marks (calendar.js guideHTML): the wire's band, and the hole punched through every sheet */
.cal-guides { inset: 0; pointer-events: none; }
.cal-wire, .cal-hole { position: absolute; box-sizing: border-box; }
.cal-wire { left: 0; right: 0; border-block: 1px dashed rgb(28 28 28 / .45); background: rgb(28 28 28 / .05); }
.cal-hole { aspect-ratio: 1; border-radius: 50%; border: 1px dashed rgb(28 28 28 / .55); background: rgb(255 255 255 / .35); }

/* the binding as it will hang (calendar.js coilHTML), never printed: Wire-O at Gelato's 3:1 pitch (a twin loop every 8.47 mm), each pair over
   its punched hole. One tile a pitch, drawn in the page's millimetres: a page edge's 5 mm (the loops run off the edge), or the open month's 10 mm
   across the two pages' meeting edges (a hole each side, the loops over the gap). .cal-up: the wire on the page's bottom edge. */
.cal-pg > .cal-coil { pointer-events: none; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8.47 5'%3E%3ClinearGradient id='g'%3E%3Cstop offset='0' stop-color='%231c1c1e'/%3E%3Cstop offset='.45' stop-color='%23a9a9ae'/%3E%3Cstop offset='1' stop-color='%231c1c1e'/%3E%3C/linearGradient%3E%3Crect x='2.6' y='2.3' width='3.3' height='2.4' rx='.6' fill-opacity='.55'/%3E%3Crect x='3.05' y='-1' width='.95' height='4.9' rx='.47' fill='url(%23g)'/%3E%3Crect x='4.45' y='-1' width='.95' height='4.9' rx='.47' fill='url(%23g)'/%3E%3C/svg%3E") center top / calc(var(--mm) * 8.47) 100% repeat-x;
  filter: drop-shadow(0 calc(var(--mm) * .35) calc(var(--mm) * .3) rgb(0 0 0 / .3)); }
.cal-pg > .cal-coil.cal-up { transform: scaleY(-1); }
.cal-pg > .cal-coil.cal-mid { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8.47 10'%3E%3ClinearGradient id='g'%3E%3Cstop offset='0' stop-color='%231c1c1e'/%3E%3Cstop offset='.45' stop-color='%23a9a9ae'/%3E%3Cstop offset='1' stop-color='%231c1c1e'/%3E%3C/linearGradient%3E%3Crect x='2.6' y='0.30000000000000004' width='3.3' height='2.4' rx='.6' fill-opacity='.55'/%3E%3Crect x='2.6' y='7.3' width='3.3' height='2.4' rx='.6' fill-opacity='.55'/%3E%3Crect x='3.05' y='1.1' width='.95' height='7.8' rx='.47' fill='url(%23g)'/%3E%3Crect x='4.45' y='1.1' width='.95' height='7.8' rx='.47' fill='url(%23g)'/%3E%3C/svg%3E") center / calc(var(--mm) * 8.47) 100% repeat-x,
  linear-gradient(transparent calc(50% - var(--mm) * .5), rgb(0 0 0 / .18) 50%, transparent calc(50% + var(--mm) * .5)); }
/* the one-page calendar's hanger, in the wire's gap over the hook hole */
.cal-pg > .cal-hook { top: 0; pointer-events: none; border: calc(var(--mm) * .7) solid #2a2a2c; border-top: 0; border-radius: 0 0 50% 50% / 0 0 70% 70%;
  filter: drop-shadow(0 calc(var(--mm) * .4) calc(var(--mm) * .4) rgb(0 0 0 / .25)); }
.cal-snap:not(.cal-snap-wire) .cal-pg :is(.cal-coil, .cal-hook) { display: none; }

/* ---- the print file: one sheet a page, trim + bleed, the page at the trim (render_calendar.py) ---- */
#cal-print .cal-sheet { position: relative; overflow: hidden; break-after: page; }
#cal-print .cal-sheet:last-child { break-after: auto; }
#cal-print .cal-at { position: absolute; }
#cal-print .cal-pg { height: 100%; overflow: visible; }

/* ---- the editor's chrome: the shop's studio grid (studio.css), as the photo book; only the calendar's own pieces here ---- */
html:not([data-cal="edit"]) .cal-app .sw-pinbar { position: static; margin-bottom: 0; }  /* studio.css pins it for the editor's grid; Check every page scrolls */
.cal-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.cal-noscript { padding: 40px var(--gutter); }
.cal-h1 { margin: 0; font: var(--display-wt) clamp(26px, 4vw, 36px)/1.15 var(--font-display); font-variant-numeric: lining-nums; text-wrap: balance; }
.cal-lede { margin: 0; max-width: 62ch; font-size: 17px; }
.cal-note { margin: 0; font-size: 14.5px; line-height: 1.45; color: var(--muted); font-weight: 400; }
.cal-err { margin: 0; color: var(--error); font-size: 14.5px; }
.cal-err:empty { display: none; }
.cal-price { font-weight: 500; font-variant-numeric: lining-nums tabular-nums; }
.cal-app .sw-linkbtn { color: var(--brass); padding: 2px 0; min-height: 24px; }
.cal-app .sw-linkbtn[disabled] { color: var(--muted); text-decoration: none; cursor: default; }

/* the preview: the page on the stone wall, its name and pager, then the strip of 14 pages */
.cal-fit { flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 8px; }
.cal-stage { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; }
.cal-pagebox { flex: 1; min-height: 0; container-type: size; display: grid; place-items: center; }
.cal-frame { box-shadow: var(--u-card-shadow); }
.cal-pagebox .cal-frame { width: min(100cqw, 100cqh * var(--ar)); }
.cal-cap-note { margin: 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; font-size: 14.5px; }
.cal-pager { display: inline-flex; gap: 16px; }
.cal-strip-nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; overscroll-behavior-x: contain; }
.cal-tab { position: relative; flex: none; min-width: 48px; min-height: 40px; padding: 6px 10px; background: var(--paper); border: 1px solid var(--rail-edge); color: var(--ink);
  font: 500 15px/1.2 var(--font); cursor: pointer; }
@media (hover: hover) and (pointer: fine) { .cal-tab:hover { border-color: var(--ink); } }
.cal-tab[aria-current] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.cal-tab.cal-todo::after { content: ''; position: absolute; top: 5px; right: 5px; width: 6px; height: 6px; border-radius: 50%; background: var(--brass); }

/* the panel: studio.css styles #panel's fields, tiles and buttons; these are the calendar's pictures in them */
.sw-body #panel .cal-tiles label { flex-direction: column; justify-content: flex-start; gap: var(--u-gap-label); padding: 10px 6px; }
.sw-body #panel .cal-sizes { --u-cols: 2; }
.sw-body #panel :is(.cal-lts, .cal-styles) { --u-cols: 3; }
.sw-body #panel .cal-ws { --u-cols: 2; }
.cal-shape { height: 52px; display: flex; align-items: flex-end; }
.cal-shape i { display: block; background: var(--u-sage); box-shadow: inset 0 0 0 1px var(--rail-edge); }
.cal-lt-pic { position: relative; display: block; overflow: hidden; background: var(--rail); box-shadow: inset 0 0 0 1px var(--rail-edge); }
.cal-lt-pic i { position: absolute; background: var(--muted); opacity: .5; }
.cal-lt-pic i.cal-lt-w { background: none; opacity: .8; border-top: 1px solid var(--muted); }
.cal-sw { position: relative; width: 100%; height: 44px; display: flex; align-items: center; justify-content: center; font-size: 20px; box-shadow: inset 0 0 0 1px rgb(0 0 0 / .08); }
.cal-sw i { position: absolute; right: 6px; bottom: 6px; width: 10px; height: 10px; border-radius: 50%; }
.sw-body #panel :is(.cal-addph, .cal-adddate) { justify-self: start; }
.cal-tray { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 6px; max-height: 288px; overflow: auto; }
.sw-body #panel button.cal-thumb { aspect-ratio: 1; min-height: 0; padding: 0; border: 1px solid var(--rail-edge); border-radius: 0; background: var(--rail); overflow: hidden; }
.cal-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cal-tile { position: relative; }
.sw-body #panel .cal-tile button.cal-thumb { width: 100%; position: relative; }
.cal-uses { position: absolute; left: 4px; bottom: 4px; min-width: 20px; height: 20px; padding: 0 5px; display: grid; place-items: center; background: var(--ink); color: var(--paper);
  font: 500 12px/1 var(--font); font-variant-numeric: lining-nums tabular-nums; }
.sw-body #panel button.cal-rm { position: absolute; top: 2px; right: 2px; width: 24px; height: 24px; min-height: 24px; padding: 0; display: grid; place-items: center;
  background: var(--paper); border: 1px solid var(--rail-edge); border-radius: 0; color: var(--ink); }
.cal-rm svg { width: 12px; height: 12px; stroke: currentColor; stroke-width: 1.6; fill: none; }
@media (hover: hover) and (pointer: fine) { .sw-body #panel button.cal-rm:hover { border-color: var(--ink); } }
.cal-trayhead { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--u-gap-label) 16px; }
.cal-drop { display: flex; flex-wrap: wrap; align-items: center; gap: var(--u-gap-label) 12px; }
.cal-acts { display: flex; flex-wrap: wrap; align-items: center; gap: var(--u-gap-label) 16px; margin: 0; }
.cal-tools, .cal-dpick { display: grid; gap: var(--u-gap-head); }
.cal-fold summary { cursor: pointer; min-height: 24px; font-weight: 500; }
.cal-checks { display: grid; gap: var(--u-gap-label); max-height: 260px; overflow: auto; margin-top: var(--u-gap-label); padding-right: 4px; }
.cal-checks .check { font-size: 15px; }
.cal-checks b { font-weight: 500; font-variant-numeric: lining-nums; }
.cal-dthumb { width: 28px; height: 28px; object-fit: cover; vertical-align: middle; margin-right: 8px; }
.cal-dpick .cal-thumb[aria-pressed="true"] { outline: 3px solid var(--focus); outline-offset: -3px; }
.cal-hint { display: block; margin-top: var(--u-gap-label); font-weight: 400; }
.sw-body #panel :is(p, .hint) { margin: 0; }
/* product pages get border-box from the engine's layout.css, which this page doesn't load; the controls only, never the calendar page (print parity) */
.cal .sw-config :is(*, *::before, *::after) { box-sizing: border-box; }
.cal-dates { list-style: none; margin: 0; padding: 0; display: grid; }
.cal-dates li { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 40px; font-size: 15px; border-bottom: 1px solid var(--u-hair); }
.cal-dates b { font-weight: 500; font-variant-numeric: lining-nums; }

/* check every page */
.cal-wrap { padding-block: 24px 56px; display: grid; gap: var(--u-gap); }
.cal-wrap :focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.cal-sum { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.cal-all { list-style: none; margin: 0; padding: clamp(16px, 3vw, 32px); background: var(--u-sage); display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 28px 24px; align-items: end; }
.cal-all li { display: grid; justify-items: center; gap: 8px; font-size: 14.5px; }
.cal-all .cal-frame { width: min(100%, calc(260px * var(--ar))); }
.cal-approve-box { display: grid; gap: 16px; max-width: 600px; justify-items: start; }

@media (max-width: 860px) {
  .cal-cap-note { font-size: 13.5px; }
  .cal-tab { min-height: 36px; min-width: 44px; padding: 4px 8px; font-size: 14px; }
  .sw-typing .cal-cap-note, .sw-typing .cal-strip-nav { display: none; }  /* the keyboard is up: only the page stays in view */
  .cal-all { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 12px; }
}
@media (prefers-reduced-motion: reduce) { .cal-wrap * { transition: none !important; scroll-behavior: auto !important; } }
/* ======== the photo book's tools on the calendar (owner review 2026-12-02: "make the calendar more like Photo Books") ========
   Copies of book.css's rules, under the same class names so the two editors look alike; book.css isn't loaded here. A change there is made
   here too. What draws the page (frames, stickers, text boxes, handles, snap lines) is page-art.css, which both editors and both prints load. */

/* ---- on the page: a photo's mask, frame, stickers and text boxes (editor, Check every page and print alike) ---- */
.cal-ph:not(.cal-empty) { background: none; }  /* a fitted or see-through photo shows the paper round it, as it prints */
.cal-clip { position: absolute; inset: 0; overflow: hidden; display: block; }
.cal-pg > .wbox { z-index: 4; line-height: 1.3; }  /* the rest of a text box is page-art.css's */
.cal-hintw { color: color-mix(in srgb, currentColor 45%, transparent); }
.cal-edit button.stk { cursor: pointer; touch-action: none; }
.cal-edit .stk[data-sel] { outline: 2px dashed var(--walnut); outline-offset: 2px; cursor: move; }
.cal-edit .wbox { cursor: pointer; outline: 1px dashed color-mix(in srgb, var(--pi) 30%, transparent); outline-offset: -1px; }
.cal-edit .wbox[data-sel] { overflow: visible; cursor: move; touch-action: none; outline: 1.5px solid var(--walnut); }
.cal-edit :is(.stk, .wbox):focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.cal-edit .cal-ph:not(.cal-empty) { cursor: pointer; touch-action: pan-x pan-y; }  /* a swipe over a photo still scrolls the page */
.cal-edit .cal-ph.cal-sel:not(.cal-empty) { touch-action: none; }  /* the chosen photo: two fingers pinch to zoom it */
.cal-edit .cal-ph:is(.cal-moving, .cal-free) { cursor: move; }
.cal-edit .cal-ph.cal-free { touch-action: none; }  /* a chosen month frame drags to move, empty or not */
.cal-ph.cal-swap { outline: 3px dashed var(--focus); outline-offset: -3px; }
[data-sec="photos"].cal-target { outline: 2px dashed var(--walnut); outline-offset: 4px; }
@media (hover: hover) and (pointer: fine) { .cal-edit :is(.cal-ph:not(.cal-empty), button.stk, .wbox):not(.cal-sel, [data-sel]):hover { outline: 1.5px solid color-mix(in srgb, var(--walnut) 70%, transparent); outline-offset: -1.5px; } }

/* ---- the crumbs bar: Home / Calendars / Edit, the tools as icons, the build offer (book.css) ---- */
@media (min-width: 861px) {
  .cal-phonebar { display: none; }
}
@media (max-width: 860px) {
  .cal-phonebar .bk-topbar { padding: 0; }
}
/* ---- the dialog: History, Check project, Keyboard shortcuts (book.css) ---- */

/* ---- the photo toolbar: floats under the chosen photo on a desktop, docks at the foot of the preview on a phone (book.css) ---- */
.cal-fit { position: relative; }
.fxrow > * { flex: none; }
:is(.fxbar, .fx-sheet) button:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
@media (max-width: 860px) {
}

/* ---- the panel: frame, mask and sticker tiles, (book.css .tiles); colour bubbles and chips are studio.css's ---- */
.tile .lay.fprev { --mm: 1px; background: color-mix(in srgb, var(--field-edge) 45%, var(--paper)); }
.tile .lay.fprev > .fr { inset: 14%; width: auto; height: auto; background-color: transparent; }
.tile .lay.fprev > svg.fr { width: 72%; height: 72%; }
.sw-body #panel .laygroup > summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; float: none; margin: 0; font: 500 15px/1.3 var(--font); cursor: pointer; list-style: none; }
.cal-wblock { display: grid; gap: var(--u-gap-head); padding-bottom: var(--u-gap-head); border-bottom: 1px solid var(--u-hair); }
.cal-wblock textarea { width: 100%; min-height: 72px; font: inherit; resize: vertical; }
.sw-body #panel .cal-thumb[aria-pressed="true"] { outline: 3px solid var(--walnut); outline-offset: 1px; }
.cal-tray { list-style: none; margin: 0; padding: 0; }
.cal-tray .cal-uses { min-width: 28px; }

/* eight tabs on a phone: the rail scrolls sideways rather than squeezing them (book.css) */
@media (max-width: 860px) { .cal .u-rail ul { grid-template-columns: repeat(var(--u-tabs, 5), minmax(76px, 1fr)); overflow-x: auto; scrollbar-width: none; } .cal .u-rail ul::-webkit-scrollbar { display: none; } }
@media (prefers-reduced-motion: reduce) { .sw-product.cal, .sw-product.cal .sw-config > * { transition: none !important; } .bk-topbar > button:active, :is(.fxbar, .fx-sheet) button:active { transform: none; } }

/* D17: Ctrl+P prints the note (site.css .sw-print-note), never the calendar. Only the shop's page: the print file has no .cal-app. */
@media print { .cal-app { display: none !important; } }

/* ---- the calendars' page (/shop/calendars, cal_hub.html, 2026-12-02): each cover's picture (scripts/cal_hub.py) on paper grey, as the books' hub ---- */
.cal-hub .cal-sec-lede { max-width: 62ch; margin: 0 0 20px; color: var(--muted); }
.sw-gallery.cal-gallery .tcov { display: flex; align-items: center; justify-content: center; aspect-ratio: 4 / 5; padding: 11%; border-radius: 0; background: var(--rail); }
.sw-gallery.cal-gallery.cal-spread .tcov { aspect-ratio: 5 / 4; padding: 9%; }  /* the two-page covers are landscape */
.cal-gallery .tcov img { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain;
  box-shadow: 0 1px 2px rgb(0 0 0 / .12), 0 8px 22px rgb(0 0 0 / .13); transition: transform .25s var(--ease-out, ease-out); }
@media (hover: hover) and (pointer: fine) { .cal-gallery .tcov:hover img { transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .cal-gallery .tcov img { transition: none; } .cal-gallery .tcov:hover img { transform: none; } }
.cal-gallery .sw-card-looks { justify-content: center; gap: 14px; }
/* scripts/cal_hub.py's pictures (calendar.js SNAP): the cover alone, on nothing */
.cal-snap :is(body, .sw-scope, #main, .sw-preview, .cal-fit, .cal-stage, .cal-pagebox, .cal-frame) { background: transparent !important; box-shadow: none !important; }
.cal-snap .cal-pg .cal-guide, .cal-snap .cal-pg .cal-guides { display: none; }

/* ---- a cover's words as its design sets them (calendar.js COVERS look) ---- */
.cal-pg > .cal-a-left { justify-content: flex-start; text-align: left; }
.cal-pg > .cal-a-right { justify-content: flex-end; text-align: right; }
.cal-pg > .cal-on { z-index: 2; color: #fff; text-shadow: 0 0 calc(var(--mm) * 2.5) rgb(0 0 0 / .35); }
.cal-pg > .cal-on.cal-sub { color: #fff; }
.cal-pg > .cal-cband { background: var(--pa); }
.cal-pg > .cal-fill-pi { background: var(--pi); }
.cal-pg > .cal-fill-pp { background: var(--pp); }
.cal-pg > .cal-fill-scrim { background: linear-gradient(rgb(0 0 0 / 0), rgb(0 0 0 / .42)); }
.cal-pg > .cal-fill-shade { background: rgb(0 0 0 / .28); }
.cal-pg > .cal-round { border-radius: 50%; }
.cal-pg > .cal-outline { color: transparent; -webkit-text-stroke: max(calc(var(--mm) * .5), .6px) var(--pi); }
.cal-pg > .cal-caps { text-transform: uppercase; letter-spacing: .12em; }
.cal-pg > .cal-onband { z-index: 2; color: var(--pp); }
