/* Karate Dojo Chikara Dallau e. V. – gemeinsames Stylesheet */
:root {
  --rot: #d90026;
  --rot-dunkel: #a8001d;
  --schwarz: #111111;
  --grau-900: #1f1f1f;
  --grau-600: #5c5c5c;
  --grau-300: #d9d9d9;
  --grau-100: #f4f3f1;
  --weiss: #ffffff;
  --radius: 10px;
  --breite: 1100px;
  --schatten: 0 1px 3px rgba(0,0,0,.08), 0 6px 20px rgba(0,0,0,.06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--grau-900);
  background: var(--grau-100);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1; }
img { max-width: 100%; height: auto; }
a { color: var(--rot); text-underline-offset: 3px; }
a:hover { color: var(--rot-dunkel); }
h1, h2, h3 { line-height: 1.2; color: var(--schwarz); }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 0 0 .4em; letter-spacing: -.01em; }
h2 { font-size: 1.45rem; margin: 1.8em 0 .6em; }
h3 { font-size: 1.15rem; margin: 1.2em 0 .3em; }
.container { width: 100%; max-width: var(--breite); margin: 0 auto; padding: 0 20px; }

/* ---------- Kopfbereich / Navigation ---------- */
.kopf {
  background: var(--weiss);
  border-bottom: 4px solid var(--rot);
  position: sticky; top: 0; z-index: 50;
}
.kopf .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 76px; }
.marke { display: flex; align-items: center; text-decoration: none; }
.marke img { height: 58px; width: auto; display: block; }
.nav-toggle { display: none; }
.nav-knopf { display: none; cursor: pointer; padding: 10px; border-radius: 8px; }
.nav-knopf span, .nav-knopf span::before, .nav-knopf span::after {
  display: block; width: 26px; height: 3px; background: var(--schwarz); border-radius: 2px; position: relative; content: "";
}
.nav-knopf span::before { position: absolute; top: -8px; }
.nav-knopf span::after { position: absolute; top: 8px; }
.hauptnav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 2px; }
.hauptnav a {
  display: block; padding: 8px 12px; border-radius: 6px;
  color: var(--schwarz); text-decoration: none; font-weight: 600; font-size: .95rem;
}
.hauptnav a:hover { background: var(--grau-100); color: var(--rot); }
.hauptnav a.aktiv { background: var(--rot); color: var(--weiss); }
.hauptnav a.login { border: 2px solid var(--schwarz); padding: 6px 12px; }
.hauptnav a.login:hover { background: var(--schwarz); color: var(--weiss); }

@media (max-width: 960px) {
  .nav-knopf { display: block; }
  .hauptnav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--weiss); border-bottom: 4px solid var(--rot); box-shadow: var(--schatten); }
  .nav-toggle:checked ~ .hauptnav { display: block; }
  .hauptnav ul { flex-direction: column; padding: 8px 12px 14px; }
  .hauptnav a { padding: 12px; font-size: 1.05rem; }
  .marke img { height: 48px; }
}

