/* ITSK Forum – Computerladen, Quiz, Bestenliste, Lernplan, Begleiter "Bit" */

/* ---------- Gemeinsam ---------- */
.xpbar { height: 10px; background: rgba(255,255,255,0.06); border-radius: 999px; overflow: hidden; }
.xpbar > div { height: 100%; background: linear-gradient(90deg, #4d9fff, #69db7c); border-radius: 999px; transition: width .4s; }
.xpbar.small { height: 6px; }
.lern-pill {
  display: inline-block; padding: 1px 8px; border-radius: 6px;
  background: rgba(77,159,255,0.1); border: 1px solid rgba(77,159,255,0.35);
  color: #74c0fc; font-size: 0.75rem; font-weight: 600; text-decoration: none;
}
.coins { margin-left: auto; color: #ffd43b; font-weight: 600; font-size: 0.95rem; }

/* ---------- Computerladen ---------- */
.shop-sign {
  margin: 24px 0 18px;
  border-radius: 14px;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.03) 0 2px, transparent 2px 22px),
    linear-gradient(135deg, #10203a, #0d1520 60%, #15112a);
  border: 1px solid rgba(77,159,255,0.3);
  box-shadow: inset 0 0 40px rgba(77,159,255,0.08);
}
.shop-sign-inner { padding: 22px 26px; font-size: 1.7rem; font-weight: 600; letter-spacing: -0.3px; }
.shop-sign-inner small { display: block; font-size: 0.9rem; font-weight: 400; color: var(--muted, #8e95a3); margin-top: 4px; letter-spacing: 0; }
.shop-neon { color: #69db7c; text-shadow: 0 0 8px rgba(105,219,124,0.7), 0 0 18px rgba(105,219,124,0.35); font-family: ui-monospace, Consolas, monospace; }

.shop-top { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; align-items: stretch; }
.lern-card { margin: 0; }
.lern-level { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.lern-level strong { font-size: 1.8rem; color: #74c0fc; }
.lern-meta { color: var(--muted, #8e95a3); font-size: 0.82rem; margin-top: 6px; }
.lern-today { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; font-size: 0.85rem; color: var(--muted, #8e95a3); }
.lern-today strong { color: var(--text, #f0eee9); }
.shop-links { display: grid; gap: 8px; }
.shop-link {
  display: flex; align-items: center; gap: 12px; font-size: 1.4rem;
  background: var(--card, #181c25); border: 1px solid var(--border, #262b36); border-radius: 12px;
  padding: 10px 14px; text-decoration: none; color: var(--text, #f0eee9);
}
.shop-link:hover { border-color: var(--accent, #4d9fff); }
.shop-link span { display: flex; flex-direction: column; font-size: 0.95rem; }
.shop-link small { color: var(--muted, #8e95a3); font-size: 0.8rem; }

.lern-modus {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 18px 0 12px; padding: 12px 16px; border-radius: 12px;
  background: rgba(105,219,124,0.1); border: 1px solid rgba(105,219,124,0.35); color: #b2f2bb;
}
.lern-modus-sub { font-size: 0.82rem; color: var(--muted, #8e95a3); margin-top: 3px; }
.lern-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 14px; }
.lernkarte ul { margin: 0; padding-left: 1.2em; line-height: 1.7; }
.lernkarte li { margin: 4px 0; }
.free-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

.frage-box { margin: 0; }
.frage-kopf { display: flex; justify-content: space-between; gap: 10px; color: var(--muted, #8e95a3); font-size: 0.85rem; margin-bottom: 8px; flex-wrap: wrap; }
.frage-box h3 { font-size: 1.15rem; margin: 10px 0 14px; line-height: 1.4; }
.antworten { display: grid; gap: 8px; }
.antwort {
  text-align: left; padding: 11px 14px; border-radius: 10px; font-size: 0.98rem; cursor: pointer;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border, #262b36); color: var(--text, #f0eee9);
  transition: border-color .12s, background .12s;
}
.antwort:hover:not(:disabled) { border-color: var(--accent, #4d9fff); background: var(--accent-soft, rgba(77,159,255,.1)); }
.antwort:disabled { cursor: default; opacity: 0.8; }
.antwort.richtig { border-color: #69db7c; background: rgba(105,219,124,0.15); opacity: 1; }
.antwort.falsch { border-color: #ff6b6b; background: rgba(255,107,107,0.12); opacity: 1; }
.erklaerung { margin-top: 12px; padding: 10px 12px; border-radius: 8px; font-size: 0.9rem; }
.erklaerung.ok { background: rgba(105,219,124,0.1); color: #b2f2bb; }
.erklaerung.nein { background: rgba(255,107,107,0.1); color: #ffc9c9; }
.frage-box #frage-weiter { margin-top: 12px; }
.xp-pop { color: #ffd43b; font-weight: 700; }

.regal-titel { margin-top: 28px; }
.regal {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px;
  padding: 14px; border-radius: 14px;
  background: linear-gradient(180deg, transparent calc(100% - 10px), rgba(139,94,52,0.35) calc(100% - 10px));
}
.station {
  display: flex; flex-direction: column; gap: 6px;
  background: var(--card, #181c25); border: 1px solid var(--border, #262b36); border-radius: 12px; padding: 16px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
}
.station.aktiv { border-color: #69db7c; box-shadow: 0 0 0 1px rgba(105,219,124,0.4), 0 6px 18px rgba(0,0,0,0.25); }
.station-icon { font-size: 2rem; }
.station-name { font-weight: 600; }
.station-blurb { color: var(--muted, #8e95a3); font-size: 0.85rem; flex: 1; }
.station-prog small { color: var(--muted, #8e95a3); font-size: 0.75rem; }
.station-btn { width: 100%; margin-top: 6px; }

/* ---------- Quiz ---------- */
.quiz-layout { display: grid; grid-template-columns: 1.6fr 1fr; gap: 14px; align-items: start; }
.quiz-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.quiz-cat {
  display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 1.5rem; padding: 12px 8px;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border, #262b36); border-radius: 10px; cursor: pointer; color: var(--text, #f0eee9);
}
.quiz-cat span { font-size: 0.9rem; font-weight: 600; }
.quiz-cat small { font-size: 0.72rem; color: var(--muted, #8e95a3); }
.quiz-cat:hover { border-color: var(--accent, #4d9fff); }
.quiz-cat.mix { border-color: rgba(255,212,59,0.5); }
.quiz-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; min-height: 34px; }
.quiz-ende { text-align: center; }
.quiz-ende-icon { font-size: 3rem; }

/* ---------- Bestenliste ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 16px; }
.tab { padding: 7px 14px; border-radius: 999px; background: rgba(255,255,255,0.04); border: 1px solid var(--border, #262b36); color: var(--muted, #8e95a3); text-decoration: none; font-size: 0.88rem; }
.tab.on, .tab:hover { color: var(--text, #f0eee9); border-color: var(--accent, #4d9fff); background: var(--accent-soft, rgba(77,159,255,.12)); }
.mein-platz { color: #b2f2bb; }
.podest { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; align-items: end; max-width: 620px; margin: 10px auto 22px; text-align: center; }
.podest-platz a { font-weight: 600; text-decoration: none; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.podest-medaille { font-size: 2rem; }
.podest-wert { font-size: 0.95rem; margin: 2px 0 6px; }
.podest-wert small { color: var(--muted, #8e95a3); display: block; font-size: 0.75rem; }
.podest-block { border-radius: 10px 10px 0 0; background: var(--card, #181c25); border: 1px solid var(--border, #262b36); font-size: 1.6rem; font-weight: 700; color: var(--muted, #8e95a3); display: flex; align-items: center; justify-content: center; }
.p1 .podest-block { height: 110px; border-color: rgba(255,212,59,0.5); color: #ffd43b; }
.p2 .podest-block { height: 80px; border-color: rgba(206,212,218,0.4); }
.p3 .podest-block { height: 60px; border-color: rgba(214,130,74,0.45); }
.rangliste { display: grid; gap: 6px; }
.rang-row { display: flex; align-items: center; gap: 12px; background: var(--card, #181c25); border: 1px solid var(--border, #262b36); border-radius: 10px; padding: 10px 14px; }
.rang-row.ich { border-color: #69db7c; }
.rang-row a { text-decoration: none; font-weight: 600; flex: 1; }
.rang-nr { width: 32px; text-align: center; color: var(--muted, #8e95a3); font-weight: 600; }
.rang-wert { color: var(--muted, #8e95a3); font-size: 0.88rem; white-space: nowrap; }

/* ---------- Lernplan ---------- */
.plan-form { display: grid; gap: 8px; }
.plan-row {
  display: grid; grid-template-columns: 140px 1fr auto auto auto; gap: 10px; align-items: center;
  background: var(--card, #181c25); border: 1px solid var(--border, #262b36); border-radius: 10px; padding: 10px 14px;
}
.plan-row input[type=number] { width: 72px; }
.plan-row.on { border-color: rgba(77,159,255,0.45); }
.plan-row:not(.on) > :not(.plan-tag):not(.plan-frei) { display: none; }
.plan-frei { display: none; color: var(--muted, #8e95a3); grid-column: 2 / -1; }
.plan-row:not(.on) .plan-frei { display: block; }
.plan-tag, .plan-feld { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.plan-form > button { justify-self: start; margin-top: 6px; }
.profil-plan-kopf { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 24px 0 12px; }
.profil-plan { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.pp-tag { background: rgba(255,255,255,0.02); border: 1px solid var(--border, #262b36); border-radius: 10px; padding: 10px 8px; text-align: center; min-height: 86px; }
.pp-tag.on { border-color: rgba(77,159,255,0.45); background: var(--accent-soft, rgba(77,159,255,.08)); }
.pp-name { font-weight: 700; color: var(--muted, #8e95a3); font-size: 0.8rem; text-transform: uppercase; }
.pp-thema { font-weight: 600; font-size: 0.88rem; margin-top: 4px; overflow-wrap: anywhere; }
.pp-zeit { color: var(--muted, #8e95a3); font-size: 0.75rem; margin-top: 2px; }
.pp-frei { color: var(--muted, #8e95a3); font-size: 0.82rem; margin-top: 10px; }

/* ---------- Begleiter "Bit" ---------- */
.bit { position: fixed; right: 18px; bottom: 18px; z-index: 900; font-size: 0.9rem; }
.bit-knopf {
  position: relative; width: 56px; height: 56px; border-radius: 50%; padding: 0;
  background: linear-gradient(135deg, #1d3557, #10203a); border: 1px solid rgba(77,159,255,0.5);
  box-shadow: 0 8px 24px rgba(0,0,0,0.45); cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.bit-gesicht { font-size: 1.7rem; }
.bit-zeit {
  position: absolute; bottom: -6px; left: 50%; transform: translateX(-50%);
  background: #ffd43b; color: #111; font-size: 0.66rem; font-weight: 700; border-radius: 999px; padding: 0 6px; white-space: nowrap;
}
.bit-zeit:empty { display: none; }
.bit.lernt .bit-knopf { border-color: #69db7c; box-shadow: 0 0 0 3px rgba(105,219,124,0.25), 0 8px 24px rgba(0,0,0,0.45); }
.bit-panel {
  display: none; position: absolute; right: 0; bottom: 68px; width: 300px; max-width: calc(100vw - 32px);
  background: var(--card, #181c25); border: 1px solid var(--border, #262b36); border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.55); padding: 12px 14px;
  max-height: calc(100vh - 100px); overflow-y: auto;
}
.bit.offen .bit-panel { display: block; }
.bit-kopf { display: flex; justify-content: space-between; align-items: center; font-weight: 600; margin-bottom: 8px; }
.bit-zu { background: none; border: 0; color: var(--muted, #8e95a3); cursor: pointer; font-size: 1rem; }
.bit-blase { background: rgba(77,159,255,0.1); border-radius: 10px 10px 10px 2px; padding: 8px 10px; font-size: 0.85rem; margin-bottom: 8px; }
.bit-heute { font-size: 0.85rem; margin-bottom: 8px; }
.bit-sub { color: var(--muted, #8e95a3); font-size: 0.75rem; margin-top: 2px; }
.bit-mini { background: rgba(255,255,255,0.05); border: 1px solid var(--border, #262b36); color: var(--text, #f0eee9); border-radius: 6px; padding: 1px 7px; font-size: 0.75rem; cursor: pointer; }
.bit-modus { background: rgba(105,219,124,0.1); color: #b2f2bb; border-radius: 8px; padding: 6px 10px; font-size: 0.8rem; margin-bottom: 8px; }
.bit-level { margin-bottom: 10px; font-size: 0.85rem; }
.bit-level .xpbar { margin: 4px 0 2px; }
.bit-level small { color: var(--muted, #8e95a3); font-size: 0.72rem; }
.bit-timer { background: #0b0d12; border: 1px solid var(--border, #262b36); border-radius: 10px; padding: 10px; text-align: center; }
.bit-anzeige { font-family: ui-monospace, Consolas, monospace; font-size: 2rem; font-weight: 600; letter-spacing: 0.04em; }
.bit.timer-laeuft .bit-anzeige { color: #ffd43b; }
.bit-presets, .bit-steuer { display: flex; gap: 6px; justify-content: center; margin-top: 6px; }
.bit-presets button, .bit-steuer button {
  background: rgba(255,255,255,0.05); border: 1px solid var(--border, #262b36); color: var(--text, #f0eee9);
  border-radius: 6px; padding: 3px 10px; font-size: 0.8rem; cursor: pointer;
}
.bit-steuer button:first-child { flex: 1; background: var(--accent-soft, rgba(77,159,255,.15)); border-color: var(--accent, #4d9fff); }
.bit-links { display: flex; justify-content: space-between; margin-top: 10px; font-size: 0.82rem; }
.bit-links a { color: var(--accent, #4d9fff); text-decoration: none; }
.bit-notif { width: 100%; margin-top: 8px; font-size: 0.8rem; padding: 6px; }
.bit-toast {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px;
  background: #1d2a1f; border: 1px solid rgba(105,219,124,0.5); color: #d3f9d8;
  border-radius: 10px; padding: 8px 10px; font-size: 0.85rem;
}
.bit-toast[hidden] { display: none; }
.bit-toast span { flex: 1; min-width: 160px; }
.bit-toast button { background: rgba(255,255,255,0.08); border: 1px solid rgba(105,219,124,0.5); color: #d3f9d8; border-radius: 6px; padding: 3px 8px; cursor: pointer; font-size: 0.8rem; }
.bit-toast .bit-toast-x { border: 0; background: none; }

@media (max-width: 800px) {
  .shop-top, .lern-grid, .quiz-layout { grid-template-columns: 1fr; }
  .plan-row { grid-template-columns: 1fr 1fr; }
  .plan-row input[name^="topic"] { grid-column: 1 / -1; }
  .profil-plan { grid-template-columns: repeat(4, 1fr); }
  .shop-sign-inner { font-size: 1.3rem; }
  .bit { right: 12px; bottom: 12px; }
  .bit-knopf { width: 50px; height: 50px; }
}

/* Namen in Listen: Rollenfarbe behalten, sonst normale Textfarbe statt Link-Blau */
:where(.rang-row, .podest-platz, .quiz-layout .dash-row, .dash-row) a { color: var(--text, #f0eee9); }

/* Kopfzeile: mehr Symbole/Links – auf großen Bildschirmen enger setzen, bei Bedarf sauber umbrechen */
@media (min-width: 769px) {
  header .container.header-inner { height: auto; min-height: 64px; }
  .header-actions { gap: 0; }
  .hdr-icon { min-width: 36px; padding: 6px; }
  .main-nav { gap: 0; }
  .main-nav a, .main-nav span { padding: 8px 9px; }
}

/* ---------- Kopfzeile mit Symbolen und Reitern ---------- */
.ico { width: 18px; height: 18px; flex-shrink: 0; }
header .hdr-icon { color: var(--muted, #8e95a3); }
header .hdr-icon:hover, header .hdr-icon.on { color: var(--text, #f0eee9); background: rgba(255,255,255,0.05); }
header .hdr-icon .ico { width: 20px; height: 20px; }
.hdr-text { gap: 6px; font-size: 0.9rem; }
.hdr-sep { width: 1px; height: 22px; background: var(--border, #262b36); margin: 0 6px; }
.hdr-user { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 0.9rem; }
.hdr-user:hover { background: rgba(255,255,255,0.05); }
.hdr-avatar { width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft, rgba(77,159,255,.15)); color: var(--accent, #4d9fff); display: inline-flex; align-items: center; justify-content: center; font-size: 0.85rem; }
.tab-link { display: inline-flex; align-items: center; gap: 7px; }
.tab-link .ico { opacity: 0.8; }
.tab-alert { color: #ff8787 !important; }
@media (min-width: 769px) {
  header .container.header-inner { padding-bottom: 0; }
  .tab-nav {
    order: 10; width: 100%; margin: 0 -9px; padding: 2px 0 0;
    border-top: 1px solid rgba(255,255,255,0.04);
  }
  .tab-nav .tab-link {
    padding: 10px 12px 11px; border-radius: 0; font-size: 0.88rem;
    border-bottom: 2px solid transparent; color: var(--muted, #8e95a3);
  }
  .tab-nav .tab-link:hover { background: none; color: var(--text, #f0eee9); }
  .tab-nav .tab-link.on { color: var(--text, #f0eee9); border-bottom-color: var(--accent, #4d9fff); }
  .tab-nav .tab-link.on .ico { color: var(--accent, #4d9fff); opacity: 1; }
}
@media (max-width: 768px) {
  .hdr-name, .hdr-sep { display: none; }
  .hdr-user { padding: 4px; }
  header .hdr-icon { min-width: 38px; padding: 6px; }
  .tab-nav .tab-link { gap: 12px; }
  .tab-nav .tab-link.on { color: var(--text, #f0eee9); background: rgba(255,255,255,0.05); }
}
@media (min-width: 769px) { .tab-mobile { display: none !important; } }
@media (max-width: 768px) { .hdr-more { display: none !important; } }
@media (min-width: 769px) {
  .tab-nav { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .tab-nav::-webkit-scrollbar { display: none; }
  .tab-nav .tab-link { padding: 10px 11px 11px; white-space: nowrap; flex-shrink: 0; }
}
.main-nav .tab-link span { padding: 0 !important; min-height: 0 !important; font-size: inherit !important; display: inline !important; }
