/* ============================================================
   ium.schule — gemeinsames Design (SPARKS)
   Farben und Schrift aus dem SPARKS Design System (tokens.css).
   Wird von allen Seiten geladen: <link rel="stylesheet" href="…/assets/site.css?v=1">
   Nach einer Änderung hier: ?v=1 in allen Seiten hochzählen (?v=2 …).
   ============================================================ */

@font-face {
  font-family: "Montserrat";
  src: url("fonts/montserrat.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("fonts/cormorant-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: block;
}

:root {
  --sparks-teal: #225c67;
  --sparks-teal-700: #2d4751;
  --sparks-teal-900: #1e2f36;
  --sparks-teal-300: #8aa3ad;
  --sparks-teal-100: #dee7ea;
  --sparks-teal-050: #eef2f4;
  --ium: #c7324d;
  --ium-700: #9c2740;
  --ium-100: #f6dadf;
  --gold: #fab20b;

  /* Die zwei Fächer in IuM: I = Informatik, M = Medienbildung.
     Beide Farben haben auf --paper und Weiß mindestens 4,5 : 1 Kontrast (auch für kleine Schrift). */
  --c-informatik: #2d7691;   /* BEAM-Blau, abgedunkelt: 4,9 : 1 auf --paper */
  --c-medien: #c7324d;       /* IuM-Rot: 5,0 : 1 auf --paper */

  --ink-900: #11181c;
  --ink-700: #344048;
  --ink-500: #5b6b74;
  --ink-300: #97a4ac;
  --ink-100: #e6eaec;
  --paper: #fbfaf6;
  --paper-2: #f3efe6;
  --white: #ffffff;

  --font: "Montserrat", "Helvetica Neue", Arial, sans-serif;
  --font-roman: "Cormorant Garamond", Georgia, "Times New Roman", serif;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-pill: 999px;
  --shadow-1: 0 1px 2px rgba(30,47,54,.06), 0 2px 8px rgba(30,47,54,.05);
  --shadow-2: 0 2px 6px rgba(30,47,54,.08), 0 12px 28px rgba(30,47,54,.10);

  --page-max: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink-900);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sparks-teal); text-underline-offset: 3px; }
a:hover { color: var(--sparks-teal-700); }
h1, h2, h3 { color: var(--sparks-teal-900); line-height: 1.12; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-weight: 800; font-size: clamp(30px, 5vw, 56px); }
h2 { font-weight: 700; font-size: clamp(22px, 3vw, 32px); }
h3 { font-weight: 700; font-size: 19px; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.wrap { width: 100%; max-width: var(--page-max); margin: 0 auto; padding: 0 var(--gutter); }
.eyebrow { font-weight: 600; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--ium); margin: 0 0 .6em; }
.lede { font-size: clamp(17px, 2vw, 19px); color: var(--ink-700); text-wrap: pretty; }
.muted { color: var(--ink-500); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- Kopfzeile ------------------------------------------ */
.site-head { position: relative; background: var(--white); border-bottom: 1px solid var(--ink-100); }
.site-head .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 48px; text-decoration: none; color: var(--sparks-teal-900); font-weight: 800; font-size: 20px; letter-spacing: -0.02em; }
.brand img { width: 72px; height: auto; }
.brand:hover { color: var(--sparks-teal-900); }
/* Wortmarke: i = Informatik, m = Medienbildung, der Punkt dunkel wie „schule“ */
.brand .w-i { color: var(--c-informatik); }
.brand .w-m { color: var(--c-medien); }
.brand .w-dot { color: var(--sparks-teal-900); }

