/* ==========================================================================
   referenz-takt.css — Wochenraster, Wochenreiter und Bautagebuch-Blatt für Projekte mit mehreren Wochen
   Version: 1.0 | 2026-10-10 | Quelle: Marketing/projektreferenzen/vorlagen/ (Parkhotel Dresden)
   Regel (Skill rauMKult-Webseiten): nur Anordnung mit Präfix ph-; Farben/Radien/Schatten/Schrift aus den Website-Token.
   Einzige eigene Werte: die fünf Phasenfarben (Datenfarben, keine Gestaltungsfarben), unten als Token.
   ========================================================================== */
:root {
  --ph-a: #6f8fa6; --ph-b: #c8a56a; --ph-c: #9bb08a; --ph-d: #8a7fb0; --ph-e: #d0765a; /* Phasen: reinigen, füllen, retuschieren, Läufe+Decken, Nachtrag */
  --ph-ink: #14120e;
}
[data-phase="a"] { --ph: var(--ph-a); } [data-phase="b"] { --ph: var(--ph-b); } [data-phase="c"] { --ph: var(--ph-c); }
[data-phase="d"] { --ph: var(--ph-d); } [data-phase="e"] { --ph: var(--ph-e); }

/* ─── Wochenraster ─── */
.ph-takt { display: grid; grid-template-columns: 3.4em repeat(5, minmax(0, 1fr)); gap: 6px; margin-top: 8px; }
.ph-takt__wt { font-size: var(--rk-wow-fs-tag); color: var(--text-muted); text-align: center; letter-spacing: .06em; }
.ph-takt__kw { align-self: center; font-size: var(--rk-wow-fs-tag); color: var(--text-muted); }
.ph-takt__pause { grid-column: 1 / -1; text-align: center; padding: 6px; border: 1px dashed var(--rk-wow-line-strong); border-radius: var(--rk-wow-r-sm); font-size: var(--rk-wow-fs-tag); color: var(--text-muted); }
.ph-zelle { display: flex; flex-direction: column; justify-content: space-between; gap: 2px; min-height: 56px; padding: 8px 10px; border: 0; border-radius: var(--rk-wow-r-sm); background: var(--ph); color: var(--ph-ink); font: inherit; font-size: var(--rk-wow-fs-tag); text-align: left; cursor: pointer; transition: transform .25s var(--rk-wow-ease), box-shadow .25s var(--rk-wow-ease); }
.ph-zelle:hover { transform: translateY(-2px); box-shadow: var(--rk-wow-sh-2); }
.ph-zelle:focus-visible { outline: 3px solid var(--rk-focus-color, currentColor); outline-offset: 2px; }
.ph-zelle small { font-size: var(--rk-wow-fs-tag); opacity: .75; }
.ph-zelle.is-on { box-shadow: 0 0 0 3px var(--text-primary); }
.ph-zelle--leer { background: var(--rk-wow-tint); opacity: .5; cursor: default; pointer-events: none; }
.ph-legende { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 16px 0 0; padding: 0; list-style: none; font-size: var(--rk-wow-fs-tag); color: var(--text-secondary); }
.ph-legende i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 8px; background: var(--ph); vertical-align: -1px; }
@media (max-width: 599px) { .ph-takt { gap: 4px; grid-template-columns: 2.6em repeat(5, minmax(0, 1fr)); } .ph-zelle { padding: 6px; min-height: 52px; } .ph-zelle small { display: none; } }

