/* ─────────────────────────────────────────────────────────────────────────
   Vestaboard Controller — Stylesheet
   Schriftarten: IBM Plex Mono (Board + Code), Outfit (UI)
───────────────────────────────────────────────────────────────────────── */

:root {
  --bg:           #0d0d0b;
  --surface:      #161614;
  --surface-2:    #1e1e1c;
  --border:       #2a2a26;
  --border-hover: #3d3d38;
  --amber:        #ef9f27;
  --amber-dim:    #7d5514;
  --amber-dark:   #291e08;
  --text:         #e8e6e0;
  --text-muted:   #888880;
  --text-dim:     #555550;
  --green:        #4ade80;
  --green-dim:    #1f6b3a;
  --green-dark:   #0d2618;
  --red:          #f87171;
  --radius:       8px;
  --radius-sm:    4px;
}

/* ── Reset ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Base ────────────────────────────────────────────────────────────── */
body {
  font-family: 'Outfit', sans-serif;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(74,222,128,0.04) 0%, transparent 60%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
}

code {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--amber);
  background: var(--amber-dark);
  padding: 1px 5px;
  border-radius: 3px;
}

/* ── Header ──────────────────────────────────────────────────────────── */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  -webkit-app-region: drag;
  user-select: none;
}
/* Platz für den fixierten Header reservieren */
body { padding-top: 58px; }
/* Im Electron-Fenster Platz für die Ampel-Buttons links */
html.electron header { padding-left: 92px; }
/* Interaktive Elemente im Header dürfen nicht ziehen */
header button,
header input,
header a { -webkit-app-region: no-drag; }

.logo {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 15px;
  font-weight: 500;
  color: var(--green);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.status-badge {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--text-muted);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-dim);
  transition: background 0.3s, box-shadow 0.3s;
}
.status-dot.connected {
  background: var(--green);
  box-shadow: 0 0 8px rgba(74,222,128,0.6);
  animation: pulse 2.4s ease-in-out infinite;
}
.status-dot.error {
  background: var(--red);
  box-shadow: 0 0 8px rgba(248,113,113,0.6);
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 6px rgba(74,222,128,0.5); }
  50%      { box-shadow: 0 0 12px rgba(74,222,128,0.9); }
}

/* ── Main layout ──────────────────────────────────────────────────────── */
main {
  max-width: 1480px;
  margin: 0 auto;
  padding: 24px 20px 40px;
  display: grid;
  grid-template-columns: 290px 1fr 290px;
  gap: 16px;
  align-items: start;
}

.sidebar, .right-sidebar {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 70px;
}

.content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

