/* The Kinstead (client/stead.ts): a scene like Kinhall's (it shares .kinhall, .hallfield, .hallplates and .hplate from
   kinhall.css), with a panel for the spot in use. A staging build. */
.stead { background: #1d3a24; }
.stead .hplate { padding: 2px 7px 3px; opacity: 1; background: linear-gradient(180deg, rgba(58, 43, 31, .97), rgba(40, 29, 21, .97)); }
.stead .hplate .nm { white-space: nowrap; }
.stead .hplate .st-lv { font-style: normal; font-weight: 700; color: #f0c45a; margin-left: 2px; font-variant-numeric: tabular-nums; }
.stead .hplate .sub { display: inline-flex; align-items: center; gap: 3px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.stead .hplate .st-ic { width: 14px; height: 14px; }
.stead .hplate.st-busy .sub { color: #e8d8b4; }
.stead .hplate.st-idle .sub { color: #ffb0a0; }
.stead .hplate.st-some .sub { color: #ffe9a8; }
.stead .hplate.st-far[data-side="l"] .nm::before { content: '‹ '; color: #f0c45a; font-weight: 700; }
.stead .hplate.st-far[data-side="r"] .nm::after { content: ' ›'; color: #f0c45a; font-weight: 700; }
.stead .hplate.st-empty { border-style: dashed; }
.stead .hplate.st-empty .nm { color: #ffe9a8; }
.stead .hplate.st-done { border-color: #f0c45a; background: linear-gradient(180deg, rgba(122, 63, 30, .96), rgba(88, 44, 20, .96)); opacity: 1; animation: st-pulse 1.4s ease-in-out infinite; }
.stead .hplate.st-done .sub { color: #ffe9a8; font-weight: 700; }
.stead .hplate.st-sel { opacity: 1; box-shadow: 0 0 0 1px rgba(20, 14, 10, .7), 0 0 0 2px #e0bd6a, 0 2px 8px rgba(0, 0, 0, .5); }
@keyframes st-pulse { 50% { box-shadow: 0 0 0 1px rgba(20, 14, 10, .7), 0 0 0 3px rgba(240, 196, 90, .55), 0 2px 8px rgba(0, 0, 0, .5); } }
@media (prefers-reduced-motion: reduce) { .stead .hplate.st-done { animation: none; } }


/* The bound materials: top left, always in view. */
.stead .st-top { position: absolute; left: 10px; top: 10px; pointer-events: none; }
.st-mats { cursor: pointer; display: flex; gap: 10px; padding: 5px 10px; border: 1px solid #7e6440; border-radius: 6px; background: linear-gradient(180deg, rgba(52, 39, 28, .94), rgba(34, 25, 18, .94));
  box-shadow: 0 0 0 1px rgba(20, 14, 10, .7), 0 2px 8px rgba(0, 0, 0, .45); font: 700 15px/1 'Crimson Pro', Georgia, serif; color: #f3e6c4; font-variant-numeric: tabular-nums; pointer-events: auto; }
.st-mats span { display: inline-flex; align-items: center; gap: 4px; }
/* Collect all: a chip flies from each store to its counter, which pulses and shows what landed (client/stead.ts haulFly). */
.st-fly { position: fixed; z-index: 70; pointer-events: none; display: inline-flex; align-items: center; gap: 3px; padding: 2px 6px 2px 3px; border-radius: 12px;
  background: rgba(34, 25, 18, .9); border: 1px solid #7e6440; box-shadow: 0 2px 6px rgba(0, 0, 0, .5); font: 700 14px/1 'Crimson Pro', Georgia, serif; will-change: transform; }
.st-fly .st-ic { width: 20px; height: 20px; }
.st-mats span b { display: inline-block; }
.st-plus { position: fixed; z-index: 70; font: 700 14px/1 'Crimson Pro', Georgia, serif; white-space: nowrap; pointer-events: none; padding: 3px 7px; border-radius: 10px;
  background: rgba(34, 25, 18, .92); border: 1px solid #7e6440; box-shadow: 0 2px 6px rgba(0, 0, 0, .5); animation: st-plus 1.3s ease-out forwards; }
@keyframes st-plus { 0% { opacity: 0; transform: translateY(-6px); } 15% { opacity: 1; transform: translateY(0); } 70% { opacity: 1; } 100% { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .st-plus { animation-duration: .6s; } }
.st-mats:hover, .st-mats:focus-visible { border-color: #c9b282; outline: none; }
.st-ic { image-rendering: pixelated; vertical-align: middle; flex: none; }

/* Collect all: bottom centre, when two or more stores hold something. */
.stead .st-all { position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%); }

/* Buttons on leather. */
.st-btn { font: 700 14px/1 'Crimson Pro', Georgia, serif; color: #f3e6c4; padding: 8px 14px; border-radius: 4px; cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid #7e6440; background: linear-gradient(180deg, #4a3828, #32251a); box-shadow: 0 1px 0 rgba(255, 255, 255, .06) inset, 0 2px 6px rgba(0, 0, 0, .4); }
.st-btn:hover, .st-btn:focus-visible { border-color: #c9b282; outline: none; }
.st-btn.small { padding: 6px 10px; font-size: 13px; }
.st-btn.primary, .st-btn.gold { color: #2a1a08; border-color: #fff0bf; background: linear-gradient(180deg, #f3cf72, #c8962f); text-shadow: 0 1px 0 rgba(255, 255, 255, .35); }
.st-btn.gem { border-color: #8fd0ff; background: linear-gradient(180deg, #2f4f78, #1f3554); }
.st-btn[aria-disabled="true"] { filter: saturate(.25) brightness(.7); }
.st-btn.armed { color: #fff; border-color: #ffb0a0; background: linear-gradient(180deg, #a8412c, #7a2a1c); text-shadow: none; }
/* The wait for the second press (client/stead.ts ARM_MS) drains along the bottom, as on the game's other two-press buttons. */
.st-btn.armed { position: relative; overflow: hidden; }
.st-btn.armed::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: currentColor; opacity: .6; transform-origin: left; animation: st-arm 8s linear forwards; pointer-events: none; }
@keyframes st-arm { from { transform: scaleX(1); } to { transform: scaleX(0); } }

/* A place's card: in the middle of the screen over the dimmed yard, like the build pop-up (Cole 11-12). On a wide
   screen a building's painted cover stands at its left as a square, with its telling under it. */
.stead .st-panelwrap { position: fixed; inset: 0; z-index: 57; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; padding: 12px;
  background: rgba(8, 6, 4, .55); animation: fade .12s ease-out; }
.stead .st-panelwrap:empty { display: none; }
/* A window opened from a card (the eggs, the Bag) stands alone; the card is back when it closes. */
body.over-open .stead .st-panelwrap, body.over-open .stead .st-revealwrap { display: none; }
body:has(.stead:not([hidden]) .st-panelwrap:not(:empty)) .cdock { visibility: hidden; }
.st-panel { box-sizing: border-box; width: 342px; max-width: 100%; max-height: 100%; overflow: hidden; display: flex; flex-direction: column; gap: 10px; padding: 12px 12px 13px; color: var(--ink);
  border: 1px solid #8a6f48; border-radius: 8px; background: linear-gradient(180deg, rgba(56, 42, 30, .985), rgba(32, 24, 17, .985));
  box-shadow: 0 0 0 1px rgba(20, 14, 10, .8), 0 16px 60px rgba(0, 0, 0, .7); font: 500 14px/1.2 'Crimson Pro', Georgia, serif; }
.st-panel.st-wide { width: auto; }
.st-cardbody { display: grid; grid-template-columns: 176px 318px; gap: 14px; min-height: 0; }
.st-main { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.st-main > .st-lore { display: none; }
.st-side { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.st-cover, .st-bp-pic { display: block; width: 176px; height: 176px; object-fit: cover; image-rendering: pixelated; border-radius: 6px; box-shadow: 0 0 0 1px #8a6f48, 0 4px 14px rgba(0, 0, 0, .5); }
.st-side .st-lore { margin: 0; font-size: 14.5px; text-align: center; text-wrap: balance; }
.st-panel header { display: flex; align-items: center; gap: 10px; min-height: 30px; }
.st-panel .st-title { font: 700 23px/1 'Cormorant Garamond', Georgia, serif; letter-spacing: .02em; color: #f3e3b4; white-space: nowrap; }
.st-panel .st-lvl { color: var(--muted); font-size: 14px; white-space: nowrap; }
.st-panel .st-x { margin-left: auto; width: 32px; height: 32px; border: 0; border-radius: 4px; background: none; color: var(--muted); font: 400 24px/1 Georgia, serif; cursor: pointer; }
.st-panel .st-x:hover, .st-panel .st-x:focus-visible { color: #fff; background: rgba(255, 255, 255, .08); outline: none; }
.st-panel footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 34px; }
.st-hint { color: var(--muted); }

.st-tabs { display: flex; gap: 4px; }
.st-tabs button { flex: 1; padding: 6px 2px; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 600 13.5px/1 'Crimson Pro', Georgia, serif; cursor: pointer; white-space: nowrap; }
.st-tabs button:hover, .st-tabs button:focus-visible { border-color: #b39a66; outline: none; }
.st-tabs button.on { border-color: #f0c45a; background: rgba(240, 196, 90, .18); color: #ffe9a8; }

.st-info, .st-facts { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 13.5px; }
.st-facts { flex-direction: column; align-items: flex-start; gap: 3px; }
.st-info > span, .st-facts > span { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.st-info b, .st-facts b { color: #f3e6c4; }
.st-info i { font-style: normal; font-weight: 700; color: #f0c45a; }
.st-info .st-el { color: color-mix(in srgb, var(--el) 62%, #fff); }
.st-info .st-on b { color: #9fd08a; }
.st-info .st-off b { color: var(--faint); }

/* The build menu. */
.st-bgrid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 5px; }
.st-bt { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; height: 82px; padding: 4px 2px 5px; border: 1px solid #4e3d2a; border-radius: 4px; background: rgba(0, 0, 0, .25); color: var(--ink); cursor: pointer; font: 600 12.5px/1 'Crimson Pro', Georgia, serif; }
.st-bt:hover, .st-bt:focus-visible { border-color: #b39a66; outline: none; }
.st-bt.on { border-color: #f0c45a; background: rgba(240, 196, 90, .2); box-shadow: 0 0 0 1px #f0c45a inset; }
.st-bt.off { opacity: .45; }
.st-bt span { white-space: nowrap; }
.st-bt > i:last-child { position: absolute; top: 3px; right: 4px; font-style: normal; font-weight: 700; font-size: 11px; color: #f0c45a; }
.st-thumb { display: block; flex: none; background-repeat: no-repeat; background-position: 0 0; image-rendering: pixelated; }
.st-what { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.st-what > b { color: #f3e6c4; font-weight: 600; }

/* Costs. */
.st-costs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-variant-numeric: tabular-nums; }
.st-cost { display: inline-flex; align-items: center; gap: 3px; color: #e8d8b4; white-space: nowrap; }
.st-cost b { color: #f3e6c4; }
.st-cost.short, .st-cost.short b { color: #ff9a86; }

/* Workers: a place each, with who stands in it; a tap opens the picker pop-up. */
.st-slots { display: grid; grid-template-columns: repeat(var(--n, 3), 1fr); gap: 6px; }
.st-slot { position: relative; min-width: 0; height: 92px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 4px 3px; border: 1px dashed #6a563a; border-radius: 5px; background: rgba(0, 0, 0, .2); color: var(--muted); font: 600 12.5px/1.1 'Crimson Pro', Georgia, serif; cursor: pointer; }
.st-slot:hover, .st-slot:focus-visible { border-color: #c9b282; outline: none; }
.st-slot.on { border-style: solid; border-color: #b39a66; background: rgba(240, 196, 90, .1); }
.st-slot.locked { opacity: .6; }
.st-slot.empty b { font: 700 28px/1 Georgia, serif; color: #f0c45a; }
.st-slot img { width: 48px; height: 48px; object-fit: contain; image-rendering: pixelated; }
.st-sn { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; color: #f3e6c4; }
.st-ss { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 12px; white-space: nowrap; }
.st-ss .gr { transform: scale(.82); transform-origin: center; }
.st-ss .st-mult { position: static; color: #f0c45a; font-size: 12px; }
.st-grid { display: grid; grid-template-columns: repeat(var(--cols), 46px); grid-auto-rows: 46px; gap: 4px; justify-content: space-between; height: calc(var(--rows) * 50px - 4px); align-content: start; }
.st-c { position: relative; width: 46px; height: 46px; padding: 0; display: flex; align-items: center; justify-content: center; border: 1px solid #4e3d2a; border-radius: 4px; background: rgba(0, 0, 0, .25); cursor: pointer; }
.st-c img { width: 40px; height: 40px; object-fit: contain; image-rendering: pixelated; }
.st-c.st-item img { width: 32px; height: 32px; }
.st-c:hover, .st-c:focus-visible { border-color: #b39a66; outline: none; }
.st-c.match { border-color: #7d6a3a; background: rgba(240, 196, 90, .09); }
.st-c.on { border-color: #f0c45a; background: rgba(240, 196, 90, .22); box-shadow: 0 0 0 1px #f0c45a inset; }
.st-c .gr { position: absolute; top: 1px; left: 1px; transform: scale(.82); transform-origin: top left; }
.st-mult { position: absolute; right: 2px; bottom: 1px; font: 700 10.5px/1 'Crimson Pro', Georgia, serif; font-style: normal; color: #cdbb96; text-shadow: 0 1px 1px #000, 0 0 2px #000; }
.st-c.match .st-mult, .st-slot .st-mult { color: #f0c45a; }
.st-none { grid-column: 1 / -1; margin: 0; align-self: center; text-align: center; color: var(--muted); }
.st-pager { display: flex; align-items: center; justify-content: center; gap: 10px; height: 22px; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.st-pager button { width: 30px; height: 22px; padding: 0; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 700 15px/1 Georgia, serif; cursor: pointer; }
.st-pager button:disabled { opacity: .35; cursor: default; }
.st-store { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; }
.st-store .st-prog { flex: 1; }

.st-prog { display: flex; align-items: center; gap: 8px; font-variant-numeric: tabular-nums; color: var(--ink); }
.st-prog span { white-space: nowrap; text-align: right; }
.st-bar { flex: 1; min-width: 30px; height: 8px; border-radius: 4px; background: rgba(0, 0, 0, .45); overflow: hidden; box-shadow: 0 0 0 1px #4e3d2a; }
.st-bar > i { display: block; height: 100%; background: linear-gradient(180deg, #ffc27a, #e08a3a); }

/* Upgrades. */
.st-up { display: flex; align-items: center; gap: 10px; min-height: 70px; }
.st-upart { width: 68px; display: flex; align-items: flex-end; justify-content: center; flex: none; }
.st-upinfo { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.st-upinfo > b { color: #ffe9a8; font-size: 15.5px; }
.st-upinfo > b i { font-style: normal; font-weight: 500; color: var(--muted); }
.st-upinfo ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; color: var(--ink); font-size: 13.5px; }

/* Crafting. */
.st-line { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border: 1px solid #4e3d2a; border-radius: 4px; background: rgba(0, 0, 0, .22); }
.st-line.done { border-color: #f0c45a; background: rgba(240, 196, 90, .14); }
.st-line img, .st-recipe img { image-rendering: pixelated; flex: none; }
.st-ln { flex: 1 1 170px; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
/* A running craft's Finish now and Cancel: beside the craft, or on their own row when the card is narrow. */
.st-line { flex-wrap: wrap; }
.st-lacts { display: flex; gap: 6px; margin-left: auto; flex: none; }
.st-ln b { color: #f3e6c4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-ln small { color: var(--muted); font-size: 13px; }
.st-rgrid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 4px; }
.st-r { position: relative; height: 46px; padding: 0; display: flex; align-items: center; justify-content: center; border: 1px solid #4e3d2a; border-radius: 4px; background: rgba(0, 0, 0, .25); cursor: pointer; }
.st-r:hover, .st-r:focus-visible { border-color: #b39a66; outline: none; }
.st-r img { image-rendering: pixelated; }
.st-r.locked img { filter: grayscale(1) brightness(.55); }
.st-r i { position: absolute; left: 0; right: 0; bottom: 1px; text-align: center; font: 700 10.5px/1 'Crimson Pro', Georgia, serif; font-style: normal; color: #e8d8b4; text-shadow: 0 1px 1px #000, 0 0 2px #000; }
.st-recipe { display: flex; align-items: center; gap: 8px; }
.st-back { width: 26px; height: 40px; padding: 0; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 700 18px/1 Georgia, serif; cursor: pointer; flex: none; }
.st-els { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; }
.st-els button { height: 30px; padding: 0; border: 1px solid #4e3d2a; border-radius: 4px; background: rgba(0, 0, 0, .25); cursor: pointer; }
.st-els button.on { border-color: #f0c45a; background: rgba(240, 196, 90, .22); }
.st-pieces { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--ink); }
.st-pieces small { color: var(--muted); margin-left: 4px; }
.st-step { display: inline-flex; align-items: center; gap: 8px; }
.st-step button { width: 28px; height: 26px; padding: 0; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 700 16px/1 Georgia, serif; cursor: pointer; }
.st-step button:disabled { opacity: .35; cursor: default; }
.st-step b { min-width: 12px; text-align: center; color: #ffe9a8; font-variant-numeric: tabular-nums; }
.st-fl { display: flex; align-items: center; gap: 8px; min-width: 0; }
.st-q { color: var(--muted); white-space: nowrap; }
.st-q b { color: #ffe9a8; }
.st-master { padding: 5px 8px; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 600 13px/1 'Crimson Pro', Georgia, serif; cursor: pointer; }
.st-master.on { border-color: #f0c45a; background: rgba(240, 196, 90, .22); color: #ffe9a8; }

/* The Hatchery and the grove. */
.st-acts { display: flex; flex-direction: column; gap: 6px; }
.st-acts .st-btn { justify-content: center; }
.st-acts .st-btn small { font-weight: 400; opacity: .8; }
.st-lvl .kf { display: inline-flex; align-items: center; gap: 4px; }
/* The Hatchery: every nest a tile (the eggs warming, empty ones to fill, the ones not yet had). */
.st-nestgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.st-nest { min-width: 0; height: 104px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; padding: 6px 5px 6px; border: 1px solid #4e3d2a; border-radius: 6px;
  background: radial-gradient(ellipse 60% 30% at 50% 58%, rgba(214, 160, 82, .2), transparent 70%), rgba(0, 0, 0, .25); color: var(--ink); font: 600 13px/1.1 'Crimson Pro', Georgia, serif; cursor: pointer; }
.st-nest:hover, .st-nest:focus-visible { border-color: #b39a66; outline: none; }
.st-nest-pic { flex: 1; display: grid; place-items: center; min-height: 0; }
.st-nest .egg-ic { width: 30px; height: 39px; }
.st-nest b { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: #f3e6c4; }
.st-nest small { display: inline-flex; align-items: center; gap: 3px; color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-nest .st-bar { flex: none; width: 100%; height: 6px; }
@media (max-width: 360px) { .st-nest b { font-size: 12px; } }
/* A just-laid egg still shows a sliver, so the bar reads as one that fills. */
.st-nest .st-bar > i { min-width: 3px; }
.st-nest.ready { border-color: #f0c45a; animation: st-pulse 1.4s ease-in-out infinite; }
.st-nest.ready small { color: #ffe9a8; font-weight: 700; }
.st-nest.empty { border-style: dashed; }
.st-nest.empty b, .st-nest.empty .st-nest-pic > b { font: 400 26px/1 Georgia, serif; color: #f0c45a; }
.st-nest.locked { opacity: .55; }
.st-nest.locked.next { opacity: 1; }
.st-nest.locked .st-nest-pic svg { width: 18px; height: 18px; color: #b39a66; }
.st-nest.locked.next small { color: #f3e6c4; }
.st-nests, .st-tiers { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
.st-nests li, .st-tiers li { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 24px; padding: 0 6px; border-radius: 4px; background: rgba(0, 0, 0, .2); color: var(--ink); }
.st-nests li small { color: var(--muted); }
.st-nests li.locked { opacity: .5; }
.st-nests li .st-prog { flex: 1; max-width: 170px; }
.st-tiers li { justify-content: flex-start; min-height: 38px; }
.st-tiers li span { flex: 1; }
.st-tiers li b { color: #f3e6c4; font-variant-numeric: tabular-nums; }
.st-tier-pic { flex: none; display: flex; justify-content: center; align-items: center; width: 34px; height: 34px; }

/* A craft just taken. */
.stead .st-revealwrap { position: fixed; inset: 0; z-index: 57; pointer-events: none; }
.stead .st-revealwrap:empty { display: none; }
.st-reveal { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(8, 6, 4, .55); pointer-events: auto; }
.st-rcard { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 220px; max-width: calc(100% - 24px); padding: 16px 20px 14px; border: 1px solid #b39a66; border-radius: 8px;
  background: linear-gradient(180deg, rgba(58, 43, 30, .98), rgba(32, 23, 16, .98)); box-shadow: 0 0 0 1px rgba(20, 14, 10, .8), 0 10px 40px rgba(0, 0, 0, .7); color: var(--ink); font: 500 14.5px/1.25 'Crimson Pro', Georgia, serif; }
.st-rcard img { image-rendering: pixelated; }
.st-rname { font: 700 21px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; text-align: center; }
.st-rq { display: flex; align-items: baseline; gap: 6px; }
.st-rq > b { font: 700 40px/1 'Cormorant Garamond', Georgia, serif; color: #f3e6c4; font-variant-numeric: tabular-nums; min-width: 2ch; text-align: center; }
.st-rq small { color: var(--muted); }
.st-rgrade { font-weight: 700; color: #f0c45a; padding: 1px 6px; border: 1px solid #7e6440; border-radius: 4px; }
.st-reveal.landed.q-85 .st-rq > b { color: #9fd0ff; }
.st-reveal.landed.q-95 .st-rq > b { color: #d7a6ff; }
.st-reveal.landed.q-top .st-rq > b { color: #ffd45a; text-shadow: 0 0 14px rgba(255, 212, 90, .7); }
.st-reveal.landed .st-rq > b { animation: st-land .35s ease-out; }
@keyframes st-land { 0% { transform: scale(1.35); } 100% { transform: scale(1); } }
.st-rlines { list-style: none; margin: 0; padding: 0; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.st-reveal:not(.landed) .st-rlines, .st-reveal:not(.landed) .st-rgrade { visibility: hidden; }
@media (prefers-reduced-motion: reduce) { .st-reveal.landed .st-rq > b { animation: none; } }

@media (max-width: 620px) {
  .stead .st-panelwrap { padding: 6px; }
  .st-panel { width: 100%; gap: 6px; padding: 9px 10px 10px; }
  .st-panel .st-title { font-size: 20px; }
  .st-slot { height: 48px; }
  .st-bt { height: 62px; font-size: 11.5px; }
  .st-up { min-height: 56px; }
  .stead .st-top { left: 6px; top: 6px; }
  .st-mats { gap: 8px; padding: 4px 8px; font-size: 14px; }
  .stead.st-open .st-top { display: none; }
}

/* A creature away at work, on its card in Creatures (beside the TEAM tag's place). */
.teamtag.worktag, .teamtag.away { color: #b5651d; }
.st-r .st-rn { font-size: 10px; letter-spacing: -.2px; }

/* The telling of a place, in the game's own voice. */
.st-lore { margin: 0; font-style: italic; color: #d8c8a4; font-size: 14px; line-height: 1.3; text-wrap: pretty; }
.st-clock { color: #cdbb96; }
.st-acts.st-row { flex-direction: row; }
.st-acts.st-row .st-btn { flex: 1; }

/* A producer's store: how much waits, how fast it fills. */
.st-storebox { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid #4e3d2a; border-radius: 6px; background: rgba(0, 0, 0, .25); }
.st-storebox.full { border-color: #f0c45a; background: rgba(240, 196, 90, .1); }
.st-sb-ic .st-ic { width: 36px; height: 36px; }
.st-sb-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.st-sb-top { display: flex; align-items: baseline; gap: 6px; }
.st-sb-top b { font: 700 25px/1 'Cormorant Garamond', Georgia, serif; color: #ffe9a8; font-variant-numeric: tabular-nums; }
.st-sb-top span, .st-sb-sub { color: var(--muted); font-size: 13px; }
.st-sb-sub { display: flex; justify-content: space-between; gap: 8px; font-variant-numeric: tabular-nums; }
.st-sb-sub b { color: #f3e6c4; }
.st-storebox .st-bar { flex: none; width: 100%; height: 10px; }

/* The green: the showcase. */
.st-show { display: grid; grid-template-columns: repeat(6, 46px); gap: 4px; justify-content: space-between; }
.st-c.empty { color: #f0c45a; font: 700 20px/1 Georgia, serif; border-style: dashed; }

/* ---- pop-ups (client/pop.ts) ---- */
.st-pop .st-btn[aria-disabled="true"] { cursor: default; }

/* The build pop-up: the buildings at the left; the picked one's cover, telling, price and time at the right. */
.st-buildpop { width: 780px; }
.st-bp { display: grid; grid-template-columns: 286px 1fr; gap: 12px; min-height: 0; }
.st-bp-list { display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); gap: 6px; align-content: start; }
.st-bp-list .st-bt { height: 98px; font-size: 13px; }
.st-bp-info { display: grid; grid-template-columns: 176px 1fr; grid-template-rows: 1fr auto; gap: 12px 14px; padding: 12px; border: 1px solid #5c4830; border-radius: 6px; background: rgba(0, 0, 0, .22); min-width: 0; }
.st-bp-cover { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 10px; min-height: 236px; padding: 12px 8px 10px; border-radius: 6px;
  background: radial-gradient(ellipse 70% 34% at 50% 60%, rgba(128, 168, 86, .38), transparent 70%), linear-gradient(180deg, rgba(40, 58, 66, .55), rgba(28, 44, 30, .6)); box-shadow: 0 0 0 1px #4e3d2a inset; }
.st-bp-cover > .st-thumb { margin-top: auto; }
/* The painted cover: a square in the middle of its column, what it grows into under it. */
.st-bp-cover.pic { padding: 0; gap: 12px; justify-content: center; background: none; box-shadow: none; }
.st-bp-cover.pic .st-bp-grow { border-top: 0; padding-top: 0; }
.st-bp-grow { display: flex; align-items: flex-end; justify-content: center; gap: 10px; width: 100%; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, .08); }
.st-bp-grow span { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.st-bp-grow small { font: 700 11px/1 'Crimson Pro', Georgia, serif; color: #f0c45a; }
.st-bp-txt { display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.st-bp-name { font: 700 26px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; }
.st-bp-name .st-lv { font-style: normal; color: #f0c45a; }
.st-bp-txt .st-lore { font-size: 15.5px; }
.st-does { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; color: #e8d8b4; }
.st-does li { line-height: 1.3; }
.st-does li .st-ic { margin-right: 4px; vertical-align: -3px; }
.st-does b { color: #f3e6c4; }
.st-fav { display: inline-flex; align-items: center; gap: 4px; }
.st-bp-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 10px; border-top: 1px solid #4e3d2a; }
.st-bp-foot .st-costs { font-size: 16px; gap: 4px 14px; }
.st-bp-foot .st-btn { padding: 10px 26px; font-size: 16px; }
/* Build new or bring back: one chip per stored level, so any number of copies stays one short row. */
.st-bp-foot:has(.st-bp-from) { flex-wrap: wrap; row-gap: 8px; }
.st-bp-from { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; flex-basis: 100%; }
.st-bp-fromlbl { margin: 0 2px 0 6px; color: var(--muted); font-size: 13.5px; }
.st-bp-from > .st-bp-fromlbl:first-child { margin-left: 0; }
.st-chip { height: 28px; padding: 0 11px; border: 1px solid #6a5434; border-radius: 14px; background: rgba(0, 0, 0, .28); color: #e8d8b4; font: 700 13.5px/1 'Crimson Pro', Georgia, serif; cursor: pointer; white-space: nowrap; }
.st-chip small { font-weight: 500; opacity: .8; }
.st-chip:hover, .st-chip:focus-visible { border-color: #c9b282; color: #fff; outline: none; }
.st-chip.on { color: #2a1a08; border-color: #fff0bf; background: linear-gradient(180deg, #f3cf72, #c8962f); }
.st-chip.on small { opacity: .9; }

/* The creature picker pop-up: filters and the list at the left, the creature in focus at the right. */
.st-pickpop { width: 800px; }
.st-pk { display: grid; grid-template-columns: 1fr 236px; gap: 12px; min-height: 0; }
.st-pk-main { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.st-pk-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
/* The search row: thousands of creatures narrowed by name, grade and the best of each kind. */
.st-pk-find { display: flex; align-items: center; gap: 6px; min-width: 0; }
.st-pk-find input, .st-pk-find select { box-sizing: border-box; height: 30px; min-width: 0; padding: 0 9px; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .3); color: var(--ink); font: 500 14px/1 'Crimson Pro', Georgia, serif; }
.st-pk-find input { flex: 1 1 auto; }
.pop-card .st-pk-find :is(input, select) { color: #f3e6c4; -webkit-text-fill-color: #f3e6c4; background-color: rgba(0, 0, 0, .3); box-shadow: none; font-family: 'Crimson Pro', Georgia, serif; }
.pop-card .st-pk-find select { padding-right: 22px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7'%3E%3Cpath d='M0 0h10L5 7z' fill='%23e0bd6a'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 7px center; }
.pop-card .st-pk-find select option { color: #2a1a08; -webkit-text-fill-color: #2a1a08; background: #f3e6c4; }
.st-pk-find input::placeholder { color: var(--faint); }
.st-pk-find select { flex: none; }
.st-pk-find input:focus-visible, .st-pk-find select:focus-visible { outline: none; border-color: #b39a66; }
.st-pk-one { flex: none; height: 30px; padding: 0 10px; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 600 13px/1 'Crimson Pro', Georgia, serif; white-space: nowrap; cursor: pointer; }
.st-pk-one.on { border-color: #f0c45a; background: rgba(240, 196, 90, .2); color: #ffe9a8; }
/* Favorites only, and a one-tap star by the picked creature's name (Cole 2026-11-13). */
.st-pk-fav { padding: 0 9px; font-size: 16px; }
.st-bs { display: none; }
@media (max-width: 420px) { .st-pk-one .st-bl { display: none; } .st-pk-one .st-bs { display: inline; } }
.st-pk-fav.on { color: #f0c45a; }
.st-pk-nmrow { display: flex; align-items: center; justify-content: center; max-width: 100%; min-width: 0; }
.st-pk-nmrow .st-pk-name { min-width: 0; }
.st-pk-star { flex: none; margin-left: 6px; padding: 0 2px; border: 0; background: none; font-size: 20px; line-height: 1; vertical-align: 1px; color: rgba(243, 227, 180, .55); cursor: pointer; }
.st-pk-star.on, .st-pk-star:hover { color: #f0c45a; }
.st-pager span { min-width: 92px; text-align: center; }
.st-pk-els, .st-pk-sort { display: flex; gap: 3px; }
.st-pk-els button, .st-pk-sort button { height: 30px; min-width: 32px; padding: 0 5px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid #5c4830; border-radius: 4px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 600 13px/1 'Crimson Pro', Georgia, serif; cursor: pointer; }
.st-pk-els button:first-child, .st-pk-sort button { padding: 0 9px; }
.st-pk-els button:hover, .st-pk-sort button:hover, .st-pk-els button:focus-visible, .st-pk-sort button:focus-visible { border-color: #b39a66; outline: none; }
.st-pk-els button.on, .st-pk-sort button.on { border-color: #f0c45a; background: rgba(240, 196, 90, .2); color: #ffe9a8; }
.st-pk-els button.want { box-shadow: 0 -2px 0 #f0c45a inset; }
.st-pk-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); grid-auto-rows: 70px; gap: 6px; height: calc(var(--rows) * 76px - 6px); align-content: start; }
.st-pc { position: relative; min-width: 0; padding: 0; display: flex; align-items: center; justify-content: center; border: 1px solid #4e3d2a; border-radius: 5px; background: rgba(0, 0, 0, .25); cursor: pointer; }
.st-pc img { width: 54px; height: 54px; object-fit: contain; image-rendering: pixelated; }
.st-pc:hover, .st-pc:focus-visible { border-color: #b39a66; outline: none; }
.st-pc.match { background: rgba(240, 196, 90, .08); border-color: #7d6a3a; }
.st-pc.on { border-color: #f0c45a; background: rgba(240, 196, 90, .2); }
.st-pc.focus { box-shadow: 0 0 0 2px #fff0bf; }
.st-pc .gr { position: absolute; top: 2px; left: 2px; transform: scale(.82); transform-origin: top left; }
.st-pl { position: absolute; left: 4px; bottom: 2px; font: 700 11px/1 'Crimson Pro', Georgia, serif; font-style: normal; color: #cdbb96; text-shadow: 0 1px 1px #000, 0 0 2px #000; }
.st-pc .st-mult { right: 4px; bottom: 2px; font-size: 11px; }
.st-pc.match .st-mult { color: #f0c45a; }
.st-tick { position: absolute; top: 3px; right: 3px; width: 14px; height: 14px; border-radius: 50%; background: #f0c45a; box-shadow: 0 0 0 1px #2a1a08; }
.st-tick::after { content: ''; position: absolute; left: 4px; top: 2px; width: 4px; height: 7px; border: solid #2a1a08; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.st-pc .st-team { position: absolute; top: 3px; right: 3px; padding: 1px 4px; border-radius: 3px; background: rgba(20, 14, 10, .78); color: #f0c45a; font: 700 10.5px/1.2 'Crimson Pro', Georgia, serif; font-style: normal; text-align: center; letter-spacing: .04em; text-transform: uppercase; }
.st-pk-grid .st-none { align-self: center; padding: 20px 0; }
.st-pk-side { display: flex; flex-direction: column; align-items: center; gap: 9px; padding: 12px; border: 1px solid #5c4830; border-radius: 6px; background: rgba(0, 0, 0, .22); min-width: 0; }
.st-pk-art { width: 128px; height: 128px; display: grid; place-items: center; border-radius: 6px; background: radial-gradient(ellipse 70% 30% at 50% 82%, rgba(128, 168, 86, .38), transparent 70%); }
.st-pk-art img { max-width: 128px; max-height: 128px; image-rendering: pixelated; }
.st-pk-who { display: flex; flex-direction: column; align-items: center; gap: 4px; max-width: 100%; }
.st-pk-name { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 700 20px/1.1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; }
.st-pk-sub { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); font-size: 13.5px; }
.st-pk-facts { width: 100%; margin: 0; display: flex; flex-direction: column; gap: 3px; font-size: 13.5px; }
.st-meter { position: relative; display: block; width: 84px; height: 9px; margin: 0; border-radius: 999px; overflow: hidden; align-self: center;
  background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1px rgba(240, 196, 90, .35); }
.st-meter i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: inherit; background: linear-gradient(180deg, #ffe9a8, #e0a53a); box-shadow: 0 0 5px rgba(240, 196, 90, .55); }
.st-pk-facts > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 3px 7px; border-radius: 4px; background: rgba(0, 0, 0, .22); }
.st-pk-facts dt { color: var(--muted); }
.st-pk-facts dd { margin: 0; display: inline-flex; align-items: center; gap: 4px; color: #f3e6c4; font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-pk-facts dd b, .st-pk-facts dd.hit { color: #f0c45a; }
.st-pk-facts dd.miss { color: var(--faint); }
.st-pk-note { margin: 0; text-align: center; color: #d8c8a4; font-size: 14px; text-wrap: balance; }
.st-pk-note b { color: #9fd08a; }
.st-pk-side .st-btn { margin-top: auto; width: 100%; justify-content: center; padding: 10px 12px; font-size: 15px; }

@media (max-width: 620px) {
  .st-panel .st-lore { display: none; }
  .st-slot { height: 78px; gap: 1px; padding: 3px 2px; }
  .st-slot img { width: 36px; height: 36px; }
  .st-slot .st-sn { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .st-storebox { padding: 6px 8px; }
  .st-sb-top b { font-size: 21px; }
  /* The build pop-up stacks: a strip of buildings over the picked one. */
  .st-buildpop { width: 100%; }
  .st-bp { grid-template-columns: 1fr; gap: 8px; }
  .st-bp-list .st-bt { height: 66px; font-size: 10.5px; padding: 2px 1px 3px; gap: 1px; min-width: 0; }
  .st-bp-list .st-bt span { max-width: 100%; min-height: 21px; display: flex; align-items: center; white-space: normal; text-align: center; }
  @media (max-width: 350px) { .st-bp-list .st-bt { font-size: 10px; letter-spacing: -.2px; padding-left: 0; padding-right: 0; } }
  .st-bp-info { grid-template-columns: 88px 1fr; gap: 8px 10px; padding: 8px; }
  .st-bp-cover.pic { gap: 6px; }
  .st-bp-pic { width: 88px; height: 88px; }
  .st-bp-cover { min-height: 0; padding: 8px 4px 6px; gap: 6px; }
  .st-bp-grow { gap: 4px; padding-top: 5px; }
  .st-bp-name { font-size: 21px; }
  .st-bp-txt { gap: 6px; }
  .st-bp-txt .st-lore { font-size: 13.5px; }
  .st-does { font-size: 13px; gap: 4px; }
  .st-bp-foot .st-btn { padding: 9px 18px; }
  /* The picker stacks too: the list, then the creature in focus as a strip. */
  .st-pickpop { width: 100%; }
  .st-pk { grid-template-columns: 1fr; gap: 8px; }
  .st-pk-els button { min-width: 0; flex: 1; height: 28px; padding: 0 2px; }
  .st-pk-els { flex: 1 1 100%; }
  .st-pk-sort { flex: 1 1 100%; }
  .st-pk-sort button { flex: 1; height: 28px; }
  .st-pk-grid { grid-auto-rows: 56px; gap: 4px; height: calc(var(--rows) * 60px - 4px); }
  .st-pc img { width: 44px; height: 44px; }
  .st-pk-side { display: grid; grid-template-columns: 64px 1fr; grid-template-rows: auto auto; align-items: center; gap: 4px 10px; padding: 8px; }
  .st-pk-art { width: 64px; height: 64px; grid-row: 1 / span 2; }
  .st-pk-art img { max-width: 64px; max-height: 64px; }
  .st-pk-who { align-items: flex-start; }
  .st-pk-name { font-size: 17px; }
  .st-pk-facts { flex-direction: row; flex-wrap: wrap; gap: 3px; font-size: 12px; }
  .st-pk-facts > div { padding: 2px 5px; gap: 4px; }
  .st-pk-note { text-align: left; font-size: 13px; }
  .st-pk-side .st-btn { grid-column: 1 / -1; padding: 9px 12px; }
}

/* ---- the Shrines pop-up (client/shrines.ts) ---- */
.sh-pop { width: 780px; }
.sh { display: flex; flex-direction: column; gap: 10px; min-height: 0; }
.sh-peds { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.sh-ped { min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; height: 176px; padding: 8px 4px 8px; border: 1px solid #4e3d2a; border-radius: 6px; cursor: pointer; color: var(--ink);
  background: radial-gradient(ellipse 80% 26% at 50% 46%, rgba(128, 168, 86, .3), transparent 70%), rgba(0, 0, 0, .25); font: 500 13px/1.15 'Crimson Pro', Georgia, serif; }
.sh-ped:hover, .sh-ped:focus-visible { border-color: #b39a66; outline: none; }
.sh-ped.on { border-color: #f0c45a; box-shadow: 0 0 0 1px #f0c45a inset; background-color: rgba(240, 196, 90, .1); }
.sh-ped.empty { border-style: dashed; color: var(--muted); }
.sh-ped.empty .st-thumb { opacity: .7; }
.sh-ped > .st-thumb { margin-bottom: auto; margin-top: auto; }
.sh-ped > b { font: 700 16px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; white-space: nowrap; }
.sh-share { color: #f0c45a; font-weight: 700; }
.sh-posts { display: flex; gap: 4px; }
.sh-post { width: 30px; height: 30px; display: grid; place-items: center; border: 1px dashed #6a563a; border-radius: 4px; background: rgba(0, 0, 0, .25); color: #f0c45a; font: 700 16px/1 Georgia, serif; font-style: normal; }
.sh-post.on { border-style: solid; border-color: #b39a66; }
.sh-post img { width: 28px; height: 28px; object-fit: contain; image-rendering: pixelated; }
.sh-sub { font-size: 12px; color: var(--muted); white-space: nowrap; }
.sh-sub.good { color: #9fd08a; }
.sh-sub.warn { color: #ffb0a0; }
.sh-ped.t2 > b { color: #9fd0ff; } .sh-ped.t3 > b { color: #d7a6ff; } .sh-ped.t4 > b { color: #ffd45a; }

.sh-ctx { display: flex; flex-direction: column; gap: 8px; min-height: 150px; padding: 10px 12px; border: 1px solid #5c4830; border-radius: 6px; background: rgba(0, 0, 0, .22); }
.sh-ctx-h { display: flex; align-items: center; gap: 10px; }
.sh-ctx-h > b { font: 700 19px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; white-space: nowrap; }
.sh-what { color: #d8c8a4; font-style: italic; min-width: 0; }
.sh-acts { margin-left: auto; display: flex; gap: 6px; flex: none; }
.sh-spares { display: flex; flex-direction: column; gap: 5px; }
.sh-spare { display: flex; align-items: center; gap: 10px; padding: 4px 8px; border-radius: 5px; background: rgba(0, 0, 0, .22); }
.sh-sp-nm { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.sh-sp-nm b { color: #f3e6c4; }
.sh-sp-nm small { color: var(--muted); }
.sh-sp-n { font: 700 18px/1 'Cormorant Garamond', Georgia, serif; color: #ffe9a8; }
.sh-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sh-odds { display: flex; flex-wrap: wrap; gap: 3px 10px; color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.sh-odds span { white-space: nowrap; }
.sh-odds b { color: #d8c8a4; font-weight: 600; margin-right: 3px; }
.sh-odds .t2 b { color: #9fd0ff; } .sh-odds .t3 b { color: #d7a6ff; } .sh-odds .t4 b { color: #ffd45a; }
.sh-raise { display: flex; align-items: center; gap: 10px; flex: none; }
.sh-roll { align-items: center; justify-content: center; text-align: center; }
.sh-rollart { height: 100px; display: grid; place-items: end center; }
.sh-roll:not(.landed) .sh-rollart { filter: brightness(1.15) saturate(.8); }
.sh-rollname { font: 700 22px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; }
.sh-rolling { color: var(--muted); font-style: italic; font-weight: 500; }
.sh-roll.landed .sh-rollname { animation: st-land .35s ease-out; color: #ffe9a8; }
.sh-roll.landed.t2 .sh-rollname { color: #9fd0ff; } .sh-roll.landed.t3 .sh-rollname { color: #d7a6ff; } .sh-roll.landed.t4 .sh-rollname { color: #ffd45a; text-shadow: 0 0 14px rgba(255, 212, 90, .7); }
.sh-rollsub { color: #d8c8a4; }
.sh-rollacts { display: flex; gap: 8px; margin-top: 2px; }

/* The Team page's one-line view of the shrines (client/creatures.ts shrinesStrip). */
.tn-sec.shs { flex-wrap: wrap; gap: 6px 10px; margin-top: 14px; }
.shs-chips { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.shs-chip { display: inline-flex; align-items: center; gap: 5px; height: 32px; padding: 0 8px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--panel-2); color: var(--ink); font: inherit; font-size: 13px; cursor: pointer; }
.shs-chip:hover { border-color: var(--gold); }
.shs-chip span { color: var(--gold); font-weight: 600; }
.shs-chip img { width: 26px; height: 26px; object-fit: contain; image-rendering: pixelated; }
.shs-chip i { font-style: normal; color: var(--muted); }

@media (max-width: 620px) {
  .sh-pop { width: 100%; }
  .sh-peds { gap: 4px; }
  .sh-ped { height: 132px; padding: 5px 2px 6px; font-size: 11.5px; }
  .sh-ped > b { font-size: 13.5px; }
  .sh-ped > .st-thumb { transform: scale(.75); margin: -4px 0; }
  @media (max-width: 440px) { .sh-ped { height: 118px; } .sh-ped .sh-sub { display: none; } }
  .sh-post { width: 24px; height: 24px; }
  .sh-post img { width: 22px; height: 22px; }
  .sh-sub { font-size: 10.5px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .sh-ctx { padding: 8px; min-height: 0; }
  .sh-ctx-h { flex-wrap: wrap; gap: 4px 8px; }
  .sh-what { flex: 1 1 100%; order: 3; font-size: 13px; }
  .sh-foot { flex-direction: column; align-items: stretch; gap: 8px; }
  .sh-odds { font-size: 11.5px; gap: 2px 8px; justify-content: center; }
  .sh-raise { justify-content: space-between; }
}

/* Touch sizes on a phone: every control in the yard's cards and pop-ups is at least 32 px to the thumb. */
@media (max-width: 620px) {
  .st-panel .st-x { width: 34px; height: 34px; margin: -4px -4px -4px auto; }
  .st-tabs button { min-height: 34px; }
  .st-btn.small { min-height: 32px; }
  .st-pager { height: 32px; }
  .st-pager button { width: 40px; height: 32px; }
  .st-step button { width: 34px; height: 32px; }
  .st-back { width: 34px; }
  .st-pk-els button, .st-pk-sort button { height: 32px; }
  .st-pk-find input, .st-pk-find select, .st-pk-one { height: 32px; }
  .st-pk-find select { width: 92px; }
  .st-pk-one { padding: 0 7px; font-size: 12.5px; }
  .pop-x { width: 36px; height: 36px; }
}
/* The Shrines pop-up keeps one height through empty, rolling, landed and placed, so its header never jumps. */
.sh-ctx { min-height: 232px; }
@media (max-width: 620px) { .sh-ctx { min-height: 214px; } }
/* An empty nest: a bought egg or a bred one. */
.st-nestpop { width: 460px; }
.st-nps { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.st-np { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 10px 12px; border: 1px solid #5c4830; border-radius: 6px; background: rgba(0, 0, 0, .22); color: var(--ink); font: 600 14px/1.2 'Crimson Pro', Georgia, serif; cursor: pointer; text-align: center; }
.st-np:hover, .st-np:focus-visible { border-color: #f0c45a; outline: none; background: rgba(240, 196, 90, .1); }
.st-np-pic { height: 84px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.st-np-pic .egg-ic { width: 40px; height: 52px; }
.st-np b { font: 700 19px/1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; }
.st-np small { color: var(--muted); font-size: 13px; text-wrap: balance; }
.st-np.off { opacity: .6; }
@media (max-width: 620px) { .st-nestpop { width: 100%; } .st-np-pic { height: 64px; } .st-np b { font-size: 17px; } }

/* The boss pieces held, on a recipe: one small icon and count per kind. */
.st-pc-lbl { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.st-pc-pile { display: inline-flex; align-items: center; gap: 2px; }
.st-pc-pile img { image-rendering: pixelated; }
.st-pc-pile small { color: var(--muted); font-variant-numeric: tabular-nums; }
/* A phone's picker tile is small: where it shows its worth here (bottom right), the level (which does not count for
   work) gives way so the two never touch. The side card still says it. */
@media (max-width: 620px) { .st-pk-grid .st-pc:has(.st-mult) .st-pl { display: none; } }
/* Swapping a shrine in while all five are up: the pedestals wait for the pick. */
.sh-ped.swap { border-color: #f0c45a; border-style: dashed; animation: sh-swap 1.2s ease-in-out infinite; }
@keyframes sh-swap { 50% { background-color: rgba(240, 196, 90, .14); } }
@media (prefers-reduced-motion: reduce) { .sh-ped.swap { animation: none; } }
.sh-swapping .sh-ctx-h { align-items: center; }
.sh-swapping .sh-ctx-h .st-thumb { flex: none; }
.sh-sparebtn.on { border-color: #f0c45a; }

/* The Break down tab's tools (client/stead.ts breakHtml): the kind, then the "Up to" ceiling chips, lit from the
   bottom up to the one chosen. One row; on a narrow card the label goes and the chips stay. */
.st-brk-tools { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.st-brk-tools select { flex: 1 1 0; min-width: 0; box-sizing: border-box; height: 32px; padding: 0 22px 0 10px; border: 1px solid #6a5434; border-radius: 16px; color: #e8d8b4; font: 600 14px/1 'Crimson Pro', Georgia, serif; -webkit-appearance: none; appearance: none; cursor: pointer;
  background: rgba(0, 0, 0, .3) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7'%3E%3Cpath d='M0 0h10L5 7z' fill='%23e0bd6a'/%3E%3C/svg%3E") no-repeat right 9px center; text-overflow: ellipsis; }
.st-brk-tools select:hover, .st-brk-tools select:focus-visible { border-color: #c9b282; outline: none; }
.st-brk-tools select option { color: #2a1a08; -webkit-text-fill-color: #2a1a08; background: #f3e6c4; }
.st-cap { flex: none; display: inline-flex; align-items: center; gap: 2px; height: 32px; padding: 0 3px 0 9px; box-sizing: border-box; border: 1px solid #6a5434; border-radius: 16px; background: rgba(0, 0, 0, .3); }
.st-cap-l { margin-right: 3px; color: var(--muted); font: 600 12.5px/1 'Crimson Pro', Georgia, serif; white-space: nowrap; }
.st-cap button { position: relative; display: grid; place-items: center; width: 32px; height: 26px; padding: 0; border: 0; border-radius: 13px; background: transparent; cursor: pointer; opacity: .42; transition: opacity .12s, background .12s; }
.st-cap.pct button { width: 38px; }
.st-cap button b { color: #e8d8b4; font: 800 12.5px/1 var(--sans); }
.st-cap button:hover, .st-cap button:focus-visible { opacity: .85; outline: none; }
.st-cap button.in { opacity: 1; background: rgba(240, 200, 120, .13); }
.st-cap button.top { background: rgba(240, 200, 120, .26); box-shadow: inset 0 0 0 1.5px #f0d08a, 0 0 8px rgba(240, 200, 120, .35); }
.st-cap button.top b { color: #fff3c4; }
.st-brk-hint { color: var(--muted); font: italic 500 13.5px/1.25 'Crimson Pro', Georgia, serif; }
@media (max-width: 420px) { .st-cap-l { display: none; } .st-cap { padding-left: 3px; } .st-cap button { width: 28px; } .st-cap .gr { width: 18px; height: 18px; } .st-cap.pct button { width: 33px; } .st-cap.pct button b { font-size: 11.5px; } }
.st-item { position: relative; }
.st-item .gr { position: absolute; top: 2px; left: 2px; }

/* What a producer's material is for (client/stead.ts), one quiet line under its store. */
.st-use { margin: 4px 0 0; font-size: 12.5px; line-height: 1.3; color: #cbb98f; }
.st-cost.st-free { color: #3f7a32; font-weight: 700; }

/* The picker's warning: a worker on the Arena team sits out of PvP (client/stead.ts). */
.st-pk-warn { margin: 6px 0 0; font-size: 12px; line-height: 1.3; color: #f0b070; }

/* A shrine's posts (client/shrines.ts): one card per post, who stands there and what it learns; Choose opens the picker
   over every creature you own (client/shrinepick.ts, Cole 11-26). */
.sh-pcs { flex: 1; display: grid; grid-template-columns: 1fr; gap: 8px; align-content: center; }
.sh-pcs.two { grid-template-columns: 1fr 1fr; }
.sh-pc { position: relative; display: flex; align-items: center; gap: 14px; min-width: 0; padding: 12px 16px; border: 1px solid #5c4830; border-radius: 6px; background: rgba(0, 0, 0, .25); }
.sh-pc.empty { border-style: dashed; }
.sh-pc-lbl { position: absolute; top: -9px; left: 12px; padding: 0 6px; background: #241a12; color: var(--muted); font: 600 12px/18px 'Crimson Pro', Georgia, serif; }
.sh-pc-art { position: relative; flex: none; width: 84px; height: 84px; display: grid; place-items: center; border-radius: 6px; background: radial-gradient(ellipse 70% 30% at 50% 82%, rgba(128, 168, 86, .38), transparent 70%); }
.sh-pc-art img { width: 76px; height: 76px; object-fit: contain; image-rendering: pixelated; }
.sh-pc-art .gr { position: absolute; top: 2px; left: 2px; transform: scale(.82); transform-origin: top left; }
.sh-pc-add { flex: none; width: 84px; height: 84px; display: grid; place-items: center; border: 1px dashed #6a563a; border-radius: 6px; background: rgba(0, 0, 0, .25); color: #f0c45a; font: 700 30px/1 Georgia, serif; cursor: pointer; }
.sh-pc-add:hover, .sh-pc-add:focus-visible { border-color: #f0c45a; outline: none; }
.sh-pc-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.sh-pc-txt b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 700 20px/1.1 'Cormorant Garamond', Georgia, serif; color: #f3e3b4; }
.sh-pc-txt small { color: var(--muted); font-size: 13.5px; }
.sh-pc-txt .sh-sub { font-size: 13.5px; white-space: normal; }
.sh-pc-acts { flex: none; display: flex; flex-direction: column; gap: 6px; }
.sh-pc-acts .st-btn, .sh-pc > .st-btn { justify-content: center; min-width: 92px; }
.sh-pcs.two .sh-pc { gap: 10px; padding: 12px 10px; }
.sh-pcs.two .sh-pc-art, .sh-pcs.two .sh-pc-add { width: 64px; height: 64px; }
.sh-pcs.two .sh-pc-art img { width: 58px; height: 58px; }
.st-pc.off { opacity: .45; }
@media (max-width: 620px) {
  .sh-pcs.two { grid-template-columns: 1fr; gap: 12px; }
  .sh-pc, .sh-pcs.two .sh-pc { gap: 10px; padding: 8px 10px; }
  .sh-pc-art, .sh-pc-add, .sh-pcs.two .sh-pc-art, .sh-pcs.two .sh-pc-add { width: 52px; height: 52px; }
  .sh-pc-art img, .sh-pcs.two .sh-pc-art img { width: 48px; height: 48px; }
  .sh-pc-add { font-size: 24px; }
  .sh-pc-txt { gap: 2px; }
  .sh-pc-txt b { font-size: 17px; }
  .sh-pc-txt small, .sh-pc-txt .sh-sub { font-size: 12.5px; line-height: 1.2; }
  .sh-pc-acts { gap: 4px; }
  .sh-pc-acts .st-btn, .sh-pc > .st-btn { min-width: 80px; min-height: 32px; padding: 0 8px; font-size: 13px; }
}
/* The shrine picker has one more toggle (Team) than the Kinstead's: on the narrowest phones the search takes its own line. */
@media (max-width: 380px) {
  .sh-pickpop .st-pk-find { flex-wrap: wrap; }
  .sh-pickpop .st-pk-find input { flex: 1 1 100%; }
  .sh-pickpop .st-pk-find select { flex: 1 1 auto; width: auto; }
}
