/* Ghanaian Traditional Semiotics: scene banners (spec 30).
   Archive-only motion exceptions (to add to CLAUDE.md at ship): the big-symbol rotation
   (6s loop, pause button), the grid's stroke draw, the breathing glow, the 1.6x tap zoom. */
.scn { position: relative; background: #0d0806; overflow: hidden; }
.scn-frame { position: relative; width: 100%; aspect-ratio: 1376 / 768; overflow: hidden; }
@media (max-width: 767px) { .scn-frame { aspect-ratio: 896 / 1200; } }
.scn-stage { position: absolute; inset: 0; transform-origin: 50% 40%; transition: transform 700ms var(--ease, cubic-bezier(.22,1,.36,1)); }
.scn-stage.is-out { transition-duration: 500ms; }
.scn-stage picture, .scn-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.scn-stage img { filter: brightness(var(--scn-dim, 1)); }
.scn-dim { position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 55%, transparent 45%, rgba(8,4,3,.55) 100%),
    linear-gradient(180deg, rgba(8,4,3,.45) 0%, transparent 28%, transparent 78%, rgba(8,4,3,.5) 100%); }
.scn-dim::after { content: ""; position: absolute; inset: 0; background: #080403; animation: scnLift 1200ms ease-out both; }
@keyframes scnLift { from { opacity: .7; } to { opacity: 0; } }
.scn-dust { position: absolute; inset: -20% 0 0; pointer-events: none; opacity: .5; mix-blend-mode: screen;
  background-image: radial-gradient(1.4px 1.4px at 20% 30%, rgba(255,214,160,.9), transparent 60%),
    radial-gradient(1px 1px at 70% 60%, rgba(255,200,140,.8), transparent 60%),
    radial-gradient(1.6px 1.6px at 45% 80%, rgba(255,226,180,.7), transparent 60%),
    radial-gradient(1px 1px at 85% 20%, rgba(255,214,160,.8), transparent 60%);
  background-size: 220px 260px, 180px 200px, 260px 300px, 200px 240px; animation: scnDust 24s linear infinite; }
@keyframes scnDust { to { transform: translate3d(-40px, 18%, 0); } }
.scn-cap { position: absolute; right: 8px; bottom: 4px; margin: 0; font-size: .5rem; letter-spacing: .02em; color: rgba(245,242,238,.4); z-index: 2; }

/* Symbols */
.scn-sym { position: absolute; left: var(--x); top: var(--y); width: var(--s); aspect-ratio: 1; transform: translate(-50%, -50%);
  border: 0; padding: 0; background: none; min-width: 44px; min-height: 44px; display: grid; place-items: center; z-index: 1;
  opacity: 0; animation: scnIn 500ms ease-out both; animation-delay: calc(250ms + var(--i) * 90ms); }
button.scn-sym { cursor: pointer; }
@keyframes scnIn { from { opacity: 0; transform: translate(-50%, calc(-50% + 6px)); } to { opacity: 1; transform: translate(-50%, -50%); } }
.scn-sym__ink, .scn-sym__glow { position: absolute; inset: 0; margin: auto; width: var(--s); height: var(--s);
  -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.scn-sym__ink { background: linear-gradient(180deg, #fbe6c8 0%, #e9b878 100%); opacity: .92; }
.scn-sym__glow { background: rgba(255,190,120,.9); opacity: 0; filter: blur(2px); transition: opacity 600ms ease; }
.scn-sym--small { filter: drop-shadow(0 0 8px rgba(255,170,90,.45)); }
.scn-sym[data-glow="white"]:not(.scn-sym--big) .scn-sym__ink { background: linear-gradient(180deg, #fff 0%, #f5f2ee 100%); }
.scn-sym[data-glow="white"]:not(.scn-sym--big) { filter: drop-shadow(0 0 10px rgba(255,248,236,.6)); }
.scn-sym[data-glow="red"]:not(.scn-sym--big) .scn-sym__ink { background: linear-gradient(180deg, #ff8a5c 0%, #e04514 100%); }
.scn-sym[data-glow="red"]:not(.scn-sym--big) { filter: drop-shadow(0 0 10px rgba(224,69,20,.75)); }
.scn-sym--big { filter: drop-shadow(0 0 14px rgba(255,170,90,.55)) drop-shadow(0 0 40px rgba(224,69,20,.35)); }
.scn-sym--big .scn-sym__ink { background: linear-gradient(180deg, #ffeccc 0%, #f0b868 60%, #d8742a 100%); opacity: .95; }
.scn-sym.is-hint .scn-sym__glow, button.scn-sym:hover .scn-sym__glow, .scn-sym:focus-visible .scn-sym__glow { opacity: .55; }
.scn-sym:focus-visible { outline: 2px solid var(--beige); outline-offset: 4px; border-radius: 8px; }
.scn-sym.is-up .scn-sym__ink { opacity: .22; transition: opacity 500ms ease; }
.scn-sym.is-swapping { opacity: 0 !important; transform: translate(-50%, calc(-50% + 6px)) scale(.96); transition: opacity 420ms ease, transform 420ms ease; }
.scn-sym:not(.is-swapping) { transition: opacity 600ms ease, transform 600ms ease; }
.scn.is-focus .scn-sym:not(.is-active) { opacity: .35 !important; }

/* Halo + faded grid behind the big symbol */
.scn-halo { position: absolute; left: var(--x); top: var(--y); width: calc(var(--s) * 2.1); aspect-ratio: 1; pointer-events: none; transform: translate(-50%, -50%); border-radius: 50%;
  background: radial-gradient(circle, rgba(255,170,90,.55) 0%, rgba(224,69,20,.25) 40%, transparent 70%); animation: scnBreath 6s ease-in-out infinite; }
@keyframes scnBreath { 0%,100% { opacity: .55; transform: translate(-50%,-50%) scale(1); } 50% { opacity: .85; transform: translate(-50%,-50%) scale(1.03); } }
.scn-grid { position: absolute; left: var(--x); top: var(--y); width: calc(var(--s) * 1.3); aspect-ratio: 1; transform: translate(-50%, -50%); pointer-events: none; opacity: .32; transition: opacity 420ms ease;
  -webkit-mask: radial-gradient(circle, #000 45%, transparent 72%); mask: radial-gradient(circle, #000 45%, transparent 72%); }
.scn-grid svg { width: 100%; height: 100%; display: block; overflow: hidden; }
.scn-grid .construct__fill, .scn-grid .construct__line, .scn-grid .construct__bez, .scn-grid .construct__handles, .scn-grid .construct__ctrl,
.scn-grid .construct__nodes, .scn-grid .construct__anchors, .scn-grid .sem-solid { display: none; }
.scn-grid line, .scn-grid circle { fill: none; stroke: rgba(255,226,190,.9); stroke-width: 1; stroke-dasharray: 1; stroke-dashoffset: 1; }
.scn-grid.is-drawing line, .scn-grid.is-drawing circle { animation: scnDraw 1400ms ease-out forwards; }
.scn-grid.is-drawing .construct__diag line, .scn-grid.is-drawing .construct__diag circle { animation-delay: 300ms; }
@keyframes scnDraw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.scn-grid.is-swapping { opacity: 0 !important; }

/* Pause control (anything moving over 5s needs one) */
.scn-pause { position: absolute; left: 12px; bottom: 12px; z-index: 3; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(245,242,238,.35);
  background: rgba(13,8,6,.45); color: var(--beige); display: grid; place-items: center; cursor: pointer; }
.scn-pause__icon { width: 12px; height: 14px; border-left: 4px solid currentColor; border-right: 4px solid currentColor; box-sizing: border-box; }
.scn.is-paused .scn-pause__icon { width: 0; height: 0; border: 0; border-left: 12px solid currentColor; border-top: 7px solid transparent; border-bottom: 7px solid transparent; }
.scn-pause:focus-visible { outline: 2px solid var(--beige); outline-offset: 3px; }
.scn.is-paused .scn-halo, .scn.is-paused .scn-dust { animation-play-state: paused; }

@media (prefers-reduced-motion: reduce) {
  .scn-dim::after, .scn-dust, .scn-sym, .scn-halo { animation: none !important; }
  .scn-dim::after { opacity: 0; } .scn-sym { opacity: 1; }
  .scn-stage { transition: none; }
  .scn-grid line, .scn-grid circle { stroke-dashoffset: 0; animation: none !important; }
}

/* Pages with a scene: the band under it carries text only. */
.sem-band--text .sem-band__grid { grid-template-columns: minmax(0, 48rem); }
.scn--break { margin: var(--space-12, 3rem) 0; border-radius: 0; }

/* Symbol pages: the symbol lies on the image in plain white, no glow or halo (Nick, 2026-11-16). */
.scn--plain .scn-sym--big { filter: none; }
.scn--plain .scn-sym--big .scn-sym__ink { background: #fff; opacity: 1; }
.scn--plain .scn-sym--big .scn-sym__glow, .scn--plain .scn-halo { display: none; }

/* v3: the big symbol is drawn from its own construction file (assets/semiotics/construct/{slug}.svg):
   its real grid, axes and circles draw in faintly behind it, aligned exactly to its shape. */
.scn-sym--big.has-art { width: calc(var(--s) * 1.18); }
.scn-sym--big svg { width: 100%; height: 100%; display: block; overflow: hidden; }
.scn-sym--big .sem-solid { fill: url(#scnGold); }
.scn--plain .scn-sym--big .sem-solid { fill: #fff; }
.scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle {
  fill: none; stroke: rgba(255, 226, 190, .34); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; }
.scn--plain .scn-sym--big .construct__guides line, .scn--plain .scn-sym--big .construct__diag line, .scn--plain .scn-sym--big .construct__diag circle { stroke: rgba(255, 255, 255, .3); }
.scn-sym--big.is-drawing .construct__guides line, .scn-sym--big.is-drawing .construct__diag line, .scn-sym--big.is-drawing .construct__diag circle { animation: scnDraw 1400ms ease-out forwards; }
.scn-sym--big.is-drawing .construct__diag line, .scn-sym--big.is-drawing .construct__diag circle { animation-delay: 300ms; }
@media (prefers-reduced-motion: reduce) { .scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle { stroke-dashoffset: 0; animation: none !important; } }

/* Read more */
.sem-more { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.sem-more.is-open { display: block; -webkit-line-clamp: unset; }
.sem-more-btn { display: inline-flex; align-items: center; min-height: 44px; padding: 0; border: 0; background: none; font: inherit; font-size: .9375rem; font-weight: 600; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.sem-more-btn:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; border-radius: 4px; }

/* v4: precise construction grids measured from each symbol's path (spec: Nick, 2026-11-16).
   Hierarchy: frame (bounding box) thicker > edge guides, diagonals and fitted circles thin > centre axes fine dashes. */
.scn-sym--big { --gl: 255, 226, 190; }
.scn--plain .scn-sym--big { --gl: 255, 255, 255; }
.scn-sym--big .g-frame rect, .scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle {
  fill: none; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; }
.scn-sym--big .g-frame rect { stroke: rgba(var(--gl), .55); stroke-width: 1.5; }
.scn-sym--big .g-edge line, .scn-sym--big .g-diag line { stroke: rgba(var(--gl), .3); stroke-width: .75; }
.scn-sym--big .g-circle circle { stroke: rgba(var(--gl), .3); stroke-width: .75; }
.scn-sym--big .g-axis line { stroke: rgba(var(--gl), .32); stroke-width: .6; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; opacity: 0; transition: opacity 600ms ease; }
.scn-sym--big .g-centre circle { fill: rgba(var(--gl), .55); opacity: 0; transition: opacity 600ms ease 900ms; }
.scn-sym--big.is-drawing .g-frame rect { animation: scnDraw 900ms ease-out forwards; }
.scn-sym--big.is-drawing .g-edge line, .scn-sym--big.is-drawing .g-diag line { animation: scnDraw 1200ms ease-out 250ms forwards; }
.scn-sym--big.is-drawing .g-circle circle { animation: scnDraw 1400ms ease-out 450ms forwards; }
.scn-sym--big.is-drawing .g-axis line, .scn-sym--big.is-drawing .g-centre circle { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .scn-sym--big .g-frame rect, .scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle { stroke-dashoffset: 0; animation: none !important; }
  .scn-sym--big .g-axis line, .scn-sym--big .g-centre circle { opacity: 1; transition: none; }
}

/* Frame fades like the other lines (Nick, 2026-11-16). */
.scn-sym--big .g-frame rect { stroke: rgba(var(--gl), .3); stroke-width: .9; }

/* v5: stroke widths in screen pixels via --u (user units per px), since vector-effect is removed for the draw-on. */
.scn-sym--big .g-frame rect { stroke-width: calc(.9px * var(--u, 1)); }
.scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle,
.scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle { stroke-width: calc(.75px * var(--u, 1)); }
.scn-sym--big .g-axis line { stroke-width: calc(.6px * var(--u, 1)); stroke-dasharray: calc(3px * var(--u, 1)) calc(4px * var(--u, 1)); }

/* v6: draw-on by real length (--len set in JS), and faint Illustrator-style handles on the frame. */
.scn-sym--big .g-frame rect, .scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle,
.scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle {
  stroke-dasharray: var(--len, 1000); stroke-dashoffset: var(--len, 1000); }
@keyframes scnDraw { to { stroke-dashoffset: 0; } }
.scn-sym--big .g-handles rect { fill: rgba(13, 8, 6, .35); stroke: rgba(var(--gl), .32); stroke-width: calc(.75px * var(--u, 1)); }
.scn-sym--big .g-handles__centre { fill: rgba(var(--gl), .32); }
.scn-sym--big .g-handles { opacity: 0; transition: opacity 700ms ease 700ms; }
.scn-sym--big.is-drawing .g-handles { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .scn-sym--big .g-frame rect, .scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle,
  .scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle { stroke-dashoffset: 0; }
  .scn-sym--big .g-handles { opacity: 1; transition: none; }
}

/* v7 (Nick, 2026-11-16): square frame with every line inside it (built into the files), handles in faded white,
   symbol size kept as before now that the frame margin is tighter, no pause button (loops; still pauses on hover
   and focus, and stays still under reduced motion). */
.scn-sym--big.has-art { width: calc(var(--s) * .95); }
.scn-sym--big .g-handles rect { fill: rgba(var(--gl), .32); stroke: none; }
.scn-sym--big .g-handles__centre { fill: rgba(var(--gl), .32); }

/* v8 (Nick, 2026-11-16): symbols a little bigger, grids fainter. */
.scn-sym--big.has-art { width: calc(var(--s) * 1.08); }
.scn-sym--big .g-frame rect { stroke: rgba(var(--gl), .2); }
.scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle,
.scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle { stroke: rgba(var(--gl), .17); }
.scn-sym--big .g-axis line { stroke: rgba(var(--gl), .18); }
.scn-sym--big .g-handles rect, .scn-sym--big .g-handles__centre, .scn-sym--big .g-centre circle { fill: rgba(var(--gl), .2); }

/* v9: grids visible again: crisp 1px lines, drawn over the shape in a difference blend
   (light on the sky, dark on the symbol), still faint. */

.scn-sym--big .g-frame rect { stroke: rgba(var(--gl), .34); stroke-width: calc(1px * var(--u, 1)); }
.scn-sym--big .g-edge line, .scn-sym--big .g-diag line, .scn-sym--big .g-circle circle,
.scn-sym--big .construct__guides line, .scn-sym--big .construct__diag line, .scn-sym--big .construct__diag circle { stroke: rgba(var(--gl), .26); stroke-width: calc(1px * var(--u, 1)); }
.scn-sym--big .g-axis line { stroke: rgba(var(--gl), .26); stroke-width: calc(1px * var(--u, 1)); }
.scn-sym--big .g-handles rect, .scn-sym--big .g-handles__centre, .scn-sym--big .g-centre circle { fill: rgba(var(--gl), .38); }

/* v10: grids below the symbol; the frame's handles pulse gently (opacity only). */
.scn-sym--big.is-drawing .g-handles rect { animation: scnPulse 3.2s ease-in-out 1.6s infinite; }
@keyframes scnPulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .scn-sym--big .g-handles rect { animation: none !important; } }

/* v11: the frame is four lines (Safari cut a dashed <rect> short); each side draws in turn so the square closes. */
.scn-sym--big .g-frame-box { display: none; }
.scn-sym--big .g-frame line { fill: none; stroke: rgba(var(--gl), .34); stroke-width: calc(1px * var(--u, 1)); stroke-linecap: square;
  stroke-dasharray: var(--len, 1000); stroke-dashoffset: var(--len, 1000); }
.scn-sym--big.is-drawing .g-frame line { animation: scnDraw 380ms linear forwards; }
.scn-sym--big.is-drawing .g-frame line:nth-of-type(2) { animation-delay: 380ms; }
.scn-sym--big.is-drawing .g-frame line:nth-of-type(3) { animation-delay: 760ms; }
.scn-sym--big.is-drawing .g-frame line:nth-of-type(4) { animation-delay: 1140ms; }
@media (prefers-reduced-motion: reduce) { .scn-sym--big .g-frame line { stroke-dashoffset: 0; animation: none !important; } }

/* v12: never thinner than a hairline, even if a size is measured mid-layout. */
.scn-sym--big svg line, .scn-sym--big svg circle { stroke-width: max(calc(1px * var(--u, 1)), 0.9px); }

/* v13: line widths are set in drawing units via --u, so no element may use non-scaling strokes
   (that applied the width in screen pixels: thick lines on large drawings, faint ones on small). */
.scn-sym--big svg * { vector-effect: none !important; }

/* v14 (Nick, 2026-11-16): reveal, then step back. After drawing in, the grid settles to about a third of its strength. */
.scn-sym--big svg > g { transition: opacity 1400ms ease; }
.scn-sym--big.is-settled svg > g { opacity: .35; }

/* Downloads sit at the end of a symbol page, before the statement. */
.sem-downloads-end { margin-top: var(--space-16, 4rem); margin-bottom: var(--space-8, 2rem); }
.sem-downloads-end .sem-designers { max-width: 62rem; }

/* Symbol pages: slightly larger reading text, 17px (Nick, 2026-11-16). Scoped to pages with a symbol sky. */
main:has(.scn--plain) article p:not(.sem-eyebrow),
main:has(.scn--plain) article li,
main:has(.scn--plain) .sem-statement p,
main:has(.scn--plain) .sem-downloads-end p:not(.sem-eyebrow) { font-size: 1.0625rem; line-height: 1.65; }
main:has(.scn--plain) .sem-card__meaning { font-size: 1rem; }

/* No pause button: the rotation loops (Nick, 2026-11-16). */
.scn-pause { display: none; }

/* The archive always shows the cloth tiles; the Cloth/List switch is hidden (Nick, 2026-11-16). */
.sem-browser .sem-seg { display: none; }
/* Main archive page: the hero search does the searching, so the filter panel under it is hidden (kept in the page for the script). */
.sem-browser--nofilter .sem-filterbar { display: none; }
.sem-browser--nofilter .sem-clear-inline { margin-bottom: var(--space-3, .75rem); }
