/* ==========================================================================
   TIBIL – gemeinsames Design für alle Seiten
   Farben: metallisches Türkisblau + Orange auf fast schwarzem Grund
   ========================================================================== */

:root {
  --bg: #03080d;
  --ink: #dbf6f8;
  --muted: #8db3ba;

  --teal: #19c3d1;
  --teal-hi: #9df3f7;
  --teal-line: rgba(157, 243, 247, 0.18);
  --orange: #ff7a1a;
  --orange-hi: #ffc27a;

  /* Chrom-Effekt: helle Oberkante, dunkle "Horizontlinie" in der Mitte */
  --metal-teal: linear-gradient(180deg,
    #f4feff 0%, #a6f4f8 20%, #2ec4d1 44%, #0a5462 51%,
    #1fa9b7 58%, #8ff0f5 78%, #d9fdff 90%, #4cc9d3 100%);
  --metal-orange: linear-gradient(180deg,
    #fff3e3 0%, #ffc98a 22%, #ff8a2a 45%, #7a2e00 52%,
    #e8691a 60%, #ffb468 80%, #ffe0bd 92%, #ff9440 100%);
  /* Lichtreflex, der über die Schrift wandert */
  --sheen: linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, 0.85) 50%, transparent 58%);

  --panel: linear-gradient(160deg, rgba(16, 40, 50, 0.74), rgba(4, 12, 18, 0.86));
  --radius: 14px;

  /* Michroma: breite Technik-/Automobil-Schrift (nur eine Stärke; „fett“ erzeugt der Browser) */
  --font-display: "Michroma", "Segoe UI", Arial, sans-serif;
  --font-body: "Rajdhani", "Segoe UI", Arial, sans-serif;
  --font-mono: "JetBrains Mono", Consolas, "Courier New", monospace;
}

* { box-sizing: border-box; }

html { color-scheme: dark; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 700px at 12% -10%, rgba(25, 195, 209, 0.16), transparent 60%),
    radial-gradient(1000px 700px at 100% 110%, rgba(255, 122, 26, 0.12), transparent 60%),
    var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Animierte Platine im Hintergrund (wird in main.js gezeichnet) */
#bg {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Feine Bildschirm-Scanlines + dunkle Ränder */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 90% 85% at 50% 45%, transparent 55%, rgba(0, 2, 6, 0.6) 100%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.018) 0 1px, transparent 1px 3px);
}

.page {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
}

a { color: var(--teal-hi); }

/* --------------------------------------------------------------------------
   Metall-Schrift (türkis, auf Wunsch orange)
   -------------------------------------------------------------------------- */
.metal,
.metal-orange {
  background-image: var(--sheen), var(--metal-teal);
  background-size: 300% 100%, 100% 100%;
  background-position: 110% 0, 0 0;
  background-repeat: no-repeat;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: sheen 8s ease-in-out infinite;
}

.metal-orange { background-image: var(--sheen), var(--metal-orange); }

@keyframes sheen {
  0%, 60% { background-position: 110% 0, 0 0; }
  100%    { background-position: -10% 0, 0 0; }
}

/* --------------------------------------------------------------------------
   Kopfbereich der Startseite: TIBIL + Langform
   -------------------------------------------------------------------------- */
.hero {
  text-align: center;
  padding: clamp(40px, 8vh, 88px) 0 clamp(30px, 5vh, 52px);
}

.brand {
  display: flex;
  justify-content: center;
  gap: clamp(0.1em, 2.6vw, 0.36em);
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(3.8rem, 18vw, 11rem);
  line-height: 1;
  filter:
    drop-shadow(0 0 18px rgba(25, 195, 209, 0.38))
    drop-shadow(0 3px 0 rgba(0, 0, 0, 0.55));
}

/* Ein Buchstabe von TIBIL – eine Grafik aus drei Ebenen:
   Chrom türkis, wandernder Lichtreflex, orange Ebene fürs Aufleuchten */
.tl {
  position: relative;
  display: inline-block;
  cursor: default;
  transition: transform 0.3s ease;
  animation: letter-in 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) calc(var(--i) * 0.12s) both;
}

