/* ==========================================================
   Eigene Ding Film Studios
   Leitidee: das Werkprint. Eine Filmspule läuft als Perforation
   den linken Rand entlang; Abschnitte hängen daran wie Einstellungen
   in einem Schnittprotokoll. Ruhig, archivarisch, kein Studio-Glanz.
   ========================================================== */

:root {
  --ink:      #17160f;
  --ink-2:    #201f18;
  --paper:    #ece7db;
  --paper-2:  #b9b3a2;
  --rust:     #b8532e;
  --ochre:    #c9a25a;
  --line:     rgba(236, 231, 219, 0.14);
  --line-strong: rgba(236, 231, 219, 0.28);

  --sprocket: 84px;      /* Abstand der Perforationslöcher */
  --rail: 34px;           /* Abstand der Spurlinie vom Rand */

  /* Bewusst nur Systemschriften — keine Schrift von fremden Servern,
     genau wie shiitake-film.eu und atopics-film.eu. Das ist auch das,
     was die CSP in _headers erzwingt (font-src 'self'). */
  --font-display: ui-serif, 'Iowan Old Style', Charter, Georgia, Cambria, 'Times New Roman', serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, system-ui, sans-serif;
  --font-mono: ui-monospace, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
a:not(.btn):not(.reelcard):not(.navlink) { text-decoration-color: var(--rust); text-underline-offset: 3px; }

::selection { background: var(--rust); color: var(--paper); }

:focus-visible {
  outline: 2px solid var(--ochre);
  outline-offset: 3px;
}

img { max-width: 100%; display: block; }

.wrap {
  max-width: 74rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ---------- Sprungmarke für Tastatur und Screenreader ---------- */

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--rust);
  color: var(--paper);
  padding: 0.6rem 1rem;
  font-weight: 600;
  z-index: 99;
}
.skip:focus { left: 0; }

/* ---------- Typografische Rollen ---------------------------- */

.display {
  font-family: var(--font-display);
  font-optical-sizing: auto;
  font-weight: 480;
  letter-spacing: -0.01em;
  line-height: 1.04;
}

.tc {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  color: var(--paper-2);
  font-variant-numeric: tabular-nums;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--ochre);
  letter-spacing: 0.02em;
}

/* ---------- Kopfzeile ----------------------------------------- */

header.top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(23, 22, 15, 0.86);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
  gap: 1.5rem;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 560;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-decoration: none;
}

.wordmark .ding { color: var(--rust); font-style: italic; }

nav.primary {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  flex-wrap: wrap;
}

.navlink {
  font-size: 0.9rem;
  text-decoration: none;
  color: var(--paper-2);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: color 150ms ease, border-color 150ms ease;
}
.navlink:hover { color: var(--paper); border-color: var(--rust); }

#lang-toggle {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  background: none;
  border: 1px solid var(--line-strong);
  color: var(--paper);
  padding: 0.32rem 0.6rem;
  cursor: pointer;
  letter-spacing: 0.04em;
}
#lang-toggle:hover { border-color: var(--rust); color: var(--rust); }

/* ---------- Sprocket-Spur -------------------------------------- */

.reel {
  position: relative;
  padding-left: calc(var(--rail) + 2.2rem);
}

.reel::before {
  content: '';
  position: absolute;
  left: var(--rail);
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--line-strong);
}

.reel::after {
  content: '';
  position: absolute;
  left: calc(var(--rail) - 6px);
  top: 0;
  bottom: 0;
  width: 13px;
  background-image: repeating-linear-gradient(
    to bottom,
    var(--paper-2) 0 8px,
    transparent 8px var(--sprocket)
  );
  -webkit-mask-image: repeating-radial-gradient(circle at 6.5px 4px, #000 0 3.4px, transparent 3.5px 100%);
  mask-image: repeating-radial-gradient(circle at 6.5px 4px, #000 0 3.4px, transparent 3.5px 100%);
  opacity: 0.55;
}

.frame-mark {
  position: absolute;
  left: calc(var(--rail) - 3px);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--rust);
  margin-top: 0.5rem;
}

/* ---------- Hero ------------------------------------------------- */

.hero {
  padding: 5.5rem 0 4.5rem;
}

.hero .eyebrow { display: block; margin-bottom: 1.1rem; }

.hero h1 {
  margin: 0;
  font-size: clamp(3rem, 9vw, 6.4rem);
}

.hero .broken {
  display: block;
  color: var(--paper-2);
  font-style: italic;
  font-size: 0.34em;
  margin-top: 0.6rem;
  letter-spacing: 0;
}

.hero p.lede {
  max-width: 34rem;
  margin: 1.8rem 0 0;
  font-size: 1.15rem;
  color: var(--paper-2);
}

.hero .roll {
  margin-top: 2.6rem;
  display: flex;
  gap: 2.4rem;
  flex-wrap: wrap;
}
.hero .roll a {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--paper);
  border-bottom: 1px solid var(--rust);
  padding-bottom: 3px;
}