/* ─── Wochenreiter (öffentliche Referenz) ─── */
.ph-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: clamp(22px, 3vw, 36px) 0 0; padding: 0; list-style: none; }
.ph-tab { font: inherit; min-height: 48px; padding: 0 20px; border: 1px solid var(--rk-wow-line-strong); border-radius: var(--rk-wow-r-pill, 999px); background: var(--rk-wow-card); color: var(--text-secondary); cursor: pointer; }
.ph-tab[aria-selected="true"] { background: var(--text-primary); color: var(--bg-primary, var(--rk-wow-card)); border-color: var(--text-primary); }
.ph-tab:focus-visible { outline: 3px solid var(--rk-focus-color, currentColor); outline-offset: 2px; }
.ph-panel { margin-top: clamp(20px, 3vw, 32px); display: grid; gap: clamp(20px, 3vw, 36px); padding: clamp(20px, 3.4vw, 40px); border: 1px solid var(--rk-wow-line); border-top: 4px solid var(--ph, var(--rk-wow-line-strong)); border-radius: var(--rk-wow-r-card); background: var(--rk-wow-card); box-shadow: var(--rk-wow-sh-2); }
.ph-panel[hidden] { display: none; }
.ph-panel h3 { margin: 4px 0 12px; font-size: var(--rk-wow-fs-big); line-height: 1.12; font-weight: var(--rk-fw-regular, 400); letter-spacing: var(--rk-wow-ls-tight); color: var(--text-primary); }
.ph-panel p { max-width: 62ch; margin: 0 0 1em; color: var(--text-secondary); line-height: 1.6; }
.ph-panel__nr { margin: 0; font-size: var(--rk-wow-fs-tag); letter-spacing: .14em; text-transform: uppercase; color: var(--rk-gold-text); }
.ph-fakten { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.ph-fakten li { padding: 6px 12px; border: 1px solid var(--rk-wow-line-strong); border-radius: var(--rk-wow-r-pill, 999px); font-size: var(--rk-wow-fs-tag); color: var(--text-secondary); }
.ph-tage { margin: 0; padding: 0; list-style: none; display: grid; gap: 0; }
.ph-tage li { display: grid; grid-template-columns: 5.2em minmax(0, 1fr); gap: 12px; padding: 12px 0; border-top: 1px solid var(--rk-wow-line); color: var(--text-secondary); line-height: 1.45; }
.ph-tage li:first-child { border-top: 0; }
.ph-tage b { font-weight: var(--rk-fw-regular, 400); color: var(--text-primary); font-variant-numeric: tabular-nums; }
.ph-tage small { display: block; color: var(--text-muted); }
.ph-paar { display: grid; grid-template-columns: 1fr 1fr; gap: 0; height: 100%; }
.ph-paar figure { position: relative; margin: 0; overflow: hidden; }
.ph-paar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ph-paar figcaption { position: absolute; left: 10px; top: 10px; padding: 4px 12px; border-radius: var(--rk-wow-r-pill, 999px); background: var(--rk-wow-dark-bg); color: var(--rk-wow-dark-text); font-size: var(--rk-wow-fs-tag); letter-spacing: .06em; }

/* ─── Nachweis: Wochen aufklappbar ─── */
.ph-woche { margin-top: 14px; border: 1px solid var(--rk-wow-line); border-radius: var(--rk-wow-r-md); background: var(--rk-wow-card); box-shadow: var(--rk-wow-sh-1); }
.ph-woche > summary { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; padding: 18px 22px; cursor: pointer; list-style: none; min-height: 48px; }
.ph-woche > summary::-webkit-details-marker { display: none; }
.ph-woche > summary:focus-visible { outline: 3px solid var(--rk-focus-color, currentColor); outline-offset: 2px; }
.ph-woche__titel { font-size: var(--rk-wow-fs-title); color: var(--text-primary); }
.ph-woche__summe { font-size: var(--rk-wow-fs-meta); color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.ph-woche[open] > summary { border-bottom: 1px solid var(--rk-wow-line); }
.ph-woche__inhalt { padding: 6px clamp(14px, 2.4vw, 26px) 22px; }
.ph-woche .nw-tag { box-shadow: none; }
.ph-mini { width: 100%; border-collapse: collapse; font-size: var(--rk-wow-fs-meta); margin: 6px 0 0; }
.ph-mini th, .ph-mini td { padding: 6px 8px; text-align: left; border-bottom: 1px solid var(--rk-wow-line); color: var(--text-secondary); vertical-align: top; }
.ph-mini th { font-size: var(--rk-wow-fs-tag); letter-spacing: .08em; text-transform: uppercase; color: var(--rk-gold-text); font-weight: var(--rk-fw-regular, 400); }
.ph-mini .nw-r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ph-zusatz { margin: 12px 0 0; padding: 10px 14px; color: var(--text-secondary); font-size: var(--rk-wow-fs-meta); }
.ph-einheit { color: var(--text-muted); font-size: var(--rk-wow-fs-tag); }

/* ─── Bautagebuch-Blatt (Download/Druck) ─── */
.ph-bt > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; cursor: pointer; list-style: none; min-height: 48px; }
.ph-bt { border: 1px solid var(--rk-wow-line); border-radius: var(--rk-wow-r-card); background: var(--rk-wow-card); box-shadow: var(--rk-wow-sh-2); }
.ph-bt > summary::-webkit-details-marker { display: none; }
.ph-bt__inhalt { padding: 0 clamp(14px, 3vw, 32px) 28px; }
.ph-blatt { margin-top: 22px; padding: clamp(14px, 2.4vw, 24px); border: 1px solid var(--rk-wow-line-strong); border-radius: var(--rk-wow-r-sm); break-inside: avoid; }
.ph-blatt__kopf { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-bottom: 10px; margin-bottom: 10px; border-bottom: 2px solid var(--text-primary); }
.ph-blatt__kopf h4 { margin: 0; font-weight: var(--rk-fw-regular, 400); font-size: var(--rk-wow-fs-title); color: var(--text-primary); }
.ph-blatt p { margin: 0; color: var(--text-secondary); font-size: var(--rk-wow-fs-meta); }

@media print {
  html.ph-druck-bt .ph-nicht-bt, html.ph-druck-bt header, html.ph-druck-bt footer, html.ph-druck-bt .ph-bt > summary { display: none !important; }
  html.ph-druck-bt .ph-bt, html.ph-druck-bt .ph-bt__inhalt { border: 0; box-shadow: none; padding: 0; }
}

/* ─── Stundenband (Aufwand je Schritt) ─── */
.ph-band { display: flex; gap: 8px; margin: 0; padding: 0; list-style: none; align-items: stretch; }
.ph-band > li { flex: var(--h) 1 0; min-width: 118px; }
.ph-band__seg { position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; width: 100%; height: clamp(190px, 26vw, 300px); padding: 14px; overflow: hidden; text-align: left; border: 0; border-radius: var(--rk-wow-r-md); color: var(--rk-wow-dark-text); background: var(--ph); cursor: pointer; font: inherit; transition: transform .3s var(--rk-wow-ease), box-shadow .3s var(--rk-wow-ease); }
.ph-band__seg > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph-band__seg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, color-mix(in srgb, var(--rk-wow-dark-bg) 88%, transparent) 0%, color-mix(in srgb, var(--rk-wow-dark-bg) 70%, transparent) 38%, color-mix(in srgb, var(--ph) 38%, transparent) 100%); }
.ph-band__seg > span { position: relative; z-index: 1; }
.ph-band__zahl { font-size: var(--rk-wow-fs-big); line-height: 1; letter-spacing: var(--rk-wow-ls-tight); text-shadow: 0 1px 12px color-mix(in srgb, var(--rk-wow-dark-bg) 80%, transparent); }
.ph-band__name { font-size: var(--rk-wow-fs-tag); }
.ph-band__seg:hover { transform: translateY(-3px); box-shadow: var(--rk-wow-sh-3); }
.ph-band__seg:focus-visible { outline: 3px solid var(--rk-focus-color, currentColor); outline-offset: 2px; }
@media (max-width: 899px) { .ph-band { flex-direction: column; } .ph-band > li { flex: none; min-width: 0; width: max(52%, calc(var(--h) / 75 * 100%)); } .ph-band__seg { height: 92px; flex-direction: row; align-items: center; justify-content: space-between; } .ph-band__zahl { font-size: var(--rk-wow-fs-title); } }

