:root {
  color-scheme: dark;
  font-family: "Space Grotesk", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  --bg: #050713;
  --panel: rgba(10, 14, 36, 0.65);
  --glass: rgba(255, 255, 255, 0.08);
  --accent: #8c5bff;
  --accent-2: #16ffe0;
  --text: #e0e3ff;
  --muted: #9ea3c7;
  --rail-width: clamp(180px, 14vw, 300px);
  --stage-size: min(640px, 52vw, 65vh);
}

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

body {
  --page-gutter: clamp(1.5rem, 4vw, 3rem);
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 20% 20%, #1a1d3f 0%, #050713 60%);
  color: var(--text);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 1.5rem;
  padding: clamp(0.35rem, 1.5vh, 0.9rem) var(--page-gutter) clamp(2rem, 6vh, 4rem);
  padding-left: calc(var(--page-gutter) + var(--rail-width));
  padding-right: calc(var(--page-gutter) + var(--rail-width));
}

.page-layout {
  width: min(1700px, 100%);
  margin: 0 auto;
  display: block;
  position: relative;
}

.ad-rail {
  border-radius: 24px;
  min-height: clamp(380px, 65vh, 640px);
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  top: 50%;
  width: var(--rail-width);
  transform: translateY(-50%);
  z-index: 4;
}

.ad-rail--left {
  left: clamp(0.6rem, 2vw, 1.8rem);
}

.ad-rail--right {
  right: clamp(0.6rem, 2vw, 1.8rem);
}

.ad-rail__content {
  padding: 1rem;
  margin: clamp(1.5rem, 4vw, 2.5rem) auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  gap: 0.5rem;
}

.ad-rail__unit {
  width: 100%;
  min-height: 300px;
}

.ad-slot {
  margin: clamp(1.5rem, 4vw, 2.5rem) auto;
  border-radius: 32px;
}

.ad-slot__inner {
  padding: clamp(1.5rem, 4vw, 2.5rem);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.ad-slot__unit {
  width: 100%;
  min-height: 250px;
}

.ad-slot--collapsed {
  display: none;
}

.ad-slot__inner span {
  font-size: 0.9rem;
  letter-spacing: 0.2rem;
  text-transform: uppercase;
}

.ad-placeholder {
  text-transform: uppercase;
  letter-spacing: 0.2rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.site-footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.6;
}

.site-footer p {
  margin: 0.1rem 0;
}

.section-heading {
  max-width: 720px;
  margin: 0 auto clamp(1.5rem, 4vw, 3rem);
  text-align: center;
}

.section-heading .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.24rem;
  font-size: 0.75rem;
  color: var(--accent-2);
}

.value-grid {
  background: rgba(5, 7, 25, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: clamp(1.5rem, 4vw, 3.5rem);
  margin: clamp(2rem, 5vw, 4rem) auto;
  backdrop-filter: blur(12px);
}

.value-grid__items {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: clamp(1rem, 3vw, 1.8rem);
}

.value-grid__items article {
  padding: 1rem 1.1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.04);
  box-shadow: 0 20px 40px rgba(5, 7, 19, 0.35);
}

.value-grid__items h3 {
  margin-top: 0;
}

.how-it-works {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
  margin: clamp(2rem, 5vw, 4rem) auto;
}