/* ── Color/Symbol Picker ──────────────────────────────────────────────── */
.picker-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}
.picker-btn {
  width: 28px;
  height: 28px;
  padding: 0;
  font-size: 11px;
  font-weight: 600;
  font-family: 'IBM Plex Mono', monospace;
  border-radius: 4px;
  border: 1px solid var(--border-hover);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.picker-btn.col-red    { background: #c8332b; }
.picker-btn.col-orange { background: #d97a1f; }
.picker-btn.col-yellow { background: #d4b820; color:#000; }
.picker-btn.col-green  { background: #2f9e44; }
.picker-btn.col-blue   { background: #2b5fc8; }
.picker-btn.col-violet { background: #7a3fb5; }
.picker-btn.col-white  { background: #e8e6e0; color:#000; }
.picker-btn.col-eraser { background: #2a2a26; color: var(--text); font-size: 14px; line-height: 1; }
.picker-btn:hover     { filter: brightness(1.15); }
.picker-btn.active {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

#paintToggle.selected {
  background: var(--green-dark);
  border-color: var(--green-dim);
  color: var(--green);
}

/* Cursor in Pinsel-Modus */
#boardDisplay.painting .tile { cursor: crosshair; }
#boardDisplay.painting .tile:hover {
  outline: 1.5px solid var(--green);
  outline-offset: 1px;
}

/* Verschieben — Default-Verhalten wenn Pinsel aus ist */
#boardDisplay .tile { cursor: cell; }
#boardDisplay.painting .tile { cursor: crosshair; }
#boardDisplay .tile.selected:not(.painting *) { cursor: move; }
#boardDisplay .tile.selected {
  outline: 2px solid var(--green);
  outline-offset: 1px;
  z-index: 10;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.5);
}
#boardDisplay .tile.move-preview {
  outline: 2px dashed var(--green);
  outline-offset: 1px;
  z-index: 9;
  box-shadow: 0 0 10px rgba(74, 222, 128, 0.4);
}

/* Context-Menü */
.context-menu {
  position: fixed;
  background: linear-gradient(180deg, var(--surface) 0%, #131310 100%);
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  padding: 6px;
  z-index: 200;
  min-width: 180px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.6);
  animation: ctxIn 0.12s ease-out;
}
@keyframes ctxIn {
  from { opacity: 0; transform: scale(0.95); }
  to   { opacity: 1; transform: scale(1); }
}
.ctx-color-row {
  display: flex;
  gap: 4px;
  padding: 4px;
}
.ctx-color {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,0.1);
  cursor: pointer;
  padding: 0;
  transition: transform 0.1s;
}
.ctx-color:hover { transform: scale(1.18); }
.ctx-color.col-red    { background: linear-gradient(180deg, #e04039, #c0312a); }
.ctx-color.col-orange { background: linear-gradient(180deg, #f29128, #d97a1f); }
.ctx-color.col-yellow { background: linear-gradient(180deg, #ead023, #c8aa1c); }
.ctx-color.col-green  { background: linear-gradient(180deg, #3ab94e, #2f9e44); }
.ctx-color.col-blue   { background: linear-gradient(180deg, #3672e8, #2b5fc8); }
.ctx-color.col-violet { background: linear-gradient(180deg, #9450d4, #7a3fb5); }
.ctx-color.col-white  { background: linear-gradient(180deg, #faf6eb, #c8c4ba); }

.ctx-sep {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}
.ctx-item {
  padding: 6px 12px;
  font-size: 12px;
  color: var(--text);
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.1s;
}
.ctx-item:hover { background: var(--surface-2); }

/* ── History-Items ───────────────────────────────────────────────────── */
#historyList {
  max-height: calc(100vh - 200px);
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-width: none;            /* Firefox */
  -ms-overflow-style: none;         /* IE/Edge alt */
}
#historyList::-webkit-scrollbar { display: none; }  /* Chrome/Safari */
.history-item {
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s;
}
.history-item:hover {
  background: var(--surface-2);
  border-color: var(--border-hover);
}
.hist-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.hist-time {
  font-family: 'IBM Plex Mono', monospace;
  color: var(--text-dim);
  white-space: nowrap;
}
.hist-attr {
  font-style: italic;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.hist-star, .hist-action {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 14px;
  line-height: 1;
  padding: 0 2px;
  cursor: pointer;
  transition: color 0.15s, transform 0.12s;
}
.hist-star:hover, .hist-action:hover { color: var(--green); transform: scale(1.2); }
.hist-star.active { color: var(--green); }

#favFilter.selected {
  background: var(--green-dark);
  border-color: var(--green-dim);
  color: var(--green);
}

/* Mini-Board (Thumbnail in History) */
.mini-board {
  background: #0a0907;
  padding: 3px 4px;
  border-radius: 4px;
  border: 1px solid rgba(0,0,0,0.6);
  display: flex;
  flex-direction: column;
  gap: 1px;
  box-shadow: inset 0 1px 4px rgba(0,0,0,0.5);
  width: fit-content;
  max-width: 100%;
  box-sizing: border-box;
}
.mini-board-row {
  display: flex;
  gap: 1px;
}
.mini-tile {
  width: 9px;
  height: 12px;
  flex-shrink: 0;
  background: linear-gradient(180deg, #2a2620 0%, #1f1c17 48%, #100e0b 50%, #1a1714 52%, #221f1a 100%);
  border-radius: 1px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 7px;
  font-weight: 600;
  color: #f5f1e6;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.mini-tile.col-red    { background: linear-gradient(180deg, #e04039 0%, #c0312a 48%, #8a1f1a 52%, #b02822 100%); }
.mini-tile.col-orange { background: linear-gradient(180deg, #f29128 0%, #d97a1f 48%, #9b5715 52%, #c66c1a 100%); }
.mini-tile.col-yellow { background: linear-gradient(180deg, #ead023 0%, #c8aa1c 48%, #8e7913 52%, #b89818 100%); }
.mini-tile.col-green  { background: linear-gradient(180deg, #3ab94e 0%, #2f9e44 48%, #1d6a2c 52%, #2a8a3d 100%); }
.mini-tile.col-blue   { background: linear-gradient(180deg, #3672e8 0%, #2b5fc8 48%, #1c3f8a 52%, #2754ad 100%); }
.mini-tile.col-violet { background: linear-gradient(180deg, #9450d4 0%, #7a3fb5 48%, #51297a 52%, #6a35a0 100%); }
.mini-tile.col-white  { background: linear-gradient(180deg, #faf6eb 0%, #e8e6e0 48%, #b8b4aa 52%, #d4d0c4 100%); }
.mini-tile.col-black  { background: linear-gradient(180deg, #1f1d1a 0%, #14120f 48%, #050505 52%, #0e0c0a 100%); }
.mini-tile.col-filled { background: linear-gradient(180deg, #dad6c8 0%, #c0bcaf 48%, #908c80 52%, #ada99c 100%); }

/* Hover-Effekt: Mini-Board skalieren + grünes Glow */
.mini-board {
  transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}
.history-item:hover .mini-board,
.template-item:hover .mini-board {
  transform: scale(1.06);
  box-shadow:
    inset 0 1px 4px rgba(0,0,0,0.5),
    0 0 18px rgba(74, 222, 128, 0.35);
}

/* ── Send-Animation: Scan-Strahl + Frame-Flash ────────────────────────── */
.send-scan-wrap {
  position: fixed;
  pointer-events: none;
  overflow: hidden;
  z-index: 9999;
  border-radius: 18px;
}
.send-scan-line {
  position: absolute;
  top: -10%;
  bottom: -10%;
  left: 0;
  width: 110px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(74, 222, 128, 0.0) 25%,
    rgba(74, 222, 128, 0.55) 50%,
    rgba(74, 222, 128, 0.0) 75%,
    transparent 100%);
  filter: blur(2px);
  mix-blend-mode: screen;
  transform: translateX(-110px);
  animation: sendScan 800ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
@keyframes sendScan {
  0%   { transform: translateX(-110px); opacity: 0; }
  12%  { opacity: 1; }
  88%  { opacity: 1; }
  100% { transform: translateX(var(--scan-w, 100vw)); opacity: 0; }
}
.board-frame.send-flash {
  animation: sendFlash 850ms ease-out;
}
@keyframes sendFlash {
  0%   { box-shadow: inherit; }
  35%  {
    box-shadow:
      0 0 0 1px rgba(74, 222, 128, 0.45),
      0 0 40px rgba(74, 222, 128, 0.4),
      inset 0 0 24px rgba(74, 222, 128, 0.18);
  }
  100% { box-shadow: inherit; }
}

/* ── Aluminum-Bezel Rahmen ─────────────────────────────────────────────── */
.board-frame {
  position: relative;
  padding: 26px 18px 32px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, #2c2c28 0%, #1a1a16 100%),
    repeating-linear-gradient(180deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 2px);
  background-blend-mode: overlay;
  border: 1px solid #3a3a36;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.12),
    inset 0 -1px 0 rgba(0,0,0,0.6),
    0 10px 36px rgba(0,0,0,0.6);
}
.frame-label {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 8px;
  letter-spacing: 0.38em;
  color: rgba(255,255,255,0.3);
  text-transform: uppercase;
  user-select: none;
  text-shadow: 0 1px 0 rgba(0,0,0,0.6);
}
.frame-screw {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 30%, #8a8a86 0%, #4a4a46 45%, #1f1f1c 85%, #050505 100%);
  box-shadow:
    inset 0 1px 1px rgba(255,255,255,0.2),
    inset 0 -1px 1px rgba(0,0,0,0.6),
    0 1px 2px rgba(0,0,0,0.7);
  pointer-events: none;
}
.frame-screw::after {
  content: '';
  position: absolute;
  inset: 3px;
  background:
    linear-gradient(45deg, transparent 47%, rgba(0,0,0,0.7) 47% 53%, transparent 53%);
}
.frame-screw.tl { top: 6px;    left: 6px; }
.frame-screw.tr { top: 6px;    right: 6px; }
.frame-screw.bl { bottom: 6px; left: 6px; }
.frame-screw.br { bottom: 6px; right: 6px; }
.frame-screw:hover { transform: scale(1.15); transition: transform 0.12s; }

/* Easter Egg — Schraube fällt raus */
.frame-screw.screw-falling {
  animation: screwFall 0.9s cubic-bezier(0.4, 0.1, 0.7, 1) forwards;
}
@keyframes screwFall {
  0%   { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  20%  { transform: translate(0, 4px) rotate(20deg); }
  100% { transform: translate(var(--screw-dx, 30px), 600px) rotate(720deg); opacity: 0; }
}
.frame-screw.tl.screw-falling { --screw-dx: -40px; }
.frame-screw.tr.screw-falling { --screw-dx: 40px; }
.frame-screw.bl.screw-falling { --screw-dx: -30px; }
.frame-screw.br.screw-falling { --screw-dx: 30px; }

/* Easter Egg — Board fällt nach unten */
.board-frame.board-falling {
  animation: boardFall 1.4s cubic-bezier(0.5, 0, 0.75, 0.2) forwards;
  pointer-events: none;
}
@keyframes boardFall {
  0%   { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  20%  { transform: translate(-4px, 4px) rotate(-2deg); }
  100% { transform: translate(20px, 130vh) rotate(28deg); opacity: 0; }
}

.board-frame.board-respawn {
  animation: boardRespawn 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
@keyframes boardRespawn {
  0%   { transform: translateY(-120vh) rotate(-6deg); opacity: 0; }
  60%  { transform: translateY(8px) rotate(1deg);     opacity: 1; }
  100% { transform: translate(0, 0) rotate(0deg);     opacity: 1; }
}

/* Easter Egg — Tiles fliegen einzeln auseinander */
.tile.scatter {
  --tx: 0px;
  --ty: 0px;
  --rot: 0deg;
  animation: tileScatter 1.4s cubic-bezier(0.4, 0.1, 0.65, 1) forwards;
  z-index: 50;
}
@keyframes tileScatter {
  0%   { transform: translate(0, 0) rotate(0deg);     opacity: 1; }
  15%  { transform: translate(calc(var(--tx) * 0.15), calc(var(--ty) * 0.02)) rotate(calc(var(--rot) * 0.1)); opacity: 1; }
  100% { transform: translate(var(--tx), var(--ty)) rotate(var(--rot)); opacity: 0; }
}

/* ── Template-Items ───────────────────────────────────────────────────── */
#templateList {
  max-height: calc(100vh - 220px);
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
#templateList::-webkit-scrollbar { display: none; }

.template-item {
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s;
  overflow: hidden;
  box-sizing: border-box;
}
.template-item.tpl-entering {
  animation: tplEnter 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes tplEnter {
  0% {
    opacity: 0;
    transform: translateY(-8px) scale(0.94);
    border-color: var(--green);
    box-shadow: 0 0 0 1px rgba(74, 222, 128, 0.4), 0 0 18px rgba(74, 222, 128, 0.25);
  }
  60% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    border-color: var(--border);
    box-shadow: none;
  }
}
.template-item.tpl-removing {
  transition:
    height        0.32s cubic-bezier(0.4, 0, 0.2, 1),
    margin        0.32s cubic-bezier(0.4, 0, 0.2, 1),
    padding       0.32s cubic-bezier(0.4, 0, 0.2, 1),
    opacity       0.22s ease-out,
    transform     0.32s cubic-bezier(0.4, 0, 0.2, 1),
    border-color  0.22s ease-out,
    border-width  0.32s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  transform: translateX(-12px) scale(0.96);
  border-color: transparent;
  border-width: 0;
  pointer-events: none;
}
.template-item:hover {
  background: var(--surface-2);
  border-color: var(--border-hover);
}
.template-item .tpl-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.template-item .tpl-name {
  flex: 1;
  font-size: 12px;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.template-item .tpl-del {
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 14px;
  padding: 2px 6px;
  border-radius: 3px;
}
.template-item .tpl-del:hover { color: var(--red); background: var(--surface); }

/* ── Cards ───────────────────────────────────────────────────────────── */
.card {
  background:
    linear-gradient(180deg, var(--surface) 0%, #131310 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.02) inset,
    0 2px 8px rgba(0,0,0,0.3);
  transition: border-color 0.18s, box-shadow 0.18s;
}
.card:hover {
  border-color: var(--border-hover);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.card-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.card-header .card-title { margin-bottom: 0; }

.meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--text-dim);
}

.hint {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ── Rate-Limit-Cooldown-Bar über dem Board ────────────────────────── */
.cooldown-bar {
  display: none;
  text-align: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--green);
  background: var(--green-dark);
  border: 1px solid var(--green-dim);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  margin: 0 0 10px 0;
}
.cooldown-bar.visible { display: block; }

/* ── Toast-Notification ───────────────────────────────────────────────── */
.toast {
  /* Immer im Layout vorhanden, aber bei !visible zusammengeklappt — so
     animiert das Board sanft mit, statt zu springen. */
  text-align: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-height: 0;
  padding: 0 12px;
  margin: 0;
  border: 1px solid transparent;
  opacity: 0;
  transform: translateY(-4px);
  transition:
    max-height  0.28s cubic-bezier(0.4, 0, 0.2, 1),
    padding     0.28s cubic-bezier(0.4, 0, 0.2, 1),
    margin      0.28s cubic-bezier(0.4, 0, 0.2, 1),
    opacity     0.22s ease-out,
    transform   0.22s ease-out;
}
.toast.visible {
  max-height: 120px;
  padding: 8px 12px;
  margin: 0 0 10px 0;
  opacity: 1;
  transform: translateY(0);
}
.toast.success {
  color: var(--green);
  background: var(--green-dark);
  border: 1px solid var(--green-dim);
}
.toast.info {
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border-hover);
}
.toast.warn,
.toast.error {
  color: #f3a23a;
  background: rgba(242, 145, 40, 0.08);
  border: 1px solid rgba(242, 145, 40, 0.4);
}
.toast .toast-hint {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  opacity: 0.85;
  letter-spacing: 0.02em;
}

/* ── Board Display ───────────────────────────────────────────────────── */
.board-wrap {
  background:
    radial-gradient(ellipse at top, #16140f 0%, #0a0907 70%),
    #0a0907;
  border: 1px solid #1c1b17;
  border-radius: 14px;
  padding: 26px 28px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow-x: auto;
  position: relative;
  box-shadow:
    inset 0 2px 12px rgba(0,0,0,0.7),
    inset 0 -1px 4px rgba(255,255,255,0.02),
    0 6px 24px rgba(0,0,0,0.5);
}
/* Subtle Vignette für mehr Tiefe */
.board-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 14px;
  background: radial-gradient(ellipse at center, transparent 50%, rgba(0,0,0,0.35) 100%);
  pointer-events: none;
}
/* Bezel-Highlight oben */
.board-wrap::after {
  content: '';
  position: absolute;
  top: 0;
  left: 14px;
  right: 14px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
  pointer-events: none;
}

.board-row {
  display: flex;
  gap: 3px;
  margin-bottom: 3px;
}

.tile {
  width: 28px;
  height: 38px;
  flex-shrink: 0;
  /* Flap-Faces in mattem dunklem Beige-Grau, schmaler Spalt in der Mitte */
  background:
    linear-gradient(180deg,
      #36302a 0%,
      #2a2620 5%,
      #252118 48%,
      #1a1612 49.5%,
      #0a0807 50%,
      #1a1612 50.5%,
      #221e17 52%,
      #2a2620 95%,
      #1f1c17 100%);
  border: 1px solid #000;
  border-radius: 3px;
  position: relative;
  overflow: hidden;
  user-select: none;
  perspective: 220px;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.18),
    inset 0 -1px 1px rgba(0,0,0,0.9),
    inset 1px 0 0 rgba(255,255,255,0.05),
    inset -1px 0 1px rgba(0,0,0,0.6),
    0 1px 3px rgba(0,0,0,0.9),
    0 0 0 0.5px rgba(0,0,0,0.8);
}

.tile-ch {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 18px;
  font-weight: 600;
  color: #f5f1e6;
  text-shadow:
    0 1px 1px rgba(0,0,0,0.6),
    0 0 4px rgba(245,241,230,0.15);
  pointer-events: none;
  z-index: 3;   /* über dem Groove damit Buchstaben lesbar bleiben */
}

.flap {
  will-change: transform, opacity;
}
.history-item {
  contain: content;
}

/* Split-flap divider — schmale dunkle Linie + winziger Highlight unter dem Spalt */
.tile::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1.5px;
  background: rgba(0,0,0,0.85);
  pointer-events: none;
  z-index: 1;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06);
}

/* Mittiger Hinge-Pin zwischen Top- und Bottom-Flap */
.tile::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3px;
  height: 3px;
  margin-top: -1.5px;
  margin-left: -1.5px;
  background:
    radial-gradient(circle at 35% 35%, #6a6660 0%, #3a3530 55%, #050505 100%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 4;
  box-shadow:
    0 0 1px rgba(0,0,0,0.8),
    inset 0 -0.5px 0 rgba(255,255,255,0.12);
}

/* Oberer Flap — animiert die Top-Hälfte beim Wechsel */
.flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  overflow: hidden;
  z-index: 5;
  background: linear-gradient(180deg, #2f2b25 0%, #221f1a 60%, #1a1714 100%);
  transform-origin: bottom center;
  opacity: 0;
  pointer-events: none;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.10),
    inset 0 -1px 0 rgba(0,0,0,0.6),
    0 1px 1px rgba(0,0,0,0.4);
}
.flap-ch {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 38px;            /* volle Kachelhöhe → nur Top-Hälfte sichtbar */
  line-height: 38px;
  text-align: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 18px;
  font-weight: 600;
  color: #f5f1e6;
  text-shadow:
    0 1px 1px rgba(0,0,0,0.6),
    0 0 4px rgba(245,241,230,0.15);
}
.flap.col-red    { background: linear-gradient(180deg, #e04039 0%, #c0312a 100%); }
.flap.col-orange { background: linear-gradient(180deg, #f29128 0%, #d97a1f 100%); }
.flap.col-yellow { background: linear-gradient(180deg, #ead023 0%, #c8aa1c 100%); }
.flap.col-green  { background: linear-gradient(180deg, #3ab94e 0%, #2f9e44 100%); }
.flap.col-blue   { background: linear-gradient(180deg, #3672e8 0%, #2b5fc8 100%); }
.flap.col-violet { background: linear-gradient(180deg, #9450d4 0%, #7a3fb5 100%); }
.flap.col-white  { background: linear-gradient(180deg, #faf6eb 0%, #e8e6e0 100%); }
.flap.col-black  { background: linear-gradient(180deg, #1f1d1a 0%, #14120f 100%); }
.flap.col-filled { background: linear-gradient(180deg, #dad6c8 0%, #c0bcaf 100%); }
.flap.blank      { background: linear-gradient(180deg, #100e0b 0%, #14110e 100%); }

.flap.flapping {
  animation: flapDown 130ms ease-in forwards;
}
@keyframes flapDown {
  0%   { opacity: 1; transform: rotateX(0deg); }
  85%  { opacity: 1; transform: rotateX(-80deg); }
  100% { opacity: 0; transform: rotateX(-95deg); }
}

.tile.blank .tile-ch { color: transparent; }

/* Farb-Kacheln — solider Farbflap mit klarem dunklem Groove in der Mitte */
.tile.col-red    { background: linear-gradient(180deg, #d8362e 0%, #c0302a 49%, #050000 50%, #050000 52%, #c0302a 54%, #a8281f 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(216,54,46,0.3); }
.tile.col-orange { background: linear-gradient(180deg, #ed8a26 0%, #d97a1f 49%, #050000 50%, #050000 52%, #d97a1f 54%, #b86518 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(237,138,38,0.3); }
.tile.col-yellow { background: linear-gradient(180deg, #e5c821 0%, #c8aa1c 49%, #050000 50%, #050000 52%, #c8aa1c 54%, #ad9416 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(229,200,33,0.3); }
.tile.col-green  { background: linear-gradient(180deg, #36b04a 0%, #2f9e44 49%, #050000 50%, #050000 52%, #2f9e44 54%, #258239 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(54,176,74,0.3); }
.tile.col-blue   { background: linear-gradient(180deg, #3068d8 0%, #2b5fc8 49%, #050000 50%, #050000 52%, #2b5fc8 54%, #244fa8 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(48,104,216,0.3); }
.tile.col-violet { background: linear-gradient(180deg, #8a47c4 0%, #7a3fb5 49%, #050000 50%, #050000 52%, #7a3fb5 54%, #65329a 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), 0 0 4px rgba(138,71,196,0.3); }
.tile.col-white  { background: linear-gradient(180deg, #f5f1e6 0%, #e8e6e0 49%, #050000 50%, #050000 52%, #e8e6e0 54%, #c8c4ba 100%); color: transparent; box-shadow: inset 0 1px 0 rgba(255,255,255,0.4), 0 0 4px rgba(232,230,224,0.25); }
.tile.col-black  { background: linear-gradient(180deg, #181614 0%, #0e0c0a 49%, #000 50%, #000 52%, #0e0c0a 54%, #050505 100%); color: transparent; }
.tile.col-filled { background: linear-gradient(180deg, #d0ccc2 0%, #c0bcaf 49%, #050000 50%, #050000 52%, #c0bcaf 54%, #a6a298 100%); color: transparent; }

/* ── Controls grid ───────────────────────────────────────────────────── */
.controls-grid {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 16px;
}

/* ── Buttons ──────────────────────────────────────────────────────────── */
button {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-sm);
  padding: 7px 14px;
  border: 1px solid var(--border-hover);
  background: transparent;
  color: var(--text);
  transition: background 0.12s, border-color 0.12s, color 0.12s, transform 0.08s ease-out;
}

button:hover { background: var(--surface-2); }
button:active { transform: scale(0.96); }

.btn-primary {
  background: var(--green-dark);
  border-color: var(--green-dim);
  color: var(--green);
}
.btn-primary:hover { background: #143524; border-color: var(--green); }

.btn-sm { font-size: 12px; padding: 5px 12px; }

.btn-toggle         { font-size: 12px; padding: 5px 0; text-align: center; }
.btn-toggle.selected { background: var(--green-dark); border-color: var(--green-dim); color: var(--green); }

.align-btn.selected {
  background: var(--green-dark);
  border-color: var(--green-dim);
  color: var(--green);
}
.align-btn.raw-active {
  opacity: 0.4;
  background: transparent;
  border-color: var(--border);
  color: var(--text-muted);
}
.align-btn.raw-active:hover { opacity: 0.7; }

.full-width { width: 100%; }

/* ── Transition Hover Preview ────────────────────────────────────────── */
.trans-hover {
  position: fixed;
  background: linear-gradient(180deg, var(--surface) 0%, #131310 100%);
  border: 1px solid var(--border-hover);
  border-radius: 10px;
  padding: 12px;
  z-index: 200;
  box-shadow: 0 12px 32px rgba(0,0,0,0.6);
  pointer-events: none;
  animation: hoverIn 0.15s ease-out;
}
@keyframes hoverIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.trans-hover-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--green);
  text-transform: uppercase;
  margin-bottom: 8px;
  text-align: center;
}
.trans-hover-board {
  background: #0a0907;
  padding: 4px;
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.trans-hover-row { display: flex; gap: 1px; }
.thv-tile {
  width: 13px;
  height: 18px;
  background: linear-gradient(180deg, #2a2620 0%, #1f1c17 48%, #100e0b 50%, #1a1714 52%, #221f1a 100%);
  border-radius: 1px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 600;
  color: #f5f1e6;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  perspective: 80px;
}
.thv-tile.col-red    { background: linear-gradient(180deg, #e04039 0%, #c0312a 100%); color: transparent; }
.thv-tile.col-orange { background: linear-gradient(180deg, #f29128 0%, #d97a1f 100%); color: transparent; }
.thv-tile.col-yellow { background: linear-gradient(180deg, #ead023 0%, #c8aa1c 100%); color: transparent; }
.thv-tile.col-green  { background: linear-gradient(180deg, #3ab94e 0%, #2f9e44 100%); color: transparent; }
.thv-tile.col-blue   { background: linear-gradient(180deg, #3672e8 0%, #2b5fc8 100%); color: transparent; }
.thv-tile.col-violet { background: linear-gradient(180deg, #9450d4 0%, #7a3fb5 100%); color: transparent; }
.thv-tile.col-white  { background: linear-gradient(180deg, #faf6eb 0%, #c8c4ba 100%); color: transparent; }
.thv-flap {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 50%;
  background: inherit;
  transform-origin: bottom center;
  opacity: 0;
  pointer-events: none;
  z-index: 2;
}
.thv-flap.flapping {
  animation: thvFlap 110ms ease-in forwards;
}
@keyframes thvFlap {
  0%   { opacity: 1; transform: rotateX(0); }
  85%  { opacity: 1; transform: rotateX(-80deg); }
  100% { opacity: 0; transform: rotateX(-95deg); }
}

/* ── Transition picker ────────────────────────────────────────────────── */
.trans-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}


/* ── Header-Buttons (Info + Sound + Hilfe) ──────────────────────────── */
#infoBtn, #soundBtn, #helpBtn {
  width: 26px;
  height: 26px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--border-hover);
  background: transparent;
  color: var(--text-muted);
  font-family: 'Outfit', sans-serif;
  font-style: italic;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s, border-color 0.15s, background 0.15s, transform 0.08s;
}
#infoBtn:hover, #soundBtn:hover, #helpBtn:hover {
  color: var(--green);
  border-color: var(--green);
  background: var(--green-dark);
}
#soundBtn, #helpBtn { font-style: normal; font-size: 13px; font-weight: 600; }
#helpBtn.active {
  color: var(--green);
  border-color: var(--green);
  background: var(--green-dark);
}

/* ── Hilfe-Modus ──────────────────────────────────────────────────────── */
#helpBanner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 250;
  background: var(--green-dark);
  color: var(--green);
  padding: 10px 50px 10px 20px;
  text-align: center;
  font-size: 13px;
  border-bottom: 1px solid var(--green-dim);
  animation: helpBannerIn 0.2s ease-out;
}
#helpClose {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  background: transparent;
  border: 1px solid var(--green-dim);
  color: var(--green);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
}
#helpClose:hover { background: var(--green); color: var(--green-dark); }
@keyframes helpBannerIn {
  from { transform: translateY(-100%); }
  to   { transform: translateY(0); }
}
body.help-active { padding-top: 96px; }  /* Platz für Banner + Header */
body.help-active [data-help] {
  outline: 2px solid var(--green) !important;
  outline-offset: 2px;
  cursor: help !important;
  position: relative;
  z-index: 5;
}
body.help-active [data-help]:hover {
  background: var(--green-dark) !important;
  filter: brightness(1.2);
}

.help-info {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  max-width: 520px;
  background: linear-gradient(180deg, var(--surface) 0%, #131310 100%);
  border: 1px solid var(--green-dim);
  border-radius: 10px;
  padding: 18px 22px;
  z-index: 260;
  font-size: 13px;
  color: var(--text);
  line-height: 1.55;
  display: none;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  animation: helpInfoIn 0.18s ease-out;
}
.help-info.visible { display: block; }
.help-info .help-title {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 6px;
}
@keyframes helpInfoIn {
  from { opacity: 0; transform: translate(-50%, 16px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.25);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  animation: backdropIn 0.25s ease-out;
  padding: 20px;
}
.modal-backdrop.closing { animation: backdropOut 0.2s ease-out forwards; }

/* Glass / Aero-Look — fast transparent, leichter Blur, weiße Kante */
.modal-content {
  background: rgba(30, 28, 24, 0.28);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  padding: 28px;
  max-width: 800px;
  width: 100%;
  text-align: center;
  box-shadow:
    0 30px 90px rgba(0,0,0,0.6),
    inset 0 1px 0 rgba(255,255,255,0.12),
    inset 0 -1px 0 rgba(0,0,0,0.25);
  animation: modalIn 0.45s cubic-bezier(0.34, 1.6, 0.55, 1);
  position: relative;
  overflow: hidden;
}
/* Subtle Aero-Highlight oben */
.modal-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.04) 0%, transparent 100%);
  pointer-events: none;
  border-radius: 14px 14px 0 0;
}
.modal-backdrop.closing .modal-content { animation: modalOut 0.2s ease-out forwards; }

.changelog {
  text-align: left;
  font-size: 12px;
  color: var(--text);
  max-height: 280px;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 4px 8px;
}
.changelog::-webkit-scrollbar { display: none; }
.changelog-title {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 10px;
}
.changelog-version {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 10px;
  letter-spacing: 0.05em;
}
.changelog-group {
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
  margin: 14px 0 6px 0;
  letter-spacing: 0.02em;
}
.changelog-section {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text);
  margin: 18px 0 8px 0;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border-hover);
}
.changelog ul {
  list-style: none;
  padding: 0;
  margin: 0 0 4px 0;
}
.changelog li {
  font-size: 12px;
  color: var(--text);
  padding-left: 14px;
  position: relative;
  line-height: 1.55;
}
.changelog li::before {
  content: '▸';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--green);
}

@keyframes backdropIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes backdropOut {
  from { opacity: 1; }
  to   { opacity: 0; }
}
@keyframes modalIn {
  0%   { opacity: 0; transform: translateY(30px) scale(0.88); }
  100% { opacity: 1; transform: translateY(0)    scale(1);    }
}
@keyframes modalOut {
  from { opacity: 1; transform: scale(1); }
  to   { opacity: 0; transform: scale(0.95); }
}

/* ── Login-Lock-Style ─────────────────────────────────────────────────── */
[data-requires-login].locked {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ── Collapsible Card ──────────────────────────────────────────────────── */
.collapsible .card-toggle {
  width: 100%;
  background: transparent;
  border: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  color: var(--text);
}
.card-toggle:hover { background: transparent; }
.card-toggle-icon {
  font-size: 14px;
  color: var(--text-muted);
  transition: transform 0.2s;
}
.collapsible.collapsed .card-toggle-icon { transform: rotate(-90deg); }

/* Sanftes Ein-/Ausklappen — robust via max-height (grid-template-rows-Trick
   ist in manchen Browser-Zuständen unzuverlässig nach Layout-Shifts). */
#credBody, #weatherBody, #devBody {
  max-height: 1200px;
  overflow: hidden;
  transition: max-height 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Während des Boots keine Transitions — sonst sieht man das initiale
   Auf-/Zuklappen, bis JS den richtigen Collapse-Zustand gesetzt hat. */
body.booting #credBody,
body.booting #weatherBody,
body.booting #devBody {
  transition: none !important;
}
.collapsible.collapsed #credBody,
.collapsible.collapsed #weatherBody,
.collapsible.collapsed #devBody {
  max-height: 0;
}
.cred-inner, .collapsible-inner {
  min-height: 0;
}

/* ── Token-Sektion: alle Texte grün ───────────────────────────────────── */
#tokenSection,
#tokenSection .card-title,
#tokenSection .hint {
  color: var(--green);
}
#tokenSection code {
  color: var(--green);
  background: var(--green-dark);
}

/* ── Form elements ────────────────────────────────────────────────────── */
input[type="text"],
input[type="password"],
textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  padding: 8px 10px;
  outline: none;
  resize: none;
  transition: border-color 0.15s;
  line-height: 1.6;
}
input:focus, textarea:focus { border-color: var(--amber-dim); }

/* ── Log ──────────────────────────────────────────────────────────────── */
.log {
  max-height: 320px;
  overflow-y: auto;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  word-break: break-all;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.log::-webkit-scrollbar { display: none; }
.log-entry         { margin-bottom: 3px; line-height: 1.5; }
.log-entry.success { color: var(--green); }
.log-entry.error   { color: var(--red); }
.log-entry.dev     { color: var(--text-muted); opacity: 0.75; font-size: 10px; }

/* ── Utility ──────────────────────────────────────────────────────────── */
.row            { display: flex; align-items: center; }
.gap-6          { gap: 6px; }
.gap-8          { gap: 8px; }
.space-between  { justify-content: space-between; }
.flex-1         { flex: 1; }

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 1200px) {
  main { grid-template-columns: 1fr; }
  .sidebar, .right-sidebar { position: static; }
}
@media (max-width: 640px) {
  .controls-grid { grid-template-columns: 1fr; }
  header { padding: 12px 16px; }
  main   { padding: 16px 12px 32px; }
}

/* ── An/Aus-Toggle-Button ─────────────────────────────────────────────────── */
.toggle-btn {
  position: relative;
  display: inline-block;
  width: 78px;
  height: 28px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-hover);
  color: var(--text-dim);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  cursor: pointer;
  padding: 0;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}
.toggle-btn:hover { border-color: var(--green-dim); }
.toggle-btn .toggle-dot {
  position: absolute;
  top: 50%;
  left: 4px;
  width: 18px;
  height: 18px;
  margin-top: -9px;
  border-radius: 50%;
  background: var(--text-dim);
  transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1), background 0.18s ease, box-shadow 0.18s ease;
}
.toggle-btn .toggle-label {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  pointer-events: none;
  transition: right 0.22s cubic-bezier(0.4, 0, 0.2, 1), left 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}
.toggle-btn[aria-pressed="true"] {
  background: rgba(46, 204, 113, 0.12);
  border-color: var(--green);
  color: var(--green);
}
.toggle-btn[aria-pressed="true"] .toggle-dot {
  background: var(--green);
  box-shadow: 0 0 10px rgba(46, 204, 113, 0.55);
  transform: translateX(48px);
}
.toggle-btn[aria-pressed="true"] .toggle-label {
  right: auto;
  left: 10px;
}
