/* Santa's Workshop (premium): a cosy timber workshop at night, lit by brass lanterns. Northern lights through a big
   arched window, a toy train on the sill, shelves of toys and two elves busy at the workbench (built in
   theme-workshop.js). Stitched red-felt buttons with brass corners, wooden cards with brass rivets, toy-block
   Head to Head tiles, an elf hat on the title and a wooden shelf for the bottom bar. Everything is scoped to
   [data-theme="workshop"] or to ws- class names. */

[data-theme="workshop"] {
  --bg-0: #1c0f08; --bg-1: #2c180d; --bg-2: #3e2414;
  --card: rgba(42, 22, 12, .93); --card-2: rgba(255, 226, 180, .08); --panel-edge: rgba(242, 193, 110, .38);
  --ink: #fff6e8; --ink-dim: #e6cba6; --on-hot: #ffffff;
  --hot: #d8342c; --cool: #2f9a5a; --amber: #f2b13a; --good: #45c96b; --bad: #ff6a5a; --seen: #8fe3c8;
  --title-1: #fff3dc; --title-2: #ff5446;
  --mine: rgba(216, 52, 44, .26); --mine-edge: rgba(216, 52, 44, .55); --fact-bg: rgba(242, 177, 58, .12); --fact-edge: rgba(242, 177, 58, .42);
  --shadow: 0 8px 24px rgba(10, 4, 0, .5);
  --scrim: rgba(14, 6, 2, .62); --off: rgba(255, 236, 210, .2); --press: rgba(0, 0, 0, .35);
  /* painted-toy colours for the toy-block tiles */
  --s-general: #c8372d; --s-geography: #2f6fb8; --s-history: #a8642c; --s-science: #1f8f8a;
  --s-nature: #3f8f3a; --s-music: #b83a78; --s-film_tv: #7a43b8; --s-sport: #c98a12;
  --s-arts_lit: #5a4fc0; --s-food: #cf5a26; --s-tech_games: #3b5fc0; --s-words: #1f7f6a;
  /* bottom-bar icon colours (look3d.js TAB_ICONS): elf green and red, brass, warm wood */
  --tb-blue-1: #8fe8a0; --tb-blue-2: #1f8a4a; --tb-pink-1: #ff9c88; --tb-pink-2: #d02e2a;
  --tb-green-1: #8fe8a0; --tb-green-2: #1f8a4a; --tb-red-1: #ff8f80; --tb-red-2: #c8282a;
  --tb-purple-1: #ff8f80; --tb-purple-2: #b01e2a; --tb-orange-1: #e8b07a; --tb-orange-2: #9a5a26;
  --tb-gold-1: #ffe9a0; --tb-gold-2: #dc9e1c; --tb-cream-1: #fffaf0; --tb-cream-2: #ecd2a8;
  --tb-brown-1: #c98a54; --tb-brown-2: #6e3a1a;
}

/* ---- the scene: timber walls warmed by lantern light ---- */
[data-theme="workshop"] #stage-bg { background:
  radial-gradient(34% 22% at 7% 16%, rgba(255, 176, 80, .30), transparent 72%),
  radial-gradient(34% 22% at 93% 16%, rgba(255, 176, 80, .30), transparent 72%),
  radial-gradient(80% 26% at 50% 96%, rgba(255, 150, 70, .2), transparent 75%),
  repeating-linear-gradient(90deg, rgba(20, 8, 2, .55) 0 2px, rgba(255, 214, 160, .07) 2px 3px, transparent 3px 3.4rem),
  repeating-linear-gradient(90deg, rgba(255, 230, 190, .025) 0 1px, transparent 1px 6px, rgba(0, 0, 0, .04) 6px 7px, transparent 7px 13px),
  linear-gradient(#24130a 0%, #4a2a16 30%, #5a341c 60%, #3e2213 100%); }
[data-theme="workshop"] #splash { background: linear-gradient(#24130a, #5a341c); }

.ws-scene { position: absolute; inset: 0; overflow: hidden;
  --wt: 2.1rem; --wh: 27vh; --ww: min(68vw, 24rem); --bb: calc(var(--tabh) + env(safe-area-inset-bottom)); --bh: 13vh; }
.ws-scene .ws-defs { position: absolute; width: 0; height: 0; }
.ws-scene svg { display: block; width: 100%; height: auto; overflow: visible; }
.ws-scene .ws-glow { position: absolute; left: 0; right: 0; top: 0; height: 60vh; pointer-events: none;
  background: radial-gradient(50% 60% at 50% 18%, rgba(110, 255, 190, .08), transparent 70%); }

/* the arched window, with the northern lights moving over snowy hills */
.ws-scene .ws-window { position: absolute; top: var(--wt); left: 50%; width: var(--ww); height: var(--wh); transform: translateX(-50%);
  padding: .5rem .5rem 0; box-sizing: border-box; border: 2.5px solid #1b1033; border-bottom: 0;
  border-radius: calc(var(--ww) / 2) calc(var(--ww) / 2) 0 0;
  background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .12) 0 1px, transparent 1px 7px), linear-gradient(90deg, #6e3a1a, #a8683a 30%, #c98a54 50%, #a8683a 70%, #6e3a1a);
  box-shadow: inset 0 2px 0 rgba(255, 220, 170, .35), 0 10px 26px rgba(0, 0, 0, .45), 0 0 60px rgba(110, 255, 190, .1); }