/* ─── Fotostrecke im Kapitel ─── */
.ph-galerie { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .ph-galerie { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .ph-galerie { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.ph-galerie .nw-medium__knopf img { aspect-ratio: 3 / 4; }
.ph-panel__text { max-width: 70ch; }

/* ─── Verlauf-Schieber ─── */
.ph-verlauf__orte { justify-content: center; }
.ph-verlauf { margin-top: clamp(20px, 3vw, 32px); display: grid; justify-items: center; }
.ph-verlauf__ort { width: min(100%, 560px); display: grid; gap: 14px; }
.ph-verlauf__ort[hidden] { display: none; }
.ph-verlauf__fig { position: relative; margin: 0; aspect-ratio: 3 / 4; overflow: hidden; border: 1px solid var(--rk-wow-line); border-radius: var(--rk-wow-r-card); background: var(--rk-wow-tint); box-shadow: var(--rk-wow-sh-3); }
.ph-verlauf__bild { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .45s var(--rk-wow-ease); }
.ph-verlauf__bild.is-on { opacity: 1; }
.ph-verlauf__stufe { position: absolute; left: 12px; bottom: 12px; padding: 6px 14px; border-radius: var(--rk-wow-r-pill, 999px); background: var(--rk-wow-dark-bg); color: var(--rk-wow-dark-text); font-size: var(--rk-wow-fs-meta); }
.ph-verlauf__regler input { width: 100%; min-height: 48px; accent-color: var(--rk-wow-hl-solid); cursor: pointer; }
.ph-verlauf__skala { display: flex; justify-content: space-between; margin: -8px 0 0; font-size: var(--rk-wow-fs-tag); letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
@media (prefers-reduced-motion: reduce) { .ph-verlauf__bild, .ph-band__seg, .ph-zelle { transition: none; } }

/* ─── Farbpunkt statt Seitenrand ─── */
.ph-punkt { display: inline-block; width: 10px; height: 10px; margin-right: 10px; border-radius: 50%; background: var(--ph, currentColor); vertical-align: middle; }
.ph-punkt[data-phase="a"], [data-phase="a"] { --ph: var(--ph-a); } .ph-punkt[data-phase="b"], [data-phase="b"] { --ph: var(--ph-b); }
.ph-punkt[data-phase="c"], [data-phase="c"] { --ph: var(--ph-c); } .ph-punkt[data-phase="d"], [data-phase="d"] { --ph: var(--ph-d); } .ph-punkt[data-phase="e"], [data-phase="e"] { --ph: var(--ph-e); }

/* ─── Schritte: nummerierte Leiste links, Inhalt rechts (statt Pillen) ─── */
.ph-ent { display: grid; gap: clamp(20px, 3vw, 36px); margin-top: clamp(20px, 3vw, 32px); }
@media (min-width: 900px) { .ph-ent { grid-template-columns: 260px minmax(0, 1fr); align-items: start; } .ph-schritte { position: sticky; top: 96px; } }
.ph-schritte { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
@media (max-width: 899px) { .ph-schritte { grid-auto-flow: column; grid-auto-columns: minmax(150px, 1fr); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; } .ph-schritte > li { scroll-snap-align: start; } }
.ph-schritt { display: flex; gap: 12px; align-items: baseline; width: 100%; min-height: 56px; padding: 12px 14px; text-align: left; border: 0; border-bottom: 1px solid var(--rk-wow-line); background: transparent; color: var(--text-secondary); font: inherit; cursor: pointer; transition: color .25s var(--rk-wow-ease), background .25s var(--rk-wow-ease); }
.ph-schritt__nr { font-size: var(--rk-wow-fs-tag); letter-spacing: .12em; color: var(--rk-gold-text); }
.ph-schritt__txt { display: grid; gap: 2px; } .ph-schritt__txt b { font-weight: inherit; } .ph-schritt__txt small { font-size: var(--rk-wow-fs-tag); color: var(--text-muted); }
.ph-schritt[aria-selected="true"] { color: var(--text-primary); background: var(--rk-wow-tint); }
.ph-schritt:focus-visible { outline: 3px solid var(--rk-focus-color, currentColor); outline-offset: 2px; }
.ph-ent__inhalt .ph-panel { margin-top: 0; padding: 0; border: 0; background: transparent; box-shadow: none; }
.ph-mat { font-size: var(--rk-wow-fs-meta); color: var(--text-muted); }

/* ─── Orte im Verlauf: Bildkacheln ─── */
.ph-orte { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0; padding: 0; list-style: none; }
.ph-ort { display: grid; gap: 6px; width: 120px; padding: 6px; border: 1px solid var(--rk-wow-line); border-radius: var(--rk-wow-r-md); background: transparent; color: var(--text-secondary); font: inherit; font-size: var(--rk-wow-fs-tag); cursor: pointer; text-align: left; }
.ph-ort img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: calc(var(--rk-wow-r-md) - 4px); }
.ph-ort[aria-selected="true"] { border-color: var(--rk-gold-text); color: var(--text-primary); }

/* ─── Schäden und Material ─── */
.ph-schaeden { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; margin: clamp(20px, 3vw, 32px) 0 0; padding: 0; list-style: none; }
.ph-schaeden figure { margin: 0 0 12px; aspect-ratio: 4 / 3; overflow: hidden; border-radius: var(--rk-wow-r-md); } .ph-schaeden img { width: 100%; height: 100%; object-fit: cover; }
.ph-schaeden h3 { margin: 0 0 6px; font-size: var(--rk-wow-fs-card, 1.125rem); } .ph-schaeden p { margin: 0; color: var(--text-secondary); font-size: var(--rk-wow-fs-meta); }
.ph-mat-liste { display: grid; gap: 0; max-width: 560px; margin: clamp(16px, 2vw, 24px) 0 0; padding: 0; list-style: none; }
.ph-mat-liste li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--rk-wow-line); }

/* ─── Wechselnde Ausrichtung der Abschnittsköpfe (links/Mitte/rechts) ─── */
.ph-pos-r { text-align: right; margin-left: auto; }
.ph-pos-r .rk-wow-statement__sub, .ph-pos-r .rk-wow-statement__title { margin-left: auto; }
.ph-pos-r .rk-wow-kicker { justify-content: flex-end; }
.ph-pos-m .rk-wow-statement__sub { margin-inline: auto; }
.ph-schaeden { justify-content: center; }
.ph-pos-m + .ph-schaeden, .ph-pos-m ~ ul.ph-schaeden { text-align: center; }

/* ─── Zweispalter: Text links, Steckbrief rechts bleibt stehen ─── */
.ph-zweispalt { display: grid; gap: clamp(24px, 4vw, 56px); }
@media (min-width: 960px) { .ph-zweispalt { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; } .ph-steckbrief { position: sticky; top: 96px; } }
.ph-zweispalt .ph-schaeden { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

/* ─── Hero: Vergleichsregler ─── */
.ph-hero-vergleich { margin: 0; aspect-ratio: 3 / 4; max-height: min(78vh, 760px); width: 100%; justify-self: end; }
.ph-hero-vergleich .rk-wow-vergleich { height: 100%; }

/* ─── Karten leicht erhaben (Kai 10.10.2026: nicht zu flach im Dunkelmodus) ─── */
.ref-steckbrief, .ref-stufe, .nw-tag, .ph-woche, .ph-bt, .ph-schaeden figure, .ph-galerie .nw-medium__knopf, .ph-ort, .ph-schritt[aria-selected="true"] { box-shadow: var(--ph-erhaben); }
.ph-band__seg { box-shadow: var(--ph-erhaben); }

/* Autor und Datum im Einstieg (sichtbar, gleich wie in den strukturierten Daten) */
.ref-autor { margin: 10px 0 0; color: var(--text-secondary); font-size: var(--rk-wow-fs-meta); }
.ref-autor__datum { white-space: nowrap; }