.how-it-works__content,
.how-it-works__tips {
  padding: clamp(1.25rem, 4vw, 2.5rem);
  border-radius: 24px;
  background: rgba(5, 7, 25, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  min-height: 100%;
}

.how-it-works__content ol {
  counter-reset: steps;
  padding-left: 1rem;
  line-height: 1.6;
}

.how-it-works__content li {
  margin-bottom: 0.6rem;
}

.how-it-works__tips ul {
  padding-left: 1.1rem;
  line-height: 1.6;
}

.how-it-works__note {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.use-case-grid {
  margin: clamp(2rem, 5vw, 4rem) auto;
}

.use-case-grid__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: clamp(1rem, 3vw, 2rem);
}

.use-case-grid__list article {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 22px;
  padding: 1.25rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.use-case-grid__list ul {
  padding-left: 1.1rem;
  margin: 0 0 0.75rem;
}

.trust-panel {
  margin: clamp(2rem, 5vw, 4rem) auto;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: 28px;
  background: linear-gradient(120deg, rgba(140, 91, 255, 0.12), rgba(22, 255, 224, 0.08));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.trust-panel__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: clamp(1rem, 3vw, 2rem);
  margin-top: clamp(1rem, 3vw, 2rem);
}

.trust-panel__grid article {
  background: rgba(5, 7, 25, 0.82);
  border-radius: 20px;
  padding: 1.2rem 1.4rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.faq {
  margin: clamp(2rem, 5vw, 4rem) auto;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: 28px;
  background: rgba(5, 7, 25, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.faq__items details {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.75rem 0;
}

.faq__items details:last-child {
  border-bottom: none;
}

.faq__items summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.faq__items summary::marker,
.faq__items summary::-webkit-details-marker {
  display: none;
}

.faq__items details p {
  margin: 0.4rem 0 0;
  color: var(--muted);
}

.cta-banner {
  margin: clamp(2rem, 5vw, 4rem) auto;
  padding: clamp(1.25rem, 4vw, 2.5rem);
  border-radius: 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: rgba(140, 91, 255, 0.15);
  border: 1px solid rgba(140, 91, 255, 0.4);
  flex-wrap: wrap;
}

.secondary-cta {
  min-width: 200px;
  border-radius: 999px;
  padding: 0.85rem 1.6rem;
  background: var(--accent-2);
  color: #04162a;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.secondary-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 30px rgba(5, 7, 19, 0.4);
}

.grid-bg {
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 80px 80px;
  opacity: 0.25;
  z-index: -2;
}

.interface-controls {
  position: fixed;
  top: clamp(0.8rem, 3vh, 1.6rem);
  left: clamp(1rem, 3vw, 3rem);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.6rem;
  z-index: 5;
}

.language-toggle {
  position: static;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 1rem;
  background: rgba(5, 7, 19, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(5, 7, 19, 0.55);
  z-index: 5;
}

.language-toggle label {
  font-size: 0.75rem;
  letter-spacing: 0.18rem;
  text-transform: uppercase;
  color: var(--accent-2);
}

.language-toggle select {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.language-flags {
  display: flex;
  gap: 0.35rem;
}

.mode-picker {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.75rem 0.95rem;
  background: rgba(5, 7, 19, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(5, 7, 19, 0.55);
  min-width: 180px;
  width: 100%;
  position: relative;
  z-index: 3;
}

.mode-picker label {
  font-size: 0.75rem;
  letter-spacing: 0.18rem;
  text-transform: uppercase;
  color: var(--accent);
}

.mode-picker select {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.rarity-toggle,
.sound-toggle {
  display: flex;
  width: 100%;
  justify-content: flex-start;
}

.sound-toggle {
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.rarity-toggle[hidden],
.sound-toggle[hidden] {
  display: none;
}

.rarity-toggle__label,
.sound-toggle__label {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.65rem;
  width: auto;
  font-size: 0.75rem;
  letter-spacing: 0.14rem;
  text-transform: uppercase;
  color: var(--muted);
  cursor: pointer;
  padding: 0.2rem 0;
  line-height: 1;
}

.rarity-toggle__text,
.sound-toggle__text {
  display: inline-block;
  transform: translateY(-7px);
}

.rarity-toggle__checkbox,
.sound-toggle__checkbox {
  appearance: none;
  width: 42px;
  height: 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  position: relative;
  flex-shrink: 0;
  transition: background 0.2s ease;
  margin-top: 4px;
}

.rarity-toggle__checkbox::after,
.sound-toggle__checkbox::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #050713;
  top: 2px;
  left: 3px;
  transition: transform 0.25s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
}

.rarity-toggle__checkbox:checked,
.sound-toggle__checkbox:checked {
  background: linear-gradient(120deg, var(--accent-2), #7ef9ff);
}

.rarity-toggle__checkbox:checked::after,
.sound-toggle__checkbox:checked::after {
  transform: translateX(18px);
}

.sound-toggle__volume {
  flex: 1;
  min-width: 120px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
  appearance: none;
  outline: none;
  cursor: pointer;
  position: relative;
  margin-left: auto;
}

.sound-toggle__volume:focus-visible {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
}

.sound-toggle__volume:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.sound-toggle__volume::-webkit-slider-thumb {
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--accent-2), #7ef9ff);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
  margin-top: -5px;
}

.sound-toggle__volume::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--accent-2), #7ef9ff);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
  border: none;
}

.sound-toggle__volume::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
}

.sound-toggle__volume::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
}

.mode-dropdown {
  position: relative;
  width: 100%;
}

.mode-dropdown__toggle {
  width: 100%;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.65rem;
  padding: 0.55rem 0.85rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.mode-dropdown__toggle svg {
  transition: transform 0.25s ease;
  margin-left: auto;
  flex-shrink: 0;
}

.mode-picker.is-open .mode-dropdown__toggle svg {
  transform: rotate(180deg);
}

.mode-dropdown__menu {
  list-style: none;
  margin: 0;
  padding: 0.35rem;
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  right: 0;
  background: rgba(5, 7, 19, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  display: none;
  z-index: 30;
}

.mode-picker.is-open .mode-dropdown__menu {
  display: block;
  animation: dropdown-fade 0.18s ease;
}

.mode-dropdown__menu button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
  border: none;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.6rem 0.8rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.mode-dropdown__menu button[aria-selected="true"] {
  background: rgba(140, 91, 255, 0.15);
  color: var(--accent-2);
}

.mode-dropdown__menu button:is(:hover, :focus-visible) {
  background: rgba(255, 255, 255, 0.08);
  outline: none;
}

.mode-option__content {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex: 1;
}

.mode-option__label {
  flex: 1;
}

.mode-option__icon {
  width: 26px;
  height: 26px;
  display: block;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.35));
}

@keyframes dropdown-fade {
  from {
    opacity: 0;
    transform: translateY(0.3rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.flag-btn {
  width: 34px;
  height: 24px;
  padding: 0;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(6, 12, 26, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.flag-btn img {
  width: 24px;
  height: 16px;
  display: block;
  border-radius: 3px;
}

.flag-btn:is(:hover, :focus-visible) {
  border-color: var(--accent-2);
  box-shadow: 0 0 8px rgba(22, 255, 224, 0.45);
  transform: translateY(-1px);
}

.flag-btn.is-active {
  border-color: var(--accent);
  box-shadow: 0 0 12px rgba(140, 91, 255, 0.5);
}

.controls {
  position: relative;
  z-index: 2;
}

.shell {
  width: 100%;
  margin: 0;
  padding: 3rem clamp(2rem, 4.5vw, 3.4rem) 3.2rem;
}

header {
  text-align: center;
  margin: 0 0 1rem;
}

.seo-highlight {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.75rem;
  margin: 2rem auto 2.5rem;
  padding: clamp(1.5rem, 3vw, 2.2rem);
  background: rgba(5, 7, 25, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  backdrop-filter: blur(14px);
  box-shadow: 0 22px 55px rgba(5, 7, 19, 0.65);
}

.seo-copy h2 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.6rem, 3vw, 2rem);
  text-transform: capitalize;
}

.seo-copy p {
  margin: 0 0 0.75rem;
  color: var(--muted);
  line-height: 1.65;
}

.wheel-preview {
  margin: 0;
  text-align: center;
}

.wheel-preview img {
  width: min(360px, 100%);
  height: auto;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 45px rgba(5, 7, 19, 0.7);
}

.wheel-preview figcaption {
  margin-top: 0.6rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.seo-translations {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.seo-translations article {
  padding: 1rem 1.1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(6, 10, 24, 0.7);
}

.seo-translations h3 {
  margin: 0 0 0.45rem;
  font-size: 1rem;
}

.seo-translations p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--muted);
}

.eyebrow {
  letter-spacing: 0.3rem;
  text-transform: uppercase;
  color: var(--accent-2);
  font-size: 0.8rem;
}

h1 {
  font-size: clamp(2.8rem, 6vw, 4.2rem);
  margin: 0.4rem 0 0.6rem;
}

.logo-title {
  display: inline-block;
  font-weight: 600;
  background: linear-gradient(
    120deg,
    #ff5f6d,
    #ffc371,
    #7ef9ff,
    #16ffe0,
    #a86bff,
    #ff5f6d
  );
  background-size: 400% 400%;
  -webkit-background-clip: text;
  color: transparent;
  animation: rainbow-shift 6s linear infinite;
  text-shadow:
    0 0 12px rgba(255, 255, 255, 0.4),
    0 0 24px rgba(140, 91, 255, 0.55),
    0 0 48px rgba(22, 255, 224, 0.4);
}

.lede {
  margin: 0 auto;
  max-width: 540px;
  color: var(--muted);
  font-size: 1rem;
}

.panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2.2rem;
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: clamp(1.6rem, 3vw, 2.4rem);
  backdrop-filter: blur(18px);
  box-shadow: 0 28px 65px rgba(5, 7, 19, 0.85);
}

.controls label {
  display: block;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.2rem;
  font-size: 0.9rem;
  color: var(--accent-2);
}

.option-form {
  margin-bottom: 1.25rem;
}

.option-input-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

input[type="text"] {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 1.05rem 1.2rem;
  background: rgba(5, 7, 19, 0.9);
  color: var(--text);
  font-family: inherit;
  font-size: 1.05rem;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

input[type="text"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 20px rgba(140, 91, 255, 0.3);
}

.options-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.options-header {
  display: flex;
  margin-bottom: 0;
  font-size: 0.9rem;
  letter-spacing: 0.05rem;
  text-transform: uppercase;
  color: var(--muted);
}


button {
  border: none;
  border-radius: 999px;
  padding: 1rem 1.7rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

button:active {
  transform: translateY(2px);
}

button.share-link {
  background: none;
  padding: 0;
  border-radius: 0;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08rem;
  color: var(--accent-2);
  text-decoration: underline;
  text-underline-offset: 0.15rem;
}

button.share-link:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 4px;
}

button.share-link:hover {
  color: #a8fff5;
}

button.share-link:disabled {
  opacity: 0.4;
  pointer-events: none;
  text-decoration: none;
}

button.primary {
  background: linear-gradient(120deg, var(--accent), #cf5fff);
  color: white;
  box-shadow: 0 12px 30px rgba(140, 91, 255, 0.4);
}

button.ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 16px;
  padding: 0.75rem 1.4rem;
  backdrop-filter: blur(6px);
}

button.accent {
  background: var(--winner-accent, var(--accent-2));
  color: #061316;
  border-radius: 16px;
  padding: 0.9rem 1.6rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.overlay-actions {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 1.5rem;
  width: 100%;
}

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

.overlay-back-link {
  margin-top: 1.5rem;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0;
  border: none;
  border-radius: 0;
  background: none;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.2rem;
  transition: color 0.2s ease;
}

.overlay-back-link:focus-visible {
  outline: 2px solid var(--winner-accent, var(--accent-2));
  outline-offset: 4px;
}

.overlay-back-link:hover {
  color: var(--winner-accent, var(--accent-2));
}

.overlay-back-icon {
  display: inline-flex;
  align-items: center;
  line-height: 0;
}

.overlay-back-icon svg {
  display: block;
  width: 1.2rem;
  height: auto;
}

.options-scroll {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background: rgba(5, 7, 19, 0.6);
  height: clamp(240px, 40vh, 360px);
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-color: rgba(22, 255, 224, 0.65) rgba(255, 255, 255, 0.05);
  position: relative;
}

.options-scroll::-webkit-scrollbar {
  width: 10px;
}

.options-scroll::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 22px;
}

.options-scroll::-webkit-scrollbar-thumb {
  background: linear-gradient(160deg, rgba(22, 255, 224, 0.95), rgba(126, 249, 255, 0.95));
  border: 2px solid rgba(5, 7, 19, 0.6);
  border-radius: 12px;
  box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.35);
}

.options-scroll::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(160deg, rgba(52, 255, 230, 1), rgba(174, 255, 255, 1));
}

.controls .mode-picker {
  margin-top: 1.25rem;
}

.options-list {
  list-style: none;
  margin: 0;
  padding: 0;
  min-height: 100%;
}

.options-list:empty::after {
  content: "No options yet. Add one above.";
  display: block;
  padding: 1.2rem;
  color: var(--muted);
  text-align: center;
}

.option-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  position: relative;
  z-index: 1;
  transition: box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.option-row.is-new {
  animation: option-pop 0.45s ease;
}

.option-row:last-child {
  border-bottom: none;
}

.option-row.is-editing {
  background: rgba(22, 255, 224, 0.05);
}

body[data-rarities="enabled"] .option-row[data-has-rarity="true"] {
  background: rgba(5, 7, 19, 0.9);
  border-bottom-color: rgba(255, 255, 255, 0.18);
  box-shadow:
    0 0 18px rgba(0, 0, 0, 0.5),
    0 0 35px var(--rarity-glow, transparent);
}

body[data-rarities="enabled"] .option-row[data-has-rarity="true"]::after {
  content: "";
  position: absolute;
  inset: 0.4rem;
  border-radius: 18px;
  background: radial-gradient(circle, var(--rarity-glow, transparent), transparent 65%);
  filter: blur(8px);
  opacity: 0.85;
  z-index: -1;
  pointer-events: none;
}

.option-content {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.option-content span {
  word-break: break-word;
}


.option-actions {
  display: flex;
  gap: 0.4rem;
}

.icon-btn {
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
  border-radius: 14px;
  padding: 0.4rem 0.65rem;
  min-width: 2.4rem;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: var(--accent-2);
}

.icon-btn.confirm {
  background: linear-gradient(120deg, var(--accent-2), #7ef9ff);
  color: #03161d;
  box-shadow: 0 10px 25px rgba(22, 255, 224, 0.25);
}

.inline-input {
  flex: 1;
  min-width: 140px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.55rem 0.85rem;
  background: rgba(5, 7, 19, 0.92);
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
}

.inline-input:focus {
  outline: none;
  border-color: var(--accent-2);
  box-shadow: 0 0 15px rgba(22, 255, 224, 0.25);
}

.color-control {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  padding: 2px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.55), transparent 55%),
    linear-gradient(135deg, rgba(22, 255, 224, 0.2), rgba(140, 91, 255, 0.3));
  overflow: hidden;
  box-shadow: 0 15px 35px rgba(5, 7, 19, 0.55);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.color-control::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 12px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35), transparent 60%);
  filter: blur(8px);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.color-control:is(:hover, :focus-within) {
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 18px 45px rgba(22, 255, 224, 0.2);
}

.color-control:is(:hover, :focus-within)::after {
  opacity: 0.8;
}

.color-chip {
  position: absolute;
  inset: 2px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.4), transparent 55%),
    var(--chip-color, var(--accent-2));
  box-shadow:
    inset 0 0 20px rgba(0, 0, 0, 0.4),
    0 0 18px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
  text-shadow:
    0 1px 4px rgba(0, 0, 0, 0.65),
    0 0 12px rgba(0, 0, 0, 0.35);
}

.color-chip::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0));
  mix-blend-mode: screen;
  opacity: 0.5;
}

.color-chip::after {
  content: attr(data-hex);
  position: relative;
  z-index: 1;
}

.color-control:focus-within .color-chip {
  border-color: rgba(22, 255, 224, 0.8);
  box-shadow:
    inset 0 0 22px rgba(0, 0, 0, 0.5),
    0 0 25px rgba(22, 255, 224, 0.45);
}

.color-picker {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  appearance: none;
  border: none;
  background: none;
}

.rarity-control {
  position: relative;
}

.rarity-badge {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  padding: 0.25rem 0.9rem;
  background: rgba(5, 7, 19, 0.8);
  color: #f4f4ff;
  font-size: 0.7rem;
  letter-spacing: 0.14rem;
  text-transform: uppercase;
  font-weight: 600;
  box-shadow:
    inset 0 0 18px rgba(255, 255, 255, 0.05),
    0 0 16px var(--rarity-color, transparent);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.rarity-badge:hover,
.rarity-badge:focus-visible {
  border-color: var(--rarity-color, var(--accent-2));
  transform: translateY(-1px);
  outline: none;
}

.rarity-control.is-open .rarity-badge {
  border-color: var(--rarity-color, var(--accent-2));
}

.rarity-menu {
  list-style: none;
  margin: 0;
  padding: 0.35rem;
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  min-width: 180px;
  border-radius: 18px;
  background: rgba(5, 7, 19, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.65);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 6;
}

.rarity-control.is-open .rarity-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.rarity-menu-placeholder {
  display: none;
}

.rarity-menu.is-floating {
  position: fixed;
  opacity: 1;
  transform: none;
  pointer-events: auto;
  z-index: 70;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.65);
}

.rarity-menu li {
  margin: 0;
}

.rarity-menu button {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: #f6f7ff;
  padding: 0.45rem 0.65rem;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.25rem;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.rarity-menu button:last-child {
  margin-bottom: 0;
}

.rarity-menu button::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--rarity-color, var(--accent-2));
  box-shadow: 0 0 10px var(--rarity-color, var(--accent-2));
}

