/* AUTOMATISCH ERZEUGT von tools/build-dark-css.js - nicht von Hand aendern.
   Ausnahmen und hoher Kontrast stehen in tools/dark-overrides.css. */

/* --- style.css --- */
html.dark {
  --line-thin: #2e3845;
  --line-thick: #33475b;
  --cage-line: #344861;
  --cell-bg: #14181f;
  --peer-bg: #112137;
  --selected-bg: #0d2f58;
  --same-value-bg: #0b2b4b;
  --user-color: #d5dde6;
  --note-color: #7c8a9a;
}
html.dark body {
  background: #171d29 !important;
  color: #d5dde6 !important;
}
html.dark .app-nav-link {
  background: #14181f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .app-nav-link:hover {
    background: #161f2f !important;
  }
}
html.dark .app-nav-link.active {
  color: #ffffff !important;
}
html.dark .file-protocol-warning {
  background: #49360a !important;
  color: #f8e5ab !important;
}
html.dark .rules-btn {
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .rules-btn:hover {
    background: #15253c !important;
  }
}
html.dark .diff-btn {
  background: #14181f !important;
  color: #a6b2c1 !important;
}
html.dark .diff-btn.active {
  color: #ffffff !important;
}
html.dark .difficulty-fallback-note {
  color: #f6d492 !important;
  background: #49360a !important;
  border: 1px solid #7e5c17 !important;
}
html.dark .game-tile {
  background: #14181f !important;
}
@media (hover: hover) {
  html.dark .game-tile:hover {
    background: #141e2a !important;
  }
}
html.dark .game-tile-stat {
  color: #a6b2c1 !important;
}
html.dark .game-tile-best-cell {
  background: #141e2a !important;
}
html.dark .week-trend {
  color: #a6b2c1 !important;
}
html.dark .global-stats {
  background: #14181f !important;
}
html.dark .global-stats-table .global-stats-row-label {
  color: #a6b2c1 !important;
}
html.dark .stats-section-title {
  border-top: 1px solid #161f2f !important;
}
html.dark .best-time-cell {
  background: #141e2a !important;
}
html.dark .leaderboard-list li {
  background: #141e2a !important;
}
html.dark .cell.hint-context {
  background: #49360a !important;
}
html.dark .cell.hint-context.hint-target {
  background: #49360a !important;
}
html.dark .stats-row {
  background: #14181f !important;
}
html.dark #pause-btn {
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark #pause-btn:hover {
    background: #15253c !important;
  }
}
html.dark .notes-primary-btn {
  background: #161f2f !important;
  border: 1px solid #1f2b3b !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .notes-primary-btn:hover {
    background: #1b2637 !important;
  }
}
html.dark .notes-primary-btn.active {
  color: #ffffff !important;
}
html.dark .num-btn {
  background: #161f2f !important;
}
@media (hover: hover) {
  html.dark .num-btn:hover {
    background: #15253c !important;
  }
}
html.dark .num-btn:disabled {
  background: #161f2f !important;
}
html.dark .tool-btn-sm {
  background: #14181f !important;
}
@media (hover: hover) {
  html.dark .tool-btn-sm:hover {
    background: #141e2a !important;
  }
}
html.dark .tool-btn-sm.active {
  color: #ffffff !important;
}
html.dark .endgame-solver-btn {
  background: #161f2f !important;
  border: 1px solid #1f2b3b !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .endgame-solver-btn:hover {
    background: #1b2637 !important;
  }
}
html.dark .endgame-solver-btn.active {
  background: #3b1708 !important;
  border-color: #743118 !important;
  color: #e89d73 !important;
}
html.dark .new-game-btn {
  color: #ffffff !important;
}
html.dark .hint-panel-card {
  background: #14181f !important;
  border: 1px solid #1f2b3b !important;
}
html.dark .hint-panel-close {
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .hint-panel-close:hover {
    background: #15253c !important;
  }
}
html.dark .hint-panel-apply {
  color: #ffffff !important;
}
html.dark .overlay-card {
  background: #14181f !important;
}
html.dark .overlay-card input[type="text"] {
  border: 1px solid #343f4e !important;
}
html.dark .modal-card p {
  color: #a6b2c1 !important;
}
html.dark .modal-steps li {
  color: #b4c3d1 !important;
}
html.dark .app-nav-panel {
  background: #14181f !important;
}
html.dark .app-nav-panel-link {
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .app-nav-panel-link:hover {
    background: #161f2f !important;
  }
}
html.dark .app-nav-panel-link.active {
  color: #ffffff !important;
}
@media (hover: hover) {
  html.dark .game-tile-best-cell:hover .game-tile-best-diff,
  html.dark .game-tile-best-cell:hover .game-tile-best-value {
    color: #ffffff !important;
  }
}
html.dark .home-card {
  background: #14181f !important;
}
@media (hover: hover) {
  html.dark .home-card:hover {
    background: #141e2a !important;
  }
}
html.dark .home-card-main {
  color: #ffffff !important;
}
html.dark .home-card-streak {
  border: 1px dashed #c78d19 !important;
}
html.dark .gen-panel {
  background: #14181f !important;
}
html.dark .gen-sub {
  color: #8a95a2 !important;
}
html.dark .gen-bar {
  background: #1b2534 !important;
}
html.dark .gen-stats {
  color: #a6b2c1 !important;
}
html.dark .gen-log {
  background: #141e2a !important;
  color: #a6b2c1 !important;
}
html.dark .gen-result.ok {
  color: #9ad3b2 !important;
}
html.dark .act-btn {
  background: #14181f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .act-btn:hover {
    background: #141e2a !important;
  }
}
html.dark .act-primary {
  color: #ffffff !important;
}
html.dark .act-result.ok {
  background: #1b3421 !important;
  color: #a9e0ba !important;
}
html.dark .act-result.bad {
  background: #39130d !important;
  color: #dc8779 !important;
}
html.dark .act-result.note {
  background: #44340a !important;
  color: #f7e09f !important;
}
html.dark .act-stand {
  background: #14181f !important;
  color: #a6b2c1 !important;
}
html.dark .act-link {
  background: #161f2f !important;
}
@media (hover: hover) {
  html.dark .act-link:hover {
    background: #15253c !important;
  }
}
@media (hover: hover) {
  html.dark .act-quiet:hover {
    background: #161f2f !important;
  }
}
html.dark .act-menu {
  background: #14181f !important;
  border: 1px solid #1f2b3b !important;
}
html.dark .act-menu-item {
  color: #d5dde6 !important;
}
@media (hover: hover) {
  html.dark .act-menu-item:hover {
    background: #161f2f !important;
  }
}
html.dark .act-counts b {
  color: #a6b2c1 !important;
}
@media (max-width: 700px) {
  html.dark .actions {
    background: #14181f !important;
  }
}
html.dark .account-close {
  color: #a6b2c1 !important;
}
html.dark .account-close:hover,
html.dark .account-close:focus-visible {
  background: #18212e !important;
}
html.dark .account-who {
  color: #a6b2c1 !important;
}
html.dark .account-menu {
  border-top: 1px solid #232a35 !important;
}
html.dark .account-menu-item {
  border-bottom: 1px solid #232a35 !important;
}
html.dark .account-menu-item:hover,
html.dark .account-menu-item:focus-visible {
  background: #161f2a !important;
}
html.dark .account-section {
  border-bottom: 1px solid #232a35 !important;
}
html.dark .account-field {
  color: #a6b2c1 !important;
}
html.dark .account-card input[type="text"],
html.dark .account-card input[type="email"],
html.dark .account-card input[type="password"] {
  border: 1px solid #343f4e !important;
}
html.dark .account-card .new-game-btn.secondary {
  background: #1b2432 !important;
  color: #bfc9d7 !important;
}
html.dark .account-error {
  color: #dc7670 !important;
}
html.dark .account-danger {
  color: #a6b2c1 !important;
}
html.dark .account-danger > summary {
  color: #dc7670 !important;
}
html.dark .daily-card {
  background: #14181f !important;
}
html.dark .daily-card .home-card-sub {
  color: #a6b2c1 !important;
}
html.dark .daily-top {
  color: #a6b2c1 !important;
}
html.dark .daily-note {
  background: #45370a !important;
  color: #f8e5ab !important;
}
html.dark .account-error.account-ok {
  color: #9de0b3 !important;
}
html.dark .account-banner {
  background: #08193b !important;
  color: #adc0e0 !important;
}
html.dark .account-note {
  color: #9ba2b0 !important;
}
html.dark {
  --accent-dark: #2c56b0;
  --accent-soft: #08193b;
  --ink: #d5dde6;
  --muted: #96a2af;
  --card-shadow: 0 1px 2px rgba(20, 35, 60, 0.06), 0 4px 14px rgba(20, 35, 60, 0.06);
}
html.dark body {
  background: linear-gradient(180deg, #0f1d38 0, #171d29 420px) no-repeat #171d29 !important;
}
html.dark .app-nav {
  background: #14181f !important;
}
html.dark .app-nav-link {
  color: #b0bbca !important;
}
@media (hover: hover) {
  html.dark .app-nav-link:hover {
    background: #161f2f !important;
  }
  html.dark .app-nav-link.active:hover {
    background: #0a1f45 !important;
  }
}
html.dark .app-nav-account {
  color: #ffffff !important;
}
html.dark .app-nav-account:hover,
html.dark .app-nav-account:focus-visible {
  color: #ffffff !important;
}
html.dark .account-banner {
  border: 1px solid #112548 !important;
}
@media (hover: hover) {
  html.dark .game-tile:hover {
    background: #14181f !important;
    border-color: #182b4c !important;
  }
}
html.dark .rating-star.on {
  color: #f1c34f !important;
}
html.dark .rating-star:hover,
html.dark .rating-star:focus-visible {
  color: #f1c34f !important;
}
html.dark .overlay-compare {
  color: #b5c1d1 !important;
}
html.dark .overlay-rating {
  color: #b5c1d1 !important;
}
html.dark .overlay-related {
  color: #a6b2c1 !important;
}
html.dark .overlay-related a {
  background: #161f2f !important;
  color: #7290d1 !important;
}
html.dark .overlay-related a:hover,
html.dark .overlay-related a:focus-visible {
  background: #0a1f45 !important;
}
html.dark .tile-filter button {
  background: #14181f !important;
  border: 1px solid #303a46 !important;
  color: #b5c1d1 !important;
}
html.dark .tile-filter button.active {
  background: #356ec5 !important;
  border-color: #356ec5 !important;
  color: #ffffff !important;
}
html.dark .weekly-card {
  border: 1px solid #303a46 !important;
  background: #14181f !important;
}
html.dark .weekly-card .weekly-slot {
  border: 1px solid #242e38 !important;
}
html.dark .weekly-card .weekly-slot.done {
  background: #1a3021 !important;
  border-color: #356c46 !important;
}
html.dark .badge {
  border: 1px solid #242e38 !important;
  background: #14181f !important;
}
html.dark .badge.earned {
  background: #3e3109 !important;
}
html.dark .badge .badge-desc,
html.dark .badge .badge-progress {
  color: #97a2af !important;
}
html.dark .app-nav-panel-all {
  color: #ffffff !important;
}
html.dark .mega-group {
  background: #131a29 !important;
}
html.dark .mega-title i {
  background: color-mix(in srgb, var(--g) 16%, #14181f) !important;
}
html.dark .mega-name {
  color: #c2cddc !important;
}
@media (hover: hover) {
  html.dark .mega-group .app-nav-panel-link:hover {
    background: #14181f !important;
  }
}
html.dark .mega-group .app-nav-panel-link.active .mega-name {
  color: #ffffff !important;
}
html.dark .mega-foot {
  border-top: 1px solid #1d2632 !important;
}
html.dark .diff-chip {
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .diff-chip:hover {
    color: #ffffff !important;
  }
}
html.dark .stats-table-wrap {
  background: #14181f !important;
}
html.dark .stats-table td {
  border-top: 1px solid #19222e !important;
  color: #b5c1d1 !important;
}
html.dark .stats-table tr.group-row td {
  background: #131a29 !important;
}
html.dark .account-banner {
  background: #14181f !important;
  border: 1px solid #112548 !important;
  color: #c2cddc !important;
}
html.dark .account-banner-close:hover {
  background: #161f2f !important;
}
html.dark .skip-link {
  color: #ffffff !important;
}
html.dark .coach {
  background: #08193b !important;
  border: 1px solid #112548 !important;
  color: #d5dde6 !important;
}
html.dark .coach-link {
  color: #7290d1 !important;
}
html.dark .coach-ok {
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .coach-ok:hover {
    background: #112548 !important;
  }
}
html.dark .share-card textarea {
  border: 1px solid #343f4e !important;
}
@media (max-width: 700px) {
  html.dark .head-status {
    color: #a6b2c1 !important;
  }
  html.dark .head-status b {
    color: #d5dde6 !important;
  }
  html.dark .head-status .hs-err.has {
    color: var(--error-color, #d16f65) !important;
  }
}
html.dark .game-tile-art {
  background: #121c2c !important;
}
html.dark .tbadge {
  background: #14181f !important;
  color: #a6b2c1 !important;
}
html.dark .tb-lvl-1 {
  background: #1c3926 !important;
  color: #a9e0ba !important;
}
html.dark .tb-lvl-2 {
  background: #4f3d0b !important;
  color: #f7e09f !important;
}
html.dark .tb-lvl-3 {
  background: #43140d !important;
  color: #dc8779 !important;
}
html.dark .tb-done {
  background: #1b3421 !important;
  color: #a9e0ba !important;
}
html.dark .tiles-empty {
  color: #98a3b0 !important;
}
html.dark .set-group {
  background: #14181f !important;
}
html.dark .set-seg {
  border: 1px solid #303a46 !important;
}
html.dark .set-seg button {
  background: #14181f !important;
  color: #b5c1d1 !important;
}
html.dark .set-seg button + button {
  border-left: 1px solid #303a46 !important;
}
html.dark .set-seg button.active {
  color: #ffffff !important;
}
@media (hover: hover) {
  html.dark .set-seg button:not(.active):hover {
    background: #161f2f !important;
  }
}
html.dark .set-btn {
  border: 1px solid #303a46 !important;
  background: #14181f !important;
  color: #b5c1d1 !important;
}
@media (hover: hover) {
  html.dark .set-btn:hover {
    background: #161f2f !important;
  }
}
html.dark .set-danger {
  color: #dc7670 !important;
  border-color: #602b26 !important;
}
html.dark .set-status {
  color: #9ad3b2 !important;
}
html.dark .start-grid .home-card,
html.dark .start-grid .daily-card,
html.dark .start-grid .weekly-card {
  background: #14181f !important;
}
html.dark .start-grid .home-card-streak {
  border: 1px dashed #c78d19 !important;
}
html.dark .start-grid .weekly-card .home-card-kicker {
  color: #f6db92 !important;
}
html.dark .seg {
  border: 1px solid #303a46 !important;
  background: #14181f !important;
}
html.dark .seg button {
  background: #14181f !important;
  color: #b5c1d1 !important;
}
html.dark .seg button + button {
  border-left: 1px solid #303a46 !important;
}
html.dark .seg button.active {
  color: #ffffff !important;
}
@media (hover: hover) {
  html.dark .seg button:not(.active):hover {
    background: #161f2f !important;
  }
}

/* --- puzzles.css --- */
html.dark {
  --pz-fill: #bec9d8;
  --pz-cross: #9aa7b8;
  --pz-hint: #356ec5;
  --pz-hint-ctx: #49360a;
}
html.dark .puzzle-info-note {
  color: #a6b2c1 !important;
}
html.dark .pz-tool-btn {
  background: #161f2f !important;
  border: 1px solid #1f2b3b !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .pz-tool-btn:hover {
    background: #1b2637 !important;
  }
}
html.dark .pz-tool-btn.active {
  color: #ffffff !important;
}
html.dark .nz-wrap {
  background: #14181f !important;
}
html.dark .nz-cell {
  background: #14181f !important;
}
html.dark .nz-cell.error {
  background: #40120d !important;
}
html.dark .lo-board {
  background: #14181f !important;
}
html.dark .lo-lamp.on {
  background: #b7910a !important;
}
html.dark .mm-wrap {
  background: #14181f !important;
  --mm-c0: #ba3027 !important;
  --mm-c1: #356ec5 !important;
  --mm-c2: #2e9e57 !important;
  --mm-c3: #c89c17 !important;
  --mm-c4: #6435a2 !important;
  --mm-c5: #ca6e19 !important;
  --mm-c6: #1fa8a8 !important;
  --mm-c7: #99225c !important;
}
html.dark .mm-peg {
  color: rgba(255, 255, 255, 0.92) !important;
}
html.dark .mm-peg.c3 {
  color: #fbf3cf !important;
}
html.dark .mm-clue {
  background: #171d29 !important;
}
html.dark .mm-fb .dot.white {
  background: #14181f !important;
}
html.dark .mm-slot {
  border: 2px dashed #2e3845 !important;
}
html.dark .mm-slot.filled {
  background: #171d29 !important;
}
html.dark .mm-cell {
  background: #171d29 !important;
}
@media (hover: hover) {
  html.dark .mm-cell:hover {
    background: #182333 !important;
  }
}
html.dark .mm-cell.chosen {
  background: #182333 !important;
}
html.dark .mm-cell.error {
  background: #40120d !important;
}
html.dark .ak-cell.white {
  background: #14181f !important;
}
html.dark .ak-cell.white.lit {
  background: #5d510d !important;
}
html.dark .ak-cell.black {
  color: #ffffff !important;
}
html.dark .ak-cell.black.done {
  color: #8993a2 !important;
}
html.dark .ak-cell.clash {
  background: #40120d !important;
}
html.dark .hs-wrap {
  background: #14181f !important;
}
html.dark .hx-dot {
  fill: #212834 !important;
}
html.dark .hs-guide {
  stroke: #242c38 !important;
}
html.dark .hs-island circle {
  fill: #14181f !important;
}
html.dark .hs-island.done circle {
  fill: #1c3922 !important;
}
html.dark .hs-island.over circle {
  fill: #40120d !important;
}
html.dark .hs-island.hint-context circle {
  stroke: #c78d19 !important;
}
html.dark .hs-island text {
  fill: #d5dde6 !important;
}
html.dark .ht-board {
  background: #14181f !important;
}
html.dark .ht-cell {
  background: #171d29 !important;
}
html.dark .ht-cell.black {
  color: #96a0ae !important;
}
html.dark .sl-wrap {
  background: #14181f !important;
}
html.dark .sl-clue {
  fill: #d5dde6 !important;
}
html.dark .sl-clue.done {
  fill: #3d4856 !important;
}
html.dark .sl-guide {
  stroke: #222933 !important;
}
html.dark .sl-ctx-dot {
  fill: #c78d19 !important;
}
html.dark .mm-palette-btn {
  background: #171d29 !important;
}
@media (hover: hover) {
  html.dark .mm-palette-btn:hover {
    background: #182333 !important;
  }
}
html.dark .mm-msg {
  color: #f6d492 !important;
}
html.dark .sk-board {
  background: #14181f !important;
}
html.dark .sk-clue {
  color: #a6b2c1 !important;
}
html.dark .sk-cell {
  background: #171d29 !important;
}
html.dark .sk-cell.given {
  background: #1d2632 !important;
}
html.dark .sk-pad button {
  background: #161f2f !important;
}
@media (hover: hover) {
  html.dark .sk-pad button:hover {
    background: #15253c !important;
  }
}
html.dark .sk-pad button.active {
  color: #ffffff !important;
}
html.dark .sk-pad button:disabled {
  background: #161f2f !important;
}
html.dark .sb-cell .sb-no {
  color: rgba(213, 221, 230, 0.55) !important;
}
html.dark .sb-cell.star::after {
  color: #f2c561 !important;
}
html.dark .sb-r0 {
  background: #40120d !important;
}
html.dark .sb-r1 {
  background: #0f213f !important;
}
html.dark .sb-r2 {
  background: #1c3922 !important;
}
html.dark .sb-r3 {
  background: #513f0c !important;
}
html.dark .sb-r4 {
  background: #26123e !important;
}
html.dark .sb-r5 {
  background: #4c2d0e !important;
}
html.dark .sb-r6 {
  background: #1e4040 !important;
}
html.dark .sb-r7 {
  background: #42132c !important;
}
html.dark .sb-r8 {
  background: #3c4423 !important;
}
html.dark .sb-r9 {
  background: #2a333f !important;
}
html.dark .nk-cell {
  background: #14181f !important;
}
html.dark .nk-cell.clue {
  background: #171d29 !important;
}
html.dark .ms-pearl.white {
  fill: #14181f !important;
}
html.dark .ms-ctx {
  stroke: #c78d19 !important;
}
html.dark .rh-wrap {
  background: #14181f !important;
}
html.dark .rh-board {
  background-color: #1e252f !important;
  background-image: linear-gradient(#2f3744 1px, transparent 1px),
    linear-gradient(90deg, #2f3744 1px, transparent 1px) !important;
}
html.dark .rh-exit {
  background: #1e252f !important;
}
html.dark .rh-car {
  color: rgba(255, 255, 255, 0.92) !important;
}
html.dark .rh-ghost {
  background: rgba(53, 110, 197, 0.12) !important;
}
html.dark .rh-car.c0 {
  background: #ba3027 !important;
}
html.dark .rh-car.c1 {
  background: #356ec5 !important;
}
html.dark .rh-car.c4 {
  background: #6435a2 !important;
}
html.dark .rh-car.c5 {
  background: #ca6e19 !important;
}
html.dark .rh-car.c7 {
  background: #99225c !important;
}
html.dark .ei-wrap {
  background: #14181f !important;
}
html.dark .ei-clues li {
  color: #b4c3d1 !important;
}
html.dark .ei-mat th {
  color: #a6b2c1 !important;
  background: #14181f !important;
}
html.dark .ei-mat-group {
  border-bottom: 1px solid #333c49 !important;
}
html.dark .ei-mat-col {
  border-left: 1px solid #212834 !important;
}
html.dark .ei-mat-row {
  border-top: 1px solid #212834 !important;
}
html.dark .ei-mat-col.hl,
html.dark .ei-mat-row.hl {
  background: #122641 !important;
}
html.dark .ei-mat-cell {
  border: 1px solid #212834 !important;
  background: #171d29 !important;
}
html.dark .ei-mat-cell.hl {
  background: #112039 !important;
}
html.dark .ei-mat-cell.dim {
  background: #1e232d !important;
}
html.dark .ei-mat-cell.yes {
  color: #91deb1 !important;
  background: #1a3725 !important;
}
html.dark .ei-mat-cell.no {
  color: #c17871 !important;
  background: #341411 !important;
}
html.dark .ei-group {
  background: #171d29 !important;
  color: #b4c3d1 !important;
}
html.dark .ei-group > b {
  color: #a6b2c1 !important;
}
html.dark .ei-chip {
  background: #14181f !important;
  border: 1px solid #212834 !important;
}
html.dark .ei-mat-tools {
  background: #14181f !important;
}
html.dark .pz-zoom-btn {
  border: 1px solid #1f2b3b !important;
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
@media (hover: hover) {
  html.dark .pz-zoom-btn:hover:not(:disabled) {
    background: #1b2637 !important;
  }
}
html.dark .level-note {
  color: #a6b2c1 !important;
}
html.dark .hint-more {
  background: #14181f !important;
}
@media (hover: hover) {
  html.dark .hint-more:hover {
    background: #0d1a34 !important;
  }
}
html.dark .lo-board.torus {
  outline: 3px dashed #495d77 !important;
}
html.dark .sb-count.done {
  color: #80d19d !important;
}
html.dark .nk-cell.auto-sea:not(.sea) {
  background: #1a2d44 !important;
}
html.dark .nk-cell.clue.done::after {
  color: #80d19d !important;
}
html.dark .rh-car:focus-visible {
  outline: 3px solid #14181f !important;
}
html.dark .su-cell {
  background: #14181f !important;
}
html.dark .su-cell.given {
  background: #1b222c !important;
}
html.dark .su-cell.same {
  background: #122641 !important;
}
html.dark .su-cell.hint-ctx {
  background: #47380a !important;
}
html.dark .su-cell.error,
html.dark .su-cell.error.same,
html.dark .su-cell.error.peer {
  background: #3d0d0d !important;
}
html.dark .ic-wrap {
  background: #14181f !important;
}
html.dark .ic-board {
  background-color: #102e3f !important;
  background-image: linear-gradient(#1d4153 1px, transparent 1px),
    linear-gradient(90deg, #1d4153 1px, transparent 1px) !important;
}
html.dark .ic-ghost {
  background: rgba(53, 110, 197, 0.12) !important;
}
html.dark .dr-wrap {
  background: #14181f !important;
}
html.dark .dr-board {
  background: #2c3642 !important;
}
html.dark .dr-cell {
  background: #171d29 !important;
}
html.dark .dr-cell.exit {
  background: #193724 !important;
}
html.dark .dr-cell.door.closed {
  color: #ffffff !important;
}
html.dark .dr-cell.c0 {
  --dc: #ba3027;
}
html.dark .dr-cell.c1 {
  --dc: #356ec5;
}
html.dark .dr-cell.c2 {
  --dc: #2e9e57;
}
html.dark .dr-cell.c3 {
  --dc: #c98a00;
}
html.dark .tg-wrap {
  background: #14181f !important;
}
html.dark .tg-cell {
  background: #161f2f !important;
}
html.dark .tg-cell.preview-bad {
  background: rgba(186, 48, 39, 0.4) !important;
}
html.dark .tg-piece {
  background: #161f2f !important;
}
@media (hover: hover) {
  html.dark .tg-piece:hover {
    background: #15253c !important;
  }
}
html.dark .tg-piece.active {
  background: #14181f !important;
}
html.dark .tg-cell.p0,
html.dark .tg-mini-cell.p0 {
  background: #ba3027 !important;
}
html.dark .tg-cell.p1,
html.dark .tg-mini-cell.p1 {
  background: #356ec5 !important;
}
html.dark .tg-cell.p4,
html.dark .tg-mini-cell.p4 {
  background: #6435a2 !important;
}
html.dark .tg-cell.p5,
html.dark .tg-mini-cell.p5 {
  background: #ca6e19 !important;
}
html.dark .tg-cell.p7,
html.dark .tg-mini-cell.p7 {
  background: #99225c !important;
}
html.dark .sh-wrap {
  background: #14181f !important;
}
html.dark .sh-view-title {
  color: #8993a2 !important;
}
html.dark .sh-top div {
  background: #161f2f !important;
}
html.dark .sh-top div.on {
  background: #356ec5 !important;
}
html.dark .sh-top div.on.done {
  background: #3d4856 !important;
}
html.dark .sh-bar i {
  background: #161f2f !important;
}
html.dark .sh-bar i.on {
  background: #356ec5 !important;
}
html.dark .sh-bar b {
  color: #a6b2c1 !important;
}
html.dark .sh-bar.done i.on {
  background: #3d4856 !important;
}
html.dark .sh-cell {
  background: #171d29 !important;
}
html.dark .sh-cell .sh-stack {
  background: rgba(53, 110, 197, 0.22) !important;
}
html.dark .sh-cell.given {
  background: #1d2632 !important;
}
html.dark .sh-info {
  color: #a6b2c1 !important;
}
html.dark .sh-siderow i {
  background: #161f2f !important;
}
html.dark .sh-siderow i.on {
  background: #356ec5 !important;
}
html.dark .sh-siderow b {
  color: #a6b2c1 !important;
}
html.dark .sh-siderow.done i.on {
  background: #3d4856 !important;
}
html.dark .ic-sand {
  background: rgba(146, 112, 49, 0.55) !important;
}
html.dark .mg-wrap {
  background: #14181f !important;
}
html.dark .mg-cell {
  background: #171d29 !important;
}
html.dark .mg-cell.given {
  background: #1d2632 !important;
}
html.dark .mg-cell.same {
  background: #122641 !important;
}
html.dark .mg-op {
  color: #a6b2c1 !important;
}
html.dark .mg-op.unknown {
  background: #47380a !important;
  color: #f2c561 !important;
}
html.dark .mg-res.ok .mg-res-c {
  color: #9ddfb3 !important;
}
html.dark .sy-res {
  background: #161f2f !important;
  color: #96a0ae !important;
}
html.dark .sy-res.ok {
  background: #1f4029 !important;
  color: #9ddfb3 !important;
}
html.dark .sy-wrap {
  background: #14181f !important;
}
html.dark .sy-op,
html.dark .sy-num {
  color: #a6b2c1 !important;
}
html.dark .sy-chip {
  background: #171d29 !important;
}
html.dark .sy-chip em {
  color: #a6b2c1 !important;
}
html.dark .sy-chip.given {
  background: #1d2632 !important;
}
html.dark .sy-leg {
  background: #161f2f !important;
}
html.dark .sy-leg em {
  color: #a6b2c1 !important;
}
html.dark .sy-pad .num-btn.active {
  color: #ffffff !important;
}
html.dark .sy-note-row.active {
  background: #161f2f !important;
}
html.dark .sy-note {
  background: #122641 !important;
}
html.dark .sy-note.set {
  background: #1f4029 !important;
  color: #9ddfb3 !important;
}
html.dark .sh-sum {
  color: #a6b2c1 !important;
}
html.dark .sh-colsums div {
  color: #a6b2c1 !important;
}
html.dark .sh-total {
  color: #a6b2c1 !important;
}
html.dark .bb-rank-name {
  color: #a6b2c1 !important;
}
html.dark .bb-bar {
  background: #1f2b3b !important;
}
html.dark .bb-mark {
  background: #4e5b6b !important;
}
html.dark .bb-input {
  color: #d5dde6 !important;
}
html.dark .bb-in-center {
  color: #f1b854 !important;
}
html.dark .bb-msg {
  color: #a6b2c1 !important;
}
html.dark .bb-msg.good {
  color: #9ddfb3 !important;
}
html.dark .bb-msg.pan {
  color: #f1b854 !important;
}
html.dark .bb-hex {
  background: #1f2b3b !important;
  color: #d5dde6 !important;
}
html.dark .bb-hex.bb-center {
  background: #c89c17 !important;
}
html.dark .bb-btn {
  border: 1px solid #1f2b3b !important;
  background: #161f2f !important;
  color: #a6b2c1 !important;
}
html.dark .bb-btn.bb-submit {
  color: #ffffff !important;
}
@media (hover: hover) {
  html.dark .bb-btn:hover {
    background: #1b2637 !important;
  }
}
html.dark .bb-goalline {
  background: #193322 !important;
  color: #a9e0bc !important;
}
html.dark .bb-found li {
  color: #d5dde6 !important;
}
html.dark .bb-found li.pan {
  color: #f1b854 !important;
}
html.dark .su-cell.hint-focus {
  background: #68510f !important;
}
html.dark .hint-step-active {
  background: #49360a !important;
}
html.dark .hint-step-note {
  color: #98a3b0 !important;
}
@media (hover: hover) {
  html.dark .hint-step-link:hover {
    background: #49360a !important;
  }
}
html.dark .pz-keys {
  color: var(--muted, #8a95a2) !important;
}
html.dark .sk-cell.dup,
html.dark .su-cell.dup,
html.dark .board .cell.dup,
html.dark .sh-cell.dup,
html.dark .mg-cell.dup {
  background-image: linear-gradient(to top, #c78d19 4px, transparent 4px) !important;
}
html.dark .sk-cell.same,
html.dark .sh-cell.same {
  background: #122641 !important;
}
html.dark .tg-cell.dead:not(.filled) {
  background: repeating-linear-gradient(45deg, #411f1b, #411f1b 4px, #161f2f 4px, #161f2f 8px) !important;
}

/* --- site.css --- */
html.dark .btn {
  color: #ffffff !important;
}
html.dark .btn-ghost {
  background: #14181f !important;
}
html.dark .btn-ghost:hover,
html.dark .btn-ghost:focus-visible {
  background: #0b1833 !important;
}
html.dark .mini-grid {
  background: #14181f !important;
}
html.dark .fact {
  background: #14181f !important;
}
html.dark .card {
  background: #14181f !important;
}
html.dark .pz {
  background: #14181f !important;
}
@media (hover: hover) {
  html.dark .pz:hover {
    border-color: #172c51 !important;
  }
}
html.dark .step {
  background: #14181f !important;
}
html.dark .step::before {
  color: #ffffff !important;
}
html.dark .band {
  background: linear-gradient(135deg, #2f5fc4, #1e52b3) !important;
  color: #ffffff !important;
}
html.dark .site .band h2 {
  color: #ffffff !important;
}
html.dark .site .band a.btn {
  background: #14181f !important;
}
html.dark .site .band a.btn:hover {
  background: #08193b !important;
}
html.dark .site .band a.btn-ghost {
  color: #ffffff !important;
  border: 2px solid rgba(20, 24, 31, 0.55) !important;
}
html.dark .site .band a.btn-ghost:hover {
  background: rgba(20, 24, 31, 0.12) !important;
}
html.dark .band li::before {
  background: rgba(20, 24, 31, 0.2) !important;
}
html.dark .panel {
  background: #14181f !important;
}
html.dark .panel li {
  color: #b5c1d1 !important;
}
html.dark .panel li::before {
  color: #9de0b3 !important;
}
html.dark .prose p {
  color: #c0cbd8 !important;
}
html.dark .quote {
  background: #14181f !important;
}
html.dark .faq details {
  background: #14181f !important;
}
html.dark .faq details p {
  color: #b5c1d1 !important;
}
html.dark .cta {
  background: #14181f !important;
}
html.dark .plain-p {
  color: #b5c1d1 !important;
}
html.dark .learn-path {
  background: #14181f !important;
}
html.dark .learn-path a {
  background: #161f2f !important;
}
html.dark .learn-path a:hover,
html.dark .learn-path a:focus-visible {
  background: #0a1f45 !important;
}
html.dark .learn-path li.next a {
  color: #ffffff !important;
}
html.dark .learn-path li.done a {
  background: #1b3626 !important;
}
html.dark .lp-num {
  background: #14181f !important;
}
html.dark .learn-path li.done .lp-num {
  color: #ffffff !important;
}

/* --- rules.css --- */
html.dark {
  --pz-fill: #bec9d8;
  --pz-cross: #9aa7b8;
  --pz-hint: #356ec5;
}
html.dark .rules-card p,
html.dark .rules-card li {
  color: #b4c3d1 !important;
}
html.dark .rules-card .rx-lead {
  color: #d5dde6 !important;
}
html.dark .rules-card .rx-note {
  background: #131e2e !important;
}
html.dark .rules-card .rx-close-row {
  background: linear-gradient(to bottom, rgba(20, 24, 31, 0), #14181f 28%) !important;
}
html.dark .rx-fig figcaption {
  color: #8a95a2 !important;
}
html.dark .rx-fig figcaption b {
  color: #b4c3d1 !important;
}
html.dark .rx-ok figcaption::before {
  color: #80d19d !important;
}
html.dark .rx-grid {
  background: #14181f !important;
}
html.dark .rx-c.wall {
  color: #ffffff !important;
}
html.dark .rx-c.fill {
  color: #ffffff !important;
}
html.dark .rx-c.lit {
  background: #63560e !important;
}
html.dark .rx-c.star::after {
  color: #f1c858 !important;
}
html.dark .rx-c.bad {
  background: #40120d !important;
}
html.dark .rx-c.ok {
  background: #1c3724 !important;
}
html.dark .rx-c.sea {
  background: #1e4d7d !important;
}
html.dark .rx-c.land {
  background: #14181f !important;
}
html.dark .rx-c.black {
  color: #ffffff !important;
}
html.dark .rx-c.sm {
  color: #8a95a2 !important;
}
html.dark .rx-c.r0 {
  background: #40120d !important;
}
html.dark .rx-c.r1 {
  background: #0a2545 !important;
}
html.dark .rx-c.r2 {
  background: #1c3724 !important;
}
html.dark .rx-c.r3 {
  background: #56440c !important;
}
html.dark .rx-c.r4 {
  background: #261738 !important;
}
html.dark .rx-c.r5 {
  background: #4d2b0b !important;
}
html.dark .rx-c .tag {
  color: #a6b2c1 !important;
}
html.dark .rx-sign {
  color: #b4c3d1 !important;
}
html.dark .rx-tbl {
  background: #14181f !important;
}
html.dark .rx-nono td.nzc.hl {
  background: #49360a !important;
}
html.dark .rx-kk td.k {
  background: linear-gradient(to top right, transparent calc(50% - 1px), #2e3845 calc(50% - 1px), #2e3845 calc(50% + 1px), transparent calc(50% + 1px)),
    #2b3a4f !important;
}
html.dark .rx-kk td.k .kr {
  color: #ffffff !important;
}
html.dark .rx-kk td.k .kc {
  color: #ffffff !important;
}
html.dark .rx-kk td.w {
  background: #14181f !important;
}
html.dark .rx-peg {
  border: 1px solid rgba(0, 0, 0, 0.25) !important;
}
html.dark .rx-peg.c0 {
  background: #ba3027 !important;
}
html.dark .rx-peg.c1 {
  background: #356ec5 !important;
}
html.dark .rx-peg.c3 {
  background: #c89c17 !important;
}
html.dark .rx-peg.c4 {
  background: #6435a2 !important;
}
html.dark .rx-peg.c5 {
  background: #ca6e19 !important;
}
html.dark .rx-fb i.w {
  background: #14181f !important;
}
html.dark .rx-fb i.n {
  border-color: #1f2b3b !important;
}
html.dark .rx-row .lbl {
  color: #8a95a2 !important;
}
html.dark .rx-lamp-on {
  background: #b98e13 !important;
}
html.dark .rx-lamps {
  background: #14181f !important;
}
html.dark .rx-lamps i.press::after {
  color: #ffffff !important;
}
html.dark .rx-bar {
  background: #2e3845 !important;
  color: #b4c3d1 !important;
}
html.dark .rx-bar.seen {
  background: #356ec5 !important;
  color: #ffffff !important;
}
html.dark .rx-barline .cnt {
  color: #d5dde6 !important;
}
html.dark .rx-park {
  background: #161f2f !important;
}
html.dark .rx-park .v {
  border: 2px solid rgba(0, 0, 0, 0.25) !important;
}
html.dark .rx-svg {
  background: #14181f !important;
}
html.dark .rx-svg text {
  fill: #d5dde6 !important;
}

/* --- legal.css --- */
html.dark .legal-note {
  background: #47380a !important;
}

/* --- futoshiki.css --- */
html.dark .cell.given {
  background: #161f2f !important;
}

/* --- kakuro.css --- */
html.dark .kakuro-clue {
  color: #ffffff !important;
}

/* --- tools/dark-overrides.css --- */
/* Handgepflegte Ausnahmen fuer das dunkle Design und der Modus "Hoher Kontrast". */

/* Linien-Variablen sind dunkel UND werden teils als Textfarbe genutzt (Vorgaben): im dunklen Design aufhellen. */
html.dark {
  --line-thin: #46546a;
  --line-thick: #a7b8cc;
  --cage-line: #b4c3d6;
}
/* Bretter, deren Gitter aus dem Hintergrund zwischen den Zellen (gap) besteht: duenne Linien gedaempft,
   dicke (Bloecke/Regionen/Rand) hell - sonst sind beide gleich hell und die Struktur verschwindet. */
html.dark .su-board, html.dark .sb-board { background: var(--line-thin) !important; }
html.dark .su-cell.box-left { box-shadow: -3px 0 0 var(--line-thick) !important; }
html.dark .su-cell.box-top { box-shadow: 0 -3px 0 var(--line-thick) !important; }
html.dark .su-cell.box-left.box-top { box-shadow: -3px 0 0 var(--line-thick), 0 -3px 0 var(--line-thick) !important; }

/* Weitere Gitter: Linien zwischen den Zellen sichtbar machen (die automatische Umrechnung macht helle Linien fast so dunkel wie den Hintergrund). */
html.dark .nk-board, html.dark .ak-board, html.dark .dr-board { background: var(--line-thin) !important; }
html.dark .sk-cell { outline: 1px solid var(--line-thin); outline-offset: -1px; }
html.dark .tg-cell:not(.hole) { outline: 1px solid var(--line-thin); outline-offset: -1px; }
html.dark .ic-board {
  background-image:
    linear-gradient(#3d6a86 1px, transparent 1px),
    linear-gradient(90deg, #3d6a86 1px, transparent 1px) !important;
}
html.dark .sl-guide { stroke: #4c5b70 !important; }
html.dark .sl-dot { fill: #9fb0c4 !important; }

/* Einstein-Matrix: Gruppen-Trenner (dick) und Zellraster (duenn). */
html.dark .ei-mat-group { border-bottom-color: var(--line-thin) !important; border-left-color: var(--line-thick) !important; }
html.dark .ei-mat-col { border-left-color: var(--line-thin) !important; }
html.dark .ei-mat-col.first { border-left-color: var(--line-thick) !important; }
html.dark .ei-mat-rowgroup { border-top-color: var(--line-thick) !important; }
html.dark .ei-mat-row { border-top-color: var(--line-thin) !important; box-shadow: 1px 0 0 var(--line-thin) !important; }
html.dark .ei-mat-row.first { border-top-color: var(--line-thick) !important; }
html.dark .ei-mat-cell { border-color: var(--line-thin) !important; }
html.dark .ei-mat-cell.first { border-left-color: var(--line-thick) !important; }
html.dark .ei-mat-cell.top { border-top-color: var(--line-thick) !important; }
html.dark .ei-mat-cell.last { border-right-color: var(--line-thick) !important; }
html.dark .ei-mat-cell.bottom { border-bottom-color: var(--line-thick) !important; }

/* Hoher Kontrast: kraeftigere Linien, Rahmen und Fokus. */
html.hc {
  --line-thin: #64748b;
  --line-thick: #0f172a;
  --cage-line: #0f172a;
  --note-color: #46566b;
}
html.hc.dark {
  --line-thin: #8196ae;
  --line-thick: #f1f5f9;
  --cage-line: #f1f5f9;
  --note-color: #c3cdd9;
}
html.hc button, html.hc .diff-btn, html.hc .btn, html.hc .app-nav-link { border: 2px solid currentColor; }
html.hc :focus-visible { outline: 4px solid #f59e0b; outline-offset: 2px; }
html.hc body { color: #000; }
html.hc.dark body { color: #fff !important; }

/* Heller Akzenttext (Links, Kennzahlen, Eyebrows) - Flaechen behalten --accent. */
html.dark { --accent-text: #8db4ff; }
html.dark .site a, html.dark .account-banner-more { color: var(--accent-text) !important; }
html.dark .site a.btn, html.dark .site a.btn:hover { color: #fff !important; }
html.dark .site a.btn-ghost { color: var(--accent-text) !important; }
html.dark .mm-peg.c3 { color: #3d3200 !important; }
html.dark .bb-hex.bb-center { color: #3d3200 !important; }

/* Perlen (Masyu): Schwarz/Weiss tragen Bedeutung - nicht umrechnen, nur hell umranden. */
html.dark .ms-pearl { stroke: #cfd8e4 !important; }
html.dark .ms-pearl.white { fill: #f4f6fa !important; }
html.dark .ms-pearl.black { fill: #06090e !important; }

/* Akari: Mauern deutlich dunkler als begehbare Felder. */
html.dark .ak-cell.white { background: #2b3647 !important; }
html.dark .ak-cell.white.lit { background: #5a5128 !important; }
html.dark .ak-cell.black { background: #04070b !important; }

/* Kakuro: Waende tiefschwarz, Summen-Chips dunkel mit hellem Text (nutzen sonst --line-thick). */
html.dark .cell.kakuro-black { background: #04070b !important; border-color: #04070b !important; }
html.dark .kakuro-clue { background: #2d3b50 !important; color: #e6edf6 !important; }

/* Einstellungsseite: aktive Auswahl im dunklen Design klar vom Rest abheben. */
html.dark .set-seg button.active { background: #3a6fd8 !important; color: #fff !important; }

html.dark .weekly-register { color: #8fb4ff !important; }
