/* r228.css (#1014 / #1064) — Strict 2-Font Unification, Zero-Void 308px Callings & 288px Realms, Target Hero & Unwrapped Footer:
   1. Global: Strict Cinzel (--display) across ALL CTAs & Realm display tabs + Alegreya (--body) across ALL prose;
      gold-accented skill trigger cards + bronze active wash on WARRIOR Path tab + muted DWARF/HALFLING padlocks +
      uniform underlined gold Spheres membership links.
   2. Desktop (>= 1041px): Protected lower-left Hero crowd scrim, richer gold H1 line 2, ribbon promo & bottom fold fade;
      unclipped Priest headroom (8%); 2-line CENTRAL REALM / THALENYR tab symmetry & 288px framed BORN OF card;
      zero-void 308px 3-column Callings lockup (flush baseline across Fighter, BODY & WARRIOR); crisp WebGPU pill &
      balanced footer legal padding.
   3. Mobile (<= 699px): Upper-615px Hero painting framing matching target-phone.png face clearance + 32px safe area;
      128px Slice 1 top mountain fade & spaced tabs; generous 8% Priest headroom + 224px clip & 16px dot pitch;
      138px full-bleed rounded Calling stage (0 dome hard cut) + legible 11px skills & dark locked ancestries;
      unwrapped 2-row footer bar (Spheres Membership + Back to top ↑ above © 2026) on aligned 16px gutters.
   Preserves all sacred owner locks (content.js verbatim copy, 0 step badges, .chapter-divider, R08/R09/R31/R32, spheres.html). */

/* ============================================================================
   1. GLOBAL TYPOGRAPHY CONTRACT, CONTROL DIFFERENTIATION & ACTIVE/LOCK GRAMMAR
   ============================================================================ */
html:root body header#bar.bar a.btn.btn-play,
html:root body #hero .hero-cta a.btn.btn-play,
html:root body #hero .hero-cta a.btn.btn-play span,
html:root body #hero .hero-cta a.btn.btn-ghost,
html:root body #play .final-copy a.btn.btn-play,
html:root body #play .final-copy a.btn.btn-play span,
html:root body section#play.final #account-mount a#sign-in.final-signin,
html:root body section#realms #realm-tabs > button.tab,
html:root body section#realms #realm-tabs > button#realm-tab-thalenyr {
  font-family: var(--display, "Soul Cinzel", "Cinzel", Georgia, serif) !important;
}
html:root body section#realms #realm-tabs > button.tab .rof {
  font-family: var(--ui-sans) !important;
}

html:root body #hero .cta-notes p.note#hero-note,
html:root body #world .s-copy p:not(.eyebrow),
html:root body #journey figcaption p,
html:root body section#realms #realm-stage #realm-card p.law,
html:root body section#realms #realm-stage #realm-card ul li,
html:root body #callings #calling-panel .adv-card p.about,
html:root body section#callings #lock-note,
html:root body section#play.final .final-copy p.final-member-note,
html:root body footer#account.foot .foot-tagline,
html:root body footer#account.foot .foot-legal p {
  font-family: var(--body, "Soul Dialogue", "Alegreya", Georgia, serif) !important;
}

/* Distinct interactive trigger grammar for Skill Previews (vs Ancestry/Body radio tiles) */


/* Unify warm antique-gold active surface on WARRIOR Path tab matching FIGHTER / HUMAN / MALE */
html:root body main section#callings #calling-panel .adv-row .adv-btn[aria-selected="true"] {
  background: linear-gradient(180deg, rgba(84, 60, 25, 0.88) 0%, rgba(32, 22, 11, 0.96) 100%) !important;
  border: 1px solid rgba(236, 204, 134, 0.84) !important;
  box-shadow: inset 0 1px 0 rgba(255, 242, 198, 0.28), 0 0 10px rgba(218, 176, 92, 0.14) !important;
  color: #fff8e8 !important;
}

/* Muted padlock color on locked DWARF/HALFLING matching dimmed text */
html:root body main section#callings #calling-panel button.cp-chip:has(.cp-lock) .cp-lock {
  color: #968974 !important;
  opacity: 0.88 !important;
}

/* Consistent underlined gold link styling across Callings, Closing CTA & Footer */
html:root body a.membership-inline-link,
html:root body footer#account.foot a.foot-meta-spheres {
  color: #e6c57a !important;
  text-decoration: underline !important;
  text-underline-offset: 3px !important;
  text-decoration-color: rgba(230, 197, 122, 0.55) !important;
}

/* ============================================================================
   2. DESKTOP (>= 1041px): HERO SCRIM, 2-LINE CENTRAL REALM TAB, ZERO-VOID 308PX CALLINGS
   ============================================================================ */