.tl svg {
  display: block;
  height: calc(var(--h) * 1em);
  width: auto;
  overflow: visible;
}

/* Ebenen aller Nasalization-Grafiken (Logo, Titelzeile, Modul-Überschriften) */
.l-metal  { fill: url(#grad-teal); }
.l-sheen  { fill: url(#grad-sheen); }
.l-orange {
  fill: url(#grad-orange);
  opacity: 0;
  filter: drop-shadow(0 0 14px rgba(255, 122, 26, 0.75));
  transition: opacity 0.25s ease;
  /* Einmaliger Durchlauf nach dem Laden: T-I-B-I-L nacheinander */
  animation: link-flash 1.2s ease-in-out calc(1.3s + var(--i, 0) * 0.42s);
}

/* Text als Grafik (erzeugt mit tools/logo-erzeugen.py): steht auf der Grundlinie
   wie normaler Text, Höhe folgt der Schriftgröße */
.nt {
  display: inline-block;
  height: calc(var(--h) * 1em);
  width: auto;
  max-width: 100%;
  overflow: visible;
  vertical-align: baseline;
}

.logo-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

@keyframes letter-in {
  from { opacity: 0; transform: translateY(0.35em) scale(0.9); filter: blur(10px); }
  to   { opacity: 1; transform: none; filter: none; }
}

@keyframes link-flash {
  0%, 100% { opacity: 0; }
  35%, 65% { opacity: 1; }
}

.tl.is-lit { transform: translateY(-0.06em); }
/* Buchstabe und zugehöriger Anfangsbuchstabe leuchten gemeinsam orange */
.tl.is-lit .l-orange,
.tw.is-lit .l-orange { opacity: 1; }

/* Orange-Durchlauf alle paar Sekunden (main.js) – schnelles An und Aus */
.tl.is-sweep .l-orange {
  opacity: 1;
  transition-duration: 0.12s;
}

/* Leuchtlinie zwischen Titel und Langform */
.hero-line {
  position: relative;
  width: min(560px, 78vw);
  height: 1px;
  margin: clamp(18px, 3vh, 28px) auto clamp(16px, 2.6vh, 24px);
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
}

.hero-line::after {
  content: "";
  position: absolute;
  top: -2px;
  width: 64px;
  height: 5px;
  border-radius: 99px;
  background: #fff;
  box-shadow: 0 0 12px var(--orange-hi), 0 0 26px var(--orange);
  animation: sweep 4s ease-in-out infinite;
}

@keyframes sweep {
  0%, 100% { left: 0; opacity: 0; }
  15%, 85% { opacity: 1; }
  50%      { left: calc(100% - 64px); }
}

/* Langform: Technical Innovations – Base for Integrated Level */
.claim {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.15em 0.6em;
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  /* Einzeilig ist der Untertitel (Nasalization-Grafik) ca. 32 × Schriftgröße
     breit – mit 2,8vw bleibt er bei jeder Bildschirmbreite schmaler als der Platz */
  font-size: clamp(0.85rem, 2.8vw, 2.15rem);
  letter-spacing: 0.06em;
  filter: drop-shadow(0 0 10px rgba(25, 195, 209, 0.3));
}

/* Auf Monitoren und Tablets quer: niemals zweizeilig */
@media (min-width: 761px) {
  .claim { flex-wrap: nowrap; white-space: nowrap; }
}

.tw {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  cursor: default;
}

/* Anfangsbuchstabe: deutlich größer und fetter */
.tw b {
  position: relative;
  font-weight: 900;
  font-size: 1.55em;
  margin-right: 0.03em;
}

/* Kleine orange Marke unter jedem Anfangsbuchstaben */
.tw b::before {
  content: "";
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: -0.16em;
  height: 2px;
  border-radius: 2px;
  background: var(--orange);
  box-shadow: 0 0 8px var(--orange);
}

/* Beim Hervorheben läuft die Linie unter dem ganzen Wort */
.tw::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.32em;
  height: 1px;
  background: linear-gradient(90deg, var(--orange), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s ease;
  animation: underline-flash 1.2s ease-in-out calc(1.3s + var(--i) * 0.42s);
}

@keyframes underline-flash {
  0%, 100% { transform: scaleX(0); }
  35%, 65% { transform: scaleX(1); }
}

.tw.is-lit::after { transform: scaleX(1); }

.claim .minor,
.claim .sep { opacity: 0.6; }

/* --------------------------------------------------------------------------
   Die 4 Themenfenster
   -------------------------------------------------------------------------- */
.tiles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: 1fr;               /* alle Fenster gleich hoch */
  gap: clamp(16px, 2.2vw, 28px);
  flex: 1;
  margin: 0;
  padding: 0;
}

.tile {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 260px;
  padding: clamp(22px, 2.6vw, 32px);
  color: inherit;
  text-decoration: none;
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow:
    0 22px 50px -22px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  overflow: hidden;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  animation: tile-in 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) calc(0.5s + var(--d) * 0.12s) both;
}

@keyframes tile-in {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}

/* Metallischer Rahmen: Türkis-Chrom, das unten rechts in Orange übergeht */
.tile::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  padding: 4px;                       /* Rahmenstärke */
  border-radius: inherit;
  background: linear-gradient(135deg,
    #c9fbff 0%, #2ec4d1 18%, #0a4651 42%, #15808c 60%, #ff8a2a 85%, #ffd2a1 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0.75;
  transition: opacity 0.35s ease;
}

/* Orange Eckwinkel oben links und unten rechts */
.tile::after {
  content: "";
  position: absolute;
  inset: 12px;
  pointer-events: none;
  background:
    linear-gradient(var(--orange), var(--orange)) top left / 20px 2px no-repeat,
    linear-gradient(var(--orange), var(--orange)) top left / 2px 20px no-repeat,
    linear-gradient(var(--orange), var(--orange)) bottom right / 20px 2px no-repeat,
    linear-gradient(var(--orange), var(--orange)) bottom right / 2px 20px no-repeat;
  opacity: 0.7;
  transition: inset 0.35s ease, opacity 0.35s ease;
}

/* Lichtbalken, der beim Drüberfahren durchs Fenster scannt */
.tile-scan {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 45%;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(25, 195, 209, 0.12) 55%, rgba(157, 243, 247, 0.22) 60%, transparent 62%);
  transform: translateY(-110%);
}

.tile:hover,
.tile:focus-visible {
  transform: translateY(-5px);
  outline: none;
  box-shadow:
    0 30px 60px -24px rgba(0, 0, 0, 0.9),
    0 0 46px -8px rgba(25, 195, 209, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tile:hover::before,
.tile:focus-visible::before { opacity: 1; }

.tile:hover::after,
.tile:focus-visible::after { inset: 9px; opacity: 1; }

.tile:hover .tile-scan,
.tile:focus-visible .tile-scan { animation: scan 1.8s linear infinite; }

@keyframes scan {
  from { transform: translateY(-110%); }
  to   { transform: translateY(240%); }
}

.tile-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.tile-icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 12px;
  color: var(--teal-hi);
  background: linear-gradient(145deg, rgba(25, 195, 209, 0.2), rgba(25, 195, 209, 0.04));
  box-shadow:
    inset 0 0 0 1px rgba(157, 243, 247, 0.3),
    0 0 26px -6px rgba(25, 195, 209, 0.55);
  transition: color 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
}

.tile:hover .tile-icon,
.tile:focus-visible .tile-icon {
  color: var(--orange-hi);
  background: linear-gradient(145deg, rgba(255, 122, 26, 0.22), rgba(255, 122, 26, 0.05));
  box-shadow:
    inset 0 0 0 1px rgba(255, 194, 122, 0.4),
    0 0 30px -4px rgba(255, 122, 26, 0.6);
}

.icon {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tile-no {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  color: var(--orange-hi);
  opacity: 0.85;
}

.tile-title {
  margin: 6px 0 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.2rem, 2.2vw, 1.75rem);
  letter-spacing: 0.06em;
  line-height: 1.15;
  text-transform: uppercase;
}

.tile-text {
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
  font-weight: 500;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.chips li {
  position: relative;
  padding: 6px 11px 6px 24px;
  border-radius: 6px;
  border: 1px solid var(--teal-line);
  background: rgba(3, 10, 14, 0.6);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: #cdeff2;
}

/* Status-LED vor jedem Eintrag */
.chips li::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 50%;
  width: 6px;
  height: 6px;
  margin-top: -3px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 6px var(--orange);
  animation: led 2.6s ease-in-out infinite;
}

.chips li:nth-child(2)::before { animation-delay: 0.4s; }
.chips li:nth-child(3)::before { animation-delay: 0.8s; }
.chips li:nth-child(4)::before { animation-delay: 1.2s; }
.chips li:nth-child(5)::before { animation-delay: 1.6s; }

@keyframes led {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.35; }
}

.tile-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid rgba(157, 243, 247, 0.12);
  font-family: var(--font-display);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal-hi);
}

