/* AI.Coding Club – Stylesheet. Farben aus Plakat und Folien. */
@font-face { font-family: "Oxanium"; src: url("../fonts/oxanium-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Oxanium"; src: url("../fonts/oxanium-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Oxanium"; src: url("../fonts/oxanium-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("../fonts/roboto-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("../fonts/roboto-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("../fonts/jetbrains-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --ink: #03243f;
  --muted: #566178;
  --line: #dde3ec;
  --paper: #ffffff;
  --wash: #f2f5f9;
  --orange: #f6a241;
  --orange-soft: #fff1df;
  --orange-ink: #8a4b00;
  --teal: #2e90a6;
  --link: #006e9e;
  --h2blue: #008ac4;
  --night: #020f18;
  --poster: #1d345e url("../img/bg-code.jpg") center / cover no-repeat;
  --display: "Oxanium", "Roboto", system-ui, sans-serif;
  --text: "Roboto", system-ui, -apple-system, "Segoe UI", sans-serif;
  --code: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  --measure: 68ch;
  --r-s: 6px;
  --r-m: 12px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.6 var(--text); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-underline-offset: 0.18em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.12; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; max-width: var(--measure); }
code, pre { font-family: var(--code); font-size: 0.9rem; }
.wrap { width: min(1120px, 100% - 2rem); margin-inline: auto; }
.muted { color: var(--muted); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 1rem; top: 1rem; background: var(--paper); padding: 0.5rem 1rem; z-index: 10; }

/* ------------------------------------------------ Kopf */
.site-head { border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 5; }
.site-head .wrap { display: flex; align-items: center; gap: 1.5rem; min-height: 64px; flex-wrap: wrap; }
.brand { font-family: var(--display); font-weight: 800; font-size: 1.3rem; color: var(--ink); text-decoration: none; letter-spacing: 0.01em; text-transform: uppercase; }
.nav { display: flex; gap: 0.25rem 1.1rem; flex-wrap: wrap; margin-left: auto; align-items: center; }
.nav a { color: var(--ink); text-decoration: none; padding: 0.35rem 0; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--orange); }
.h2logo { width: 64px; border-radius: 3px; }
@media (max-width: 760px) {
  .site-head { position: static; }
  .site-head .wrap { gap: 0.4rem 1rem; padding: 0.6rem 0 0.2rem; }
  .h2logo { order: 2; margin-left: auto; }
  .nav { order: 3; width: 100%; margin-left: 0; flex-wrap: nowrap; overflow-x: auto; gap: 1.1rem; padding-bottom: 0.35rem; }
  .nav a { white-space: nowrap; }
  .hero { background-position: 78% bottom; }
}

/* ------------------------------------------------ Buttons & Formulare */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; font: 700 1rem/1 var(--text); padding: 0.75rem 1.1rem;
  border-radius: var(--r-s); border: 2px solid var(--ink); background: var(--paper); color: var(--ink); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--wash); color: var(--ink); }
.btn.primary { background: var(--orange); border-color: var(--orange); color: var(--night); }
.btn.primary:hover { background: #ffb766; }
.btn.small { padding: 0.45rem 0.7rem; font-size: 0.9rem; border-width: 1.5px; }
.btn.quiet { border-color: var(--line); }
.actions { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
form.stack { display: grid; gap: 1rem; max-width: 720px; }
label { font-weight: 700; display: grid; gap: 0.35rem; }
label .hint { font-weight: 400; color: var(--muted); font-size: 0.92rem; }
input[type=text], input[type=url], textarea, select { font: inherit; font-weight: 400; padding: 0.65rem 0.75rem; border: 1.5px solid #b9c3d2;
  border-radius: var(--r-s); background: var(--paper); color: var(--ink); width: 100%; }
textarea { min-height: 9rem; resize: vertical; }
.check { display: flex; gap: 0.6rem; align-items: flex-start; font-weight: 400; }
.check input { margin-top: 0.3rem; width: 1.1rem; height: 1.1rem; }
.notice { background: var(--orange-soft); border-radius: var(--r-m); padding: 0.9rem 1.1rem; margin: 0 0 1.5rem; max-width: 760px; }

/* ------------------------------------------------ Hero (Plakat) */
/* Hintergrund = Original aus der Folienvorlage (Verlauf, Code-Zeilen, Schlange unten rechts) */
.hero { background: #1d345e url("../img/bg-schlange.jpg") right bottom / cover no-repeat; color: #fff; position: relative; overflow: hidden; }
.hero .wrap { position: relative; padding: clamp(2.5rem, 7vw, 4.75rem) 0 2.25rem; }
.hero h1 { font-weight: 800; text-transform: uppercase; font-size: clamp(2.9rem, 9.5vw, 6.6rem); line-height: 0.95; letter-spacing: 0.005em; margin: 0; }
.hero h1 span { display: block; }
.hero .rule { width: clamp(120px, 18vw, 210px); height: 6px; background: var(--orange); margin: 1.4rem 0 1.1rem; }
.hero .lead { font-size: clamp(1.3rem, 2.6vw, 1.85rem); font-weight: 400; max-width: 30ch; margin-bottom: 0.5em; }
.urlbox { display: inline-flex; align-items: center; gap: 0.55rem; background: var(--h2blue); color: #fff; font: 700 clamp(1.2rem, 2.2vw, 1.6rem)/1 var(--text);
  padding: 0.55rem 0.9rem; text-decoration: none; }
.urlbox:hover { color: #fff; background: #0079ad; }
.urlbox svg { width: 1.1em; height: 1.1em; }
.hero .when { opacity: 0.9; }
.hero .actions { margin-top: 1.5rem; }
.hero .btn:not(.primary) { background: transparent; color: #fff; border-color: rgba(255,255,255,0.75); }
.hero .btn:not(.primary):hover { background: rgba(255,255,255,0.12); }

/* ------------------------------------------------ Fahrplan als Build-Log (das Erkennungszeichen) */
.track { list-style: none; margin: 2.75rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); position: relative; max-width: 940px; }
.track::before { content: ""; position: absolute; left: 0; right: 0; top: 13px; height: 3px; background: rgba(255,255,255,0.28); }
.track li { position: relative; padding-right: 0.75rem; }
.track .dot { position: absolute; z-index: 1; top: 3px; left: 0; width: 23px; height: 23px; border-radius: 50%; background: #2a3a66; border: 3px solid rgba(255,255,255,0.55); }
.track .vorbei .dot { background: #fff; border-color: #fff; }
.track .vorbei::after { content: ""; position: absolute; left: 0; right: 0; top: 13px; height: 3px; background: #fff; }
.track .naechster .dot, .track .heute .dot { background: var(--orange); border-color: #fff; box-shadow: 0 0 0 6px rgba(246,162,65,0.35); }
.track a { color: #fff; text-decoration: none; display: block; padding-top: 2.1rem; }
.track a:hover .dot { box-shadow: 0 0 0 5px rgba(255,255,255,0.3); }
.track a:hover .t-title { text-decoration: underline; }
.track .t-meta { font: 400 0.82rem/1.3 var(--code); opacity: 0.85; }
.track .t-title { font-family: var(--display); font-weight: 700; font-size: 1.02rem; line-height: 1.2; margin-top: 0.2rem; }
.track .naechster .t-meta, .track .heute .t-meta { color: var(--orange); opacity: 1; }
@media (max-width: 760px) {
  .track { grid-template-columns: 1fr; gap: 0.9rem; }
  .track::before { left: 10px; right: auto; width: 3px; top: 0; bottom: 0; height: auto; }
  .track li { padding: 0; }
  .track a { padding: 0 0 0 2.4rem; }
  .track .dot { top: 0; }
  .track .vorbei::after { display: none; }
}

/* ------------------------------------------------ Abschnitte */
section.block { padding: clamp(2.25rem, 5vw, 3.5rem) 0; }
section.block.wash { background: var(--wash); }
.week { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: start; }
@media (max-width: 860px) { .week { grid-template-columns: 1fr; } }
.kicker { font-family: var(--code); font-size: 0.9rem; color: var(--muted); margin-bottom: 0.4rem; }
.message { font-family: var(--display); font-weight: 700; font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.02; margin: 0.2em 0 0.45em; }
.mission { background: var(--orange-soft); border-radius: var(--r-m); padding: 1.4rem 1.5rem; }
.mission h3 { margin-bottom: 0.35rem; }
.mission .mins { font-family: var(--code); font-size: 0.88rem; color: var(--orange-ink); }

/* ------------------------------------------------ Termin-Seite */
.termin-head { background: var(--poster); color: #fff; }
.termin-head h1 { font-weight: 800; }
.termin-head .wrap { padding: 2.5rem 0 2.25rem; }
.termin-head .kicker { color: rgba(255,255,255,0.85); }
.termin-head .message { color: var(--orange); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); }
@media (max-width: 860px) { .two { grid-template-columns: 1fr; } }
ol.steps { margin: 0; padding-left: 1.3rem; }
ol.steps li { margin-bottom: 0.45rem; }
.materials { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.materials a { display: flex; justify-content: space-between; gap: 1rem; align-items: center; border: 1.5px solid var(--line);
  border-radius: var(--r-s); padding: 0.8rem 1rem; color: var(--ink); text-decoration: none; font-weight: 700; }
.materials a:hover { border-color: var(--ink); }
.materials .kind { font-weight: 400; color: var(--muted); font-size: 0.9rem; white-space: nowrap; }
.pager { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2.5rem; flex-wrap: wrap; }

/* ------------------------------------------------ Snippets & Prompt-Karten */
.snippet { margin: 0 0 2.25rem; }
.snippet header { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.snippet h3 { margin: 0; }
.snippet p { margin: 0.25rem 0 0.7rem; color: var(--muted); }
pre.code { background: var(--night); color: #e7edf5; padding: 1rem 1.1rem; border-radius: var(--r-m); overflow-x: auto; line-height: 1.55; margin: 0; tab-size: 4; }
.copy[data-done]::after { content: " – kopiert"; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.card { border: 1.5px solid var(--line); border-radius: var(--r-m); padding: 1.1rem 1.2rem; display: flex; flex-direction: column; gap: 0.6rem; background: var(--paper); }
.card blockquote { margin: 0; font-weight: 700; white-space: pre-line; }
.card .when { color: var(--muted); font-size: 0.92rem; margin: 0; }
.card .btn { align-self: flex-start; margin-top: auto; }

/* ------------------------------------------------ Board */
.tabs { display: flex; gap: 0.4rem; flex-wrap: wrap; margin: 0 0 1.25rem; }
.tabs a { padding: 0.4rem 0.8rem; border-radius: 999px; border: 1.5px solid var(--line); color: var(--ink); text-decoration: none; font-size: 0.95rem; }
.tabs a[aria-current="page"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.posts { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.posts li { border-bottom: 1px solid var(--line); padding: 0.9rem 0; display: grid; grid-template-columns: 8.5rem 1fr auto; gap: 1rem; align-items: baseline; }
.posts .title { font-weight: 700; color: var(--ink); text-decoration: none; }
.posts .title:hover { text-decoration: underline; }
.posts .by { color: var(--muted); font-size: 0.92rem; }
@media (max-width: 640px) { .posts li { grid-template-columns: 1fr; gap: 0.2rem; } }
.tag { display: inline-block; font-size: 0.82rem; font-weight: 700; padding: 0.15rem 0.55rem; border-radius: 999px; white-space: nowrap; }
.tag.hilfe { background: #fde4e4; color: #8b1d1d; }
.tag.devlog { background: var(--orange-soft); color: var(--orange-ink); }
.tag.wissen { background: #dff1f4; color: #135565; }
.tag.solved { background: #e2f3e5; color: #1f6b2e; }
.tag.flag { background: var(--wash); color: var(--muted); }
article.post { max-width: 780px; }
article.post .body { margin: 1rem 0 1.5rem; }
article.post .body pre { background: var(--night); color: #e7edf5; padding: 0.9rem; border-radius: var(--r-s); overflow-x: auto; }
article.post img.shot { border-radius: var(--r-m); border: 1px solid var(--line); margin: 1rem 0; }
.comments { max-width: 780px; border-top: 1px solid var(--line); padding-top: 1.25rem; }
.comment { padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
.comment .by { color: var(--muted); font-size: 0.9rem; }
.comment.hidden { opacity: 0.5; }
.modbar { display: flex; gap: 0.5rem; flex-wrap: wrap; margin: 0.5rem 0 1rem; }
.modbar form { margin: 0; }

/* ------------------------------------------------ Devlogs, Teams, Galerie */
.feed { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.feed a { color: var(--ink); text-decoration: none; }
.feed figure { margin: 0; }
.feed img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; border-radius: var(--r-m); background: var(--wash); }
.feed figcaption { margin-top: 0.5rem; }
.feed .ph { aspect-ratio: 4 / 3; border-radius: var(--r-m); background: var(--poster); display: grid; place-items: center; color: #fff; font-family: var(--display); font-size: 1.4rem; padding: 1rem; text-align: center; }
.team-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 0 2rem; }
.team-list li { border-top: 2px solid var(--ink); padding: 0.9rem 0 1.4rem; }
.team-list h3 a { color: var(--ink); text-decoration: none; }
.team-list .kind { font-family: var(--code); font-size: 0.85rem; color: var(--teal); }
.empty { border: 1.5px dashed #b9c3d2; border-radius: var(--r-m); padding: 1.4rem; color: var(--muted); max-width: 760px; }
.tools { display: flex; flex-wrap: wrap; gap: 0.6rem; }
dl.facts { display: grid; grid-template-columns: 11rem 1fr; gap: 0.5rem 1rem; max-width: 780px; }
dl.facts dt { font-weight: 700; }
dl.facts dd { margin: 0; }
@media (max-width: 640px) { dl.facts { grid-template-columns: 1fr; } dl.facts dd { margin-bottom: 0.6rem; } }
table.mod { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
table.mod th, table.mod td { text-align: left; padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.table-scroll { overflow-x: auto; }

/* ------------------------------------------------ Fuß */
.site-foot { border-top: 1px solid var(--line); margin-top: 3rem; padding: 1.75rem 0 2.5rem; color: var(--muted); font-size: 0.95rem; }
.site-foot .wrap { display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; justify-content: space-between; }
.site-foot a { color: var(--muted); }

@media (prefers-reduced-motion: no-preference) {
  .track .naechster .dot, .track .heute .dot { animation: pulse 2.4s ease-in-out 1; }
  @keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(246,162,65,0.7); } 100% { box-shadow: 0 0 0 6px rgba(246,162,65,0.35); } }
}

/* ------------------------------------------------ Mach mit (Foto) */
.photo { margin: 0; }
.photo img { border-radius: var(--r-m); width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.photo figcaption { margin-top: 0.5rem; color: var(--muted); font-size: 0.95rem; }

/* ------------------------------------------------ Inhalte bearbeiten */
textarea.codearea { font-family: var(--code); font-size: 0.9rem; line-height: 1.5; min-height: 14rem; tab-size: 4; white-space: pre; overflow-x: auto; }
textarea.codearea.tall { min-height: 60vh; }
form.stack.wide { max-width: none; }
.preview { border: 1.5px dashed #b9c3d2; border-radius: var(--r-s); padding: 0.75rem 1rem; }
.notice.error { background: #fde4e4; color: #6b1515; }
.sticky-save { position: sticky; bottom: 0; background: var(--paper); padding: 0.75rem 0; border-top: 1px solid var(--line); }
.admin-list li { grid-template-columns: 7rem 1fr auto; }
.admin-list form { margin: 0; }
.kat-hinweise { grid-template-columns: 9rem 1fr; font-size: 0.95rem; gap: 0.25rem 1rem; }
.btn.danger { color: #8b1d1d; }
.btn.danger:hover { background: #fde4e4; border-color: #8b1d1d; }

/* Moderationsfelder beim Schreiben */
.modfields { border: 1px dashed var(--line, #ccc); border-radius: var(--r-m); padding: 0.9rem 1rem 1rem; margin: 0; }
.modfields legend { font-weight: 700; padding: 0 0.4rem; }