.rarity-menu button[aria-pressed="true"] {
  border-color: var(--rarity-color, var(--accent-2));
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.25);
}

.rarity-menu button:hover {
  border-color: var(--rarity-color, var(--accent-2));
  background: rgba(255, 255, 255, 0.18);
}


.wheel-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.wheel-stage {
  width: 100%;
  display: flex;
  justify-content: center;
  position: relative;
  min-height: var(--stage-size);
}

.case-stage {
  width: 100%;
  display: none;
  justify-content: center;
  align-items: center;
  min-height: var(--stage-size);
}

.slot-stage {
  width: 100%;
  display: none;
  justify-content: center;
  align-items: center;
  min-height: var(--stage-size);
}

body[data-mode="case"] .wheel-stage {
  display: none;
}

body[data-mode="case"] .case-stage {
  display: flex;
}

body[data-mode="slot"] .wheel-stage,
body[data-mode="slot"] .case-stage {
  display: none;
}

body[data-mode="slot"] .slot-stage {
  display: flex;
}

body[data-mode="slot"] .spin-btn {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.wheel-wrap.is-pulsing #wheel {
  animation: wheel-glow 0.65s ease;
}

#wheel {
  width: var(--stage-size);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.3);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.65), inset 0 0 35px rgba(255, 255, 255, 0.05);
  transition: transform 5s cubic-bezier(0.19, 1, 0.22, 1);
}

