.prob-consecration-screen {
  --prob-peach: #ffb06b;
  --prob-coral: #e75a7c;
  --prob-magenta: #b72b83;
  --prob-gold: #f2c94c;
  --prob-green: #2f9d83;
  --prob-ink: #211324;
  --prob-paper: #fff2cf;
  color: var(--prob-paper);
  overflow-y: auto;
}

.prob-consecration-topbar {
  align-items: center;
  display: grid;
  gap: 16px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  margin-bottom: 10px;
}

.prob-consecration-topbar div {
  min-width: 0;
  text-align: center;
}

.prob-consecration-topbar span {
  color: var(--text-secondary);
  display: block;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prob-consecration-topbar strong {
  color: var(--text-primary);
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.6vw, 2.2rem);
  line-height: 1;
}

.prob-consecration-topbar p {
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 900;
  margin: 0;
  text-align: right;
}

.prob-consecration-progress {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  height: 8px;
  margin-bottom: 10px;
  overflow: hidden;
}

.prob-consecration-progress span {
  background: linear-gradient(90deg, var(--prob-gold), var(--prob-coral), var(--prob-green), var(--prob-magenta));
  display: block;
  height: 100%;
  transition: width 420ms ease;
}

.prob-consecration-stage {
  background:
    radial-gradient(circle at 50% 15%, rgba(242, 201, 76, 0.2), transparent 22%),
    linear-gradient(120deg, rgba(255, 176, 107, 0.16) 0 10%, transparent 10% 20%, rgba(183, 43, 131, 0.14) 20% 30%, transparent 30% 40%),
    linear-gradient(180deg, #54205b 0%, #2f1745 48%, #211324 100%);
  border: 1px solid rgba(255, 242, 207, 0.24);
  border-radius: 8px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
  height: min(760px, calc(100vh - 126px));
  min-height: 650px;
  overflow: hidden;
  position: relative;
}

.prob-tent-architecture {
  inset: 0;
  pointer-events: none;
  position: absolute;
  z-index: 1;
}

.prob-tent-architecture::before {
  background:
    repeating-linear-gradient(100deg, rgba(255, 176, 107, 0.18) 0 8%, rgba(255, 242, 207, 0.08) 8% 16%, rgba(183, 43, 131, 0.16) 16% 24%),
    radial-gradient(ellipse at 50% -4%, rgba(242, 201, 76, 0.18) 0 24%, transparent 25%);
  content: "";
  inset: 0;
  position: absolute;
}

.prob-tent-architecture span {
  background: linear-gradient(180deg, rgba(255, 242, 207, 0.22), rgba(69, 35, 54, 0.84));
  border: 1px solid rgba(255, 242, 207, 0.16);
  bottom: 0;
  position: absolute;
  top: 8%;
  width: 3px;
}

.prob-tent-architecture span:nth-child(1) { left: 10%; }
.prob-tent-architecture span:nth-child(2) { left: 28%; }
.prob-tent-architecture span:nth-child(3) { left: 50%; }
.prob-tent-architecture span:nth-child(4) { right: 28%; }
.prob-tent-architecture span:nth-child(5) { right: 10%; }

.prob-tent-lamps {
  inset: 0;
  pointer-events: none;
  position: absolute;
  z-index: 3;
}

.prob-tent-lamps span {
  background: radial-gradient(circle, #fff6bf 0 18%, #f2c94c 42%, rgba(242, 201, 76, 0) 70%);
  border-radius: 50%;
  height: 74px;
  position: absolute;
  top: 10%;
  width: 74px;
}

.prob-tent-lamps span:nth-child(1) { left: 14%; }
.prob-tent-lamps span:nth-child(2) { left: 34%; top: 6%; }
.prob-tent-lamps span:nth-child(3) { right: 34%; top: 6%; }
.prob-tent-lamps span:nth-child(4) { right: 14%; }

.prob-prize-counter {
  bottom: 0;
  height: 142px;
  left: 50%;
  pointer-events: none;
  position: absolute;
  transform: translateX(-50%);
  width: min(940px, 78%);
  z-index: 2;
}

.prob-prize-counter span {
  background:
    repeating-linear-gradient(90deg, rgba(255, 242, 207, 0.08) 0 1px, transparent 1px 82px),
    linear-gradient(180deg, #8c4c35, #3a1f27);
  border: 1px solid rgba(255, 242, 207, 0.16);
  border-radius: 50% 50% 12px 12px / 14% 14% 12px 12px;
  bottom: 0;
  box-shadow: 0 18px 35px rgba(0, 0, 0, 0.34);
  height: 118px;
  left: 0;
  position: absolute;
  right: 0;
}

.prob-prize-counter i {
  background: linear-gradient(90deg, var(--prob-gold), var(--prob-coral));
  border-radius: 999px;
  bottom: 88px;
  box-shadow: 0 0 20px rgba(242, 201, 76, 0.36);
  height: 9px;
  left: 24%;
  position: absolute;
  right: 24%;
}

.prob-tree {
  background:
    radial-gradient(circle at 20% 18%, rgba(33, 19, 36, 0.08) 0 2px, transparent 3px),
    radial-gradient(circle at 74% 12%, rgba(33, 19, 36, 0.08) 0 2px, transparent 3px),
    repeating-linear-gradient(38deg, rgba(33, 19, 36, 0.04) 0 1px, transparent 1px 18px),
    #fff2cf;
  border: 10px solid rgba(118, 59, 38, 0.96);
  border-radius: 8px;
  box-shadow: inset 0 0 34px rgba(33, 19, 36, 0.24), 0 28px 50px rgba(0, 0, 0, 0.34);
  color: var(--prob-ink);
  height: clamp(500px, 57vw, 545px);
  left: 50%;
  padding: 15px 16px 18px;
  position: absolute;
  top: 4%;
  transform: translateX(-50%);
  width: min(760px, 61%);
  z-index: 5;
}

.prob-tree__title {
  align-items: baseline;
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.prob-tree__title span {
  color: rgba(33, 19, 36, 0.62);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prob-tree__title strong {
  color: #6c2456;
  font-family: var(--font-display);
  font-size: 1.26rem;
}

.prob-tree__trunks {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  min-height: 228px;
  position: relative;
  z-index: 3;
}

.prob-trunk {
  border: 1px solid rgba(33, 19, 36, 0.12);
  border-radius: 7px;
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  opacity: 0.62;
  padding: 9px;
  position: relative;
  transition: opacity 600ms ease, box-shadow 600ms ease, background 600ms ease;
}

.prob-trunk.is-lit {
  background: rgba(255, 255, 255, 0.3);
  box-shadow: inset 0 0 20px rgba(242, 201, 76, 0.18), 0 0 18px rgba(242, 201, 76, 0.2);
  opacity: 1;
}

.prob-trunk--simple.is-lit { border-color: rgba(242, 201, 76, 0.55); }
.prob-trunk--counting.is-lit { border-color: rgba(47, 157, 131, 0.48); }
.prob-trunk--compounds.is-lit { border-color: rgba(231, 90, 124, 0.48); }
.prob-trunk--strategic.is-lit { border-color: rgba(183, 43, 131, 0.48); }

.prob-trunk__branch {
  background: currentColor;
  border-radius: 999px;
  height: 4px;
  left: 14px;
  opacity: 0.34;
  position: absolute;
  right: 14px;
  top: 70px;
  transform: rotate(var(--branch-tilt, 0deg));
}

.prob-trunk--simple { color: #a77b10; --branch-tilt: -9deg; }
.prob-trunk--counting { color: #237f6b; --branch-tilt: -3deg; }
.prob-trunk--compounds { color: #c44665; --branch-tilt: 3deg; }
.prob-trunk--strategic { color: #8f2368; --branch-tilt: 9deg; }

.prob-trunk__label {
  min-height: 48px;
}

.prob-trunk__label span {
  color: rgba(33, 19, 36, 0.52);
  display: block;
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.prob-trunk__label strong {
  color: currentColor;
  display: block;
  font-size: clamp(0.72rem, 0.9vw, 0.86rem);
  line-height: 1.1;
}

.prob-trunk__slots {
  display: grid;
  gap: 9px;
  grid-template-rows: repeat(2, minmax(72px, 1fr));
}

.prob-artifact {
  background: rgba(33, 19, 36, 0.14);
  border: 1px dashed rgba(33, 19, 36, 0.2);
  border-radius: 6px;
  color: rgba(33, 19, 36, 0.56);
  display: grid;
  min-width: 0;
  overflow: hidden;
  padding: 8px;
  place-items: center;
  position: relative;
  text-align: center;
  transition: background 600ms ease, border-color 600ms ease, box-shadow 600ms ease, color 600ms ease, transform 600ms ease;
}

.prob-artifact.is-lit {
  border-style: solid;
  color: #fff9dc;
  transform: translateY(-1px);
}

.prob-artifact--simple.is-lit { background: linear-gradient(180deg, #f2c94c, #8a6817); }
.prob-artifact--counting.is-lit { background: linear-gradient(180deg, #3ab89b, #1f5f52); }
.prob-artifact--compounds.is-lit { background: linear-gradient(180deg, #ee738f, #7b2641); }
.prob-artifact--strategic.is-lit { background: linear-gradient(180deg, #c04f9b, #5d204c); }

.prob-artifact.is-missing {
  filter: saturate(0.78);
}

.prob-artifact span {
  background: rgba(255, 242, 207, 0.92);
  border-radius: 50%;
  color: var(--prob-ink);
  font-size: 0.65rem;
  font-weight: 900;
  height: 20px;
  left: 6px;
  line-height: 20px;
  position: absolute;
  top: 6px;
  width: 20px;
}

.prob-artifact strong {
  font-size: clamp(0.62rem, 0.8vw, 0.76rem);
  line-height: 1.08;
  max-width: 100%;
}

.prob-artifact i {
  background: currentColor;
  border-radius: 999px;
  bottom: 7px;
  height: 3px;
  left: 20px;
  opacity: 0.42;
  position: absolute;
  right: 20px;
}

.prob-tree__roots {
  background:
    linear-gradient(70deg, transparent 0 45%, rgba(116, 72, 46, 0.62) 45% 47%, transparent 47%),
    linear-gradient(110deg, transparent 0 53%, rgba(116, 72, 46, 0.62) 53% 55%, transparent 55%),
    linear-gradient(90deg, transparent 0 49%, rgba(116, 72, 46, 0.66) 49% 51%, transparent 51%);
  height: 92px;
  left: 12%;
  pointer-events: none;
  position: absolute;
  right: 12%;
  top: 254px;
  z-index: 1;
}

.prob-tree-root {
  background: linear-gradient(180deg, #fff8e2, #e7ca89);
  border: 2px solid rgba(33, 19, 36, 0.22);
  border-radius: 7px;
  bottom: 48px;
  box-shadow: 0 14px 26px rgba(33, 19, 36, 0.22);
  color: var(--prob-ink);
  cursor: pointer;
  display: grid;
  gap: 4px;
  left: 50%;
  min-height: 154px;
  padding: 13px 18px;
  place-items: center;
  position: absolute;
  text-align: center;
  transform: translateX(-50%);
  width: min(480px, 72%);
  z-index: 4;
}

.prob-tree-root:disabled {
  cursor: default;
}

.prob-tree-root.is-target {
  animation: probRootPulse 1300ms ease-in-out infinite;
}

.prob-tree-root em {
  color: rgba(33, 19, 36, 0.52);
  font-style: normal;
  font-weight: 900;
}

.prob-tree-root span {
  color: #8f2368;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prob-tree-root p {
  font-size: 0.78rem;
  line-height: 1.2;
  margin: 0;
}

.prob-tree-root strong,
.prob-tree-root b {
  display: block;
  font-family: var(--font-display);
  line-height: 1;
}

.prob-tree-root strong {
  color: #6c2456;
  font-size: clamp(1rem, 1.5vw, 1.36rem);
}

.prob-tree-root b {
  color: #9b6d09;
  font-size: clamp(0.98rem, 1.3vw, 1.2rem);
}

.prob-lockbox {
  background: linear-gradient(180deg, #8f5a38, #3d2024);
  border: 2px solid rgba(255, 242, 207, 0.24);
  border-radius: 6px;
  bottom: 14px;
  box-shadow: 0 13px 20px rgba(33, 19, 36, 0.32);
  height: 46px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  transition: transform 500ms ease, box-shadow 500ms ease;
  width: 130px;
  z-index: 5;
}

.prob-lockbox span {
  background: rgba(33, 19, 36, 0.28);
  border-radius: 5px 5px 0 0;
  height: 20px;
  left: 14px;
  position: absolute;
  right: 14px;
  top: -16px;
  transform-origin: left bottom;
  transition: transform 500ms ease;
}

.prob-lockbox strong {
  color: var(--prob-gold);
  display: block;
  font-family: var(--font-display);
  font-size: 1.1rem;
  line-height: 42px;
  opacity: 0;
  text-align: center;
  transition: opacity 500ms ease;
}

.prob-lockbox.is-open {
  box-shadow: 0 13px 20px rgba(33, 19, 36, 0.32), 0 0 22px rgba(242, 201, 76, 0.28);
}

.prob-lockbox.is-open span {
  transform: rotate(-28deg) translateY(-2px);
}

.prob-lockbox.is-open strong {
  opacity: 1;
}

.prob-master,
.prob-apprentice {
  background: transparent;
  border: 0;
  color: var(--prob-paper);
  cursor: pointer;
  padding: 0;
  position: absolute;
  text-align: center;
  z-index: 8;
}

.prob-master:disabled,
.prob-apprentice:disabled {
  cursor: default;
}

.prob-master.is-target .prob-master__sprite,
.prob-apprentice.is-target .prob-apprentice__sprite {
  filter: drop-shadow(0 0 18px rgba(242, 201, 76, 0.82));
  transform: translateY(-4px);
}

.prob-master__sprite,
.prob-apprentice__sprite {
  display: block;
  height: 124px;
  margin: 0 auto 6px;
  position: relative;
  transition: transform 240ms ease, filter 240ms ease;
  width: 82px;
}

.prob-master__sprite i,
.prob-apprentice__sprite i {
  background: #bd815c;
  border-radius: 42% 42% 48% 48%;
  height: 44px;
  left: 22px;
  position: absolute;
  top: 0;
  width: 38px;
}

.prob-master__sprite b,
.prob-apprentice__sprite b {
  background: linear-gradient(180deg, var(--prob-magenta), #4b1d56);
  border-radius: 24px 24px 10px 10px;
  height: 80px;
  left: 14px;
  position: absolute;
  top: 42px;
  width: 54px;
}

.prob-master__sprite em,
.prob-apprentice__sprite em {
  background: rgba(255, 242, 207, 0.84);
  border-radius: 999px;
  height: 8px;
  left: 16px;
  position: absolute;
  top: 70px;
  transform: rotate(-16deg);
  width: 50px;
}

.prob-master__name,
.prob-master__role,
.prob-apprentice strong {
  display: block;
  text-shadow: 0 3px 10px rgba(0, 0, 0, 0.6);
}

.prob-master__name,
.prob-apprentice strong {
  font-family: var(--font-display);
  font-size: 0.96rem;
}

.prob-master__role {
  color: rgba(255, 242, 207, 0.76);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.prob-master__line {
  background: rgba(255, 242, 207, 0.97);
  border: 1px solid rgba(242, 201, 76, 0.28);
  border-radius: 8px;
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.26);
  color: var(--prob-ink);
  display: block;
  font-size: 0.88rem;
  left: 50%;
  line-height: 1.2;
  min-width: 190px;
  padding: 9px 11px;
  position: absolute;
  top: -54px;
  transform: translateX(-50%);
}

.prob-master--solen { left: 7%; top: 18%; }
.prob-master--aldra { left: 8%; bottom: 20%; }
.prob-master--pellan { right: 8%; top: 18%; }
.prob-master--veth { right: 8%; bottom: 20%; }

.prob-master--solen .prob-master__sprite b { background: linear-gradient(180deg, #d8a923, #705719); }
.prob-master--aldra .prob-master__sprite b { background: linear-gradient(180deg, #2f9d83, #1e5048); }
.prob-master--pellan .prob-master__sprite b { background: linear-gradient(180deg, #e75a7c, #69233a); }
.prob-master--veth .prob-master__sprite b { background: linear-gradient(180deg, #8f2368, #3b1837); }

.prob-apprentice {
  bottom: 9%;
  left: 50%;
  transform: translateX(-50%);
}

.prob-apprentice__pins {
  background: linear-gradient(90deg, #c04f9b, var(--prob-gold));
  border-radius: 5px;
  display: block;
  height: 34px;
  left: 50%;
  opacity: 1;
  position: absolute;
  top: 64px;
  transform: translateX(-50%) rotate(-5deg);
  transition: opacity 420ms ease;
  width: 58px;
}

.prob-apprentice.has-pinned .prob-apprentice__pins {
  opacity: 0.18;
}

.prob-consecration-cue {
  background: rgba(33, 19, 36, 0.88);
  border: 1px solid rgba(255, 242, 207, 0.18);
  border-radius: 8px;
  bottom: 22px;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.34);
  color: var(--prob-paper);
  left: 50%;
  max-width: min(700px, 74%);
  padding: 14px 18px;
  position: absolute;
  text-align: center;
  transform: translateX(-50%);
  z-index: 12;
}

.prob-consecration-cue span {
  color: rgba(255, 242, 207, 0.68);
  display: block;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prob-consecration-cue h1 {
  color: #fff7d6;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 2rem);
  line-height: 1;
  margin: 2px 0 6px;
}

.prob-consecration-cue p {
  color: rgba(255, 242, 207, 0.88);
  font-size: 0.95rem;
  line-height: 1.25;
  margin: 0;
}

.prob-consecration-cue strong {
  color: var(--prob-gold);
  display: block;
  font-size: 0.86rem;
  margin-top: 8px;
  text-transform: uppercase;
}

.prob-title-card {
  background:
    radial-gradient(circle at 50% 18%, rgba(242, 201, 76, 0.24), transparent 28%),
    linear-gradient(140deg, #b72b83, #54205b 45%, #211324);
  border: 1px solid rgba(242, 201, 76, 0.34);
  border-radius: 8px;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.44);
  display: grid;
  min-height: min(760px, calc(100vh - 126px));
  overflow: hidden;
  padding: 42px 24px;
  place-items: center;
  position: relative;
  text-align: center;
}

.prob-title-card > span {
  color: rgba(255, 242, 207, 0.72);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.prob-title-card p {
  color: var(--prob-paper);
  font-size: 1.05rem;
  margin: 0;
}

.prob-title-card h1 {
  color: #f8dc83;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 5rem);
  line-height: 0.94;
  margin: 10px 0 6px;
  max-width: 900px;
}

.prob-title-stars {
  color: rgba(255, 255, 255, 0.24);
  font-size: 1.8rem;
  margin-bottom: 18px;
}

.prob-title-stars span.is-filled {
  color: var(--prob-gold);
}

.prob-title-card__sparks {
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.prob-title-card__sparks span {
  animation: probSpark 4200ms ease-in-out infinite;
  background: rgba(242, 201, 76, 0.5);
  border-radius: 50%;
  height: 8px;
  position: absolute;
  width: 8px;
}

.prob-title-card__sparks span:nth-child(1) { left: 18%; top: 32%; }
.prob-title-card__sparks span:nth-child(2) { left: 72%; top: 24%; animation-delay: 600ms; }
.prob-title-card__sparks span:nth-child(3) { left: 28%; top: 70%; animation-delay: 1100ms; }
.prob-title-card__sparks span:nth-child(4) { left: 82%; top: 64%; animation-delay: 1700ms; }

@keyframes probRootPulse {
  0%, 100% { box-shadow: 0 14px 26px rgba(33, 19, 36, 0.22), 0 0 0 0 rgba(242, 201, 76, 0.34); }
  50% { box-shadow: 0 14px 26px rgba(33, 19, 36, 0.22), 0 0 0 12px rgba(242, 201, 76, 0); }
}

@keyframes probSpark {
  0%, 100% {
    opacity: 0.2;
    transform: translateY(0);
  }
  50% {
    opacity: 0.8;
    transform: translateY(-24px);
  }
}

@media (max-width: 980px) {
  .prob-consecration-stage {
    height: auto;
    min-height: 760px;
  }

  .prob-tree {
    width: 82%;
  }

  .prob-master--solen { left: 3%; top: 20%; }
  .prob-master--aldra { left: 3%; bottom: 23%; }
  .prob-master--pellan { right: 3%; top: 20%; }
  .prob-master--veth { right: 3%; bottom: 23%; }

  .prob-consecration-cue {
    max-width: calc(100% - 32px);
  }
}

@media (max-width: 720px) {
  .prob-consecration-topbar {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .prob-consecration-topbar p {
    text-align: center;
  }

  .prob-tree {
    height: 560px;
    top: 3%;
    width: calc(100% - 28px);
  }

  .prob-tree__trunks {
    gap: 6px;
  }

  .prob-trunk {
    padding: 7px;
  }

  .prob-trunk__label span {
    display: none;
  }

  .prob-artifact strong {
    font-size: 0.58rem;
  }

  .prob-tree-root {
    width: 82%;
  }

  .prob-master__line {
    min-width: 150px;
  }

  .prob-master__name,
  .prob-master__role {
    display: none;
  }
}