.tile-foot .go {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.tile-foot .icon {
  width: 18px;
  height: 18px;
  stroke-width: 2;
  transition: transform 0.3s ease;
}

.tile:hover .tile-foot .icon { transform: translateX(5px); }

.tile-foot .status {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Fußleiste mit Kontakt-Button
   -------------------------------------------------------------------------- */
.foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: clamp(30px, 5vh, 46px) 0 26px;
}

.btn-contact,
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border: 1px solid rgba(255, 220, 180, 0.65);
  border-radius: 10px;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #2b1100;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
  background: linear-gradient(180deg, #ffd8a8 0%, #ff9f45 46%, #ec6a12 54%, #ff9a48 100%);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.55),
    0 12px 30px -10px rgba(255, 122, 26, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-contact:hover,
.btn-contact:focus-visible,
.btn:hover,
.btn:focus-visible {
  transform: translateY(-2px);
  filter: brightness(1.08);
  outline: none;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.55),
    0 16px 40px -10px rgba(255, 122, 26, 0.9),
    0 0 0 4px rgba(255, 122, 26, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.btn-contact:active,
.btn:active { transform: translateY(0); }

.btn-contact .icon,
.btn .icon { width: 20px; height: 20px; stroke-width: 1.8; }

/* Zweitrangiger Button (z. B. Abbrechen) */
.btn-ghost {
  color: var(--teal-hi);
  text-shadow: none;
  background: transparent;
  border-color: rgba(157, 243, 247, 0.35);
  box-shadow: none;
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  box-shadow: 0 0 0 4px rgba(25, 195, 209, 0.14);
}

.foot small {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  opacity: 0.8;
  text-align: center;
}

/* Dezente Urheberzeile ganz unten */
.foot .made-by {
  margin-top: -4px;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  color: var(--orange-hi);
  opacity: 1;
  text-shadow: 0 0 10px rgba(255, 122, 26, 0.55);
}

.foot .made-by b {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: 0.12em;
  filter: drop-shadow(0 0 8px rgba(25, 195, 209, 0.6));
}

.foot { gap: 14px; }

/* --------------------------------------------------------------------------
   Kontakt-Fenster
   -------------------------------------------------------------------------- */
.contact {
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  padding: 0;
  border: none;
  border-radius: 16px;
  color: var(--ink);
  background: linear-gradient(160deg, #0c2029, #050c11);
  box-shadow:
    0 0 0 1px rgba(157, 243, 247, 0.28),
    0 40px 100px -20px #000,
    0 0 70px -24px rgba(25, 195, 209, 0.6);
}

.contact::backdrop {
  background: rgba(1, 4, 8, 0.72);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.contact[open] { animation: dialog-in 0.3s ease-out; }

@keyframes dialog-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to   { opacity: 1; transform: none; }
}

.contact form {
  display: grid;
  gap: 16px;
  padding: clamp(22px, 4vw, 32px);
}

.contact-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.contact h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contact-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.contact-close {
  flex: none;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--teal-line);
  border-radius: 8px;
  background: transparent;
  color: var(--teal-hi);
  cursor: pointer;
}

.contact-close:hover,
.contact-close:focus-visible { border-color: var(--teal); outline: none; }
.contact-close .icon { width: 18px; height: 18px; stroke-width: 2; }

.field { display: grid; gap: 6px; }

.field label {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-hi);
}

.field label span { color: var(--muted); text-transform: none; letter-spacing: 0.02em; }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid rgba(157, 243, 247, 0.22);
  border-radius: 8px;
  background: rgba(1, 6, 10, 0.75);
  color: var(--ink);
  font: 500 1.05rem/1.4 var(--font-body);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field textarea { min-height: 130px; resize: vertical; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(25, 195, 209, 0.2);
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* Spam-Falle: für Menschen unsichtbar */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
}

.contact-msg {
  min-height: 1.4em;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--teal-hi);
}

.contact-msg.is-error { color: var(--orange-hi); }

/* --------------------------------------------------------------------------
   Unterseiten
   -------------------------------------------------------------------------- */
.topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  padding: 22px 0;
  border-bottom: 1px solid rgba(157, 243, 247, 0.1);
}

.logo {
  display: inline-flex;
  align-items: baseline;
  gap: 12px;
  text-decoration: none;
}

.logo-mark {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.7rem;
  letter-spacing: 0.3em;
  filter: drop-shadow(0 0 10px rgba(25, 195, 209, 0.35));
}

.logo-sub {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.logo-sub b { color: var(--orange-hi); font-weight: 600; }

.areas {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.areas a {
  display: block;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.areas a:hover,
.areas a:focus-visible {
  color: var(--teal-hi);
  border-color: var(--teal-line);
  outline: none;
}

.areas a[aria-current="page"] {
  color: var(--orange-hi);
  border-color: rgba(255, 122, 26, 0.45);
  background: rgba(255, 122, 26, 0.08);
}

.area { flex: 1; padding: clamp(30px, 6vh, 64px) 0 10px; }

.back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 26px;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
}

.back .icon { width: 16px; height: 16px; stroke-width: 2; transform: rotate(180deg); transition: transform 0.25s ease; }
.back:hover .icon { transform: rotate(180deg) translateX(4px); }

.area-hero {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 28px);
  margin-bottom: clamp(28px, 5vh, 48px);
}

.area-hero .tile-icon { width: 76px; height: 76px; flex: none; border-radius: 16px; }
.area-hero .icon { width: 40px; height: 40px; }

.area-title {
  margin: 4px 0 6px;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(1.7rem, 5vw, 3.2rem);
  letter-spacing: 0.06em;
  line-height: 1.1;
  text-transform: uppercase;
  filter: drop-shadow(0 0 14px rgba(25, 195, 209, 0.3));
}

.area-intro { margin: 0; max-width: 60ch; color: var(--muted); font-size: 1.12rem; font-weight: 500; }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.card {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 18px 40px -20px rgba(0, 0, 0, 0.85);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  padding: 1px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(201, 251, 255, 0.7), rgba(10, 70, 81, 0.6) 45%, rgba(255, 138, 42, 0.6));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

/* Status-Schild steht über dem Titel, damit lange Namen nicht umbrechen */
.card-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.card-head .badge { order: -1; }

.card h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #e9fbfc;
}

.card p { margin: 0; color: var(--muted); font-weight: 500; }

.badge {
  flex: none;
  padding: 4px 9px;
  border-radius: 99px;
  border: 1px solid rgba(255, 122, 26, 0.5);
  background: rgba(255, 122, 26, 0.1);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange-hi);
  white-space: nowrap;
}