.indicator {
  position: absolute;
  top: -22px;
  left: 50%;
  width: 0;
  height: 0;
  --indicator-nudge: 0px;
  --indicator-tilt: 0deg;
  transform: translateX(calc(-50% + var(--indicator-nudge, 0px))) rotate(var(--indicator-tilt, 0deg));
  transform-origin: 50% 100%;
  transition: transform 140ms cubic-bezier(0.22, 1, 0.36, 1);
  border-left: 18px solid transparent;
  border-right: 18px solid transparent;
  border-top: 32px solid var(--accent-2);
  filter: drop-shadow(0 0 14px rgba(22, 255, 224, 0.7));
}

.case-window {
  position: relative;
  width: min(720px, 90vw);
  padding: 1.4rem;
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(4, 8, 18, 0.9);
  box-shadow:
    0 25px 80px rgba(0, 0, 0, 0.65),
    inset 0 0 30px rgba(255, 255, 255, 0.04);
  overflow: hidden;
  --case-gap: clamp(0.65rem, 1.8vw, 1rem);
  --case-visible: 5;
  --case-gap-count: calc(var(--case-visible) - 1);
}

.case-window::before,
.case-window::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 18%;
  pointer-events: none;
  z-index: 2;
}

.case-window::before {
  left: 0;
  background: linear-gradient(90deg, rgba(5, 7, 19, 0.95), rgba(5, 7, 19, 0));
}

