/* dokuschnitt.de — gemeinsames Stylesheet
   Motiv: Schnittplatz. Timecodes in Monospace, Spuren als Linien,
   warmer Bernsteinakzent auf kuehlem Grau. */

@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Inter:wght@300;400;500;600;700&display=swap');

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

:root {
  color-scheme: dark;
  --bg:           #0a0c10;
  --bg-deep:      #06080b;
  --surface:      #11151b;
  --surface-2:    #161b23;
  --surface-hover:#1b212a;
  --border:       rgba(198, 176, 142, .14);
  --border-strong:rgba(198, 176, 142, .28);
  --text:         #e9e6df;
  --text-soft:    #b3aea3;
  --muted:        #7b766d;
  --amber:        #e0a45c;
  --amber-soft:   rgba(224, 164, 92, .12);
  --amber-line:   rgba(224, 164, 92, .35);
  --slate:        #7fa3b5;
  --slate-soft:   rgba(127, 163, 181, .12);
  --rose:         #d98a7e;
  --green:        #86b08a;
  --shadow:       0 22px 60px rgba(0, 0, 0, .42);
  --radius:       14px;
  --track:        rgba(198, 176, 142, .055);
}

html[data-theme="light"] {
  color-scheme: light;
  --bg:           #f4f1ea;
  --bg-deep:      #ece8df;
  --surface:      #ffffff;
  --surface-2:    #faf7f1;
  --surface-hover:#f3efe6;
  --border:       rgba(60, 48, 30, .13);
  --border-strong:rgba(60, 48, 30, .26);
  --text:         #1d1c19;
  --text-soft:    #4d4a43;
  --muted:        #7a746a;
  --amber:        #a86a1c;
  --amber-soft:   rgba(168, 106, 28, .09);
  --amber-line:   rgba(168, 106, 28, .30);
  --slate:        #3f6b80;
  --slate-soft:   rgba(63, 107, 128, .09);
  --rose:         #a8544a;
  --green:        #4a7350;
  --shadow:       0 18px 44px rgba(60, 48, 30, .10);
  --track:        rgba(60, 48, 30, .042);
}

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

/* Feine horizontale Spurlinien - der Schnittplatz im Hintergrund. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: repeating-linear-gradient(
    to bottom,
    var(--track) 0, var(--track) 1px,
    transparent 1px, transparent 124px
  );
  pointer-events: none;
  z-index: 0;
}

main { position: relative; z-index: 1; flex: 1; }

a { color: inherit; }
button, input, textarea, select { font: inherit; }
img, svg { max-width: 100%; }

.shell { width: min(1080px, calc(100% - 44px)); margin-inline: auto; }
.shell--narrow { width: min(780px, calc(100% - 44px)); }

.mono {
  font-family: 'DM Mono', ui-monospace, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

/* Kopfzeile */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.topbar-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 62px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: -.01em;
  white-space: nowrap;
}
.brand svg { width: 26px; height: 26px; flex: none; }
.brand-name { font-size: 1.02rem; }
.brand-dot { color: var(--amber); }

.topnav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}
.topnav a {
  padding: 7px 11px;
  border-radius: 8px;
  font-size: .88rem;
  color: var(--text-soft);
  text-decoration: none;
  transition: background .16s, color .16s;
}
.topnav a:hover { background: var(--surface-hover); color: var(--text); }
.topnav a[aria-current="page"] { color: var(--amber); background: var(--amber-soft); }

.theme-toggle {
  flex: none;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
  transition: background .16s, color .16s, border-color .16s;
}
.theme-toggle:hover { background: var(--surface-hover); color: var(--text); border-color: var(--border-strong); }

/* Textbausteine */
.kicker {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 0 0 14px;
}

h1 {
  margin: 0 0 18px;
  font-size: clamp(2rem, 4.6vw, 3rem);
  font-weight: 300;
  line-height: 1.14;
  letter-spacing: -.025em;
}
h2 {
  margin: 0 0 16px;
  font-size: clamp(1.35rem, 2.6vw, 1.75rem);
  font-weight: 500;
  line-height: 1.24;
  letter-spacing: -.018em;
}
h3 {
  margin: 0 0 10px;
  font-size: 1.03rem;
  font-weight: 600;
  letter-spacing: -.008em;
}
p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }

.lead { font-size: 1.1rem; color: var(--text-soft); }
.muted { color: var(--muted); }
.soft { color: var(--text-soft); }
.small { font-size: .9rem; }

section { padding: 68px 0; }
section + section { border-top: 1px solid var(--border); }

.section-head { max-width: 660px; margin-bottom: 34px; }