.badge-online {
  border-color: rgba(25, 195, 209, 0.55);
  background: rgba(25, 195, 209, 0.1);
  color: var(--teal-hi);
}

.card-note {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed rgba(157, 243, 247, 0.14);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Minecraft-Server-Fenster – Stil der bisherigen Seite:
   dunkles Menü-Panel, steingraue Buttons mit Blockkanten wie im Spiel
   -------------------------------------------------------------------------- */
.mc-wrap {
  display: flex;
  justify-content: center;
  padding: 10px 0 20px;
}

.mc-box {
  display: grid;                /* untereinander, alle gleich breit */
  gap: 10px;
  width: min(420px, 100%);
  padding: 16px;
  background: rgba(16, 16, 16, 0.72);
  border: 2px solid #000;
  box-shadow:
    inset 2px 2px 0 rgba(255, 255, 255, 0.10),
    inset -2px -2px 0 rgba(0, 0, 0, 0.45),
    0 10px 34px rgba(0, 0, 0, 0.55);
  animation: mc-in 0.7s ease-out 0.2s both;
}

@keyframes mc-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

.mc-title {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 4px 6px;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #fff;
  text-shadow: 2px 2px 0 #3f3f3f;
}

.mc-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 14px 16px 15px 18px;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #e0e0e0;
  text-shadow: 2px 2px 0 #3a3a3a;
  background: linear-gradient(180deg, #7d7d7d 0%, #707070 55%, #666 100%);
  border: 2px solid #000;
  border-radius: 0;
  box-shadow:
    inset 2px 2px 0 #aaaaaa,
    inset -2px -3px 0 #4a4a4a;
}

/* Drüberfahren wie im Spielmenü: weiße Kontur, gelbliche Schrift */
.mc-btn:hover,
.mc-btn:focus-visible {
  color: #ffffa0;
  border-color: #fff;
  background: linear-gradient(180deg, #8a8a8a 0%, #7c7c7c 55%, #727272 100%);
  outline: none;
}

/* Gedrückt: Kanten drehen sich um */
.mc-btn:active {
  box-shadow:
    inset 2px 3px 0 #4a4a4a,
    inset -2px -2px 0 #9a9a9a;
  padding: 15px 16px 14px 18px;
}

/* Nach dem Klick steht der kopierte Wert im Button – in echter Schreibweise */
.mc-btn.is-copied .mc-label,
.mc-btn.is-failed .mc-label {
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.02em;
  text-transform: none;
}

/* Erfolgreich kopiert: kurz grasgrün */
.mc-btn.is-copied {
  color: #fff;
  text-shadow: 2px 2px 0 #2c4a1e;
  background: linear-gradient(180deg, #6fae4a 0%, #5f9a3e 55%, #548a36 100%);
  border-color: #000;
  box-shadow:
    inset 2px 2px 0 #9ad072,
    inset -2px -3px 0 #3b6326;
}

.mc-title svg,
.mc-btn svg {
  width: 17px;
  height: 17px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mc-btn .icon-check { display: none; }
.mc-btn.is-copied .icon-copy { display: none; }
.mc-btn.is-copied .icon-check { display: block; }

/* --------------------------------------------------------------------------
   Lautsprecher-Button mit Sound-Menü oben rechts (wird per sound.js eingefügt)
   -------------------------------------------------------------------------- */
.sound {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 20;
}

.sound-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 2px solid rgba(157, 243, 247, 0.45);
  border-radius: 50%;
  cursor: pointer;
  color: var(--teal-hi);
  background: radial-gradient(circle at 35% 30%, rgba(30, 70, 84, 0.95), rgba(4, 12, 18, 0.95));
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.55), 0 0 18px -6px rgba(25, 195, 209, 0.6);
  transition: color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, transform 0.2s ease;
}

.sound-btn:hover,
.sound-btn:focus-visible {
  transform: scale(1.06);
  border-color: var(--teal);
  outline: none;
}

.sound-btn .icon { width: 22px; height: 22px; stroke-width: 1.8; }
.sound-btn .icon-on { display: none; }
.sound-btn.is-on .icon-on { display: block; }
.sound-btn.is-on .icon-off { display: none; }

/* Eingeschaltet: orange, mit pulsierendem Ring */
.sound-btn.is-on {
  color: var(--orange-hi);
  border-color: rgba(255, 160, 80, 0.8);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.55), 0 0 22px -4px rgba(255, 122, 26, 0.75);
}

.sound-btn.is-on::after,
.sound-btn.is-waiting::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 2px solid var(--orange);
  animation: sound-ring 2.4s ease-out infinite;
  pointer-events: none;
}