.case-window::after {
  right: 0;
  background: linear-gradient(270deg, rgba(5, 7, 19, 0.95), rgba(5, 7, 19, 0));
}

.case-track {
  display: flex;
  align-items: center;
  gap: var(--case-gap);
  padding: 0;
  will-change: transform;
}

.case-item {
  flex: 0 0 calc(
    (100% - (var(--case-gap-count) * var(--case-gap))) / var(--case-visible)
  );
  min-width: 0;
  padding: 1.05rem 0.85rem;
  border-radius: 20px;
  text-align: center;
  font-size: clamp(0.8rem, 1.15vw, 1rem);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #ffffff;
  background: linear-gradient(135deg, var(--case-color, var(--accent-2)), rgba(5, 7, 19, 0.85));
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow:
    inset 0 0 18px rgba(255, 255, 255, 0.08),
    0 12px 35px rgba(0, 0, 0, 0.4);
  min-height: 90px;
  display: grid;
  place-items: center;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.35);
}

body[data-rarities="enabled"] .case-item {
  box-shadow:
    inset 0 0 18px rgba(255, 255, 255, 0.08),
    0 12px 35px rgba(0, 0, 0, 0.4),
    0 0 35px var(--rarity-glow, transparent);
  border-color: var(--rarity-color, var(--accent-2));
}

