@property --solar {
  syntax: "<number>";
  inherits: true;
  initial-value: 0.5;
}

:root {
  /* A range slider's height (.range-bar), which a .room-track's wall reads too. */
  --range-h: 24px;
  --bg: #dedede;
  --panel: #ffffff;
  --ink: #03050b;
  --muted: #555555;
  --line: #c1c1c1;
  /* A row rule a quarter of --line; each scope that sets --line sets it again so it follows. */
  --line-faint: color-mix(in srgb, var(--line) 25%, transparent);
  --accent: #ffd24a;
  --on-accent: var(--ink);
  --danger: #d32f2f;
  /* Crest heights (src/ui/crest.js); a crest is as wide as its flag (.crest).
     The cache draws every crest at --crest-profile, so it stays the largest. */
  --crest-list: 38px;
  --crest-chip: 72px;
  --crest-profile: 96px;
  /* An account with no crest: loud, so it reads as something gone wrong. */
  --crest-missing: #ff4fd8;
  /* Paired with INK.costly in src/city/ground_inks.js: the amber of a move that costs morale. */
  --warn: #e39b2d;
  /* Text over a --warn fill. */
  --warn-ink: #1d1203;
  /* The red of something waiting on the player: a corner badge, and the dot on an
     unread news post, report, or alliance notice. */
  --unread-mark: #ff3340;
  /* A count on an --unread-mark badge. */
  --unread-ink: #fff;
  /* The ground a settler's portrait stands on, wherever it shows. */
  --portrait-ground: #575b4b;
  /* The title screen's ground: the grassland's green, under the scene while it
     loads and in its place when it cannot. */
  --title-ground: #768130;
  /* The corner of a portrait in a raid's floating card: the attack line's
     commanders and the raider roster's groups. */
  --card-pic-radius: 6px;
  --btn-positive: var(--accent);
  --btn-positive-ink: var(--on-accent);
  --btn-positive-fill: color-mix(in srgb, var(--accent) 55%, white);
  --btn-go: #2e9e5e;
  --btn-go-ink: #ffffff;
  --btn-go-fill: #7fd3a3;
  --btn-start: #2f8fc4;
  --btn-start-ink: #ffffff;
  --btn-caution-ink: #000000;
  --btn-caution-fill: #ffe2a8;
  --btn-start-fill: #8fcdee;
  --btn-negative: #c4453c;
  --btn-negative-ink: #ffffff;
  --btn-negative-fill: #e08a84;
  --btn-neutral: var(--line);
  --btn-neutral-ink: var(--ink);
  --btn-neutral-fill: #a8a8a8;
  --btn-discord: #5865f2;
  --btn-discord-ink: #ffffff;
  --btn-discord-fill: #a5acf8;
  --chrome: color-mix(in srgb, var(--bg) 94%, transparent);
  --chip-well: #cfcfcf;
  --chip-fill: color-mix(in srgb, var(--accent) 30%, var(--chip-well));
  --chip-fill-work: color-mix(in srgb, var(--accent) 52%, var(--chip-well));
  --dim: color-mix(in srgb, var(--ink) 28%, transparent);
  --shadow: 0 8px 24px color-mix(in srgb, var(--ink) 12%, transparent);
  --scroll: color-mix(in srgb, var(--ink) 22%, transparent);
  --scroll-hover: color-mix(in srgb, var(--ink) 38%, transparent);
  --font: system-ui, "Segoe UI", sans-serif;
  --float-width: 720px;
  --chat-list: 140px;
  --chat-thread: 500px;
  --panel-pad: 16px;
  --panel-enter-ms: 400;
  --panel-leave-ms: 200;
  --panel-enter-ease: cubic-bezier(0.87, 0, 0.13, 1); /* inOutExpo */
  --panel-leave-ease: cubic-bezier(0.55, 0.055, 0.675, 0.19);
  --badge-hang: 6px;
  /* How far something that can't be done yet fades: a disabled or blocked
     button or switch, a good the bag has none of, a blocked Build or Plant
     tile. */
  --dim-opacity: 0.5;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  overscroll-behavior: none;
  color-scheme: light;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  user-select: none;
  -webkit-user-select: none;
  /* iOS ignores user-scalable=no; this stops double-tap zoom. */
  touch-action: manipulation;
}

input[type="range"] {
  touch-action: none;
}

/* A range slider (.range-bar): a thick rounded bar that fills gold up to its
   knob, a light disc ringed in gold inside the bar. The fill is the knob's
   shadow reaching left, clipped to the bar, so a value code sets fills too.
   The shadow's right edge sits at the knob's centre. */
.range-bar {
  --range-fill: var(--accent);
  --range-track: color-mix(in srgb, var(--text) 14%, transparent);
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: var(--range-h);
  padding: 0;
  border: 0;
  border-radius: 99px;
  overflow: hidden;
  background: var(--range-track);
  cursor: pointer;
}

.range-bar:focus-visible {
  outline: 2px solid var(--range-fill);
  outline-offset: 2px;
}

.range-bar::-webkit-slider-runnable-track {
  height: 100%;
  border: 0;
  background: none;
}

.range-bar::-moz-range-track {
  height: 100%;
  border: 0;
  background: none;
}

.range-bar::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
  width: var(--range-h);
  height: var(--range-h);
  border: 4px solid var(--range-fill);
  border-radius: 50%;
  background: var(--text);
  box-shadow: calc(-100vw - var(--range-h) / 2) 0 0 100vw var(--range-fill);
}

.range-bar::-moz-range-thumb {
  box-sizing: border-box;
  width: var(--range-h);
  height: var(--range-h);
  border: 4px solid var(--range-fill);
  border-radius: 50%;
  background: var(--text);
  box-shadow: calc(-100vw - var(--range-h) / 2) 0 0 100vw var(--range-fill);
}

::selection {
  background: var(--accent);
  color: var(--on-accent);
}

#play-veil {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: var(--chat-inset);
  z-index: var(--z-veil);
  background: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms linear;
}

#play-veil.is-on {
  opacity: 1;
  pointer-events: auto;
}

/* The scene's edge pulses red as our city comes under attack, each pulse weaker, gone after
   four seconds. It sits over the scene and under the HUD, and never takes a tap. */
.attack-glow {
  position: absolute;
  inset: 0;
  z-index: var(--z-mid);
  pointer-events: none;
  box-shadow: inset 0 0 12vmin 2vmin rgb(230 30 30);
  opacity: 0;
}

.attack-glow.is-on {
  animation: attack-glow 4s ease-out forwards;
}

@keyframes attack-glow {
  0% { opacity: 0; }
  6% { opacity: 1; }
  18% { opacity: 0.45; }
  30% { opacity: 0.8; }
  45% { opacity: 0.3; }
  58% { opacity: 0.55; }
  74% { opacity: 0.15; }
  86% { opacity: 0.28; }
  100% { opacity: 0; }
}

.city-travel-overlay {
  position: absolute;
  inset: 0;
  z-index: var(--z-mid);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  background: #000;
  color: #fff;
  pointer-events: auto;
}

.city-travel-overlay-title {
  font-size: 1.2rem;
  font-weight: 600;
}

.city-travel-overlay-countdown {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.screen-play:not(.city-moving) .city-travel-overlay,
.screen-play.map-open .city-travel-overlay {
  display: none;
}

.screen-play.city-moving .city-play-btns,
.screen-play.city-moving .building-sheet,
.screen-play.city-moving .city-sheet,
.screen-play.city-moving .city-held,
.screen-play.city-moving .city-find-modal,
.screen-play.city-moving .city-family-sheet,
.screen-play.city-moving .city-editor,
.screen-play.city-visiting .city-play-btns,
.screen-play.city-visiting .top-bar,
.screen-play.city-visiting .city-family-sheet,
.screen-play.city-visiting .city-family-bubbles,
.screen-play.city-visiting .city-sheet-collect,
.screen-play.city-visiting .city-sheet-harvest,
.screen-play.city-visiting .city-sheet-manage,
.screen-play.city-visiting .city-sheet-discard,
.screen-play.city-visiting .city-sheet-cancel,
.screen-play.city-visiting .menu-bar-row.dest > button:not(#visit-back, #visit-move-btn, #visit-attack-btn, #armies-btn),
.screen-play.city-visiting:not(.visit-armies) #armies-btn {
  display: none;
}

.city-canvas,
.world-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: var(--z-canvas);
  touch-action: none;
  user-select: none;
  pointer-events: auto;
}

/* A mouse over something a tap would open or order (city/input.js). */
.city-canvas.is-aim {
  cursor: pointer;
}

.city-names {
  position: absolute;
  inset: 0;
  z-index: var(--z-names);
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition-property: opacity;
  transition-timing-function: linear;
}

.city-ask {
  position: absolute;
  inset: 0;
  z-index: var(--z-names);
  overflow: hidden;
  pointer-events: none;
}

.city-names.is-on {
  opacity: 1;
}

.city-ask-board,
.city-names-board {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

.map-pins {
  position: absolute;
  inset: 0;
  z-index: var(--z-names);
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition-property: opacity;
  transition-timing-function: linear;
}

.map-pins.is-on {
  opacity: 1;
}

.map-pin {
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--chip-well);
  color: var(--gold-200);
  transform-origin: 0 0;
  visibility: hidden;
  opacity: 0;
  transition-property: opacity;
  transition-timing-function: linear;
}

/* A raider's strength, on a pill across the foot of its pin (pin_icons.js). */
.map-pin-strength {
  position: absolute;
  left: 50%;
  bottom: -7px;
  transform: translateX(-50%);
  box-sizing: border-box;
  min-width: 18px;
  height: 15px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--surface-0);
  color: var(--text);
  font: 700 11px/15px var(--font);
  text-align: center;
  white-space: nowrap;
}

.map-pin.is-on {
  opacity: 1;
}

.screen-play .map-pin .i {
  width: 62%;
  height: 62%;
  filter: none;
}

.map-pin-hub,
.map-pin-spoke {
  color: var(--gold-ink);
}

.map-pin-hub {
  background: #eb8c1f;
}

.map-pin-spoke {
  background: #ffd133;
}

/* --troop-own, --troop-ally and --troop-enemy are battle/troop_colours.js's, set by pin_icons.js. */
.map-pin-own {
  background: var(--troop-own);
  color: var(--text);
}

.map-pin-ally {
  background: var(--troop-ally);
  color: var(--text);
}

.map-pin-enemy {
  background: var(--troop-enemy);
  color: var(--text);
}

/* A raider army, amber against a raider city's enemy red (pin_icons.js pinTone). */
.map-pin-raider-army {
  background: var(--warn);
  color: var(--warn-ink);
}

@font-face {
  font-family: "Power Chord";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./powerchord.fb3b9b9418ed.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./source-sans-3-400.03271590a466.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("./source-sans-3-500.731b2f524fd7.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("./source-sans-3-600.7f8a222a36af.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("./barlow-condensed-600.4644bc787687.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("./barlow-condensed-700.2cbc6cbed0a8.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./barlow-semi-condensed-400.fdb8bfadfbe8.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("./barlow-semi-condensed-500.133868cbef58.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Semi Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("./barlow-semi-condensed-600.f795a82ac0eb.woff2") format("woff2");
}

@font-face {
  font-family: "Press Start 2P";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./press-start-2p.06d63aa9c218.woff2") format("woff2");
}

/* Block, not swap: the intertitle types one letter at a time, and a fallback
   face swapping out mid-line reads as a glitch. */
@font-face {
  font-family: "Handwriting";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("./handwriting.d7d92d75934d.woff2") format("woff2");
}

.title-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.5s ease;
}

.title-canvas.is-ready { opacity: 1; }
html.title-live body { background: var(--title-ground); }
html.title-live .title-wordmark { color: #fff; text-shadow: 0 0 14px #000, 0 0 2px #000; }

.title-canvas[hidden],
.designer-canvas[hidden] {
  display: none !important;
}

.designer-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
  pointer-events: none;
}

#ui {
  position: relative;
  z-index: 1;
  height: 100%;
  pointer-events: none;
}

.screen {
  pointer-events: auto;
}

.screen[hidden],
[hidden] {
  display: none !important;
}

.screen-title {
  position: relative;
  /* Visible height, so the bottom menu box rides above the phone keyboard. */
  height: var(--vv-height, 100dvh);
  pointer-events: auto;
  --z-panels: 2;
}

.title-wordmark {
  position: absolute;
  top: max(20px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  width: min(var(--float-width), 100%);
  z-index: 1;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  container-type: inline-size;
  font-family: "Power Chord", sans-serif;
  font-weight: 400;
  line-height: 0.95;
  text-align: center;
  color: var(--ink);
  text-shadow: 0 0 14px var(--bg), 0 0 2px var(--bg);
  pointer-events: none;
  --wordmark-line-em: 5.99; /* Power Chord width plus letter spacing. */
  --wordmark-leave: 1s;
}

/* A campaign setting off: the wordmark slides up and fades as the menu
   slides down. */
.title-wordmark.is-leaving {
  transform: translate(-50%, -100%);
  opacity: 0;
  transition:
    transform var(--wordmark-leave) var(--panel-leave-ease),
    opacity var(--wordmark-leave) ease;
}

.aspect-portrait .title-wordmark {
  width: calc(100% - 48px);
}

.title-wordmark > span {
  font-size: calc(100cqi / var(--wordmark-line-em));
  letter-spacing: 0.18em;
}

.title-loading {
  position: absolute;
  left: 50%;
  bottom: max(32px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: min(360px, calc(100% - 48px));
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 1;
}

.title-actions,
.title-create,
.title-login,
.title-lost,
.title-confirm {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.title-actions {
  max-height: 50vh;
  overflow-y: auto;
}

.title-actions button,
.title-lost button,
.title-form-actions button {
  width: 100%;
}

.title-action-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

/* Log in, Register, and Discord stacked on the left; Play fills the right at
   the stack's height. */
.title-primary-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.title-auth-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Play as Guest in title type, its note under it in italic button type. */
.title-play {
  flex-direction: column;
}

.title-play .btn-label {
  font-size: var(--card-title-size);
}

.title-play-note {
  position: relative;
  z-index: 1;
  font-style: italic;
}

.title-terms {
  margin: 0;
  font-size: var(--caption-text-size);
  text-align: center;
}

.title-resume,
.title-account-row {
  min-height: calc((1.2em + 16px) * 2);
}

.title-account-row .btn-label {
  overflow: hidden;
  text-overflow: ellipsis;
}

.title-account-row {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 1fr);
  gap: 8px;
  align-items: stretch;
}

.title-last-played {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4px 6px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: var(--caption-text-size);
  line-height: 1.2;
  text-align: center;
}

.title-create .status:empty,
.title-login .status:empty {
  display: none;
}

.login-terms {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.title-form-actions {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 8px;
}

.title-progress {
  position: relative;
  height: 8px;
  background: color-mix(in srgb, var(--ink) 12%, transparent);
  overflow: hidden;
}

.title-progress-fill {
  height: 100%;
  width: 0;
  background: var(--accent);
  animation: title-progress-pulse 1.2s ease-in-out infinite;
}

.title-progress::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 42%;
  background: linear-gradient(
    90deg,
    transparent,
    color-mix(in srgb, #ffffff 55%, transparent),
    transparent
  );
  animation: title-progress-sheen 1.2s linear infinite;
  pointer-events: none;
}

@keyframes title-progress-sheen {
  from {
    transform: translateX(-120%);
  }
  to {
    transform: translateX(280%);
  }
}

@keyframes title-progress-pulse {
  50% {
    filter: brightness(1.2);
  }
}

#blackout {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms linear;
}

.blackout-load {
  position: absolute;
  left: 50%;
  bottom: max(32px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: min(360px, calc(100% - 48px));
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.blackout-status {
  margin: 0;
  color: #fff;
  text-align: center;
  font-size: 0.85rem;
}

#blackout.is-on {
  opacity: 1;
  pointer-events: auto;
}

.intertitle {
  position: fixed;
  inset: 0;
  z-index: 41;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  color: #fff;
  font-family: "Handwriting", cursive;
  font-size: 2rem;
  line-height: 1.5;
  text-align: center;
}

.intertitle-copy {
  margin: 0;
  max-width: var(--float-width, 28rem);
  white-space: pre-wrap;
}

.intertitle-live {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.panel h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
  font-weight: 600;
}

label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.9rem;
}

input,
textarea {
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 8px 10px;
  font: inherit;
  /* iOS zooms the page when the focused field is under 16px, and does not reset. */
  font-size: 16px;
  user-select: text;
  -webkit-user-select: text;
}

select {
  font: inherit;
  font-size: 16px;
}

/* The one table of rows (src/ui/list_table.js): muted column names over
   rows split by a line, each led by a bold row header. A table adds only
   rules for its own columns. */
.list-table {
  width: 100%;
  border-collapse: collapse;
}

.list-table th,
.list-table td {
  padding: 8px 6px;
  text-align: left;
  border-bottom: 1px solid var(--line-faint);
}

.list-table thead th {
  color: var(--muted);
  font-size: var(--meta-text-size);
  font-weight: 500;
}

.list-table tbody th {
  font-weight: 600;
}

.password-field {
  display: flex;
  align-items: stretch;
  background: var(--bg);
  border: 1px solid var(--line);
}

.password-field input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
}

.password-field .password-show {
  flex-shrink: 0;
  background: none;
  color: var(--muted);
  padding: 8px 10px;
}

button {
  font: inherit;
  cursor: pointer;
  background: var(--accent);
  color: var(--on-accent);
  border: 0;
  padding: 8px 12px;
  -webkit-tap-highlight-color: transparent;
}

button:disabled,
button[aria-disabled="true"] {
  opacity: var(--dim-opacity);
  cursor: default;
}

button:focus {
  outline: none;
}

button:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--ink) 28%, transparent);
  outline-offset: 2px;
}

button:active:not(:disabled):not([aria-disabled="true"]) {
  filter: brightness(1.16);
}

button.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
  user-select: none;
  text-align: center;
}

button.btn.positive {
  background: var(--btn-positive);
  color: var(--btn-positive-ink);
  border: 0;
}

button.btn.go {
  background: var(--btn-go);
  color: var(--btn-go-ink);
  border: 0;
}

button.btn.start {
  background: var(--btn-start);
  color: var(--btn-start-ink);
  border: 0;
}

button.btn.negative {
  background: var(--btn-negative);
  color: var(--btn-negative-ink);
  border: 0;
}

button.btn.neutral {
  background: var(--btn-neutral);
  color: var(--btn-neutral-ink);
  border: 0;
}

button.btn.discord {
  gap: 8px;
  background: var(--btn-discord);
  color: var(--btn-discord-ink);
  border: 0;
}

button.btn.discord .i {
  flex: none;
  width: 20px;
  height: 20px;
}

button.btn.processing:disabled {
  opacity: 1;
}

.btn-fill {
  position: absolute;
  inset: 0;
  transform: scaleX(0);
  transform-origin: left center;
  pointer-events: none;
  z-index: 0;
}

button.btn.positive .btn-fill {
  background: var(--btn-positive-fill);
}

button.btn.go .btn-fill {
  background: var(--btn-go-fill);
}

button.btn.start .btn-fill {
  background: var(--btn-start-fill);
}

button.btn.negative .btn-fill {
  background: var(--btn-negative-fill);
}

button.btn.neutral .btn-fill {
  background: var(--btn-neutral-fill);
}

button.btn.caution .btn-fill {
  background: var(--btn-caution-fill);
}

button.btn.discord .btn-fill {
  background: var(--btn-discord-fill);
}

button.btn.armed .btn-fill {
  animation: btn-drain 3s linear forwards;
}

@keyframes btn-drain {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

.btn-label {
  position: relative;
  z-index: 1;
}

/* An icon-only button (an icon prepended, no words) keeps no gap for its label. */
.btn-label:empty {
  display: none;
}

button.link {
  background: none;
  color: var(--accent);
  padding: 0;
}

.tabs {
  margin: 0;
  color: var(--muted);
}

.status {
  margin: 0;
  color: var(--danger);
  min-height: 1.2em;
}

.muted {
  color: var(--muted);
  margin: 0;
}

.account-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.account-list button {
  text-align: left;
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
}

.screen-play {
  position: relative;
  min-height: 0;
  height: var(--vv-height, 100dvh);
  display: grid;
  /* Docked chat is column 1 at full height. HUD lives in the remaining column. */
  grid-template-columns: var(--chat-inset) minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr) auto;
  grid-template-areas:
    "dock top"
    "dock mid"
    "dock menu";
  pointer-events: none;
  --chat-inset: 0px;
  --z-canvas: 0;
  --z-names: 1;
  --z-mid: 2;
  --z-chrome: 3;
  --z-top: 4;
  --z-panels: 5;
  --z-notifications: 6;
  --z-veil: 8;
  --z-chat: 9;
  --z-toasts: 10;
  --z-editor: 11;
}

html.aspect-portrait .screen-play:has(> #radio-host:not([hidden])) > .play-top-row > .top-bar {
  display: none;
}

/* In portrait a bottom panel reaches the top of the screen: the day clock, the debug chip, and
   the settings and debug buttons would sit over its tabs and close button. */
html.aspect-portrait .screen-play:has(#panels:not([hidden])) .play-top-controls {
  visibility: hidden;
}

/* The landscape dock is the chat's thread pane, with the room list beside it where the
   window has room for both (html.chat-split, display_aspect.js). */
html.aspect-landscape .screen-play:not(:is(.find-open, .city-unloading)):has(> #radio-host:not([hidden])) {
  --chat-inset: var(--chat-thread);
}

html.chat-split .screen-play:not(:is(.find-open, .city-unloading)):has(> #radio-host:not([hidden])) {
  --chat-inset: calc(var(--chat-list) + var(--chat-thread));
}

.screen-play .chrome {
  pointer-events: auto;
}

.screen-play:has(.panels:not([hidden])) :is(.play-top-hud, .city-play-btns) {
  display: none;
}

/* The account and morale row stacks with the top row, above the top panel's box and dim. The
   panel opens where the row hangs, so the row steps aside. */
.screen-play:has(.top-panel:not([hidden])) .play-top-hud {
  display: none;
}

@property --top-band {
  syntax: "yes | no";
  inherits: false;
  initial-value: no;
}

.play-top-row {
  position: relative;
  grid-area: top;
  z-index: var(--z-notifications);
  min-width: 0;
  display: flex;
  align-items: stretch;
  gap: 12px;
  container: play-top / inline-size;
}

/* Wide rows join the clock to the resources. Portrait keeps it in the corner.
   The row and the chip row under it hold --play-width in the middle of the play column. */
html:not(.aspect-portrait) .play-top-row {
  --top-band: yes;
  width: var(--play-width);
  justify-self: center;
}


.top-bar {
  position: relative;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: var(--chrome);
  overscroll-behavior: none;
}

.chips {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  flex: 1;
  min-width: 0;
  user-select: none;
}

.chip {
  flex: 1;
  min-width: 72px;
  max-width: 128px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  pointer-events: none;
}

.chip-name {
  font-size: 14px;
  text-align: left;
  line-height: 1.2;
  overflow: hidden;
}

.chip-well {
  position: relative;
  height: 32px;
  background: var(--chip-well);
}

.chip-fill {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 0%;
  background: var(--chip-fill);
}

.chip-fill-work {
  background: var(--chip-fill-work);
}

.chip-fill-stalled {
  background: color-mix(in srgb, var(--danger) 55%, var(--chip-well));
}

.chip-fill-ready {
  background-color: var(--ok);
}

.chip-fill-damaged {
  background-color: var(--danger);
}

.chip-qty {
  position: relative;
  z-index: 1;
  height: 32px;
  display: flex;
  align-items: center;
  padding-left: 6px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
}

/* The account and morale row hangs under the top row. Where the clock and tools float in the
   corner, the cluster stops short of them; the wide band pulls them into the row and frees it. */
.play-top-hud {
  position: absolute;
  top: calc(100% + var(--play-top-gap));
  left: var(--play-top-inset);
  right: var(--play-top-inset);
  z-index: var(--z-chrome);
  display: flex;
  align-items: flex-start;
  gap: 8px;
  pointer-events: none;
}

.play-top-hud .play-left-cluster {
  margin-right: calc(var(--icon-control-size) + 8px + var(--corner-clock-reserve));
}

.play-top-hud .play-left-cluster,
.play-top-controls .play-right {
  pointer-events: none;
}

.play-top-controls {
  position: absolute;
  top: calc(100% + var(--play-top-gap));
  right: var(--play-control-inset);
  z-index: var(--z-chrome);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  pointer-events: none;
}

.play-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  pointer-events: none;
}

.day-clock {
  pointer-events: none;
}

.debug-stack {
  position: fixed;
  top: 50%;
  right: var(--play-top-inset, 12px);
  transform: translateY(-50%);
  z-index: var(--z-chrome);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  pointer-events: none;
}

.debug-chip {
  padding: 8px 12px;
  background: var(--chrome);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-size: 0.85rem;
  white-space: pre;
  text-align: right;
  pointer-events: auto;
}

.debug-transfers {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.debug-transfer-reset,
.debug-map-cache-drop,
.debug-clear-local,
.debug-dialogue-test,
.debug-cards-test,
.debug-lag,
.debug-noon-midnight,
.debug-tap-hulls,
.debug-nudge-btn {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  font: inherit;
  line-height: 1;
}

.debug-transfer-reset {
  width: 20px;
  height: 20px;
  padding: 0;
}

.debug-map-cache-drop,
.debug-clear-local,
.debug-dialogue-test,
.debug-cards-test,
.debug-lag,
.debug-noon-midnight,
.debug-tap-hulls,
.debug-nudge-btn {
  display: block;
  margin-left: auto;
  padding: 3px 6px;
  pointer-events: auto;
}

.debug-panel {
  width: 200px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--chrome);
  font-variant-numeric: tabular-nums;
  font-size: 0.85rem;
  pointer-events: auto;
}

.debug-panel[hidden] {
  display: none;
}

.debug-nudge {
  width: auto;
  max-width: min(92vw, 520px);
  max-height: 40vh;
  overflow: auto;
  white-space: pre;
  text-align: left;
  font-size: 0.75rem;
  line-height: 1.35;
}


.hud-tools {
  display: flex;
  flex-direction: column;
  gap: 4px;
  pointer-events: auto;
}

.debug-btn {
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  font-size: 18px;
  line-height: 1;
}

.play-left-cluster {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  pointer-events: none;
}

.play-left-cluster > * {
  pointer-events: auto;
}

.morale-chip {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
}

/* The account chip is a dark bar as wide as the name, the crest cut out over
   its left end and hanging below it into the world. Clicks on either land on
   the one button. With no crest the bar holds the name alone. */
.account-chip {
  position: relative;
  overflow: visible;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  height: var(--left-chip-size);
  padding: 0 14px 0 8px;
  background: var(--skin-panel);
  color: var(--text);
  border-radius: var(--control-radius);
  font-weight: 600;
  white-space: nowrap;
}

#account-chip-crest {
  align-self: flex-start;
  margin-top: -4px;
}

#account-chip-crest:empty {
  display: none;
}

/* Verify email: where the PIN goes. It carries the last badge of the trail
   to it, and is red until the login's email is verified. */
.account-verify-card {
  position: relative;
  overflow: visible;
}

.account-verify-card.unverified {
  border-color: var(--danger);
  background: color-mix(in srgb, var(--danger) 16%, var(--bg));
}

.account-verify-card.unverified .settings-card-head {
  border-bottom-color: var(--danger);
  color: var(--danger);
}

.morale-chip {
  width: var(--left-chip-size);
  height: var(--left-chip-size);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  line-height: 1;
}

.morale-chip.active {
  border-color: var(--accent);
}

.morale-chip[hidden] {
  display: none;
}

.menu-bar {
  position: relative;
  grid-area: menu;
  z-index: var(--z-notifications);
  min-width: 0;
  display: flex;
  justify-content: center;
  padding: var(--menu-inset) 0;
  background: var(--chrome);
}

html.keyboard-open .menu-bar {
  display: none;
}

html.keyboard-open .screen-play {
  padding-bottom: 12px;
}

.menu-bar-row {
  display: flex;
  width: var(--play-width);
  gap: 6px;
}

.menu-bar button {
  position: relative;
  overflow: visible;
  flex: 1;
  min-width: 64px;
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
}

.badge {
  position: absolute;
  top: calc(-1 * var(--badge-hang));
  right: calc(-1 * var(--badge-hang));
  z-index: 1;
  box-sizing: border-box;
  width: 14px;
  height: 14px;
  padding: 0;
  border-radius: 999px;
  background: var(--unread-mark);
  pointer-events: none;
}

/* A badge that counts what waits. */
.badge-count {
  width: auto;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  color: var(--unread-ink);
  font-size: var(--caption-text-size);
  line-height: 18px;
  text-align: center;
}

.play-middle {
  position: relative;
  grid-area: mid;
  min-width: 0;
  min-height: 0;
}

.radio-host {
  position: absolute;
  inset: 0;
  grid-area: dock;
  z-index: var(--z-chat);
  display: flex;
  pointer-events: none;
}

/* The Radio dock (radio_dock.js): its Chat / Calls strip on top, then the pane it shows. */
.radio-dock {
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
  border-right: 1px solid var(--line);
  box-shadow: none;
  background: var(--skin-panel);
}

/* The bottom sheets' tabs (.panel-tabs), standing at the dock's top edge
   rather than floating above it, and the crest catalogue's the same way. */
.radio-tabline,
.crest-tabline {
  --panel-tabline-height: 48px;
  flex: none;
  display: flex;
  border-bottom: 1px solid var(--line);
  background: var(--skin-accent);
}

.radio-tabline {
  padding-right: 14px;
}

.chat-host {
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 0;
}

/* The Calls pane (panels/calls.js): a box per contact or shelter, raised like a build tile.
   Its portrait greys out when no calls remain, and radio waves run behind it when a call can
   be fulfilled. The badge shows when one waits on the player. Its asks and
   gives are the building sheets' term groups. */
.calls-pane {
  padding-block: 12px;
  padding-left: 12px;
}

.call-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.call-box {
  position: relative;
  isolation: isolate;
  padding: 10px;
  background: var(--skin-raised);
}

/* Wave spacing widens toward the right; faster layers sit lower in the card. */
.call-radio-wave { display: none; }

.call-box.is-ready::before,
.call-box.is-ready::after,
.call-box.is-ready.has-open-call > .call-radio-wave {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--ok);
  mask-composite: intersect;
  mask-size: 100% 100%, 100% 180px;
  mask-repeat: no-repeat;
}

.call-box.is-ready::before {
  opacity: .26;
  mask-position: 0 0, center 0%;
  mask-image: linear-gradient(to right, #000, transparent 90%), url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22600%22%20height%3D%22200%22%20viewBox%3D%220%200%20600%20200%22%20preserveAspectRatio%3D%22none%22%3E%3Cdefs%3E%3Cfilter%20id%3D%22g%22%20x%3D%22-20%25%22%20y%3D%22-50%25%22%20width%3D%22140%25%22%20height%3D%22200%25%22%3E%3CfeGaussianBlur%20stdDeviation%3D%225%22%20%2F%3E%3C%2Ffilter%3E%3ClinearGradient%20id%3D%22f%22%20x1%3D%220%22%20y1%3D%220%22%20x2%3D%220%22%20y2%3D%221%22%3E%3Cstop%20stop-color%3D%22white%22%20stop-opacity%3D%220.5%22%20%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22white%22%20stop-opacity%3D%220%22%20%2F%3E%3C%2FlinearGradient%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20fill%3D%22url%28%23f%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%2212s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%20L600%2C200%20L0%2C200%20Z%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%20L600%2C200%20L0%2C200%20Z%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%2212%22%20opacity%3D%22.8%22%20filter%3D%22url%28%23g%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%2212s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%221.5%22%20opacity%3D%22.8%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%2212s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3C%2Fsvg%3E");
}

.call-box.is-ready.has-open-call > .call-radio-wave {
  display: block;
  opacity: .22;
  mask-position: 0 0, center 50%;
  mask-image: linear-gradient(to right, #000, transparent 90%), url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22600%22%20height%3D%22200%22%20viewBox%3D%220%200%20600%20200%22%20preserveAspectRatio%3D%22none%22%3E%3Cdefs%3E%3Cfilter%20id%3D%22g%22%20x%3D%22-20%25%22%20y%3D%22-50%25%22%20width%3D%22140%25%22%20height%3D%22200%25%22%3E%3CfeGaussianBlur%20stdDeviation%3D%225%22%20%2F%3E%3C%2Ffilter%3E%3ClinearGradient%20id%3D%22f%22%20x1%3D%220%22%20y1%3D%220%22%20x2%3D%220%22%20y2%3D%221%22%3E%3Cstop%20stop-color%3D%22white%22%20stop-opacity%3D%220.5%22%20%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22white%22%20stop-opacity%3D%220%22%20%2F%3E%3C%2FlinearGradient%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20fill%3D%22url%28%23f%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%228s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%20L600%2C200%20L0%2C200%20Z%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%20L600%2C200%20L0%2C200%20Z%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%2212%22%20opacity%3D%22.8%22%20filter%3D%22url%28%23g%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%228s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%221.5%22%20opacity%3D%22.8%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%228s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3C%2Fsvg%3E");
}

.call-box.is-ready::after {
  opacity: .20;
  mask-position: 0 0, center 100%;
  mask-image: linear-gradient(to right, #000, transparent 90%), url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22600%22%20height%3D%22200%22%20viewBox%3D%220%200%20600%20200%22%20preserveAspectRatio%3D%22none%22%3E%3Cdefs%3E%3Cfilter%20id%3D%22g%22%20x%3D%22-20%25%22%20y%3D%22-50%25%22%20width%3D%22140%25%22%20height%3D%22200%25%22%3E%3CfeGaussianBlur%20stdDeviation%3D%225%22%20%2F%3E%3C%2Ffilter%3E%3ClinearGradient%20id%3D%22f%22%20x1%3D%220%22%20y1%3D%220%22%20x2%3D%220%22%20y2%3D%221%22%3E%3Cstop%20stop-color%3D%22white%22%20stop-opacity%3D%220.8%22%20%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22white%22%20stop-opacity%3D%220%22%20%2F%3E%3C%2FlinearGradient%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20fill%3D%22url%28%23f%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%225s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%20L600%2C200%20L0%2C200%20Z%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%20L600%2C200%20L0%2C200%20Z%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%20L600%2C200%20L0%2C200%20Z%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%20L600%2C200%20L0%2C200%20Z%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%2212%22%20opacity%3D%22.8%22%20filter%3D%22url%28%23g%29%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%225s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20fill%3D%22none%22%20stroke%3D%22white%22%20stroke-width%3D%221.5%22%20opacity%3D%22.8%22%3E%3Canimate%20attributeName%3D%22d%22%20dur%3D%225s%22%20repeatCount%3D%22indefinite%22%20values%3D%22M0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%3BM0%2C80.2%20L10%2C85.8%20L20%2C92.1%20L30%2C98.6%20L40%2C104.8%20L50%2C110.7%20L60%2C115.8%20L70%2C120.2%20L80%2C123.6%20L90%2C126.1%20L100%2C127.5%20L110%2C128%20L120%2C127.6%20L130%2C126.3%20L140%2C124.3%20L150%2C121.7%20L160%2C118.5%20L170%2C114.9%20L180%2C110.9%20L190%2C106.8%20L200%2C102.6%20L210%2C98.4%20L220%2C94.3%20L230%2C90.4%20L240%2C86.8%20L250%2C83.4%20L260%2C80.5%20L270%2C77.9%20L280%2C75.8%20L290%2C74.1%20L300%2C73%20L310%2C72.2%20L320%2C72%20L330%2C72.2%20L340%2C72.9%20L350%2C73.9%20L360%2C75.4%20L370%2C77.2%20L380%2C79.3%20L390%2C81.7%20L400%2C84.3%20L410%2C87.1%20L420%2C90%20L430%2C93.1%20L440%2C96.2%20L450%2C99.3%20L460%2C102.4%20L470%2C105.5%20L480%2C108.4%20L490%2C111.3%20L500%2C113.9%20L510%2C116.4%20L520%2C118.7%20L530%2C120.8%20L540%2C122.6%20L550%2C124.2%20L560%2C125.5%20L570%2C126.6%20L580%2C127.3%20L590%2C127.8%20L600%2C128%3BM0%2C72%20L10%2C72.9%20L20%2C75.4%20L30%2C79.2%20L40%2C83.9%20L50%2C89.3%20L60%2C94.9%20L70%2C100.6%20L80%2C106.1%20L90%2C111.2%20L100%2C115.8%20L110%2C119.7%20L120%2C122.9%20L130%2C125.4%20L140%2C127%20L150%2C127.9%20L160%2C127.9%20L170%2C127.3%20L180%2C126%20L190%2C124%20L200%2C121.6%20L210%2C118.7%20L220%2C115.4%20L230%2C111.8%20L240%2C108.1%20L250%2C104.3%20L260%2C100.4%20L270%2C96.6%20L280%2C92.8%20L290%2C89.3%20L300%2C86%20L310%2C83%20L320%2C80.3%20L330%2C77.9%20L340%2C75.9%20L350%2C74.3%20L360%2C73.2%20L370%2C72.4%20L380%2C72%20L390%2C72.1%20L400%2C72.5%20L410%2C73.3%20L420%2C74.4%20L430%2C75.9%20L440%2C77.7%20L450%2C79.7%20L460%2C82%20L470%2C84.4%20L480%2C87.1%20L490%2C89.8%20L500%2C92.7%20L510%2C95.6%20L520%2C98.5%20L530%2C101.5%20L540%2C104.4%20L550%2C107.2%20L560%2C109.9%20L570%2C112.5%20L580%2C115%20L590%2C117.3%20L600%2C119.4%3BM0%2C80.2%20L10%2C75.8%20L20%2C73.1%20L30%2C72%20L40%2C72.4%20L50%2C74.1%20L60%2C76.9%20L70%2C80.6%20L80%2C85%20L90%2C89.7%20L100%2C94.8%20L110%2C99.9%20L120%2C104.8%20L130%2C109.6%20L140%2C113.9%20L150%2C117.8%20L160%2C121%20L170%2C123.7%20L180%2C125.8%20L190%2C127.2%20L200%2C127.9%20L210%2C128%20L220%2C127.4%20L230%2C126.3%20L240%2C124.7%20L250%2C122.6%20L260%2C120.1%20L270%2C117.2%20L280%2C114.1%20L290%2C110.7%20L300%2C107.2%20L310%2C103.7%20L320%2C100.1%20L330%2C96.5%20L340%2C93.1%20L350%2C89.8%20L360%2C86.7%20L370%2C83.8%20L380%2C81.2%20L390%2C78.8%20L400%2C76.8%20L410%2C75.2%20L420%2C73.8%20L430%2C72.9%20L440%2C72.3%20L450%2C72%20L460%2C72.1%20L470%2C72.5%20L480%2C73.3%20L490%2C74.4%20L500%2C75.7%20L510%2C77.3%20L520%2C79.2%20L530%2C81.3%20L540%2C83.5%20L550%2C85.9%20L560%2C88.5%20L570%2C91.1%20L580%2C93.8%20L590%2C96.6%20L600%2C99.4%3BM0%2C100%20L10%2C92.9%20L20%2C86.6%20L30%2C81.2%20L40%2C77.1%20L50%2C74.1%20L60%2C72.5%20L70%2C72%20L80%2C72.7%20L90%2C74.3%20L100%2C76.9%20L110%2C80.1%20L120%2C83.9%20L130%2C88.2%20L140%2C92.6%20L150%2C97.2%20L160%2C101.8%20L170%2C106.3%20L180%2C110.5%20L190%2C114.4%20L200%2C117.9%20L210%2C120.9%20L220%2C123.4%20L230%2C125.4%20L240%2C126.8%20L250%2C127.7%20L260%2C128%20L270%2C127.8%20L280%2C127.1%20L290%2C125.9%20L300%2C124.2%20L310%2C122.2%20L320%2C119.9%20L330%2C117.2%20L340%2C114.3%20L350%2C111.2%20L360%2C108%20L370%2C104.7%20L380%2C101.3%20L390%2C98%20L400%2C94.7%20L410%2C91.6%20L420%2C88.6%20L430%2C85.7%20L440%2C83.1%20L450%2C80.7%20L460%2C78.6%20L470%2C76.7%20L480%2C75.2%20L490%2C73.9%20L500%2C73%20L510%2C72.3%20L520%2C72%20L530%2C72%20L540%2C72.3%20L550%2C72.9%20L560%2C73.8%20L570%2C74.9%20L580%2C76.3%20L590%2C77.9%20L600%2C79.8%3BM0%2C119.8%20L10%2C114.2%20L20%2C107.9%20L30%2C101.4%20L40%2C95.2%20L50%2C89.3%20L60%2C84.2%20L70%2C79.8%20L80%2C76.4%20L90%2C73.9%20L100%2C72.5%20L110%2C72%20L120%2C72.4%20L130%2C73.7%20L140%2C75.7%20L150%2C78.3%20L160%2C81.5%20L170%2C85.1%20L180%2C89.1%20L190%2C93.2%20L200%2C97.4%20L210%2C101.6%20L220%2C105.7%20L230%2C109.6%20L240%2C113.2%20L250%2C116.6%20L260%2C119.5%20L270%2C122.1%20L280%2C124.2%20L290%2C125.9%20L300%2C127%20L310%2C127.8%20L320%2C128%20L330%2C127.8%20L340%2C127.1%20L350%2C126.1%20L360%2C124.6%20L370%2C122.8%20L380%2C120.7%20L390%2C118.3%20L400%2C115.7%20L410%2C112.9%20L420%2C110%20L430%2C106.9%20L440%2C103.8%20L450%2C100.7%20L460%2C97.6%20L470%2C94.5%20L480%2C91.6%20L490%2C88.7%20L500%2C86.1%20L510%2C83.6%20L520%2C81.3%20L530%2C79.2%20L540%2C77.4%20L550%2C75.8%20L560%2C74.5%20L570%2C73.4%20L580%2C72.7%20L590%2C72.2%20L600%2C72%3BM0%2C128%20L10%2C127.1%20L20%2C124.6%20L30%2C120.8%20L40%2C116.1%20L50%2C110.7%20L60%2C105.1%20L70%2C99.4%20L80%2C93.9%20L90%2C88.8%20L100%2C84.2%20L110%2C80.3%20L120%2C77.1%20L130%2C74.6%20L140%2C73%20L150%2C72.1%20L160%2C72.1%20L170%2C72.7%20L180%2C74%20L190%2C76%20L200%2C78.4%20L210%2C81.3%20L220%2C84.6%20L230%2C88.2%20L240%2C91.9%20L250%2C95.7%20L260%2C99.6%20L270%2C103.4%20L280%2C107.2%20L290%2C110.7%20L300%2C114%20L310%2C117%20L320%2C119.7%20L330%2C122.1%20L340%2C124.1%20L350%2C125.7%20L360%2C126.8%20L370%2C127.6%20L380%2C128%20L390%2C127.9%20L400%2C127.5%20L410%2C126.7%20L420%2C125.6%20L430%2C124.1%20L440%2C122.3%20L450%2C120.3%20L460%2C118%20L470%2C115.6%20L480%2C112.9%20L490%2C110.2%20L500%2C107.3%20L510%2C104.4%20L520%2C101.5%20L530%2C98.5%20L540%2C95.6%20L550%2C92.8%20L560%2C90.1%20L570%2C87.5%20L580%2C85%20L590%2C82.7%20L600%2C80.6%3BM0%2C119.8%20L10%2C124.2%20L20%2C126.9%20L30%2C128%20L40%2C127.6%20L50%2C125.9%20L60%2C123.1%20L70%2C119.4%20L80%2C115%20L90%2C110.3%20L100%2C105.2%20L110%2C100.1%20L120%2C95.2%20L130%2C90.4%20L140%2C86.1%20L150%2C82.2%20L160%2C79%20L170%2C76.3%20L180%2C74.2%20L190%2C72.8%20L200%2C72.1%20L210%2C72%20L220%2C72.6%20L230%2C73.7%20L240%2C75.3%20L250%2C77.4%20L260%2C79.9%20L270%2C82.8%20L280%2C85.9%20L290%2C89.3%20L300%2C92.8%20L310%2C96.3%20L320%2C99.9%20L330%2C103.5%20L340%2C106.9%20L350%2C110.2%20L360%2C113.3%20L370%2C116.2%20L380%2C118.8%20L390%2C121.2%20L400%2C123.2%20L410%2C124.8%20L420%2C126.2%20L430%2C127.1%20L440%2C127.7%20L450%2C128%20L460%2C127.9%20L470%2C127.5%20L480%2C126.7%20L490%2C125.6%20L500%2C124.3%20L510%2C122.7%20L520%2C120.8%20L530%2C118.7%20L540%2C116.5%20L550%2C114.1%20L560%2C111.5%20L570%2C108.9%20L580%2C106.2%20L590%2C103.4%20L600%2C100.6%3BM0%2C100%20L10%2C107.1%20L20%2C113.4%20L30%2C118.8%20L40%2C122.9%20L50%2C125.9%20L60%2C127.5%20L70%2C128%20L80%2C127.3%20L90%2C125.7%20L100%2C123.1%20L110%2C119.9%20L120%2C116.1%20L130%2C111.8%20L140%2C107.4%20L150%2C102.8%20L160%2C98.2%20L170%2C93.7%20L180%2C89.5%20L190%2C85.6%20L200%2C82.1%20L210%2C79.1%20L220%2C76.6%20L230%2C74.6%20L240%2C73.2%20L250%2C72.3%20L260%2C72%20L270%2C72.2%20L280%2C72.9%20L290%2C74.1%20L300%2C75.8%20L310%2C77.8%20L320%2C80.1%20L330%2C82.8%20L340%2C85.7%20L350%2C88.8%20L360%2C92%20L370%2C95.3%20L380%2C98.7%20L390%2C102%20L400%2C105.3%20L410%2C108.4%20L420%2C111.4%20L430%2C114.3%20L440%2C116.9%20L450%2C119.3%20L460%2C121.4%20L470%2C123.3%20L480%2C124.8%20L490%2C126.1%20L500%2C127%20L510%2C127.7%20L520%2C128%20L530%2C128%20L540%2C127.7%20L550%2C127.1%20L560%2C126.2%20L570%2C125.1%20L580%2C123.7%20L590%2C122.1%20L600%2C120.2%22%20%2F%3E%3C%2Fpath%3E%3C%2Fsvg%3E");
}

/* Taller call cards spread the outer waves toward their edges. */
.call-box.is-ready.has-open-call::before {
  mask-position: 0 0, center -35px;
}

.call-box.is-ready.has-open-call::after {
  mask-position: 0 0, center calc(100% + 35px);
}

.call-box-title {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: var(--tile-title-size);
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.call-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 10px;
}

/* A contact's name, with the radio frequency it calls on at the right. */
.call-box-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.call-frequency {
  flex: none;
  color: var(--muted);
  opacity: 0.5;
  font-size: var(--meta-text-size);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* Keep a new call's Listen control at the right of its contact. */
.call-box-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
}

.call-box-controls > .row-card-copy {
  margin-left: auto;
}

.call-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

/* Provoke panel: the raider band's card stays put and the ladder scrolls under it. The
   ladder's first rung sits at the bottom and the climb reads upward; a rung is its raider
   level and a cell for each win it takes, dimmed while it lies ahead. */
.provoke-band {
  flex: none;
}

.provoke-note {
  color: var(--muted);
  font-size: var(--meta-text-size);
  overflow-wrap: anywhere;
}

.provoke-status {
  flex: none;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* The next raid's loot card takes the current rung's green. */
.provoke-next {
  background: var(--ok-bg);
}

.provoke-climb {
  display: flex;
  gap: 2px;
  height: 8px;
}

.provoke-climb-seg {
  flex: 1;
  background: var(--surface-1);
}

.provoke-climb-seg.is-won {
  background: var(--ok);
}

.provoke-ladder {
  position: relative;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 6px;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.provoke-rung {
  flex: none;
}

/* A short ladder sits on the band card, the empty room above it. */
.provoke-ladder > :first-child {
  margin-top: auto;
}

.provoke-rung {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

/* The rung the account stands on takes the next raid's green. */
.provoke-rung[data-state="current"] {
  background: var(--ok-bg);
}

.provoke-rung[data-state="ahead"] {
  opacity: .5;
}

.provoke-cells {
  display: flex;
  gap: 4px;
}

.provoke-cell {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--panel-line);
}

.provoke-cell[data-state="won"] {
  border-color: var(--ok);
  background: var(--ok-bg);
  color: var(--ok-text);
}

.provoke-cell[data-state="next"] {
  border-color: var(--ok);
}

.provoke-cell > .i {
  width: 22px;
  height: 22px;
}

.call-box-controls .call-new-listen {
  align-self: flex-end;
  margin-top: 6px;
}

.call-reject {
  margin-inline-end: auto;
}

.aspect-portrait .radio-host {
  display: block;
  grid-area: mid;
  z-index: var(--z-chat);
}

.aspect-portrait .radio-dock {
  position: absolute;
  inset: 0;
  width: auto;
  /* Radio hides the resource bar, so the dock keeps its tabs below the status bar. */
  padding-top: env(safe-area-inset-top);
  border-right: 0;
}

.chat-split .chat-list-pane {
  width: var(--chat-list);
  flex: 0 0 var(--chat-list);
}

.chat-split .chat-thread-pane {
  width: var(--chat-thread);
  flex: 0 0 var(--chat-thread);
}

.chat-list-pane,
.chat-thread-pane {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100%;
}

:where(html:not(.chat-split)) .chat-host.thread-open .chat-list-pane {
  display: none;
}

:where(html:not(.chat-split)) .chat-host:not(.thread-open) .chat-thread-pane {
  display: none;
}

:where(html:not(.chat-split)) :is(.chat-list-pane, .chat-thread-pane) {
  width: 100%;
  flex: 1 1 auto;
}

.chat-split .chat-rooms-back {
  display: none;
}

.chat-thread-header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}

.chat-thread-header h2 {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  font-size: 1rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* The Rooms back (bindBack) lets its unread badge hang past its edge. */
button.chat-rooms-back {
  overflow: visible;
  flex: 0 0 auto;
}

.chat-leave,
.chat-ticket {
  flex: 0 0 auto;
}

/* View ticket stands as tall as the Leave close beside it, as the Back does. */
.screen-play button.btn.chat-ticket {
  min-height: var(--icon-control-size);
}

.chat-rooms {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.chat-room {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  text-align: left;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}

.chat-room.selected {
  background: var(--row-selected);
}

/* A room's kind, in its own colour: an icon at the left of its row and a word beside its name.
   Where the room list fills the Radio the word sits right of the name; in the narrow landscape list
   it drops under it. */
.chat-room {
  --kind: var(--warn);
  --chat-room-face: 32px;
  border-bottom-color: var(--chat-room-line);
}

.chat-room-global {
  --kind: #b393ff;
}

.chat-room-alliance {
  --kind: #6fa3ff;
}

.chat-room-private {
  --kind: #3fc7b5;
}

/* The room's unread badge hangs on the icon's top right corner. */
.chat-room-face {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: var(--chat-room-face);
  height: var(--chat-room-face);
  border: 1px solid color-mix(in srgb, var(--kind) 45%, transparent);
  border-radius: 8px;
  background: color-mix(in srgb, var(--kind) 14%, transparent);
  color: var(--kind);
}

.chat-room-text {
  display: flex;
  flex: 1 1 auto;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.chat-room-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-room-label {
  flex: none;
  margin-left: auto;
  font-size: var(--meta-text-size);
  color: var(--kind);
}

.chat-split .chat-room-text {
  flex-direction: column;
  gap: 0;
}

.chat-split .chat-room-label {
  margin-left: 0;
}

.chat-thread {
  --chat-stack-gap: 8px;
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: var(--chat-stack-gap);
}

.chat-msg {
  --chat-avatar: var(--crest-list);
  --chat-msg-gap: 8px;
  display: flex;
  align-items: flex-start;
  gap: var(--chat-msg-gap);
  width: 100%;
  user-select: none;
  -webkit-user-select: none;
}

.chat-msg.continued {
  padding-left: calc(var(--chat-avatar) + var(--chat-msg-gap));
  margin-top: calc(-1 * var(--chat-stack-gap));
}

.chat-msg:has(+ .chat-msg.continued) .chat-bubble {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-bottom-width: 0;
}

.chat-msg.continued .chat-bubble {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  border-top-style: dashed;
}

.chat-avatar {
  flex: 0 0 var(--chat-avatar);
  padding: 0;
  border: 0;
  line-height: 0;
  border-radius: 0;
  color: var(--skin-panel);
  background: transparent;
}

/* A crest image is its flag's box (crest/art.js FLAG_LEFT to FLAG_RIGHT of
   the 1000-unit frame, full height), so nothing beside the flag takes room.
   art.test.js holds this ratio to art.js. */
.crest {
  display: block;
  flex: none;
  aspect-ratio: 680 / 1000;
}

.crest-list {
  height: var(--crest-list);
}

.crest-chip {
  height: var(--crest-chip);
}

.crest-profile {
  height: var(--crest-profile);
}

.crest-missing {
  background: var(--crest-missing);
}

.chat-bubble {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  padding: 6px 8px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 8px;
  user-select: none;
  -webkit-user-select: none;
  white-space: pre-wrap;
  word-break: break-word;
  padding-top: 2px;
}

.chat-bubble.mine {
  background: color-mix(in srgb, var(--accent) 18%, var(--panel));
}

.chat-bubble-top {
  display: flex;
  gap: 8px;
  margin-bottom: 2px;
  align-items: flex-start;
}

.chat-bubble-name,
.chat-bubble-body {
  flex: 1 1 auto;
  min-width: 0;
}

.chat-bubble-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink);
}

/* The System's and the Developer's names read in their own colour through --text, which the play
   screen's name rule reads. */
.chat-developer {
  --text: var(--developer);
}

.chat-system {
  --text: var(--system);
}

.chat-bubble-age {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: var(--meta-text-size);
  color: var(--muted);
  text-box-trim: trim-start;
  text-box-edge: cap alphabetic;
}

.chat-msg.continued .chat-bubble-top {
  margin-bottom: 0;
}

.chat-bubble.redacted {
  color: var(--muted);
  font-style: italic;
}

.chat-react-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.chat-react-chips:empty {
  display: none;
}

.chat-host button.chat-react-chip {
  display: inline-flex;
  align-items: center;
  min-height: 0;
  min-width: 0;
  padding: 0 5px;
  font-size: 0.85rem;
  line-height: 1.6;
  background: color-mix(in srgb, var(--ink) 7%, transparent);
  border: 0;
  border-radius: 999px;
  color: var(--ink);
  box-shadow: none;
}

.chat-host button.chat-react-chip.mine {
  background: color-mix(in srgb, var(--ink) 16%, transparent);
}

.chat-react-menu {
  position: absolute;
  top: 4px;
  right: 4px;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  max-width: calc(100% - 8px);
  padding: 2px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.chat-host .chat-react-menu button {
  min-height: var(--icon-control-size);
  min-width: var(--icon-control-size);
  padding: 0;
  font-size: 1.05rem;
  line-height: 1;
  background: transparent;
  color: inherit;
  border: 0;
  border-radius: 6px;
  box-shadow: none;
}

.chat-host .chat-react-menu button:hover {
  background: color-mix(in srgb, var(--ink) 8%, transparent);
}

.chat-host button.chat-react-chip:active,
.chat-host .chat-react-menu button:active {
  filter: none;
}

.chat-typing {
  margin: 0;
  padding: 4px 12px 0;
  font-size: var(--caption-text-size);
  color: var(--muted);
}

.chat-composer {
  flex: 0 0 auto;
  display: flex;
  gap: 6px;
  padding: 8px 12px;
  border-top: 1px solid var(--line);
}

.chat-composer input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 6px 8px;
}

.chat-composer button {
  flex: 0 0 auto;
  padding: 6px 12px;
}

.chat-composer.is-locked input,
.chat-composer.is-locked button {
  opacity: var(--dim-opacity);
}

.top-panel {
  --top-pad: 8px;
  position: absolute;
  inset: 0;
  z-index: var(--z-top);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: var(--top-pad);
  pointer-events: none;
  overflow: visible;
}

.top-panel-box {
  pointer-events: auto;
  position: relative;
  z-index: 1;
  width: var(--play-width);
  margin: 0 auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: visible;
  transform: translate3d(0, calc(-100% - var(--top-pad, 8px)), 0);
  transition: transform calc(var(--panel-enter-ms) * 1ms) var(--panel-enter-ease);
}

.top-panel.is-open .top-panel-box {
  transform: none;
}

.top-panel.is-leaving .top-panel-box {
  transform: translate3d(0, calc(-100% - var(--top-pad, 8px)), 0);
  transition-timing-function: var(--panel-leave-ease);
  transition-duration: calc(var(--panel-leave-ms) * 1ms);
}

.top-panel.is-entering .top-panel-box,
.top-panel.is-leaving .top-panel-box {
  pointer-events: none;
}

.aspect-portrait .top-panel {
  --top-pad: 0px;
}

.aspect-portrait .top-panel-box {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 16px;
}

.top-panel-header {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  overflow: visible;
}

.top-panel-title {
  flex: 1;
  min-width: 0;
  white-space: normal;
  overflow: visible;
}

.top-panel-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

.top-panel.is-collapsed .top-panel-body {
  display: none;
}

.top-panel-dismiss {
  position: relative;
  z-index: 2;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  padding: 0;
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 8px;
}

html:not(.aspect-portrait) .top-panel-dismiss {
  position: absolute;
  right: 28px;
  bottom: 24px;
  transform: translate(33px, 30px);
}

.build-long {
  margin: 0 0 10px;
}

/* A building's descriptions (build.js, build_tile.js) highlight emphasis in light text. */
.building-copy :is(em, strong) {
  font-style: normal;
  font-weight: 700;
  color: var(--text);
}

.city-play-btns {
  position: absolute;
  left: max(var(--menu-inset), calc((100% - var(--float-width)) / 2));
  bottom: 12px;
  z-index: var(--z-chrome);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#dialogue {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: var(--z-chrome);
  display: flex;
  justify-content: center;
  padding: 0 12px;
  pointer-events: none;
}

#dialogue[hidden] {
  display: none;
}

/* The floating menu bar's transparent padding would leave a gap under the bust. */
html:not(.aspect-portrait) .screen-play:not(:is(.city-arranging, .find-open, .city-unloading)) #dialogue {
  bottom: -8px;
}

.dialogue-strip {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  width: min(var(--float-width), 100%);
}

.dialogue-strip.is-right {
  flex-direction: row-reverse;
}

.dialogue-bust {
  --dialogue-bust-size: 112px;
  position: relative;
  width: var(--dialogue-bust-size);
  height: var(--dialogue-bust-size);
  flex: 0 0 var(--dialogue-bust-size);
  overflow: hidden;
  transform: translateY(100%);
}

.dialogue-bust.is-up {
  transform: none;
}

.dialogue-bubble {
  --dialogue-emphasis: var(--warn);
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  margin-bottom: 12px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 12px 16px;
  font-size: 16px;
  pointer-events: none;
  visibility: hidden;
}

/* Speech tail toward the bust. */
.dialogue-bubble::before {
  content: "";
  position: absolute;
  left: -7px;
  bottom: 20px;
  width: 12px;
  height: 12px;
  background: inherit;
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  transform: rotate(45deg);
}

.dialogue-strip.is-right .dialogue-bubble::before {
  left: auto;
  right: -7px;
  border-left: 0;
  border-bottom: 0;
  border-top: 1px solid var(--line);
  border-right: 1px solid var(--line);
}

.dialogue-bubble.is-shown {
  visibility: visible;
}

/* A line typed out and waiting for its tap glows from inside until tapped. */
.dialogue-bubble.is-nudging::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 18px 2px #fff6;
  pointer-events: none;
  animation: dialogue-nudge 2.4s ease-in-out infinite;
}

@keyframes dialogue-nudge {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

/* The tail's outer half, the triangle outside the bubble, glows with it,
   brightest at the tip. */
@property --nudge-glow {
  syntax: "<number>";
  inherits: false;
  initial-value: 0;
}

.dialogue-bubble.is-nudging::before {
  background-image: linear-gradient(
    to top right,
    rgb(255 255 255 / calc(var(--nudge-glow) * 0.45)),
    rgb(255 255 255 / calc(var(--nudge-glow) * 0.25)) 50%,
    transparent 50%
  );
  animation: dialogue-nudge-tail 2.4s ease-in-out infinite;
}

.dialogue-strip.is-right .dialogue-bubble.is-nudging::before {
  background-image: linear-gradient(
    to bottom left,
    rgb(255 255 255 / calc(var(--nudge-glow) * 0.45)),
    rgb(255 255 255 / calc(var(--nudge-glow) * 0.25)) 50%,
    transparent 50%
  );
}

@keyframes dialogue-nudge-tail {
  0%, 100% { --nudge-glow: 0; }
  50% { --nudge-glow: 1; }
}

.dialogue-bust.is-clickable,
.dialogue-bust.is-clickable .royal-plate,
.dialogue-bubble.is-clickable {
  pointer-events: auto;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.dialogue-name {
  color: var(--dialogue-emphasis);
  font-weight: 600;
  margin-bottom: 4px;
}

.dialogue-line {
  white-space: pre-wrap;
}

/* Words the author wraps in asterisks (wipe.js emphasisRuns) draw bold in the speaker
   name's colour: amber, or a clanker's cyan. */
.dialogue-line strong {
  color: var(--dialogue-emphasis);
}

/* A choice (dialogue.js pick): the option buttons under the line, the one part of the
   bubble that takes taps. The author's words wrap rather than clip at phone width. */
.dialogue-options {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  pointer-events: auto;
}

.dialogue-options:empty {
  display: none;
}

.dialogue-options .btn {
  min-width: 0;
}

.dialogue-options .btn-label {
  padding: 6px 0;
  line-height: 1.2;
  white-space: normal;
}

.dialogue-options .btn:disabled .btn-label {
  visibility: hidden;
}

.dialogue-live {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.city-sheet,
.map-cell-sheet {
  position: absolute;
  left: 0;
  top: 0;
  z-index: var(--z-mid);
  min-width: 160px;
  padding: 10px 12px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  pointer-events: auto;
}

html.is-pointer-guard .building-sheet,
html.is-pointer-guard .building-sheet *,
html.is-pointer-guard .city-sheet,
html.is-pointer-guard .city-sheet *,
html.is-pointer-guard .map-cell-sheet,
html.is-pointer-guard .map-cell-sheet * {
  pointer-events: none;
}

/* The held building's line in the top panel: the morale the move makes,
   why a wall the move lines up won't form, then, for a mouse, its keys. */
.hold-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.hold-info-chip {
  padding: 2px 8px;
  border-radius: 5px;
  background: var(--surface-1);
  border: 1px solid var(--play-line-strong);
  font-family: var(--font-ui);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--text-dim);
}

.hold-info-chip[data-tone="good"] {
  color: var(--ok);
}

.hold-info-chip[data-tone="bad"] {
  color: var(--warn);
}

/* Card and rail form one measured box for pinLeftover. */
.building-sheet {
  --city-sheet-tool-width: 46px;
  --city-sheet-gap: 8px;
  position: absolute;
  left: 0;
  top: 0;
  z-index: var(--z-mid);
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--city-sheet-tool-width);
  grid-template-rows: auto auto;
  gap: 0 var(--city-sheet-gap);
  width: 360px;
  max-width: calc(100% - 24px);
  pointer-events: auto;
  --city-sheet-content-pad: 12px 18px;
}

.city-sheet-tools {
  display: grid;
  grid-row: 1 / 3;
  grid-template-rows: subgrid;
}
.city-sheet-levels {
  display: flex;
  flex-direction: column;
  grid-row: 2;
  align-self: start;
  gap: 4px;
}
:where(.city-sheet-tools:has(.city-sheet-move:not([hidden]))) .city-sheet-levels { padding-top: 4px; }
.city-sheet-head { display: flex; align-items: center; gap: 8px; }

.city-find-modal {
  position: absolute;
  inset: 0;
  z-index: var(--z-mid);
  display: none;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
}

.city-find-modal:not([hidden]) {
  display: flex;
}


.city-find-sheet {
  position: relative;
  left: auto;
  top: auto;
  z-index: 1;
  min-width: 220px;
}

/* The defeat screen (defeat_screen.js): how the battle ended over what the city lost. */
.city-defeat-sheet {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: min(360px, calc(100vw - 32px));
}

.screen-play:is(.find-open, .city-unloading) .play-top-row,
.screen-play:is(.find-open, .city-unloading) .play-top-hud,
.screen-play:is(.find-open, .city-unloading) .city-play-btns,
.screen-play:is(.find-open, .city-unloading) .menu-bar,
.screen-play:is(.find-open, .city-unloading) .notifications,
.screen-play:is(.find-open, .city-unloading) #radio-host,
.screen-play:is(.find-open, .city-unloading) .top-panel,
.screen-play:is(.find-open, .city-unloading) .city-family-sheet,
.screen-play:is(.find-open, .city-unloading) #city-sheet {
  display: none;
}

/* An opener draws across the whole screen, over the dimmed game, with nothing boxing it. */
.city-find-panel {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.city-find-panel[hidden] {
  display: none;
}

.city-find-stage {
  position: absolute;
  inset: 0;
  touch-action: none;
  pointer-events: auto;
  overflow: hidden;
}

/* Where the opener's camera frames its subject; the scene draws past it to the screen's edges. */
.city-find-focus {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(100% - 32px, 960px);
  height: clamp(320px, 62vh, 560px);
  translate: -50% -50%;
  pointer-events: none;
}

.city-find-stage canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  /* A tap on a key or the lock is play, not a link: no tint over the whole stage. */
  -webkit-tap-highlight-color: transparent;
}

button.city-find-leave {
  position: absolute;
  top: max(12px, env(safe-area-inset-top));
  right: max(12px, env(safe-area-inset-right));
  z-index: 3;
  pointer-events: auto;
}

button.city-find-leave[hidden] {
  display: none;
}

.city-find-deal {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.city-find-cards {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.city-find-cards[hidden] {
  display: none;
}

button.city-find-card {
  position: absolute;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font-family: var(--font-ui);
  perspective: 900px;
  cursor: pointer;
  pointer-events: auto;
  transition: filter 220ms ease;
  -webkit-tap-highlight-color: transparent;
}

button.city-find-card:disabled {
  opacity: 1;
  filter: none;
  pointer-events: none;
  cursor: default;
}

.city-find-card-inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: translate 160ms ease;
}

.city-find-card:not(:disabled):hover .city-find-card-inner,
.city-find-card:focus-visible .city-find-card-inner {
  translate: 0 -6px;
}

.city-find-card:not(:disabled):hover .city-find-card-back,
.city-find-card:focus-visible .city-find-card-back {
  border-color: var(--skin-accent);
}

.city-find-card.is-up .city-find-card-inner {
  transform: rotateY(180deg);
}

.city-find-card-back,
.city-find-card-front {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  box-sizing: border-box;
  padding: 8px;
  backface-visibility: hidden;
}

/* Face down, a card is a panel: the panel fill inside the panel line, a question mark in the accent. */
.city-find-card-back {
  border: var(--panel-border);
  background: var(--surface-1);
  color: var(--skin-accent);
  transition: border-color 140ms linear;
}

.city-find-card-stamp {
  font-family: var(--font-display);
  font-size: 64px;
  font-weight: 700;
  line-height: 1;
}

.city-find-card-sealed {
  margin-top: 6px;
  color: var(--muted);
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 3px;
}

/* Face up, a card is a row card standing on end: the raised fill. */
.city-find-card-front {
  background: var(--surface-2);
  transform: rotateY(180deg);
  overflow: hidden;
}

.city-find-card-front::after {
  content: "";
  position: absolute;
  inset: -40%;
  background: linear-gradient(115deg, transparent 35%, #fff7 49%, transparent 62%);
  translate: -100% 0;
  pointer-events: none;
}

.city-find-card.is-up .city-find-card-front::after {
  animation: find-card-sheen 700ms 220ms ease-out both;
}

.city-find-card-icon {
  width: 56px;
  height: 56px;
  color: var(--find-item);
}

.screen-play .city-find-card-icon .i {
  width: 100%;
  height: 100%;
  filter: none;
}

.city-find-card-name {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-weight: 600;
  line-height: 1.2;
}

/* A card's note under its amount: a fragment found before any Workshop stands. Up to two
   lines fit the card because its icon shrinks to make room. */
.city-find-card-note {
  color: var(--warn);
  font-size: var(--caption-text-size);
  font-weight: 600;
  line-height: 1.1;
  text-align: center;
}

.city-find-card.has-note .city-find-card-icon {
  width: 40px;
  height: 40px;
}

.city-find-card-qty {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.city-find-card::after {
  content: "";
  position: absolute;
  inset: -10px;
  border: 2px solid var(--find-item);
  opacity: 0;
  pointer-events: none;
}

.city-find-card.is-up::after {
  animation: find-card-burst 520ms 240ms ease-out;
}

/* Rarity's palette: anything of a rare or epic item wears is-rare or is-epic
   (item_look.js rarityClass) and reads these. A find card's back matches
   every other card; only the face tells. */
.is-rare {
  --tier-deep: #7a5410;
  --tier-mid: #c8861a;
  --tier-lit: #ffe28a;
  --tier-pale: #fff4c2;
  --tier-fill: #5b4516;
  --tier-glow: #ffc24a;
  --tier-ink: #2a1a04;
}

.is-epic {
  --tier-deep: #4a1d7a;
  --tier-mid: #9a4dff;
  --tier-lit: #dcb3ff;
  --tier-pale: #f6eaff;
  --tier-fill: #3b2258;
  --tier-glow: #b46cff;
  --tier-ink: #1c0833;
}

.city-find-card.is-tier .city-find-card-front {
  border: 2px solid transparent;
  background:
    linear-gradient(var(--tier-fill), var(--surface-2)) padding-box,
    conic-gradient(from var(--tier-spin, 0deg), var(--tier-deep), var(--tier-lit), var(--tier-mid), var(--tier-pale), var(--tier-deep)) border-box;
  box-shadow: 0 0 16px color-mix(in srgb, var(--tier-glow) 40%, transparent);
}

.city-find-card.is-tier.is-up .city-find-card-front {
  animation: find-tier-spin 2.4s linear infinite, find-tier-glow 1.6s ease-in-out infinite alternate;
}

.city-find-card-tag {
  position: absolute;
  inset: 0;
  transform: rotateY(180deg) translateZ(1px);
  backface-visibility: hidden;
  pointer-events: none;
}

/* A rare or epic item's badge: its tier word on a tag in the tier's colours
   (rarityLabel). Its owner places it. */
.tier-badge {
  padding: 3px 9px;
  border-radius: var(--control-radius);
  background: linear-gradient(var(--tier-lit), var(--tier-mid));
  color: var(--tier-ink);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
  box-shadow: 0 0 0 2px #0d1212, 0 0 10px color-mix(in srgb, var(--tier-glow) 60%, transparent);
}

.city-find-card-badge {
  position: absolute;
  top: 0;
  left: 75%;
  translate: -50% -50%;
}

.city-find-cards.is-spotlight .city-find-card:not(.is-spotlit) {
  filter: brightness(.4) saturate(.5);
  pointer-events: none;
}

.city-find-card.is-spotlit { z-index: 2; }

.city-find-card.is-tier.is-up::after { animation: none; }

.city-find-card.is-tier.is-landed::after {
  border-color: var(--tier-lit);
  animation: find-tier-burst 700ms ease-out;
}

.city-find-spark {
  position: absolute;
  width: 3px;
  height: 12px;
  margin: -6px 0 0 -1.5px;
  border-radius: 2px;
  background: linear-gradient(#fff, var(--tier-lit) 40%, var(--tier-mid));
  box-shadow: 0 0 6px var(--tier-glow);
  pointer-events: none;
}

.city-find-deal:has(.city-find-cards:not([hidden])) {
  background: color-mix(in srgb, var(--surface-1) 70%, transparent);
  animation: find-reveal-in 350ms ease-out both;
}

html.dim-blur .city-find-deal:has(.city-find-cards:not([hidden])) {
  backdrop-filter: blur(3px);
}

.city-find-trunk-target {
  position: absolute;
  width: 40px;
  height: 40px;
  translate: -50% -50%;
  border: 1px solid #f1cf87b3;
  border-radius: 50%;
  box-shadow: 0 0 20px #e9b96722, inset 0 0 12px #e9b96722;
  pointer-events: none;
}

.city-find-trunk-target::after {
  content: "";
  position: absolute;
  inset: -6px;
  border: 1px solid #f1cf8740;
  border-radius: 50%;
}

.city-find-stage:not([data-phase="idle"]) .city-find-trunk-target { display: none; }
.city-find-stage[data-phase="armed"] canvas { cursor: ns-resize; }
.city-find-stage[data-phase="idle"] canvas { cursor: crosshair; }

.city-find-trunk-force {
  position: absolute;
  bottom: 13px;
  left: 50%;
  translate: -50% 0;
  width: 140px;
  height: 3px;
  background: #b0bba329;
  opacity: 0;
  pointer-events: none;
}

.city-find-trunk-force span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #b4bd96, #f5c15f, #ff8051);
  box-shadow: 0 0 10px #e99c6266;
  transform-origin: left;
}

.city-find-stage[data-phase="armed"] .city-find-trunk-force,
.city-find-stage[data-phase="committed"] .city-find-trunk-force { opacity: 1; }
@keyframes find-card-burst {
  0% { opacity: .9; transform: scale(.8); }
  100% { opacity: 0; transform: scale(1.3); }
}
@keyframes find-card-sheen {
  to { translate: 100% 0; }
}
@keyframes find-reveal-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
@property --tier-spin {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}
@keyframes find-tier-spin {
  to { --tier-spin: 360deg; }
}
@keyframes find-tier-glow {
  from { box-shadow: 0 0 10px color-mix(in srgb, var(--tier-glow) 27%, transparent); }
  to { box-shadow: 0 0 28px color-mix(in srgb, var(--tier-glow) 67%, transparent); }
}
@keyframes find-tier-burst {
  0% { opacity: 1; transform: scale(.9); box-shadow: 0 0 30px var(--tier-glow); }
  100% { opacity: 0; transform: scale(1.6); box-shadow: 0 0 0 transparent; }
}

button.city-find-close {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 3;
  min-width: 140px;
  pointer-events: auto;
  transform: translate(-50%, 28px);
}

button.city-find-close[hidden] {
  display: none;
}

.city-sheet-title,
.map-cell-sheet-title {
  font-weight: 600;
}

.city-family-sheet-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.city-family-sheet-look {
  position: relative;
  width: 72px;
  height: 72px;
  flex: 0 0 72px;
  overflow: hidden;
  background: #f6f1e5;
}

.city-family-bubbles {
  position: absolute;
  inset: 0;
  z-index: var(--z-names);
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition-property: opacity;
  transition-timing-function: linear;
}

.city-family-bubbles.is-on {
  opacity: 1;
}

.city-family-bubble {
  position: absolute;
  left: 0;
  top: 0;
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  overflow: hidden;
  background: #f6f1e5;
  pointer-events: auto;
  box-shadow: var(--shadow);
  transform-origin: 50% 100%;
}

.city-family-bubble::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 50%;
  border: 1px solid #000;
  pointer-events: none;
}

.city-family-bubble.is-founding::after {
  border: 1px solid var(--gold-400);
}

.city-family-bubble canvas {
  display: block;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  pointer-events: none;
}

.screen-play.city-arranging .city-family-bubbles {
  display: none;
}

/* Battalion icons (battalion_icons.js): a troop glyph on a dark disc in
   its side's ring over each battalion, and under every icon a line down
   towards its troops, fading out as it nears them. The layer takes no
   pointer events; the battle hit-tests taps. JS sets --icon-px and --side
   once per icon, --icon-ring (the ring's width, a share of the icon's) on
   the layer, and --flash while one blinks. */
.battle-icons {
  --icon-line-w: 2px;
  position: absolute;
  inset: 0;
  z-index: var(--z-names);
  overflow: hidden;
  pointer-events: none;
  transition: opacity 0.3s linear;
}

.battle-icons.is-off {
  opacity: 0;
}

.battle-icon,
.battle-icon-line {
  position: absolute;
  left: 0;
  top: 0;
}

.battle-icon {
  width: var(--icon-px);
  height: var(--icon-px);
  border-radius: 50%;
  box-shadow: 0 2px 6px #0008;
}

/* The disc fills the icon up to the ring's inner edge. */
.battle-icon-pic {
  position: absolute;
  inset: var(--icon-ring);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-panel);
  color: #f4f1ea;
}

.battle-icon-pic > .i {
  width: 68%;
  height: 68%;
}

.battle-icon-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--side);
}

.battle-icon.is-selected {
  box-shadow: 0 0 0 2px var(--selected-line), 0 0 10px 2px color-mix(in srgb, var(--selected-line) 55%, transparent);
}

.battle-icon.is-flash {
  box-shadow: 0 0 0 3px var(--flash), 0 0 16px 6px color-mix(in srgb, var(--flash) 80%, transparent);
  filter: brightness(1.4);
}

/* Laid from its foot (x 0) to the icon's centre (x 1): clear at the foot,
   full at the icon. */
.battle-icon-line {
  width: 1px;
  height: var(--icon-line-w);
  margin-top: calc(var(--icon-line-w) / -2);
  background: linear-gradient(to right, transparent, var(--side));
  transform-origin: 0 50%;
}

.city-sheet-sub,
.city-sheet-row {
  white-space: pre-line;
}

.city-sheet-row {
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.city-sheet-energy {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--meta-text-size);
  font-variant-numeric: tabular-nums;
}

.city-sheet-energy .city-sheet-energy-track {
  flex: 1;
  min-width: 60px;
  margin-top: 0;
}

.city-sheet-energy-track {
  height: 8px;
  margin-top: 6px;
  background: color-mix(in srgb, var(--line) 70%, transparent);
  overflow: hidden;
}

.city-sheet-energy-fill {
  height: 100%;
  width: 0;
}

.city-sheet-energy-fill.green {
  background: #16a34a;
}

.city-sheet-energy-fill.red {
  background: #dc2626;
}

.city-sheet-craft-out {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin: 6px 0 4px;
}

/* A detail taller than its sheet scrolls, so its actions stay reachable. */
#build-detail,
#plant-detail {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
}

#plant-panel.panel-pane {
  overflow: hidden;
}

/* A quantity slider with a reach: green while stock pays for the quantity,
   amber while chits buy what stock lacks, and short past both. Behind the
   fill, a dim green reach runs to where the knob's right edge sits at the
   most stock pays for (--stock, 0 to 1 along the slider), and with chits a
   dim amber one on to the most stock and chits do (--reach); both set by
   the owner, ui/quantity.js. Each reach ends round: a flat stretch to where
   that knob's centre sits, then a half disc (a radial gradient in a box
   half the bar's height wide) out to its right edge. It stacks above a
   .room-track's hatching.

   Alone, the green reach is see-through over the track. With chits
   (.chit-reach) both reaches are opaque, mixed over --reach-ground, the
   solid surface the slider sits on, to look the same: the amber runs from
   the start to its end and the green lies over it, so the green's round
   end shows on the amber, and each flat stretch runs 1px into its disc so
   no seam shows where two meet. */
.reach-range {
  --range-fill: var(--ok);
  --reach: 0;
  --stock: var(--reach);
  --reach-color: color-mix(in srgb, var(--ok) 20%, transparent);
  position: relative;
  display: block;
  width: 100%;
  margin: 6px 0;
  background:
    linear-gradient(var(--reach-color), var(--reach-color))
      0 0 / calc(var(--range-h) / 2 + var(--reach) * (100% - var(--range-h))) 100% no-repeat,
    radial-gradient(circle at 0 50%,
      var(--reach-color) calc(var(--range-h) / 2 - 1px),
      transparent calc(var(--range-h) / 2))
      calc(var(--range-h) / 2 + var(--reach) * (100% - var(--range-h) / 2)) 0 / calc(var(--range-h) / 2) 100% no-repeat,
    var(--range-track);
}

.reach-range.chit-reach {
  --reach-track: color-mix(in srgb, var(--text) 14%, var(--reach-ground));
  --reach-color: color-mix(in srgb, var(--ok) 20%, var(--reach-track));
  --buy-color: color-mix(in srgb, var(--warn) 25%, var(--reach-track));
  background:
    linear-gradient(var(--reach-color), var(--reach-color))
      0 0 / calc(var(--range-h) / 2 + var(--stock) * (100% - var(--range-h)) + 1px) 100% no-repeat,
    radial-gradient(circle at 0 50%,
      var(--reach-color) calc(var(--range-h) / 2 - 1px),
      transparent calc(var(--range-h) / 2))
      calc(var(--range-h) / 2 + var(--stock) * (100% - var(--range-h) / 2)) 0 / calc(var(--range-h) / 2) 100% no-repeat,
    linear-gradient(var(--buy-color), var(--buy-color))
      0 0 / calc(var(--range-h) / 2 + var(--reach) * (100% - var(--range-h)) + 1px) 100% no-repeat,
    radial-gradient(circle at 0 50%,
      var(--buy-color) calc(var(--range-h) / 2 - 1px),
      transparent calc(var(--range-h) / 2))
      calc(var(--range-h) / 2 + var(--reach) * (100% - var(--range-h) / 2)) 0 / calc(var(--range-h) / 2) 100% no-repeat,
    var(--range-track);
}

.reach-range.buys {
  --range-fill: var(--warn);
}

.reach-range.short {
  --range-fill: var(--accent);
}

/* A slider's wall: past --room (0 to 1, set by ui/quantity.js) its knob can't
   go, so the track there is hatched. The hatching sits behind the slider,
   from where the knob's centre would sit at that most to the end, its left
   edge cut to the knob's curve: a knob at the wall nests in it with no gap,
   and one short of it sees the wall's round edge. */
.room-track {
  --room: 1;
  --room-hatch: color-mix(in srgb, var(--text) 16%, transparent);
  position: relative;
}

.room-track::before {
  --knob-r: calc(var(--range-h) / 2);
  --wall-cut: radial-gradient(circle at 0 50%, transparent var(--knob-r), #000 calc(var(--knob-r) + 0.5px));
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: calc((1 - var(--room)) * (100% - var(--range-h)) + var(--knob-r));
  height: var(--range-h);
  translate: 0 -50%;
  border-radius: 0 var(--knob-r) var(--knob-r) 0;
  background: repeating-linear-gradient(135deg, var(--room-hatch) 0 3px, transparent 3px 8px);
  -webkit-mask: var(--wall-cut);
  mask: var(--wall-cut);
  pointer-events: none;
}

/* The Repair, Scrap, and troop Make tabs: a line on what happens, beside
   Max and None (and All on Repair), then a card for each troop type (its
   picture, name, how many the tab takes of how many it could, its slider,
   and what that count costs or could give). Repair and Make add the whole
   cost as need / have, the requirements, and the time; each ends in its
   button across the foot. */
.troop-quick {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
}

.troop-rows {
  display: grid;
  gap: 8px;
  margin-block: 8px;
}

.troop-row-head {
  display: flex;
  align-items: center;
  gap: 8px;
}

.troop-row-name {
  font-weight: 700;
}

.troop-row-count {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}

/* A troop type the building's level has not reached yet fades, its count
   saying what unlocks it. */
.troop-row.is-locked {
  opacity: var(--dim-opacity);
}

/* A recipe's own view: its picture and name, the quantity slider, then what
   it takes beside what it makes as the recipe list's pills, the time to
   complete, and the start button across the foot. Upgrade and Expand share its
   head for the rung they start. */
.detail-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 2px 0 14px;
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  font-weight: 700;
}

.detail-head-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--text) 8%, transparent);
}

.detail-head-icon .i {
  width: 28px;
  height: 28px;
}

.term-label {
  font-weight: 600;
  font-size: 0.85rem;
}

/* Pills sit two to a row: a settler's skill stats, the raider card's potential loot, a repair row's cost. */
.term-list.two-up {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

/* A term that changes: what it was, faint, before what it becomes. */
.formula-was {
  color: var(--muted);
  font-weight: 500;
}

/* A weapon system's reach against the farthest any fires: the dead zone it
   can't fire into hatched red, the ground it reaches gold, a tick at each
   edge. */
.reach-bar {
  position: relative;
  margin-top: 10px;
  padding-bottom: 16px;
}

.reach-track {
  position: relative;
  display: block;
  height: 10px;
  border-radius: 5px;
  background: color-mix(in srgb, var(--text) 8%, transparent);
  box-shadow: inset 0 0 0 1px var(--line);
  overflow: hidden;
}

.reach-dead,
.reach-live {
  position: absolute;
  top: 0;
  bottom: 0;
}

.reach-dead {
  left: 0;
  background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--alert) 60%, transparent) 0 3px, transparent 3px 6px);
}

.reach-live {
  border-radius: 5px;
  background: linear-gradient(var(--gold-200), var(--gold-500));
}

.reach-ticks {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 14px;
}

.reach-tick {
  position: absolute;
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
}

.reach-tick.is-min {
  transform: translateX(-50%);
}

.reach-tick.is-max {
  transform: translateX(-100%);
}

/* How a weapon system fares against each target class, a chip each: strong
   green, weak yellow, a class it can't hit red and struck through. */
.matchups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-top: 10px;
}

.matchup {
  display: flex;
  flex-direction: column;
  padding: 5px 9px;
  border-radius: 8px;
  background: var(--chip-well);
  box-shadow: inset 0 0 0 1px var(--line);
  line-height: 1.15;
}

.matchup-class {
  font-weight: 600;
  font-size: 0.85rem;
}

.matchup-state {
  color: var(--muted);
  font-size: var(--caption-text-size);
}

.matchup[data-state="strong"] {
  background: color-mix(in srgb, var(--ok) 16%, var(--chip-well));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ok) 55%, transparent);
}

.matchup[data-state="strong"] .matchup-state {
  color: var(--ok-text);
}

.matchup[data-state="weak"] {
  background: color-mix(in srgb, var(--warn) 14%, var(--chip-well));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 55%, transparent);
}

.matchup[data-state="weak"] .matchup-state {
  color: var(--warn);
}

.matchup[data-state="misses"] {
  background: color-mix(in srgb, var(--alert) 14%, var(--chip-well));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--alert) 55%, transparent);
}

.matchup[data-state="misses"] .matchup-class {
  text-decoration: line-through;
}

.matchup[data-state="misses"] .matchup-state {
  color: var(--alert);
}

/* A weapon's stats (weapon_stats_view.js) on the Floor plan: its range and
   damage a second in a line, its reach, and its matchups. In a Build tile
   they span the tile under its words. */
.weapon-stats-line {
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
}

.screen-play .inv-tile > .weapon-stats {
  grid-column: 1 / -1;
}

/* Two columns of formula pills in labelled groups, a group hidden while it
   has none: the recipe view, Build, Upgrade, Expand, and call cards. The
   recipe view stacks them in portrait (.stack-portrait). */
.term-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  margin-top: 10px;
}

.aspect-portrait .stack-portrait {
  grid-template-columns: minmax(0, 1fr);
}

.aspect-portrait .building-columns .formula-text {
  min-width: 0;
}

.aspect-portrait .building-columns :is(.formula-qty, .formula-name) {
  white-space: normal;
  overflow-wrap: anywhere;
}

.term-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 6px;
}

.term-group:not([hidden]) ~ .term-group {
  margin-top: 12px;
}

.term-list .formula-term {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.city-sheet-collect,
.map-cell-sheet-prospect,
.map-cell-sheet-construct,
.map-cell-sheet-mine,
.map-cell-sheet-summon,
.map-cell-sheet-move-city,
.map-cell-sheet-recall,
.map-cell-sheet-recall-all,
.map-cell-sheet-view {
  width: 100%;
  margin-top: 8px;
}

.map-cell-sheet-patch {
  white-space: pre-wrap;
}

.map-cell-sheet-leave-text {
  font-size: 0.85rem;
  margin-top: 8px;
}

.map-cell-sheet-leave-row {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.map-cell-sheet-leave-row button {
  flex: 1;
  min-width: 0;
}

.mine-status,
.mine-stock,
.mine-occupancy,
.mine-construct-stock {
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.mine-prefs {
  display: flex;
  gap: 8px;
  margin: 8px 0;
}

.mine-pref {
  flex: 1;
  min-width: 0;
}

.mine-error {
  color: var(--danger);
  font-size: var(--meta-text-size);
}

/* The costs line: the scrap and builders a mine costs, then its build
   time, compact terms wrapping as one row. */
.mine-construct-costs-line,
.mine-construct-term-group {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.mine-construct-costs-line {
  flex: 1;
}

.mine-construct-term-list {
  display: contents;
}

.mine-construct-error {
  color: var(--danger);
  font-size: var(--meta-text-size);
}

.mine-construct-field {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
}

.mine-construct-field input[type="range"] {
  flex: 1;
}

.map-cell-sheet-error,
.map-cell-sheet-tax,
.map-cell-sheet-patch,
.map-cell-sheet-block,
.map-cell-sheet-family,
.map-cell-sheet-status,
.map-cell-sheet-city-name {
  color: var(--muted);
  font-size: var(--meta-text-size);
  margin-top: 6px;
}

/* Logs and scrap: icon, a bar against the map's richest cell, the amount. */
.map-cell-sheet-stock {
  display: grid;
  grid-template-columns: max-content minmax(96px, 1fr) max-content;
  align-items: center;
  gap: 6px 8px;
  margin-top: 6px;
}

.map-cell-sheet-stock[hidden] {
  display: none;
}

.map-cell-sheet-stock-row {
  display: contents;
}

.screen-play .map-cell-sheet-stock .i {
  width: 20px;
  height: 20px;
}

.map-cell-sheet-stock-qty {
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.map-cell-sheet-occupants {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.map-cell-sheet-royal {
  display: flex;
  align-items: center;
  gap: 8px;
}

.map-cell-sheet-bust {
  position: relative;
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  overflow: hidden;
  background: #f6f1e5;
}

.map-cell-sheet-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.map-cell-sheet-name {
  font-weight: 600;
}

/* A raider city's loot: each group's label on a line, then a compact term
   per item (raiderLoot), wrapping to the sheet's width. */
.map-cell-sheet-loot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
}

.map-cell-sheet-loot-label {
  flex-basis: 100%;
  color: var(--muted);
  font-size: 0.8rem;
}

.map-cell-sheet-skel {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.map-cell-sheet-skel-line {
  height: 12px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--muted) 28%, transparent);
  animation: map-cell-skel 1s ease-in-out infinite;
}

.map-cell-sheet-skel-line.short {
  width: 55%;
}

@keyframes map-cell-skel {
  50% { opacity: 0.45; }
}

.city-sheet-collect.blocked {
  opacity: var(--dim-opacity);
}

.upgrade-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 8px 6px;
  margin: 0 -8px;
}

.upgrade-table th {
  text-align: left;
  font-weight: 600;
  font-size: 0.85rem;
}

.upgrade-table td {
  width: 50%;
  vertical-align: top;
}

.upgrade-table.is-single td {
  width: 100%;
}

.upgrade-table tr.staff button {
  min-width: 2.75rem;
  margin-left: 8px;
}

.upgrade-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: color-mix(in srgb, var(--panel) 50%, var(--bg));
  border: 1px solid color-mix(in srgb, var(--line) 50%, var(--panel));
  font-size: 0.9rem;
}

.upgrade-cell.short {
  background: color-mix(in srgb, var(--btn-negative) 50%, var(--panel));
  color: var(--ink);
  border-color: color-mix(in srgb, var(--btn-negative) 50%, var(--panel));
}

.upgrade-cell-text {
  flex: 1;
  min-width: 0;
}

.upgrade-check {
  margin-left: auto;
  flex: none;
}

.morale-tail {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
}

.morale-tail .upgrade-check {
  margin-left: 0;
}

.morale-delta {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.upgrade-go {
  flex: none;
}

#upgrade-start,
#field-expand-start,
#build-start,
#plant-start {
  flex: 1 1 auto;
  min-width: 0;
}

#upgrade-start.blocked,
#field-expand-start.blocked,
#build-start.blocked,
#plant-start.blocked {
  opacity: var(--dim-opacity);
}

.screen-play .manage-depleted {
  margin: 0;
  padding: 8px 11px;
  border: 1.5px solid var(--alert);
  border-radius: 8px;
  background: color-mix(in srgb, var(--alert) 12%, transparent);
  color: var(--alert);
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 15px;
  line-height: 1.3;
}

.build-detail-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

/* A start row outside a panel pane's 12px gap (Build, Plant, a floor plan's
   detail) carries the whole space a pane's start row gets above it. */
.loose-actions {
  margin-top: 24px;
}

/* A pane's call to action sits at its bottom right. */
.end-actions {
  justify-content: flex-end;
}

.screen-play.city-arranging .building-sheet,
.screen-play.city-arranging .city-sheet,
.screen-play.city-arranging .city-find-modal,
.screen-play.city-arranging .city-family-sheet {
  display: none;
}

/* The notification slot (notifications.js): the play column's bottom right, its right edge a
   --menu-inset in from the play chrome's (--play-width, centred), whatever is open. A card with
   an anchor gets --notification-bottom measured from the menu bar's top edge. Floor chrome on its left (Edit and Build
   in portrait) narrows it to --notification-room beside that chrome. The slot clips its card
   --notification-pad below where the card rests, the menu bar's top edge, so a card rises from
   behind what is under it and falls back behind it. A card swiped sideways (portrait) leaves by
   --notification-leave-x instead, off the screen. A flung card leaves at its fling's speed:
   --notification-leave-ease linear over the --notification-leave-ms its distance takes. */
.notifications {
  position: absolute;
  right: calc((100% - var(--play-width)) / 2 + var(--menu-inset));
  bottom: var(--notification-bottom, var(--notification-pad, 8px));
  z-index: var(--z-toasts);
  max-width: min(var(--notification-max, 380px), calc(var(--play-width) - 2 * var(--menu-inset)), var(--notification-room, 100%));
  clip-path: inset(-100vh -100vw calc(-1 * var(--notification-pad, 8px)) -100vw);
  pointer-events: none;
}

.notification {
  position: relative;
  isolation: isolate;
  margin: 0;
  padding: 8px 12px;
  pointer-events: auto;
  touch-action: none;
  transform: translate3d(0, calc(100% + var(--notification-pad, 8px)), 0);
  transition: transform calc(var(--panel-enter-ms) * 1ms) var(--panel-enter-ease);
}

.notifications.is-open .notification {
  transform: none;
}

.notifications.is-leaving .notification {
  transform: translate3d(var(--notification-leave-x, 0), var(--notification-leave-y, calc(100% + var(--notification-pad, 8px))), 0);
  transition-timing-function: var(--notification-leave-ease, cubic-bezier(.4, 0, 1, 1));
  transition-duration: var(--notification-leave-ms);
}

.notifications.is-entering .notification,
.notifications.is-leaving .notification {
  pointer-events: none;
}

/* The fill clips to the card's corners; the drain runs on its ::before. */
.notification-fill {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
  z-index: 0;
}

.notification-fill::before {
  content: "";
  position: absolute;
  inset: 0;
  transform-origin: left center;
}

.notification.is-holding .notification-fill::before {
  animation: notification-drain var(--notification-hold-ms, 3000ms) linear forwards;
}

@keyframes notification-drain {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

.notification-body {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.notification.is-shake {
  animation: notification-shake var(--notification-shake-ms, 250ms) ease-in;
}

@keyframes notification-shake {
  0%,
  100% {
    translate: 0 0;
  }
  20% {
    translate: var(--notification-shake, 5.5px) 0;
  }
  40% {
    translate: calc(-1 * var(--notification-shake, 5.5px)) 0;
  }
  60% {
    translate: calc(0.6 * var(--notification-shake, 5.5px)) 0;
  }
  80% {
    translate: calc(-0.4 * var(--notification-shake, 5.5px)) 0;
  }
}

.notification-icon {
  flex: 0 0 auto;
  display: flex;
  width: 22px;
  height: 22px;
  align-self: start;
}

.notification-icon[hidden] {
  display: none;
}

.notification-icon .i {
  width: 100%;
  height: 100%;
}

.notification-text {
  flex: 1 1 auto;
  min-width: 0;
  white-space: pre-line;
}

.notification-count {
  flex: 0 0 auto;
  font-weight: 600;
}

/* A card's action (show's action) is a green compact button at the card's end. */
.notification-action {
  flex: 0 0 auto;
  min-width: var(--icon-control-size);
  padding: 0 8px;
}

.city-editor {
  position: absolute;
  inset: 0;
  z-index: var(--z-mid);
  pointer-events: none;
}

.city-editor-bar {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: var(--z-chrome);
  display: flex;
  gap: 8px;
  pointer-events: auto;
}

.screen-play.city-arranging .top-bar,
.screen-play.city-arranging .menu-bar:where(:not(:has(.city-held))),
.screen-play.city-arranging .play-left-cluster,
.screen-play.city-arranging .account-chip,
.screen-play.city-arranging .city-play-btns,
.screen-play.city-arranging .day-clock {
  display: none;
}

.screen-play.map-open .city-play-btns,
.screen-play.map-open .building-sheet,
.screen-play.map-open .city-sheet,
.screen-play.map-open .city-find-modal,
.screen-play.map-open .city-family-sheet,
.screen-play.map-open .city-family-bubbles,
.screen-play.map-open .battle-icons,
.screen-play.map-open .city-editor {
  display: none;
}

.screen-play:not(.map-open) .map-cell-sheet {
  display: none;
}

/* A scrolling list of catalogue tiles (build_tile.js): Plant's one grid, or
   Build's headed sections, each its own grid. The padding leaves the corner
   badge room to hang. */
.build-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  gap: 18px;
  padding: calc(var(--badge-hang) + 10px) calc(var(--badge-hang) + 10px) 10px 10px;
}

/* Rows hold each tile's full height, so a short panel scrolls the list
   instead of squeezing the seed strip and name plate out of the tiles. */
.build-grid {
  display: grid;
  grid-template-columns: repeat(var(--tile-cols), minmax(0, 1fr));
  grid-auto-rows: max-content;
  align-content: start;
  justify-content: start;
  gap: var(--tile-gap);
  --tile-cols: 1;
  --tile-gap: 8px;
}

/* A row: the big icon, then the building's details. The icon stands as
   tall as the name over two rows of need pills, so a second row never
   grows the tile. A tile too narrow for two pill columns beside the icon
   puts a smaller icon beside the name and the pills under both. */
.build-tile {
  container: build-tile / inline-size;
  --build-name-size: var(--tile-title-size);
  --build-name-line: 1.25;
  --build-needs-gap: 6px;
  --build-glyph-size: calc(var(--build-name-size) * var(--build-name-line) + 2 * (var(--build-needs-gap) + var(--term-height)));
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  width: 100%;
  min-width: 0;
  padding: 0;
  overflow: visible;
  text-align: left;
  z-index: 0;
  transition:
    background-color 140ms linear,
    border-color 140ms linear,
    opacity 140ms linear;
}

.screen-play .build-tile {
  color: var(--text);
  font-family: var(--font-ui);
  font-weight: 600;
  box-shadow: none;
  text-shadow: none;
  filter: none;
  border: 0;
  background: var(--skin-raised);
  padding: 10px;
}

/* Whole-pixel columns. A fractional track puts the 1px border on a half
   pixel. A WebView without round() skips this block and keeps the
   fractional columns and full width above. */
@supports (width: round(down, 100%, 1px)) {
  .build-grid {
    grid-template-columns: repeat(
      var(--tile-cols),
      round(down, (100% - (var(--tile-cols) - 1) * var(--tile-gap)) / var(--tile-cols), 1px)
    );
  }

  .build-tile {
    width: round(down, 100%, 1px);
  }
}

/* Clipped to the inside of the tile's border, so the name plate doesn't
   paint over its corners. */
.build-tile-face {
  position: relative;
  display: flex;
  overflow: hidden;
  border-radius: var(--control-radius);
  pointer-events: none;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
}

/* A blocked tile fades as far as a disabled button, as a done one does
   (button:disabled), but remains clickable to show its details. */
.build-tile.blocked {
  opacity: var(--dim-opacity);
}

/* A done tile has no needs, so its glyph keeps its width, lining its name up
   with the rest, and stands two names tall: about half a tile with needs. */
.build-tile.done .build-tile-glyph {
  aspect-ratio: auto;
  height: calc(2 * var(--build-name-size) * var(--build-name-line));
}

.build-tile.done .build-tile-glyph .i {
  width: auto;
  height: 80%;
}

.screen-play .build-tile.ready .build-tile-glyph {
  color: var(--ok-text);
}

/* The tile a requirement's Go points at (build.point) rings twice in the
   accent, then fades. */
.build-tile.is-pointed {
  animation: build-tile-pointed 1.6s ease-out;
}

@keyframes build-tile-pointed {
  0%, 20% { box-shadow: 0 0 0 3px var(--accent); }
  35% { box-shadow: 0 0 0 3px transparent; }
  50%, 70% { box-shadow: 0 0 0 3px var(--accent); }
  100% { box-shadow: 0 0 0 3px transparent; }
}

/* Only a tile that can start lightens under the pointer. */
@media (hover: hover) {
  .build-tile.ready:hover {
    background: color-mix(in srgb, var(--skin-raised), var(--skin-text) 10%);
  }
}

.build-tile-glyph {
  display: grid;
  place-items: center;
  color: var(--text);
  background: transparent;
  width: var(--build-glyph-size);
  aspect-ratio: 1;
  flex: none;
}

.screen-play .build-tile-glyph .i {
  height: auto;
  aspect-ratio: 1;
  width: 70%;
}

/* Building details beside the glyph. */
.build-tile-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  min-width: 0;
  flex: 1;
  border: 0;
  padding: 0;
  background: transparent;
}

.build-tile-name {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
  white-space: normal;
  font-size: var(--build-name-size);
  line-height: var(--build-name-line);
}

/* A tile's needs, as the pills its detail sheet shows: requirements wide
   enough for a building's name and its Go, costs narrow, so pills of a
   kind line up down the list. They sit on the panel's colour, set into the
   raised tile. */
.build-tile-needs {
  align-self: stretch;
  margin: var(--build-needs-gap) 0 0;
}

.build-tile-need-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--build-needs-gap);
}

.build-tile-need-list > .formula-term {
  grid-template-columns: auto minmax(0, 1fr) auto;
  flex: none;
  width: 7.5rem;
  max-width: 100%;
}

.build-tile-need-list > .formula-term.is-require {
  width: 15rem;
}

/* Pills set into a raised box (a build tile, a call box) sit on the panel's colour. */
.term-inset > .formula-term {
  background: var(--surface-1);
}

.call-deadline {
  margin-bottom: 6px;
}

.build-tile-need-list :is(.formula-qty, .formula-name) {
  overflow: hidden;
  text-overflow: ellipsis;
}

@container build-tile (max-width: 440px) {
  .build-tile-face {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: 10px;
  }

  .build-tile-copy {
    display: contents;
  }

  .build-tile-glyph {
    --build-glyph-size: 56px;
  }

  .build-tile-desc,
  .build-tile-needs,
  .build-tile-sub {
    grid-column: 1 / -1;
  }
}

.build-tile-desc {
  max-width: 100%;
  color: var(--muted);
  font-weight: 500;
  font-size: var(--meta-text-size);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.build-tile-desc p {
  margin: 0;
}

.build-tile-sub {
  max-width: 100%;
  color: var(--muted);
  font-weight: 600;
  font-size: var(--caption-text-size);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* A machine's few recipes list as full-width rows. */
.build-grid.is-rows {
  grid-template-columns: minmax(0, 1fr);
}

/* A term is a raised tile, like a build tile or a sheet card, with its icon
   in a darker box set into the pill and filling its height: --term-icon
   colours the icon and --term-tone the odds rule. */
.formula-term {
  display: inline-grid;
  grid-template-columns: auto auto;
  align-items: center;
  column-gap: 8px;
  padding: 0 10px 0 0;
  border-radius: var(--control-radius);
  background: var(--surface-2);
}

.formula-icon {
  display: grid;
  place-items: center;
  align-self: stretch;
  width: var(--term-height);
  min-height: var(--term-height);
  border-radius: var(--control-radius);
  background: color-mix(in srgb, #000 22%, transparent);
  color: var(--term-icon, var(--text));
}

.formula-icon .i {
  width: 22px;
  height: 22px;
}

.formula-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.formula-qty {
  font-weight: 700;
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.formula-name {
  color: var(--muted);
  font-size: var(--caption-text-size);
  white-space: nowrap;
}

/* A term's tone (ui/term.js) colours its icon, one meaning each:
   met green, short amber (a soft lock), blocked red (a hard lock), gain
   blue. A term with none is plain. A rare or epic roll wears its tier's
   colours (the palette is-rare or is-epic sets). */
.formula-term.is-met {
  --term-tone: var(--ok);
  --term-icon: var(--ok-text);
}

.formula-term.is-short {
  --term-tone: var(--warn);
  --term-icon: var(--warn);
}

.formula-term.is-blocked {
  --term-tone: var(--danger);
  --term-icon: var(--danger);
}

.formula-term.is-gain {
  --term-tone: var(--info-deep);
  --term-icon: var(--info);
}

.formula-term:is(.is-rare, .is-epic) {
  --term-tone: var(--tier-mid);
  --term-icon: var(--tier-lit);
  background: color-mix(in srgb, var(--tier-fill) 75%, var(--surface-2));
}

/* An output a craft may not pay has its odds right-aligned in a cell of
   their own behind a dashed rule. */
.formula-odds {
  align-self: stretch;
  display: grid;
  align-content: center;
  justify-items: end;
  box-sizing: border-box;
  width: 3.6rem;
  margin: 0 -10px 0 0;
  padding: 0 10px 0 8px;
  border-left: 1.5px dashed color-mix(in srgb, var(--term-tone, var(--line)) 55%, transparent);
  font-weight: 700;
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* A requirement or short cost the player can work toward (paintRequires',
   paintCosts' goOf) ends in Go, in the pill's last column, inset from its
   right edge. It takes taps inside a build tile, whose face lets them
   through to the tile. */
.screen-play button.btn.compact.term-go {
  pointer-events: auto;
  min-width: var(--icon-control-size);
  margin: 6px 0;
  padding: 0 8px;
}

/* What a later level brings (Manage's seatLater): plain, both lines small. */
.formula-term.is-later .formula-qty {
  font-size: var(--caption-text-size);
}

/* A compact term (termPill's compact) is one small line, amount then name,
   for a chip row inside a card or a sheet: loot, rewards, a batch's haul. */
.formula-term.is-compact {
  --term-height: 24px;
  grid-template-columns: none;
  grid-auto-flow: column;
  column-gap: 6px;
  padding-right: 8px;
  font-size: var(--meta-text-size);
}

.formula-term.is-compact .formula-icon .i {
  width: 16px;
  height: 16px;
}

.formula-term.is-compact .formula-text {
  flex-direction: row;
  align-items: baseline;
  gap: 4px;
}

.formula-term.is-compact .formula-qty {
  font-size: inherit;
}

.formula-term.is-compact .formula-odds {
  width: auto;
  margin-right: -8px;
  padding: 0 8px 0 6px;
  font-size: inherit;
}

.panels {
  position: absolute;
  inset: 0;
  z-index: var(--z-panels);
  overflow: visible;
}

.panels.is-entering,
.panels.is-leaving {
  overflow: hidden;
}

/* The backdrop (ui/dismiss.js bindBackdrop) dims the game under a closable layer; a tap on it
   closes the topmost layer. */
.backdrop {
  position: fixed;
  inset: 0;
  left: var(--chat-inset);
  background: var(--dim);
  pointer-events: auto;
}

/* A find or a defeat sits in a pool of light: the game dims toward the edges, blurred where the
   graphics allow. */
.backdrop.is-spot {
  position: absolute;
  left: 0;
  background: radial-gradient(ellipse 60% 55% at 50% 50%, #0b121499 0%, #05090af0 100%);
}

html.dim-blur .backdrop.is-spot {
  backdrop-filter: blur(4px);
}

/* Under the bottom panels the backdrop fades and blurs in with them. */
.panels .backdrop {
  opacity: 0;
  transition:
    opacity calc(var(--panel-enter-ms) * 1ms) linear,
    backdrop-filter calc(var(--panel-enter-ms) * 1ms) ease-out;
}

.panels.is-open .backdrop {
  opacity: 1;
}

.panels.is-leaving .backdrop {
  opacity: 0;
  transition-duration: calc(var(--panel-leave-ms) * 1ms);
}

html.dim-blur:not(.aspect-portrait) .panels .backdrop {
  backdrop-filter: blur(0px);
}

html.dim-blur:not(.aspect-portrait) .panels.is-open .backdrop {
  backdrop-filter: blur(3px);
}

html.aspect-portrait .panels .backdrop {
  transition-property: opacity;
}

.bottom-panel,
.menu-box {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--panel-pad) 0;
  pointer-events: none;
  overflow: visible;
}

.aspect-portrait .bottom-panel,
.aspect-portrait .menu-box {
  padding: 0;
  --panel-pad: 0px; /* unitless 0 makes calc(100% + var(--panel-pad)) invalid */
}

.bottom-panel.panel-fill .panel {
  flex: 1 1 auto;
  min-height: 0;
}

.panel {
  pointer-events: auto;
  position: relative;
  width: var(--float-width);
  max-width: 100%;
  max-height: 100%;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: visible;
  transform: translate3d(0, calc(100% + var(--panel-pad) + var(--panel-exit-clearance, 0px)), 0);
  transition: transform calc(var(--panel-enter-ms) * 1ms) var(--panel-enter-ease);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panels.is-open .panel {
  transform: none;
}

.panels.is-leaving .panel {
  transform: translate3d(0, calc(100% + var(--panel-pad) + var(--panel-exit-clearance, 0px)), 0);
  transition-timing-function: var(--panel-leave-ease);
  transition-duration: calc(var(--panel-leave-ms) * 1ms);
}

.panels.is-entering .panel,
.panels.is-leaving .panel {
  pointer-events: none;
}

.panels.is-snap .backdrop,
.panels.is-snap .panel {
  transition-duration: 0s;
}

.aspect-portrait .panel {
  width: 100%;
  max-width: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 16px;
}

/* Its look is the close button's (.close-btn). */
.panel-close {
  position: relative;
  z-index: 2;
}

.panel-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
}

#build-panel .panel-body,
#manage-panel .panel-body {
  flex: 1 1 auto;
}

#alliance-view-panel .panel-body {
  overflow: visible;
}

#account-panel .panel-body {
  flex: 1 1 auto;
}

.account-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.account-stack[hidden] {
  display: none;
}

.account-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* Edit crest sits under the crest, on your own profile only. */
.account-crest-col {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.account-name {
  margin: 0;
  overflow-wrap: anywhere;
}

.account-about {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.account-about.is-empty {
  color: var(--muted);
}

.account-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
}

.account-form[hidden] {
  display: none;
}

.account-form textarea {
  resize: vertical;
}

.account-form-row,
.account-form-foot {
  display: flex;
  align-items: center;
  gap: 8px;
}

.account-form-row input {
  flex: 1;
  min-width: 0;
}

.account-count {
  margin-right: auto;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.account-count.is-over {
  color: var(--danger);
}

/* The account panel's tables (account.js, account_options.js): a row
   header, its value, and its action at the right edge. An edit opens its
   form in the value cell, or in a full-width row under it. */
.account-table td:nth-child(2) {
  width: 100%;
  overflow-wrap: anywhere;
}

.account-table td:nth-child(3),
.account-switch-table td:nth-child(3) {
  text-align: right;
  white-space: nowrap;
}

/* The address and its Needs-style verified mark, centred on one line. */
.account-email {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 12px;
  row-gap: 4px;
}

.account-login-row {
  display: flex;
  gap: 8px;
}

.account-login-row > :first-child {
  flex: 1;
}

.account-login-row > :last-child {
  flex: 2;
}

.account-switch {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.account-switch-table td:nth-child(2) {
  width: 100%;
  text-align: right;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.account-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.account-actions > * {
  flex: 1;
  min-width: 0;
}

.account-view-meta {
  margin: 0;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

/* Zero specificity: a classed button keeps its own skin. */
:where(.panel-body) button {
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
}

/* A name that opens its owner reads as gold text, not a button. */
button.account-name-link {
  background: none;
  border: 0;
  padding: 0;
  color: var(--accent);
  font: inherit;
  cursor: pointer;
  text-align: left;
}

button.account-name-link:hover,
button.account-name-link:focus-visible {
  text-decoration: underline;
}

/* A card in a panel list, in a building tile's look: a raised fill.
   News, notices, alliances, feed, armies, summons, reports, inventory tiles, settings sections.
   Each owner keeps its own layout. */
/* --row-card-pad-y and -x are its padding, for a part that runs to the card's edge. */
.row-card {
  --row-card-pad-y: 8px;
  --row-card-pad-x: 10px;
  padding: var(--row-card-pad-y) var(--row-card-pad-x);
  border: 0;
  border-radius: var(--panel-radius-inner);
  background: var(--surface-2);
  --reach-ground: var(--surface-2);
  color: var(--ink);
}

button.row-card {
  width: 100%;
  text-align: left;
}

.row-card.selected {
  background: var(--row-selected);
}

.row-card-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.row-card-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.row-card-title {
  flex: 1;
  min-width: 0;
}

.row-card-age {
  flex: none;
  margin-left: auto;
  color: var(--muted);
  font-size: var(--meta-text-size);
  white-space: nowrap;
}

.row-card-sub {
  color: var(--muted);
  font-size: var(--meta-text-size);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-body-col {
  flex: 1;
  min-height: 0;
}

.news-article {
  flex: 1 1 auto;
  min-height: 0;
  background: var(--bg);
  color: var(--ink);
  border-radius: var(--panel-radius-inner);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.news-article h3 {
  margin: 0;
  color: var(--accent);
  font-size: 1.15rem;
  font-weight: 700;
}

.news-summary {
  color: var(--muted);
  font-size: var(--meta-text-size);
  overflow-wrap: anywhere;
}

.markdown {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.45;
}

.markdown h1,
.markdown h2,
.markdown h3 {
  margin: 0.4em 0 0.2em;
  color: var(--ink);
  font-weight: 700;
}

.markdown h1 {
  font-size: var(--card-title-size);
  color: var(--accent);
}

.markdown h2 {
  font-size: 20px;
}

.markdown h3 {
  font-size: 18px;
}

.markdown p,
.markdown ul,
.markdown ol,
.markdown blockquote {
  margin: 0 0 0.6em;
}

.markdown ul,
.markdown ol {
  padding-left: 1.4em;
}

.markdown blockquote {
  padding-left: 12px;
  border-left: 3px solid var(--accent);
  font-style: italic;
}

.markdown code {
  font-family: ui-monospace, monospace;
  font-size: 0.9em;
}

.markdown a {
  color: var(--accent);
}

.news-inline-article {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.news-list-scroll {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  flex: 1;
}

.news-article,
.news-list-scroll {
  scrollbar-width: thin;
  scrollbar-color: var(--scroll) transparent;
}

.news-article::-webkit-scrollbar,
.news-list-scroll::-webkit-scrollbar {
  width: 8px;
}

.news-article::-webkit-scrollbar-track,
.news-list-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.news-article::-webkit-scrollbar-thumb,
.news-list-scroll::-webkit-scrollbar-thumb {
  background: var(--scroll);
  background-clip: padding-box;
  border: 2px solid transparent;
  border-radius: 999px;
}

.news-article::-webkit-scrollbar-thumb:hover,
.news-list-scroll::-webkit-scrollbar-thumb:hover {
  background-color: var(--scroll-hover);
}

.news-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: var(--badge-hang);
  padding-right: 8px;
}

/* The Field Manual's list (panels/field_manual.js): section headings over their entry rows, in
   the pane's own scroll. */
.manual-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.title-mark {
  width: 10px;
  height: 10px;
  margin-top: 7px;
  flex: 0 0 10px;
  border-radius: 8px;
  background: var(--unread-mark);
}

#alliance-panel .panel-body {
  flex: 1 1 auto;
  overflow: auto;
}

.alliance-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
}

#alliance-out {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#alliance-create-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

#alliance-create-wrap[hidden] {
  display: none;
}

.alliance-create {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.alliance-create[hidden] {
  display: none;
}

.alliance-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.alliance-actions-end {
  justify-content: flex-end;
}

.alliance-actions .btn {
  flex: 0 0 auto;
  width: auto;
}

.alliance-browse {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.alliance-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.alliance-row-title {
  font-weight: 600;
}

.alliance-row-sub,
.alliance-names {
  color: var(--muted);
  font-size: var(--meta-text-size);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.alliance-member-who {
  display: flex;
  align-items: center;
  gap: 10px;
}

.alliance-member-table .alliance-member-role,
.alliance-member-table .alliance-member-tools {
  width: 1%;
  white-space: nowrap;
}

.alliance-member-table td.alliance-member-role {
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.alliance-member-table .alliance-member-tools {
  text-align: right;
}

.alliance-member-table select {
  padding: 4px 8px;
}

.alliance-summary {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.alliance-summary-name {
  margin: 0;
  overflow-wrap: anywhere;
}

/* An alliance's own words: a well, signed by its leader. */
.alliance-quote {
  margin: 0;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--surface-well);
  border-radius: var(--panel-radius-inner);
}

.alliance-quote-text {
  margin: 0;
  font-style: italic;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.alliance-quote-by {
  color: var(--muted);
  font-size: var(--meta-text-size);
  text-align: right;
}

.alliance-view-actions {
  margin-top: auto;
}

.alliance-view-actions .btn.positive {
  margin-left: auto;
}

#alliance-in {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.panel-tabs {
  display: flex;
  gap: 6px;
  flex: 0 0 auto;
  min-width: 0;
  padding: 0;
  overflow: visible;
}

.panel-tabs[hidden] {
  display: none;
}

.panel-tab {
  position: relative;
  overflow: visible;
  flex: 1;
  min-width: 0;
}

.panel-tab[hidden] {
  display: none;
}

.panel-pane {
  flex: 1;
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.panel-pane[hidden] {
  display: none;
}

.alliance-edit {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.alliance-edit[hidden] {
  display: none;
}

#alliance-notices-view {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#alliance-notices-view[hidden] {
  display: none;
}

#alliance-notice-create-open {
  align-self: flex-start;
  width: auto;
}

.alliance-notice-article {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  background: var(--bg);
  color: var(--ink);
  border-radius: var(--panel-radius-inner);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 16px 16px 44px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.alliance-notice-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

#alliance-notice-headline {
  margin: 0;
  flex: 1;
  min-width: 0;
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 700;
}

.alliance-notice-head .row-card-age {
  font-size: var(--caption-text-size);
}

#alliance-notice-delete {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  padding: 0;
  background: transparent;
  color: var(--ink);
  border: 0;
  font-size: 18px;
  line-height: 1;
}

.alliance-notice-list-scroll {
  height: auto;
  max-height: none;
  overflow-y: auto;
  overscroll-behavior: contain;
  flex: 0 1 auto;
}

.alliance-notice-article,
.alliance-notice-list-scroll {
  scrollbar-width: thin;
  scrollbar-color: var(--scroll) transparent;
}

.alliance-notice-article::-webkit-scrollbar,
.alliance-notice-list-scroll::-webkit-scrollbar {
  width: 8px;
}

.alliance-notice-article::-webkit-scrollbar-track,
.alliance-notice-list-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.alliance-notice-article::-webkit-scrollbar-thumb,
.alliance-notice-list-scroll::-webkit-scrollbar-thumb {
  background: var(--scroll);
  background-clip: padding-box;
  border: 2px solid transparent;
  border-radius: 999px;
}

.alliance-notice-article::-webkit-scrollbar-thumb:hover,
.alliance-notice-list-scroll::-webkit-scrollbar-thumb:hover {
  background-color: var(--scroll-hover);
}

.alliance-notice-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-right: 8px;
}

#alliance-notice-form.alliance-notice-compose {
  flex: 1 1 auto;
  min-height: 0;
}

#alliance-notice-form.alliance-notice-compose label {
  flex: 1 1 auto;
  min-height: 0;
}

#alliance-notice-body {
  flex: 1 1 auto;
  min-height: 12em;
}

#alliance-panel.alliance-notices-read .panel,
#alliance-panel.alliance-notices-read .alliance-body,
#alliance-panel.alliance-notices-read #alliance-in,
#alliance-panel.alliance-notices-read #alliance-tab-notices,
#alliance-panel.alliance-notices-read #alliance-notices-view,
#alliance-panel.alliance-notices-read .alliance-notice-article {
  flex: 0 1 auto;
}

#alliance-panel.alliance-notices-read .panel-body {
  overflow: hidden;
}

#alliance-panel.alliance-notices-read #alliance-tab-notices {
  overflow: hidden;
}

#alliance-panel.alliance-notices-read .alliance-notice-list-scroll {
  height: 220px;
  max-height: 220px;
  flex: 0 0 220px;
}

#alliance-panel.alliance-notices-compose .panel,
#alliance-panel.alliance-notices-compose .alliance-body,
#alliance-panel.alliance-notices-compose #alliance-in,
#alliance-panel.alliance-notices-compose #alliance-tab-notices,
#alliance-panel.alliance-notices-compose #alliance-notice-form {
  flex: 1 1 auto;
}

#alliance-panel.alliance-notices-compose .panel-body {
  overflow: hidden;
}

#alliance-panel.alliance-notices-compose #alliance-tab-notices {
  overflow: hidden;
}

.alliance-member {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.alliance-feed {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.alliance-matrix-table td,
.alliance-matrix-table thead th:not(:first-child) {
  text-align: center;
}

.alliance-matrix-cell {
  position: relative;
  display: inline-flex;
  vertical-align: middle;
}

.screen-play .alliance-matrix-cell .i {
  position: absolute;
  top: 50%;
  left: calc(100% + 6px);
  width: 14px;
  height: 14px;
  color: var(--muted);
  filter: none;
  transform: translateY(-50%);
}

html.aspect-portrait,
html.aspect-portrait body {
  font-size: 14px;
}

.aspect-portrait .top-bar {
  padding: 4px 8px 6px;
}

.aspect-portrait .chips {
  width: 100%;
  gap: 4px;
}

.aspect-portrait .chip {
  min-width: 0;
  max-width: none;
  gap: 1px;
}

.aspect-portrait .chip .chip-name {
  font-size: 11px;
}

.aspect-portrait .chip .chip-well,
.aspect-portrait .chip .chip-qty {
  height: 22px;
  font-size: 11px;
}

.aspect-portrait .chip .chip-qty {
  padding-left: 4px;
}

.aspect-portrait .play-top-hud {
  left: 8px;
}

.aspect-portrait .debug-chip {
  padding: 4px 8px;
  font-size: 11px;
}

.aspect-portrait .debug-panel {
  width: 168px;
  padding: 8px 10px;
  font-size: 11px;
}

.aspect-portrait .dialogue-bust {
  --dialogue-bust-size: 128px;
}

.dialogue-bust.is-robot {
  --dialogue-bust-size: 88px;
}

.aspect-portrait .debug-btn {
  font-size: 16px;
}

.aspect-portrait .morale-chip {
  font-size: 16px;
}

.aspect-portrait .city-play-btns {
  left: var(--menu-inset);
}

/* Edit and Build step aside while a dialogue plays, so its strip has the full width. */
.play-middle:has(> #dialogue:not([hidden])) > .city-play-btns {
  display: none;
}

.screen-designer {
  min-height: 100%;
  height: 100dvh;
  pointer-events: none;
  background: transparent;
}

.screen-designer .panels {
  pointer-events: none;
}

.screen-designer .panel {
  pointer-events: auto;
}

button.secondary {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
}

.royal-slot {
  position: relative;
  width: 180px;
  height: 260px;
  overflow: hidden;
  cursor: pointer;
  flex: 0 0 auto;
  background: #f6f1e5;
}

.royal-plate {
  position: absolute;
  top: 0;
  left: 0;
  image-rendering: pixelated;
  pointer-events: none;
}

.designer-tabs {
  display: flex;
  align-items: flex-end;
  flex: 0 0 auto;
  width: var(--float-width);
  max-width: 100%;
  height: var(--panel-tab-selected-height);
  margin: 0 auto;
  pointer-events: auto;
}

.aspect-portrait .designer-tabs {
  width: 100%;
}

.designer-editors {
  display: grid;
  flex: 0 1 auto;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.designer-pane {
  grid-area: 1 / 1;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  overflow: hidden;
}

.designer-pane.is-off {
  visibility: hidden;
  pointer-events: none;
}

.designer-actions {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 8px;
  flex: 0 0 auto;
  padding-top: 8px;
}

.designer-actions button {
  width: 100%;
}

.screen-designer .designer-step {
  transition: transform 500ms ease-in;
}

.screen-designer .designer-step.is-out {
  transform: translate3d(0, calc(100% + var(--panel-pad)), 0);
}

.screen-designer .designer-step.is-in {
  transform: none;
  transition-duration: 300ms;
  transition-timing-function: ease-out;
}

.designer-lead-picks {
  margin: 8px 0 4px;
}

.designer-lead-picks .btn {
  flex: 1 1 0;
  height: calc(2 * var(--control-height));
}

.designer-names-form {
  --name-pad: 8px 10px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 12px;
  align-items: center;
  margin: 8px 0 0;
}

.designer-names-form label {
  font-size: inherit;
  font-weight: 500;
  white-space: nowrap;
}

.designer-names-form input {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: var(--name-pad);
}

/* The family name follows each given name, dimmed: an overlay that repeats the
   typed name invisibly, then the family name, at the input's padding. */
.designer-name-field {
  position: relative;
  min-width: 0;
}

.designer-name-surname {
  position: absolute;
  inset: 0;
  box-sizing: border-box;
  border: 1px solid transparent;
  padding: var(--name-pad);
  overflow: hidden;
  white-space: pre;
  pointer-events: none;
  font-family: var(--font-body);
  /* The input's own size: every field is 16px (input, textarea above). */
  font-size: 16px;
  color: var(--text-dim);
}

.designer-name-ghost {
  visibility: hidden;
}

.designer-controls {
  --designer-check: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  margin: 12px auto 0;
}

.designer-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
}

.child-sex {
  display: flex;
  gap: 8px;
  flex: 0 0 auto;
}

.child-sex .btn {
  flex: 0 0 auto;
  min-height: var(--designer-check);
  box-sizing: border-box;
}

.designer-random {
  flex: none;
  margin-left: auto;
}

.child-inherit {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.child-inherit-label {
  width: 9.5rem;
}

.child-inherit-pick {
  width: calc((100% - 9.5rem) / 5);
}

.child-inherit th,
.child-inherit td {
  padding: 6px 2px;
  text-align: center;
  vertical-align: middle;
}

.child-inherit thead th {
  font-weight: 500;
}

.child-inherit thead th:first-child,
.child-inherit .child-inherit-who {
  text-align: left;
  font-weight: 500;
  white-space: nowrap;
}

input:where([type="checkbox"]) {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  place-items: center;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin: 0;
  padding: 0;
  border: 1px solid var(--accent);
  border-radius: 3px;
  background: var(--bg);
  vertical-align: middle;
  cursor: pointer;
}

input:where([type="checkbox"]:checked) {
  background: var(--accent);
}

input:where([type="checkbox"]:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

input:where([type="checkbox"]:disabled) {
  cursor: not-allowed;
}

input:where([type="checkbox"])::after {
  content: "";
  width: 5px;
  height: 9px;
  margin-top: -2px;
  border: solid var(--on-accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
}

input:where([type="checkbox"]:checked)::after {
  transform: rotate(45deg) scale(1);
}

.child-inherit input[type="checkbox"] {
  width: var(--designer-check);
  height: var(--designer-check);
  margin: 0 auto;
}

.child-inherit input[type="checkbox"]::after {
  width: 9px;
  height: 16px;
  margin-top: -3px;
  border-width: 0 3px 3px 0;
}

.trait-col {
  width: 100%;
  max-width: 100%;
  flex: 0 1 auto;
  overflow-x: hidden;
  overflow-y: visible;
}

.trait-table {
  --trait-control-h: 32px;
  width: 100%;
  max-width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

.trait-table th {
  text-align: left;
  font-weight: 500;
  white-space: nowrap;
  width: 4.5rem;
  padding: 5px 12px 5px 0;
  vertical-align: middle;
}

.trait-table td {
  padding: 5px 0;
  vertical-align: middle;
}

.trait-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: stretch;
}

.trait-table tr:has(.trait-stack) th {
  vertical-align: top;
}

.trait-swatches {
  display: flex;
  flex-wrap: nowrap;
  gap: 4px;
  align-items: stretch;
  height: var(--trait-control-h);
}

.trait-swatches-fill {
  width: 100%;
}

.trait-swatch,
.panel-body .trait-swatch {
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  height: var(--trait-control-h);
  margin: 0;
  padding: 0;
  border: 1px solid color-mix(in srgb, #000 22%, var(--swatch, var(--line)));
  border-radius: var(--control-radius);
  background: var(--swatch, var(--bg));
  color: inherit;
  display: grid;
  place-content: center;
  cursor: pointer;
}

.trait-swatches-fill .trait-swatch,
.panel-body .trait-swatches-fill .trait-swatch {
  flex: 1 1 0;
  min-width: 0;
  width: auto;
}

.trait-swatch:checked::after,
.panel-body .trait-swatch:checked::after {
  content: "✓";
  font-size: calc(var(--trait-control-h) * 0.62);
  font-weight: 700;
  line-height: 1;
  color: #fff;
  text-shadow: 0 1px 2px #000;
  border: 0;
  transform: none;
  width: auto;
  height: auto;
  margin: 0;
}

.trait-swatch:checked,
.panel-body .trait-swatch:checked {
  border-color: var(--selected-line);
  box-shadow: inset 0 0 0 2px var(--selected-line);
}

.trait-picks {
  display: flex;
  gap: 6px;
  width: 100%;
}

.trait-picks .trait-pick {
  flex: 1;
  min-width: 0;
  padding: 6px 8px;
}

.trait-table input,
.trait-table select {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.trait-table select {
  height: var(--trait-control-h);
  padding: 0 8px;
}

#armies-panel .panel-body,
#family-panel .panel-body,
#inventory-panel .panel-body,
#morale-panel .panel-body,
#provoke-panel .panel-body,
#summon-panel .panel-body {
  flex: 1 1 auto;
  min-height: 0;
}

#armies-panel .panel-body,
#family-panel .panel-body,
#inventory-panel .panel-body,
#morale-panel .panel-body,
#summon-panel .panel-body {
  overflow: auto;
  overscroll-behavior: contain;
}

#morale-title {
  margin: 0;
}

#account-panel .panel-pane {
  overscroll-behavior: contain;
}

/* A settings pane's controls, and the help below them, stand on the panel
   itself, no card around them. */
.settings-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.settings-card {
  padding: 0;
}

.settings-report {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.report-form,
.report-compose {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.report-form h3 {
  margin: 0;
}

.report-note {
  margin: 0;
  color: var(--muted);
  font-size: var(--caption-text-size);
}

/* The dev's message on a gift, in italic under the report's line. */
.report-message {
  margin: 0;
  font-style: italic;
}

.report-board {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Logbook rows anchor the badge for an unread item or waiting Action. */
.report-row,
.news-list > .row-card {
  position: relative;
}

/* Every Reports row is one frame: what happened's icon, the body, and the clock time top right. */
.report-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  column-gap: 10px;
  align-items: start;
}

.report-lead {
  display: flex;
  width: 22px;
  height: 22px;
}

.report-lead .i {
  width: 100%;
  height: 100%;
}

.report-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  line-height: 1.4;
}

.report-corner {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--caption-text-size);
  line-height: 1.4;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* What a report gained, lost, or missed (report_nodes.js itemNode), as term tiles set into the
   card (term-inset), in the term's tones. */
.report-items {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.report-items:empty {
  display: none;
}

/* A battle report's result word, in its tone: green won, red lost (report_nodes.js lineNode). */
.report-result {
  font-weight: 700;
  letter-spacing: 0.04em;
}

.report-result[data-tone="ok"] {
  color: var(--ok);
}

.report-result[data-tone="alert"] {
  color: var(--alert);
}

/* A report row's action: Replay on a battle's, View on a ticket's, Find a new location and
   Dismiss side by side in a bare stand's Action (report_nodes.js). */
.report-action {
  align-self: flex-start;
}

.report-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* A ticket status's colour, read by the tracker board's status chips (tracker/board.js). */
.tracker-status-accepted {
  --status: #3d8bd9;
}

.tracker-status-in_progress {
  --status: var(--warn);
}

.tracker-status-pending_release {
  --status: #3fae5a;
}

.tracker-status-released {
  --status: #1fa58f;
}

.tracker-status-closed {
  --status: var(--btn-negative);
}

/* Filter chips (Logbook reports, alliance list): a row of small toggles; a pressed one wears the selected gold
   from the shared selected rule by the menu bar. The top padding leaves a chip's corner badge room to
   hang inside the scrolling pane. */
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: var(--badge-hang);
}

.filter-chips[hidden] {
  display: none;
}

.filter-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: var(--control-height);
  padding: 0 12px;
  border-radius: var(--control-radius);
  border: 1px solid var(--play-line-strong);
  background: transparent;
  color: var(--text);
  font-size: 0.85rem;
}

.filter-chip .i {
  width: 16px;
  height: 16px;
}

.list-heading {
  margin: 6px 0 0;
}


.report-sent {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.report-sent p {
  margin: 0;
}

.report-actions {
  display: flex;
  justify-content: flex-end;
}

/* The files a report will carry, under the button that adds them, each with its remove. */
.report-attach {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.report-files {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* One chosen file: its thumbnail over its name, the remove on the thumbnail's corner. */
.report-file {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 112px;
  font-size: var(--meta-text-size);
}

.report-file-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--play-line);
  border-radius: 8px;
  background: var(--surface-1);
}

.report-file-name {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.report-file > .close-btn {
  position: absolute;
  top: 4px;
  right: 4px;
}

.settings-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 6px 14px;
  border-bottom: 1px solid var(--line);
}

#settings-audio-reset {
  margin-left: auto;
  flex: 0 0 auto;
  padding: 4px 10px;
  font-size: 12px;
}

.settings-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 16px 14px;
}

.settings-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
}

.settings-title {
  font-size: 0.9rem;
}

.settings-row .settings-title {
  flex: 1 1 8rem;
  min-width: 8rem;
}

.settings-fps-readout {
  color: var(--muted);
  font-size: var(--caption-text-size);
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.settings-check-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(40px, auto));
  grid-auto-flow: column;
  gap: 8px 10px;
  margin-top: 4px;
}

.settings-check-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.settings-check {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: color-mix(in srgb, var(--panel) 55%, var(--bg));
  font-size: 0.9rem;
  cursor: pointer;
}

.settings-check:has(input:checked) {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: color-mix(in srgb, var(--accent) 8%, var(--bg));
}

.settings-check:has(input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.settings-check:has(input:disabled) {
  cursor: not-allowed;
}

.settings-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.settings-langs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.settings-language-note {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

#settings-langs button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: var(--control-height);
  padding: 0 12px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--panel) 55%, var(--bg));
}

#settings-langs button::after {
  content: "✓";
  font-weight: 700;
  visibility: hidden;
}

#settings-langs button[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}

#settings-langs button[aria-pressed="true"]::after {
  visibility: visible;
}

#settings-langs button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.settings-dead {
  opacity: 0.45;
}

.settings-janky {
  color: #8b5a2b;
}

.settings-sexy,
.settings-maxed {
  color: #b44cff;
}

.settings-muted {
  color: #e05050;
}

.inv-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.inv-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* The Goods and Troops tabs' tiles (inventory_tile.js): each its icon beside its name over its
   amount, as many to a row as fit, with a thin bar of segments under them. Goods come in a
   section per kind of good. */
.screen-play .inv-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.screen-play .inv-section-title {
  margin: 0;
}

/* A section's title, as the Build sheet heads its sections: inventory sections, and a list's
   headings (Reports' days, the Field Manual's groups, alliance invites). */
.screen-play :is(.inv-section-title, .list-heading) {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--muted);
  font-size: 22px;
  text-transform: uppercase;
}

/* A section inside another (Troops' Infantry, Vehicles, Aircraft): a smaller title, set apart
   from what comes before it. */
.screen-play .inv-subsection-title {
  margin: 8px 0 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  color: var(--muted);
  text-transform: uppercase;
}

/* Troop space (inventory_troops.js): its line and legend over its bar, across the Units section. */
.screen-play .troop-space {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.screen-play .inv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
}

/* Fixture names share their row with an Installed badge. */
.screen-play .workshop-fixture-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
}

.screen-play .inv-tile {
  display: grid;
  grid-template-columns: var(--good-icon-size) minmax(0, 1fr);
  align-items: center;
  gap: 2px 8px;
  color: var(--gold-200);
}

.screen-play .inv-tile > .i {
  grid-row: 1 / span 2;
  width: var(--good-icon-size);
  height: var(--good-icon-size);
}

.screen-play .inv-tile-name {
  color: #d1dfeb;
  font-size: 14px;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.screen-play .inv-tile-amount {
  grid-column: 2;
  color: var(--text);
  font-weight: 600;
  font-size: 18px;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* A good the bag has none of shows dimmed as a disabled troop tile does, its name alone beside
   its icon. A tile out of reach (a fixture above its building's level) dims the same. */
.screen-play .inv-tile.is-empty,
.screen-play .inv-tile.is-dim {
  opacity: var(--dim-opacity);
}

/* A toned tile (inventory_tile.js fillTile) wears its tone on its icon and badge.
   ok is one that can go to work now (a spare fixture that fits, a blueprint that makes a
   grade), info a fixture installed, muted one offered from another building. */
.screen-play .inv-tile[data-tone] {
  color: var(--tile-icon);
}

.screen-play .inv-tile[data-tone="ok"] {
  --tile-tone: var(--ok);
  --tile-icon: var(--ok-text);
}

.screen-play .inv-tile[data-tone="info"] {
  --tile-tone: var(--info-deep);
  --tile-icon: var(--info);
}

.screen-play .inv-tile[data-tone="muted"] {
  --tile-tone: var(--muted);
  --tile-icon: var(--muted);
}

/* A tile's badge is a tag in its tone at the right of its first line, in a column of its own
   so the name ellipsizes before it. */
.screen-play .inv-tile:has(> .inv-tile-badge) {
  grid-template-columns: var(--good-icon-size) minmax(0, 1fr) auto;
}

.screen-play .inv-tile-badge {
  grid-column: 3;
  grid-row: 1;
  padding: 2px 6px;
  border-radius: var(--control-radius);
  background: var(--tile-tone, var(--accent));
  color: var(--surface-1);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* A tile led by its name (no amount) ellipsizes it, its caption beside the picture under it. */
.screen-play .inv-tile-headline {
  overflow: hidden;
  text-overflow: ellipsis;
}

.screen-play .inv-tile-headline ~ .inv-tile-caption {
  grid-column: 2 / -1;
}

.screen-play .inv-tile.is-empty > .inv-tile-name {
  grid-row: 1 / span 2;
}

.screen-play .inv-tile-flag {
  font-weight: 500;
  font-size: 12px;
  color: var(--gold-200);
}

.inv-bar {
  grid-column: 1 / -1;
  position: relative;
  height: 4px;
  margin-top: 2px;
  border-radius: 2px;
  background: #0b1519;
  box-shadow: inset 0 1px 1px #0008;
  overflow: hidden;
}

.inv-bar-fill {
  position: absolute;
  top: 0;
  bottom: 0;
  background: linear-gradient(to bottom, #c9a35a, #8a7240);
}

/* A Units tab bar of where troops stand: thick enough to read its shares. */
.troop-bar {
  height: var(--troop-bar-height);
  border-radius: calc(var(--troop-bar-height) / 2);
}

.troop-deployed {
  background: var(--troop-deployed);
}

.troop-reserve {
  background: var(--troop-reserve);
}

.troop-damaged {
  background: var(--troop-damaged);
}

/* The legend under troop space, wrapping as a row, and under a troop tile's bar, a line
   per place with its count at the end (troop-legend-stack). */
.screen-play .troop-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 12px;
  color: #d1dfeb;
  font-size: var(--caption-text-size);
}

.screen-play .troop-legend-stack {
  grid-column: 1 / -1;
  flex-direction: column;
  margin-top: 2px;
}

.screen-play .troop-key {
  display: flex;
  align-items: center;
  gap: 6px;
}

.screen-play .troop-key-count {
  margin-left: auto;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.screen-play .troop-dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.screen-play .inv-tile-caption {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Each blueprint owns a full row, its distinct fragments under its name. */
.workshop-blueprint {
  display: grid;
  grid-template-columns: var(--good-icon-size) minmax(0, 1fr) max-content;
  align-items: center;
  gap: 6px 8px;
  color: var(--gold-200);
  text-align: left;
}

.workshop-blueprint > .i {
  grid-row: 1 / span 2;
  width: var(--good-icon-size);
  height: var(--good-icon-size);
}

.workshop-blueprint-count {
  grid-column: 3;
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.workshop-blueprint-progress {
  --meter-fill: linear-gradient(var(--info), var(--info-deep));
  grid-column: 2 / -1;
  min-width: 0;
}

/* A blueprint's page on the Workshop (workshop.js): a cell per fragment, its letter over a check
   when held or a cross when missing, then a chip per grade with the fragments that open it,
   lit once open and outlined while picked; the picked grade's shape and a warning when it has
   nowhere to go. */
.screen-play :is(.bp-letters, .bp-grades) {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.screen-play .bp-letter {
  display: grid;
  justify-items: center;
  min-width: 52px;
  padding: 6px 4px;
  border: var(--panel-border-width) solid var(--danger);
  border-radius: var(--control-radius);
  background: var(--surface-well);
  color: var(--danger);
  font-variant-numeric: tabular-nums;
}

.screen-play .bp-letter.is-held {
  border-color: var(--ok);
  color: var(--ok-text);
}

.screen-play .bp-letter-name {
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  font-weight: 700;
  line-height: 1;
  color: var(--text);
}

.screen-play .bp-letter-mark {
  font-size: var(--meta-text-size);
  font-weight: 900;
}

.screen-play .bp-letter-count {
  color: var(--muted);
  font-size: var(--caption-text-size);
}

.screen-play .bp-grade {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 4px 10px;
  border: var(--panel-border);
  border-radius: var(--control-radius);
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: var(--meta-text-size);
  cursor: pointer;
}

.screen-play .bp-grade.is-open {
  border-color: var(--ok);
  background: var(--ok-bg);
  color: var(--ok-text);
}

.screen-play .bp-grade.is-picked {
  box-shadow: inset 0 0 0 2px var(--selected-line);
}

.screen-play .bp-grade-name {
  font-weight: 700;
}

.screen-play .bp-shape {
  --fp-glyph-size: 56px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--meta-text-size);
}

.screen-play .bp-shape-size {
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  font-weight: 700;
}

.screen-play .bp-warn {
  margin: 0;
  color: var(--warn);
  font-size: var(--meta-text-size);
}

/* The Troops tab's Clankers box (clanker_box.js): a small clanker per clanker under what it is
   doing. */
.screen-play .clk-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* A label and its count on the Troops tab: a clanker group's (Crafting 4) and troop space's. */
.screen-play :is(.clk-group-title, .troop-space-line) {
  display: flex;
  gap: 6px;
  color: #d1dfeb;
  font-size: 13px;
}

.screen-play :is(.clk-group-count, .troop-space-count) {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.screen-play .clk-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
}

.screen-play .clk-icon {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--gold-200);
}

.screen-play .clk-icon > .i {
  width: 20px;
  height: 20px;
}

.screen-play button.clk-icon {
  cursor: pointer;
}

/* A clanker still walking over to its work shows faded. */
.screen-play .clk-icon.is-coming {
  opacity: 0.5;
}

.screen-play button.clk-icon:hover {
  color: var(--text);
}

/* The inventory's stock bars, and a battalion's troops (.troop-fill, on the army card and the
   battalion bar): a recessed rounded well with a hairline
   edge, and a fill lit from above. The gradient layers over each fill's own colour, so work and
   stalled segments keep theirs. */
.screen-play .inv-list .chip-well,
.screen-play .troop-fill.chip-well {
  height: 30px;
  border: 1px solid color-mix(in srgb, var(--gold-400) 22%, transparent);
  border-radius: 6px;
  background: linear-gradient(to bottom, #0f1a20, var(--chip-well));
  box-shadow: inset 0 1px 3px #0009;
  overflow: hidden;
}

.screen-play .inv-list .chip-fill,
.screen-play .troop-fill .chip-fill {
  background-image: linear-gradient(to bottom, #ffffff2e, #ffffff00 55%, #0000001f);
  box-shadow: inset -1px 0 0 color-mix(in srgb, var(--gold-200) 35%, transparent);
}

.screen-play .inv-list .chip-qty,
.screen-play .troop-fill .chip-qty {
  height: 30px;
  padding-left: 10px;
  text-shadow: 0 1px 2px #000c;
}

/* Text over a green fill reads in --ok-ink. A well whose fill is green says so with .fill-ok,
   set by its owner. The label spans the whole well, so its ink splits at the fill's edge (--fill,
   set by fillWell): dark over the green, the light ink past it over the empty track. A fill of any
   other colour keeps the light ink and its shadow. */
.screen-play .chip-well.fill-ok .chip-qty {
  color: transparent;
  text-shadow: none;
  background: linear-gradient(to right, var(--ok-ink) var(--fill), var(--text) var(--fill));
  -webkit-background-clip: text;
  background-clip: text;
}

.family-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.aspect-portrait .royal-slot {
  width: min(180px, 28vw);
  height: calc(min(180px, 28vw) * 260 / 180);
}

.morale-scale {
  margin: 0 0 12px;
}

.morale-scale-track {
  position: relative;
  display: flex;
  gap: 2px;
  min-height: 47px;
  padding-top: 8px;
  overflow: visible;
}

.morale-seg {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 2px;
  font-size: 18px;
  line-height: 1;
  background: var(--chip-well);
  color: var(--ink);
  border: 1px solid var(--line);
  overflow: visible;
}

.morale-seg.is-current {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
}

.morale-caret {
  position: absolute;
  top: -6px;
  z-index: 1;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 12px solid var(--ink);
  transform: translateX(-50%);
  pointer-events: none;
}

.armies-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.army-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.army-card.is-leaderless {
  border-color: var(--danger);
}

/* An army place not yet taken: a card to start one from. */
.army-card.is-empty {
  border-style: dashed;
}

/* The card's title runs along its top: arrows, name and Leadership, and at
   its end Disband or, away from home, where the army is. */
.army-head {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

/* Under the portraits: Fill, and at the right what can be done about the
   army there; under them a march's bar. */
.army-foot {
  display: flex;
  align-items: center;
  gap: 8px;
}

.screen-play .icon-btn.army-move {
  flex: none;
  font-size: 11px;
}

.army-cta {
  flex: none;
  margin-left: auto;
  display: flex;
  align-items: stretch;
  gap: 6px;
}

.army-march .chip-fill {
  background-color: var(--ok);
}

.army-disband,
.army-where {
  flex: none;
  margin-left: auto;
}

.army-where {
  color: var(--muted);
  font-size: var(--caption-text-size);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.screen-play button.btn.compact.army-go {
  flex: none;
  min-width: var(--icon-control-size);
  min-height: var(--icon-control-size);
  padding: 0 8px;
}

.screen-play button.btn.compact.army-deploy,
.screen-play button.btn.compact.army-send,
.army-standing {
  flex: none;
}

.army-standing,
.army-repair-count {
  align-self: center;
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-weight: 600;
}

/* Repair terms and their action share a row. A repairing army dims its
   roster under the countdown. */
.army-repair {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  min-width: 0;
}

.repair-cost {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  max-width: 100%;
}

.repair-terms {
  display: contents;
}

.repair-cost .formula-term {
  flex: none;
  max-width: min(16rem, 100%);
}

.army-repair-btn {
  align-self: stretch;
}

.army-card.is-repairing .army-roster {
  opacity: var(--dim-opacity);
}

.summon-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.summon-head {
  margin: 0;
  font-weight: 600;
}

.summon-army {
  display: flex;
  align-items: center;
  gap: 10px;
}

.summon-army.is-away {
  opacity: 0.45;
}

.summon-army .tray-pic {
  flex: none;
}

.summon-army-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.summon-army-units {
  font-size: 13px;
  overflow-wrap: anywhere;
}

/* The battle dock: battle chrome along the bottom of the field, the pick's
   order line (battle/order_line.js) and, while an army is being placed,
   the deploy line (battle/deploy.js). Taps pass through it to the field
   except on the deploy line. */
.battle-dock {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 12px;
  z-index: var(--z-chrome);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}

.screen-play.map-open .battle-dock {
  display: none;
}

/* The pick's order: a status line. */
.battle-order {
  max-width: 100%;
  margin: 0;
  padding: 6px 12px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-panel);
  box-shadow: var(--shadow-sheet);
  color: var(--text);
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
}

/* The deploy line (battle/deploy.js): while an army is being placed, what
   to tap and Cancel. */
.deploy-pick {
  order: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 100%;
  padding: 6px 8px 6px 14px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-panel);
  box-shadow: var(--shadow-sheet);
  color: var(--text);
  font-family: var(--font-ui);
  pointer-events: auto;
}

.deploy-pick[hidden] {
  display: none;
}

.deploy-pick-hint {
  margin: 0;
  font-weight: 600;
  font-size: 16px;
}

/* The attack line (attack_line.js): down the left edge of the raiders'
   view and their battle, floating boxes as the raider roster's on the
   right: the Auto deploy switch, then each army sent at them, its
   commander, troops by type and state, a march's bar, Deploy, and a
   corner button that sends it home; then Reinforce. The army on the field
   is lit gold. */
.attack-line {
  position: absolute;
  top: 8px;
  left: 16px;
  z-index: var(--z-chrome);
  display: grid;
  gap: 4px;
  width: min(168px, calc(50% - 24px));
  max-height: calc(100% - 96px);
  padding: 6px 6px 0 0;
  color: var(--text);
  font-family: var(--font-ui);
  overflow-y: auto;
}

.attack-line-auto,
.attack-line-army {
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-hud);
  box-shadow: var(--shadow-sheet);
  backdrop-filter: var(--hud-blur);
}

.attack-line[hidden],
.screen-play.map-open .attack-line {
  display: none;
}

/* The line holds the top-left corner on raiders: the account and morale
   chips that hang there step aside, and so does the day clock
   (visit_bar.js visiting-raiders). */
.screen-play.visiting-raiders .play-left-cluster,
.screen-play.visiting-raiders .day-clock {
  display: none;
}

/* On raiders the settings button joins the top row right of the banner at
   every width, as the wide band has it, so the roster under the row keeps
   the right edge to itself. */
.screen-play.visiting-raiders .play-top-controls {
  position: relative;
  inset: auto;
  flex: none;
  align-items: center;
  margin: var(--play-top-gap) var(--play-top-inset) 0 0;
}

.screen-play.visiting-raiders .top-bar {
  margin-right: 0;
}

.attack-line-auto {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 8px;
  font-weight: 600;
  font-size: var(--caption-text-size);
  cursor: pointer;
}

.attack-line-army {
  position: relative;
  display: grid;
  gap: 4px;
  padding: 4px;
}

.attack-line-reject {
  position: absolute;
  top: calc(var(--icon-control-size-half) / -4);
  right: calc(var(--icon-control-size-half) / -4);
}

.attack-line-army.is-field {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 2px var(--gold-400);
}

.attack-line-army.is-fallen {
  filter: grayscale(1);
}

.attack-line-entry {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.attack-line-face {
  position: relative;
  flex: none;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: var(--card-pic-radius);
  background: var(--portrait-ground);
}

.attack-line-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.attack-line-name {
  overflow: hidden;
  font-weight: 600;
  font-size: var(--caption-text-size);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attack-line-troops {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px 4px;
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
}

.attack-line-troop {
  width: 16px;
  height: 16px;
  image-rendering: pixelated;
}

.attack-line-state {
  color: var(--muted);
  font-size: var(--caption-text-size);
  font-variant-numeric: tabular-nums;
}

.attack-line-march .chip-fill {
  background-color: var(--ok);
}

.screen-play .attack-line .troop-fill.chip-well,
.screen-play .attack-line .troop-fill .chip-qty {
  height: 18px;
  font-size: var(--caption-text-size);
}

/* On a phone the line narrows beside the roster. */
.aspect-portrait .attack-line {
  width: 136px;
}

/* The raider roster (raider_roster.js): down the right edge of the raiders'
   view and their battle, a box per group they stand with: its picture,
   and beside it the group's name over its bar. A tap on a box looks at
   its group. Once a battle is on view it narrows to pictures over bars,
   the names fading out. A gone group's box
   slides off to the right, then the boxes under it close up; coming back,
   the space opens, then the box slides in. The box is see-through while
   its fold is shut, so nothing clips it, picture and shadow included. */
.raider-roster {
  position: absolute;
  top: 8px;
  right: 16px;
  z-index: var(--z-chrome);
  display: flex;
  flex-direction: column;
  --roster-width: min(132px, calc(50% - 24px));
  width: var(--roster-width);
  pointer-events: none;
  transition: width calc(var(--panel-leave-ms) * 1ms) var(--panel-leave-ease);
}


.raider-roster[hidden],
.screen-play.map-open .raider-roster {
  display: none;
}

.roster-entry {
  display: grid;
  grid-template-rows: 1fr;
  transition: grid-template-rows calc(var(--panel-leave-ms) * 1ms) var(--panel-leave-ease);
}

.roster-entry.is-gone {
  grid-template-rows: 0fr;
  transition-delay: calc(var(--panel-leave-ms) * 1ms);
}

.roster-fold {
  min-height: 0;
}

/* The picture pokes out of the box's top left corner, the name beside it
   and the bar under both. The top margin keeps the picture off the box
   above. */
.roster-card {
  position: relative;
  width: 100%;
  margin-top: 8px;
  display: grid;
  gap: 3px;
  padding: 4px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-hud);
  box-shadow: var(--shadow-sheet);
  backdrop-filter: var(--hud-blur);
  color: var(--text);
  font-family: var(--font-ui);
  font-variant-numeric: tabular-nums;
  text-align: left;
  pointer-events: auto;
  transition:
    transform calc(var(--panel-leave-ms) * 1ms) var(--panel-leave-ease) calc(var(--panel-leave-ms) * 1ms),
    opacity calc(var(--panel-leave-ms) * 1ms) var(--panel-leave-ease) calc(var(--panel-leave-ms) * 1ms);
}

.roster-entry.is-gone .roster-card {
  transform: translateX(calc(100% + 16px));
  opacity: 0;
  pointer-events: none;
  transition-delay: 0s;
}

.roster-pic {
  position: absolute;
  top: -8px;
  left: -8px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: var(--panel-border);
  border-radius: var(--card-pic-radius);
  background: var(--portrait-ground);
  color: var(--alert);
}

.roster-pic .i {
  width: 16px;
  height: 16px;
}

.roster-face {
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}

/* A building group's level, a badge on its picture's bottom right. */
.roster-level {
  position: absolute;
  right: -6px;
  bottom: -3px;
  min-width: 13px;
  padding: 0 3px;
  border-radius: 7px;
  background: var(--gold-400);
  color: var(--on-accent);
  font-size: 9px;
  font-weight: 700;
  line-height: 13px;
  text-align: center;
}

.roster-title {
  padding-left: 22px;
  transition: opacity calc(var(--panel-leave-ms) * 1ms) var(--panel-leave-ease);
  overflow: hidden;
  font-weight: 600;
  font-size: var(--caption-text-size);
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.screen-play .raider-roster .troop-fill.chip-well,
.screen-play .raider-roster .troop-fill .chip-qty {
  height: 16px;
  font-size: var(--caption-text-size);
}

/* On a phone the roster narrows beside the attack line. */
.aspect-portrait .raider-roster {
  --roster-width: 112px;
}

/* A battle narrows it on any screen, after the phone's width so it wins,
   and keeps each name's room so the bars stay put as the names fade. */
.raider-roster.is-battle {
  --roster-width: 56px;
}

.raider-roster.is-battle .roster-title {
  opacity: 0;
}

/* The replay bar (battle/replay_bar.js): while a replay plays, Play or
   Pause, the rate, the scrubber under its strip of moment marks, where it
   is of how long, and Copy link; over them at the last tick, how the
   battle ended and Watch again. At phone width the scrubber takes what
   the buttons leave. */
.replay-bar {
  order: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: min(560px, 100%);
  padding: 8px 10px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-panel);
  box-shadow: var(--shadow-sheet);
  color: var(--text);
  font-family: var(--font-ui);
  pointer-events: auto;
}

.replay-end,
.replay-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.replay-end[hidden] {
  display: none;
}

.replay-result {
  flex: 1;
  margin: 0;
  font-weight: 600;
  font-size: 15px;
}

.screen-play .replay-controls .btn.compact {
  min-width: 40px;
  min-height: 40px;
  padding: 0 8px;
  display: inline-grid;
  place-items: center;
}

.replay-controls .i {
  width: 18px;
  height: 18px;
}

.replay-track {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* The scrubber is a range slider (.range-bar), flush under the strip and
   over the marks' lines, so its fill and knob draw on top of them. */
.replay-scrub {
  position: relative;
  z-index: 1;
  margin: 0;
}

/* The strip's ends sit over the knob's centre at the first tick and the
   last. A tap anywhere on it takes the nearest mark (MARK_HIT_PX). */
.replay-marks {
  position: relative;
  height: 18px;
  margin: 0 calc(var(--range-h) / 2);
  cursor: pointer;
}

/* A mark is its moment's place on the strip, in its colour: a line from
   its dot down to the scrubber's middle, under its fill and knob, and the
   dot over it. Neither
   takes a tap or a drag; the strip and the scrubber do. */
.replay-mark {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 0;
  pointer-events: none;
}

.replay-mark.side-0,
.replay-mark.fall {
  color: var(--replay-side-0);
}

.replay-mark.side-1 {
  color: var(--replay-side-1);
}

.replay-tick {
  position: absolute;
  top: 50%;
  bottom: calc(var(--range-h) / -2);
  left: 0;
  width: 2px;
  transform: translateX(-50%);
  background: currentColor;
  opacity: 0.75;
}

.replay-dot {
  position: absolute;
  top: 50%;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: currentColor;
  box-shadow: 0 0 0 1.5px var(--chrome);
}

/* A building falling: a bigger diamond, over the deploys it crowds. */
.replay-mark.fall {
  z-index: 1;
}

.replay-mark.fall .replay-dot {
  width: 11px;
  height: 11px;
  border-radius: 2px;
  transform: translate(-50%, -50%) rotate(45deg);
  box-shadow: 0 0 0 1.5px var(--chrome), 0 0 6px color-mix(in srgb, currentColor 70%, transparent);
}

.replay-time {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* The battalion bar (battle/battalion_bar.js): a row of small tiles per
   army of the viewer's on the field, along the bottom of the dock over the
   menu bar, on a see-through box. The commander's bust, then each
   battalion's portrait with its count across its foot. A selected
   battalion is outlined in gold with its toggle over it; one holding is
   bordered red under a Held badge; a fallen one is grey. Tiles narrow to
   keep a row on screen. Above the row stand two strips: the battalions'
   toggles, then the commander's toggle and Retreat! over those, so the
   two never cover each other. */
.battalion-bar {
  --bar-tile: 48px;
  /* One strip: a compact button and the gap under it. */
  --bar-strip: calc(var(--compact-control-height) + 8px);
  order: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(2 * var(--bar-strip) + 4px);
  max-width: 100%;
  padding-top: calc(2 * var(--bar-strip));
}

.bar-army {
  display: flex;
  gap: 6px;
  max-width: 100%;
  padding: 6px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-hud);
  box-shadow: var(--shadow-sheet);
  backdrop-filter: var(--hud-blur);
  color: var(--text);
  font-family: var(--font-ui);
  pointer-events: auto;
}

.bar-commander,
.bar-battalion {
  position: relative;
  flex: 0 1 auto;
  width: var(--bar-tile);
  min-width: 0;
}

.bar-battalions {
  display: flex;
  flex: 0 1 auto;
  gap: 6px;
  min-width: 0;
}

/* A toggle stands centred over its tile; the commander's pair starts at
   the bust, a strip higher. */
.bar-over {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  translate: -50% 0;
}

.bar-actions {
  bottom: calc(100% + var(--bar-strip) + 8px);
  left: 0;
  translate: none;
  display: flex;
  gap: 4px;
}

.screen-play .battalion-bar .btn.compact {
  width: max-content;
  min-width: var(--bar-tile);
  padding: 0 8px;
  font-size: 12px;
}

/* A gone toggle's whole box goes, so its empty box catches no tap. */
.bar-over.is-gone {
  visibility: hidden;
}

.bar-face,
.bar-pic {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  padding: 0;
  border: 2px solid var(--play-line);
  border-radius: 8px;
  cursor: pointer;
}

/* The commander's bust fills its square on the Settlers panel's ground; a
   tap looks at them. */
.bar-face {
  position: relative;
  overflow: hidden;
  background: var(--portrait-ground);
}

.bar-troop {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 6px;
  image-rendering: pixelated;
}

.bar-pic {
  background: var(--surface-2);
  line-height: 0;
}

.bar-pic:hover:not(:disabled) {
  border-color: var(--play-line-strong);
}

.bar-battalion.is-held .bar-pic {
  border-color: var(--danger);
}

.bar-pic.is-selected,
.bar-pic.is-selected:hover {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 2px var(--gold-400);
}

.bar-pic:disabled {
  cursor: default;
}

.bar-battalion .troop-fill {
  position: absolute;
  right: 4px;
  bottom: 4px;
  left: 4px;
  pointer-events: none;
}

.bar-held {
  position: absolute;
  top: -6px;
  left: 50%;
  translate: -50% 0;
  padding: 0 4px;
  border-radius: 6px;
  background: var(--danger);
  color: var(--on-accent);
  font-size: 9px;
  font-weight: 700;
  line-height: 12px;
  pointer-events: none;
  display: none;
}

.bar-battalion.is-held .bar-held {
  display: block;
}

.bar-battalion.is-fallen {
  filter: grayscale(1);
  opacity: 0.45;
}

/* The combat bar (combat_bar.js): in the resource bar's place while a
   battle is on screen, who fights whom and how long it has run, over when
   the attack ends on the clock and the waves still to come; on raiders on
   view with no battle, scouting them. A battle also hides Edit and Build
   and morale. */
.screen-play.in-combat .city-play-btns,
.screen-play.in-combat .morale-chip {
  display: none;
}

.screen-play.city-visiting.in-combat .top-bar:not([hidden]),
.screen-play.city-visiting.scouting .top-bar:not([hidden]) {
  display: flex;
}

/* While the top bar carries the combat bar (a battle, or scouting raiders)
   it reads as a banner: red-edged, glowing, its title in display caps
   behind crossed swords. */
.screen-play:is(.in-combat, .scouting) .top-bar {
  border-color: var(--alert);
  background: linear-gradient(115deg, color-mix(in srgb, var(--btn-negative) 45%, var(--surface-2)), var(--surface-1) 70%);
  box-shadow: var(--shadow-sheet), 0 0 18px color-mix(in srgb, var(--alert) 35%, transparent);
}

.combat-bar {
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2px;
}

.combat-bar[hidden] {
  display: none;
}

.combat-bar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
  font-weight: 600;
}

.combat-bar-head > .i {
  flex: none;
  width: 22px;
  height: 22px;
  color: var(--alert);
}

.combat-bar-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--selected-ink);
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.combat-bar-clock {
  flex: none;
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  font-variant-numeric: tabular-nums;
}

/* On a phone the banner steps down a size and drops its icon, so the kind
   and level fit beside the way back and the settings button. */
.aspect-portrait :is(.combat-bar-title, .combat-bar-clock) {
  font-size: 18px;
  letter-spacing: 0.02em;
}

.aspect-portrait .combat-bar-head > .i {
  display: none;
}

.combat-bar-waves {
  display: grid;
  margin: 0;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

/* The clock's fill drains behind its line, a second at a time, and turns red near the end. */
.combat-bar-ends {
  position: relative;
  overflow: hidden;
  margin: 0;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--surface-2);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.combat-bar-ends-fill {
  position: absolute;
  inset: 0 auto 0 0;
  background: color-mix(in srgb, var(--info-deep) 55%, transparent);
  transition: width 1s linear;
}

.combat-bar-ends-urgent .combat-bar-ends-fill {
  background: color-mix(in srgb, var(--alert) 60%, transparent);
}

.combat-bar-ends-text {
  position: relative;
}

.combat-bar-ends[hidden],
.combat-bar-waves[hidden] {
  display: none;
}

/* Along the card's top: its commander's portrait, a little wider than a
   battalion's, then a slot per battalion position, kept compact on a wide
   panel. */
.army-roster {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(5, minmax(0, 1fr));
  gap: var(--army-slot-gap);
  align-items: stretch;
  max-width: 440px;
}

/* The commander's portrait, which picks or changes who leads, as tall as a
   slot with its bar. */
.army-commander,
.army-slot-pic {
  display: grid;
  place-items: center;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--play-line);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
}

.army-commander-face,
.army-troop-face {
  width: 100%;
  height: 100%;
}

.army-commander-face {
  object-fit: cover;
}

.army-slot-pic {
  width: 100%;
  aspect-ratio: 1;
}

button.army-commander:hover,
button.army-slot-pic:hover {
  border-color: var(--play-line-strong);
  background: var(--surface-3);
}

.army-commander-face {
  background: #f6f1e5;
}

.army-troop-face {
  image-rendering: pixelated;
}

.army-plus {
  font-size: 28px;
  line-height: 1;
}

.army-commander-name {
  min-width: 0;
  overflow: hidden;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.army-commander-lead {
  flex: none;
  color: var(--muted);
  font-size: var(--caption-text-size);
  white-space: nowrap;
}

/* A slot is its troop's portrait or an unused frame, a half close button
   on its corner that clears it, and under it its troops against its target
   as a bar as wide. */
.army-slot {
  display: grid;
  align-content: start;
  gap: var(--army-slot-gap);
  min-width: 0;
}

/* A position with no battalion reads unused: a darker, dashed square over
   an empty bar. A battalion with no troops left dims. */
.army-slot.is-unused .army-slot-pic {
  border-style: dashed;
  background: var(--surface-1);
}

.army-slot.is-out .army-slot-pic {
  opacity: var(--dim-opacity);
}

.army-slot-face {
  position: relative;
}

/* A half close button on the slot face's top right corner, mostly inside it. */
.army-slot-clear {
  position: absolute;
  top: calc(var(--icon-control-size-half) / -4);
  right: calc(var(--icon-control-size-half) / -4);
}

.screen-play .troop-fill.chip-well {
  height: var(--troop-fill-height);
}

.screen-play .troop-fill .chip-qty {
  justify-content: center;
  height: var(--troop-fill-height);
  padding: 0;
  font-size: 12px;
}

.screen-play .battalion-bar .troop-fill.chip-well,
.screen-play .battalion-bar .troop-fill .chip-qty {
  height: 12px;
  font-size: 9px;
}

/* An army card's battalion at its target fills green, one short amber, and
   one with none red right across. */
.troop-fill.fill-ok .chip-fill {
  background-color: var(--ok);
}

.troop-fill.is-short .chip-fill {
  background-color: var(--warn);
}

.troop-fill.is-out .chip-fill {
  background-color: var(--danger);
}

/* The slot the troop picker is filling. */
.army-slot-pic.is-picking,
.army-slot-pic.is-picking:hover {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 2px var(--gold-400);
}

/* The troop picker's portraits are square, as the slots are. */
.tray-face.is-troop .tray-pic {
  border: 1px solid var(--play-line);
  border-radius: 8px;
  background: var(--surface-2);
}

/* The troop type the slot holds now, lit as the slot is. */
.tray-face.is-troop.is-current,
button.tray-face.is-troop.is-current:hover {
  border-color: var(--gold-400);
  box-shadow: 0 0 0 2px var(--gold-400);
}

/* What the slot would hold of a type against how many wait in reserve:
   green with enough, gold when the reserve falls short, red with none. */
.army-supply {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.army-supply.is-enough {
  color: var(--ok);
}

.army-supply.is-short {
  color: var(--gold-400);
}

.army-supply.is-none {
  color: var(--danger);
}

.member-leads {
  color: var(--muted);
  font-size: var(--caption-text-size);
}

.morale-impacts-title {
  margin: 8px 0 0;
  font-size: 1rem;
  font-weight: 600;
}

.morale-impacts {
  margin: 4px 0 8px;
  padding-left: 1.2em;
}

.morale-cols {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.morale-col {
  flex: 1 1 0;
  min-width: 0;
}

.morale-col h3,
.morale-improve h3 {
  margin: 0 0 6px;
  font-size: 0.85rem;
  font-weight: 600;
}

.morale-col-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.morale-improve {
  margin-top: 12px;
}

/* The game skin is shared by play, the title menu, and the family designer. */
:is(.screen-play, .screen-title, .screen-designer) {
  /* Play keeps its column this far in from the screen's edges; the designer's toasts too. */
  --menu-inset: 8px;
  /* The developer's and the System's colours: their chat lines, and the tracker's developer
     section and log. */
  --developer: #7fd08c;
  --system: var(--selected-ink);
  --play-top-gap: 8px;
  /* The account and morale chips' height; the portrait clock matches it. */
  --left-chip-size: 36px;
  /* The sky clock's lens: its width in landscape, its height in portrait. */
  --clock-lens: 48px;
  /* The clock holds this width so the account and morale row can stop short of it. */
  --corner-clock-width: var(--clock-lens);
  --corner-clock-reserve: 0px;
  --panel-fixed-max: 745px;
  --panel-inset: 14px;
  --panel-border-width: 1px;
  --panel-border: var(--panel-border-width) solid var(--panel-line);
  --control-height: 32px;
  --compact-control-height: 24px;
  --icon-control-size: 30px;
  --icon-control-size-half: calc(var(--icon-control-size) / 2);
  --panel-tab-selected-height: 40px;
  /* The gap between an army card's portraits and under a battalion's, and
     its troop bar. */
  --army-slot-gap: 6px;
  --troop-fill-height: 22px;
  /* Where troops stand (inventory_troops.js PLACES), on the Units tab's
     troop space and troop tiles: a bar share and its legend dot. Damaged
     troops are amber wherever they are, since they don't fight. */
  --troop-deployed: var(--ok);
  --troop-reserve: var(--info-deep);
  --troop-damaged: var(--warn);
  --troop-bar-height: 10px;
  /* A term pill's height and its icon box's width (build_tile.js). */
  --term-height: 40px;
  --control-text-size: 14px;
  --panel-title-size: 24px;
  --meta-text-size: 14px;
  --caption-text-size: 12px;
  --card-title-size: 22px;
  /* A good's icon in a list: inventory tiles, trade rows. */
  --good-icon-size: 36px;
  /* A tile's or call box's name: a build tile, a radio contact. */
  --tile-title-size: 18px;
  /* Recessed fields use the panel and raised surfaces. */
  --surface-well: linear-gradient(var(--surface-1), var(--surface-2));
  --well-line: #6c818866;
  --gold-500: #d4a44a;
  --gold-700: #c49238;
  --olive: #3c3624;
  --olive-line: #c6a45a;
  --info: #78d5fa;
  --info-deep: #4a92dc;
  --alert: #ff858c;
  --alert-ink: #1a0a0c;
  --ok: #3dbe78;
  --ok-bg: #173d2c;
  --ok-text: #b2f3d5;
  --ok-ink: #06180f;
  /* A building pip's upgrade that waits only on stock (pip.js PIP_SAVE): the
     ok green's arrow in brown, muted so it stays clear of --warn's amber. */
  --save: #b07d52;
  --font-body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --font-ui: "Barlow Semi Condensed", "Segoe UI", system-ui, sans-serif;
  --font-pixel: "Press Start 2P", monospace;
  --bg: var(--surface-0);
  --ink: var(--text);
  --line: var(--play-line);
  --line-faint: color-mix(in srgb, var(--line) 25%, transparent);
  --accent: var(--gold-400);
  --on-accent: var(--gold-ink);
  --danger: var(--alert);
  --chip-well: #1b2b34;
  --chip-fill: #71603c;
  --chip-fill-work: #94804b;
  --btn-positive-ink: var(--btn-go-ink);
  --btn-positive-fill: var(--btn-go-fill);
  --btn-go: var(--ok);
  --btn-go-ink: var(--ok-ink);
  --btn-go-fill: #8ee8b63d;
  --btn-start: var(--info);
  --btn-start-ink: #04141c;
  --btn-start-fill: #b6e9ff3d;
  --btn-negative: #b84d56;
  --btn-negative-fill: #ff858c33;
  --btn-neutral: var(--skin-accent);
  --btn-neutral-ink: var(--skin-panel);
  --btn-neutral-fill: #bad8ef20;
  --scroll: #b5ccd738;
  --scroll-hover: #b5ccd760;
  --row-selected: #f4c75f18;
  --meter-fill: linear-gradient(#ffe998, #f5bc43 70%, #efb640);
  --ms-turn: 1400ms;
  --chat-list: 120px;
  /* The thread takes the width the floating HUD leaves, 280px to 380px. display_aspect.js
     adds the room list beside it only once both fit at the full 380px. */
  --chat-thread: clamp(280px, 100vw - var(--float-width), 380px);
  color-scheme: dark;
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 14px;
  --skin-panel: #202124;
  --skin-raised: #393b40;
  --skin-line: #aaadb5;
  --skin-text: #f0f1f3;
  --skin-muted: #c4c6cd;
  --skin-accent: #c4cbe1;
  --skin-selected: #464c5b;
  --font-display: "Barlow Condensed", sans-serif;
  /* The play column's chrome, stacked: the top row, the top and bottom panels, the crest editor,
     and the menu bar. --float-width wide, or the column less a --menu-inset each side. Its 100%
     resolves where it is read, so it holds only for a box whose container is the play column. */
  --play-width: min(var(--float-width), calc(100% - 2 * var(--menu-inset)));
  --play-top-inset: 0px;
  --play-control-inset: 0px;
  --panel-radius: 0px;
  --control-radius: 0px;
  --surface-panel: var(--skin-panel);
  --surface-hud: var(--skin-panel);
  --panel: var(--skin-panel);
  --surface-1: var(--skin-panel);
  --surface-2: var(--skin-raised);
  /* The solid surface a quantity slider sits on (.reach-range.chit-reach):
     a panel's, or a row card's, which sets its own. */
  --reach-ground: var(--surface-1);
  --play-line: var(--skin-line);
  --play-line-strong: var(--skin-line);
  --text: var(--skin-text);
  --muted: var(--skin-muted);
  --gold-200: var(--skin-accent);
  --gold-400: var(--skin-accent);
  --btn-neutral-face: var(--skin-raised);
  --btn-disabled-face: #4a4642;
  --btn-negative-face: var(--alert);
  --btn-negative-ink: var(--skin-panel);
  --btn-negative-line: var(--alert);
  --selected-fill: var(--skin-selected);
  --selected-ink: var(--skin-text);
  --selected-line: var(--skin-accent);
  --selected-glow: none;
  --shadow-card: none;
  --shadow-sheet: none;
  --btn-shadow: none;
  --shadow: none;
  --panel-line: var(--skin-line);
  --surface-0: var(--skin-panel);
  --surface-3: var(--skin-raised);
  --text-dim: var(--skin-muted);
  --chrome: var(--skin-panel);
  --hud-blur: none;
  --panel-radius-inner: 0px;
  --btn-positive: var(--btn-go);
  --gold-ink: var(--skin-panel);
  --chat-room-line: var(--skin-raised);
}

.aspect-portrait .screen-play {
  --left-chip-size: 32px;
  --clock-lens: var(--left-chip-size);
  --corner-clock-width: calc(2 * var(--clock-lens));
  --menu-inset: 6px;
  --play-width: 100%;
  --play-control-inset: 7px;
  --meta-text-size: 13px;
  --caption-text-size: 11px;
}

:is(.screen-play, .screen-designer) .i {
  width: 22px;
  height: 22px;
  display: block;
  flex: none;
  text-shadow: none;
  filter: none;
}

:is(.screen-play, .screen-title, .screen-designer) :is(button, input):focus-visible {
  outline: 2px solid var(--skin-accent);
  outline-offset: -3px;
}

:is(.screen-play, .screen-title, .screen-designer) .btn,
.screen-play .trait,
.screen-play .dest-item,
.screen-play .tool,
.screen-play .res,
.screen-play .clock,
.screen-play .pill,
.screen-play .member-meta,
.screen-play .xp-line,
.screen-play .card-meta,
.screen-play .card-line,
.screen-play .card-status,
.screen-play .menu-bar button {
  font-family: var(--font-ui);
}

:is(.screen-play, .screen-title, .screen-designer) button.btn {
  gap: 6px;
  min-height: var(--control-height);
  padding: 0 10px;
  border: 1px solid var(--play-line-strong);
  border-radius: var(--control-radius);
  font-weight: 600;
  font-size: var(--control-text-size);
  line-height: 1;
  white-space: nowrap;
  box-shadow: var(--btn-shadow);
}

:is(.screen-play, .screen-title, .screen-designer) button.btn.positive,
:is(.screen-play, .screen-title, .screen-designer) button.btn.go {
  background-color: var(--ok);
  background-image: linear-gradient(#6fdc9f, #2f9e62);
  color: var(--btn-go-ink);
  border-color: #8ee8b6;
}

.screen-play button.btn.start {
  background-color: var(--info);
  background-image: linear-gradient(#9fe2ff, #3c9fd0);
  color: var(--btn-start-ink);
  border-color: #b6e9ff;
}

:is(.screen-play, .screen-title, .screen-designer) button.btn.neutral {
  background: var(--btn-neutral);
  border-color: var(--btn-neutral);
  color: var(--btn-neutral-ink);
  text-shadow: none;
}

:is(.screen-play, .screen-title, .screen-designer) button.btn.discord {
  background: var(--btn-discord);
  border-color: var(--btn-discord);
  color: var(--btn-discord-ink);
  text-shadow: none;
}

/* Caution: a button the player can still tap, that will say why it can't
   go through yet (the market's trade past what the account can do), or a
   start that buys its shortfall with chits (button.js bindStart). */
.screen-play button.btn.caution {
  background-color: var(--warn);
  background-image: linear-gradient(#ffcf80, #d8891f);
  color: var(--btn-caution-ink);
  text-shadow: none;
  border-color: #ffdca3;
}

.screen-play button.btn.negative {
  background: var(--btn-negative-face);
  color: var(--alert-ink);
  border-color: var(--btn-negative-line);
}

/* Whatever its intent, a button that can't be pressed yet is flat grey. A
   button stays its colour while its request runs. */
:is(.screen-play, .screen-title, .screen-designer) button.btn:is(:disabled, [aria-disabled="true"]):not(.processing) {
  opacity: 1;
  background: var(--btn-disabled-face);
  border-color: var(--btn-disabled-face);
  color: var(--muted);
  text-shadow: none;
}

.screen-play button.btn.compact {
  min-height: var(--compact-control-height);
  padding: 0 10px;
  font-size: 13px;
}

.screen-play .icon-btn {
  width: var(--icon-control-size);
  height: var(--icon-control-size);
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: var(--control-radius);
  border: 1px solid var(--play-line-strong);
  box-shadow: none;
  background: var(--btn-neutral-face);
  color: var(--text);
  text-shadow: none;
}

.screen-play .icon-btn .i {
  width: 20px;
  height: 20px;
}

/* The close button (button.js closeFace, bindClose): every dismiss and
   remove in play, at the icon control size or, with .half, half of it. The
   icon fills two thirds of a full face; on a half face it fills the face, so
   the X stays legible. */
.screen-play .close-btn {
  --close-size: var(--icon-control-size);
  --close-icon: calc(var(--close-size) * 2 / 3);
  flex: none;
  width: var(--close-size);
  height: var(--close-size);
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--play-line-strong);
  border-radius: var(--control-radius);
  box-shadow: var(--btn-shadow);
  background: var(--btn-neutral-face);
  color: var(--text);
  text-shadow: none;
}

.screen-play .close-btn.half {
  --close-size: var(--icon-control-size-half);
  --close-icon: 100%;
}

.screen-play .close-btn .i {
  width: var(--close-icon);
  height: var(--close-icon);
  filter: none;
}

/* An armed close (button.js bindConfirmClose) trades its X for words and widens to fit them. */
.screen-play .close-btn.armed {
  width: auto;
  padding: 0 12px;
}

.close-btn-words {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: var(--control-text-size);
  white-space: nowrap;
}

/* The delete (button.js bindDelete): the admin's trash can, a bare icon in
   a square that turns red on hover. */
.screen-play .delete-btn {
  flex: none;
  width: var(--icon-control-size);
  height: var(--icon-control-size);
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid transparent;
  border-radius: var(--control-radius);
  box-shadow: none;
  background: transparent;
  color: var(--muted);
}

.screen-play .delete-btn:hover:not([aria-disabled="true"]) {
  border-color: color-mix(in srgb, var(--danger) 50%, transparent);
  background: color-mix(in srgb, var(--danger) 15%, transparent);
  color: var(--danger);
}

.screen-play .delete-btn .i {
  width: 18px;
  height: 18px;
}

/* The slide to confirm (ui/confirm_slide.js). In play it is a sheet where the bottom panels
   stand (.confirm-slide, placed with the crest editor), over a backdrop under the menu bar,
   which holds its Close and CTA. On the title it is a view of the menu. */
.confirm-slide {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.confirm-slide-backdrop {
  z-index: var(--z-panels);
}

.confirm-slide-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.confirm-slide-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--card-title-size);
  color: var(--text);
}

.confirm-slide-message {
  margin: 0;
  color: var(--text);
  line-height: 1.4;
}

/* The track draws as a range slider does (.range-bar), in red: a rounded bar that fills up to
   its knob over the label, a light disc ringed in red. It stands half again a slider's height, as a bigger
   mark for a finger. */
.confirm-slide-track {
  /* The track's height and the knob's diameter. */
  --confirm-slide-size: calc(var(--range-h) * 1.5);
  position: relative;
  height: var(--confirm-slide-size);
  overflow: hidden;
  border-radius: 99px;
  background: color-mix(in srgb, var(--text) 14%, transparent);
  touch-action: none;
  user-select: none;
}

.confirm-slide-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--btn-negative);
  pointer-events: none;
}

.confirm-slide-label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  font-family: var(--font-ui);
  font-size: var(--control-text-size);
  font-weight: 600;
  pointer-events: none;
}

.confirm-slide-arrow .i {
  display: block;
  width: 12px;
  height: 12px;
}

/* The three arrows pulse in turn, left to right, the way the handle goes. */
.confirm-slide-arrow {
  opacity: 0.45;
  animation: confirm-slide-pulse 1.2s ease-in-out infinite;
  animation-delay: calc(var(--arrow) * 0.2s);
}

@keyframes confirm-slide-pulse {
  20% {
    opacity: 1;
    transform: translateX(3px) scale(1.15);
  }
  45% {
    opacity: 0.45;
    transform: none;
  }
}

.confirm-slide-track.is-done .confirm-slide-arrow {
  animation: none;
}

.confirm-slide-handle {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--confirm-slide-size);
  padding: 0;
  border: 4px solid var(--btn-negative);
  border-radius: 50%;
  background: var(--text);
  cursor: grab;
  touch-action: none;
}

.confirm-slide-handle:active {
  cursor: grabbing;
}

.confirm-slide-track.springing :is(.confirm-slide-handle, .confirm-slide-fill) {
  transition: transform 0.25s ease-out, width 0.25s ease-out;
}

/* A CTA tapped before the slide flashes the track (confirm_slide.js FLASH_MS). */
.confirm-slide-track.is-flash {
  animation: confirm-slide-flash 0.45s ease-in-out;
}

@keyframes confirm-slide-flash {
  25%,
  75% {
    filter: brightness(1.6);
  }
  50% {
    filter: none;
  }
}

/* The Back (button.js bindBack): an amber button with a left chevron, as
   tall as the close it sits beside. */
.screen-play button.btn.back-btn {
  min-height: var(--icon-control-size);
  padding: 0 12px 0 6px;
  gap: 2px;
  background: var(--skin-accent);
  border-color: var(--skin-accent);
  color: var(--skin-panel);
  text-shadow: none;
}

/* A Start's label wraps where the menu bar is too narrow for it (button.js
   bindStart). */
:where(.start-btn) > .btn-label {
  white-space: pre-line;
  line-height: 1.2;
}

/* A Start priced in chits (button.js bindStart) leads with the chits icon
   and the price, held close so they read as one cost before the verb. */
.screen-play button.btn.start-btn.priced {
  gap: 2px;
}

/* The Back's chevron, the Close's X, and the Start's check (button.js bindStart) share a size,
   on every screen: the title's slide to confirm has a Close too. */
:is(.screen-play, .screen-title, .screen-designer) :is(.back-btn, .start-btn) .i {
  width: 18px;
  height: 18px;
}

.screen-play .hud-bar,
.screen-play .top-bar {
  padding: 6px 10px;
  background: var(--surface-panel);
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  box-shadow: inset 0 1px 2px #ffffff18, 0 2px 4px #0004;
  color: var(--text);
}

.screen-play .top-bar {
  flex: 1;
  margin: var(--play-top-gap) var(--play-top-inset) 0;
  box-shadow: none;
  background: var(--skin-panel);
  border: 0;
  padding: 10px 14px;
}

/* 720px matches --float-width, the widest --play-width. A container query does not resolve var().
   Under that width the clock stays in the corner. The row's own width is the measure, so an
   open radio dock can drop the clock back out. The clock fills the row so it reads as one band
   with the resource bar. Only the bar and the clock set the row's height: the tools stack and
   the debug stack are overlays, so an open debug panel or the dev debug button cannot stretch
   the bar. */
@container play-top style(--top-band: yes) and (min-width: 720px) {
  .play-top-row > .top-bar {
    margin: var(--play-top-gap) 0 0 var(--play-top-inset);
  }

  /* The band joins the clock and tools to the resource bar. Before the first resource the bar
     is hidden and they stay in the corner, beside the account and morale row. */
  /* The column is the bar's height and the clock fills it, so the tools hang the row's gap
     under the clock. */
  .play-top-row:has(> .top-bar:not([hidden])) > .play-top-controls {
    position: relative;
    inset: auto;
    flex: 0 0 auto;
    align-items: stretch;
    margin: var(--play-top-gap) var(--play-top-inset) 0 0;
    padding-right: 0;
  }

  .play-top-row:has(> .top-bar:not([hidden])) > .play-top-hud .play-left-cluster {
    margin-right: 0;
  }

  .play-top-row:has(> .top-bar:not([hidden])) > .play-top-controls > .hud-tools {
    position: absolute;
    top: calc(100% + var(--play-top-gap));
    right: 0;
  }

  .play-top-row:has(> .top-bar:not([hidden])) .play-right {
    position: relative;
    flex: 1 1 auto;
    gap: 0;
  }

  .play-top-row:has(> .top-bar:not([hidden])) .play-right > .clock {
    flex: 1 1 auto;
  }
}

.screen-play .chips {
  justify-content: space-between;
  gap: 4px;
}

:where(.screen-play) .res {
  --res-icon-size: 24px;
  flex: 1;
  display: grid;
  grid-template-columns: var(--res-icon-size) minmax(0, 1fr);
  align-items: center;
  gap: 3px 5px;
  min-width: 0;
  min-height: 48px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  --res-name-color: var(--muted);
  --res-line-color: var(--text);
  color: var(--gold-200);
  text-align: left;
}

/* A chip in alert (top_bar.js paintChip) is red whole: icon, name, amount. */
.res[data-tone="alert"] {
  --res-name-color: var(--alert);
  --res-line-color: var(--alert);
  color: var(--alert);
}

.res:disabled {
  opacity: 1;
}

@media (hover: hover) {
  .res:where(:enabled:hover) {
    background: var(--surface-2);
  }
}

.res:where(:enabled:active) {
  background: var(--selected-fill);
}

.screen-play .res .i {
  grid-column: 1;
  grid-row: 1;
  width: var(--res-icon-size);
  height: var(--res-icon-size);
}

.screen-play .res-copy {
  display: contents;
}

.screen-play .res-name {
  grid-column: 2;
  grid-row: 1;
  color: var(--res-name-color);
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: var(--caption-text-size);
}

.screen-play .res-line {
  grid-column: 1 / -1;
  grid-row: 2;
  display: flex;
  align-items: baseline;
  gap: 6px;
  color: var(--res-line-color);
  white-space: nowrap;
}

.screen-play .res-val {
  font-weight: 600;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  font-size: 22px;
}

.screen-play .res-flag {
  font-weight: 500;
  font-size: 12px;
  color: var(--gold-200);
}

.screen-play .res-flag[data-tone="alert"] {
  color: var(--alert);
}

/* Sky clock. The lens is the phase and the weather in one picture; the countdown to its turn
   is hudClock(). hud.js paints data-phase, data-weather, data-lamps, --solar, and is-turning
   for --ms-turn. Landscape stacks the countdown under the lens, so the clock stays as tall as
   the resource bar; portrait sets it beside the lens at the account chip's height. */
.screen-play .clock {
  width: var(--corner-clock-width);
  display: grid;
  grid-template-columns: var(--clock-lens);
  grid-template-rows: minmax(0, 1fr) auto;
  grid-template-areas: "sky" "countdown";
  color: var(--text);
  box-shadow: none;
  border: 0;
  --clock-radius: 0px;
  --clock-radius-inner: var(--clock-radius);
}

.screen-play:has(.day-clock:not([hidden])) {
  --corner-clock-reserve: calc(var(--corner-clock-width) + 8px);
}

.screen-play .clock[hidden] {
  display: none;
}

.screen-play .clock.is-turning .clock-countdown {
  animation: clock-copy-swap var(--ms-turn) ease;
}

.screen-play .clock-countdown {
  grid-area: countdown;
  align-self: stretch;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2px 0;
  background: var(--skin-raised);
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: var(--caption-text-size);
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: color-mix(in srgb, var(--text) 50%, transparent);
}

.screen-play .clock-sky {
  --r: calc(var(--clock-lens) * 0.36);
  --ang: calc((var(--solar) - 0.25) * 1turn);
  grid-area: sky;
  position: relative;
  align-self: stretch;
  min-height: 36px;
  border-radius: var(--clock-radius-inner) 0 0 0;
  overflow: hidden;
  background: #4aa3e6;
  background-clip: padding-box;
  isolation: isolate;
  transition: --solar 400ms linear;
  border-right: 0;
  box-shadow: none;
}

.screen-play .clock.is-turning .clock-sky {
  transition-duration: var(--ms-turn);
  transition-timing-function: cubic-bezier(0.5, 0, 0.3, 1);
}

.screen-play .clock-sky > :where(span) {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.screen-play .sky-day {
  background: linear-gradient(#3f9be3, #9fd3f2 58%, #e6cf8e);
}

.screen-play .sky-night {
  background: linear-gradient(#070c22, #16234b 60%, #2a3a66);
  opacity: 0;
  transition: opacity var(--ms-turn) ease;
}

.screen-play .clock[data-phase="night"] .sky-night {
  opacity: 1;
}

.screen-play .sky-stars {
  opacity: 0;
  transition: opacity calc(var(--ms-turn) * 0.6) ease calc(var(--ms-turn) * 0.4);
}

/* The stars twinkle on their own layer, by opacity alone, so the compositor
   runs it while .sky-stars fades in and out for night. */
.screen-play .sky-stars::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1.4px 1.4px at 18% 22%, #fff 95%, transparent),
    radial-gradient(1px 1px at 38% 12%, #fff, transparent),
    radial-gradient(1.2px 1.2px at 62% 30%, #fff, transparent),
    radial-gradient(1px 1px at 80% 16%, #fff, transparent),
    radial-gradient(1.4px 1.4px at 72% 44%, #fff, transparent),
    radial-gradient(1px 1px at 28% 46%, #fff, transparent),
    radial-gradient(1px 1px at 50% 36%, #fffb, transparent),
    radial-gradient(1px 1px at 12% 40%, #fffb, transparent);
}

.screen-play .clock[data-phase="night"] .sky-stars {
  opacity: 1;
}

.screen-play .clock[data-phase="night"] .sky-stars::before {
  animation: clock-twinkle 3.2s ease-in-out infinite alternate;
}

.screen-play .sky-sun,
.screen-play .sky-moon {
  inset: auto;
  left: 50%;
  top: 64%;
  border-radius: 50%;
}

.screen-play .sky-sun {
  width: calc(var(--clock-lens) * 0.3);
  height: calc(var(--clock-lens) * 0.3);
  margin: calc(var(--clock-lens) * -0.15);
  background: radial-gradient(circle at 40% 40%, #fff8d6, #ffd65e 55%, #f0a640);
  box-shadow: 0 0 calc(var(--clock-lens) * 0.18) #ffcf5a99;
  transform: translate(calc(cos(var(--ang)) * var(--r)), calc(sin(var(--ang)) * var(--r) * -1));
}

.screen-play .sky-moon {
  --ang-m: calc(var(--ang) + 0.5turn);
  width: calc(var(--clock-lens) * 0.24);
  height: calc(var(--clock-lens) * 0.24);
  margin: calc(var(--clock-lens) * -0.12);
  background: radial-gradient(circle at 35% 35%, #ffffff, #d9e2f5 60%, #a9b8dc);
  box-shadow: 0 0 calc(var(--clock-lens) * 0.16) #bcd0ff66, inset calc(var(--clock-lens) * -0.06) calc(var(--clock-lens) * -0.04) 0 0 #5f6f9e;
  transform: translate(calc(cos(var(--ang-m)) * var(--r)), calc(sin(var(--ang-m)) * var(--r) * -1));
}

.screen-play .sky-dusk {
  background: linear-gradient(transparent 25%, #ff7a3a99 62%, #ffc76e 78%);
  opacity: 0;
  mix-blend-mode: screen;
}

.screen-play .clock.is-turning .sky-dusk {
  animation: clock-dusk-band var(--ms-turn) ease-in-out;
}

.screen-play .sky-ground {
  top: 62%;
  background: linear-gradient(#324a37, #1b291f);
  clip-path: polygon(0 34%, 10% 34%, 10% 18%, 20% 18%, 20% 30%, 28% 30%, 28% 4%, 33% 0, 38% 4%, 38% 26%, 47% 26%, 47% 14%, 55% 14%, 55% 30%, 64% 30%, 64% 20%, 72% 20%, 72% 32%, 82% 32%, 82% 24%, 90% 24%, 90% 34%, 100% 34%, 100% 100%, 0 100%);
  transition: filter var(--ms-turn) ease;
}

.screen-play .clock[data-phase="night"] .sky-ground {
  filter: brightness(0.35) saturate(0.5);
}

/* Windows follow the city's bulbs (lampGlow), 72s after dusk and off 72s before dawn. */
.screen-play .sky-windows {
  top: 62%;
  background:
    radial-gradient(1.4px 1.4px at 14% 60%, #ffd27a, transparent),
    radial-gradient(1.4px 1.4px at 31% 30%, #ffd27a, transparent),
    radial-gradient(1.4px 1.4px at 34% 52%, #ffe39a, transparent),
    radial-gradient(1.4px 1.4px at 51% 44%, #ffd27a, transparent),
    radial-gradient(1.4px 1.4px at 68% 56%, #ffd27a, transparent),
    radial-gradient(1.4px 1.4px at 86% 58%, #ffe39a, transparent);
  opacity: 0;
  transition: opacity 500ms ease;
}

.screen-play .clock[data-lamps="on"] .sky-windows {
  opacity: 1;
}

.screen-play .sky-cloud {
  inset: auto;
  top: 26%;
  left: 0;
  width: 58%;
  height: 20%;
  border-radius: 999px;
  background: #eef4f9;
  box-shadow: inset 0 calc(var(--clock-lens) * -0.05) calc(var(--clock-lens) * 0.06) #9db2c5aa;
  opacity: 0;
  transition: opacity 600ms ease, filter var(--ms-turn) ease;
  animation: clock-cloud-drift 18s linear infinite;
  /* A hidden cloud's drift still ticks on the main thread every frame, so it
     drifts only while it shows. */
  animation-play-state: paused;
}

.screen-play .sky-cloud::before {
  content: "";
  position: absolute;
  left: 24%;
  top: -60%;
  width: 44%;
  height: 140%;
  border-radius: 50%;
  background: inherit;
  box-shadow: inherit;
}

.screen-play .sky-cloud.c2 { top: 44%; width: 44%; height: 16%; animation-duration: 26s; animation-delay: -9s; }
.screen-play .sky-cloud.c3 { top: 10%; width: 52%; height: 18%; animation-duration: 21s; animation-delay: -14s; }
.screen-play .sky-cloud.c4 { top: 34%; width: 62%; height: 20%; animation-duration: 17s; animation-delay: -5s; }
.screen-play .sky-cloud.c5 { top: 20%; width: 40%; height: 15%; animation-duration: 29s; animation-delay: -20s; }
.screen-play .sky-cloud.c6 { top: 50%; width: 56%; height: 17%; animation-duration: 23s; animation-delay: -11s; }

.screen-play .clock:is([data-weather="cloud"], [data-weather="rain"], [data-weather="storm"]) .sky-cloud {
  opacity: 0.95;
  animation-play-state: running;
}

.screen-play .clock:not([data-weather="storm"]) .sky-cloud.storm-only {
  opacity: 0;
  animation-play-state: paused;
}

.screen-play .clock[data-weather="storm"] .sky-cloud {
  filter: brightness(0.5) saturate(0.6);
}

.screen-play .clock[data-phase="night"] .sky-cloud {
  filter: brightness(0.45);
}

.screen-play .clock[data-phase="night"][data-weather="storm"] .sky-cloud {
  filter: brightness(0.3);
}

.screen-play .sky-rain {
  --rain-ms: 0.7s;
  inset: -20%;
  transform: skewX(-12deg);
  mask-image: linear-gradient(transparent 22%, #000 42%, #000 72%, transparent 88%);
  opacity: 0;
  transition: opacity 400ms ease;
}

/* Two sheets of drops, each a period taller than the sky, slid down one
   period a loop by transform so the compositor runs them. They fall only
   while it rains. */
.screen-play .sky-rain::before,
.screen-play .sky-rain::after {
  content: "";
  position: absolute;
  inset: 0;
  top: calc(-1 * var(--p));
}

.screen-play .sky-rain::before {
  --p: 14px;
  background: radial-gradient(0.6px 4.5px at 4.5px 7px, #f0f8ffcc 0, #f0f8ff66 45%, transparent 100%) 0 0 / 9px var(--p);
}

.screen-play .sky-rain::after {
  --p: 19px;
  background: radial-gradient(0.6px 3.5px at 6px 9px, #f0f8ff99 0, #f0f8ff44 45%, transparent 100%) 5px 0 / 12px var(--p);
}

.screen-play .clock:is([data-weather="rain"], [data-weather="storm"]) .sky-rain {
  opacity: 0.5;
}

.screen-play .clock:is([data-weather="rain"], [data-weather="storm"]) .sky-rain::before,
.screen-play .clock:is([data-weather="rain"], [data-weather="storm"]) .sky-rain::after {
  animation: clock-rain-fall var(--rain-ms) linear infinite;
}

.screen-play .clock[data-weather="storm"] .sky-rain {
  --rain-ms: 0.38s;
  opacity: 0.65;
}

.screen-play .sky-shade {
  background: #1d2c3d;
  mix-blend-mode: multiply;
  opacity: 0;
  transition: opacity 600ms ease;
}

.screen-play .clock[data-weather="cloud"] .sky-shade { opacity: 0.3; }
.screen-play .clock[data-weather="rain"] .sky-shade { opacity: 0.5; }
.screen-play .clock[data-weather="storm"] .sky-shade { opacity: 0.68; }

.aspect-portrait .screen-play .clock {
  height: var(--clock-lens);
  grid-template-columns: var(--clock-lens) var(--clock-lens);
  grid-template-rows: 100%;
  grid-template-areas: "sky countdown";
  --clock-radius: 6px;
}

.aspect-portrait .screen-play .clock-sky {
  min-height: 0;
  border-radius: var(--clock-radius-inner) 0 0 var(--clock-radius-inner);
}

.aspect-portrait .screen-play .clock-countdown {
  border-radius: 0 var(--clock-radius-inner) var(--clock-radius-inner) 0;
}

@keyframes clock-copy-swap {
  0%, 100% { opacity: 1; transform: none; }
  40% { opacity: 0; transform: translateY(3px); }
  55% { opacity: 0; transform: translateY(-3px); }
}

@keyframes clock-dusk-band {
  0%, 100% { opacity: 0; }
  45% { opacity: 1; }
}

@keyframes clock-twinkle {
  from { opacity: 0.55; }
  to { opacity: 1; }
}

@keyframes clock-cloud-drift {
  from { transform: translateX(-110%); }
  to { transform: translateX(190%); }
}

@keyframes clock-rain-fall {
  to { transform: translateY(var(--p)); }
}

.screen-play .menu-bar {
  background: transparent;
  border-top: 1px solid transparent;
}

.screen-play .menu-bar-row {
  min-height: 60px;
  padding: 0;
  gap: 0;
  overflow: visible;
  box-shadow: none;
  background: var(--skin-panel);
  border: 0;
}

.screen-play .menu-bar button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
  padding: 5px 4px;
  border: 1px solid transparent;
  border-right-color: var(--play-line);
  border-radius: 0;
  background: var(--menu-button-fill, transparent);
  color: var(--text);
  font-size: 12px;
  text-shadow: none;
  filter: none;
}

/* A destination shows its icon over its word, in portrait and landscape alike. */
.screen-play .menu-bar .dest-item {
  flex-direction: column;
  gap: 5px;
  font-size: var(--control-text-size);
  border-right-color: var(--line-faint);
}

@media (hover: hover) {
  .dest-item:where(:enabled:hover) {
    --menu-button-fill: var(--surface-2);
  }
}

/* Move City Here on a cell's preview: the one action, in gold. */
.screen-play .menu-bar button.visit-move {
  background: var(--btn-positive);
  color: var(--btn-positive-ink);
  text-shadow: none;
  font-weight: 600;
}

/* Menu bar layouts (menu_bar.js): the bar's own row and any row a view holds it with. A Back
   (button.js bindBack) holds the left quarter, a gap before what follows: a visit's
   (visit_bar.js), out of an open panel or the radio (hud.js leaveRow), or out of the crest
   editor. .menu-bar-gap pushes what follows it right, .menu-bar-quarter is a quarter wide, and
   .menu-bar-icon is as wide as its icon. */
.screen-play .menu-bar {
  --menu-bar-back-width: 25%;
}

.screen-play .menu-bar .back-btn {
  flex: 0 0 var(--menu-bar-back-width);
  margin-right: 8px;
}

/* leaveRow's way out: the open panel's lent strip Backs, else its Close. */
.screen-play .menu-bar .menu-bar-backs {
  display: contents;
}

.screen-play .menu-bar .menu-bar-backs:has(> .back-btn:not([hidden])) + .menu-bar-close {
  display: none;
}

/* The view's call to action (ui/bar_cta.js) at the right, twice a Back's width. */
.screen-play .menu-bar .menu-bar-cta {
  flex: 0 0 calc(2 * var(--menu-bar-back-width));
  display: flex;
}

.screen-play .menu-bar .menu-bar-cta[hidden] {
  display: none;
}

.screen-play .menu-bar .menu-bar-cta > button {
  flex: 1 1 auto;
}

/* The ready pass: one chevron of lit pixels crosses a green call to action, the bar's (ui/bar_cta.js)
   rightwards and a building's level button (sheet_tools.js paintButton) upwards. It plays once, 200ms
   after the button shows, turns green, or is enabled. The layer is a fixed mosaic of 8px pixels under a mask of
   two layers: a flat one that leaves a hint of every pixel, and the chevron, which moves a pixel a
   step at 320px a second so no pixel is ever half lit. --pass-steps carries it off the far edge of
   the largest button. */
.menu-bar-cta > :is(.go, .positive):enabled::before,
.city-sheet-upgrade[data-ready="true"]::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.18;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='128' height='64' viewBox='0 0 16 8' fill='%23fff' shape-rendering='crispEdges'%3E%3Cpath opacity='.25' d='M3 0h1v1h-1zM13 1h1v1h-1zM8 2h1v1h-1zM6 3h1v1h-1zM4 4h1v1h-1zM10 4h1v1h-1zM11 5h1v1h-1zM7 6h1v1h-1zM12 6h1v1h-1zM1 7h1v1h-1z'/%3E%3Cpath opacity='.38' d='M15 0h1v1h-1zM6 1h1v1h-1zM9 1h1v1h-1zM13 2h1v1h-1zM3 4h1v1h-1zM12 4h1v1h-1zM14 4h1v1h-1zM0 5h1v1h-1zM8 5h1v1h-1z'/%3E%3Cpath opacity='.5' d='M4 1h1v1h-1zM1 2h1v1h-1zM6 2h1v1h-1zM12 2h1v1h-1zM0 3h1v1h-1zM1 3h1v1h-1zM2 3h1v1h-1zM6 4h1v1h-1zM9 4h1v1h-1zM3 5h1v1h-1zM10 5h1v1h-1zM2 6h1v1h-1zM9 6h1v1h-1zM5 7h1v1h-1zM13 7h1v1h-1zM14 7h1v1h-1z'/%3E%3Cpath opacity='.63' d='M6 0h1v1h-1zM10 0h1v1h-1zM14 0h1v1h-1zM11 1h1v1h-1zM12 1h1v1h-1zM15 1h1v1h-1zM3 2h1v1h-1zM2 4h1v1h-1zM8 4h1v1h-1zM2 5h1v1h-1zM15 5h1v1h-1zM3 6h1v1h-1z'/%3E%3Cpath opacity='.75' d='M11 0h1v1h-1zM0 1h1v1h-1zM3 1h1v1h-1zM5 1h1v1h-1zM5 3h1v1h-1zM9 3h1v1h-1zM6 5h1v1h-1zM4 6h1v1h-1zM8 6h1v1h-1zM0 7h1v1h-1zM11 7h1v1h-1zM15 7h1v1h-1z'/%3E%3Cpath opacity='.88' d='M0 0h1v1h-1zM2 0h1v1h-1zM7 0h1v1h-1zM9 0h1v1h-1zM2 2h1v1h-1zM5 2h1v1h-1zM9 2h1v1h-1zM11 2h1v1h-1zM3 3h1v1h-1zM8 3h1v1h-1zM12 3h1v1h-1zM5 4h1v1h-1zM5 5h1v1h-1zM12 5h1v1h-1zM6 6h1v1h-1zM10 6h1v1h-1zM14 6h1v1h-1zM3 7h1v1h-1zM10 7h1v1h-1z'/%3E%3Cpath opacity='1.0' d='M1 0h1v1h-1zM4 0h1v1h-1zM13 0h1v1h-1zM2 1h1v1h-1zM8 1h1v1h-1zM10 1h1v1h-1zM10 3h1v1h-1zM7 4h1v1h-1zM13 5h1v1h-1zM14 5h1v1h-1zM1 6h1v1h-1zM13 6h1v1h-1z'/%3E%3C/svg%3E") var(--pass-pixels-at);
  mask: var(--pass-chevron) var(--pass-from) no-repeat, linear-gradient(rgb(0 0 0 / 0.06) 0 0);
  animation: ready-pass calc(var(--pass-steps) * 25ms) steps(var(--pass-steps)) 200ms both;
}

.menu-bar-cta > :is(.go, .positive)::before {
  --pass-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='248' height='80' viewBox='0 0 31 10' fill='%23fff' shape-rendering='crispEdges'%3E%3Cpath opacity='.12' d='M0 0h1v1h-1zM1 1h1v1h-1zM2 2h1v1h-1zM3 3h1v1h-1zM4 4h1v1h-1zM4 5h1v1h-1zM3 6h1v1h-1zM2 7h1v1h-1zM1 8h1v1h-1zM0 9h1v1h-1z'/%3E%3Cpath opacity='.13' d='M1 0h1v1h-1zM2 1h1v1h-1zM3 2h1v1h-1zM4 3h1v1h-1zM5 4h1v1h-1zM5 5h1v1h-1zM4 6h1v1h-1zM3 7h1v1h-1zM2 8h1v1h-1zM1 9h1v1h-1z'/%3E%3Cpath opacity='.15' d='M2 0h1v1h-1zM3 1h1v1h-1zM4 2h1v1h-1zM5 3h1v1h-1zM6 4h1v1h-1zM6 5h1v1h-1zM5 6h1v1h-1zM4 7h1v1h-1zM3 8h1v1h-1zM2 9h1v1h-1z'/%3E%3Cpath opacity='.16' d='M3 0h1v1h-1zM4 1h1v1h-1zM5 2h1v1h-1zM6 3h1v1h-1zM7 4h1v1h-1zM7 5h1v1h-1zM6 6h1v1h-1zM5 7h1v1h-1zM4 8h1v1h-1zM3 9h1v1h-1z'/%3E%3Cpath opacity='.18' d='M4 0h1v1h-1zM5 1h1v1h-1zM6 2h1v1h-1zM7 3h1v1h-1zM8 4h1v1h-1zM8 5h1v1h-1zM7 6h1v1h-1zM6 7h1v1h-1zM5 8h1v1h-1zM4 9h1v1h-1z'/%3E%3Cpath opacity='.2' d='M5 0h1v1h-1zM6 1h1v1h-1zM7 2h1v1h-1zM8 3h1v1h-1zM9 4h1v1h-1zM9 5h1v1h-1zM8 6h1v1h-1zM7 7h1v1h-1zM6 8h1v1h-1zM5 9h1v1h-1z'/%3E%3Cpath opacity='.23' d='M6 0h1v1h-1zM7 1h1v1h-1zM8 2h1v1h-1zM9 3h1v1h-1zM10 4h1v1h-1zM10 5h1v1h-1zM9 6h1v1h-1zM8 7h1v1h-1zM7 8h1v1h-1zM6 9h1v1h-1z'/%3E%3Cpath opacity='.25' d='M7 0h1v1h-1zM8 1h1v1h-1zM9 2h1v1h-1zM10 3h1v1h-1zM11 4h1v1h-1zM11 5h1v1h-1zM10 6h1v1h-1zM9 7h1v1h-1zM8 8h1v1h-1zM7 9h1v1h-1z'/%3E%3Cpath opacity='.28' d='M8 0h1v1h-1zM9 1h1v1h-1zM10 2h1v1h-1zM11 3h1v1h-1zM12 4h1v1h-1zM12 5h1v1h-1zM11 6h1v1h-1zM10 7h1v1h-1zM9 8h1v1h-1zM8 9h1v1h-1z'/%3E%3Cpath opacity='.31' d='M9 0h1v1h-1zM10 1h1v1h-1zM11 2h1v1h-1zM12 3h1v1h-1zM13 4h1v1h-1zM13 5h1v1h-1zM12 6h1v1h-1zM11 7h1v1h-1zM10 8h1v1h-1zM9 9h1v1h-1z'/%3E%3Cpath opacity='.34' d='M10 0h1v1h-1zM11 1h1v1h-1zM12 2h1v1h-1zM13 3h1v1h-1zM14 4h1v1h-1zM14 5h1v1h-1zM13 6h1v1h-1zM12 7h1v1h-1zM11 8h1v1h-1zM10 9h1v1h-1z'/%3E%3Cpath opacity='.38' d='M11 0h1v1h-1zM12 1h1v1h-1zM13 2h1v1h-1zM14 3h1v1h-1zM15 4h1v1h-1zM15 5h1v1h-1zM14 6h1v1h-1zM13 7h1v1h-1zM12 8h1v1h-1zM11 9h1v1h-1z'/%3E%3Cpath opacity='.41' d='M12 0h1v1h-1zM13 1h1v1h-1zM14 2h1v1h-1zM15 3h1v1h-1zM16 4h1v1h-1zM16 5h1v1h-1zM15 6h1v1h-1zM14 7h1v1h-1zM13 8h1v1h-1zM12 9h1v1h-1z'/%3E%3Cpath opacity='.45' d='M13 0h1v1h-1zM14 1h1v1h-1zM15 2h1v1h-1zM16 3h1v1h-1zM17 4h1v1h-1zM17 5h1v1h-1zM16 6h1v1h-1zM15 7h1v1h-1zM14 8h1v1h-1zM13 9h1v1h-1z'/%3E%3Cpath opacity='.48' d='M14 0h1v1h-1zM15 1h1v1h-1zM16 2h1v1h-1zM17 3h1v1h-1zM18 4h1v1h-1zM18 5h1v1h-1zM17 6h1v1h-1zM16 7h1v1h-1zM15 8h1v1h-1zM14 9h1v1h-1z'/%3E%3Cpath opacity='.52' d='M15 0h1v1h-1zM16 1h1v1h-1zM17 2h1v1h-1zM18 3h1v1h-1zM19 4h1v1h-1zM19 5h1v1h-1zM18 6h1v1h-1zM17 7h1v1h-1zM16 8h1v1h-1zM15 9h1v1h-1z'/%3E%3Cpath opacity='.57' d='M16 0h1v1h-1zM17 1h1v1h-1zM18 2h1v1h-1zM19 3h1v1h-1zM20 4h1v1h-1zM20 5h1v1h-1zM19 6h1v1h-1zM18 7h1v1h-1zM17 8h1v1h-1zM16 9h1v1h-1z'/%3E%3Cpath opacity='.61' d='M17 0h1v1h-1zM18 1h1v1h-1zM19 2h1v1h-1zM20 3h1v1h-1zM21 4h1v1h-1zM21 5h1v1h-1zM20 6h1v1h-1zM19 7h1v1h-1zM18 8h1v1h-1zM17 9h1v1h-1z'/%3E%3Cpath opacity='.65' d='M18 0h1v1h-1zM19 1h1v1h-1zM20 2h1v1h-1zM21 3h1v1h-1zM22 4h1v1h-1zM22 5h1v1h-1zM21 6h1v1h-1zM20 7h1v1h-1zM19 8h1v1h-1zM18 9h1v1h-1z'/%3E%3Cpath opacity='.7' d='M19 0h1v1h-1zM20 1h1v1h-1zM21 2h1v1h-1zM22 3h1v1h-1zM23 4h1v1h-1zM23 5h1v1h-1zM22 6h1v1h-1zM21 7h1v1h-1zM20 8h1v1h-1zM19 9h1v1h-1z'/%3E%3Cpath opacity='.75' d='M20 0h1v1h-1zM21 1h1v1h-1zM22 2h1v1h-1zM23 3h1v1h-1zM24 4h1v1h-1zM24 5h1v1h-1zM23 6h1v1h-1zM22 7h1v1h-1zM21 8h1v1h-1zM20 9h1v1h-1z'/%3E%3Cpath opacity='.79' d='M21 0h1v1h-1zM22 1h1v1h-1zM23 2h1v1h-1zM24 3h1v1h-1zM25 4h1v1h-1zM25 5h1v1h-1zM24 6h1v1h-1zM23 7h1v1h-1zM22 8h1v1h-1zM21 9h1v1h-1z'/%3E%3Cpath opacity='.84' d='M22 0h1v1h-1zM23 1h1v1h-1zM24 2h1v1h-1zM25 3h1v1h-1zM26 4h1v1h-1zM26 5h1v1h-1zM25 6h1v1h-1zM24 7h1v1h-1zM23 8h1v1h-1zM22 9h1v1h-1z'/%3E%3Cpath opacity='.89' d='M23 0h1v1h-1zM24 1h1v1h-1zM25 2h1v1h-1zM26 3h1v1h-1zM27 4h1v1h-1zM27 5h1v1h-1zM26 6h1v1h-1zM25 7h1v1h-1zM24 8h1v1h-1zM23 9h1v1h-1z'/%3E%3Cpath opacity='.95' d='M24 0h1v1h-1zM25 1h1v1h-1zM26 2h1v1h-1zM27 3h1v1h-1zM28 4h1v1h-1zM28 5h1v1h-1zM27 6h1v1h-1zM26 7h1v1h-1zM25 8h1v1h-1zM24 9h1v1h-1z'/%3E%3Cpath opacity='1.0' d='M25 0h1v1h-1zM26 1h1v1h-1zM27 2h1v1h-1zM28 3h1v1h-1zM29 4h1v1h-1zM29 5h1v1h-1zM28 6h1v1h-1zM27 7h1v1h-1zM26 8h1v1h-1zM25 9h1v1h-1z'/%3E%3C/svg%3E");
  --pass-pixels-at: 0 50%;
  --pass-from: -248px 50%;
  --pass-to: 360px 50%;
  --pass-steps: 76;
}

.city-sheet-upgrade[data-ready="true"]::before {
  --pass-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='136' viewBox='0 0 6 17' fill='%23fff' shape-rendering='crispEdges'%3E%3Cpath opacity='.13' d='M0 16h1v1h-1zM1 15h1v1h-1zM2 14h1v1h-1zM3 14h1v1h-1zM4 15h1v1h-1zM5 16h1v1h-1z'/%3E%3Cpath opacity='.16' d='M0 15h1v1h-1zM1 14h1v1h-1zM2 13h1v1h-1zM3 13h1v1h-1zM4 14h1v1h-1zM5 15h1v1h-1z'/%3E%3Cpath opacity='.19' d='M0 14h1v1h-1zM1 13h1v1h-1zM2 12h1v1h-1zM3 12h1v1h-1zM4 13h1v1h-1zM5 14h1v1h-1z'/%3E%3Cpath opacity='.24' d='M0 13h1v1h-1zM1 12h1v1h-1zM2 11h1v1h-1zM3 11h1v1h-1zM4 12h1v1h-1zM5 13h1v1h-1z'/%3E%3Cpath opacity='.29' d='M0 12h1v1h-1zM1 11h1v1h-1zM2 10h1v1h-1zM3 10h1v1h-1zM4 11h1v1h-1zM5 12h1v1h-1z'/%3E%3Cpath opacity='.35' d='M0 11h1v1h-1zM1 10h1v1h-1zM2 9h1v1h-1zM3 9h1v1h-1zM4 10h1v1h-1zM5 11h1v1h-1z'/%3E%3Cpath opacity='.41' d='M0 10h1v1h-1zM1 9h1v1h-1zM2 8h1v1h-1zM3 8h1v1h-1zM4 9h1v1h-1zM5 10h1v1h-1z'/%3E%3Cpath opacity='.48' d='M0 9h1v1h-1zM1 8h1v1h-1zM2 7h1v1h-1zM3 7h1v1h-1zM4 8h1v1h-1zM5 9h1v1h-1z'/%3E%3Cpath opacity='.55' d='M0 8h1v1h-1zM1 7h1v1h-1zM2 6h1v1h-1zM3 6h1v1h-1zM4 7h1v1h-1zM5 8h1v1h-1z'/%3E%3Cpath opacity='.63' d='M0 7h1v1h-1zM1 6h1v1h-1zM2 5h1v1h-1zM3 5h1v1h-1zM4 6h1v1h-1zM5 7h1v1h-1z'/%3E%3Cpath opacity='.72' d='M0 6h1v1h-1zM1 5h1v1h-1zM2 4h1v1h-1zM3 4h1v1h-1zM4 5h1v1h-1zM5 6h1v1h-1z'/%3E%3Cpath opacity='.81' d='M0 5h1v1h-1zM1 4h1v1h-1zM2 3h1v1h-1zM3 3h1v1h-1zM4 4h1v1h-1zM5 5h1v1h-1z'/%3E%3Cpath opacity='.9' d='M0 4h1v1h-1zM1 3h1v1h-1zM2 2h1v1h-1zM3 2h1v1h-1zM4 3h1v1h-1zM5 4h1v1h-1z'/%3E%3Cpath opacity='1.0' d='M0 3h1v1h-1zM1 2h1v1h-1zM2 1h1v1h-1zM3 1h1v1h-1zM4 2h1v1h-1zM5 3h1v1h-1z'/%3E%3C/svg%3E");
  --pass-pixels-at: 50% 0;
  --pass-from: 50% 104px;
  --pass-to: 50% -136px;
  --pass-steps: 30;
}

@keyframes ready-pass {
  from {
    mask-position: var(--pass-from), 0 0;
  }
  to {
    mask-position: var(--pass-to), 0 0;
  }
}

.screen-play .menu-bar .menu-bar-gap {
  flex: 1;
}

.screen-play .menu-bar .menu-bar-quarter {
  flex: 0 0 25%;
}

.screen-play .menu-bar .menu-bar-icon {
  flex: 0 0 52px;
}

/* A line under the resource bar and over the menu bar frames the destination filling the view. */
.screen-play.filled .top-bar {
  border-bottom: 1px solid var(--play-line);
}

.screen-play.filled .menu-bar {
  border-top-color: var(--play-line);
}

/* Attack while scouting a raider city on the map: the one action, in red. */
.screen-play .menu-bar button.visit-attack {
  background: var(--btn-negative);
  color: var(--btn-negative-ink);
  text-shadow: none;
  font-weight: 600;
}

.screen-play .menu-bar .dest-item .i {
  width: 24px;
  height: 24px;
  color: var(--text);
}

/* The shared selected look: the active menu button, the one a notification rises over
   (notifications.js), a pressed filter chip, the tile a detail shows (a floor plan's chosen
   Build tile), and the crest editor's chosen flag, pattern, or charge. */
.screen-play .menu-bar button.active,
.screen-play .menu-bar button[aria-current="page"],
.screen-play .menu-bar button.is-notified,
.filter-chip[aria-pressed="true"],
.screen-play button.btn.neutral.filter-chip[aria-pressed="true"],
.screen-play button.btn.neutral.filter-chip[aria-checked="true"],
.screen-play .inv-tile.selected,
.screen-play .inv-tile.selected:hover,
.screen-play .crest-tile[aria-pressed="true"],
.screen-play .crest-row[aria-selected="true"] {
  color: var(--selected-ink);
  background: var(--selected-fill);
  border-color: var(--selected-line);
  box-shadow: var(--selected-glow);
}

.screen-play .menu-bar button.active .i,
.screen-play .menu-bar button[aria-current="page"] .i,
.screen-play .menu-bar button.is-notified .i {
  color: var(--gold-200);
}

html.aspect-portrait .screen-play .menu-bar {
  /* Fullscreen app: the tabs sit above the gesture strip, which takes their colour. */
  padding: 0 0 env(safe-area-inset-bottom);
  background: var(--skin-panel);
}

html.aspect-portrait .screen-play .top-bar {
  margin: 0;
  /* iOS blurs the top of an installed app unless a full-width sticky or fixed element
     sits there; it then fills the status bar strip with that element's background. */
  position: sticky;
  top: 0;
  /* The installed app runs fullscreen: keep chips below a camera cutout. */
  padding: calc(4px + env(safe-area-inset-top)) 8px 5px;
  border-top: 0;
  border-left: 0;
  border-right: 0;
  border-radius: 0;
}

html.aspect-portrait .screen-play .chips {
  gap: 0;
}

html.aspect-portrait .screen-play .res {
  --res-icon-size: 18px;
  gap: 2px 3px;
  min-height: 52px;
  padding: 4px 2px;
}

html.aspect-portrait .screen-play .res-name {
  font-size: var(--caption-text-size);
}

html.aspect-portrait .screen-play .res-line {
  flex-wrap: wrap;
  gap: 0 3px;
}

html.aspect-portrait .screen-play .res-val {
  font-size: 18px;
}

html.aspect-portrait .screen-play .res-flag {
  font-size: 10px;
}

html.aspect-portrait .screen-play .menu-bar-row {
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
}

/* The portrait bar runs to the screen's edges, so its last button's badge sits inside the edge
   instead of hanging past it. */
html.aspect-portrait .screen-play .menu-bar button:last-child .badge {
  right: 4px;
}

html.aspect-portrait .screen-play .city-sheet-title {
  font-size: 24px;
}

.screen-play .tool {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: var(--control-height);
  padding: 0 10px;
  border-radius: var(--control-radius);
  border: 1px solid var(--btn-neutral);
  background: var(--btn-neutral);
  color: var(--btn-neutral-ink);
  font-size: 14px;
  box-shadow: var(--shadow-card);
  text-shadow: none;
}

:where(.aspect-portrait) .screen-play .build-tool {
  min-height: calc(2 * var(--control-height));
}

.screen-play .debug-btn {
  width: 24px;
  height: 24px;
  align-self: flex-end;
}

.screen-play .debug-btn.active {
  border-color: #80a8b4;
  background: linear-gradient(#304955, #1b3038);
}

.screen-play .panel.sheet {
  padding: 8px 14px 10px;
  background: var(--surface-panel);
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  box-shadow: var(--shadow-sheet);
  color: var(--text);
}

:is(.screen-play, .screen-title, .screen-designer) .panel h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--panel-title-size);
  line-height: 1.1;
  color: var(--text);
  text-shadow: 0 2px 2px #000a;
}

html.aspect-portrait .screen-play .panel.sheet {
  width: 100%;
  border-radius: 0;
  border-left: 0;
  border-right: 0;
}

/* A bottom panel rests on the menu bar: the bar's own top padding (--menu-inset) is the gap,
   the same as the one under the bar. */
.screen-play .bottom-panel {
  --panel-strip-room: calc(var(--icon-control-size) + 12px);
  padding-top: calc(var(--panel-pad) + var(--panel-strip-room));
  padding-bottom: 0;
}

/* Bottom panels hold one height whatever tab or content is showing: the space between the
   top row and the menu bar, capped at --panel-fixed-max. The tab strip stays put when the pane changes. */
.screen-play .bottom-panel .panel {
  flex: 0 0 auto;
  width: var(--play-width);
  height: min(100%, var(--panel-fixed-max));
}

:is(.screen-play .bottom-panel .panel, :is(.screen-title, .screen-designer) .menu-box .panel, .screen-play :is(.crest-designer, .confirm-slide)) {
  background: var(--surface-panel);
  border: 0;
  border-top: 5px solid var(--skin-accent);
  border-radius: var(--panel-radius);
  box-shadow: var(--shadow-sheet);
}

:is(.screen-title, .screen-designer) .menu-box .panel {
  padding: var(--panel-inset);
}

/* One inset around whatever a bottom sheet holds. The top strip (.panel-tabline) is
   absolutely positioned, so the padding only moves the content. */
.screen-play .bottom-panel .panel.sheet {
  padding: var(--panel-inset);
}

/* Every tab pane scrolls the same way: the pane is the scroller, with a thin bar that
   keeps its gutter so rows sit at the same width whether or not the pane overflows. */
.screen-play .panel-pane {
  scrollbar-width: thin;
  scrollbar-color: var(--scroll) transparent;
  scrollbar-gutter: stable;
  padding-right: 6px;
}

.screen-play #alliance-panel:not(.alliance-notices-read) .alliance-notice-list-scroll {
  overflow: visible;
  flex: 0 0 auto;
}

.screen-play .alliance-notice-list {
  padding-right: 0;
}

.screen-play .member-copy {
  min-width: 0;
}

.screen-play .debug-btn {
  background: var(--btn-neutral-face);
  color: var(--text);
  border: 1px solid var(--play-line-strong);
  border-radius: var(--control-radius);
}

.screen-play .menu-bar button:first-child { border-radius: var(--panel-radius-inner) 0 0 var(--panel-radius-inner); }
.screen-play .menu-bar button:last-child { border-radius: 0 var(--panel-radius-inner) var(--panel-radius-inner) 0; border-right-color: transparent; }

.screen-play .member {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 12px;
  padding: 6px 3px;
  margin: 0;
  border-top: 1px solid var(--play-line);
  color: var(--text);
  cursor: pointer;
}

.screen-play .look {
  position: relative;
  width: 80px;
  height: 82px;
  border-radius: 3px;
  background: var(--portrait-ground);
  overflow: hidden;
}

.screen-play .call-head .look {
  width: 64px;
  height: 65.6px;
}

.screen-play .call-box:not(.has-calls) .look {
  filter: grayscale(1);
}

.screen-play .look canvas,
.screen-play .look img {
  width: 100%;
  height: 100%;
  display: block;
}

/* Settler profile (panels/settler_profile.js): the whole portrait beside the
   name line, then the XP budget and one card per skill. Phones stack it. */
.screen-play .settler-profile-top {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

/* settler_profile.js sets the aspect from the figure it frames. */
.screen-play .settler-profile-portrait {
  position: relative;
  width: 180px;
  border-radius: 3px;
  background: var(--portrait-ground);
  overflow: hidden;
}

.screen-play .settler-profile-head,
.screen-play .settler-profile-afflictions,
.screen-play .settler-profile-xp,
.screen-play .settler-skill {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.screen-play .settler-profile-afflictions {
  align-items: flex-start;
}

.screen-play .settler-profile-xp {
  margin-top: 14px;
  gap: 8px;
}

.screen-play .settler-skill-top {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.screen-play .settler-skill-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
}

.screen-play .settler-skill-tag {
  font-family: var(--font-ui);
  font-size: var(--meta-text-size);
}

/* The amber XP still needed, after a skill's title. */
.screen-play .settler-skill-togo {
  color: var(--warn);
  font-family: var(--font-ui);
  font-size: var(--meta-text-size);
  font-weight: 500;
}

.screen-play .settler-skill-xp {
  margin-left: auto;
}

/* A skill's bar: one step per level, each as wide as its share of the XP to
   the top level (--span). */
.screen-play .level-steps {
  display: flex;
  gap: 3px;
}

.screen-play .level-steps .meter {
  flex: var(--span) 1 0;
  min-width: 4px;
}

.screen-play .settler-skill-earn {
  margin: 0;
  padding-left: 1.2em;
  color: var(--muted);
  font-size: var(--meta-text-size);
}

.screen-play .settler-skill-how {
  color: var(--muted);
  font-size: var(--caption-text-size);
}

.screen-play .settler-skill-warn {
  color: var(--warn);
  font-size: var(--meta-text-size);
}

.screen-play .member-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.screen-play .member-name {
  margin: 0;
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 20px;
  line-height: 1.1;
  color: var(--text);
  text-shadow: 0 2px 2px #0009;
}

.screen-play .member-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 1 auto;
  order: 0;
  flex-wrap: wrap;
}

.screen-play .member-meta {
  margin-left: auto;
  order: 1;
  color: var(--muted);
  font-size: var(--meta-text-size);
  white-space: nowrap;
}

.screen-play .pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: var(--compact-control-height);
  padding: 0 8px;
  border-radius: 5px;
  border: 1px solid #52997766;
  background: linear-gradient(#28543cbb, #173d2c99);
  color: var(--ok-text);
  font-size: 13px;
  white-space: nowrap;
}

.screen-play .xp-line {
  margin-block: 2px;
  color: #c4dbef;
  font-size: 14px;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.screen-play .traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.screen-play .trait {
  flex: 1 1 auto;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  min-height: var(--compact-control-height);
  padding: 0 8px;
  border-radius: 5px;
  border: 1px solid var(--play-line);
  background: linear-gradient(110deg, #21343d, #1c2c35);
  color: var(--text);
  font-size: 13px;
  white-space: nowrap;
  text-shadow: 0 1px 2px #000;
}

.screen-play .trait::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: calc(var(--fill, 0) * 100%);
  background: linear-gradient(#8e743c99, #67532a99);
  z-index: -1;
  pointer-events: none;
}

.screen-play .trait[data-tone="alert"]::before {
  background: color-mix(in srgb, var(--alert) 30%, transparent);
}

.screen-play .trait.is-locked {
  color: var(--muted);
}

.screen-play .meter {
  height: 10px;
  border-radius: 999px;
  border: 1px solid var(--well-line);
  background: var(--surface-well);
  box-shadow: inset 0 1px 3px #0005;
  overflow: hidden;
}

.screen-play .meter > span {
  display: block;
  height: 100%;
  width: var(--fill, 0%);
  border-radius: inherit;
  background: var(--meter-fill);
  box-shadow: inset 0 1px 2px #ffffddbb;
  transition: width 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.screen-play .meter[data-tone="info"] > span {
  background: linear-gradient(#9ce8ff, #56b8ed 60%, #589ddb);
}

.screen-play .meter[data-tone="alert"] > span {
  background: linear-gradient(#ffb1b5, #d96c77);
}

.screen-play .card,
.screen-play .city-sheet.card,
.screen-play .city-sheet-card,
.screen-play .map-cell-sheet {
  background: var(--surface-panel);
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  box-shadow: var(--shadow-card);
  color: var(--text);
}

.screen-play .city-sheet-card {
  display: grid;
  grid-row: 1 / 3;
  grid-template-rows: subgrid;
  width: auto;
  position: relative;
  min-width: 0;
  padding: 0;
  box-shadow: none;
  background: var(--skin-panel);
  border: 0;
}

.city-sheet-content { grid-row: 2; padding: var(--city-sheet-content-pad); }
:where(.city-sheet-card:has(.card-status[hidden])) .city-sheet-content { grid-row: 1 / 3; }

.screen-play .card[data-tone="info"] { --tone: var(--info); border-color: var(--tone); }
.screen-play .card[data-tone="ready"] { --tone: var(--gold-200); border-color: var(--tone); }
.screen-play .card[data-tone="alert"] { --tone: var(--alert); border-color: var(--tone); }
.screen-play .card[data-tone="warn"] { --tone: var(--warn); border-color: var(--tone); }
.screen-play .card[data-tone="ok"] { --tone: var(--ok); border-color: var(--tone); }
.screen-play .card[data-tone="save"] { --tone: var(--save); border-color: var(--tone); }

.city-sheet-tools .icon-btn {
  width: var(--city-sheet-tool-width);
  height: auto;
  min-height: var(--city-sheet-tool-width);
}

.city-sheet-tools .city-sheet-upgrade {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 3px;
  height: auto;
  min-height: calc(var(--city-sheet-tool-width) * 2);
  padding: 6px 2px;
  font-family: var(--font-ui);
  text-shadow: none;
}

.city-sheet-upgrade[data-ready="true"] {
  isolation: isolate;
  --btn-neutral-face: var(--btn-go);
  --play-line-strong: var(--ok);
  --text: var(--btn-go-ink);
}

/* Short of goods chits can buy (pip.js readyTabs buy): the amber of a
   start that buys its shortfall (button.js bindStart). */
.city-sheet-upgrade[data-ready="buy"] {
  --btn-neutral-face: var(--warn);
  --play-line-strong: var(--btn-caution-fill);
  --text: var(--btn-caution-ink);
}

.city-sheet-level-caption { font-size: var(--caption-text-size); line-height: 1; }
.city-sheet-level-value { font-size: 28px; font-weight: 600; line-height: 1; }

/* A building on its last rung (sheet_tools.js paintButton): a plaque, not a
   button. MAX stands where the upgrade arrow was. */
.city-sheet-tools .city-sheet-upgrade[data-max] {
  opacity: 1;
  border-color: transparent;
  cursor: default;
}
.city-sheet-level-max { font-size: 13px; font-weight: 700; line-height: 20px; letter-spacing: 0.04em; }

/* The inventory's titled boxes (inventory_box.js): Consumables' food and fuel, Troops' clankers
   and troops. */
.screen-play .inv-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 12px;
}

.screen-play .inv-box-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 18px;
}

.screen-play .consumable-box {
  --chip-fill: var(--tone);
  position: relative;
}

.screen-play .consumable-rates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 12px;
  margin: 0;
}

.screen-play .consumable-rates dt {
  font-family: var(--font-ui);
  font-size: var(--caption-text-size);
  color: var(--muted);
}

.screen-play .consumable-rates dd {
  margin: 0;
  font-family: var(--font-ui);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.screen-play .consumable-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--meta-text-size);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.screen-play .consumable-note {
  margin: 0;
  font-size: 14px;
}

.screen-play .consumable-tips {
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
}

.screen-play .consumable-lead {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--tone);
}

.screen-play .production-orbit { display: none; }

.screen-play .card[data-producing] > .production-orbit {
  display: block;
  position: absolute;
  inset: -2px;
  padding: 2px;
  border-radius: inherit;
  overflow: hidden;
  pointer-events: none;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
}

.screen-play .production-orbit::before {
  content: "";
  position: absolute;
  inset: -50%;
  background: conic-gradient(from 45deg, transparent 0deg 275deg, #78d5fa20 300deg, #a5e8ff80 330deg, #e3faffcc 345deg, transparent 360deg);
  animation: production-orbit 8s linear infinite;
}

.screen-play .card[data-producing] .meter > span {
  position: relative;
  overflow: hidden;
}

.screen-play .card[data-producing] .meter > span::after,
.screen-play button.btn.processing::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 40%;
  background: linear-gradient(90deg, transparent, #ffffff4d, transparent);
  transform: translateX(-150%) skewX(-20deg);
  opacity: 0;
  pointer-events: none;
  animation: activity-shimmer 5.5s ease-in-out infinite;
}

.screen-play button.btn.processing::after {
  animation-duration: 2s;
  animation-delay: -.8s;
}

@keyframes production-orbit { to { transform: rotate(360deg); } }

@keyframes activity-shimmer {
  0%, 38% { transform: translateX(-150%) skewX(-20deg); opacity: 0; }
  46%, 68% { opacity: 1; }
  78%, 100% { transform: translateX(400%) skewX(-20deg); opacity: 0; }
}

.screen-play .card-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -8px -12px 5px;
  padding: 4px 12px 4px 6px;
  border-bottom: 1px solid var(--tone, var(--play-line));
  background: color-mix(in srgb, var(--tone, var(--info)) 10%, transparent);
  color: var(--tone, var(--text));
  font-weight: 500;
  font-size: 14px;
  line-height: 18px;
  border-radius: 0;
}

.screen-play .card[data-tone="ok"] .card-status {
  color: var(--ok-text);
}

.city-sheet-card .card-status { grid-row: 1; margin: 0; }
.city-sheet-line { flex: 1; min-width: 0; }
.city-sheet-eta {
  flex: none;
  margin-left: auto;
  color: var(--text);
  font-size: 22px;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.city-sheet-eta[data-never="true"] { color: var(--alert); }

/* A turret base under its weapon system and the weapon's Manage: the card's
   foot, set off from the weapon above like the head is from the title. */
.screen-play .city-sheet-base {
  border-top: 1px solid var(--tone, var(--play-line));
  background: color-mix(in srgb, var(--surface-0) 70%, transparent);
  margin: 8px -18px -12px;
  padding: 12px 18px;
  border-radius: 0;
}

/* The head's badge is the building's pip, opened up: it keeps the pip's tone. */
.screen-play .card-pip {
  display: flex;
  flex: none;
  color: var(--tone);
}

.screen-play .card-title,
.screen-play .city-sheet-title,
.screen-play .map-cell-sheet-title,
.screen-play .top-panel-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--card-title-size);
  line-height: 1.1;
  color: var(--text);
  text-shadow: 0 2px 2px #000;
}

.screen-play .city-sheet-title {
  width: max-content;
  white-space: nowrap;
  font-size: 30px;
  text-transform: uppercase;
}

.city-sheet-card .city-sheet-title {
  width: auto;
  min-width: 0;
  white-space: normal;
}

.screen-play .card-meta,
.screen-play .city-sheet-sub {
  margin: 4px 0 0;
  font-family: var(--font-ui);
  font-size: var(--meta-text-size);
  line-height: 1.1;
  color: var(--muted);
}

.screen-play .card-line {
  margin: 3px 0 5px;
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.1;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.screen-play :where(.city-sheet, .city-sheet-card) .meter {
  height: 12px;
}

/* Site card: a bar per carried resource. A site bar is a
   segment per load, filled as the load lands. Out bars have nothing left to
   carry. Columns: name, meter, quantity. Crew slots share the meter's column. */
.city-sheet-work {
  display: none;
  grid-template-columns: max-content 1fr max-content;
  align-items: center;
  gap: 5px var(--city-sheet-gap);
  margin: 6px 0 2px;
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.1;
}

.city-sheet-work:where(:has(> :not([hidden]))) { display: grid; }

.screen-play .city-sheet-site { display: contents; }

.screen-play .city-sheet-site[hidden] {
  display: none;
}

.screen-play :is(.site-bars, .site-bar) {
  display: contents;
}

.screen-play .site-bar-name {
  color: var(--text);
}

.screen-play .site-bar-meter {
  height: 8px;
}

.screen-play .site-bar-qty {
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

/* Out: the unfilled track is hatched, so the missing part reads as stuck. */
.screen-play .site-bar[data-outlook="out"] .site-bar-meter:not([data-segs="true"]) {
  border-color: color-mix(in srgb, var(--alert) 60%, transparent);
  background: repeating-linear-gradient(135deg, #3a2328 0 4px, var(--surface-2) 4px 8px);
}

.screen-play .site-bar[data-outlook="out"] .site-bar-meter:not([data-segs="true"]) > span,
.screen-play .site-bar[data-outlook="out"] .site-bar-meter[data-segs="true"] > span[data-done="true"] {
  background: linear-gradient(#ffb1b5, #d96c77);
}

.screen-play .site-bar[data-outlook="out"] .site-bar-meter[data-segs="true"] > span[data-done="false"] {
  border-color: color-mix(in srgb, var(--alert) 60%, transparent);
  background: repeating-linear-gradient(135deg, #3a2328 0 4px, var(--surface-2) 4px 8px);
}

.screen-play .site-bar[data-outlook="out"] :is(.site-bar-name, .site-bar-qty) {
  color: var(--alert);
}

/* A segmented bar drops the meter chrome and draws a segment per load, gold
   once that load has landed. */
.screen-play .site-bar-meter[data-segs="true"] {
  display: flex;
  gap: 2px;
  height: 10px;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
}

.screen-play .site-bar-meter[data-segs="true"] > span {
  flex: 1;
  width: auto;
  height: auto;
  min-width: 2px;
  border-radius: 2px;
  border: 1px solid var(--well-line);
  background: var(--surface-well);
  box-shadow: none;
  transition: none;
}

.screen-play .site-bar-meter[data-segs="true"] > span[data-done="true"] {
  border-color: transparent;
  background: var(--meter-fill);
}

.screen-play :is(.city-sheet, .city-sheet-card) .card-actions,
.screen-play #city-sheet-craft {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.screen-play :is(.city-sheet, .city-sheet-card) button:not(.seat):not(.icon-btn),
.screen-play .map-cell-sheet button {
  display: flex;
  width: 100%;
  min-height: var(--control-height);
}

/* Buttons are block-level, so each sheet sizes to its widest row, not to its
   buttons laid end to end, and a label change cannot move it. A row of loot
   pills wraps at the max width rather than stretching the sheet. */
.screen-play .map-cell-sheet {
  min-width: 220px;
  max-width: min(420px, calc(100vw - 32px));
}

.screen-play :is(.city-sheet, .city-sheet-card) .card-actions button {
  margin-top: 0;
}

.city-sheet-actions {
  display: none;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: var(--city-sheet-gap);
  margin-top: 12px;
}

.city-sheet-actions:where(:has(> button:not([hidden]))) { display: grid; }
/* Each button spans the row. Cancel takes the right half beside Manage;
   Harvest takes the rest of Discard's row, so it holds the bottom-right corner. */
.city-sheet-actions > :where(button) { grid-column: 1 / -1; }
.city-sheet-discard { grid-column: 1 / 3; }
:where(.city-sheet-actions:has(> .city-sheet-discard:not([hidden]))) > .city-sheet-harvest { grid-column: 3 / -1; }
.city-sheet-cancel { grid-column: 4 / -1; }
:where(.city-sheet-actions:has(> .city-sheet-cancel:not([hidden]))) > .city-sheet-manage { grid-column: 1 / 4; }

.screen-play .radio-host,
.screen-play .radio-dock {
  background: var(--surface-panel);
  color: var(--text);
}

.screen-play .chat-thread-header h2,
.screen-play .chat-room,
.screen-play .chat-bubble-name,
.screen-play .chat-bubble-body {
  font-family: var(--font-body);
  color: var(--text);
}

.screen-play .chat-bubble-name {
  font-weight: 600;
  font-size: 14px;
  text-box-trim: trim-start;
  text-box-edge: cap alphabetic;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.screen-play .chat-bubble-body {
  font-weight: 400;
  font-size: 14px;
  line-height: 1.48;
}

.screen-play .chat-thread {
  --chat-inset: 12px;
  padding: 10px 0;
}

.screen-play .chat-msg {
  padding: 0 var(--chat-inset) 8px;
  border-bottom: 0;
  padding-bottom: 0;
}

/* The developer's messages: a row tinted in its colour, which no player's name can fake.
   The tint runs up into the gap above it, where the line above it would only cut the tint. */
.screen-play .chat-msg.developer {
  margin-top: calc(-1 * var(--chat-stack-gap));
  padding-top: var(--chat-stack-gap);
  background: color-mix(in srgb, var(--developer) 11%, transparent);
}

.screen-play .chat-msg:has(+ .chat-msg.developer) {
  border-bottom-color: transparent;
}

/* The System and the Developer stand in a crest's place with an icon on their own colour. */
.chat-avatar-system,
.chat-avatar-developer {
  --author: var(--developer);
  display: grid;
  place-items: center;
  height: var(--chat-avatar);
  border-radius: 8px;
  background: color-mix(in srgb, var(--author) 24%, transparent);
  color: var(--author);
}

.chat-avatar-system {
  --author: var(--system);
}

.chat-avatar-system .i,
.chat-avatar-developer .i {
  width: 60%;
  height: 60%;
}

.chat-room-face .i {
  width: 80%;
  height: 80%;
}

.screen-play .chat-msg:has(+ .chat-msg.continued) {
  padding-bottom: 0;
  border-bottom: 0;
}

.screen-play .chat-msg.continued {
  padding-left: calc(var(--chat-inset) + var(--chat-avatar) + var(--chat-msg-gap));
}

.screen-play .chat-bubble,
.screen-play .chat-bubble.mine {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 4px 0;
  color: var(--text);
}

.screen-play .chat-composer input {
  min-height: var(--control-height);
}

.screen-play .chat-composer button {
  min-width: 76px;
  min-height: var(--control-height);
}

.screen-play .bottom-panel {
  --panel-tabline-height: 54px;
}

.screen-play .bottom-panel:has(.panel-tabs:not([hidden])) {
  --panel-strip-room: calc(var(--panel-tabline-height) + 12px);
}

/* In portrait a bottom sheet fills the play view between the resource bar and the menu bar, as
   the Radio does. Its strip runs flush across the sheet's top edge at the Radio's height. */
html.aspect-portrait .screen-play .bottom-panel {
  --panel-tabline-height: 48px;
  padding-top: 0;
}

html.aspect-portrait .screen-play .bottom-panel .panel {
  height: 100%;
  border-top: 0;
}

html.aspect-portrait .screen-play .panel-tabline {
  position: static;
  height: auto;
  justify-content: flex-end;
  padding-inline: 0;
}

html.aspect-portrait .screen-play .panel-tabline:has(.panel-tabs:not([hidden])) {
  margin: calc(-1 * var(--panel-inset)) calc(-1 * var(--panel-inset)) 0;
  border-bottom: 1px solid var(--line);
  background: var(--skin-accent);
}

/* Every bottom sheet's top strip: its tabs when two or more show. Its Backs
   (button.js bindBack) show in the menu bar while the sheet is open (hud.js
   lendBacks), so the strip holds only tabs. */
.screen-play .panel-tabline {
  position: absolute;
  top: calc(-1 * (var(--icon-control-size) + 12px));
  right: 0;
  height: var(--icon-control-size);
  display: flex;
  gap: 8px;
  pointer-events: none;
  padding-inline: var(--play-control-inset);
}

.screen-play .panel-tabline:has(.panel-tabs:not([hidden])) {
  top: calc(-1 * var(--panel-tabline-height));
  left: 0;
  height: var(--panel-tabline-height);
  align-items: flex-end;
}

.screen-play .panel-tabs {
  flex: 1;
  height: var(--panel-tabline-height);
  gap: 0;
  align-items: flex-end;
  pointer-events: auto;
  margin-left: 0;
}

.screen-play .panel-tabs[hidden] {
  display: none;
}

:is(.screen-play, .screen-designer) .panel-tab {
  min-height: calc((var(--control-height) + var(--panel-tab-selected-height)) / 2);
  padding: 0 12px;
  background: var(--tab-ground);
  font-family: var(--font-ui);
  font-size: var(--control-text-size);
  pointer-events: auto;
  --tab-ground: var(--skin-accent);
  border-radius: 0;
  box-shadow: none;
  text-shadow: none;
  border: 0;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--skin-panel);
}

:is(.screen-play, .screen-designer) .panel-tab:hover {
  --tab-ground: var(--skin-selected);
  color: var(--text);
}

:is(.screen-play, .screen-designer) .panel-tab:not([hidden]) ~ .panel-tab:not([hidden]) {
  margin-left: -1px;
}

:is(.screen-play, .screen-designer) .panel-tab:not([hidden], [aria-selected="true"]) + .panel-tab:not([hidden], [aria-selected="true"]) {
  box-shadow: inset 1px 0 color-mix(in srgb, var(--skin-panel) 25%, transparent);
}

:is(.screen-play, .screen-designer) .panel-tab[aria-selected="true"] {
  height: var(--panel-tab-selected-height);
  border-color: var(--panel-line);
  border-bottom-color: #263638;
  --tab-ground: var(--skin-text);
  color: var(--skin-panel);
}

.screen-play .badge {
  z-index: 2;
}

/* Every typed field in play: text-like inputs, selects, and textareas.
   Checkbox and range have their own skins. */
:is(.screen-play, .screen-title, .screen-designer) :is(input:not([type="checkbox"], [type="range"], [type="radio"], [type="file"], [type="color"], [type="button"], [type="submit"], [type="reset"], [type="image"], [type="hidden"]), select, textarea) {
  border: 1px solid var(--play-line);
  border-radius: var(--control-radius);
  background: var(--surface-2);
  color: var(--text);
  font-family: var(--font-body);
}

/* A field a check refused: red edge until it is edited. */
:is(.screen-play, .screen-title, .screen-designer) :is(input, select, textarea)[aria-invalid="true"] {
  border-color: var(--alert);
  box-shadow: inset 0 0 0 1px var(--alert);
}

.screen-title .password-field {
  background: var(--surface-2);
  border-color: var(--play-line);
}

.screen-title .password-field input {
  border: 0;
  background: transparent;
}

/* A card is the play skin's panel tinted its tone: gold, green when positive, red when negative. The tint stays while a
   brighter band of it drains as the countdown, so the card stands off a panel behind it. */
/* The designer's names step uses the same cards. */
:is(.screen-play, .screen-designer) .notification {
  --notice-line: var(--skin-accent);
  border: 0;
  border-radius: var(--panel-radius);
  background: color-mix(in srgb, var(--notice-line) 24%, var(--skin-panel));
  color: var(--text);
  box-shadow: var(--shadow-card);
}

:is(.screen-play, .screen-designer) .notification .notification-fill::before {
  background: color-mix(in srgb, var(--notice-line) 18%, transparent);
}

:is(.screen-play, .screen-designer) .notification.positive {
  --notice-line: var(--ok);
}

:is(.screen-play, .screen-designer) .notification.negative {
  --notice-line: var(--alert);
}

@media (max-width: 600px) {
  .screen-play {
    --control-height: 28px;
    --icon-control-size: 28px;
    --meta-text-size: 13px;
    --caption-text-size: 11px;
  }
  .screen-play .panel.sheet { padding: 8px 10px; }
  /* Tabs size to their labels so four (Goods, Consumables, Troops, Inventory)
     fit a phone without clipping the long one. */
  .screen-play .panel-tab { flex: 1 1 auto; padding: 0 8px; white-space: nowrap; }
  .screen-play .member { grid-template-columns: 60px minmax(0, 1fr); gap: 8px; }
  .screen-play .look { width: 60px; height: 66px; }
  .screen-play .call-head .look { width: 48px; height: 52.8px; }
  .screen-play .settler-profile-top { grid-template-columns: minmax(0, 1fr); justify-items: center; }
  .screen-play .settler-profile-head { justify-self: stretch; }
  .screen-play .member-actions { flex-basis: 100%; order: 2; }
  .screen-play .member-top { gap: 6px; }
  .screen-play .xp-line { margin-block: 4px; }
  .screen-play .traits { gap: 5px; }
  .screen-play .trait { padding: 0 6px; }
  .screen-play .pill { padding: 0 6px; }
  .screen-play { --clock-lens: 36px; }
  .screen-play .clock { --clock-radius: 6px; }
}

/* Battle device knobs (debug mode, while a battle is joined). */
.battle-debug {
  position: absolute;
  left: 12px;
  bottom: 96px;
  z-index: 40;
  display: grid;
  gap: 6px;
  padding: 8px 12px;
  background: var(--chrome);
  color: var(--muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  pointer-events: auto;
}

.battle-debug-title {
  font-weight: 600;
}

.battle-debug-row {
  display: grid;
  grid-template-columns: 4.5em 8em 4em;
  align-items: center;
  gap: 6px;
}

.battle-debug-buttons {
  display: flex;
  gap: 6px;
}

.battle-debug-buttons button {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  font: inherit;
  padding: 2px 8px;
}

/* Sarah world playground (/#sarah-world) */
.sarah-world {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  background: #c9ccd0;
  color: #20282c;
  font: 14px system-ui,sans-serif;
}

.sarah-world-toolbar {
  padding: 14px 18px;
  background: #f3f3f0;
  border-bottom: 1px solid #a7aaac;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sarah-world-toolbar strong {
  font-size: 18px;
}

.sarah-world-toolbar [data-state] {
  font-weight: 400;
  font-size: 13px;
  color: #526268;
  margin-left: 12px;
}

.sarah-world-controls {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.sarah-world-controls label {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 7px;
  font-size: inherit;
}

.sarah-world-controls input {
  accent-color: #34656a;
}

.sarah-world-controls button,.sarah-world-controls select {
  background: #fff;
  color: #253235;
  border: 1px solid #a4adae;
  border-radius: 4px;
  padding: 7px 10px;
  font: inherit;
  cursor: pointer;
}

.sarah-world-controls button[aria-pressed=true] {
  background: #dce8e6;
}

.sarah-world-view {
  flex: 1;
  min-height: 0;
  position: relative;
}

.sarah-world-view canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}

.sarah-world-caption {
  position: absolute;
  bottom: 14px;
  left: 18px;
  color: #30383c;
  padding: 6px 10px;
  border: 1px solid #afb3b6;
  border-radius: 4px;
  background: #eef0f0d9;
  pointer-events: none;
  font-size: 12px;
}

@media (max-width: 560px) {
  .sarah-world-toolbar { padding: 10px 12px; gap: 8px; }
  .sarah-world-controls { gap: 8px; font-size: 12px; }
  .sarah-world-controls button,
  .sarah-world-controls select { padding: 6px; }
}

/* Walker playground (/#walker) */
.walker-playground {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: #c9ccd0;
}

.walker-playground canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}

.walker-panel {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 240px;
  max-height: calc(100% - 24px);
  overflow-y: auto;
  padding: 12px;
  display: grid;
  gap: 8px;
  background: var(--chrome);
  border-radius: 8px;
  box-shadow: var(--shadow);
  font: 13px var(--font);
  color: var(--ink);
}

.walker-panel label,
.walker-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  font-size: inherit;
}

.walker-panel input {
  padding: 0;
  min-width: 0;
}

.walker-panel select {
  font-size: inherit;
}

.walker-panel button {
  padding: 4px 10px;
}

.walker-panel label:has(input[type="range"]) {
  display: grid;
  grid-template-columns: 64px 1fr 36px;
}

.walker-panel output {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* The VFX playground's health panel sits top right, and along the bottom on a narrow screen. */
.vfx-health {
  left: auto;
  right: 12px;
  width: min(320px, calc(100% - 24px));
}

.vfx-health progress {
  flex: 1;
  min-width: 0;
}

.vfx-health output {
  white-space: nowrap;
}

/* The VFX playground's replay bar runs the width of the screen's foot, its
   slider taking all the room the play button and time leave. */
.vfx-replay {
  top: auto;
  right: 12px;
  bottom: 12px;
  width: auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.vfx-replay input {
  flex: 1;
}

.vfx-replay output {
  min-width: 4em;
}

/* Each benchmark run's stats, a block of lines a run. */
.vfx-runs {
  display: grid;
  gap: 8px;
  font-variant-numeric: tabular-nums;
}

.vfx-runs p {
  margin: 0;
}

/* On a narrow screen the health panel sits along the bottom, above the
   replay bar. */
@media (max-width: 600px) {
  .vfx-health {
    top: auto;
    bottom: 72px;
    left: 12px;
  }
}

.walker-legs {
  display: flex;
  gap: 4px;
}

.walker-legs button[aria-pressed="true"] {
  background: var(--accent);
}

.walker-ui-toggle {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 10px;
  border-radius: 6px;
  box-shadow: var(--shadow);
}

.walker-bare .walker-panel {
  display: none;
}

/* Constructing playground (/#constructing): a build button over each empty plot */
.constructing-plot {
  position: absolute;
  transform: translate(-50%, -50%);
  padding: 4px 10px;
  border-radius: 6px;
  box-shadow: var(--shadow);
  white-space: nowrap;
}

.walker-bare .walker-ui-toggle {
  opacity: 0.35;
}

.walker-bare .walker-ui-toggle:hover {
  opacity: 1;
}

.walker-readout,
.walker-hint {
  margin: 0;
  color: var(--muted);
}

/* Lootbox playground (/#lootboxes): a still of the game behind, and the game's own find overlay over it. */
.lootbox-playground {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: #0c1416;
}

.lootbox-screen.screen-play {
  display: block;
  height: 100%;
  pointer-events: auto;
}

.lootbox-game {
  position: absolute;
  inset: 0;
  background: center / cover no-repeat;
}

.lootbox-menu {
  position: absolute;
  top: 12px;
  left: 12px;
  display: grid;
  gap: 8px;
  font-family: var(--font-ui);
}

.lootbox-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lootbox-refuse {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  font-size: 13px;
}

.lootbox-status {
  margin: 0;
  font-size: 13px;
  color: #eee0bf;
}

.lootbox-status:empty {
  display: none;
}

.city-find-stage[data-opener="container"] canvas { cursor: crosshair; }
.city-find-stage[data-opener="safe"] canvas { cursor: pointer; }

/* Crafting playground (/#crafting): the controls down the left; the run on the right, a table with the board on it
   and the status below. The board is Forward's layout: 3:4 cards a ninth of their width apart, the settler's card at
   the bottom, the board sliding down as they climb. Every card size reads --cw, the card width the board sets. One
   column at phone width. */
.crafting-playground {
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.crafting-screen.screen-play {
  height: 100%;
  grid-template-columns: 300px minmax(0, 1fr);
  grid-template-rows: auto;
  grid-template-areas: none;
  align-items: start;
  gap: 16px;
  padding: 16px;
  overflow-y: auto;
  pointer-events: auto;
  background: var(--surface-0);
  --craft-felt: #2c2721;
  --craft-paper: linear-gradient(165deg, #f6ecd8, #e7d9bc);
  --craft-ink: #2d2720;
  --craft-edge: #dccfb2;
  --craft-back: #1e1b18;
  --craft-flaw: #8a4cc6;
  --craft-part: #2f9c8c;
  --craft-clamp: #7f8d9b;
  --craft-mend: #c7772f;
  --craft-rule: #d6a330;
  --craft-curse: #5f7d2c;
  --craft-test: #c6a45a;
  --craft-hurt: #c8323c;
  --craft-lift: 0 14px 26px #000a;
}

.craft-side,
.craft-main {
  display: grid;
  gap: 12px;
  min-width: 0;
}

/* The run is one screen tall: the blueprint, then the table taking what is left, then the status. From 1200px the
   blueprint stands beside the table instead, and the table has the full height. */
.craft-main {
  max-width: 720px;
  height: calc(100dvh - 32px);
  grid-template-rows: auto minmax(360px, 1fr) auto;
}

@media (min-width: 1200px) {
  .craft-main {
    max-width: 1060px;
    grid-template-columns: minmax(0, 1fr) 300px;
    grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas: "table blueprint" "status blueprint";
  }

  .craft-blueprint {
    grid-area: blueprint;
    align-self: start;
  }

  .craft-table {
    grid-area: table;
  }

  .craft-status {
    grid-area: status;
  }
}

/* At phone width the run comes first and the controls follow. */
@media (max-width: 720px) {
  .crafting-screen.screen-play {
    grid-template-columns: minmax(0, 1fr);
  }

  .craft-main {
    order: -1;
  }
}

.craft-panel {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-panel);
  box-shadow: var(--shadow-card);
}

.craft-heading {
  margin: 0;
  font: 600 var(--card-title-size) / 1 var(--font-display);
}

.craft-tuning summary {
  cursor: pointer;
}

.craft-meta {
  margin: 0;
  font-size: var(--caption-text-size);
  color: var(--muted);
}

.craft-level output {
  font-variant-numeric: tabular-nums;
}

.craft-level input {
  width: 100%;
}

.craft-stock {
  display: grid;
  gap: 6px;
}

.craft-stock-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 36px auto;
  align-items: center;
  gap: 6px;
}

.craft-stock-name {
  display: grid;
}

.craft-stock-count {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.craft-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.craft-deck-note.is-error {
  color: var(--alert);
}

.craft-tuning textarea {
  width: 100%;
  box-sizing: border-box;
  font: 12px / 1.4 ui-monospace, monospace;
  resize: vertical;
}

.craft-log {
  max-height: 180px;
  margin: 0;
  padding-left: 20px;
  overflow-y: auto;
  font-size: var(--caption-text-size);
  color: var(--muted);
}

.craft-log:empty {
  display: none;
}

/* The table: a felt stage the board sits on, and the end over it. */
.craft-table {
  position: relative;
  min-height: 0;
}

.craft-stage {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: var(--panel-radius);
  background: radial-gradient(ellipse 75% 65% at 50% 60%, #3b342b 0%, var(--craft-felt) 55%, #15120f 100%);
  box-shadow: inset 0 0 80px #000b;
  touch-action: none;
}

/* The track holds every card at its row and column; the camera slides it down a row as the settler climbs. */
.craft-track {
  position: absolute;
  left: 50%;
  bottom: var(--gap);
  width: calc(var(--cols) * var(--cw) + (var(--cols) - 1) * var(--gap));
  transform: translateX(-50%);
  translate: 0 calc(var(--cam) * (var(--ch) + var(--gap)));
  transition: translate 120ms ease-out;
}

.craft-card,
.craft-hero {
  position: absolute;
  left: calc(var(--col) * (var(--cw) + var(--gap)));
  bottom: calc(var(--row) * (var(--ch) + var(--gap)));
  width: var(--cw);
  height: var(--ch);
}

/* A card: a frame in its kind's colour round a paper face, the name on top, the art, and what it gives below. One
   class each, so a board card beats the plain button look. */
.craft-card,
.craft-hero,
.craft-info-card,
.craft-end-card {
  box-sizing: border-box;
  padding: calc(var(--cw) * 0.07) calc(var(--cw) * 0.06);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  justify-items: center;
  align-items: center;
  border: calc(var(--cw) * 0.045) solid var(--kind, var(--craft-edge));
  border-radius: calc(var(--cw) * 0.07);
  background: var(--craft-paper);
  color: var(--craft-ink);
  font-family: var(--font-display);
  box-shadow: 0 calc(var(--cw) * 0.035) 0 #0007, 0 calc(var(--cw) * 0.08) calc(var(--cw) * 0.12) #0006;
}

.craft-card {
  cursor: pointer;
}

:where(.craft-card, .craft-info-card, .craft-end-card).is-flaw { --kind: var(--craft-flaw); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-part { --kind: var(--craft-part); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-clamp { --kind: var(--craft-clamp); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-mend { --kind: var(--craft-mend); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-rule { --kind: var(--craft-rule); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-curse { --kind: var(--craft-curse); }
:where(.craft-card, .craft-info-card, .craft-end-card).is-test { --kind: var(--craft-test); }

.craft-name {
  max-width: 100%;
  font-size: calc(var(--cw) * 0.125);
  font-weight: 700;
  font-variant: small-caps;
  line-height: 1;
  text-align: center;
  letter-spacing: 0.02em;
}

.craft-art {
  width: 56%;
  color: var(--kind, var(--craft-ink));
}

.craft-art .i {
  display: block;
  width: 100%;
  height: auto;
}

.craft-foot {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.craft-gives {
  font-size: calc(var(--cw) * 0.1);
  font-weight: 600;
  opacity: 0.75;
}

/* A flaw's damage, bottom right. */
.craft-strike {
  padding: 0 calc(var(--cw) * 0.04);
  border-radius: calc(var(--cw) * 0.03);
  background: var(--craft-hurt);
  color: #fff;
  font-size: calc(var(--cw) * 0.12);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* A card back: dark, a light edge, the gear in the middle. */
.craft-card.is-down {
  grid-template-rows: 1fr;
  border-color: var(--craft-edge);
  background: radial-gradient(circle at 50% 45%, #2b2622, var(--craft-back) 70%);
  cursor: default;
}

.craft-card.is-down .craft-art {
  width: 42%;
  color: var(--craft-edge);
  opacity: 0.55;
}

.craft-card.is-test {
  background: linear-gradient(165deg, #f7e7bd, #e5cf95);
}

/* Taken, empty, behind the settler, or beside them: gone from the table. Only going fades, over 150ms; the rest of
   the row falls away this way before the board slides. */
.craft-card.is-empty,
.craft-card.is-gone {
  opacity: 0;
  scale: 0.85;
  pointer-events: none;
}

.craft-card.is-gone {
  transition: opacity 150ms ease-in, scale 150ms ease-in;
}

/* A choice rings the card, gold to step onto, red to strike; the card the dragged settler is over lifts. A card a
   flaw above strikes down on has a red top edge. */
.craft-card.is-legal {
  --craft-ring: var(--selected-line);
  box-shadow: 0 0 0 calc(var(--cw) * 0.025) var(--craft-ring), 0 calc(var(--cw) * 0.035) 0 #0007, 0 0 calc(var(--cw) * 0.15) var(--craft-ring);
}

.craft-card.is-strike {
  --craft-ring: var(--craft-hurt);
}

.craft-card.is-target {
  z-index: 1;
  scale: 1.06;
  transition: scale 100ms ease-out;
  box-shadow: 0 0 0 calc(var(--cw) * 0.04) var(--craft-ring), var(--craft-lift), 0 0 calc(var(--cw) * 0.3) var(--craft-ring);
}

.craft-card.is-struck {
  border-top-color: var(--craft-hurt);
}

.craft-card.is-look {
  outline: calc(var(--cw) * 0.025) dashed var(--info);
  outline-offset: calc(var(--cw) * 0.03);
}

/* The settler's card. It is dragged onto a card to choose it. The frame's Integrity and clamps are on the blueprint. */
.craft-hero {
  z-index: 2;
  --kind: var(--craft-edge);
  cursor: grab;
  touch-action: none;
}

.craft-hero .craft-art {
  width: 60%;
  color: var(--craft-ink);
}

/* Lifted while dragged: it rides on the stage, placed at the pointer, and lets the pointer through to the card under
   it. */
.craft-hero.is-dragging {
  position: fixed;
  bottom: auto;
  z-index: 10;
  transform: translate(-50%, -50%);
  scale: 1.12;
  pointer-events: none;
  box-shadow: var(--craft-lift);
}

.craft-hero.is-gritty {
  background: radial-gradient(#6b4b2a40 1px, transparent 1.6px) 0 0 / 7px 7px, var(--craft-paper);
}

/* A hit: the settler's card blushes and a slash crosses it. */
.craft-hero.is-hit {
  animation: craft-hit-blush 600ms ease-out;
}

.craft-hero.is-hit::after {
  content: "";
  position: absolute;
  inset: -4%;
  background: linear-gradient(135deg, transparent 45%, var(--craft-hurt) 48%, #fff 50%, var(--craft-hurt) 52%, transparent 55%);
  pointer-events: none;
  animation: craft-hit-slash 300ms ease-out forwards;
}

@keyframes craft-hit-blush {
  from { background: #f3a7a7; }
}

@keyframes craft-hit-slash {
  from { clip-path: inset(0 100% 100% 0); }
  60% { clip-path: inset(0); opacity: 1; }
  to { clip-path: inset(0); opacity: 0; }
}

/* What a hit cost, rising off the settler. It sits on the screen, placed at the settler. */
.craft-float {
  position: fixed;
  z-index: 11;
  color: #fff;
  font: 700 26px / 1 var(--font-display);
  text-shadow: 0 2px 0 var(--craft-hurt), 0 0 10px #000a;
  transform: translate(-50%, -100%);
  pointer-events: none;
  animation: craft-float 1.2s ease-out forwards;
}

@keyframes craft-float {
  from { opacity: 1; translate: 0 0; }
  to { opacity: 0; translate: 0 -34px; }
}

.craft-status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.craft-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 4px 8px;
  border: 1px solid var(--play-line);
  border-radius: var(--control-radius);
  background: var(--surface-1);
  font-family: var(--font-ui);
}

.craft-chip-label {
  font-size: var(--caption-text-size);
  color: var(--muted);
}

.craft-chip-value {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* The blueprint of the item being made: a line drawing on blueprint paper beside its Integrity, clamps, stats, and
   marks. Changes play on it: a hit shakes the drawing, flashes the flaw's part red, and drains the bar, leaving a red
   chunk that catches up; Integrity falling shows cracks; a part glows gold and stays inked; clamps show on the frame. */
.craft-blueprint {
  --bp-paper: #13396a;
  --bp-line: #d4eaff;
  --bp-faint: #d4eaff59;
  --bp-gold: #ffd36b;
  --bp-good: #7ef0b2;
  --bp-hurt: #ff6b74;
  position: relative;
  display: grid;
  gap: 6px;
  padding: 10px 14px 12px;
  border: 1px solid #5b8fc7;
  border-radius: var(--panel-radius);
  background:
    repeating-linear-gradient(0deg, #ffffff10 0 1px, transparent 1px 14px),
    repeating-linear-gradient(90deg, #ffffff10 0 1px, transparent 1px 14px),
    radial-gradient(ellipse at 30% 20%, #1b4a84, var(--bp-paper) 70%);
  color: var(--bp-line);
  font-family: var(--font-ui);
  box-shadow: inset 0 0 30px #0007, var(--shadow-card);
}

.bp-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  font: 600 13px / 1 var(--font-display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.bp-item {
  color: var(--bp-faint);
  letter-spacing: 0.06em;
}

/* On top of the table the drawing stays small, with the readout and stats beside it; at phone width the stats drop
   under both. Beside the table (from 1200px) everything stacks. */
.bp-body {
  display: grid;
  grid-template-areas: "drawing readout" "drawing stats" "marks marks";
  grid-template-columns: minmax(0, 240px) minmax(0, 1fr);
  align-items: center;
  gap: 8px 14px;
}

.bp-drawing {
  position: relative;
  grid-area: drawing;
}

.bp-svg {
  display: block;
  width: 100%;
  height: auto;
  fill: none;
  stroke: var(--bp-line);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  overflow: visible;
}

.bp-svg .bp-faint {
  stroke: var(--bp-faint);
}

.bp-svg .bp-dim {
  fill: var(--bp-faint);
  stroke: none;
  font: 8px var(--font-ui);
}

.bp-spot {
  transition: stroke 300ms;
}

/* A part fitted stays inked in gold. */
.bp-spot.is-fitted {
  stroke: var(--bp-gold);
}

.bp-spot.is-better {
  animation: bp-better 700ms ease-out;
}

.bp-spot.is-hurt {
  animation: bp-hurt 520ms ease-out;
}

/* A curse stains the frame. */
.bp-spot.is-cursed {
  stroke: #b7d36b;
  stroke-dasharray: 5 2;
}

@keyframes bp-better {
  0%, 30% { stroke: #fff; filter: drop-shadow(0 0 4px var(--bp-gold)) drop-shadow(0 0 8px var(--bp-gold)); }
}

@keyframes bp-hurt {
  0%, 40% { stroke: var(--bp-hurt); filter: drop-shadow(0 0 4px var(--bp-hurt)); }
}

.bp-clamps path,
.bp-cracks path {
  opacity: 0;
  transition: opacity 250ms;
}

.bp-clamps path {
  stroke: var(--bp-gold);
  stroke-width: 2.2;
}

.bp-cracks path {
  stroke: var(--bp-hurt);
  stroke-width: 1.8;
}

.bp-clamps path.is-shown,
.bp-cracks path.is-shown {
  opacity: 1;
}

.bp-readout {
  grid-area: readout;
  display: grid;
  gap: 6px;
  min-width: 0;
}

.bp-integrity {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 2px 8px;
}

.bp-label {
  font-size: 12px;
  color: var(--bp-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.bp-value {
  display: inline-block;
  font: 700 18px / 1 var(--font-display);
  font-variant-numeric: tabular-nums;
}

.bp-bar {
  position: relative;
  grid-column: 1 / -1;
  height: 8px;
  overflow: hidden;
  border: 1px solid var(--bp-faint);
  border-radius: 4px;
  background: #0a2246;
}

.bp-bar-fill,
.bp-bar-loss {
  position: absolute;
  inset: 0 auto 0 0;
}

.bp-bar-fill {
  background: linear-gradient(90deg, #6fd6ff, var(--bp-line));
  transition: width 200ms ease-out;
}

/* The red chunk a hit leaves catches up after a beat. */
.bp-bar-loss {
  background: var(--bp-hurt);
  transition: width 420ms ease-in 260ms;
}

.bp-bar-fill.is-mended {
  animation: bp-mend 700ms ease-out;
}

@keyframes bp-mend {
  0%, 30% { background: var(--bp-good); box-shadow: 0 0 10px var(--bp-good); }
}

.bp-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.bp-clamp-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.bp-clamp-count-icon .i {
  display: block;
  width: 18px;
  height: 18px;
  color: var(--bp-gold);
}

.bp-grit {
  padding: 1px 8px;
  border: 1px solid #c9935a;
  border-radius: 10px;
  color: #f0c08a;
  font-size: 12px;
}

.bp-stats {
  grid-area: stats;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px;
}

.bp-stat {
  position: relative;
  display: grid;
  gap: 2px;
  padding: 4px 8px;
  border: 1px solid var(--bp-faint);
  border-radius: 6px;
  background: #0d2c5580;
}

.bp-stat .bp-pct {
  color: var(--bp-gold);
  font-size: 20px;
}

.bp-stat-what {
  font-size: 11px;
  color: var(--bp-faint);
}

.bp-marks {
  grid-area: marks;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.bp-marks:empty {
  display: none;
}

.bp-mark {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 1px 8px 1px 4px;
  border: 1px solid var(--bp-gold);
  border-radius: 10px;
  color: var(--bp-gold);
  font-size: 12px;
}

.bp-mark .i {
  width: 14px;
  height: 14px;
}

.bp-mark.is-curse {
  border-color: var(--bp-hurt);
  color: var(--bp-hurt);
}

/* A technique that just held a flaw back pulses. */
.bp-mark.is-saving {
  animation: bp-saving 700ms ease-out;
}

@keyframes bp-saving {
  0%, 35% { scale: 1.2; background: #ffd36b33; box-shadow: 0 0 10px var(--bp-gold); }
}

/* What changed, rising off the number. */
.bp-float {
  position: absolute;
  right: 4px;
  top: -4px;
  color: var(--bp-hurt);
  font: 700 18px / 1 var(--font-display);
  text-shadow: 0 0 6px #000a;
  pointer-events: none;
  animation: craft-float 1.1s ease-out forwards;
}

.bp-float.is-good {
  color: var(--bp-good);
}

.craft-blueprint.is-gritty .bp-drawing {
  background: radial-gradient(#c9935a33 1px, transparent 1.6px) 0 0 / 6px 6px;
}

/* The end: approved glows gold; broken goes grey with every crack. The stamp says which. */
.bp-stamp {
  position: absolute;
  top: 50%;
  left: 50%;
  padding: 2px 10px;
  border: 2px solid currentColor;
  border-radius: 4px;
  font: 700 18px / 1 var(--font-display);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transform: translate(-50%, -50%) rotate(-12deg);
  pointer-events: none;
}

.bp-stamp:empty {
  display: none;
}

.craft-blueprint.is-approved {
  border-color: var(--bp-gold);
  box-shadow: inset 0 0 30px #0007, 0 0 18px #ffd36b55;
}

.craft-blueprint.is-approved .bp-stamp {
  color: var(--bp-gold);
}

.craft-blueprint.is-broken .bp-svg {
  filter: grayscale(1) brightness(0.8);
}

.craft-blueprint.is-broken .bp-cracks path {
  opacity: 1;
}

.craft-blueprint.is-broken .bp-stamp {
  color: var(--bp-hurt);
}

.craft-blueprint.is-approving {
  animation: bp-approve 900ms ease-out;
}

.craft-blueprint.is-breaking .bp-drawing {
  animation: bp-break 600ms ease-out;
}

@keyframes bp-approve {
  0%, 25% { box-shadow: inset 0 0 30px #0007, 0 0 40px var(--bp-gold); }
}

@keyframes bp-break {
  30% { scale: 1.04; }
}

@media (max-width: 520px) {
  .bp-item {
    display: none;
  }

  .bp-body {
    grid-template-areas: "drawing readout" "stats stats" "marks marks";
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
}

@media (min-width: 1200px) {
  .bp-body {
    grid-template-areas: "drawing" "readout" "stats" "marks";
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The card a tap reads, large over the screen. */
.craft-info {
  position: fixed;
  inset: 0;
  z-index: 12;
  display: grid;
  place-items: center;
  padding: 16px;
  background: #05090ad0;
  pointer-events: auto;
}

.craft-info-card {
  --cw: min(260px, 70vw);
  width: var(--cw);
  min-height: calc(var(--cw) * 4 / 3);
  gap: 8px;
  align-content: start;
  cursor: default;
  animation: craft-deal 260ms ease-out;
}

.craft-info-card p {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.35;
  text-align: center;
}

.craft-info-card .craft-art {
  width: 40%;
}

@keyframes craft-deal {
  from { opacity: 0; transform: perspective(800px) rotateY(70deg) scale(0.85); }
}

/* The end, over the table: the item crafted as a card beside its stats and the XP. */
.craft-end {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  padding: 16px;
  border-radius: var(--panel-radius);
  background: #0b0908d9;
  animation: craft-fade 300ms ease-out;
}

@keyframes craft-fade {
  from { opacity: 0; }
}

.craft-end-panel {
  width: min(560px, 100%);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 20px;
  padding: 20px;
  border: var(--panel-border);
  border-radius: var(--panel-radius);
  background: var(--surface-panel);
  box-shadow: var(--shadow-card);
}

@media (max-width: 520px) {
  .craft-end-panel {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
  }
}

.craft-end-card {
  --cw: 150px;
  --kind: var(--craft-test);
  position: relative;
  width: var(--cw);
  height: calc(var(--cw) * 4 / 3);
  animation: craft-deal 420ms ease-out 120ms backwards;
}

/* A cracked frame: grey, with a crack across it. */
.craft-end-card.is-cracked {
  --kind: var(--craft-edge);
  filter: grayscale(0.8);
}

.craft-end-card.is-cracked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 47%, var(--craft-ink) 48%, transparent 50%);
  clip-path: polygon(0 30%, 40% 45%, 55% 40%, 100% 70%, 100% 74%, 55% 44%, 40% 49%, 0 34%);
}

.craft-end-facts {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.craft-end-facts p {
  margin: 0;
}

.craft-end-title {
  margin: 0;
  font: 700 26px / 1 var(--font-display);
  color: var(--gold-200);
}

.craft-end-title.is-cracked {
  color: var(--alert);
}

.craft-end-stats,
.craft-end-xp {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.craft-end-stats li {
  display: grid;
}

.craft-end-stat {
  font: 700 20px / 1.1 var(--font-display);
}

/* Elevation playground (/#elevation): the fold button stands in the top left
   corner and the panel opens below it. */
.elev-fold {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 36px;
  height: 36px;
  padding: 0;
  display: grid;
  place-items: center;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.elev-fold .i {
  width: 20px;
  height: 20px;
}

.walker-playground:has(.elev-fold) > .walker-panel {
  top: 56px;
  max-height: calc(100% - 68px);
}

.elev-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.elev-wrap button[aria-pressed="true"] {
  background: var(--accent);
}

.elev-stats {
  white-space: pre-line;
  font-variant-numeric: tabular-nums;
}

.screen-play .member-new {
  padding: 1px 7px;
  border-radius: 5px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
}

.screen-play .family-count {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--text-dim);
}

.dialogue-sprite {
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
  animation: dialogue-sprite var(--sprite-ms) steps(var(--sprite-frames)) infinite;
  /* The sheets draw a clanker facing left; on the left of the strip it turns to its bubble. */
  transform: scaleX(-1);
}

.dialogue-strip.is-right .dialogue-sprite {
  transform: none;
}

@keyframes dialogue-sprite {
  from {
    background-position-x: var(--sprite-x0);
  }
  to {
    background-position-x: var(--sprite-x1);
  }
}

/* A clanker's dialogue is set smaller. */
.dialogue-bubble.is-robot {
  --dialogue-emphasis: #8fe3ff;
}

.dialogue-bubble.is-robot :is(.dialogue-name, .dialogue-line) {
  font-family: var(--font-pixel);
  font-size: 12px;
  line-height: 1.7;
}

.wipe-cursor {
  position: relative;
}

.wipe-cursor::after {
  content: "";
  position: absolute;
  left: calc(100% + 0.5em);
  top: 0;
  width: 0.55em;
  height: 1em;
  background: currentColor;
}

/* Seats: who works a building (city/seats.js). Round settler seats show a face, ringed gold
   for the founders; square clanker seats show a clanker's head; an empty seat is dashed, ringed
   red while nobody is in charge. The card and Manage draw the same seats. */
.seat-strip {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
}

.garrison-seats {
  display: inline-grid;
  grid-template-columns: repeat(5, max-content);
}

.seat {
  appearance: none;
  flex: none;
  display: grid;
  place-items: center;
  width: var(--seat);
  height: var(--seat);
  padding: 0;
  overflow: hidden;
  background: #0e171c;
  border: 1.5px dashed var(--play-line-strong);
  color: var(--muted);
  font: 600 14px/1 var(--font-ui);
}

button.seat {
  cursor: pointer;
}

.seat-settler {
  --seat: 32px;
  border-radius: 50%;
}

.seat-clanker,
.seat-troop {
  --seat: 24px;
  border-radius: 4px;
}

.seat.is-filled {
  border-style: solid;
  border-color: #0b1216;
}

.seat-settler.is-filled {
  background: #f6f1e5;
}

.seat-settler.is-founding {
  border: 2px solid var(--gold-400);
}

.seat-clanker.is-filled,
.seat-troop.is-filled {
  background: #3a4a55;
}

.seat-troop.is-damaged {
  border-color: var(--troop-damaged);
}

.seat-troop:is(.is-damaged, .is-repairing) canvas {
  opacity: var(--dim-opacity);
  filter: grayscale(1);
}

.seat.is-need {
  border: 2px solid var(--alert);
  box-shadow: 0 0 8px #ff858c66;
}

.seat canvas,
.tray-pic canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.seat-bust {
  width: 100%;
  height: 100%;
  background-repeat: no-repeat;
}

.seat.is-pop {
  animation: seat-pop 0.28s cubic-bezier(0.3, 1.6, 0.5, 1);
}

.seat.is-emptied {
  animation: seat-emptied 0.24s ease-out;
}

@keyframes seat-pop {
  0% { transform: scale(0.55); }
  60% { transform: scale(1.14); }
  100% { transform: scale(1); }
}

@keyframes seat-emptied {
  0% { transform: scale(1.12); opacity: 0.4; }
  100% { transform: scale(1); opacity: 1; }
}

/* The output figure counts to a new value and flashes the way it moved. */
.pct {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  padding: 0 4px;
  border-radius: 4px;
  font-family: var(--font-ui);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  transition: color 1s, background-color 1s;
}

.pct .pct-arrow {
  font-size: 0.8em;
  opacity: 0;
  transition: opacity 1s;
}

.pct.is-up {
  color: #9ff0c1;
  background: #3dbe7833;
  transition: none;
}

.pct.is-down {
  color: #ffc2c6;
  background: #ff858c33;
  transition: none;
}

.pct.is-up .pct-arrow,
.pct.is-down .pct-arrow {
  opacity: 1;
  transition: none;
}

.screen-play .city-sheet-seats {
  display: contents;
}

.city-sheet-crew-slots { grid-column: 2 / -1; }

/* A gathering hut's walk and pace sit under its crew: label, then the words
   across the rest of the row. */
.screen-play :is(.city-sheet-gather, .city-sheet-stat) {
  display: contents;
}

.city-sheet-stat > .walk-tone { grid-column: 2 / -1; }

.screen-play .city-sheet-gather[hidden] {
  display: none;
}

.screen-play .city-sheet-seats[hidden] {
  display: none;
}

/* Manage: bigger seats, a + in an empty settler seat, and the hint beside them. Clanker seats
   only show who works there: the server staffs them. */
#manage-panel .seat-settler {
  --seat: 44px;
}

#manage-panel .seat-clanker {
  --seat: 34px;
}

#manage-panel .seat-settler:not(.is-filled)::after {
  content: "+";
}

.upgrade-table tr.is-line td {
  vertical-align: middle;
}

.manage-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

#manage-panel .manage-line .pct {
  font-size: 18px;
}

.output-why,
.need-line.is-off {
  color: var(--alert);
}

.output-why {
  font-weight: 600;
}

.output-idle {
  color: var(--muted);
}

.seat-hint {
  font-size: var(--meta-text-size);
  color: var(--muted);
}

/* A gatherer hut's walk and pace (gather.js walkTone): green near, amber, red far. */
.walk-tone {
  font-weight: 600;
}

.walk-tone[data-tone="ok"] {
  color: var(--ok);
}

.walk-tone[data-tone="warn"] {
  color: var(--warn);
}

.walk-tone[data-tone="alert"] {
  color: var(--alert);
}

/* A Needs row's needs (energy, water), each a round mark, green ✓ or red ✕, and its words. */
.need {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.need + .need {
  margin-left: 16px;
}

.need-mark {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  font-weight: 700;
  font-size: 14px;
}

.need-mark.is-on {
  background: var(--ok);
  color: var(--ok-ink);
}

.need-mark.is-off {
  background: var(--alert);
  color: var(--alert-ink);
}

/* The tray of faces that replaces the Manage rows to choose who helps. */
.tray-title {
  margin-bottom: 10px;
  font: 700 20px/1.1 var(--font-display);
}

.tray-faces {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 8px;
}

.tray-face {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 3px;
  padding: 8px 6px;
  border: 1px solid var(--play-line);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--text);
  font-family: var(--font-ui);
  text-align: center;
}

button.tray-face {
  cursor: pointer;
}

button.tray-face:hover {
  border-color: var(--play-line-strong);
  background: var(--surface-3);
}

.tray-pic {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  overflow: hidden;
  border: 1px solid #000;
  border-radius: 50%;
  background: #f6f1e5;
}

.tray-face.is-founding .tray-pic {
  border: 3px solid var(--gold-400);
}

.tray-face.is-none .tray-pic {
  border: 2px dashed var(--play-line-strong);
  background: #0e171c;
  color: var(--muted);
}

.tray-face.is-none .tray-pic::after {
  content: "✕";
  font-size: 22px;
}

.tray-face.is-away {
  opacity: 0.45;
}

.tray-name {
  font-weight: 600;
  font-size: 15px;
}

.tray-where {
  font-size: 12px;
  color: var(--gold-200);
}

.tray-gain {
  font-size: 13px;
  color: var(--ok-text);
}

/* The floor plan section of Manage (city/floor_plan.js) is the Fixtures card, below the rows'
   own card (an inventory box each). The board holds the grid on the left and the detail on the
   right; when the pane is too narrow for both, the detail wraps under the grid. The tray runs
   full width below. One square per plan cell, --fp-cell at most,
   smaller when the plan is wider than the pane. Open floor is a panel well, floor a later level
   opens is dashed with that level, and void is nothing. A fixture's cells join into one shape;
   the picked one is lit as anything selected, and one placed but not yet installed is green.
   The one being dragged dims, and where a drag would drop shows green, or red where it can't. */
/* A closed floor (floor_plan.js paintClosed): the whole section dims and blurs under a veil
   that takes every tap, its pill in the middle. */
/* The plan's sections, Installed and the tray's, sit bare on the pane, set
   apart by more than a section's own title and tiles. */
.fp-panel,
.fp-tray {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.fp-panel {
  position: relative;
}

.fp-closed {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  border-radius: inherit;
  background: color-mix(in srgb, #000 45%, transparent);
  backdrop-filter: blur(3px);
}

.fp-board {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 16px;
}

.fp-plan {
  max-width: 100%;
}

.fp-detail {
  flex: 1 1 220px;
  min-width: 0;
}

.fp-moves {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.fp-grid {
  --fp-cell: 40px;
  display: grid;
  grid-template-columns: repeat(var(--fp-cols), minmax(0, 1fr));
  grid-template-rows: repeat(var(--fp-rows), minmax(0, 1fr));
  width: calc(var(--fp-cols) * var(--fp-cell));
  max-width: 100%;
  aspect-ratio: var(--fp-cols) / var(--fp-rows);
}

.fp-layer {
  display: contents;
}

.fp-cell,
.fp-piece,
.fp-ghost {
  margin: 1px;
  border-radius: var(--control-radius);
}

.fp-cell {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: var(--caption-text-size);
}

.fp-cell.is-open {
  border: 1px solid var(--play-line);
  background: var(--surface-1);
}

.fp-cell.is-locked {
  border: 1px dashed var(--play-line);
  background: var(--surface-0);
}

/* A fixture that drags (a tray tile, a piece on the grid): a mouse drag over it selects
   nothing. A finger that starts sideways on a tray tile drags it; one that starts up or down
   scrolls the pane, so the tray at the foot of Manage still scrolls. */
[data-drag] {
  touch-action: pan-y;
  user-select: none;
  cursor: grab;
}

/* A fixture's footprint in miniature: cells on a square of the larger side, at
   least two cells across, 36px unless its holder sets --fp-glyph-size. A tray tile holds it as
   its picture. */
.fp-glyph {
  --fp-glyph-cell: calc((var(--fp-glyph-size, 36px) - (var(--fp-glyph-side) - 1) * 2px) / var(--fp-glyph-side));
  display: grid;
  grid-template-columns: repeat(var(--fp-glyph-cols), var(--fp-glyph-cell));
  grid-template-rows: repeat(var(--fp-glyph-rows), var(--fp-glyph-cell));
  place-content: center;
  gap: 2px;
  width: var(--fp-glyph-size, 36px);
  height: var(--fp-glyph-size, 36px);
  color: var(--tile-icon, var(--tier-deep, var(--info-deep)));
}

.screen-play .inv-tile > .fp-glyph {
  grid-row: 1 / span 2;
}

/* The footprint follows the tile's status colour, or its rarity when it has no status. */
.fp-glyph-cell {
  border: 1px solid currentColor;
  border-radius: 2px;
  background: color-mix(in srgb, currentColor 35%, var(--surface-1));
}

/* Every piece is plain whatever its rarity, so only the picked one wears blue. */
.fp-piece {
  display: grid;
  place-items: center;
  border: 1px solid var(--play-line-strong);
  background: var(--surface-3);
  color: var(--text);
}

/* A finger on a piece that drags moves it in any direction, never the pane. A piece on a
   locked plan has no data-drag, so a finger on it scrolls. */
.fp-piece[data-drag] {
  touch-action: none;
}

.fp-piece[data-join~="t"] {
  margin-top: 0;
  border-top-width: 0;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.fp-piece[data-join~="r"] {
  margin-right: 0;
  border-right-width: 0;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.fp-piece[data-join~="b"] {
  margin-bottom: 0;
  border-bottom-width: 0;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

.fp-piece[data-join~="l"] {
  margin-left: 0;
  border-left-width: 0;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.fp-piece > .i {
  width: 70%;
  height: 70%;
}

.fp-piece.is-picked {
  border-color: var(--info-deep);
  background: color-mix(in srgb, var(--info-deep) 35%, var(--surface-1));
  color: var(--info);
}

.fp-piece.is-new {
  border-color: var(--ok);
  background: var(--btn-go-fill);
  color: var(--ok-text);
}

.fp-piece.is-new.is-picked {
  box-shadow: inset 0 0 9px color-mix(in srgb, var(--ok) 25%, transparent);
}

.fp-piece.is-lifted {
  opacity: var(--dim-opacity);
}

.fp-ghost {
  background: color-mix(in srgb, var(--ok-text) 40%, transparent);
  pointer-events: none;
}

.fp-ghost.is-bad {
  background: color-mix(in srgb, var(--alert) 45%, transparent);
}

/* Crest editor (src/crest/designer.js), over the play screen down to the
   menu bar, which it holds with Back, Undo, Redo, and Save. It is a bottom
   sheet the full height of the play grid's HUD column above the menu,
   beside a docked radio as the bottom panels are: as wide as they are and
   centred over the bar in landscape, the whole column in portrait. A save's
   error heads it. The charge list runs beside the crest, the edit band
   (palette, picker, sliders) sits under both, and the catalogue fills the
   rest. */
/* A sheet over the open panel, the crest editor's or the slide to confirm's
   (ui/confirm_slide.js sheetHost), stands where the bottom panels do. */
.crest-designer,
.confirm-slide {
  position: relative;
  grid-column: 2;
  grid-row: 1 / 3;
  justify-self: center;
  width: var(--play-width);
  margin: var(--panel-pad) 0 0;
  min-height: 0;
  z-index: var(--z-editor);
  padding: var(--panel-inset);
  pointer-events: auto;
}

.crest-designer {
  display: grid;
  /* The charge list is one row wide whatever the screen; the crest takes
     the rest. */
  grid-template-columns: 124px minmax(0, 1fr);
  grid-template-rows: auto auto auto minmax(0, 1fr);
  grid-template-areas: "head head" "layers main" "edit edit" "catalogue catalogue";
  gap: 8px;
  color: var(--ink);
  font-size: 14px;
  /* A charge row is as tall as the two flip buttons stacked beside it. */
  --crest-tools-gap: 6px;
  --crest-row-height: calc(2 * var(--icon-control-size) + var(--crest-tools-gap));
}

/* The sheet's margins would show the top row and a dialogue's bubble
   around it; both wait unseen behind the editor. Opacity, not visibility:
   a shown bubble sets its own visibility. */
.screen-play:has(> .crest-designer) :is(.play-top-row, #dialogue) {
  opacity: 0;
}

html.aspect-portrait .screen-play :is(.crest-designer, .confirm-slide) {
  margin: 0;
  border-top: 0;
  padding-top: max(var(--panel-inset), env(safe-area-inset-top));
}

.crest-head {
  grid-area: head;
}

.crest-status {
  text-align: center;
}

.crest-main {
  grid-area: main;
  display: flex;
  justify-content: center;
  align-items: start;
}

.crest-stage {
  position: relative;
  width: min(100%, 42dvh);
  aspect-ratio: 1;
}

.crest-random {
  position: absolute;
  right: 0;
  bottom: 0;
}

/* The dice rolls while the server deals a Random crest. */
.crest-random[aria-busy="true"] svg {
  animation: crest-dice-roll 600ms linear infinite;
}

@keyframes crest-dice-roll {
  to {
    transform: rotate(360deg);
  }
}

.crest-art {
  display: block;
  width: 100%;
  height: 100%;
}

/* The cursor says what a press will do: a pointing finger picks another
   charge, an open hand drags the selected one, a closed hand is dragging. */
.crest-live {
  touch-action: none;
}

.crest-live [data-charge] {
  cursor: pointer;
}

.crest-live [data-selected] {
  cursor: grab;
}

.crest-live.crest-dragging,
.crest-live.crest-dragging * {
  cursor: grabbing;
}

.crest-edit {
  grid-area: edit;
  display: grid;
  gap: 8px;
}

.crest-palette {
  display: flex;
  gap: 8px;
}

.crest-swatch {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  border: 2px solid var(--line);
  display: grid;
  place-items: center;
}

.crest-swatch[aria-pressed="true"] {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px var(--accent);
}

.crest-picker-host[hidden] {
  display: none;
}

/* Hue runs the full width; saturation and brightness share the row under
   it. */
.crest-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
  padding: 10px;
  border-radius: 8px;
  background: var(--surface-panel);
}

.crest-slider {
  display: grid;
  grid-template-columns: 76px 1fr;
  align-items: center;
  gap: 8px;
}

.crest-picker input[type="range"],
.crest-slider input[type="range"] {
  --thumb: 26px;
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: var(--thumb);
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.crest-picker input[type="range"]::-webkit-slider-runnable-track,
.crest-slider input[type="range"]::-webkit-slider-runnable-track {
  height: 14px;
  border-radius: 99px;
  background: var(--track-bg, var(--line));
}

.crest-picker input[type="range"]::-moz-range-track,
.crest-slider input[type="range"]::-moz-range-track {
  height: 14px;
  border-radius: 99px;
  background: var(--track-bg, var(--line));
}

.crest-picker input[type="range"]::-webkit-slider-thumb,
.crest-slider input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: var(--thumb);
  height: var(--thumb);
  margin-top: calc((14px - var(--thumb)) / 2);
  border-radius: 50%;
  border: 3px solid #fff;
  background: var(--ink);
  box-shadow: 0 1px 4px #0006;
}

.crest-picker input[type="range"]::-moz-range-thumb,
.crest-slider input[type="range"]::-moz-range-thumb {
  width: var(--thumb);
  height: var(--thumb);
  border-radius: 50%;
  border: 3px solid #fff;
  background: var(--ink);
  box-shadow: 0 1px 4px #0006;
}

.crest-strip-h {
  grid-column: 1 / -1;
  --track-bg: linear-gradient(to right, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00);
}

.crest-strip-s {
  --track-bg: linear-gradient(to right, var(--sat-from), var(--sat-to));
}

.crest-strip-v {
  --track-bg: linear-gradient(to right, #000, var(--val-to));
}

/* The tabs stay put; only the grid under them scrolls. */
.crest-catalogue {
  grid-area: catalogue;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.crest-grid {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  align-content: start;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
  gap: 6px;
}

.crest-tile {
  aspect-ratio: 1;
  padding: 6px;
  border-radius: 8px;
  background: var(--surface-panel);
  color: var(--ink);
  border: 2px solid transparent;
}

.crest-charge-art {
  display: block;
  width: 100%;
  height: 100%;
}

/* The crest alone sets its row's height: the list takes no size from its
   rows, stretches to the crest beside it, and scrolls the rest. */
.crest-layers {
  grid-area: layers;
  display: grid;
  align-content: start;
  min-height: 0;
  overflow-y: auto;
  contain: size;
}

.crest-rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 4px;
}

/* In the narrow list a row is the charge between its four corner
   buttons: delete top left, its colour top right, up and down along the
   bottom. */
.crest-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas: "remove pick colour" "up pick down";
  align-items: center;
  min-height: var(--crest-row-height);
  border-radius: 8px;
  background: var(--surface-panel);
  border: 2px solid transparent;
}

.crest-row button {
  background: transparent;
  color: var(--ink);
  padding: 4px 6px;
}

.crest-row-pick {
  grid-area: pick;
  display: flex;
  justify-content: center;
  align-items: center;
}

.crest-row [data-act="up"] {
  grid-area: up;
}

.crest-row [data-act="down"] {
  grid-area: down;
}

.crest-row [data-act="remove"] {
  grid-area: remove;
}

.crest-row button.crest-row-colour {
  grid-area: colour;
  justify-self: center;
  width: 20px;
  height: 20px;
  margin: 4px;
  padding: 0;
  border-radius: 4px;
  border: 1px solid var(--line);
}

.crest-row-art {
  width: 44px;
  height: 44px;
  flex: none;
}

/* A charge's colour choice: the palette beside its row, fixed to the screen
   so the list's scrolling does not clip it. */
.crest-slot-pop {
  position: fixed;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 44px);
  gap: 6px;
  padding: 6px;
  border-radius: 8px;
  background: var(--surface-panel);
  box-shadow: var(--shadow);
}

.crest-slot-pop[hidden] {
  display: none;
}

/* The selected charge's flips, beside its row under any open palette. */
.crest-row-tools {
  position: fixed;
  z-index: 1;
  display: grid;
  gap: var(--crest-tools-gap);
}

.crest-row-tools[hidden] {
  display: none;
}

.crest-slot {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 8px;
  border: 2px solid var(--line);
}

.crest-slot[aria-pressed="true"] {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px var(--accent);
}

.crest-empty {
  color: var(--muted);
  margin: 8px 0;
}

.crest-controls {
  display: grid;
  gap: 8px;
}

/* Scale is one slider or, unlocked, width and height; the padlock sits
   beside whichever shows. */
.crest-scale {
  display: flex;
  align-items: center;
  gap: 8px;
}

.crest-scale-sliders {
  flex: 1;
  display: grid;
  gap: 8px;
}

/* No turn sits in the middle of the turn slider; a mark shows where. */
.crest-slider-turn input {
  --track-bg: linear-gradient(to right, var(--line) calc(50% - 1px), var(--muted) 0 calc(50% + 1px), var(--line) 0);
}

/* Generator study playground (/#generator-study) */
.generator-study {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  background: #c9ccd0;
  color: #20282c;
  font: 14px system-ui, sans-serif;
}
.generator-study-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 18px;
  background: #f3f3f0;
  border-bottom: 1px solid #a7aaac;
}
.generator-study-toolbar strong { font-size: 18px; }
.generator-study-toolbar [data-status] {
  display: inline-block;
  margin-left: 10px;
  font-size: 13px;
  font-weight: 400;
  color: #526268;
}
.generator-study-controls, .generator-study-controls label {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
}
.generator-study-controls label { font-size: inherit; }
.generator-study-controls { flex-wrap: wrap; }
.generator-study-controls input { accent-color: #916b20; margin: 0; padding: 0; }
.generator-study-controls button, .generator-study-controls a {
  background: #fff;
  color: #253235;
  border: 1px solid #a4adae;
  border-radius: 4px;
  padding: 7px 10px;
  font: inherit;
  text-decoration: none;
  cursor: pointer;
}
.generator-study :focus-visible { outline: 3px solid #916b20; outline-offset: 2px; }
.generator-study-view { position: relative; flex: 1; min-height: 0; }
.generator-study-view canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.generator-study-hint {
  position: absolute;
  bottom: 12px;
  left: 14px;
  padding: 6px 9px;
  border: 1px solid #afb3b6;
  border-radius: 4px;
  background: #eef0f0d9;
  font-size: 12px;
  pointer-events: none;
}
@media (max-width: 560px) {
  .generator-study-toolbar { padding: 10px 12px; }
  .generator-study-controls { font-size: 12px; }
}

/* Standalone 3D character study. */
.character-study {
  --study-panel: #f3f1e9;
  --study-ink: #273d36;
  --study-muted: #727d74;
  --study-line: #d9ddd1;
  --study-accent: #3e6250;
  --accent: var(--study-accent);
  --bg: var(--study-panel);
  --on-accent: #fff;
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  grid-template: 96px minmax(0, 1fr) 34px / 340px minmax(0, 1fr);
  color: var(--study-ink);
  background: var(--study-panel);
  font:
    14px/1.4 system-ui,
    sans-serif;
}
.character-study button {
  background: transparent;
  color: inherit;
  border: 1px solid var(--study-line);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 550;
  padding: 9px 13px;
}
.character-study button:hover {
  background: #e3e8dc;
}
.character-study button:focus-visible {
  outline: 2px solid var(--study-accent);
  outline-offset: 3px;
}
.character-study button[aria-pressed="true"] {
  background: #dfe8d8;
  border-color: var(--study-accent);
  color: #294433;
}
.character-study h1,
.character-study h2,
.character-study p {
  margin: 0;
}
.character-study-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 19px 28px;
  border-bottom: 1px solid var(--study-line);
  gap: 16px;
}
.character-study-eyebrow {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.17em;
  color: var(--study-muted);
}
.character-study h1 {
  font:
    28px/1.3 Georgia,
    serif;
  letter-spacing: -0.7px;
}
.character-study h1 span {
  font:
    11px system-ui,
    sans-serif;
  vertical-align: top;
  margin: 4px 0 0 10px;
  display: inline-block;
  color: var(--study-muted);
  letter-spacing: 0;
}
.character-study-actions {
  display: flex;
  gap: 8px;
}
.character-study-actions [data-action="shuffle"] {
  background: var(--study-accent);
  color: #fff;
  border-color: var(--study-accent);
}
.character-study-editor {
  min-height: 0;
  overflow: auto;
  scrollbar-width: thin;
  border-right: 1px solid var(--study-line);
  padding: 24px 22px 16px;
}
.character-study-intro h2 {
  font:
    21px Georgia,
    serif;
}
.character-study-intro p {
  margin-top: 6px;
  color: var(--study-muted);
  font-size: 12px;
}
.character-study-examples {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
  margin: 20px 0 22px;
}
.character-study-examples button {
  padding: 0;
  overflow: hidden;
  border-radius: 6px;
  font-size: 10px;
}
.character-study-examples img {
  width: 100%;
  height: 72px;
  display: block;
  object-fit: cover;
}
.character-study-examples span {
  display: block;
  padding: 5px 2px;
}
.character-study-tabs {
  display: flex;
  border-bottom: 1px solid var(--study-line);
  margin-bottom: 22px;
  padding-bottom: 8px;
  gap: 4px;
}
.character-study-tabs button {
  flex: 1;
  padding: 8px 3px;
  border-color: transparent;
}
.character-study-options fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 22px;
  min-width: 0;
}
.character-study-options legend {
  padding: 0;
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 650;
}
.character-study-parts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}
.character-study-parts button {
  padding: 5px 1px 8px;
  min-width: 0;
  font-size: 10px;
  font-weight: 450;
}
.character-study-parts svg {
  width: 100%;
  height: 48px;
  display: block;
}
.character-study-parts span {
  display: block;
  white-space: nowrap;
}
.character-study-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  padding: 2px;
}
.character-study-swatches button {
  width: 25px;
  height: 25px;
  border: 0;
  padding: 0;
  background: var(--swatch);
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px #00000012;
}
.character-study-swatches button:hover {
  background: var(--swatch);
  transform: scale(1.12);
}
.character-study-swatches button[aria-pressed="true"] {
  background: var(--swatch);
  outline: 1px solid var(--study-accent);
  outline-offset: 3px;
}
.character-study-slider {
  display: block;
  margin: 28px 0;
  font-size: 12px;
}
.character-study-slider > span {
  display: flex;
  justify-content: space-between;
}
.character-study-slider output {
  color: var(--study-muted);
}
.character-study-slider input {
  width: 100%;
  margin: 16px 0 10px;
  accent-color: var(--study-accent);
}
.character-study-range-labels {
  color: var(--study-muted);
  font-size: 10px;
}
.character-study-editor-foot {
  border-top: 1px solid var(--study-line);
  color: var(--study-muted);
  padding-top: 17px;
  margin-top: 12px;
  font-size: 10px;
}
.character-study-main {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) 201px;
}
.character-study-view {
  position: relative;
  min-height: 0;
  overflow: hidden;
  background: #deddd3;
}
.character-study-view canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  outline: 0;
}
.character-study-viewbar {
  position: absolute;
  inset: 20px 24px auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  pointer-events: none;
}
.character-study-viewbar > span {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: #f3f1e9cc;
  padding: 5px 9px;
  border-radius: 5px;
}
.character-study-segment {
  display: flex;
  padding: 3px;
  background: #f3f1e9df;
  border: 1px solid #ffffff50;
  border-radius: 8px;
  pointer-events: auto;
  backdrop-filter: blur(12px);
}
.character-study-segment button {
  padding: 6px 11px;
  border-color: transparent;
  font-size: 11px;
}
.character-study-segment button[aria-pressed="true"] {
  background: var(--study-panel);
  border-color: #c3cabb;
  box-shadow: 0 1px 3px #00000008;
}
.character-study-orbit {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}
.character-study-orbit > span {
  font-size: 10px;
  color: #49554f;
  background: #f3f1e9cc;
  border-radius: 3px;
  padding: 2px 8px;
}
.character-study-render {
  position: absolute;
  bottom: 22px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-radius: 5px;
  background: #f3f1e9dd;
  padding: 8px 10px;
}
.character-study-render label {
  flex-direction: row;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  cursor: pointer;
}
.character-study-render input {
  accent-color: var(--study-accent);
  margin: 0;
  padding: 0;
}
.character-study-comparison {
  border-top: 1px solid var(--study-line);
  padding: 15px 24px;
}
.character-study-comparison-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  gap: 12px;
}
.character-study-comparison h2 {
  font:
    17px Georgia,
    serif;
}
.character-study-comparison h2 span {
  font:
    10px system-ui,
    sans-serif;
  color: var(--study-muted);
  margin-left: 10px;
}
.character-study-comparison p {
  font-size: 10px;
  color: var(--study-muted);
  margin-top: 3px;
}
.character-study-saved {
  display: grid;
  grid-template-columns: repeat(var(--study-slots), minmax(0, 1fr));
  gap: 12px;
}
.character-study-card {
  position: relative;
  height: 99px;
  border: 1px solid var(--study-line);
  border-radius: 6px;
  overflow: hidden;
}
.character-study-card > button:first-child {
  display: flex;
  align-items: end;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  padding: 0;
  text-align: left;
}
.character-study-card img {
  width: 83px;
  height: 100%;
  object-fit: cover;
}
.character-study-card > button:first-child span {
  padding: 10px;
  font-size: 10px;
}
.character-study-card.is-empty {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  border-style: dashed;
  color: #a7afa0;
}
.character-study-card.is-empty > span {
  font:
    20px Georgia,
    serif;
}
.character-study-card.is-empty small {
  font-size: 9px;
  margin-top: 5px;
}
.character-study-card .character-study-remove {
  position: absolute;
  top: 3px;
  right: 3px;
  padding: 0;
  width: 21px;
  height: 21px;
  border: 0;
  background: #f3f1e9dd;
  font-size: 15px;
}
.character-study-footer {
  grid-column: 1 / -1;
  border-top: 1px solid var(--study-line);
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--study-muted);
  font-size: 10px;
  gap: 16px;
}
@media (max-width: 1000px) {
  .character-study {
    grid-template-columns: 290px minmax(0, 1fr);
  }
  .character-study-editor {
    padding: 20px 16px;
  }
  .character-study-card > button:first-child span {
    display: none;
  }
  .character-study-card img {
    width: 100%;
  }
  .character-study-render {
    right: 10px;
    bottom: 18px;
  }
  .character-study-orbit {
    left: 15px;
    transform: none;
  }
  .character-study-viewbar {
    inset: 15px 15px auto;
  }
  .character-study-viewbar > span {
    display: none;
  }
}
@media (max-width: 650px) {
  .character-study {
    overflow-y: auto;
    grid-template: max-content 430px max-content 201px max-content / minmax(0, 1fr);
  }
  .character-study-header {
    grid-column: 1;
    padding: 14px 16px;
    align-items: start;
    flex-direction: column;
    gap: 12px;
  }
  .character-study h1 {
    font-size: 24px;
  }
  .character-study-actions {
    width: 100%;
  }
  .character-study-actions button {
    flex: 1;
    padding: 8px 6px;
  }
  .character-study-main {
    display: contents;
  }
  .character-study-view {
    height: 430px;
    grid-row: 2;
  }
  .character-study-comparison {
    grid-row: 4;
  }
  .character-study-editor {
    grid-row: 3;
    overflow: visible;
    border: 0;
    padding: 22px 18px;
  }
  .character-study-examples {
    margin: 14px 0;
  }
  .character-study-examples img {
    height: 85px;
    object-fit: contain;
    background: #deddd3;
  }
  .character-study-parts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .character-study-footer {
    grid-column: 1;
    grid-row: 5;
    padding: 12px 18px;
    align-items: start;
  }
  .character-study-footer [data-stats] {
    white-space: nowrap;
  }
}

#garrison-panel > label { display: block; margin-block: .75rem; }
#garrison-types { margin-block: .75rem; }
#garrison-types .tray-pic { font-size: 32px; }
.garrison-portrait { width: 56px; height: 56px; image-rendering: pixelated; }
.garrison-summary { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-block: 10px; }
.garrison-summary[hidden], .garrison-summary [hidden] { display: none; }
.garrison-fill { flex: 1; min-width: 140px; border-radius: 5px; overflow: hidden; }
.garrison-fill .chip-qty { justify-content: center; padding-inline: 8px; }
.garrison-fill.is-short .chip-qty, .garrison-shortage { color: var(--danger); }
.garrison-shortage { flex-basis: 100%; margin: 0; font-size: 13px; }

/* UI playground: only the fixture's layout lives here; its controls use the game styles above. */
.ui-playground {
  --ui-playground-menu-space: 78px;
  position: fixed;
  inset: 0;
  z-index: 1000;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: #0c1416;
}

.ui-playground-toolbar {
  display: flex;
  align-items: center;
  gap: 12px 20px;
  flex-wrap: wrap;
  padding: 8px 16px;
  background: #252a2b;
  color: #fff;
  font: 14px sans-serif;
}

.ui-playground-toolbar strong { flex: none; }
.ui-playground-contexts {
  display: flex;
  flex: 1 1 240px;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: thin;
}
.ui-playground-contexts button {
  flex: none;
  white-space: nowrap;
  padding: 7px 10px;
  border: 1px solid #657174;
  border-radius: 3px;
  background: transparent;
  color: #e4e9e9;
  font: inherit;
  cursor: pointer;
}
.ui-playground-contexts button:hover { background: #384346; }
.ui-playground-contexts button[aria-pressed="true"] { background: #e2ebeb; color: #182224; border-color: #e2ebeb; }
.ui-playground-contexts button:focus-visible { outline: 2px solid #c5e6ee; outline-offset: 2px; }
.ui-playground-screen { flex: 1; height: auto; overflow: hidden; display: flex; }
.ui-playground-radio {
  --ui-playground-chat-line: var(--play-line);
  --ui-playground-room-width: 220px;
  flex: 0 0 clamp(280px, 28vw, 640px);
  width: auto;
  container: playground-radio / inline-size;
}
.ui-playground-chat {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  flex: 1;
  min-width: 0;
  min-height: 0;
}
.ui-playground-radio :is(.chat-list-pane, .chat-thread-pane) { width: auto; }
.ui-playground-chat:where(.thread-open) > .chat-list-pane,
.ui-playground-chat:where(:not(.thread-open)) > .chat-thread-pane { display: none; }
.ui-playground-radio .chat-rooms-back { display: inline-flex; }
/* 520px leaves 300px for the thread beside the 220px room list. */
@container playground-radio (min-width: 520px) {
  .ui-playground-chat { grid-template-columns: var(--ui-playground-room-width) minmax(0, 1fr); }
  .ui-playground-chat > :is(.chat-list-pane, .chat-thread-pane) { display: flex; }
  .ui-playground-radio .chat-list-pane { border-right: 1px solid var(--ui-playground-chat-line); }
  .ui-playground-radio .chat-thread-header { display: none; }
}
.ui-playground-avatar {
  display: grid;
  place-items: center;
  width: var(--chat-avatar);
  height: var(--chat-avatar);
  border-radius: 0;
  background: var(--skin-accent);
  color: var(--skin-panel);
  font-weight: 700;
}
.ui-playground-world {
  position: relative;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  background: var(--surface-0);
}
.ui-playground-backdrop {
  position: absolute;
  inset: 0;
  background: center / cover no-repeat;
  filter: blur(3px) brightness(.62);
}
.ui-playground-world .play-top-row { margin: 0 auto; }
.ui-playground-scene {
  position: absolute;
  inset: 110px 0 var(--ui-playground-menu-space);
  overflow-y: auto;
}
.ui-playground-build {
  --panel-tabline-height: 54px;
  position: absolute;
  bottom: var(--ui-playground-menu-space);
  left: 50%;
  width: var(--ui-playground-width, min(var(--float-width), 92%));
  height: min(55%, var(--panel-fixed-max));
  transform: translateX(-50%);
  transition: none;
}
.ui-playground-build .panel-body { flex: 1; }
.ui-playground-menu {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: var(--ui-playground-width, min(var(--float-width), 92%));
  padding: 0;
  background: transparent;
  pointer-events: auto;
}
@media (max-width: 700px) {
  .ui-playground-radio { flex-basis: 38%; }
  .ui-playground-menu { max-width: 100%; overflow: auto; }
}

/* Tracker views use the same panel surfaces and controls as the rest of play. */
.tracker-view { display: flex; flex: 1; flex-direction: column; gap: 12px; min-width: 0; min-height: 0; overflow: auto; }
.tracker-view.tracker-board-open { overflow: hidden; }
.tracker-view .row, .tracker-view .card-meta, .tracker-view .entry-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tracker-board { display: flex; flex: 1; flex-direction: column; gap: 10px; min-height: 0; }
.tracker-statuses { display: flex; gap: 6px; overflow-x: auto; flex: none; padding-bottom: 4px; scrollbar-width: thin; scrollbar-color: var(--scroll) transparent; }
.tracker-status { flex: none; display: flex; align-items: center; gap: 6px; }
.tracker-status-count { color: var(--status, var(--muted)); font-weight: 700; }
.tracker-ticket-list { display: grid; align-content: start; gap: 8px; overflow-y: auto; min-height: 0; scrollbar-width: thin; scrollbar-color: var(--scroll) transparent; }
.tracker-empty { color: var(--muted); margin: 4px 0; }
.tracker-view .card, .tracker-view .entry, .tracker-view .block { display: block; min-width: 0; padding: 10px; border: 1px solid var(--panel-border, var(--line)); border-radius: 8px; background: var(--surface-1, var(--panel)); color: var(--ink); }
.tracker-view .card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; text-decoration: none; }
.tracker-view .card-title { grid-column: 1; grid-row: 1; }
.tracker-view .card-when { grid-column: 2; grid-row: 1; }
.tracker-view .card-meta { grid-column: 1 / -1; }
.tracker-view .card-title, .tracker-view .ticket-title { overflow-wrap: anywhere; }
.tracker-view .card-meta, .tracker-view .byline, .tracker-view .card-when, .tracker-view .muted { color: var(--muted); font-size: var(--meta-text-size); }
.tracker-view .tag { display: inline-block; padding: 2px 5px; border: 1px solid var(--line); border-radius: 4px; }
.tracker-view .entry { margin-top: 8px; }
.tracker-view .entry-actions { margin-left: auto; display: flex; gap: 4px; }
.tracker-view .prose { white-space: pre-wrap; overflow-wrap: anywhere; }
.tracker-view textarea, .tracker-view input { max-width: 100%; }
.tracker-view textarea { width: 100%; }
.tracker-view h1, .tracker-view h3 { margin: 0 0 8px; }

/* A player's report on a ticket: their crest and name over their words, and beside the reporter's
   own report, a box with what only they may do. */
.ticket-filing { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 10px 14px; margin-top: 8px; padding: 10px; border: 1px solid var(--play-line); border-radius: 8px; background: var(--surface-2); }
.ticket-filing-words { flex: 1 1 240px; min-width: 0; }
.ticket-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; font-size: var(--meta-text-size); color: var(--muted); }
.ticket-actions { margin-bottom: 4px; }
.ticket-filing-who { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.ticket-filing-when { align-self: flex-start; margin-left: auto; font-size: var(--meta-text-size); color: var(--muted); white-space: nowrap; }
.ticket-filing-flags { font-size: var(--meta-text-size); color: var(--muted); }
.ticket-filing-profile { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 0; border: 0; background: none; color: inherit; text-align: left; cursor: pointer; }
.ticket-filing-profile:hover .ticket-filing-name, .ticket-filing-profile:focus-visible .ticket-filing-name { text-decoration: underline; }
.ticket-filing-meta { display: flex; flex-direction: column; min-width: 0; }
.ticket-filing-name { font-size: var(--card-title-size); color: var(--text); overflow-wrap: anywhere; }
.ticket-filing-own { flex: none; display: flex; flex-direction: column; gap: 6px; padding: 8px 10px; border: 1px solid var(--play-line-strong); border-radius: 8px; background: var(--surface-1); }
.ticket-filing-own h4 { margin: 0; font-size: var(--caption-text-size); color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.04em; }

/* A filing's images and videos, in a wrapping row of tiles. A tapped image takes the full width;
   the reporter's remove sits on a tile's corner. */
.ticket-media-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.ticket-media { position: relative; display: flex; flex-direction: column; gap: 4px; flex: 0 1 220px; min-width: 0; margin: 0; }
.ticket-media.is-zoomed { flex-basis: 100%; }
.ticket-media img, .ticket-media video { display: block; width: 100%; max-height: 220px; object-fit: contain; border: 1px solid var(--play-line); border-radius: 8px; background: var(--surface-1); }
.ticket-media img { cursor: zoom-in; }
.ticket-media.is-zoomed img { max-height: none; cursor: zoom-out; }
.ticket-media figcaption { font-size: var(--meta-text-size); color: var(--muted); }
.ticket-media > .close-btn { position: absolute; top: 4px; right: 4px; }

/* What the developer wrote about a ticket, under the gear in the developer's colour. */
.tracker-view .ticket-developer { border-color: color-mix(in srgb, var(--developer) 45%, transparent); background: color-mix(in srgb, var(--developer) 8%, var(--surface-1)); }
.ticket-developer-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.tracker-view .ticket-developer-head h3 { margin: 0; color: var(--developer); }
.ticket-developer-badge { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: color-mix(in srgb, var(--developer) 24%, transparent); color: var(--developer); }
.ticket-developer-badge .i { width: 60%; height: 60%; }
.ticket-note { margin-top: 10px; padding: 8px 10px; border: 1px solid var(--play-line); border-radius: 8px; background: var(--surface-1); }
.ticket-note p { margin: 0; }
.ticket-note h4, .ticket-log-title { margin: 0 0 4px; font-size: var(--caption-text-size); color: var(--developer); text-transform: uppercase; letter-spacing: 0.04em; }
.ticket-log-title { margin-top: 14px; }

/* The ticket's log: the lines the tracker posted in its room, each with the System's clanker. */
.ticket-log { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.ticket-log-line { display: flex; align-items: flex-start; gap: 8px; padding: 6px 8px; border-radius: 6px; background: var(--surface-1); }
.ticket-log-mark { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 6px; background: color-mix(in srgb, var(--system) 20%, transparent); color: var(--system); }
.ticket-log-mark .i { width: 70%; height: 70%; }
.ticket-log-text { flex: 1 1 auto; min-width: 0; }
.ticket-log-when { flex: none; font-size: var(--meta-text-size); color: var(--muted); white-space: nowrap; }

.screen-play .site-rewards {
  grid-column: 1 / -1;
  color: var(--text-dim);
  margin-top: 4px;
}

.screen-play .site-rewards[hidden] {
  display: none;
}

.screen-play .site-reward-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 5px;
}

.screen-play .hud-bar {
  box-shadow: none;
  background: var(--skin-panel);
}

.screen-play .card-title {
  text-shadow: none;
  filter: none;
}

.ui-playground-world { container: amber-world / inline-size; }
.ui-playground-world .play-top-row { width: var(--play-width); }
.ui-playground-build { width: var(--play-width); height: 38%; border: 0; border-top: 5px solid var(--skin-accent); padding: 16px; }
.ui-playground-menu { bottom: 0; padding-block: 8px; }
@container amber-world (min-width: 744px) {
  .ui-playground-world .play-top-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
  .ui-playground-world .play-top-controls { position: relative; inset: auto; align-items: stretch; margin-top: var(--play-top-gap); }
  .ui-playground-world .play-right { flex: 1; align-items: stretch; }
  .ui-playground-world .clock { flex: 1; }
}
:where(html.aspect-portrait) .ui-playground-radio { display: none; }
:where(html.aspect-portrait) .ui-playground-menu { height: var(--ui-playground-menu-space); background: var(--skin-panel); }

/* Palette trials are confined to the UI playground. */
.ui-playground-screen[data-palette="slate"] {
  --skin-panel: #22292c; --skin-raised: #394448; --skin-line: #a6b8b9;
  --skin-text: #edf3f0; --skin-muted: #bbc9c5; --skin-accent: #90c6c3; --skin-selected: #395956;
}
.ui-playground-screen[data-palette="navy"] {
  --skin-panel: #171f2c; --skin-raised: #29384a; --skin-line: #91a6bc;
  --skin-text: #edf2f7; --skin-muted: #b6c5d4; --skin-accent: #70a9e7; --skin-selected: #2d496a;
}
.ui-playground-screen[data-palette="plum"] {
  --skin-panel: #292127; --skin-raised: #46363f; --skin-line: #b7a0aa;
  --skin-text: #f5edf0; --skin-muted: #d0bfc6; --skin-accent: #d5a5bd; --skin-selected: #624452;
}
.ui-playground-screen[data-palette="original"] {
  --skin-panel: #26221d; --skin-raised: #3d352b; --skin-line: #b5a38d;
  --skin-text: #f8eedf; --skin-muted: #d8c6af; --skin-accent: #f4bc64; --skin-selected: #5a4328;
}
.ui-playground-palettes { display: flex; gap: 4px; flex-wrap: wrap; }
.ui-playground-palettes button { padding: 5px 9px; border: 1px solid #849395; background: #202b2d; color: #e2ebeb; cursor: pointer; }
.ui-playground-palettes button[aria-pressed="true"] { background: #e2ebeb; color: #182224; }

/* The playgrounds page's list, over the game's page it is built from. */
.playground-list { position: fixed; inset: 0; z-index: 1000; overflow-y: auto; padding: 32px; pointer-events: auto; background: #171d1c; color: #ede9dc; font-family: system-ui, sans-serif; }
.playground-list a { color: #e5b561; line-height: 1.8; }
.warfactory { position: fixed; inset: 0; z-index: 1000; display: block; height: auto; overflow-y: auto; pointer-events: auto; background: #171d1c; color: #ede9dc; font-family: system-ui, sans-serif; padding: 28px clamp(16px, 4vw, 64px) 60px; }
.war-header { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 20px; }
.war-header h1 { margin: 4px 0; font-size: 36px; text-transform: uppercase; letter-spacing: .06em; }
.war-header p, .war-overlay p { margin: 0; color: #adb5a6; }
.war-header small, .war-header > span, .war-overlay small, .war-finish small { color: #d4a55c; font-size: 11px; letter-spacing: .14em; }
.war-preview { position: relative; height: 330px; overflow: hidden; background: #343c38; border: 1px solid #526055; }
.war-stage { position: absolute; inset: 0; }
.war-stage canvas { width: 100%; height: 100%; display: block; touch-action: none; }
.war-overlay { position: absolute; top: 20px; left: 24px; pointer-events: none; text-shadow: 0 1px 5px #111; }
.war-overlay h2 { margin: 6px 0; }
.war-stats { position: absolute; bottom: 0; right: 0; display: flex; flex-wrap: wrap; background: #171d1ce8; }
.war-stats div { min-width: 75px; padding: 12px; border-left: 1px solid #49534c; }
.war-stats small, .war-stats strong { display: block; }
.war-stats small { color: #aab3a5; font-size: 11px; text-transform: uppercase; }
.war-stats strong { font-size: 20px; color: #f4d18b; }
.war-content { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; }
.war-finish h2 { font-size: 16px; text-transform: uppercase; letter-spacing: .06em; }
.war-instruction { color: #d4a55c; margin: 24px 0 12px; }
.war-board { display: grid; grid-template-columns: [label] var(--war-label-width, 85px) repeat(var(--war-columns, 4), [c] minmax(var(--war-card-min, 0px), 1fr)); grid-template-rows: repeat(4, 135px); gap: 10px; }
/* The design bay's board gives every row a label row above it: empty beside the cards, the label itself in portrait.
   Half gaps keep cards 10px apart across the empty one. */
.war-board-v2 { row-gap: 5px; --war-label-row: 0px; }
/* In portrait every column fits the screen: cards shrink to share the width, with tighter gaps, sides, and titles. */
.aspect-portrait .war-board-v2 { grid-template-columns: repeat(var(--war-columns, 4), [c] minmax(0, 1fr)); column-gap: 6px; --war-label-row: auto; }
.aspect-portrait .war-board-v2 .war-card { padding-inline: 6px; }
.aspect-portrait .war-board-v2 .war-card strong { font-size: 14px; }
.war-row-label { grid-row: var(--row); grid-column: label; align-self: center; color: #d4a55c; font-size: 12px; text-transform: uppercase; }
.aspect-portrait .war-row-label { grid-row: var(--above); grid-column: 1 / -1; padding-top: 6px; }
.war-card.craft-card { position: relative; left: auto; bottom: auto; width: auto; height: auto; box-shadow: none; border-radius: 4px; font-family: inherit; }
.war-card.craft-card.is-legal { border-color: #e5b561; box-shadow: 0 0 0 2px #e5b561, 0 0 16px #e5b56177; }
.war-card.craft-card.is-target { transform: scale(1.04); }
.war-designer.craft-hero { position: relative; left: auto; bottom: auto; width: auto; height: auto; padding: 12px; display: grid; align-content: center; background: #e5b561; color: #171d1c; border: 2px solid #fff0c6; border-radius: 4px; font: 700 12px system-ui; }
.war-designer.craft-hero.is-dragging { position: fixed; left: 0; top: 0; z-index: 1010; }
.war-back { margin-top: 12px; }
.war-card { text-align: left; min-height: 135px; display: flex; flex-direction: column; gap: 8px; padding: 14px; background: #29322e; color: #ede9dc; border: 1px solid #536057; cursor: pointer; }
.war-card small { color: #d4a55c; }
.war-card strong { font-size: 16px; }
.war-card span, .war-card em { font-size: 12px; color: #b5beb1; font-style: normal; }
.war-card em { margin-top: auto; }
.war-card.selected { border: 2px solid #e5b561; background: #454735; }
.war-card:disabled { opacity: .42; cursor: not-allowed; }
.war-finish { margin-top: 25px; padding: 20px; background: #29322e; border: 1px solid #536057; align-self: start; }
.war-side { display: grid; gap: 16px; align-self: start; }
.war-side .war-finish { margin-top: 0; }
.war-playtest { display: grid; gap: 10px; padding: 16px 20px; background: #322929; border: 1px solid #605353; }
.war-playtest small { color: var(--war-bad); font-size: 11px; letter-spacing: .14em; }
.war-playtest p { margin: 0; font-size: 12px; color: #beb1b1; }
.war-playtest .war-seed input { flex: 1; }
.war-finish label { display: block; margin: 18px 0; font-size: 13px; }
.war-finish [data-name], .war-finish select { display: block; box-sizing: border-box; width: 100%; margin-top: 6px; padding: 10px; background: #171d1c; color: #ede9dc; border: 1px solid #657267; }
.war-finish p { font-size: 12px; color: #b5beb1; }
.warfactory { --war-good: #7fc26b; --war-bad: #e0705a; --war-trade: #d4a55c; }
.war-seed { display: flex; align-items: center; gap: 6px; font-size: 12px; color: #b5beb1; }
.war-seed input { width: 80px; padding: 6px 8px; background: #171d1c; color: #ede9dc; border: 1px solid #657267; font: inherit; }
.war-gap { grid-column: c / -1; align-self: center; padding-top: 6px; border-top: 1px dashed #536057; color: #d4a55c; font-size: 11px; letter-spacing: .14em; text-align: center; text-transform: uppercase; }
.war-board-v2 .war-card em { align-self: stretch; text-align: center; }
.war-board-v2 .war-card em b { display: block; font-weight: inherit; }
.war-board-v2 .war-card em b.is-good, .war-taken b.is-good, .war-tweak b.is-good { color: var(--war-good); }
.war-board-v2 .war-card em b.is-bad, .war-taken b.is-bad, .war-tweak b.is-bad { color: var(--war-bad); }
.war-taken b { display: block; font-weight: normal; font-size: 12px; }
.war-tweaks small { display: block; margin-top: 18px; }
.war-tweak { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 10px; margin: 12px 0; padding: 4px; font-size: 13px; }
.war-choices { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 4px; }
.war-choice { padding: 5px 8px; background: #171d1c; color: #ede9dc; border: 1px solid #657267; border-radius: 4px; font: inherit; font-size: 12px; cursor: pointer; }
.war-choice.selected { border-color: #e5b561; background: #454735; box-shadow: inset 0 0 0 1px #e5b561; }
.war-choice.is-blocked { border-color: var(--war-bad); box-shadow: 0 0 6px color-mix(in srgb, var(--war-bad) 60%, transparent); cursor: not-allowed; }
.war-tweak input[type=range] { grid-column: 1 / -1; width: 100%; accent-color: #d4a55c; }
.war-tweak input[type=checkbox] { accent-color: #d4a55c; }
.war-tweak em { grid-column: 1 / -1; font-style: normal; }
.war-tweak b { display: block; font-weight: normal; font-size: 12px; color: #b5beb1; }
.war-board-v2 .war-card em b.is-breaks { color: #fff; background: var(--war-bad); font-weight: 700; }
.war-card.craft-card.is-blocked { border-color: var(--war-bad); box-shadow: 0 0 0 2px var(--war-bad), 0 0 16px #e0705a77; cursor: not-allowed; }
/* Icons stand in for a stat's name beside its numbers. */
.warfactory .i { display: inline-block; width: 1.1em; height: 1.1em; flex: none; vertical-align: -0.2em; margin-left: 2px; }
/* A card's points and badge stat, on its top edge at the corners, clear of the title. */
.war-badge { position: absolute; top: -9px; right: 6px; z-index: 1; display: inline-flex; align-items: center; justify-content: center; min-width: 22px; padding: 2px 6px; box-sizing: border-box; border-radius: 10px; color: #171d1c; font: 700 12px system-ui; font-style: normal; text-align: center; }
.war-badge.is-good { background: var(--war-good); }
.war-badge.is-bad { background: var(--war-bad); }
.war-badge.is-left { right: auto; left: 6px; }
/* A cost, under the title. */
.war-badge.is-inline { position: static; align-self: center; justify-self: center; }
/* The design's totals, on the designer. */
.war-badge.is-total { background: #171d1c; color: #e5b561; }
.war-card.is-refused, .war-tweak.is-refused { animation: war-refuse 0.45s ease-out; }
@keyframes war-refuse { 0%, 60% { background: color-mix(in srgb, var(--war-bad) 55%, #29322e); } 15% { translate: -5px 0; } 35% { translate: 5px 0; } 55% { translate: -3px 0; } 100% { translate: 0 0; } }
.war-stats .is-broken strong, .war-stats .is-broken small { color: var(--war-bad); }
.war-designer.craft-hero { gap: 2px; text-align: center; }
.war-designer span { font-weight: 600; font-size: 11px; white-space: nowrap; }
.war-points { display: grid; grid-template-columns: repeat(5, 10px); gap: 2px; justify-content: center; margin-top: 2px; }
.war-points i { width: 10px; height: 7px; border: 1px solid #171d1c; box-sizing: border-box; }
.war-points i.is-full { background: #171d1c; }
/* The limit gauge: one box per unit of the ceiling, filled to the load, red past it. */
.war-load { display: grid; gap: 2px; margin-top: 4px; }
.war-load b { display: flex; gap: 2px; }
.war-load i { flex: 1; height: 9px; border: 1px solid #171d1c; box-sizing: border-box; }
.war-load i.is-full { background: #171d1c; }
.war-load i.is-over { background: var(--war-bad); }
.war-step-back { margin-top: 4px; padding: 3px 6px; background: #171d1c; color: #e5b561; border: 0; border-radius: 3px; font: 700 11px system-ui; cursor: pointer; }
.war-step-back:disabled { opacity: .45; cursor: default; }
.war-designer.craft-hero.is-broken { background: var(--war-bad); color: #fff; }
.war-skills { display: grid; gap: 6px; }
.war-skill { text-align: left; padding: 8px 10px; background: #29322e; color: #ede9dc; border: 1px solid #536057; border-radius: 4px; font: inherit; cursor: pointer; }
.war-skill.selected { border: 2px solid #e5b561; background: #454735; }
.war-skill strong { display: block; font-size: 13px; }
.war-skill span { display: block; font-size: 11px; color: #b5beb1; }
.war-card.war-hidden { align-items: center; justify-content: center; min-height: 0; height: 92px; background: #1f2624; border-style: dashed; }
.war-hidden strong { font-size: 24px; color: #536057; }
.war-card.war-mod { min-height: 0; padding: 10px 12px; gap: 4px; }
.war-stats i { margin-left: 4px; font-size: 12px; font-style: normal; }
.war-stats i.is-good, .war-taken .is-good strong { color: var(--war-good); }
.war-stats i.is-bad, .war-taken .is-bad strong { color: var(--war-bad); }
.war-taken .is-trade strong { color: var(--war-trade); }
.war-taken p { margin: 6px 0 0; }
@media (max-width: 800px) { .war-content { grid-template-columns: 1fr; } .war-board { --war-label-width: 58px; --war-card-min: 105px; overflow-x: auto; } .war-preview { height: 400px; } .war-header > span { display: none; } }

/* Trade pane: the Trading post's market in Manage. */
.trade-head {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 10px;
}

.trade-head p {
  margin: 0;
}

.trade-hours-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.trade-hours-block[hidden] {
  display: none;
}

/* The allowance window as one bar: open, then closed, with a mark at now.
   --open is the open share, --at now's share. */
.trade-hours {
  position: relative;
  height: 10px;
}

.trade-hours-track {
  display: flex;
  height: 100%;
  border-radius: 999px;
  border: 1px solid var(--well-line);
  background: var(--surface-well);
  overflow: hidden;
}

.trade-hours-track > span {
  flex-basis: 0;
}

.trade-hours-track > [data-phase="open"] {
  flex-grow: var(--open);
  background: var(--ok);
}

.trade-hours-track > [data-phase="shut"] {
  flex-grow: calc(1 - var(--open));
  background: var(--alert);
}

.trade-hours-now {
  position: absolute;
  top: -3px;
  bottom: -3px;
  left: var(--at);
  width: 3px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--text);
  box-shadow: 0 0 0 1px #0008;
  transition: left 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.trade-flights {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.trade-flights[hidden] {
  display: none;
}

.trade-flight {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: var(--control-radius);
  background: var(--surface-2);
  font-size: var(--meta-text-size);
}

.trade-rows {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}

/* A Sell row the player holds less than a lot of: listed so they see what
   the market buys, dimmed until they can sell it. */
.trade-row.short {
  opacity: var(--dim-opacity);
}

.screen-play .trade-icon {
  width: var(--good-icon-size);
  height: var(--good-icon-size);
}

/* A row's price line, led by its mark chip when the mark is against the player
   (Overstocked, Scarce). */
.trade-price {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.trade-mark {
  padding: 1px 8px;
  border-radius: var(--control-radius);
  font-size: var(--caption-text-size);
  font-weight: 700;
  white-space: nowrap;
}

/* A deal's badge (In demand, On sale) fills the row's right end to its edges:
   the mark over its percent, larger. */
.trade-deal {
  margin: calc(-1 * var(--row-card-pad-y)) calc(-1 * var(--row-card-pad-x)) calc(-1 * var(--row-card-pad-y)) auto;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4px 14px;
  border-radius: 0 var(--panel-radius-inner) var(--panel-radius-inner) 0;
  font-size: var(--tile-title-size);
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
}

.trade-deal-pct {
  font-size: var(--card-title-size);
}

:is(.trade-mark, .trade-deal)[data-tone="good"] {
  background: var(--ok);
  color: var(--ok-ink);
}

:is(.trade-mark, .trade-deal)[data-tone="warn"] {
  background: var(--warn);
  color: var(--warn-ink);
}

:is(.trade-mark, .trade-deal)[data-tone="alert"] {
  background: var(--alert);
  color: var(--alert-ink);
}


/* The trade view's line on its stop: how far it sits from the normal price,
   in the server's tone. */
.trade-normal {
  margin: 4px 0;
  color: var(--warn);
}

.trade-normal[data-tone="alert"] {
  color: var(--alert);
}

.trade-normal[data-tone="good"] {
  color: var(--ok);
}

/* The trade view: what the trade moves and its average per lot on one line,
   the slider, and the button bottom right. */
.trade-detail:not([hidden]) {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.trade-detail-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

/* The trade view's top right: the row's mark chip, then the average per lot. */
.trade-rate {
  display: flex;
  align-items: center;
  gap: 8px;
}

.trade-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: auto;
  padding-top: 10px;
}

.markdown img {
  max-width: 100%;
  height: auto;
}