/* Wartet auf ersten Klick, um den gemerkten Sound wieder zu starten */
.sound-btn.is-waiting::after { border-color: var(--teal); }

@keyframes sound-ring {
  from { transform: scale(1); opacity: 0.8; }
  to   { transform: scale(1.6); opacity: 0; }
}

/* Aufklappendes Menü unter dem Button */
.sound-panel {
  position: absolute;
  top: 58px;
  right: 0;
  width: min(290px, calc(100vw - 32px));
  padding: 14px;
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(14, 34, 44, 0.97), rgba(4, 11, 16, 0.98));
  box-shadow:
    0 0 0 2px rgba(157, 243, 247, 0.35),
    0 24px 60px -12px rgba(0, 0, 0, 0.9),
    0 0 40px -14px rgba(25, 195, 209, 0.6);
  animation: panel-in 0.2s ease-out;
}

.sound-panel[hidden] { display: none; }

@keyframes panel-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}

.sound-head {
  padding: 2px 6px 10px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.sound-list {
  display: grid;
  gap: 4px;
  max-height: calc(100vh - 230px);         /* niedrige Bildschirme: Liste scrollt */
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* Gruppen-Überschrift im Menü (Melodisch / Weltraum) */
.sound-group {
  margin: 8px 6px 2px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--orange-hi);
  opacity: 0.85;
}

.sound-opt {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.sound-opt:hover,
.sound-opt:focus-visible {
  background: rgba(25, 195, 209, 0.08);
  border-color: var(--teal-line);
  outline: none;
}

/* Auswahlpunkt: leer = nicht gewählt, orange leuchtend = läuft */
.sound-dot {
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(157, 243, 247, 0.5);
}

.sound-opt[aria-checked="true"] {
  background: rgba(255, 122, 26, 0.09);
  border-color: rgba(255, 122, 26, 0.45);
}

.sound-opt[aria-checked="true"] .sound-dot {
  border-color: var(--orange);
  background: radial-gradient(circle, var(--orange-hi) 0 35%, var(--orange) 36% 100%);
  box-shadow: 0 0 10px var(--orange);
}

.sound-txt { display: grid; line-height: 1.25; }

.sound-txt b {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e9fbfc;
}

.sound-opt[aria-checked="true"] .sound-txt b { color: var(--orange-hi); }

.sound-txt small {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--muted);
}

.sound-vol {
  display: grid;
  gap: 6px;
  margin-top: 10px;
  padding: 12px 6px 2px;
  border-top: 1px solid rgba(157, 243, 247, 0.14);
}

.sound-vol span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-hi);
}

.sound-vol input {
  width: 100%;
  accent-color: var(--orange);
  cursor: pointer;
}

/* Platz für den Button in der Kopfleiste der Unterseiten */
.topbar { padding-right: 62px; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   Schmale Bildschirme
   -------------------------------------------------------------------------- */
@media (max-width: 760px) {
  body { font-size: 17px; }
  .page { padding: 0 16px; }

  .tiles {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
  }

  .tile { min-height: 0; }
  .field-row { grid-template-columns: 1fr; }
  .contact-actions { flex-wrap: nowrap; }
  .contact-actions .btn { flex: 1; justify-content: center; padding: 13px 14px; }
  .area-hero { align-items: flex-start; }
  .area-hero .tile-icon { width: 60px; height: 60px; }
  .area-hero .icon { width: 32px; height: 32px; }
  .logo-sub { display: none; }
}

/* Animationen aus, wenn der Besucher das so eingestellt hat */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* TIBIL-Logo (Grafik) in der Kopfleiste der Unterseiten */
.logo-img {
  display: block;
  height: 1.55rem;
  width: auto;
  filter: drop-shadow(0 0 10px rgba(25, 195, 209, 0.35));
}