.case-focus {
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 50%;
  width: 4px;
  border-radius: 999px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, rgba(22, 255, 224, 0), rgba(22, 255, 224, 0.9), rgba(22, 255, 224, 0));
  box-shadow: 0 0 20px rgba(22, 255, 224, 0.55);
  pointer-events: none;
  z-index: 3;
}

.slot-machine {
  width: min(860px, 95vw);
  padding: clamp(1.5rem, 4vw, 2.75rem);
  border-radius: 36px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(6, 10, 28, 0.96), rgba(11, 16, 36, 0.88));
  box-shadow:
    0 40px 90px rgba(0, 0, 0, 0.68),
    inset 0 0 50px rgba(255, 255, 255, 0.03);
  display: flex;
  flex-direction: column;
  gap: clamp(0.75rem, 2vw, 1.25rem);
  align-items: stretch;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  backdrop-filter: blur(18px);
}

.slot-machine::before,
.slot-machine::after {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 30px;
  pointer-events: none;
}

.slot-machine::before {
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: radial-gradient(circle at 20% -10%, rgba(255, 255, 255, 0.18), transparent 60%);
  mix-blend-mode: screen;
  opacity: 0.7;
  z-index: 0;
}

.slot-machine::after {
  inset: -35%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(140, 91, 255, 0.16), transparent 55%);
  filter: blur(70px);
  opacity: 0.8;
  z-index: -1;
}

.slot-machine > * {
  position: relative;
  z-index: 1;
}

.slot-display {
  flex: 1 1 460px;
  display: flex;
  align-items: stretch;
  flex-wrap: nowrap;
  gap: clamp(0.6rem, 2vw, 1.4rem);
  padding: clamp(0.9rem, 2vw, 1.4rem);
  border-radius: 30px;
  background:
    radial-gradient(circle at 30% -10%, rgba(255, 255, 255, 0.18), transparent 55%),
    linear-gradient(145deg, rgba(2, 6, 18, 0.95), rgba(6, 10, 24, 0.85));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 0 45px rgba(0, 0, 0, 0.75),
    0 25px 60px rgba(0, 0, 0, 0.5);
  position: relative;
  overflow: hidden;
}

.slot-display::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.08), transparent 60%);
  opacity: 0.5;
  pointer-events: none;
}

.slot-reel {
  --slot-color: var(--accent-2);
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 -30px 40px rgba(0, 0, 0, 0.65),
    0 15px 35px rgba(0, 0, 0, 0.45);
  min-height: clamp(150px, 32vw, 220px);
  position: relative;
  overflow: hidden;
}

.slot-reel::before {
  content: "";
  position: absolute;
  inset: 10%;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 65%);
  opacity: 0.6;
  pointer-events: none;
}

.slot-reel::after {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 20px;
  background: radial-gradient(circle, color-mix(in srgb, var(--slot-color) 65%, transparent) 0%, transparent 70%);
  filter: blur(18px);
  opacity: 0.45;
  pointer-events: none;
}

.slot-reel__window {
  width: 100%;
  height: 100%;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(5, 10, 24, 0.95), rgba(2, 4, 12, 0.8)),
    rgba(5, 10, 24, 0.9);
  border: 2px solid color-mix(in srgb, var(--slot-color) 55%, rgba(255, 255, 255, 0.12));
  padding: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-shadow:
    inset 0 0 25px rgba(0, 0, 0, 0.75),
    inset 0 0 50px rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
}