/* ---------- Sektionen --------------------------------------------- */

section { padding: 4.5rem 0; border-top: 1px solid var(--line); }
section:first-of-type { border-top: none; }

.section-head {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 1.5rem;
  align-items: baseline;
  margin-bottom: 2.4rem;
}
.section-head .num {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--ochre);
}
.section-head h2 { margin: 0; font-size: clamp(1.7rem, 4vw, 2.4rem); }
.section-head .sub { margin: 0.4rem 0 0; color: var(--paper-2); font-size: 0.98rem; max-width: 38rem; }

/* ---------- Manifest / Philosophie ---------------------------------- */

.manifest {
  max-width: 42rem;
}
.manifest p { color: var(--paper); font-size: 1.04rem; }
.manifest .pull {
  font-family: var(--font-display);
  font-weight: 460;
  font-style: italic;
  font-size: 1.5rem;
  line-height: 1.4;
  color: var(--ochre);
  border-left: 2px solid var(--rust);
  padding-left: 1.3rem;
  margin: 2rem 0;
}
.manifest .origin-note {
  margin-top: 2rem;
  font-size: 0.88rem;
  color: var(--paper-2);
}

/* ---------- Aktuelle Produktion --------------------------------- */

.current {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: start;
}
.current .status {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--rust);
  display: block;
  margin-bottom: 0.9rem;
}
.current h3 { font-size: clamp(1.6rem, 3.4vw, 2.1rem); margin: 0 0 0.6rem; }
.current .kind { color: var(--ochre); font-size: 0.95rem; margin: 0 0 1.1rem; }
.current p { color: var(--paper-2); max-width: 34rem; }
.current .slate {
  border: 1px solid var(--line-strong);
  padding: 1.6rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--paper-2);
  line-height: 2;
}
.current .slate b { color: var(--paper); font-weight: 500; }

/* ---------- Sparten ------------------------------------------------ */

.sparten-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
}

.reelcard {
  display: block;
  text-decoration: none;
  border: 1px solid var(--line-strong);
  padding: 2rem;
  position: relative;
  transition: border-color 180ms ease, transform 180ms ease;
}
.reelcard:hover { border-color: var(--rust); transform: translateY(-2px); }

.reelcard .tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--rust);
  letter-spacing: 0.03em;
}
.reelcard h3 {
  font-family: var(--font-display);
  font-weight: 520;
  font-size: 1.7rem;
  margin: 0.6rem 0 0.7rem;
}
.reelcard p { color: var(--paper-2); font-size: 0.95rem; margin: 0 0 1.2rem; }
.reelcard .go {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--paper);
  border-top: 1px solid var(--line);
  padding-top: 0.9rem;
  display: flex;
  justify-content: space-between;
}

/* ---------- Werkschau (Filmografie) --------------------------------- */

.filmo-group { margin-bottom: 3rem; }
.filmo-group h3 {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--ochre);
  text-transform: none;
  margin: 0 0 1.2rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--line);
}

.filmo-row {
  display: grid;
  grid-template-columns: 5.5rem 1fr auto;
  gap: 1.2rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
}
.filmo-group .filmo-row:first-of-type { border-top: none; }

.filmo-row .yr { font-family: var(--font-mono); font-size: 0.82rem; color: var(--paper-2); }
.filmo-row .title { font-size: 1.02rem; }
.filmo-row .kind { color: var(--paper-2); font-size: 0.88rem; margin-left: 0.5rem; }
.filmo-row .role { font-size: 0.85rem; color: var(--ochre); text-align: right; white-space: nowrap; }

/* ---------- Werdegang -------------------------------------------- */

.werdegang-lede { max-width: 40rem; color: var(--paper-2); margin-bottom: 2.6rem; }

.wd-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.wd-list h4 {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--ochre);
  margin: 0 0 1rem;
}
.wd-item { padding: 0.85rem 0; border-top: 1px solid var(--line); }
.wd-list .wd-item:first-of-type { border-top: none; }
.wd-item .yr { font-family: var(--font-mono); font-size: 0.78rem; color: var(--paper-2); display: block; margin-bottom: 0.2rem; }
.wd-item b { font-weight: 560; }
.wd-item .role { color: var(--paper-2); font-size: 0.92rem; }

