/* The Garden behind one demo window. The colours and the System 7 chrome follow the try page. */
:root { --ink: #262626; --paper: #f6f0d8; --blue: #2450ff; --lav: #dfe2ff; --wall: #e8dfca; --floor: #b08a61; }
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: #4f7a4f; color: var(--ink); font: 400 15px/1.4 -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, sans-serif; }
.desktop { position: relative; min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 16px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n' x='0' y='0' width='100%' height='100%' color-interpolation-filters='sRGB'><feTurbulence type='fractalNoise' baseFrequency='1.15' numOctaves='1' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0.9 0 0 0 -0.35'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); background-size: 180px 180px; }

/* The window */
.win { width: min(1180px, 100%, calc((100vh - 306px) * 2.107)); background: #f5f3ec; border: 2px solid var(--ink); box-shadow: 5px 5px 0 rgba(0, 0, 0, .28); }
.bar { display: flex; align-items: center; gap: 8px; height: 28px; padding: 0 8px; border-bottom: 2px solid var(--ink); background: #f5f3ec; font: 500 12px/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .12em; }
.bar .box { width: 14px; height: 14px; flex: none; border: 1.5px solid var(--ink); }
.bar .lines { flex: 1; height: 9px; background: repeating-linear-gradient(to bottom, var(--ink) 0 1px, transparent 1px 3px); }
.frame { position: relative; width: 100%; aspect-ratio: 1180 / 560; overflow: hidden; }
.story { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 58px; padding: 10px 16px; border-top: 2px solid var(--ink); background: var(--lav); }
.story p { margin: 0; font-size: 17px; font-weight: 500; line-height: 1.3; }
.story span { flex: none; color: #3c3e50; font-size: 13px; text-align: right; }

/* The room: 1180 x 560, scaled as a whole to fit */
.stage { position: absolute; left: 0; top: 0; width: 1180px; height: 560px; transform-origin: 0 0; }
.wall { position: absolute; inset: 0 0 auto; height: 330px; background: var(--wall); }
.floor { position: absolute; inset: 330px 0 0; border-top: 8px solid #a8916f; background: repeating-linear-gradient(to bottom, var(--floor) 0 44px, #a27c55 44px 46px); }
.prop { position: absolute; display: block; pointer-events: none; }
.whiteboard { left: 468px; top: -36px; width: 270px; }
.pinboard { left: 772px; top: -30px; width: 190px; }
.note { position: absolute; left: 96px; top: 30px; width: 280px; padding: 12px 14px; border: 1.5px solid var(--ink); background: var(--paper); box-shadow: 3px 3px 0 rgba(0, 0, 0, .18); font: 500 15px/1.32 -apple-system, BlinkMacSystemFont, sans-serif; transform: rotate(-1.2deg); }
.clock { position: absolute; right: 14px; top: 14px; padding: 6px 10px; border: 1.5px solid var(--ink); background: var(--paper); font: 500 12px/1 ui-monospace, "SF Mono", Menlo, monospace; }

/* Desks and people */
.desk { position: absolute; width: 210px; top: 248px; pointer-events: none; }
.actor { position: absolute; left: 0; top: 0; width: 172px; height: 172px; will-change: transform; }
.actor .body { position: absolute; inset: 0; opacity: 0; transition: opacity .35s; }
.actor.ready .body { opacity: 1; }
.actor canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; }
.look-pixel .actor canvas { image-rendering: pixelated; }
.look-pixel .actor .body { filter: url(#garage-pixel); }
.style-gear .actor::before { content: ''; position: absolute; left: 22%; right: 22%; bottom: 6px; height: 18px; border-radius: 50%; background: radial-gradient(closest-side, rgba(40, 24, 10, .38), rgba(40, 24, 10, 0)); }
.look-pixel .actor::before { content: ''; position: absolute; left: 33%; right: 33%; bottom: 8px; height: 7px; border-radius: 0; background: rgba(50, 30, 12, .24); }
.tag { position: absolute; left: 50%; bottom: -21px; transform: translateX(-50%); padding: 3px 7px 2px; border: 1.5px solid transparent; font: 500 11px/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .08em; color: #3a2b18; white-space: nowrap; }
.actor.on .tag { border-color: var(--ink); background: var(--paper); }

/* What they pass around */
.item { position: absolute; left: 0; top: 0; width: 58px; height: 58px; transform-origin: 50% 50%; filter: drop-shadow(0 2px 0 rgba(0, 0, 0, .28)); will-change: transform; z-index: 40; }
.item svg, .item canvas { display: block; width: 100%; height: 100%; }
.look-pixel .item canvas { image-rendering: pixelated; }
.item i { position: absolute; left: 50%; top: 100%; transform: translateX(-50%); margin-top: 2px; padding: 2px 5px 1px; background: var(--paper); border: 1px solid var(--ink); font: 500 10px/1 ui-monospace, "SF Mono", Menlo, monospace; font-style: normal; white-space: nowrap; }
.item.resting i { display: none; }

.say { position: absolute; z-index: 50; padding: 5px 9px; border: 1.5px solid var(--ink); border-radius: 9px; background: #fff; font-size: 13.5px; font-weight: 500; line-height: 1.2; white-space: nowrap; transform: translate(-50%, -100%); }
.score { position: absolute; z-index: 50; padding: 6px 10px; border: 2px solid var(--ink); font: 700 13px/1.15 ui-monospace, "SF Mono", Menlo, monospace; transform: translate(-50%, -100%) rotate(-3deg); white-space: nowrap; }
.score.miss { background: #ffd9d2; color: #8e1f10; }
.score.pass { background: #d8f4cf; color: #205e12; }

/* A stop for the person */
.call { position: absolute; left: 50%; top: 12px; z-index: 60; width: 520px; transform: translateX(-50%); border: 2px solid var(--ink); background: #fff; box-shadow: 4px 4px 0 rgba(0, 0, 0, .28); }
.call[hidden] { display: none; }
.call h3 { margin: 0; padding: 7px 12px; border-bottom: 2px solid var(--ink); background: var(--paper); font: 500 12px/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .1em; }
.call p { margin: 0; padding: 10px 12px 6px; font-size: 16px; font-weight: 500; }
.call div { display: flex; gap: 8px; padding: 4px 12px 12px; }
.call button { flex: 1; padding: 8px; border: 1.5px solid var(--ink); border-radius: 5px; background: #fff; font: 500 14px/1 -apple-system, BlinkMacSystemFont, sans-serif; color: inherit; cursor: default; }
.call button.pick { background: var(--blue); color: #fff; }

/* The choices */
.panel { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 22px; width: min(1180px, 100%, calc((100vh - 306px) * 2.107)); padding: 10px 14px; border: 2px solid var(--ink); background: #f5f3ec; }
.ask { flex-basis: 100%; margin: 0; font-size: 15px; font-weight: 600; text-align: center; }
.group { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; }
.label { margin-right: 4px; font: 500 12px/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .1em; text-transform: uppercase; }
.panel button { padding: 8px 12px; border: 1.5px solid var(--ink); border-radius: 5px; background: #fff; color: var(--ink); font: 500 14px/1 -apple-system, BlinkMacSystemFont, sans-serif; cursor: pointer; }
.panel button:hover { background: var(--lav); }
.panel button[aria-pressed="true"] { background: var(--blue); color: #fff; }
.panel button:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.warn { flex-basis: 100%; margin: 0; padding: 8px 10px; border: 1.5px solid var(--ink); background: #ffe9c7; font-size: 14px; }
.warn[hidden] { display: none; }

/* The variations side by side */
.sheet { display: none; }
.show-sheet .sheet { display: block; }
.show-sheet .run { display: none; }
.grid { display: grid; grid-template-columns: 90px repeat(4, minmax(0, 1fr)); align-items: center; gap: 6px 10px; padding: 12px 16px; background: var(--wall); }
.grid > b { font: 500 12px/1.2 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .06em; text-align: center; }
.grid > b.row { text-align: left; }
.cell { display: block; width: 100%; max-width: calc((100vh - 340px) / 4); aspect-ratio: 1; margin: 0 auto; padding: 0; border: 1.5px solid transparent; border-radius: 6px; background: transparent; cursor: pointer; font-size: 12px; }
.cell:hover, .cell:focus-visible { border-color: var(--ink); background: rgba(255, 255, 255, .35); outline: none; }
.cell canvas { display: block; }
.cell.is-pixel canvas { image-rendering: pixelated; filter: url(#garage-pixel); }
.cell.is-gear { position: relative; }
.cell.is-gear::before { content: ''; position: absolute; left: 22%; right: 22%; bottom: 7%; height: 9%; border-radius: 50%; background: radial-gradient(closest-side, rgba(40, 24, 10, .34), rgba(40, 24, 10, 0)); }
.cell.is-pixel::before { left: 33%; right: 33%; bottom: 6%; height: 4%; border-radius: 0; background: rgba(50, 30, 12, .22); }
.cell canvas { position: relative; }