/* Hero */
.hero { padding: 84px 0 64px; }
.hero h1 { max-width: 17ch; }
.hero .lead { max-width: 58ch; }

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 26px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: .8rem;
  color: var(--text-soft);
}
.chip::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--amber);
  flex: none;
}
.chip--slate::before { background: var(--slate); }

/* Knoepfe */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  font-size: .92rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background .16s, border-color .16s, transform .16s;
}
.btn:hover { background: var(--surface-hover); border-color: var(--amber-line); transform: translateY(-1px); }
.btn--primary {
  background: var(--amber-soft);
  border-color: var(--amber-line);
  color: var(--amber);
}
.btn--primary:hover { background: var(--amber-soft); border-color: var(--amber); }

/* Karten */
.grid { display: grid; gap: 18px; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.card {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color .18s, background .18s, transform .18s;
}
.card:hover { border-color: var(--border-strong); background: var(--surface-2); }

.card-num {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .74rem;
  letter-spacing: .12em;
  color: var(--amber);
  margin-bottom: 12px;
  display: block;
}
.card p { font-size: .94rem; color: var(--text-soft); }

a.card { text-decoration: none; display: block; }
a.card:hover { transform: translateY(-2px); }

/* Ablauf als Spur */
.track-list { list-style: none; margin: 0; padding: 0; }

.track-step {
  position: relative;
  padding: 0 0 30px 34px;
  border-left: 1px solid var(--border);
}
.track-step:last-child { padding-bottom: 0; border-left-color: transparent; }
.track-step::before {
  content: '';
  position: absolute;
  left: -5px; top: 6px;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--amber);
}
.track-step h3 { margin-bottom: 6px; }
.track-step p { font-size: .95rem; color: var(--text-soft); }

.track-tc {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .74rem;
  letter-spacing: .08em;
  color: var(--muted);
  display: block;
  margin-bottom: 4px;
}

/* Tabellen */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 11px 15px; text-align: left; vertical-align: top; }
thead th {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .74rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
tbody tr + tr td { border-top: 1px solid var(--border); }
tbody td:first-child { color: var(--text); font-weight: 500; }
tbody td { color: var(--text-soft); }
td.tc { font-family: 'DM Mono', ui-monospace, monospace; color: var(--amber); white-space: nowrap; }

/* Kennzahlen */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.stat { background: var(--surface); padding: 18px 20px; }
.stat-value {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: 1.5rem;
  color: var(--amber);
  line-height: 1.1;
  display: block;
}
.stat-label {
  font-size: .8rem;
  color: var(--muted);
  margin-top: 6px;
  display: block;
}

/* Hinweiskasten */
.note {
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-left: 2px solid var(--amber);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--surface);
  font-size: .94rem;
  color: var(--text-soft);
}
.note--slate { border-left-color: var(--slate); }
.note strong { color: var(--text); font-weight: 600; }

/* Listen */
.plain-list { list-style: none; margin: 0; padding: 0; }
.plain-list li {
  position: relative;
  padding: 0 0 10px 20px;
  font-size: .94rem;
  color: var(--text-soft);
}
.plain-list li::before {
  content: '';
  position: absolute;
  left: 2px; top: .62em;
  width: 6px; height: 1px;
  background: var(--amber);
}
.plain-list li:last-child { padding-bottom: 0; }

/* Beispiel-Szenenband */
.strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.strip-cell {
  background: var(--surface);
  padding: 13px 12px;
  min-height: 104px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.strip-id {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .7rem;
  letter-spacing: .06em;
  color: var(--muted);
}
.strip-kind { font-size: .76rem; font-weight: 600; }
.strip-kind--ai { color: var(--amber); }
.strip-kind--archive { color: var(--slate); }
.strip-dur {
  font-family: 'DM Mono', ui-monospace, monospace;
  font-size: .72rem;
  color: var(--text-soft);
  margin-top: auto;
}

/* Inline-Links im Flisstext */
.link {
  color: var(--amber);
  text-decoration: none;
  border-bottom: 1px solid var(--amber-line);
  transition: border-color .16s;
}
.link:hover { border-bottom-color: var(--amber); }

/* Fusszeile */
footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 34px 0;
  margin-top: 20px;
  background: var(--bg-deep);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 26px;
  align-items: center;
  font-size: .86rem;
  color: var(--muted);
}
.footer-inner a { color: var(--text-soft); text-decoration: none; }
.footer-inner a:hover { color: var(--amber); }
.footer-spacer { margin-left: auto; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .55s ease, transform .55s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }

/* Klein */
@media (max-width: 640px) {
  body { font-size: 15px; }
  section { padding: 52px 0; }
  .hero { padding: 60px 0 46px; }
  .topnav a { padding: 6px 8px; font-size: .84rem; }
  .brand-name { font-size: .95rem; }
}