.slot-reel__label {
  font-size: clamp(0.95rem, 3.4vw, 1.6rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #f7f8ff;
  text-shadow:
    0 0 18px rgba(0, 0, 0, 0.55),
    0 0 8px rgba(22, 255, 224, 0.25);
  word-break: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.slot-reel.is-spinning .slot-reel__label {
  opacity: 0.55;
  filter: blur(1px);
}

.slot-reel.is-match .slot-reel__window {
  box-shadow:
    inset 0 0 25px rgba(0, 0, 0, 0.65),
    0 0 60px color-mix(in srgb, var(--slot-color) 70%, transparent);
  border-color: color-mix(in srgb, var(--slot-color) 80%, rgba(255, 255, 255, 0.24));
}

.slot-hint {
  margin: 0;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: clamp(0.85rem, 2vw, 1.2rem);
}

.slot-lever {
  position: relative;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  color: var(--accent-2);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.45));
  flex: 0 0 auto;
  align-self: center;
  margin-left: clamp(0.5rem, 1vw, 1.2rem);
}

.slot-lever:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.slot-lever__label {
  font-size: 0.85rem;
  transform: translateY(-5px);
}

.slot-lever__stem {
  width: 10px;
  height: clamp(140px, 20vw, 180px);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(130, 148, 168, 0.35));
  box-shadow:
    inset 0 0 18px rgba(0, 0, 0, 0.55),
    0 0 30px rgba(22, 255, 224, 0.35);
  position: relative;
  display: flex;
  justify-content: center;
  padding-bottom: clamp(32px, 4vw, 46px);
  overflow: visible;
}

.slot-lever__stem::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.45), transparent);
  opacity: 0.9;
}

.slot-lever__knob {
  width: clamp(18px, 7vw, 38px);
  height: clamp(18px, 7vw, 38px);
  border-radius: 50%;
  background:
    radial-gradient(circle at 28% 28%, #fff6f0, #ffd0c8 45%, #ff7964 65%, #c7142f 100%),
    radial-gradient(circle at 70% 70%, rgba(255, 255, 255, 0.35), transparent 55%);
  box-shadow:
    inset 0 0 18px rgba(255, 255, 255, 0.35),
    0 15px 30px rgba(0, 0, 0, 0.5),
    0 0 50px rgba(255, 105, 120, 0.55);
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translate(-50%, -154px);
  transition: transform 0.25s ease;
  border: 3px solid rgba(255, 255, 255, 0.4);
}

.slot-lever__knob::after {
  content: "";
  position: absolute;
  width: calc(100% + 36px);
  height: calc(100% + 36px);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 105, 120, 0.35), rgba(255, 105, 120, 0));
  border: 2px solid rgba(255, 180, 190, 0.65);
  box-shadow:
    0 0 25px rgba(255, 105, 120, 0.35),
    inset 0 0 15px rgba(255, 105, 120, 0.25);
  opacity: 0.9;
  pointer-events: none;
}

.slot-lever.is-pulling .slot-lever__knob {
  animation: slotLeverPull 1.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slotLeverPull {
  0% {
    transform: translate(-50%, -152px);
  }
  18% {
    transform: translate(-50%, 28px);
  }
  35% {
    transform: translate(-50%, 32px);
  }
  65% {
    transform: translate(-50%, -44px);
  }
  82% {
    transform: translate(-50%, -114px);
  }
  100% {
    transform: translate(-50%, -152px);
  }
}

@media (max-width: 640px) {
  .slot-display {
    flex-direction: column;
  }

  .slot-lever {
    margin-left: 0;
  }
}

.spin-btn {
  background: linear-gradient(110deg, var(--accent-2), #7ef9ff);
  color: #04161c;
  padding: 1.1rem 2.8rem;
  box-shadow: 0 20px 45px rgba(22, 255, 224, 0.35);
}

.spin-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

.result {
  font-size: 1.1rem;
  color: var(--muted);
  text-align: center;
  min-height: 1.5rem;
}

.result strong {
  color: var(--accent-2);
  font-size: 1.35rem;
}

.result-overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(5, 7, 19, 0.92);
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  z-index: 20;
  --winner-accent: var(--accent-2);
}

.result-overlay.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.result-card {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: clamp(2rem, 6vw, 3.5rem);
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(10, 14, 36, 0.85);
  backdrop-filter: blur(24px);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.65),
    0 0 60px rgba(22, 255, 224, 0.08);
  transform: translateY(20px) scale(0.96);
  opacity: 0;
  transition: transform 0.5s ease, opacity 0.5s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.result-overlay.is-visible .result-card {
  filter: drop-shadow(0 0 35px rgba(0, 0, 0, 0.35))
    drop-shadow(0 0 60px var(--winner-accent, var(--accent-2)));
}

.result-overlay.is-visible .result-card {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.result-label {
  text-transform: uppercase;
  letter-spacing: 0.4rem;
  font-size: 0.85rem;
  color: var(--winner-accent, var(--accent-2));
  margin-bottom: 0.6rem;
}

#overlay-result {
  font-size: clamp(2rem, 7vw, 4rem);
  margin: 0 0 1rem;
  color: var(--winner-accent, var(--accent-2));
}

.result-share {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin: 0.5rem 0 1rem;
}

.share-chip {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 0.8rem 1.2rem;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.share-chip.ghosty {
  background: transparent;
}

.share-chip:hover {
  border-color: var(--winner-accent, var(--accent-2));
  color: var(--winner-accent, var(--accent-2));
}

.confetti-layer {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.confetti-piece {
  position: absolute;
  width: 10px;
  height: 18px;
  border-radius: 4px;
  opacity: 0.9;
  animation: confetti-fall var(--duration, 3.5s) linear infinite;
}


.share-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 30;
}

.share-modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.share-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 7, 19, 0.88);
  backdrop-filter: blur(12px);
}

