.v3-page {
  --v3-gold: #ffcf61;
  --v3-gold-light: #ffe49a;
  --v3-blue: #9adffa;
  --v3-navy: #0c1c30;
  --v3-muted: #b7cde1;
  --accent: var(--v3-gold);
  background:
    radial-gradient(ellipse 64rem 38rem at 67% -5rem, #16456b 0, transparent 83%),
    #0a1728;
  color: #f8fafc;
}
.v3-page .header {
  background: #0a1a2bdd;
  border-color: #88c5e334;
}
.v3-page .header-inner { min-height: 3.6rem; }
.v3-page .brand-mark {
  border-color: #ffc75f65;
  background: #ffcf6116;
}
.v3-page .brand-mark i { background: var(--v3-gold); }
.v3-page .edition {
  order: -1;
  color: #f5faff;
  font-size: 1rem;
  font-weight: 750;
  letter-spacing: -.035em;
  text-transform: uppercase;
}
.v3-edition-number { color: var(--v3-gold); font-size: 1.15em; }
.v3-page .edition span { color: var(--v3-muted); font-size: .8em; letter-spacing: 0; text-transform: none; }
.v3-page .brand { color: var(--v3-muted); font-weight: 580; }
.v3-page :focus-visible { outline-color: var(--v3-blue); }

.v3-hero {
  display: grid;
  grid-template-areas: "art" "intro" "preview" "action";
  gap: .75rem;
  padding-bottom: 1.5rem;
}
.v3-intro { grid-area: intro; min-width: 0; }
.v3-kicker {
  display: inline-flex;
  padding: .12rem .5rem .15rem;
  border: 1px solid #ffd36c80;
  border-radius: .3rem;
  background: #102e4a;
  color: var(--v3-gold-light);
  font-size: .8125rem;
  font-weight: 700;
}
.v3-hero h1 {
  margin-top: .34rem;
  font-size: clamp(1.75rem, 7.75vw, 3.35rem);
  font-weight: 750;
  line-height: 1.05;
  letter-spacing: -.059em;
  text-wrap: initial;
}
.v3-emphasis, .v3-game-name { display: inline-block; max-width: 100%; }
.v3-emphasis { color: var(--v3-gold); }

.v3-art {
  position: relative;
  grid-area: art;
  display: grid;
  align-items: end;
  isolation: isolate;
  overflow: hidden;
  margin: 0 calc(-1 * var(--gutter));
  aspect-ratio: 1.34;
  border-bottom: 1px solid #8edbfb9e;
  border-radius: 0 0 .85rem .85rem;
  background: linear-gradient(155deg, #74cce9 10%, #38aeba 68%, #ffd69c 94%);
  box-shadow: 0 .7rem 1.9rem #03121a7b;
}
.v3-art img {
  position: absolute;
  z-index: -1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  color: #092e45;
  font-size: .9rem;
}
.v3-art figcaption {
  place-self: end start;
  margin: .5rem var(--gutter);
  padding: .19rem .4rem;
  border-radius: .29rem;
  background: #091d2de8;
  color: #f8fafc;
  font-size: .6875rem;
  font-weight: 570;
}
.v3-hero-art-factor {
  position: absolute;
  right: var(--gutter);
  bottom: .5rem;
  padding: .12rem .55rem;
  border: 1px solid var(--v3-gold);
  border-radius: .4rem;
  background: #12243e;
  color: var(--v3-gold-light);
  font-size: 1.24rem;
  font-weight: 750;
  line-height: 1.28;
  box-shadow: inset 0 1px #fff3b94a, 0 2px 0 #05121f9c;
}

.v3-hero-preview { grid-area: preview; }
.v3-hero-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: .32rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.v3-hero-flow li {
  position: relative;
  display: grid;
  align-content: space-between;
  gap: .18rem;
  min-width: 0;
  padding: .35rem .27rem .38rem;
  border: 1px solid #467799;
  border-radius: .43rem;
  background: linear-gradient(145deg, #163d59, #0f253c 83%);
  text-align: center;
}
.v3-hero-flow li + li::before {
  position: absolute;
  top: calc(50% - .16rem);
  left: -.27rem;
  width: .26rem;
  height: .26rem;
  border-top: 1px solid #9adffa;
  border-right: 1px solid #9adffa;
  transform: rotate(45deg);
  content: "";
}
.v3-hero-flow span {
  color: #d2e2f0;
  font-size: clamp(.7rem, 2.95vw, .8rem);
  line-height: 1.15;
}
.v3-hero-flow strong {
  color: #f5faff;
  font-size: clamp(1.25rem, 5.05vw, 1.85rem);
  font-weight: 740;
  line-height: 1.08;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
}
.v3-hero-flow li:last-child {
  border-color: #ffcf61a8;
  background: linear-gradient(145deg, #3a362d, #213049 90%);
}
.v3-hero-flow li:last-child strong { color: var(--v3-gold-light); }
.v3-hero-context {
  margin-top: .4rem;
  color: var(--v3-muted);
  font-size: .8125rem;
  line-height: 1.32;
}
.v3-hero-action { grid-area: action; }
.v3-page .v3-primary {
  width: 100%;
  min-height: 3.15rem;
  border-color: #ffe49a;
  background: linear-gradient(#ffe391, #ffc34b);
  color: #18202b;
  box-shadow: inset 0 1px #fff7c1, 0 3px #7a4f27a1;
  font-size: 1rem;
}
.v3-page .v3-primary:hover { background: var(--v3-gold-light); }
.v3-play {
  width: .5rem;
  height: .62rem;
  margin-right: .55rem;
  background: currentColor;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.v3-example {
  max-width: 44rem;
  margin-inline: auto;
  padding-block: 1.3rem 2rem;
  border-top: 1px solid #8edbfb4c;
  scroll-margin-top: .5rem;
}
.v3-example h2 {
  font-size: clamp(1.6rem, 6.3vw, 2.35rem);
  line-height: 1.1;
  letter-spacing: -.045em;
}
.v3-example-intro {
  max-width: 42ch;
  margin-top: .38rem;
  color: var(--v3-muted);
  font-size: .9375rem;
}

.v3-round {
  display: grid;
  gap: .55rem;
  margin-top: .9rem;
  padding: .52rem;
  border: 1px solid #4d819b;
  border-radius: .85rem;
  background: #10273e;
}
.v3-round-art {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  height: clamp(7.1rem, 32vw, 12rem);
  border-radius: .45rem;
  background: #358ba7 url("tr2-coast.webp") center 26% / cover no-repeat;
}
.v3-multiplier {
  position: absolute;
  right: .55rem;
  bottom: .5rem;
  padding: .12rem .55rem;
  border: 1px solid #ffe1a9;
  border-radius: .45rem;
  background: #102332eb;
  color: var(--v3-gold-light);
  font-size: 1.2rem;
  font-weight: 750;
  line-height: 1.35;
}
.v3-module {
  position: absolute;
  top: 29%;
  left: 57.5%;
  width: 25%;
  aspect-ratio: 3.1;
  transform: translateX(-50%);
  clip-path: polygon(50% 0, 100% 31%, 100% 69%, 50% 100%, 0 70%, 0 31%);
  background: linear-gradient(153deg, #fff1d6 11%, #d6a58b 42%, #a37665 69%, #503a45 91%);
  opacity: 0;
}
.v3-module::after {
  content: "";
  position: absolute;
  inset: 49% 14% 21%;
  transform: skewY(6deg);
  background: repeating-linear-gradient(90deg, transparent 0 13%, #213f73 13% 24%);
}
.v3-round:is([data-phase="secured"], [data-phase="building"]) .v3-module {
  opacity: 1;
  animation: v3-lower 650ms cubic-bezier(.25,.61,.35,1) both;
}
.v3-round[data-phase="fallen"] .v3-module { animation: v3-fall 420ms ease-in both; }
@keyframes v3-lower {
  from { transform: translate(-50%, -60%); }
  to { transform: translate(-50%, 12%); }
}
@keyframes v3-fall {
  from { transform: translate(-50%, 12%); opacity: 1; }
  to { transform: translate(165%, 290%) rotate(37deg); opacity: 0; }
}

.v3-stats, .v3-result-split {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .35rem;
  margin: 0;
}
.v3-stats div { padding: .3rem .4rem; border-radius: .35rem; background: #081b2d; }
.v3-stats dt, .v3-result-split dt {
  color: var(--v3-muted);
  font-size: .75rem;
  font-weight: 560;
}
.v3-stats dd, .v3-result-split dd {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 720;
  line-height: 1.16;
  font-variant-numeric: tabular-nums;
  word-break: break-word;
}
#stage-credit { color: #a3f1c7; }
.v3-stage-state {
  padding-inline: .15rem;
  color: #dbeafa;
  font-size: .8125rem;
  line-height: 1.36;
}
.v3-round[data-phase="fallen"] .v3-stage-state { color: #ffcfab; }

.v3-choices { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: .42rem; }
.v3-choice {
  border-color: #6297b786;
  background: #17344e;
  color: #f5faff;
}
.v3-choice[data-choice="half"] {
  grid-column: 1 / -1;
  border-color: #ffe4a5;
  background: var(--v3-gold);
  color: #18202b;
}
.v3-choice:not([data-choice="half"]):is(:hover, [aria-pressed="true"]) {
  border-color: var(--v3-blue);
  background: #235176;
}
.v3-choice[data-choice="half"]:is(:hover, [aria-pressed="true"]) { background: var(--v3-gold-light); }
.v3-choice[aria-disabled="true"] { cursor: progress; }

.v3-result { display: grid; gap: .55rem; margin-top: .65rem; }
.v3-result-main {
  display: grid;
  gap: .5rem;
  padding: .8rem;
  border: 1px solid #91dcb68c;
  border-radius: .78rem;
  background: linear-gradient(136deg, #123c40, #10253c 82%);
}
.v3-result[data-outcome="continue"] .v3-result-main { border-color: #f8ba8590; }
.v3-result-label { font-size: .8125rem; color: var(--v3-muted); }
.v3-result-title {
  margin: 0;
  color: #a3f1c7;
  font-size: clamp(2rem, 10vw, 2.8rem);
  line-height: 1;
  letter-spacing: -.055em;
  font-variant-numeric: tabular-nums;
}
.v3-result[data-outcome="continue"] .v3-result-title { color: #ffca96; }
.v3-result-split { grid-template-columns: repeat(2, minmax(0,1fr)); gap: .65rem; }
.v3-result-split div { min-width: 0; padding-top: .42rem; border-top: 1px solid #a2d6e750; }
.v3-result-explanation { font-size: .9375rem; line-height: 1.35; }
.v3-conditional { color: var(--v3-muted); font-size: .8125rem; line-height: 1.37; }
.v3-result .owner-actions { margin-top: 0; }
.v3-result .next-step { width: 100%; }
.v3-replay {
  justify-self: start;
  padding-inline: .16rem;
  color: var(--v3-blue);
  background: transparent;
  text-decoration: underline;
  text-underline-offset: .2em;
}

@media (max-width: 359px) {
  .v3-page .header-inner { min-height: 3.3rem; }
  .v3-page .edition { font-size: .9rem; }
  .v3-page .brand { font-size: .73rem; }
  .v3-hero { gap: .62rem; }
  .v3-result-split dd { font-size: 1.02rem; }
}

@media (min-width: 600px) {
  .v3-round { padding: .75rem; }
  .v3-result-main { padding: 1rem; }
}

@media (min-width: 780px) {
  .v3-page .header-inner { min-height: 4rem; }
  .v3-hero {
    grid-template-areas: "intro art" "preview art" "action art";
    grid-template-columns: minmax(0,.86fr) minmax(0,1.14fr);
    grid-template-rows: auto auto auto;
    align-items: center;
    column-gap: clamp(1.4rem, 3.4vw, 3.1rem);
    row-gap: 1rem;
    padding-block: clamp(2.3rem, 4.5vw, 4.2rem);
  }
  .v3-intro { align-self: end; }
  .v3-hero h1 { font-size: clamp(2.2rem, 4.05vw, 3.75rem); }
  .v3-art {
    margin: 0;
    aspect-ratio: 1.14;
    border: 1px solid #8edbfb7d;
    border-radius: .9rem;
  }
  .v3-hero-action { align-self: start; }
  .v3-hero-action .button { width: auto; padding-inline: 1.65rem; }
  .v3-example { padding-block: 1.55rem 3rem; }
  .v3-round {
    grid-template-columns: minmax(0,1.13fr) minmax(0,1fr);
    align-items: center;
    gap: .65rem .8rem;
  }
  .v3-round-art { grid-column: 1; grid-row: 1 / 4; height: 12rem; }
  .v3-static-tip { grid-column: 2; }
}
