/* ==========================================================================
   Rätsel-spezifische Bausteine
   ========================================================================== */
/* --- 2 Waage --- */
.rt-scale { display: flex; flex-direction: column; gap: 0.8rem; align-items: center; }
.rt-scale-top { display: flex; gap: 1rem; width: 100%; justify-content: center; align-items: flex-end; }
.rt-zone-wrap { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.3rem; }
.rt-scale-top .rt-zone-wrap { max-width: 260px; }
.rt-zone-label { font-size: 0.78rem; color: var(--text-muted); text-align: center; }
.rt-zone { min-height: 56px; display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; align-content: center; padding: 8px; border: 1px dashed var(--border-color-hover); border-radius: 12px; background: var(--bg-surface-hover); }
.rt-scale-top .rt-zone { border-style: solid; border-bottom-width: 4px; }
.rt-ball { width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer; font-weight: 800; color: #3a2a05; background: radial-gradient(circle at 30% 30%, #fde68a, #d99a06); box-shadow: 0 2px 5px rgba(0,0,0,.35); }
.rt-beam { width: 70%; max-width: 360px; height: 8px; border-radius: 4px; background: var(--rt-wood-dark); transition: transform .5s; position: relative; }
.rt-log { list-style: none; font-size: 0.85rem; color: var(--text-muted); margin: 0.6rem 0; }
.rt-log li::before { content: '⚖ '; }
/* --- 4 Hüte --- */
.rt-lineup { display: flex; gap: 1rem; justify-content: center; align-items: flex-end; margin-bottom: 1rem; flex-wrap: wrap; }
.rt-man { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 0.8rem; color: var(--text-muted); }
.rt-hat { width: 46px; height: 24px; border-radius: 10px 10px 2px 2px; background: repeating-linear-gradient(45deg, #94a3b8, #94a3b8 6px, #cbd5e1 6px, #cbd5e1 12px); display: flex; align-items: center; justify-content: center; font-weight: 800; color: #111; }
.rt-body { width: 42px; height: 52px; border-radius: 22px 22px 6px 6px; background: var(--text-muted); opacity: .55; }
.rt-arrow { width: 100%; text-align: center; color: var(--text-muted); font-size: 0.8rem; }

/* --- 7 Schiebepuzzle --- */
.rt-board .rt-cell { aspect-ratio: 1; font-size: 1.8rem; }
.rt-cell.tile { cursor: pointer; background: linear-gradient(145deg, #e2b878, #b9854b); color: #2b1b07; border-color: #8a5a2b; box-shadow: 0 3px 0 #6e4521; position: relative; }
.rt-cell.tile:hover { filter: brightness(1.08); }
.rt-cell.tile.locked { background: linear-gradient(145deg, #94a3b8, #64748b); border-color: #475569; box-shadow: 0 3px 0 #334155; cursor: not-allowed; }
.rt-cell.tile.locked i { position: absolute; top: 4px; right: 5px; font-size: 1rem; }
.rt-cell.empty { background: var(--bg-base); border-style: dashed; }
/* --- 8 Eis --- */
.rt-ice { display: grid; gap: 2px; width: 100%; max-width: 370px; margin: 0 auto; touch-action: none; }
.rt-ice-cell { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; font-size: clamp(1.1rem, 5vw, 1.8rem); background: #cfeaf9; border-radius: 6px; }
.rt-ice-cell.rock { background: #94a3b8; }
.rt-ice-cell.goal { background: #fde68a; }
.rt-pad { display: grid; grid-template-columns: repeat(3, 52px); grid-template-areas: ". up ." "left down right"; gap: 6px; margin-top: 0.8rem; justify-content: center; }
.rt-pad .up { grid-area: up; } .rt-pad .left { grid-area: left; } .rt-pad .down { grid-area: down; } .rt-pad .right { grid-area: right; }
.rt-pad .rt-btn { height: 46px; font-size: 1.2rem; }
/* --- 9 Wasser --- */
.rt-jars { display: flex; gap: 2.5rem; align-items: flex-end; justify-content: center; margin-bottom: 0.4rem; }
.rt-jar-wrap { display: flex; flex-direction: column; align-items: center; gap: 0.4rem; }
.rt-jar { width: 78px; border: 3px solid var(--text-muted); border-top: 0; border-radius: 0 0 16px 16px; position: relative; overflow: hidden; background: rgba(255,255,255,.04); display: flex; align-items: flex-end; }
.rt-water { width: 100%; background: linear-gradient(#38bdf8, #0ea5e9); transition: height .5s; }
.rt-jar-label { font-size: 0.85rem; color: var(--text-muted); }
/* --- 10 Hanoi --- */
.rt-hanoi { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; width: 100%; max-width: 520px; }
.rt-peg { position: relative; height: 210px; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; background: var(--bg-surface-hover); border: 2px solid var(--border-color); border-radius: 14px; cursor: pointer; padding-bottom: 6px; }
.rt-peg.sel { border-color: var(--accent-amber); box-shadow: 0 0 0 2px rgba(245,158,11,.35); }
.rt-peg-pole { position: absolute; bottom: 6px; width: 8px; height: 190px; background: var(--rt-wood-dark); border-radius: 4px; }
.rt-peg-stack { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; width: 100%; }
.rt-disk { height: 30px; border-radius: 15px; background: linear-gradient(#fcd34d, #d97706); border: 1px solid #92400e; display: flex; align-items: center; justify-content: center; font-size: 0.9rem; box-shadow: 0 2px 4px rgba(0,0,0,.3); }
.rt-disk.d1 { background: linear-gradient(#a7f3d0, #10b981); } .rt-disk.d2 { background: linear-gradient(#bae6fd, #0ea5e9); } .rt-disk.d3 { background: linear-gradient(#ddd6fe, #8b5cf6); }
/* --- 11 Fähre --- */
.rt-ferry { display: grid; grid-template-columns: 1fr 1.1fr 1fr; gap: 0.5rem; align-items: stretch; }
.rt-bank { display: flex; flex-direction: column; gap: 0.4rem; padding: 0.6rem; border-radius: 14px; background: color-mix(in srgb, var(--accent-emerald) 12%, var(--bg-surface-hover)); min-height: 190px; }
.rt-bank-label { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; }
.rt-river { background: linear-gradient(#0ea5e9, #0369a1); border-radius: 14px; display: flex; align-items: center; padding: 6px; }
.rt-river[data-side="R"] { justify-content: flex-end; }
.rt-river[data-side="L"] { justify-content: flex-start; }
.rt-boat { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px; border-radius: 12px; background: rgba(255,255,255,.18); min-width: 80px; }
.rt-boat-icon { font-size: 1.4rem; }
.rt-chipbtn { display: flex; align-items: center; gap: 0.4rem; padding: 0.4rem 0.6rem; border-radius: 10px; cursor: pointer; background: var(--bg-surface); border: 1px solid var(--border-color); font-size: 1.1rem; }
.rt-chipbtn span { font-size: 0.78rem; color: var(--text-muted); }
.rt-chipbtn:hover { border-color: var(--accent-amber); }
@media (max-width: 520px) { .rt-ferry { grid-template-columns: 1fr; } .rt-river { min-height: 80px; } }
/* --- 12 Kutschenstau --- */
.rt-rush-wrap { position: relative; width: 100%; max-width: 380px; padding-right: 56px; margin-top: 0.2rem; }
.rt-rush { position: relative; width: 100%; aspect-ratio: 1; background: var(--bg-surface-hover); border: 3px solid var(--border-color-hover); border-radius: 10px; touch-action: none; background-image: linear-gradient(to right, rgba(128,128,128,.25) 1px, transparent 1px), linear-gradient(to bottom, rgba(128,128,128,.25) 1px, transparent 1px); background-size: calc(100% / 6) calc(100% / 6); }
.rt-car { position: absolute; border-radius: 10px; border: 3px solid rgba(255,255,255,.55); box-sizing: border-box; cursor: grab; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; box-shadow: 0 3px 6px rgba(0,0,0,.35); touch-action: none; }
.rt-car.drag { cursor: grabbing; z-index: 3; filter: brightness(1.1); }
.rt-exit { position: absolute; right: 0; top: calc((100% - 6px) / 6 * 2 + 3px); height: calc((100% - 6px) / 6); display: flex; align-items: center; font-size: 0.72rem; color: var(--accent-amber); font-weight: 700; }

/* --- Geometrie --- */
.rt-dot { fill: var(--text-muted); }
.rt-hit { stroke: transparent; stroke-width: 24; fill: none; cursor: pointer; }
.rt-slotline { stroke: var(--border-color-hover); stroke-width: 3; stroke-dasharray: 3 6; stroke-linecap: round; }
.rt-stick { stroke: #d6a45c; stroke-width: 8; stroke-linecap: round; }
.rt-stickhead { fill: #dc2626; }
.rt-slot.sel .rt-stick { stroke: var(--accent-cyan); }
.rt-silhouette { fill: color-mix(in srgb, var(--text-muted) 12%, transparent); stroke: var(--text-muted); stroke-width: 2; stroke-dasharray: 8 6; }
.rt-tpiece { stroke: rgba(0,0,0,.45); stroke-width: 1.5; stroke-linejoin: round; cursor: grab; fill-opacity: .92; touch-action: none; }
.rt-tpiece.sel { stroke: #fff; stroke-width: 3; }
.rt-garden { display: grid; grid-template-columns: repeat(4, 56px); gap: 3px; margin-bottom: 0.8rem; }
.rt-gcell { width: 56px; height: 56px; border-radius: 8px; background: #86d38e; border: 1px solid rgba(0,0,0,.2); font-size: 1.6rem; cursor: pointer; }
.rt-gcell.void { background: transparent; border: 0; cursor: default; }
.rt-swatch { width: 36px; height: 36px; border-radius: 50%; border: 3px solid transparent; cursor: pointer; }
.rt-swatch.on { border-color: var(--text-main); transform: scale(1.12); }
.rt-cubes { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 0.6rem; margin-top: 1rem; }
.rt-cubebtn { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0.6rem; border-radius: 14px; background: var(--bg-surface-hover); border: 2px solid var(--border-color); cursor: pointer; font-size: 0.8rem; color: var(--text-muted); }
.rt-cubebtn:hover:not(:disabled) { border-color: var(--accent-amber); }
.rt-cubebtn.ok { border-color: var(--accent-emerald); }
.rt-cubebtn.bad { border-color: var(--accent-rose); opacity: .5; }
.rt-mcell { fill: var(--bg-surface-hover); stroke: var(--border-color); }
.rt-mcell.rock { fill: #64748b; }
.rt-mirror { stroke: #67e8f9; stroke-width: 6; stroke-linecap: round; pointer-events: none; }
.rt-beam-line { fill: none; stroke: #f43f5e; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; opacity: .85; pointer-events: none; }
.rt-beam-line.hit { stroke: #facc15; }
.rt-tri-line { stroke: var(--text-main); stroke-width: 2.5; stroke-linecap: round; }

/* --- Wege --- */
.rt-water-bg { fill: #0ea5e9; opacity: .85; }
.rt-bridge-path { fill: none; stroke: #8a5a2b; stroke-width: 10; stroke-linecap: round; stroke-dasharray: 3 2; }
.rt-bridge.can .rt-bridge-path { stroke: #d6a45c; }
.rt-bridge.used .rt-bridge-path { stroke: #10b981; stroke-dasharray: none; }
.rt-bridge .rt-hit { stroke-width: 26; }
.rt-land ellipse { fill: #86d38e; stroke: #3b8a4a; stroke-width: 3; }
.rt-land.here ellipse { fill: #fde68a; stroke: #d97706; }
.rt-land text { font-size: 14px; font-weight: 700; fill: #14391c; pointer-events: none; }
.rt-maze-bg { fill: var(--bg-surface-hover); }
.rt-maze-goal { fill: var(--accent-emerald); opacity: .85; }
.rt-maze-wall { stroke: var(--text-main); stroke-width: 3; stroke-linecap: round; }
.rt-maze-trail { fill: none; stroke: var(--accent-amber); stroke-width: 6; opacity: .4; stroke-linecap: round; stroke-linejoin: round; }
.rt-maze-me { fill: var(--accent-amber); }
.rt-pipe { cursor: pointer; }
.rt-pipe-cell { fill: var(--bg-surface-hover); stroke: var(--border-color); }
.rt-pipe-line { stroke: #94a3b8; stroke-width: 12; stroke-linecap: butt; }
.rt-pipe-hub { fill: #94a3b8; }
.rt-pipe.wet .rt-pipe-line { stroke: #38bdf8; } .rt-pipe.wet .rt-pipe-hub { fill: #38bdf8; }
.rt-road { stroke: var(--border-color-hover); stroke-width: 6; stroke-linecap: round; }
.rt-road.on { stroke: var(--accent-amber); }
.rt-roadnum { fill: var(--text-main); font-size: 13px; font-weight: 700; paint-order: stroke; stroke: var(--bg-surface); stroke-width: 4px; }
.rt-stop circle { fill: #94a3b8; stroke: var(--bg-surface); stroke-width: 3; }
.rt-stop circle.red { fill: #ef4444; } .rt-stop circle.depot { fill: #3b82f6; }
.rt-stop.cur circle { stroke: var(--accent-amber); stroke-width: 5; }
.rt-stop-label { fill: #fff; font-weight: 800; font-size: 15px; pointer-events: none; }

/* --- Detektiv --- */
.rt-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
@media (max-width: 560px) { .rt-pair { grid-template-columns: 1fr; } }
.rt-scene { border-radius: 12px; cursor: crosshair; border: 1px solid var(--border-color); }
.rt-found { fill: none; stroke: #f43f5e; stroke-width: 3; pointer-events: none; }
.rt-badge { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-amber); color: #1a1205; font-size: 0.75rem; font-weight: 800; margin-left: 6px; }
.rt-gridline { stroke: var(--border-color); stroke-width: 1; }
.rt-axis { fill: var(--text-muted); font-size: 11px; } .rt-axis.strong { fill: var(--text-main); font-weight: 700; font-size: 13px; }
.rt-bar { fill: var(--accent-cyan); opacity: .85; } .rt-bar.b1 { fill: var(--accent-purple); }
.rt-bar-label { fill: #08111a; font-size: 10.5px; font-weight: 700; pointer-events: none; }
.rt-crime { stroke: #f43f5e; stroke-width: 2.5; stroke-dasharray: 5 3; } .rt-crime-label { fill: #f43f5e; font-size: 11px; font-weight: 700; }
.rt-obj { cursor: grab; touch-action: none; }
.rt-obj:active { cursor: grabbing; }
.rt-shadows { display: flex; justify-content: center; align-items: center; gap: 1.5rem; }
.rt-shcol { display: flex; flex-direction: column; gap: 0.5rem; }
.rt-shbtn { width: 82px; height: 68px; border-radius: 14px; background: var(--bg-surface-hover); border: 2px solid var(--border-color); cursor: pointer; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.rt-shbtn.sel { border-color: var(--accent-amber); }
.rt-shbtn.done { border-color: var(--accent-emerald); opacity: .55; cursor: default; }
.rt-shsym { font-size: 2.1rem; display: inline-block; }
.rt-shsym.shadow { filter: brightness(0) opacity(.75); }
body:not(.light-mode) .rt-shsym.shadow { filter: brightness(0) invert(1) opacity(.6); }
.rt-sharrow { font-size: 1.6rem; color: var(--text-muted); }

/* --- Wort & Code --- */
.rt-cipher { text-align: center; word-break: break-word; }
.rt-cipher.dim { color: var(--text-muted); }
.rt-range { width: 100%; max-width: 360px; margin: 0.5rem 0 0.8rem; accent-color: var(--accent-amber); }
.rt-rebus { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 0.6rem; margin-bottom: 1rem; }
.rt-rebus-item { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0.6rem; border-radius: 12px; background: var(--bg-surface-hover); border: 1px solid var(--border-color); }
.rt-rebus-pic { font-size: 2.4rem; line-height: 1.1; } .rt-rebus-op { font-family: var(--font-heading); font-weight: 700; white-space: pre; }
.rt-clues { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1rem; }
.rt-clue { display: flex; align-items: center; gap: 0.8rem; padding: 0.5rem 0.7rem; border-radius: 10px; background: var(--bg-surface-hover); border: 1px solid var(--border-color); flex-wrap: wrap; }
.rt-code { font-family: var(--font-heading); font-size: 1.2rem; font-weight: 800; letter-spacing: .1em; }
.rt-clue-txt { color: var(--text-muted); font-size: 0.88rem; }
.rt-morse { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.4rem; margin: 0.4rem 0; }
.rt-mword { display: flex; gap: 0.9rem; }
.rt-mletter { display: flex; gap: 4px; align-items: center; }
.rt-mletter i { display: inline-block; height: 8px; border-radius: 4px; background: var(--accent-amber); }
.rt-mletter i.dot { width: 8px; } .rt-mletter i.dash { width: 24px; }
.rt-lamp { font-size: 2.4rem; filter: grayscale(1) brightness(.6); }
.rt-lamp.on { filter: none; text-shadow: 0 0 24px #facc15; }
.rt-details { margin: 0.9rem 0; font-size: 0.88rem; } .rt-details summary { cursor: pointer; color: var(--text-muted); }
.rt-mtable { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 4px 10px; margin-top: 0.5rem; font-family: var(--font-heading); }
.rt-xword { display: grid; grid-template-columns: repeat(5, 52px); gap: 3px; margin-bottom: 0.8rem; }
.rt-xcell { position: relative; width: 52px; height: 52px; border-radius: 6px; background: var(--bg-surface-hover); border: 1px solid var(--border-color-hover); }
.rt-xcell.void { background: transparent; border: 0; }
.rt-xcell.bad { border-color: var(--accent-rose); background: color-mix(in srgb, var(--accent-rose) 14%, transparent); }
.rt-xinput { width: 100%; height: 100%; background: transparent; border: 0; text-align: center; font-size: 1.5rem; font-weight: 800; color: var(--text-main); text-transform: uppercase; outline: none; font-family: var(--font-heading); }
.rt-xinput:focus { background: color-mix(in srgb, var(--accent-amber) 18%, transparent); border-radius: 6px; }
.rt-xnum { position: absolute; top: 2px; left: 4px; font-size: 0.65rem; color: var(--text-muted); pointer-events: none; }

/* --- Mechanik --- */
.rt-gear polygon { stroke: rgba(0,0,0,.4); stroke-width: 1.5; stroke-linejoin: round; }
.rt-gear.a polygon { fill: #fbbf24; } .rt-gear.b polygon { fill: #38bdf8; }
.rt-gear-hub { fill: var(--bg-surface); stroke: rgba(0,0,0,.4); }
.rt-gear-label { font-weight: 800; font-size: 20px; fill: #111; pointer-events: none; }
.rt-gear-arrow { fill: none; stroke: #111; stroke-width: 3; } .rt-gear-arrowfill { fill: #111; }
.rt-fulcrum { fill: #94a3b8; }
.rt-beamrect { fill: var(--rt-wood); stroke: var(--rt-wood-dark); stroke-width: 2; }
.rt-hook { fill: #fcd34d; } .rt-hooknum { fill: var(--text-muted); font-size: 11px; }
.rt-weight line { stroke: var(--text-muted); stroke-width: 2; }
.rt-weight rect { fill: #475569; stroke: #1e293b; stroke-width: 2; } .rt-weight.fixed rect { fill: #7c3aed; }
.rt-weight text { fill: #fff; font-weight: 800; font-size: 14px; pointer-events: none; }
.rt-slotcirc { fill: transparent; stroke: var(--border-color-hover); stroke-dasharray: 3 3; cursor: pointer; } .rt-slotcirc.ready { stroke: var(--accent-amber); fill: rgba(245,158,11,.15); }
.rt-clock-face { fill: #fff7e0; stroke: #8a5a2b; stroke-width: 4; } .rt-clock-num { fill: #3a2a14; font-size: 10px; font-weight: 700; }
.rt-hand { stroke: #2b1b07; stroke-linecap: round; } .rt-hand.hour { stroke-width: 5; } .rt-hand.min { stroke-width: 3; } .rt-hand-hub { fill: #2b1b07; }
.rt-clocks { display: flex; justify-content: center; gap: 1.5rem; flex-wrap: wrap; }
.rt-clockwrap { width: 170px; }
.rt-sliders { display: flex; flex-direction: column; gap: 0.3rem; align-items: center; margin-top: .4rem; } .rt-sliders label { display: flex; gap: .6rem; align-items: center; font-size: .9rem; }
.rt-dchain { display: flex; flex-wrap: wrap; gap: 4px; min-height: 66px; padding: 8px; border: 2px dashed var(--border-color-hover); border-radius: 12px; align-items: center; margin-bottom: 1rem; }
.rt-dpool { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.rt-domino { display: inline-flex; align-items: center; background: #fff7e0; color: #2b1b07; border: 2px solid #2b1b07; border-radius: 8px; font-family: var(--font-heading); font-weight: 800; font-size: 1.3rem; }
.rt-domino span { width: 34px; height: 44px; display: flex; align-items: center; justify-content: center; }
.rt-domino i { width: 2px; height: 34px; background: #2b1b07; }
.rt-dbtn { background: transparent; border: 0; cursor: pointer; border-radius: 10px; padding: 2px; }
.rt-dbtn:hover { transform: translateY(-2px); }

/* --- Kniffe --- */
.rt-qtext { margin: 0.4rem 0 0.8rem; font-size: 1.05rem; }
.rt-calc { background: #c8d5c0; color: #1f2a1c; border: 4px solid #4b5563; border-radius: 14px; padding: 0.8rem 1.2rem; display: flex; flex-direction: column; gap: 0.2rem; align-items: flex-end; min-width: 220px; transition: transform .6s; }
.rt-calc.flip { transform: rotate(180deg); }
.rt-calc-digits { font-family: 'Courier New', monospace; font-size: 2.6rem; letter-spacing: .12em; font-weight: 700; }
.rt-latt { fill: var(--border-color-hover); } .rt-latt-hit { fill: transparent; cursor: pointer; } .rt-latt-hit:hover { fill: rgba(245,158,11,.25); }
.rt-poly { fill: none; stroke: var(--accent-amber); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.rt-vert { fill: var(--accent-amber); pointer-events: none; } .rt-vert-n { fill: var(--accent-amber); font-size: 12px; font-weight: 800; pointer-events: none; }
.rt-nine { fill: var(--text-main); stroke: var(--bg-surface); stroke-width: 2; } .rt-nine.on { fill: var(--accent-emerald); }