.share-modal__card {
  position: relative;
  z-index: 1;
  background: rgba(10, 14, 36, 0.92);
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: clamp(1.75rem, 4vw, 2.5rem);
  width: min(520px, calc(100% - 2.4rem));
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.65);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.share-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
  padding: 0;
}

.share-modal__eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.3rem;
  font-size: 0.75rem;
  color: var(--accent-2);
}

#share-modal-title {
  margin: 0;
}

#share-modal-description {
  margin: 0;
  color: var(--muted);
}

.share-modal__url {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

#share-url-input {
  flex: 1;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(5, 7, 19, 0.7);
  color: var(--text);
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
}

#copy-share-url {
  padding: 0.85rem 1.4rem;
  border-radius: 16px;
  background: var(--accent);
  color: white;
  white-space: nowrap;
}

.share-modal__status {
  min-height: 1rem;
  font-size: 0.85rem;
  color: var(--accent-2);
}

.share-modal__actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.6rem;
}

.social-btn {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.social-btn:hover {
  border-color: var(--accent-2);
  color: var(--accent-2);
}

.share-modal__card:focus-within {
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.65), 0 0 0 2px rgba(22, 255, 224, 0.3);
}


@keyframes confetti-fall {
  0% {
    transform: translate3d(var(--x, 0), -10%, 0) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  100% {
    transform: translate3d(var(--x, 0), 110vh, 0) rotate(360deg);
    opacity: 0;
  }
}

@keyframes option-pop {
  0% {
    transform: translateX(-12px) scale(0.96);
    opacity: 0;
  }
  60% {
    transform: translateX(0) scale(1.02);
    opacity: 1;
  }
  100% {
    transform: translateX(0) scale(1);
    opacity: 1;
  }
}

@keyframes wheel-glow {
  0% {
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.65), inset 0 0 35px rgba(255, 255, 255, 0.05);
    filter: drop-shadow(0 0 0 rgba(140, 91, 255, 0));
  }
  50% {
    box-shadow: 0 35px 100px rgba(22, 255, 224, 0.45), inset 0 0 55px rgba(255, 255, 255, 0.2);
    filter: drop-shadow(0 0 28px rgba(22, 255, 224, 0.55));
  }
  100% {
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.65), inset 0 0 35px rgba(255, 255, 255, 0.05);
    filter: drop-shadow(0 0 0 rgba(140, 91, 255, 0));
  }
}

@keyframes rainbow-shift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@media (max-width: 1400px) {
  :root {
    --rail-width: 0px;
  }

  .ad-rail {
    display: none;
    position: static;
  }
}

@media (max-width: 1100px) {
  .page-layout {
    width: min(900px, 100%);
  }

  body {
    padding-left: clamp(1rem, 4vw, 2rem);
    padding-right: clamp(1rem, 4vw, 2rem);
  }
}

@media (max-width: 1280px) {
  .case-window {
    --case-visible: 4;
  }
}

@media (max-width: 960px) {
  .case-window {
    --case-visible: 3;
  }
}

@media (max-width: 640px) {
  body {
    --page-gutter: clamp(0.75rem, 5vw, 1.2rem);
    padding: clamp(0.45rem, 3vh, 0.85rem) var(--page-gutter) clamp(1.4rem, 5vh, 2.1rem);
    padding-left: var(--page-gutter);
    padding-right: var(--page-gutter);
    gap: 1rem;
  }

  .page-layout {
    width: 100%;
  }

  .shell {
    padding: 2rem var(--page-gutter) 2.3rem;
  }

  .panel {
    grid-template-columns: minmax(0, 1fr);
    padding: 1.25rem;
  }

  .seo-highlight {
    margin: 1.5rem 0 2rem;
    padding: 1.25rem;
  }

  .mode-picker {
    width: 100%;
  }

  .case-window {
    --case-visible: 2;
    --case-gap: clamp(0.45rem, 4vw, 0.65rem);
  }
}

@media (max-width: 720px) {
  .panel {
    padding: 1.5rem;
  }

  #wheel {
    width: 80vw;
    height: 80vw;
  }
}


@media (min-width: 520px) {
  .result-share {
    flex-direction: row;
  }
}
