/* =========================================================
   SPIELPLATZ — Design Tokens
   Konzept: der Spieltisch. Tiefgrünes Filz, Holzkante,
   Kreide-Typografie, Chips als Akzente, Steppnaht als
   wiederkehrendes Strukturelement (wie am Rand eines
   Kartentischs).
   ========================================================= */

:root {
  /* Farben */
  --felt-900: #0f231a;
  --felt-700: #163c2b;
  --felt-500: #1b4332;
  --felt-400: #2d6a4f;
  --felt-300: #3f8863;

  --wood-500: #c9a66b;
  --wood-300: #e3c896;
  --wood-700: #8a6a3c;

  --chalk-100: #f7f3e8;
  --chalk-300: #ece4d0;

  --chip-gold: #e9b44c;
  --chip-red: #c1443c;
  --chip-blue: #3d7ea6;
  --chip-yellow: #e0c341;

  --ink: #0a1712;

  /* Typografie */
  --font-display: "Bricolage Grotesque", "Segoe UI", sans-serif;
  --font-body: "Inter", "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "Courier New", monospace;

  /* Radius / Schatten */
  --radius-card: 18px;
  --radius-sm: 10px;
  --shadow-lift: 0 14px 30px -12px rgba(0, 0, 0, 0.55);
  --shadow-soft: 0 6px 16px -8px rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--chalk-100);
  background:
    radial-gradient(ellipse at 20% -10%, rgba(63, 136, 99, 0.35), transparent 55%),
    radial-gradient(ellipse at 100% 0%, rgba(233, 180, 76, 0.08), transparent 45%),
    var(--felt-500);
  background-attachment: fixed;
  line-height: 1.5;
}

/* feiner Filz-Grain über allem */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.05 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

a {
  color: inherit;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  margin: 0;
  color: var(--chalk-100);
}

p {
  margin: 0;
}

button {
  font-family: var(--font-body);
  cursor: pointer;
}

.wrap {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Steppnaht: Signatur-Element ---------- */
.stitched {
  position: relative;
  border: 2px dashed rgba(247, 243, 232, 0.28);
  border-radius: var(--radius-card);
}
.stitched::after {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px dashed rgba(247, 243, 232, 0.14);
  border-radius: calc(var(--radius-card) - 7px);
  pointer-events: none;
}

/* ---------- Kopfzeile ---------- */
.site-header {
  position: relative;
  z-index: 2;
  padding: 18px 0;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none;
}
.brand-mark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  color: var(--chalk-100);
}
.brand-mark span {
  color: var(--chip-gold);
}
.brand-sub {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--wood-300);
  opacity: 0.85;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--chalk-100);
  background: rgba(247, 243, 232, 0.08);
  border: 1px solid rgba(247, 243, 232, 0.2);
  padding: 8px 14px;
  border-radius: 999px;
  transition: background 0.15s ease, transform 0.15s ease;
}
.back-link:hover {
  background: rgba(247, 243, 232, 0.16);
  transform: translateX(-2px);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  z-index: 1;
  padding: 56px 0 40px;
  text-align: center;
}
.hero-eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--wood-300);
  padding: 6px 14px;
  border: 1px dashed rgba(233, 196, 150, 0.5);
  border-radius: 999px;
  margin-bottom: 20px;
}
.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.02;
  text-shadow: 0 2px 0 rgba(0,0,0,0.25);
}
.hero h1 em {
  font-style: normal;
  color: var(--chip-gold);
}
.hero p.lede {
  max-width: 560px;
  margin: 18px auto 0;
  color: var(--chalk-300);
  font-size: 1.05rem;
}

/* ---------- Spiel-Kacheln (Karten am Tisch) ---------- */
.game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
  margin: 44px 0 60px;
}

.game-card {
  position: relative;
  text-decoration: none;
  padding: 26px 22px 22px;
  background: linear-gradient(165deg, rgba(247,243,232,0.06), rgba(247,243,232,0.02));
  border: 2px dashed rgba(247, 243, 232, 0.22);
  border-radius: var(--radius-card);
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 190px;
  transition: transform 0.22s cubic-bezier(.2,.8,.2,1), box-shadow 0.22s ease, border-color 0.22s ease;
  box-shadow: var(--shadow-soft);
}
.game-card:hover,
.game-card:focus-visible {
  transform: translateY(-6px) rotate(-0.4deg);
  box-shadow: var(--shadow-lift);
  border-color: var(--chip-gold);
  outline: none;
}
.game-card .chip {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  box-shadow: inset 0 0 0 3px rgba(255,255,255,0.18), var(--shadow-soft);
}
.game-card h3 {
  font-size: 1.25rem;
}
.game-card p {
  color: var(--chalk-300);
  font-size: 0.92rem;
  flex-grow: 1;
}
.game-card .play {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--chip-gold);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.game-card.soon {
  opacity: 0.55;
  pointer-events: none;
}
.game-card.soon .play { color: var(--wood-300); }

.chip.c-gold { background: var(--chip-gold); color: var(--ink); }
.chip.c-red { background: var(--chip-red); color: var(--chalk-100); }
.chip.c-blue { background: var(--chip-blue); color: var(--chalk-100); }
.chip.c-yellow { background: var(--chip-yellow); color: var(--ink); }
.chip.c-green { background: var(--felt-300); color: var(--chalk-100); }

/* ---------- Placemat: Spielfläche pro Seite ---------- */
.placemat {
  background: var(--chalk-100);
  color: var(--ink);
  border-radius: var(--radius-card);
  border: 2px dashed var(--wood-500);
  padding: 32px;
  box-shadow: var(--shadow-lift);
  margin-bottom: 60px;
}
.placemat h2 {
  color: var(--ink);
  font-size: 1.7rem;
  margin-bottom: 6px;
}
.placemat .subtitle {
  color: #55524a;
  font-size: 0.95rem;
  margin-bottom: 24px;
}

/* ---------- Buttons ---------- */
.btn {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 10px 20px;
  border: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn-primary {
  background: var(--chip-gold);
  color: var(--ink);
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover { transform: translateY(-2px); }
.btn-ghost {
  background: transparent;
  border: 1.5px solid var(--wood-500);
  color: var(--ink);
}
.btn-ghost:hover { background: rgba(201, 166, 107, 0.12); }
.btn-danger {
  background: var(--chip-red);
  color: white;
}
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  padding: 28px 0 50px;
  text-align: center;
  color: var(--wood-300);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}
.site-footer a { text-decoration: underline; }

/* ---------- Utility ---------- */
.mono { font-family: var(--font-mono); }
.center { text-align: center; }
.small { font-size: 0.85rem; opacity: 0.8; }

@media (max-width: 560px) {
  .placemat { padding: 20px; }
  .hero { padding: 40px 0 28px; }
}

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