/* =============================================
   dancephl+ — the public pages: /read, /read/<slug>, /read/about.
   Black on white. The only colour is the blue + in the wordmark.
   Familjen Grotesk for titles, labels and metadata; Times New Roman for
   reading; Arial Bold only for the wordmark. Values follow the mockup
   (dancephl-plus-mockup-source.html). The calendar side doesn't load this.
   ============================================= */

html, body { margin: 0; background: #fff; color: #000; }

.dp { font-family: 'Familjen Grotesk', Arial, sans-serif; font-size: 15px; line-height: 1.35; color: #000; background: #fff; min-height: 100vh; }
.dp * { box-sizing: border-box; }
.dp button { background: none; border: 0; padding: 0; margin: 0; color: inherit; font: inherit; cursor: pointer; text-align: left; }
.dp a { color: inherit; text-decoration: none; }
.dp :focus-visible { outline: 2px solid #000; outline-offset: 3px; }
.dp .wm { font-family: Arial, Helvetica, sans-serif; font-weight: 700; letter-spacing: -0.035em; }
.dp .wm .p { color: #0000ee; font-size: 0.62em; position: relative; top: -0.44em; margin-left: 0.05em; letter-spacing: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* on load: the wordmark types in, then the page comes up */
@keyframes type { to { opacity: 1; } }
@keyframes slidein { from { opacity: 0; transform: translateX(48px); } to { opacity: 1; transform: none; } }
@keyframes enter { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.ty > * { opacity: 0; animation: type 1ms step-end forwards; animation-delay: calc(var(--i) * 70ms + 120ms); }
.mast .ty > * { animation-delay: calc(var(--i) * 95ms + 200ms); }
.enter { animation: enter 1s ease both; animation-delay: 0.15s; }
.enter.e2 { animation-delay: 0.3s; }
.enter.e3 { animation-delay: 0.45s; }
/* leaving a page: it fades out before the next one fades in */
.dp.leaving .stage { opacity: 0; transition: opacity 0.4s ease; }

.stage { container: stage / inline-size; position: relative; margin: 0 auto; width: 100%; max-width: 1280px; min-height: 100vh; background: #fff; }
.in { padding: 0 32px 96px; }

/* running head */
.head { position: sticky; top: 0; z-index: 3; background: #fff; }
.rh { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 44px; border-top: 1px solid #000; border-bottom: 1px solid #000; font-size: 15px; }
.rh-l, .rh-r { display: flex; align-items: center; gap: 0 8px; white-space: nowrap; min-width: 0; }
.rh a, .rh button { min-height: 44px; display: inline-flex; align-items: center; }
.rh .here { overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* the growing underline: the one hover movement, used on every link */
.u { --uh: max(1px, 0.045em); padding-bottom: 0.08em; background-image: linear-gradient(currentColor, currentColor); background-repeat: no-repeat; background-position: 0 100%; background-size: 0 var(--uh); transition: background-size 0.45s cubic-bezier(0.2, 0.7, 0.2, 1); }
.dp a:hover .u, .dp button:hover .u, .dp a:focus-visible .u, .dp button:focus-visible .u, .u.on { background-size: 100% var(--uh); }

/* the same opening row, used for the bio and for notes */
.fold { display: grid; grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows 0.4s cubic-bezier(0.2, 0.7, 0.2, 1), visibility 0s 0.4s; }
.fold.open { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows 0.4s cubic-bezier(0.2, 0.7, 0.2, 1); }
.fold > div { overflow: hidden; min-height: 0; }

/* filters sit in the running head: only the current one shows; the rest
   open out sideways on hover or focus */
.filters { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0 2px; }
.f { min-height: 44px; padding: 0 5px; display: inline-flex; align-items: center; justify-content: center; }
.fx { display: inline-flex; align-items: center; max-width: 0; opacity: 0; overflow: hidden; white-space: nowrap; transition: max-width 0.5s cubic-bezier(0.2, 0.7, 0.2, 1), opacity 0.3s ease; }
.fx.on, .filters:hover .fx, .filters:focus-within .fx { max-width: 180px; opacity: 1; }
.filters:hover .fx + .fx::before, .filters:focus-within .fx + .fx::before { content: "\00b7"; padding: 0 2px; }
.fx :focus-visible { outline-offset: -3px; }

/* figures rise into place as they enter the screen */
@keyframes rise { from { opacity: 0; transform: translateY(40px); } to { opacity: 1; transform: none; } }
@supports (animation-timeline: view()) {
  .rise { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% entry 45%; }
}

/* label | content grid, shared by every view */
.g2 { display: grid; grid-template-columns: 200px minmax(0, 1fr); column-gap: 24px; }
.lab { position: sticky; top: 60px; align-self: start; }

.pdek { margin: 0; max-width: 600px; font-family: 'Times New Roman', Times, serif; font-size: 34px; line-height: 1.2; letter-spacing: -0.01em; }
.by { margin: 18px 0 0; }
.empty { margin-top: 64px; }
.empty .by a { min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- read: pieces as columns; the one under the cursor widens ---------- */

.cols6 { display: flex; margin-top: 56px; min-height: 600px; border-top: 1px solid #000; border-bottom: 1px solid #000; }
.col { flex: 1 1 0; min-width: 0; padding: 12px 12px 24px; border-left: 1px solid #000; overflow: hidden; container: col / inline-size; transition: flex-grow 0.55s cubic-bezier(0.2, 0.7, 0.2, 1); }
.col:first-child { border-left: 0; padding-left: 0; }
.col:last-child { padding-right: 0; }
.col.open { flex-grow: 2.5; }
.ci { display: flex; flex-direction: column; }
.cb { min-width: 0; }
/* a wide column sets its image beside the text, so the image never stretches */
@container col (min-width: 600px) {
  .ci { flex-direction: row; align-items: flex-start; gap: 32px; }
  .cimg { width: min(480px, 50%); }
  .cb { flex: 1; }
  .cb .ct { margin-top: 0; }
}
.col :focus-visible { outline-offset: -2px; }
.cimg { display: block; flex: none; max-width: 480px; height: 320px; background: #f3f3f1; }
.cimg img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ct { display: block; margin-top: 14px; font-size: 22px; line-height: 1.1; letter-spacing: -0.015em; transition: font-size 0.45s cubic-bezier(0.2, 0.7, 0.2, 1); overflow-wrap: break-word; }
.col.open .ct { font-size: 40px; line-height: 1.02; letter-spacing: -0.03em; }
.cm { display: flex; flex-direction: column; margin-top: 10px; }
.more { display: none; }
.col.open .more { display: block; max-width: 480px; margin-top: 18px; animation: enter 0.5s 0.2s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.more .pdek { font-size: 20px; line-height: 1.25; letter-spacing: 0; }
.pprev { margin: 10px 0 4px; font-family: 'Times New Roman', Times, serif; font-size: 17px; line-height: 25px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; }
.pread { min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- read: past the newest seven, one tight list of titles ---------- */

.earlier { margin-top: 96px; }
.earlier .fl { margin-bottom: 12px; }
.tlist { border-bottom: 1px solid #000; }
.trow { display: grid; grid-template-columns: minmax(0, 1fr) 140px 100px 70px 56px; column-gap: 20px; align-items: baseline; padding: 10px 0 12px; border-top: 1px solid #000; }
.tt { font-size: 40px; line-height: 1.05; letter-spacing: -0.025em; overflow-wrap: break-word; }
.tmeta { display: contents; }
/* the image that comes up beside the earlier list, near the cursor */
.float { position: fixed; left: 0; top: 0; z-index: 2; width: 240px; height: 300px; background: #f3f3f1; pointer-events: none; visibility: hidden; will-change: transform; }
.float img { display: block; width: 100%; height: 100%; object-fit: cover; }
.float.show { visibility: visible; }

/* ---------- the piece ---------- */

.at { margin: 72px 0 0 -0.03em; line-height: 0.95; letter-spacing: -0.035em; font-weight: 400; font-size: clamp(40px, 12cqw, 72px); overflow-wrap: break-word; }
.dek { margin-top: 40px; }
.dek p { grid-column: 2; margin: 0; max-width: 660px; font-family: 'Times New Roman', Times, serif; font-size: 28px; line-height: 1.2; letter-spacing: -0.01em; }
.details { margin-top: 56px; border-bottom: 1px solid #000; }
.dr { padding: 12px 0; border-top: 1px solid #000; align-items: baseline; }
.details p { margin: 0; }
.details .lab { position: static; }
.bio-b { min-height: 44px; margin: -12px 0; display: inline-flex; align-items: center; gap: 10px; }
.details .bio { max-width: 520px; padding: 10px 0 8px; font-family: 'Times New Roman', Times, serif; font-size: 16px; line-height: 23px; }

.body { margin-top: 96px; }
.fig { margin-top: 32px; }
.cont { margin-top: 64px; }
.brk { margin-top: 128px; }
.sec.body { margin-top: 96px; }
.txt, .sec figure { max-width: 660px; }
.sec figure { margin: 0; }
.sec .txt p { margin: 0 0 32px; font-family: 'Times New Roman', Times, serif; font-size: 20px; line-height: 32px; }
.sec .txt p.spaced { white-space: pre-wrap; tab-size: 4; }
/* ||redacted||: a solid bar; the letters under it are only x's */
.redact { background: #000; color: transparent; -webkit-user-select: none; user-select: none; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
@media (forced-colors: active) { .redact { background: CanvasText; forced-color-adjust: none; } }
.sec .txt p a { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.sec .txt p a:hover { text-decoration-thickness: 2px; }
.sec blockquote { margin: 56px 0; font-family: 'Times New Roman', Times, serif; font-size: 34px; line-height: 1.2; letter-spacing: -0.01em; }
.sec blockquote p, .sec .txt blockquote p { margin: 0; font: inherit; }
.sec blockquote cite { display: block; margin-top: 14px; font-family: 'Familjen Grotesk', Arial, sans-serif; font-size: 15px; line-height: 1.35; font-style: normal; letter-spacing: 0; }
.sec figcaption { margin-top: 12px; }
.sec figure img, .sec figure video { display: block; width: 100%; height: auto; }
.sec figure iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; }
.sec .qa { margin: 0 0 8px; font-size: 15px; }
.dp .fn { font-family: 'Familjen Grotesk', Arial, sans-serif; font-size: 15px; line-height: 0; vertical-align: super; padding: 12px 8px; margin: -12px -2px; text-decoration: underline; text-underline-offset: 3px; }
.fnote { margin: -16px 0 32px; padding: 10px 0; border-top: 1px solid #000; border-bottom: 1px solid #000; }
.notes { margin: 0; padding: 0 0 0 20px; max-width: 660px; }
.notes li { margin-bottom: 8px; font-family: 'Times New Roman', Times, serif; font-size: 17px; line-height: 25px; }

/* images side by side, each set high, mid or low */
.pair { display: flex; align-items: flex-start; gap: 48px; }
.sec .pair figure { flex: 1; min-width: 0; max-width: none; }
.pair .mid { margin-top: 64px; }
.pair .low { margin-top: 128px; }

/* ---------- the widening columns: the end of a piece, and the footer ---------- */

.xcols { display: flex; border-top: 1px solid #000; }
.xcol { flex: 1 1 0; min-width: 0; padding: 14px 12px 24px; border-left: 1px solid #000; overflow: hidden; transition: flex-grow 0.55s cubic-bezier(0.2, 0.7, 0.2, 1); }
.xcol:first-child { border-left: 0; padding-left: 0; }
.xcol :focus-visible { outline-offset: -2px; }
.xcol:hover, .xcol:focus-within, .xcols:not(:hover):not(:focus-within) .xcol.first { flex-grow: 3; }
.xsub { display: none; }
.xcol:hover .xsub, .xcol:focus-within .xsub, .xcols:not(:hover):not(:focus-within) .xcol.first .xsub { display: flex; flex-direction: column; align-items: flex-start; animation: enter 0.5s 0.15s ease both; }
.onward { margin-top: 128px; }
.mcols { border-bottom: 1px solid #000; }
.mcols .cimg { height: 220px; margin-bottom: 14px; }
.mcols .ct { margin-top: 0; font-size: 28px; letter-spacing: -0.02em; }
.mcols .xsub { margin-top: 16px; }
.mcols .pdek { font-size: 20px; line-height: 1.25; letter-spacing: 0; }
.fl { margin-bottom: 10px; }

.foot { margin-top: 160px; }
.fg { display: flex; flex-direction: column; align-items: flex-start; }
.fg a { min-height: 32px; display: inline-flex; align-items: center; }
.fg .xsub { padding: 0 0 8px 16px; color: #555; }

/* ---------- about ---------- */

.mast { margin: 0; padding-top: 96px; font-size: clamp(56px, 9cqw, 116px); line-height: 1; font-weight: 700; }
.about { margin-top: 88px; }
.about p { margin: 0 0 0.6em; max-width: 860px; font-family: 'Times New Roman', Times, serif; font-size: 34px; line-height: 1.24; letter-spacing: -0.01em; }

/* ---------- mid widths: tablets and narrow windows ---------- */

@container stage (max-width: 1040px) {
  .g2 { grid-template-columns: 140px minmax(0, 1fr); }
  .trow { grid-template-columns: minmax(0, 1fr); row-gap: 6px; }
  .tt { font-size: 34px; }
  .tmeta { display: flex; flex-wrap: wrap; gap: 2px 16px; }
  .float { display: none; }
}

/* columns become a stack when there is no room for them side by side */
@container stage (max-width: 900px) {
  .cols6 { flex-direction: column; min-height: 0; margin-top: 32px; }
  .col, .col.open { flex: none; padding: 12px 0 16px; border-left: 0; border-top: 1px solid #000; }
  .col:first-child, .col.open:first-child { border-top: 0; }
  .cimg { display: none; }
  .col.open .cimg { display: block; width: min(100%, 340px); height: 240px; animation: slidein 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .col.open .ct { margin-top: 14px; font-size: 30px; }
  .ct { margin-top: 0; min-height: 28px; }
  .cm { flex-direction: row; flex-wrap: wrap; gap: 2px 14px; margin-top: 6px; }
}

/* ---------- phones and narrow widths ---------- */

@container stage (max-width: 760px) {
  .in { padding: 0 20px 64px; }
  .rh { min-height: 48px; flex-wrap: wrap; gap: 0 8px; }
  .rh a, .rh button { min-height: 48px; }
  .rh-r { gap: 0 6px; order: 1; margin-left: auto; }
  .rh-l.has-filters { display: contents; }
  .fsep { display: none; }
  .filters { order: 2; flex: 0 0 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; border-top: 1px solid #000; }
  .filters::-webkit-scrollbar { display: none; }
  .fx { flex: none; max-width: none; opacity: 1; overflow: visible; }
  .fx + .fx::before { content: "\00b7"; padding: 0 2px; }
  .fx:first-child .f { padding-left: 0; justify-content: flex-start; }
  .f { min-height: 48px; min-width: 48px; }
  .g2 { grid-template-columns: minmax(0, 1fr); }
  .lab { position: static; margin-bottom: 14px; }
  .ct { display: flex; align-items: center; min-height: 48px; }
  .col.open .ct { display: block; min-height: 48px; }
  .pread { min-height: 48px; }
  .pdek { font-size: 24px; }
  .earlier { margin-top: 64px; }
  .tt { font-size: 28px; display: flex; align-items: center; min-height: 48px; }
  .empty .by a { min-height: 48px; }
  .mast { padding-top: 56px; }
  .about { margin-top: 48px; }
  .about p { font-size: 24px; line-height: 1.28; }
  .foot { margin-top: 96px; }
  .fg a { min-height: 48px; }
  .xcols { flex-direction: column; }
  .xcol { flex: none; padding: 14px 0 18px; border-left: 0; border-top: 1px solid #000; }
  .xcol:first-child { border-top: 0; }
  .mcols .cimg { display: block; height: 180px; }
  .at { margin-top: 64px; }
  .dek { margin-top: 24px; }
  .dek p { grid-column: 1; font-size: 24px; }
  .details { margin-top: 32px; }
  .details .lab { margin-bottom: 2px; }
  .bio-b { min-height: 48px; }
  .sec blockquote { margin: 40px 0; font-size: 24px; }
  .brk { margin-top: 80px; }
  .body, .sec.body { margin-top: 64px; }
  .fig { margin-top: 19px; }
  .fig.brk { margin-top: 80px; }
  .cont { margin-top: 48px; }
  .sec > .lab { display: none; }
  .sec.keep > .lab, .sec.brk > .lab { display: block; }
  .sec .txt p { font-size: 18px; line-height: 29px; margin-bottom: 29px; }
  .pair { flex-direction: column; gap: 32px; }
  .pair .mid, .pair .low { margin-top: 0; }
  .onward { margin-top: 80px; }
}

/* reduced motion: no typing, sliding, widening or fading; everything is there */
@media (prefers-reduced-motion: reduce) {
  .u, .fx, .fold, .fold.open, .xcol, .col, .ct { transition: none; }
  .rise, .enter, .col.open .more, .col.open .cimg, .xsub, .xcol .xsub { animation: none !important; }
  .ty > * { opacity: 1; animation: none; }
  .dp.leaving .stage { opacity: 1; transition: none; }
}

/* --- comments on a shared draft (js/comments.js) ---
   Beside the text when there's room; a list under the piece when not. */
.cm-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 20px; padding: 10px 0; border-bottom: 1px solid #000; }
.cm-bar .cm-help { color: #555; }
.cm-status.bad { font-weight: 700; }
.cm-act { min-height: 32px; display: inline-flex; align-items: center; }
#main.has-comments { position: relative; }
mark.cmk { background: #ffeeb0; color: inherit; cursor: pointer; }
mark.cmk.lit, mark.cmk.cm-pending { background: #ffd75e; }
.cm-start { position: absolute; z-index: 4; min-height: 40px; padding: 0 14px; background: #000; color: #fff; }
.cm-start[hidden] { display: none; }
.cm-rail { margin-top: 64px; border-top: 2px solid #000; }
.cm-rail:empty { display: none; }
.cm-card { padding: 10px 0 12px; border-bottom: 1px solid #000; background: #fff; outline: none; }
.cm-card.on, .cm-card:focus-visible { box-shadow: -8px 0 0 #ffd75e; }
.cm-card p { margin: 6px 0 0; font-family: 'Times New Roman', Times, serif; font-size: 17px; line-height: 24px; white-space: pre-wrap; }
.cm-card .cm-quote { padding-left: 10px; border-left: 3px solid #ffd75e; color: #555; font-size: 15px; line-height: 21px; }
.cm-meta { color: #555; }
.cm-meta .cm-act { min-height: 0; }
.cm-reply { margin-top: 10px; padding-left: 14px; border-left: 1px solid #000; }
.cm-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 0 16px; margin-top: 6px; }
.cm-hint { color: #767676; }
.cm-replybox[hidden] { display: none; }
#cmToggle[hidden] { display: none; }
.cm-card textarea { display: block; width: 100%; margin-top: 8px; border: 1px solid #000; border-radius: 0; padding: 8px 10px; font: 17px/24px 'Times New Roman', Times, serif; color: #000; background: #fff; resize: vertical; }
.cm-group { padding: 18px 0 6px; color: #555; border-bottom: 1px solid #000; }
@container stage (min-width: 1200px) {
  .cm-rail { position: absolute; top: 0; left: 916px; right: 0; margin: 0; border-top: 0; }
  .cm-rail .cm-card, .cm-rail .cm-group { position: absolute; left: 0; right: 0; border-top: 1px solid #000; border-bottom: 0; }
}
@container stage (max-width: 760px) {
  .cm-act { min-height: 48px; }
  .cm-start { min-height: 48px; }
}