/* Hauptnavigation (nur Startseite). Breit: Links nebeneinander. Schmal (≤ 640 px): Menü-Knopf. */
.site-head nav a { text-decoration: none; font-weight: 600; font-size: 15px; padding: 10px 14px; border-radius: var(--r-pill); color: var(--sparks-teal-900); }
.site-head nav a:hover { background: var(--sparks-teal-050); color: var(--sparks-teal-900); }
.nav-wide { margin-left: auto; display: flex; gap: 6px; }
.nav-menu { display: none; margin-left: auto; }
.nav-menu > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--r-sm); color: var(--sparks-teal-900);
}
.nav-menu > summary::-webkit-details-marker { display: none; }
.nav-menu > summary:hover { background: var(--sparks-teal-050); }
.burger, .burger::before, .burger::after { display: block; width: 22px; height: 2px; border-radius: 2px; background: currentColor; transition: transform .15s; }
.burger { position: relative; }
.burger::before, .burger::after { content: ""; position: absolute; left: 0; }
.burger::before { top: -7px; }
.burger::after { top: 7px; }
.nav-menu[open] .burger { background: transparent; }
.nav-menu[open] .burger::before { transform: translateY(7px) rotate(45deg); }
.nav-menu[open] .burger::after { transform: translateY(-7px) rotate(-45deg); }
.nav-menu nav {
  position: absolute; z-index: 10; top: 100%; left: 0; right: 0;
  display: flex; flex-direction: column; gap: 2px;
  padding: 8px var(--gutter) 12px; background: var(--white);
  border-bottom: 1px solid var(--ink-100); box-shadow: var(--shadow-2);
}
.nav-menu nav a { display: flex; align-items: center; min-height: 48px; border-radius: var(--r-sm); font-size: 17px; }
@media (max-width: 640px) {
  .site-head .wrap { min-height: 60px; }
  .brand { font-size: 19px; }
  .brand img { width: 60px; }
  .nav-wide { display: none; }
  .nav-menu { display: block; }
}

/* ---- Fußzeile ------------------------------------------- */
.site-foot { background: var(--sparks-teal-900); color: #cfdbdf; margin-top: 64px; font-size: 14px; }
.site-foot .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; padding-top: 24px; padding-bottom: 24px; }
.site-foot a { color: var(--white); }
.site-foot .links { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.site-foot .sep { display: none; }
@media (max-width: 640px) {
  .site-foot .wrap { flex-direction: column; align-items: flex-start; gap: 6px; padding-top: 22px; padding-bottom: 26px; }
  .site-foot .links { margin-left: 0; gap: 10px; }
  .site-foot .links a { display: inline-flex; align-items: center; min-height: 44px; }
  .site-foot .sep { display: inline; color: var(--sparks-teal-300); }
}

/* ---- Knöpfe --------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 18px; border-radius: var(--r-pill);
  border: 2px solid var(--sparks-teal); background: var(--white); color: var(--sparks-teal);
  font: 600 15px/1.2 var(--font); text-decoration: none; cursor: pointer;
  transition: background .15s, color .15s;
}
.btn:hover { background: var(--sparks-teal-050); color: var(--sparks-teal-700); }
.btn.primary { background: var(--sparks-teal); color: var(--white); }
.btn.primary:hover { background: var(--sparks-teal-700); border-color: var(--sparks-teal-700); color: var(--white); }
.btn.accent { background: var(--ium); border-color: var(--ium); color: var(--white); }
.btn.accent:hover { background: var(--ium-700); border-color: var(--ium-700); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.icon { width: 44px; padding: 0; }

/* ---- Karten / Kacheln ----------------------------------- */
.card { background: var(--white); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; }
.card.link { display: flex; flex-direction: column; text-decoration: none; color: inherit; transition: box-shadow .2s, transform .2s; }
.card.link:hover { box-shadow: var(--shadow-2); transform: translateY(-2px); color: inherit; }
.card .body { padding: 20px 22px 24px; }

/* ---- Aufklappbereiche ----------------------------------- */
details.box { background: var(--white); border-radius: var(--r-md); box-shadow: var(--shadow-1); }
details.box > summary { cursor: pointer; padding: 14px 18px; font-weight: 700; color: var(--sparks-teal-900); list-style: none; display: flex; align-items: center; gap: 10px; min-height: 44px; }
details.box > summary::-webkit-details-marker { display: none; }
details.box > summary::before { content: "▸"; color: var(--ium); transition: transform .15s; }
details.box[open] > summary::before { transform: rotate(90deg); }
details.box > .inner { padding: 0 18px 18px; }

/* ---- Formulare ------------------------------------------ */
label { font-weight: 600; font-size: 14px; color: var(--ink-700); }
textarea, input[type="text"], input[type="number"] {
  width: 100%; font: 400 17px/1.45 var(--font); color: var(--ink-900);
  background: var(--white); border: 2px solid var(--ink-100); border-radius: var(--r-md); padding: 12px 14px;
}
textarea:focus, input:focus { border-color: var(--sparks-teal); outline: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