@media (min-width: 1041px) {
  html:root body #hero .hero-shade {
    background:
      radial-gradient(ellipse 56% 40% at 18% 82%, rgba(8, 6, 4, 0.92) 0%, rgba(8, 6, 4, 0.64) 56%, rgba(8, 6, 4, 0) 100%),
      linear-gradient(90deg, rgba(10, 8, 6, 0.86) 0%, rgba(10, 8, 6, 0.46) 44%, rgba(10, 8, 6, 0.06) 76%, rgba(10, 8, 6, 0.14) 100%),
      linear-gradient(180deg, rgba(10, 8, 6, 0.44) 0%, rgba(10, 8, 6, 0) 24%, rgba(10, 8, 6, 0) 72%, rgba(12, 9, 6, 0.88) 92%, #0e0b08 100%) !important;
  }
  html:root body section#hero.hero .hero-copy h1#hero-title span:last-child {
    color: #eab95c !important;
  }
  html:root body section#hero.hero .cta-notes p.note#hero-note,
  html:root body #hero .cta-notes .promo {
    border: 0 !important;
    border-left: 2px solid rgba(230, 194, 116, 0.68) !important;
    border-radius: 0 3px 3px 0 !important;
    background: linear-gradient(90deg, rgba(10, 8, 5, 0.78) 0%, rgba(10, 8, 5, 0.44) 78%, rgba(10, 8, 5, 0) 100%) !important;
    box-shadow: none !important;
    padding: 6px 20px 6px 12px !important;
  }
  html:root body main section#hero.hero .hero-copy ul.hero-facts {
    background: linear-gradient(90deg, rgba(8, 6, 4, 0.72) 0%, rgba(8, 6, 4, 0.46) 76%, rgba(8, 6, 4, 0) 100%) !important;
    padding: 10px 28px 10px 12px !important;
    border-left: 2px solid rgba(230, 194, 116, 0.36) !important;
  }

  /* Slice 2 Desktop: Unclipped Priest headroom */
  html:root body #game-band figure.frame:nth-child(1) .clip img {
    object-position: 50% 8% !important;
  }

  /* Slice 3 Desktop: 2-line CENTRAL REALM tab matching REALM OF SKY/FIRE/SEA/STONE + 288px zero-void card */
  html:root body section#realms #realm-tabs > button#realm-tab-thalenyr::after {
    content: "CENTRAL REALM" !important;
    order: -1 !important;
    display: block !important;
    font-family: var(--ui-sans) !important;
    font-size: 9px !important;
    font-weight: 600 !important;
    letter-spacing: 0.12em !important;
    color: rgba(232, 206, 152, 0.88) !important;
    margin-bottom: 1px !important;
  }
  html:root body section#realms.band {
    padding: 112px 0 132px !important;
  }
  html:root body section#realms .realm-media,
  html:root body section#realms .realm-pics,
  html:root body section#realms #realm-card {
    height: 314px !important;
    min-height: 314px !important;
    max-height: 314px !important;
  }
  html:root body section#realms #realm-card {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    padding: 20px 26px !important;
  }
  html:root body section#realms #realm-stage #realm-card p.law,
  html:root body section#realms #realm-card p.law {
    background: rgba(218, 180, 108, 0.08) !important;
    border: 1px solid rgba(218, 180, 108, 0.22) !important;
    border-left: 3px solid #e0ba6c !important;
    padding: 8px 12px !important;
    margin: 2px 0 !important;
  }
  html:root body section#realms #realm-card ul {
    gap: 8px !important;
  }

  /* Slice 4 Desktop: Zero-void 338px 3-column lockup with flush baseline across Fighter, BODY & WARRIOR */
  html:root body section#callings.band {
    padding: 176px 0 54px !important;
  }
  html:root body #callings #calling-panel,
  html:root body section#callings #calling-panel {
    min-height: 0 !important;
    padding: 18px 24px !important;
    align-items: stretch !important;
  }
  html:root body #callings #calling-panel .calling-base > .adv-media.base-fig {
    height: 338px !important;
    min-height: 338px !important;
    max-height: 338px !important;
    background-color: #140f0b !important;
    background-image:
      radial-gradient(ellipse 68% 74% at 50% 44%, rgba(226, 182, 98, 0.14) 0%, rgba(16, 12, 9, 0.88) 72%, #120e0a 100%),
      url("art/band-skills-900.webp") !important;
    background-size: 100% 100%, cover !important;
    background-position: center, 50% 30% !important;
  }
  html:root body #callings #calling-panel .calling-base > div:not(.adv-media) {
    height: 338px !important;
    min-height: 338px !important;
    max-height: none !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    gap: 0 !important;
    padding: 0 !important;
  }
  html:root body #callings #calling-panel .calling-base .cp-toggle.cp-desk {
    margin-top: 0 !important;
    gap: 10px !important;
  }
  html:root body #callings #calling-panel .cp-desk .cp-trow button.cp-chip {
    min-height: 38px !important;
    height: 38px !important;
  }
  html:root body #callings #calling-panel > .adv {
    height: 338px !important;
    min-height: 338px !important;
    max-height: 338px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
  }
  html:root body #callings #calling-panel > .adv > .adv-card {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: auto !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: stretch !important;
    padding: 12px 0 0 !important;
    margin-top: 10px !important;
  }
  html:root body #callings #calling-panel .adv-card .adv-media.figure {
    width: 168px !important;
    min-width: 168px !important;
    height: 100% !important;
    min-height: 0 !important;
    max-height: 100% !important;
    align-self: stretch !important;
  }

  /* Slice 5 Desktop: High-contrast WebGPU backing & balanced legal padding */
  html:root body section#play.final .final-copy p.req {
    background: rgba(10, 8, 5, 0.82) !important;
    border-radius: 3px !important;
    padding: 4px 14px !important;
    color: #efe2c8 !important;
  }
  html:root body footer#account.foot .wrap.foot-legal {
    padding-top: 16px !important;
    padding-bottom: 16px !important;
  }
}