.ws-scene .ws-glass { position: relative; width: 100%; height: 100%; overflow: hidden; border: 2px solid #1b1033; border-bottom: 0;
  border-radius: calc(var(--ww) / 2 - .5rem) calc(var(--ww) / 2 - .5rem) 0 0;
  background: linear-gradient(#04101f 0%, #0a2440 50%, #164a63 100%); box-shadow: inset 0 0 18px rgba(0, 0, 0, .6); }
/* the window bars: one up the middle, one across, and an arch */
.ws-scene .ws-glass::after { content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 3;
  background:
    linear-gradient(90deg, transparent calc(50% - 5px), #1b1033 calc(50% - 5px) calc(50% - 3px), #a8683a calc(50% - 3px) calc(50% + 3px), #1b1033 calc(50% + 3px) calc(50% + 5px), transparent calc(50% + 5px)),
    linear-gradient(transparent calc(58% - 5px), #1b1033 calc(58% - 5px) calc(58% - 3px), #a8683a calc(58% - 3px) calc(58% + 3px), #1b1033 calc(58% + 3px) calc(58% + 5px), transparent calc(58% + 5px)); }
.ws-scene .ws-frost { position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(30% 22% at 0% 100%, rgba(235, 245, 255, .55), transparent 70%), radial-gradient(30% 22% at 100% 100%, rgba(235, 245, 255, .55), transparent 70%),
    radial-gradient(18% 14% at 50% 100%, rgba(235, 245, 255, .3), transparent 70%); }
.ws-scene .ws-stars { position: absolute; inset: 0; }
.ws-scene .ws-stars i { position: absolute; width: 2px; height: 2px; border-radius: 50%; background: #fff; transform: scale(var(--s));
  box-shadow: 0 0 4px rgba(255, 255, 255, .8); animation: ws-twinkle 3.2s ease-in-out infinite; }
@keyframes ws-twinkle { 50% { opacity: .25; } }
.ws-scene .ws-aur { position: absolute; left: -30%; width: 160%; top: 6%; height: 62%; mix-blend-mode: screen; filter: blur(5px); transform-origin: 50% 100%;
  background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0) 0 5px, rgba(255, 255, 255, .14) 5px 7px, rgba(255, 255, 255, 0) 7px 13px),
    linear-gradient(to top, rgba(80, 255, 170, 0) 0%, rgba(80, 255, 170, .75) 30%, rgba(90, 220, 200, .45) 55%, rgba(160, 100, 255, .5) 78%, rgba(160, 100, 255, 0) 100%);
  -webkit-mask: radial-gradient(50% 50% at 50% 50%, #000 40%, transparent 72%); mask: radial-gradient(50% 50% at 50% 50%, #000 40%, transparent 72%);
  border-radius: 50%; animation: ws-aurora 14s ease-in-out infinite alternate; }
.ws-scene .ws-aur2 { top: 0; height: 52%; opacity: .75; animation-duration: 19s; animation-delay: -7s;
  background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0) 0 4px, rgba(255, 255, 255, .12) 4px 6px, rgba(255, 255, 255, 0) 6px 11px),
    linear-gradient(to top, rgba(170, 110, 255, 0), rgba(170, 110, 255, .7) 35%, rgba(255, 110, 210, .35) 70%, transparent); }
.ws-scene .ws-aur3 { top: 18%; height: 48%; opacity: .7; animation-duration: 11s; animation-delay: -4s; }
@keyframes ws-aurora {
  0% { transform: translateX(-12%) skewX(-14deg) scaleY(.85); opacity: .55; }
  50% { transform: translateX(4%) skewX(8deg) scaleY(1.1); opacity: 1; }
  100% { transform: translateX(14%) skewX(-6deg) scaleY(.9); opacity: .7; } }
.ws-scene .ws-hills { position: absolute; left: 0; right: 0; bottom: 0; height: 32%; z-index: 1; }
.ws-scene .ws-hills svg { width: 100%; height: 100%; }

/* the window sill: a long shelf the toy train runs along */
.ws-scene .ws-sill { position: absolute; left: 0; right: 0; top: calc(var(--wt) + var(--wh)); height: .85rem;
  background: linear-gradient(#ffd9a0, #e2a868 30%, #b97a42 70%, #8a5228); border-top: 2.5px solid #1b1033; border-bottom: 2.5px solid #1b1033;
  box-shadow: 0 8px 14px -4px rgba(0, 0, 0, .55); }
.ws-scene .ws-train { position: absolute; left: 0; top: calc(var(--wt) + var(--wh) - 2.75rem + 1px); width: 8.6rem;
  animation: ws-chug 30s linear infinite; animation-delay: -8s; }
.ws-scene .ws-train svg { filter: drop-shadow(0 2px 1px rgba(0, 0, 0, .4)); }
@keyframes ws-chug { from { transform: translateX(-9.5rem); } to { transform: translateX(calc(100vw + 1rem)); } }
.ws-scene .ws-wheel { transform-box: fill-box; transform-origin: center; animation: ws-spin .9s linear infinite; }
@keyframes ws-spin { to { transform: rotate(360deg); } }
.ws-scene .ws-puff { position: absolute; left: 7.05rem; top: -.2rem; width: .8rem; height: .8rem; border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fff, #e8e2f0 60%, #bfb6cc); box-shadow: 0 0 0 1.5px rgba(27, 16, 51, .5);
  animation: ws-puff 1.8s ease-out infinite; opacity: 0; }
.ws-scene .ws-puff:nth-child(2) { animation-delay: -.6s; }
.ws-scene .ws-puff:nth-child(3) { animation-delay: -1.2s; }
@keyframes ws-puff { 0% { transform: translate(0, 0) scale(.4); opacity: .95; } 100% { transform: translate(-1.6rem, -1.6rem) scale(1.5); opacity: 0; } }

/* the ceiling beam and the swaying brass lanterns */
.ws-scene .ws-beam { position: absolute; left: 0; right: 0; top: 0; height: max(1.5rem, calc(env(safe-area-inset-top) + 1rem));
  background: repeating-linear-gradient(0deg, rgba(0, 0, 0, .14) 0 1px, transparent 1px 5px), linear-gradient(#3a2010, #7a4824 55%, #5a3418);
  border-bottom: 3px solid #1b1033; box-shadow: 0 6px 12px rgba(0, 0, 0, .5); }
.ws-scene .ws-beam::after { content: ''; position: absolute; left: 0; right: 0; bottom: .3rem; height: .5rem;
  background: radial-gradient(circle, #ffe08a 0 2px, #b97a14 2.5px 3.5px, #1b1033 3.8px 4.4px, transparent 4.8px) 1.4rem 50% / 5.5rem 100% repeat-x; }
.ws-scene .ws-lantern { position: absolute; top: max(1.5rem, calc(env(safe-area-inset-top) + 1rem)); left: var(--x); width: 2.5rem; margin-left: -1.25rem;
  padding-top: 2.4rem; transform-origin: 50% 0; animation: ws-sway 4.6s ease-in-out infinite alternate; animation-delay: var(--t); }
.ws-scene .ws-lantern::before { content: ''; position: absolute; left: calc(50% - 1.5px); top: 0; width: 3px; height: 2.55rem;
  background: repeating-linear-gradient(#1b1033 0 2px, #c8902e 2px 5px); }
.ws-scene .ws-lantern svg { position: relative; z-index: 1; }
.ws-scene .ws-halo { position: absolute; left: 50%; top: 3.9rem; width: 9rem; height: 9rem; margin: -4.5rem 0 0 -4.5rem; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 214, 120, .5), rgba(255, 160, 60, .16) 40%, transparent 70%); animation: ws-flicker 2.6s ease-in-out infinite; }
@keyframes ws-sway { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }
@keyframes ws-flicker { 0%, 100% { opacity: .85; } 30% { opacity: 1; } 55% { opacity: .7; } 70% { opacity: .95; } }
.ws-scene .ws-flame { transform-box: fill-box; transform-origin: 50% 100%; animation: ws-flame .5s ease-in-out infinite alternate; }
@keyframes ws-flame { from { transform: scale(.9, .95) skewX(-4deg); } to { transform: scale(1.05, 1.08) skewX(4deg); } }

/* shelves of toys along the walls */
.ws-scene .ws-shelf { position: absolute; height: 4.6rem; display: flex; align-items: flex-end; gap: .25rem; padding: 0 .5rem .7rem; box-sizing: border-box; }
.ws-scene .ws-shelf-l { left: 0; top: 50vh; width: min(34vw, 9rem); }
.ws-scene .ws-shelf-r { right: 0; top: 54vh; width: min(36vw, 9.5rem); justify-content: flex-end; }
.ws-scene .ws-plank { position: absolute; left: -3px; right: -3px; bottom: 0; height: .75rem; border: 2.5px solid #1b1033; border-radius: 3px;
  background: linear-gradient(#ffd9a0, #d39a5c 35%, #9a5a2c); box-shadow: 0 8px 12px -3px rgba(0, 0, 0, .55); }
.ws-scene .ws-shelf-l .ws-plank { border-left: 0; border-radius: 0 3px 3px 0; }
.ws-scene .ws-shelf-r .ws-plank { border-right: 0; border-radius: 3px 0 0 3px; }
.ws-scene .ws-plank::after { content: ''; position: absolute; top: 100%; width: .7rem; height: 1.2rem; right: 1rem;
  background: linear-gradient(135deg, #b97a42 50%, transparent 50%); border-left: 2.5px solid #1b1033; border-top: 0; }
.ws-scene .ws-shelf-r .ws-plank::after { right: auto; left: 1rem; }
.ws-scene .ws-toy { position: relative; flex: none; filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .45)); }
.ws-scene .ws-horse { width: 3.7rem; transform-origin: 50% 100%; animation: ws-rock 2.4s ease-in-out infinite alternate; }
@keyframes ws-rock { from { transform: rotate(-7deg); } to { transform: rotate(7deg); } }
.ws-scene .ws-teddy { width: 2.6rem; }
.ws-scene .ws-top { width: 1.8rem; transform-origin: 50% 100%; animation: ws-wobble .7s ease-in-out infinite alternate; }
@keyframes ws-wobble { from { transform: rotate(-6deg); } to { transform: rotate(6deg); } }
.ws-scene .ws-drum { width: 2.3rem; }
.ws-scene .ws-sold { width: 1.25rem; }
.ws-scene .ws-sold2 { margin-left: -.2rem; }

/* the workbench along the bottom, with drawers and brass knobs */
.ws-scene .ws-bench { position: absolute; left: 0; right: 0; bottom: var(--bb); height: var(--bh); border-top: 3px solid #1b1033;
  background:
    linear-gradient(#ffd9a0 0 3px, #dba062 3px .7rem, #b97a42 .7rem 1.15rem, #1b1033 1.15rem calc(1.15rem + 3px), transparent calc(1.15rem + 3px)),
    repeating-linear-gradient(0deg, rgba(0, 0, 0, .1) 0 1px, transparent 1px 6px),
    linear-gradient(#6e3e1e, #4e2a14);
  display: flex; justify-content: space-around; align-items: flex-start; padding-top: calc(1.15rem + 3px + .6rem); box-sizing: border-box; }
.ws-scene .ws-bench::after { content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 8rem; background: #3a1f0f; }
.ws-scene .ws-drawer { width: 24%; height: 2.2rem; max-height: 45%; border: 2.5px solid #1b1033; border-radius: 4px;
  background: radial-gradient(circle at 50% 50%, #ffe08a 0 .22rem, #b97a14 .24rem .34rem, #1b1033 .36rem .44rem, transparent .46rem),
    linear-gradient(#8a5228, #6e3e1e); box-shadow: inset 0 2px 0 rgba(255, 220, 170, .25), 0 2px 0 rgba(0, 0, 0, .3); }

/* the elves stand behind the bench, the toys sit on top of it */
.ws-scene .ws-elf { position: absolute; bottom: calc(var(--bb) + var(--bh) - .95rem); width: 4.4rem; filter: drop-shadow(0 4px 3px rgba(0, 0, 0, .4)); }
.ws-scene .ws-elf-h { left: max(.3rem, 2%); }
.ws-scene .ws-elf-w { right: max(.3rem, 2%); transform: scaleX(-1); animation: ws-bob 1.1s ease-in-out infinite alternate; }
@keyframes ws-bob { to { transform: scaleX(-1) translateY(-3px) rotate(2deg); } }
.ws-scene .ws-elf-h svg { animation: ws-lean .9s ease-in infinite; transform-origin: 50% 100%; }
@keyframes ws-lean { 0%, 55% { transform: rotate(-2deg); } 75% { transform: rotate(2deg); } 100% { transform: rotate(-2deg); } }
.ws-scene .ws-harm { transform-box: view-box; transform-origin: 45px 60px; animation: ws-hammer .9s ease-in infinite; }
@keyframes ws-hammer { 0% { transform: rotate(-58deg); } 55% { transform: rotate(-58deg); } 75% { transform: rotate(-6deg); } 80% { transform: rotate(-10deg); } 100% { transform: rotate(-58deg); } }
.ws-scene .ws-spark { position: absolute; left: 4.4rem; bottom: .9rem; width: 1.3rem; height: 1.3rem; margin-left: -.65rem; opacity: 0;
  background: radial-gradient(circle, #fffbe0 0 12%, transparent 14%),
    conic-gradient(from 0deg, transparent 0 20deg, #ffd84d 20deg 26deg, transparent 26deg 65deg, #ffd84d 65deg 71deg, transparent 71deg 110deg, #ffd84d 110deg 116deg, transparent 116deg 155deg, #ffd84d 155deg 161deg, transparent 161deg 200deg, #ffd84d 200deg 206deg, transparent 206deg 245deg, #ffd84d 245deg 251deg, transparent 251deg 290deg, #ffd84d 290deg 296deg, transparent 296deg 335deg, #ffd84d 335deg 341deg, transparent 341deg);
  -webkit-mask: radial-gradient(circle, #000 55%, transparent 70%); mask: radial-gradient(circle, #000 55%, transparent 70%);
  animation: ws-spark .9s linear infinite; }
@keyframes ws-spark { 0%, 72% { opacity: 0; transform: scale(.3); } 76% { opacity: 1; transform: scale(1); } 90%, 100% { opacity: 0; transform: scale(1.3); } }
.ws-scene .ws-arml { transform-box: view-box; transform-origin: 19px 60px; animation: ws-tie .55s ease-in-out infinite alternate; }
.ws-scene .ws-armr { transform-box: view-box; transform-origin: 45px 60px; animation: ws-tie .55s ease-in-out infinite alternate-reverse; }
@keyframes ws-tie { from { transform: rotate(-10deg); } to { transform: rotate(12deg); } }
.ws-scene .ws-ontop { position: absolute; bottom: calc(var(--bb) + var(--bh) - 1rem); filter: drop-shadow(0 3px 2px rgba(0, 0, 0, .45)); }
.ws-scene .ws-car { left: calc(max(.3rem, 2%) + 3.75rem); width: 2.4rem; }
.ws-scene .ws-car svg { animation: ws-jolt .9s ease-in infinite; transform-origin: 50% 100%; }
@keyframes ws-jolt { 0%, 74% { transform: none; } 78% { transform: scale(1.04, .9); } 86%, 100% { transform: none; } }
.ws-scene .ws-blocks { left: calc(50% - 3.8rem); width: 2.4rem; bottom: calc(var(--bb) + var(--bh) - .95rem); }
.ws-scene .ws-pot { left: calc(50% + 1.8rem); width: 1.4rem; }
.ws-scene .ws-present { right: calc(max(.3rem, 2%) + 3.1rem); width: 2.5rem; }
.ws-scene .ws-bow { transform-box: view-box; transform-origin: 23px 12px; animation: ws-bow 2.2s ease-in-out infinite; }
@keyframes ws-bow { 0%, 60%, 100% { transform: scale(1); } 70% { transform: scale(1.25) rotate(-6deg); } 80% { transform: scale(.95) rotate(4deg); } }

/* sawdust and sparkles drifting in the lamplight */
.ws-scene .ws-dust { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: #ffe7a8; box-shadow: 0 0 6px 2px rgba(255, 200, 100, .45);
  transform: scale(var(--z)); animation: ws-drift var(--d) ease-in-out infinite; animation-delay: var(--t); opacity: 0; }
@keyframes ws-drift { 0% { opacity: 0; transform: translate(0, 0) scale(var(--z)); } 20% { opacity: .9; } 50% { opacity: .35; }
  80% { opacity: .9; } 100% { opacity: 0; transform: translate(var(--dx), -7vh) scale(var(--z)); } }

/* ---- the app: painted wood, brass and stitched red felt ---- */
[data-theme="workshop"] :is(.title, .tag, .home .dim) { text-shadow: 0 2px 10px rgba(20, 8, 0, .75); }

/* the title: cream and toy-red painted letters with a dark outline, and an elf hat on "Party" */
[data-theme="workshop"] .logo .l1 { color: #fff3dc; text-shadow: 0 0 1px #1b1033, 2px 2px 0 #1b1033, -2px 2px 0 #1b1033, 2px -1px 0 #1b1033, -2px -1px 0 #1b1033, 0 5px 0 #7a3a14, 0 8px 14px rgba(0, 0, 0, .5); }
[data-theme="workshop"] .logo .l2 { position: relative; color: #ff5446; text-shadow: 0 0 1px #1b1033, 2px 2px 0 #1b1033, -2px 2px 0 #1b1033, 2px -1px 0 #1b1033, -2px -1px 0 #1b1033, 0 5px 0 #7a1410, 0 0 18px rgba(255, 84, 70, .45); }
[data-theme="workshop"] .logo.small .l1, [data-theme="workshop"] .logo.small .l2 { text-shadow: 0 0 1px #1b1033, 1px 1px 0 #1b1033, -1px 1px 0 #1b1033, 0 2px 0 rgba(0, 0, 0, .5); }
[data-theme="workshop"] .logo:not(.small) .l2::after { content: ''; position: absolute; right: -.42em; top: -.42em; width: .95em; height: .8em; transform: rotate(18deg); pointer-events: none;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .4));
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 84'%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%238fe89a'/%3E%3Cstop offset='1' stop-color='%231f8a4a'/%3E%3C/linearGradient%3E%3Cpath d='M10 64C14 30 34 8 60 6c16-1 28 8 30 22-8-6-18-4-20 6l6 30z' fill='url(%23g)' stroke='%231b1033' stroke-width='5' stroke-linejoin='round'/%3E%3Cellipse cx='34' cy='30' rx='5' ry='12' fill='%23fff' opacity='.45' transform='rotate(30 34 30)'/%3E%3Ccircle cx='90' cy='32' r='8' fill='%23f2c14e' stroke='%231b1033' stroke-width='4'/%3E%3Cpath d='M4 60h80v10l-6.7 8-6.7-8-6.7 8-6.6-8-6.7 8-6.7-8-6.6 8-6.7-8-6.7 8-6.6-8-6.7 8L4 70z' fill='%23d8342c' stroke='%231b1033' stroke-width='4' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat; }

/* main buttons: stitched felt with brass corner plates */
html[data-theme="workshop"] .btn:not(.ghost) { color: #fff8ec;
  background: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1.4px) 0 0 / 5px 5px,
    linear-gradient(180deg, rgba(255, 255, 255, .3), rgba(255, 255, 255, .06) 48%, rgba(255, 255, 255, 0) 52%, rgba(0, 0, 0, .14)), var(--hot);
  box-shadow: inset 0 1.5px 0 rgba(255, 255, 255, .45), inset 0 -3px 0 rgba(0, 0, 0, .22), 0 0 0 2px #1b1033, 0 5px 0 color-mix(in srgb, var(--hot) 50%, black),
    0 5px 0 2px #1b1033, 0 14px 22px -6px rgba(0, 0, 0, .6); }
html[data-theme="workshop"] .btn:not(.ghost):active { box-shadow: inset 0 2px 5px rgba(0, 0, 0, .25), 0 0 0 2px #1b1033, 0 1px 0 2px #1b1033; }
html[data-theme="workshop"] .btn.gold:not(.ghost) { color: #3a2200; text-shadow: 0 1px 0 rgba(255, 255, 255, .4); }
[data-theme="workshop"] .btn:not(.ghost):not(.small) { position: relative; overflow: visible; }
[data-theme="workshop"] .btn:not(.ghost):not(.small)::after { content: ''; position: absolute; inset: 5px; border-radius: 9px; pointer-events: none;
  border: 2px dashed rgba(255, 244, 222, .55); }
[data-theme="workshop"] .btn.gold:not(.ghost):not(.small)::after { border-color: rgba(90, 50, 10, .45); }
[data-theme="workshop"] .btn:not(.ghost):not(.small)::before { content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  --c: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23fff3b0'/%3E%3Cstop offset='.5' stop-color='%23f2c14e'/%3E%3Cstop offset='1' stop-color='%23a86a10'/%3E%3C/linearGradient%3E%3Cpath d='M2 18V7q0-5 5-5h11v5H9q-2 0-2 2v9z' fill='url(%23g)' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Ccircle cx='5.4' cy='5.4' r='1.4' fill='%231b1033'/%3E%3C/svg%3E");
  }
/* the other three corners: the same plate turned round */
[data-theme="workshop"] .btn:not(.ghost):not(.small)::before {
  background:
    var(--c) 0 0 / 15px 15px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23fff3b0'/%3E%3Cstop offset='.5' stop-color='%23f2c14e'/%3E%3Cstop offset='1' stop-color='%23a86a10'/%3E%3C/linearGradient%3E%3Cpath d='M18 18V7q0-5-5-5H2v5h9q2 0 2 2v9z' fill='url(%23g)' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Ccircle cx='14.6' cy='5.4' r='1.4' fill='%231b1033'/%3E%3C/svg%3E") 100% 0 / 15px 15px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23fff3b0'/%3E%3Cstop offset='.5' stop-color='%23f2c14e'/%3E%3Cstop offset='1' stop-color='%23a86a10'/%3E%3C/linearGradient%3E%3Cpath d='M2 2v11q0 5 5 5h11v-5H9q-2 0-2-2V2z' fill='url(%23g)' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Ccircle cx='5.4' cy='14.6' r='1.4' fill='%231b1033'/%3E%3C/svg%3E") 0 100% / 15px 15px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23fff3b0'/%3E%3Cstop offset='.5' stop-color='%23f2c14e'/%3E%3Cstop offset='1' stop-color='%23a86a10'/%3E%3C/linearGradient%3E%3Cpath d='M18 2v11q0 5-5 5H2v-5h9q2 0 2-2V2z' fill='url(%23g)' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Ccircle cx='14.6' cy='14.6' r='1.4' fill='%231b1033'/%3E%3C/svg%3E") 100% 100% / 15px 15px no-repeat; }
html[data-theme="workshop"] .btn.ghost { border: 0; box-shadow: inset 0 1px 0 rgba(255, 230, 190, .25), inset 0 0 0 1.5px rgba(242, 193, 110, .45), 0 3px 0 rgba(0, 0, 0, .35), 0 8px 16px -6px rgba(0, 0, 0, .55); }

/* cards: dark walnut with a fine grain, a brass edge and a brass rivet in each corner */
html[data-theme="workshop"] :is(.panel, .sheetbox) {
  background: linear-gradient(180deg, rgba(255, 226, 180, .1), rgba(255, 226, 180, 0) 40%, rgba(0, 0, 0, .06)),
    repeating-linear-gradient(176deg, rgba(255, 220, 170, .028) 0 2px, transparent 2px 9px, rgba(0, 0, 0, .05) 9px 11px, transparent 11px 19px),
    var(--panel);
  box-shadow: inset 0 1px 0 rgba(255, 226, 180, .3), inset 0 -2px 0 rgba(0, 0, 0, .2), 0 1px 2px rgba(0, 0, 0, .3), 0 14px 30px -10px rgba(0, 0, 0, .7); }
[data-theme="workshop"] .panel { position: relative; }
[data-theme="workshop"] .panel::after { content: ''; position: absolute; inset: 6px; pointer-events: none; border-radius: inherit;
  --r: radial-gradient(circle at 50% 50%, #fff3b0 0 1.2px, #e0a838 1.8px 2.8px, #1b1033 3.2px 3.9px, transparent 4.2px);
  background: var(--r) 0 0 / 9px 9px no-repeat, var(--r) 100% 0 / 9px 9px no-repeat, var(--r) 0 100% / 9px 9px no-repeat, var(--r) 100% 100% / 9px 9px no-repeat; }

/* Head to Head tiles are painted wooden toy blocks with a routed edge; a little letter block sits on each corner */
html[data-theme="workshop"] .topic { border: 0; color: #fff; border-radius: 10px; overflow: visible;
  background: linear-gradient(180deg, rgba(255, 255, 255, .24), rgba(255, 255, 255, 0) 42%, rgba(0, 0, 0, .14)),
    repeating-linear-gradient(98deg, rgba(255, 255, 255, .06) 0 2px, transparent 2px 10px, rgba(0, 0, 0, .06) 10px 12px, transparent 12px 21px),
    var(--sc);
  box-shadow: inset 0 0 0 4px color-mix(in srgb, var(--sc) 72%, white), inset 0 0 0 6px color-mix(in srgb, var(--sc) 55%, black), inset 0 2px 0 6px rgba(255, 255, 255, .2),
    0 0 0 2px #1b1033, 0 6px 0 0 color-mix(in srgb, var(--sc) 48%, black), 0 6px 0 2px #1b1033, 0 14px 18px -6px rgba(0, 0, 0, .65); }
html[data-theme="workshop"] .topic:active { transform: translateY(3px); }
[data-theme="workshop"] .topic span, [data-theme="workshop"] .topic small { position: relative; text-shadow: 0 1px 2px rgba(0, 0, 0, .55); max-width: 80%; }
[data-theme="workshop"] .topic small { color: rgba(255, 246, 232, .88); }
/* the block shows the topic's first letter (user, 5 Nov; app.js viewDuel sets data-letter); colours and tilts cycle */
[data-theme="workshop"] .topic::after { content: attr(data-letter); position: absolute; right: -.45rem; top: -.6rem; width: 1.9rem; height: 1.9rem; box-sizing: border-box;
  padding: .41rem .41rem 0 0; display: grid; place-items: center; font: 900 .95rem/1 var(--display); color: #d8342c; pointer-events: none;
  transform: rotate(8deg); filter: drop-shadow(0 2px 1.5px rgba(0, 0, 0, .5));
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Cpath d='M1 7l6-6h20v20l-6 6z' fill='%23c08448' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M1 7l6-6h20l-6 6z' fill='%23ffe7bd' stroke='%231b1033' stroke-width='1.8' stroke-linejoin='round'/%3E%3Crect x='1' y='7' width='20' height='20' rx='1.5' fill='%23f5d199' stroke='%231b1033' stroke-width='1.8'/%3E%3Crect x='3.6' y='9.6' width='14.8' height='14.8' rx='1' fill='none' stroke='%23d9a868' stroke-width='1.2'/%3E%3C/svg%3E") center / contain no-repeat; }
[data-theme="workshop"] .topic:nth-child(6n+2)::after { color: #2f6fb8; transform: rotate(-6deg); }
[data-theme="workshop"] .topic:nth-child(6n+3)::after { color: #2f9a5a; transform: rotate(4deg); }
[data-theme="workshop"] .topic:nth-child(6n+4)::after { color: #c8640a; transform: rotate(-9deg); }
[data-theme="workshop"] .topic:nth-child(6n+5)::after { color: #8e2bc4; transform: rotate(6deg); }
[data-theme="workshop"] .topic:nth-child(6n)::after { color: #d8342c; transform: rotate(-4deg); }
[data-theme="workshop"] .topicgrid { row-gap: .9rem; column-gap: .7rem; padding-top: .5rem; }

/* the bottom bar: a wooden shelf with a brass rail along the top */
html[data-theme="workshop"] #tabbar {
  background: repeating-linear-gradient(0deg, rgba(0, 0, 0, .1) 0 1px, transparent 1px 6px), linear-gradient(#7a4824, #5a3418 60%, #43260f);
  box-shadow: 0 -10px 24px -8px rgba(0, 0, 0, .7); border-top: 0; overflow: visible; }
html[data-theme="workshop"] #tabbar::before { content: ''; position: absolute; left: 0; right: 0; top: -3px; height: 6px; pointer-events: none; z-index: 0;
  background: radial-gradient(circle, #1b1033 0 1.2px, transparent 1.6px) 1rem 50% / 3.6rem 100% repeat-x, linear-gradient(#fff3b0, #e0a838 50%, #8a5a10);
  border-top: 1.5px solid #1b1033; border-bottom: 1.5px solid #1b1033; }
html[data-theme="workshop"] #tabbar button.homebtn::before { box-shadow: none; filter: drop-shadow(0 -5px 6px rgba(0, 0, 0, .35));
  background: linear-gradient(transparent calc(50% + 1px), #7a4824 calc(50% + 1px), #66391b),
    radial-gradient(circle closest-side, #8a5428 0 calc(100% - 6px), #f2c14e calc(100% - 6px) calc(100% - 2.5px), #1b1033 calc(100% - 2.5px) 100%, transparent 100%); }
html[data-theme="workshop"] #tabbar button span { color: #f2dcbc; text-shadow: 0 1px 1px rgba(0, 0, 0, .6); }
html[data-theme="workshop"] #tabbar button.on span { color: #ffd76a; }

/* ---- the bundle's style items ---- */
/* chat bubble "Elf Felt": red felt with cream stitching round the edge */
html body .bubble.bub-ws.bub-ws { color: #fff8ec; border: 2px solid #1b1033; border-radius: 18px 18px 18px 6px;
  background: radial-gradient(rgba(255, 255, 255, .08) 1px, transparent 1.4px) 0 0 / 4px 4px, linear-gradient(#e8473c, #c42a24 60%, #a81f1c);
  text-shadow: 0 1px 1px rgba(0, 0, 0, .4); }
html body .bubble.mine.bub-ws.bub-ws { border-radius: 18px 18px 6px 18px; }
html body .bubble.bub-ws.bub-ws::after { content: ''; position: absolute; inset: 3px; border-radius: inherit; pointer-events: none;
  border: 1.6px dashed rgba(255, 240, 214, .7); }

/* answer buttons "Toy Blocks": painted wooden blocks with a routed cream edge and wood grain, in each answer's colour */
body.btns-ws .abtn, .btns-ws-demo { border-radius: 8px !important; color: #fff !important; border: 0 !important;
  background: linear-gradient(180deg, rgba(255, 255, 255, .26), rgba(255, 255, 255, 0) 42%, rgba(0, 0, 0, .14)),
    repeating-linear-gradient(97deg, rgba(255, 255, 255, .07) 0 2px, transparent 2px 9px, rgba(0, 0, 0, .07) 9px 11px, transparent 11px 19px),
    var(--c) !important;
  box-shadow: inset 0 0 0 4px rgba(255, 240, 214, .85), inset 0 0 0 6px color-mix(in srgb, var(--c) 55%, black),
    0 0 0 2px #1b1033, 0 6px 0 0 color-mix(in srgb, var(--c) 48%, black), 0 6px 0 2px #1b1033, 0 12px 16px -6px rgba(0, 0, 0, .55) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .55) !important; }
body.btns-ws .abtn:active { transform: translateY(4px); box-shadow: inset 0 0 0 4px rgba(255, 240, 214, .85), 0 0 0 2px #1b1033, 0 2px 0 2px #1b1033 !important; }
body.btns-ws .abtn .badge { color: #3a2200; text-shadow: none; border-radius: 4px; transform: rotate(-4deg);
  background: linear-gradient(135deg, #ffe7bd, #f5d199 55%, #d9a868); box-shadow: 0 0 0 2px #1b1033, 2px 3px 0 #1b1033; }
.btns-ws-demo { font-family: var(--display); }

/* ---- calm for anyone who asks for less motion ---- */
@media (prefers-reduced-motion: reduce) {
  .ws-scene *, .ws-scene *::before, .ws-scene *::after { animation: none !important; }
  .ws-scene .ws-dust, .ws-scene .ws-puff, .ws-scene .ws-spark { display: none; }
  .ws-scene .ws-train { transform: translateX(8vw); }
  .ws-scene .ws-harm { transform: rotate(-30deg); }
}