/* ---------- Seitenkopf ---------- */
.seitenkopf { background: var(--schwarz); color: var(--weiss); padding: 42px 0 36px; position: relative; overflow: hidden; }
.seitenkopf::after {
  content: ""; position: absolute; right: -80px; top: -120px; width: 340px; height: 340px;
  border-radius: 50%; background: var(--rot); opacity: .9;
}
.seitenkopf .container { position: relative; z-index: 1; }
.seitenkopf h1 { color: var(--weiss); margin: 0; }
.seitenkopf p { margin: .4em 0 0; color: #cfcfcf; max-width: 640px; }

/* Startseite */
.hero { background: var(--schwarz); color: var(--weiss); padding: 56px 0 60px; }
.hero .container { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; }
.hero img.hero-logo { width: 100%; max-width: 520px; }
.hero h1 { color: var(--weiss); }
.hero p { color: #d6d6d6; font-size: 1.1rem; }
@media (max-width: 800px) { .hero .container { grid-template-columns: 1fr; } .hero { padding: 36px 0 40px; } }

.knopf {
  display: inline-block; background: var(--rot); color: var(--weiss); text-decoration: none;
  font-weight: 700; padding: 12px 22px; border-radius: 8px; margin: 6px 8px 0 0; border: 2px solid var(--rot);
}
.knopf:hover { background: var(--rot-dunkel); border-color: var(--rot-dunkel); color: var(--weiss); }
.knopf.hell { background: transparent; color: var(--weiss); border-color: var(--weiss); }
.knopf.hell:hover { background: var(--weiss); color: var(--schwarz); }
.knopf.umriss { background: transparent; color: var(--rot); }
.knopf.umriss:hover { background: var(--rot); color: var(--weiss); }

/* ---------- Inhalt ---------- */
.inhalt { padding: 40px 0 56px; }
.karte {
  background: var(--weiss); border-radius: var(--radius); box-shadow: var(--schatten);
  padding: 28px 30px; margin-bottom: 24px;
}
.karte > :first-child { margin-top: 0; }
.karte > :last-child { margin-bottom: 0; }
.text { max-width: 760px; }
.raster { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.kachel {
  background: var(--weiss); border-radius: var(--radius); box-shadow: var(--schatten); padding: 24px;
  text-decoration: none; color: inherit; border-top: 4px solid var(--rot); display: block; transition: transform .15s;
}
a.kachel:hover { transform: translateY(-3px); color: inherit; }
.kachel h3 { margin-top: 0; }
.kachel p { margin: 0; color: var(--grau-600); }

.hinweis {
  border-left: 5px solid var(--rot); background: #fff4f5; padding: 18px 22px; border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 24px;
}
.hinweis strong.marker { color: var(--rot); text-transform: uppercase; letter-spacing: .05em; font-size: .85rem; display: block; }
.zitat { border-left: 4px solid var(--grau-300); margin: 1em 0; padding: .2em 0 .2em 1.2em; color: var(--grau-600); font-style: italic; }
.klein { font-size: .9rem; color: var(--grau-600); }

/* Tabellen */
.tabelle-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: var(--weiss); }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--grau-300); vertical-align: top; }
th { background: var(--schwarz); color: var(--weiss); font-weight: 600; }
tbody tr:nth-child(even) td { background: #faf9f8; }

/* Termine */
.termine { list-style: none; margin: 0; padding: 0; }
.termine li { display: grid; grid-template-columns: 170px 1fr; gap: 18px; padding: 18px 0; border-bottom: 1px solid var(--grau-300); }
.termine li:last-child { border-bottom: 0; }
.termine .datum { font-weight: 800; color: var(--rot); }
.termine h3 { margin: 0 0 .2em; }
.termine p { margin: 0; color: var(--grau-600); }
.termine li.vorbei { opacity: .45; }
.termine li.vorbei .datum::after { content: " · vorbei"; font-weight: 400; color: var(--grau-600); font-size: .85rem; }
@media (max-width: 600px) { .termine li { grid-template-columns: 1fr; gap: 4px; } }

/* Personen */
.personen { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.person { background: var(--weiss); border-radius: var(--radius); box-shadow: var(--schatten); overflow: hidden; }
.person .foto { aspect-ratio: 3 / 4; background: var(--schwarz); display: flex; align-items: center; justify-content: center; }
.person .foto img { width: 100%; height: 100%; object-fit: cover; display: block; }
.person .foto span { color: var(--weiss); font-size: 3rem; font-weight: 800; width: 110px; height: 110px; border-radius: 50%; background: var(--rot); display: flex; align-items: center; justify-content: center; }
.person .info { padding: 16px 18px 20px; }
.person h3 { margin: 0; }
.person .amt { color: var(--rot); font-weight: 700; margin: 2px 0 8px; }
.person ul { margin: 0; padding-left: 18px; color: var(--grau-600); font-size: .95rem; }

/* Knigge */
.regeln { counter-reset: regel; list-style: none; padding: 0; margin: 0; }
.regeln li { position: relative; padding: 14px 0 14px 64px; border-bottom: 1px solid var(--grau-300); }
.regeln li:last-child { border-bottom: 0; }
.regeln li::before {
  counter-increment: regel; content: counter(regel, upper-roman);
  position: absolute; left: 0; top: 12px; width: 46px; text-align: center;
  font-weight: 800; color: var(--weiss); background: var(--rot); border-radius: 6px; padding: 2px 0;
}

/* Unternavigation */
.unternav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.unternav a { padding: 8px 14px; border-radius: 999px; background: var(--weiss); box-shadow: var(--schatten); text-decoration: none; color: var(--schwarz); font-weight: 600; font-size: .95rem; }
.unternav a:hover { color: var(--rot); }
.unternav a.aktiv { background: var(--schwarz); color: var(--weiss); }

/* Begriffe */
.suche { width: 100%; padding: 12px 14px; font-size: 1rem; border: 2px solid var(--grau-300); border-radius: 8px; margin-bottom: 18px; }
.suche:focus { outline: none; border-color: var(--rot); }
.begriffe td:first-child { font-weight: 700; white-space: nowrap; width: 34%; }

/* Galerie (Prüfungsprogramm) */
.galerie { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.galerie a { display: block; background: var(--weiss); border-radius: var(--radius); box-shadow: var(--schatten); overflow: hidden; text-decoration: none; color: var(--schwarz); }
.galerie img { display: block; width: 100%; aspect-ratio: 3/4; object-fit: cover; object-position: top; border-bottom: 1px solid var(--grau-300); }
.galerie span { display: block; padding: 10px 12px; font-weight: 600; font-size: .95rem; }

/* Downloads */
.downloads { list-style: none; padding: 0; margin: 0; }
.downloads li { border-bottom: 1px solid var(--grau-300); }
.downloads li:last-child { border-bottom: 0; }
.downloads a { display: flex; justify-content: space-between; gap: 12px; padding: 12px 4px; text-decoration: none; color: var(--grau-900); }
.downloads a:hover { color: var(--rot); }
.downloads a::after { content: "PDF"; font-size: .75rem; font-weight: 800; color: var(--weiss); background: var(--rot); padding: 2px 7px; border-radius: 4px; height: fit-content; }

/* Formular */
.formular label { font-weight: 600; display: block; margin-bottom: 4px; }
.formular input[type=text], .formular input[type=tel], .formular textarea {
  width: 100%; padding: 10px 12px; font: inherit; border: 2px solid var(--grau-300); border-radius: 8px; margin-bottom: 16px; background: var(--weiss);
}
.formular input:focus, .formular textarea:focus { outline: none; border-color: var(--rot); }
.formular fieldset { border: 0; padding: 0; margin: 0 0 8px; }
.formular .auswahl { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 14px; margin-bottom: 14px; }
.formular .auswahl label, .formular label.check { font-weight: 400; display: flex; align-items: center; gap: 8px; }
.formular label.zeit { font-size: 1.15rem; font-weight: 700; margin-bottom: 14px; }
.formular input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--rot); }
.formular button { font: inherit; cursor: pointer; width: 100%; font-size: 1.05rem; }
.fehler { display: none; background: #ffe3e6; color: #8a0018; border: 2px solid var(--rot); padding: 12px 16px; border-radius: 8px; margin-bottom: 20px; font-weight: 600; }

/* ---------- Fuß ---------- */
.fuss { background: var(--schwarz); color: #bdbdbd; padding: 40px 0 26px; font-size: .95rem; }
.fuss .container { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 30px; }
.fuss img { width: 200px; }
.fuss h4 { color: var(--weiss); margin: 0 0 10px; font-size: 1rem; }
.fuss a { color: #e6e6e6; text-decoration: none; }
.fuss a:hover { color: var(--weiss); text-decoration: underline; }
.fuss ul { list-style: none; margin: 0; padding: 0; }
.fuss li { margin: 4px 0; }
.fuss .unten { grid-column: 1 / -1; border-top: 1px solid #333; padding-top: 16px; font-size: .85rem; }
@media (max-width: 760px) { .fuss .container { grid-template-columns: 1fr; } }

@media print {
  .kopf, .fuss, .unternav { display: none; }
  .seitenkopf { background: none; color: #000; padding: 0; }
  .seitenkopf::after { display: none; }
  .seitenkopf h1 { color: #000; }
  .karte { box-shadow: none; }
}