.tools-block { margin-top: 2.6rem; }
.tools-block h4 { font-family: var(--font-mono); font-size: 0.78rem; color: var(--ochre); margin: 0 0 0.9rem; }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.55rem; }
.chip {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  border: 1px solid var(--line-strong);
  padding: 0.35rem 0.7rem;
  color: var(--paper-2);
}

.own-tools {
  margin-top: 2.6rem;
  border-left: 2px solid var(--ochre);
  padding-left: 1.3rem;
  max-width: 38rem;
  color: var(--paper-2);
  font-size: 0.95rem;
}
.own-tools a { color: var(--ochre); }

/* ---------- Kooperationen ------------------------------------------ */

.kooperationen-note { color: var(--paper-2); font-size: 0.88rem; max-width: 36rem; margin-bottom: 1.8rem; }
.koop-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem 1rem;
}
.koop-chip {
  font-size: 0.86rem;
  color: var(--paper-2);
  border: 1px solid var(--line);
  padding: 0.4rem 0.85rem;
}

/* ---------- Kontakt ----------------------------------------------- */

.contact-block h2 { font-size: clamp(1.9rem, 4.4vw, 2.7rem); max-width: 26rem; margin: 0 0 1.6rem; }
.contact-block .mail {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  color: var(--rust);
  text-decoration: none;
}
.social-row { margin-top: 2rem; display: flex; gap: 1.6rem; flex-wrap: wrap; }
.social-row a { font-size: 0.9rem; color: var(--paper-2); text-decoration: none; border-bottom: 1px solid var(--line-strong); }
.social-row a:hover { color: var(--rust); border-color: var(--rust); }

/* ---------- Rechtsseiten und 404 ------------------------------------
   Eigener, ruhiger Satzspiegel: schmaler als der Rest der Seite, damit
   die langen Rechtstexte lesbare Zeilen behalten. */

.legal {
  max-width: 46rem;
  margin: 0 auto;
  padding: 4rem 1.5rem 5rem;
}
.legal h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0 0 2rem;
}
.legal h2 { font-size: 1.05rem; font-weight: 600; margin: 2.5rem 0 0.6rem; }
.legal p, .legal address { margin: 0 0 1em; color: var(--paper-2); line-height: 1.75; font-style: normal; }
.legal a { color: var(--paper); }

/* Hinweiskasten für den Betreiber. Wird von build.sh vor dem
   Hochladen entfernt und ist deshalb nie öffentlich zu sehen. */
.todo {
  display: block;
  margin: 1.5rem 0;
  padding: 1rem 1.2rem;
  border-left: 3px solid var(--rust);
  background: var(--ink-2);
  color: var(--paper) !important;
  font-size: 0.92rem;
  line-height: 1.7;
}
.todo strong { color: var(--rust); }

/* ---------- Footer -------------------------------------------------- */

footer {
  border-top: 1px solid var(--line);
  padding: 2.4rem 0 3.5rem;
  color: var(--paper-2);
  font-size: 0.82rem;
}
footer .wrap {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
footer a { color: var(--paper-2); text-decoration: none; }
footer a:hover { color: var(--rust); }
footer .flinks { display: flex; gap: 1.4rem; }

/* ---------- Sprachumschaltung ----------------------------------------
   Gleiche Mechanik wie shiitake-film.eu und atopics-film.eu: js/main.js
   setzt .lang-de bzw. .lang-en auf <html>, diese eine Regel blendet die
   jeweils andere Sprache aus.

   Wichtig für die Pflege: die Klassen "de"/"en" gehören IMMER auf ein
   eigenes <span> INNERHALB des gestalteten Elements, nie auf das
   gestaltete Element selbst. Sonst kann eine Komponentenregel mit
   display (etwa .hero .eyebrow) diese Regel überstimmen und beide
   Sprachen stehen gleichzeitig da. ------------------------------------ */

.lang-de .en, .lang-en .de { display: none; }

/* ---------- Responsiv -------------------------------------------------- */

@media (max-width: 56rem) {
  .current { grid-template-columns: 1fr; }
  .sparten-grid { grid-template-columns: 1fr; }
  .wd-grid { grid-template-columns: 1fr; gap: 2rem; }
  nav.primary { display: none; }
}

@media (max-width: 40rem) {
  :root { --rail: 12px; }
  .reel { padding-left: 2.4rem; }
  .section-head { grid-template-columns: 1fr; gap: 0.4rem; }
  .filmo-row { grid-template-columns: 1fr; gap: 0.2rem; }
  .filmo-row .role { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