/* ============================================================================
   3. MOBILE (<= 699px): TARGET-PHONE 615PX HERO, 138PX FULL-BLEED STAGE & CLEAN 2-ROW FOOTER BAR
   ============================================================================ */
@media (max-width: 699px) {
  /* Slice 0: Upper-615px Hero painting framing clearing woman's face above pill + iOS 32px safe-area */
  html:root body section#hero.hero {
    background-color: #100c08 !important;
  }
  html:root body #hero .hero-art,
  html:root body #hero .hero-art picture,
  html:root body #hero .hero-poster,
  html:root body #hero .hero-canvas {
    top: 0 !important;
    bottom: auto !important;
    height: 615px !important;
    max-height: 615px !important;
    object-fit: cover !important;
    object-position: 52% 26% !important;
  }
  html:root body #hero .hero-art {
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 74%, rgba(0, 0, 0, 0) 100%) !important;
    mask-image: linear-gradient(180deg, #000 0%, #000 74%, rgba(0, 0, 0, 0) 100%) !important;
  }
  html:root body #hero .hero-shade {
    background:
      radial-gradient(ellipse 58% 28% at 84% 16%, rgba(255, 146, 54, 0.30) 0%, rgba(214, 96, 30, 0.10) 52%, rgba(0, 0, 0, 0) 100%),
      radial-gradient(ellipse 32% 18% at 10% 54%, rgba(16, 12, 8, 0.92) 0%, rgba(16, 12, 8, 0) 100%),
      radial-gradient(ellipse 68% 18% at 50% 13%, rgba(8, 6, 4, 0.44) 0%, rgba(8, 6, 4, 0) 100%),
      linear-gradient(180deg, rgba(8, 6, 4, 0.42) 0%, rgba(8, 6, 4, 0) 24%, rgba(8, 6, 4, 0) 48%, rgba(16, 12, 8, 0.88) 66%, #100c08 76%, #100c08 100%) !important;
  }
  html:root body section#hero.hero .hero-copy p#hero-eyebrow.eyebrow {
    border: 1px solid rgba(218, 180, 108, 0.16) !important;
    background: rgba(12, 9, 6, 0.84) !important;
  }
  html:root body section#hero.hero .hero-copy h1#hero-title {
    font-size: 25px !important;
    padding-right: 6px !important;
  }
  html:root body #hero .hero-copy {
    padding-bottom: 84px !important;
  }
  html:root body #hero .hero-dots {
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 14px !important;
    bottom: 32px !important;
    border: 1px solid rgba(218, 180, 108, 0.22) !important;
  }
  html:root body #hero .motion-toggle {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    bottom: 28px !important;
  }

  /* Slice 1: Smooth top mountain fade under sticky header & breathable 4-tab tracking */
  html:root body section#world.band .sunder::before {
    height: 128px !important;
    background: linear-gradient(180deg, #0d0a07 0%, rgba(13, 10, 7, 0.72) 48%, rgba(13, 10, 7, 0) 100%) !important;
  }
  html:root body section#world.band .sunder .s-mark {
    padding: 0 2px !important;
  }
  html:root body #world .sunder .s-mark::after {
    font-size: 9.5px !important;
    letter-spacing: 0.02em !important;
  }

  /* Slice 2 & 3: Generous Priest headroom, >=44px 16px-pitch dot row, clean sticky clearance above THE REALMS */
  html:root body section#journey.band {
    padding: 76px 0 24px !important;
  }
  html:root body #journey .j-swipe figure.frame > .clip {
    min-height: 224px !important;
  }
  html:root body #journey .j-swipe figure.frame .clip img {
    object-position: 50% 8% !important;
  }
  html:root body #journey .j-dots {
    gap: 16px !important;
    min-height: 44px !important;
  }
  html:root body section#realms.band {
    padding: 168px 0 8px !important;
  }

  /* Slice 4: Full-bleed rounded 138px vaulted stage (0 top cut) + legible 11px skills + clear unlocked vs locked */
  html:root body section#callings.band {
    padding: 72px 0 0 !important;
  }
  html:root body section#callings #calling-panel .cp97 .v0 {
    padding: 0 12px 6px 12px !important;
    gap: 3px !important;
  }
  html:root body section#callings #calling-panel .cp97 .v0 .cp-fig {
    margin: 0 -12px 6px -12px !important;
    width: calc(100% + 24px) !important;
    border-radius: 3px 3px 0 0 !important;
    flex: 0 0 138px !important;
    height: 138px !important;
    min-height: 138px !important;
    max-height: 138px !important;
    background-color: #120e0a !important;
    background-image:
      linear-gradient(180deg, rgba(16, 12, 8, 0.68) 0%, rgba(16, 12, 8, 0) 24%),
      radial-gradient(ellipse 52% 14% at 50% 94%, rgba(0, 0, 0, 0.90) 0%, rgba(0, 0, 0, 0) 100%),
      radial-gradient(ellipse 48% 82% at 50% 52%, rgba(18, 13, 9, 0.68) 0%, rgba(226, 182, 98, 0.18) 48%, rgba(14, 10, 7, 0.94) 96%),
      url("art/band-skills-900.webp") !important;
    background-size: 100% 100%, 100% 100%, 100% 100%, cover !important;
    background-position: center, center, center, 50% 34% !important;
  }
  html:root body section#callings #calling-panel .cp97 .v0 .cp-fig > img,
  html:root body #callings #calling-panel .cp97 .v0 .cp-fig > img,
  html:root body #callings #calling-panel .cp97 .cp-dfig > img {
    height: 130px !important;
    max-height: 130px !important;
    width: auto !important;
    object-fit: contain !important;
  }
  html:root body section#callings #calling-panel .cp97 .v0 .cp-toggle .cp-trow button.cp-chip {
    min-height: 40px !important;
    height: 40px !important;
  }
  html:root body main section#callings #calling-panel .cp97 .v0 .cp-toggle .cp-trow button.cp-chip[aria-checked="false"]:not([data-v="dwarf"]):not([data-v="halfling"]):not(:has(.cp-lock)) {
    background: rgba(28, 21, 14, 0.92) !important;
    border: 1px solid rgba(226, 190, 114, 0.36) !important;
    color: #efe2c8 !important;
  }
  html:root body main section#callings #calling-panel .cp97 .v0 .cp-toggle .cp-trow button.cp-chip[aria-checked="false"]:is([data-v="dwarf"], [data-v="halfling"]) {
    background: rgba(8, 6, 4, 0.95) !important;
    border: 1px solid rgba(138, 122, 96, 0.16) !important;
    color: #827664 !important;
  }

  /* Slice 5 Mobile: Matched 272px PLAY/SIGN IN + 16px gutter + clean 2-row unwrapped footer bar */
  html:root body section#play.final {
    padding: 58px 16px 22px !important;
  }
  html:root body #play .final-copy a.btn.btn-play,
  html:root body section#play.final #account-mount a#sign-in.final-signin {
    width: 272px !important;
    min-width: 272px !important;
    max-width: 272px !important;
  }
  html:root body footer#account.foot .wrap,
  html:root body footer#account.foot .wrap.foot-grid,
  html:root body footer#account.foot .wrap.foot-legal,
  html:root body footer#account.foot .wrap.foot-meta {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
  html:root body footer#account.foot .wrap.foot-meta {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    row-gap: 2px !important;
    column-gap: 12px !important;
    align-items: center !important;
    padding-top: 2px !important;
    padding-bottom: 8px !important;
  }
  html:root body footer#account.foot .wrap.foot-meta a.foot-meta-spheres,
  html:root body footer#account.foot .foot-meta a.foot-meta-spheres {
    grid-column: 1 !important;
    grid-row: 1 !important;
    justify-self: start !important;
    min-height: 44px !important;
    font-size: 12.5px !important;
    white-space: nowrap !important;
  }
  html:root body footer#account.foot .wrap.foot-meta a[href="#top"],
  html:root body footer#account.foot .foot-meta a[href="#top"] {
    grid-column: 2 !important;
    grid-row: 1 !important;
    justify-self: end !important;
    min-height: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    font-size: 12.5px !important;
    white-space: nowrap !important;
  }
  html:root body footer#account.foot .wrap.foot-meta .foot-copy {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    font-size: 12px !important;
    color: rgba(214, 198, 170, 0.72) !important;
    white-space: nowrap !important;
  }
}
