@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');


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


:root {
  --bg: #06080f;
  --surface: rgba(255, 255, 255, .04);
  --surface-hover: rgba(255, 255, 255, .07);
  --glass: rgba(255, 255, 255, .06);
  --glass-border: rgba(255, 255, 255, .1);
  --accent: #7c5cfc;
  --accent-2: #a78bfa;
  --accent-3: #c4b5fd;
  --accent-glow: rgba(124, 92, 252, .3);
  --cyan: #22d3ee;
  --gold: #fbbf24;
  --green: #34d399;
  --green-deep: #059669;
  --text: #f1f5f9;
  --text-secondary: #94a3b8;
  --muted: #64748b;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-pill: 100px;
  --ease: cubic-bezier(.4, 0, .2, 1);
  --duration: .3s;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 60% 50% at 20% 10%, rgba(124, 92, 252, .15) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 80% 80%, rgba(34, 211, 238, .08) 0%, transparent 50%),
    radial-gradient(ellipse 40% 30% at 50% 50%, rgba(251, 191, 36, .05) 0%, transparent 50%);
  animation: bgShift 12s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes bgShift {
  0% {
    opacity: .7;
    filter: hue-rotate(0deg);
  }

  100% {
    opacity: 1;
    filter: hue-rotate(20deg);
  }
}

body::after {
  content: '';
  position: fixed;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 92, 252, .12) 0%, transparent 70%);
  top: -80px;
  right: -80px;
  z-index: 0;
  animation: floatOrb 8s ease-in-out infinite alternate;
  pointer-events: none;
}


.bg-symbols {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.bg-symbol {
  position: absolute;
  user-select: none;
  opacity: .17;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .22));
  transform-origin: center;
  animation: symbolDrift 11s ease-in-out infinite alternate;
}

.sym-cherries { width: 76px; top: 7%; left: 3%; transform: rotate(-10deg); animation-duration: 10s; }
.sym-diamond { width: 82px; top: 10%; right: 6%; transform: rotate(8deg); animation-duration: 12s; }
.sym-seven { width: 66px; top: 58%; left: 5%; transform: rotate(-10deg); animation-duration: 9s; }
.sym-bell { width: 64px; bottom: 18%; left: 8%; transform: rotate(-12deg); animation-duration: 11s; }
.sym-crown { width: 74px; bottom: 8%; right: 18%; transform: rotate(8deg); animation-duration: 13s; }
.sym-grapes { width: 70px; bottom: 12%; left: 24%; transform: rotate(-5deg); animation-duration: 10.5s; }
.sym-slot { width: 98px; bottom: 8%; right: 4%; transform: rotate(8deg); opacity: .14; animation-duration: 14s; }
.sym-strawberry { width: 70px; top: 28%; left: 1.5%; transform: rotate(-8deg); animation-duration: 10.8s; }
.sym-clover { width: 66px; top: 16%; left: 11%; transform: rotate(7deg); opacity: .16; animation-duration: 9.5s; }
.sym-coins { width: 74px; top: 44%; right: 2.5%; transform: rotate(9deg); opacity: .15; animation-duration: 12.5s; }
.sym-horseshoe { width: 68px; bottom: 28%; right: 7%; transform: rotate(-8deg); opacity: .14; animation-duration: 11.4s; }
.sym-dice { width: 62px; bottom: 24%; left: 16%; transform: rotate(10deg); opacity: .15; animation-duration: 9.6s; }
.sym-bar { width: 64px; top: 34%; right: 8%; transform: rotate(-6deg); opacity: .14; animation-duration: 13s; }

@keyframes symbolDrift {
  0% { transform: translate3d(0,0,0) rotate(var(--rot, 0deg)) scale(1); }
  50% { transform: translate3d(6px,-10px,0) rotate(calc(var(--rot, 0deg) + 5deg)) scale(1.04); }
  100% { transform: translate3d(-8px,12px,0) rotate(calc(var(--rot, 0deg) - 6deg)) scale(.98); }
}

@keyframes symbolPulse {
  0%,100% { opacity: .12; }
  50% { opacity: .2; }
}

@keyframes floatOrb {
  0% {
    transform: translate(0, 0) scale(1);
  }

  100% {
    transform: translate(-40px, 60px) scale(1.15);
  }
}


.quiz-wrapper {
  width: 100%;
  max-width: 600px;
  position: relative;
  z-index: 1;
}

.screen {
  display: none;
  animation: screenIn .5s var(--ease) both;
}

.screen.active {
  display: flex;
  flex-direction: column;
  gap: 24px;
}


@keyframes cardDecorFloat {
  0% { transform: translateY(0); }
  100% { transform: translateY(8px); }
}

@keyframes cardDecorFloatB {
  0% { transform: translateX(0); }
  100% { transform: translateX(-6px); }
}

@keyframes screenIn {
  from {
    opacity: 0;
    transform: translateY(24px) scale(.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.screen:not(#screen-intro):not(#screen-result) {
  position: relative;
  overflow: hidden;
  background: var(--glass);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
}

.screen:not(#screen-intro):not(#screen-result)::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .14;
  background-image:
    url('../assets/symbols/diamond.png'),
    url('../assets/symbols/cherries.png'),
    url('../assets/symbols/clover.png'),
    url('../assets/symbols/coins.png');
  background-repeat: no-repeat;
  background-size: 44px, 48px, 42px, 46px;
  background-position: right 18px top 18px, left 14px bottom 24px, left 22px top 18px, right 16px bottom 16px;
  animation: cardDecorFloat 10s ease-in-out infinite alternate;
}

.screen:not(#screen-intro):not(#screen-result)::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .08;
  background-image:
    url('../assets/symbols/seven.png'),
    url('../assets/symbols/bar.png'),
    url('../assets/symbols/grapes.png');
  background-repeat: no-repeat;
  background-size: 52px, 48px, 44px;
  background-position: left -8px center, right -6px 34%, center calc(100% - 18px);
  animation: cardDecorFloatB 12s ease-in-out infinite alternate;
}

.screen:not(#screen-intro):not(#screen-result) > * {
  position: relative;
  z-index: 1;
}


#screen-intro {
  align-items: center;
  text-align: center;
}

.intro-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(124, 92, 252, .12);
  border: 1px solid rgba(124, 92, 252, .3);
  color: var(--accent-2);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 6px 16px;
  border-radius: var(--radius-pill);
}

.intro-title {
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -.02em;
  background: linear-gradient(135deg, #fff 0%, var(--accent-2) 60%, var(--cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  max-width: 520px;
}

.intro-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 460px;
  line-height: 1.7;
}

.bonus-box {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 18px 22px;
  font-size: .95rem;
  color: var(--text-secondary);
  max-width: 480px;
  text-align: left;
}

.bonus-box strong {
  color: var(--text);
}

.bonus-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.progress-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.progress-bar {
  flex: 1;
  height: 5px;
  background: rgba(255, 255, 255, .06);
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent) 0%, var(--cyan) 100%);
  border-radius: var(--radius-pill);
  transition: width .6s var(--ease);
  box-shadow: 0 0 12px rgba(124, 92, 252, .4);
}

.progress-label {
  font-size: .75rem;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
  letter-spacing: .04em;
}

.question-title {
  font-size: clamp(1.05rem, 3.2vw, 1.25rem);
  font-weight: 700;
  line-height: 1.5;
  color: var(--text);
  letter-spacing: -.01em;
}

.insight-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(251, 191, 36, .1);
  border: 1px solid rgba(251, 191, 36, .25);
  color: var(--gold);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  align-self: flex-start;
}

.options {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.option-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, .03);
  border: 1.5px solid rgba(255, 255, 255, .07);
  border-radius: 12px;
  padding: 15px 18px;
  font-size: .95rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition:
    border-color var(--duration) var(--ease),
    background var(--duration) var(--ease),
    transform var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease),
    color var(--duration) var(--ease);
  position: relative;
  overflow: hidden;
  user-select: none;
}

.option-item::before {
  content: attr(data-letter);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .05);
  border: 1.5px solid rgba(255, 255, 255, .1);
  font-size: .78rem;
  font-weight: 700;
  color: var(--muted);
  transition:
    background var(--duration) var(--ease),
    border-color var(--duration) var(--ease),
    color var(--duration) var(--ease),
    transform var(--duration) var(--ease);
}

.option-item:hover {
  border-color: rgba(124, 92, 252, .4);
  background: rgba(124, 92, 252, .06);
  color: var(--text);
  transform: translateX(4px);
}

.option-item:hover::before {
  border-color: rgba(124, 92, 252, .4);
  background: rgba(124, 92, 252, .12);
  color: var(--accent-3);
}

.option-item.selected {
  border-color: var(--accent);
  background: linear-gradient(135deg, rgba(124, 92, 252, .14) 0%, rgba(34, 211, 238, .06) 100%);
  color: var(--text);
  box-shadow:
    0 0 0 1px rgba(124, 92, 252, .25),
    0 8px 32px rgba(124, 92, 252, .15);
}

.option-item.selected::before {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-color: transparent;
  color: #fff;
  transform: scale(1.05);
}

.option-item.selected::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg,
      transparent 40%,
      rgba(255, 255, 255, .06) 45%,
      rgba(255, 255, 255, .06) 55%,
      transparent 60%);
  animation: shimmer 2.5s ease infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

.option-item:active {
  transform: scale(.985);
}

.nav-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 4px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: 12px;
  font-family: inherit;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  padding: 14px 28px;
  letter-spacing: .01em;
  transition:
    transform var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease),
    background var(--duration) var(--ease);
  text-decoration: none;
  white-space: nowrap;
}

.btn:active {
  transform: scale(.97);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #6d28d9 50%, var(--accent-2) 100%);
  background-size: 200% 200%;
  animation: gradientMove 4s ease infinite;
  color: #fff;
  box-shadow: 0 4px 24px var(--accent-glow);
  flex: 1;
}

@keyframes gradientMove {

  0%,
  100% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }
}

.btn-primary:hover {
  box-shadow: 0 8px 36px rgba(124, 92, 252, .45);
  transform: translateY(-2px);
}

.btn-outline {
  background: rgba(255, 255, 255, .04);
  color: var(--text-secondary);
  border: 1.5px solid rgba(255, 255, 255, .1);
  padding: 13px 20px;
  flex-shrink: 0;
}

.btn-outline:hover {
  border-color: rgba(255, 255, 255, .2);
  color: var(--text);
  background: rgba(255, 255, 255, .07);
}

#btn-start {
  width: 100%;
  padding: 18px;
  font-size: 1.1rem;
  border-radius: var(--radius);
  max-width: 360px;
}

#screen-result {
  align-items: center;
  text-align: center;
}

.result-icon {
  font-size: 3.5rem;
  filter: drop-shadow(0 0 20px rgba(52, 211, 153, .5));
  animation: popBounce .6s var(--ease) both;
}

@keyframes popBounce {
  0% {
    transform: scale(0);
    opacity: 0;
  }

  60% {
    transform: scale(1.15);
    opacity: 1;
  }

  100% {
    transform: scale(1);
  }
}

.result-heading {
  font-size: clamp(1.3rem, 4vw, 1.7rem);
  font-weight: 900;
  line-height: 1.3;
  letter-spacing: -.02em;
  background: linear-gradient(135deg, #fff 0%, var(--green) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  max-width: 480px;
}

.result-card {
  background: var(--glass);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
  max-width: 520px;
  width: 100%;
}

.result-verdict {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--green);
  display: flex;
  align-items: center;
  gap: 10px;
}

.result-verdict::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px rgba(52, 211, 153, .6);
  flex-shrink: 0;
}

.result-body {
  color: var(--text-secondary);
  font-size: .95rem;
  line-height: 1.7;
}

.result-body strong {
  color: var(--text);
  font-weight: 600;
}

.result-cta-hint {
  color: var(--muted);
  font-size: .88rem;
  border-top: 1px solid rgba(255, 255, 255, .06);
  padding-top: 16px;
  margin-top: 4px;
}


.result-actions {
  width: 100%;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
}

.result-bonus-note {
  width: 100%;
  text-align: center;
  color: var(--gold);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
  padding: 12px 18px;
  border-radius: var(--radius-pill);
  background: rgba(251, 191, 36, .08);
  border: 1px solid rgba(251, 191, 36, .22);
  box-shadow: 0 8px 28px rgba(251, 191, 36, .08);
}

.btn-install {
  width: 100%;
  max-width: 360px;
  padding: 18px;
  font-size: 1.1rem;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--green) 0%, var(--green-deep) 100%);
  background-size: 200% 200%;
  animation: gradientMove 4s ease infinite;
  box-shadow: 0 4px 28px rgba(52, 211, 153, .35);
  color: #fff;
}

.btn-install:hover {
  box-shadow: 0 8px 40px rgba(52, 211, 153, .5);
  transform: translateY(-2px);
}

.toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: rgba(30, 27, 75, .9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(124, 92, 252, .3);
  color: var(--accent-3);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .88rem;
  font-weight: 600;
  padding: 12px 28px;
  border-radius: var(--radius-pill);
  box-shadow: 0 12px 40px rgba(0, 0, 0, .5);
  pointer-events: none;
  transition: transform .35s var(--ease), opacity .35s;
  opacity: 0;
  z-index: 9999;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  20% {
    transform: translateX(-6px);
  }

  40% {
    transform: translateX(6px);
  }

  60% {
    transform: translateX(-4px);
  }

  80% {
    transform: translateX(4px);
  }
}

.shake {
  animation: shake .45s ease both;
}

@media (max-width: 480px) {
  body {
    padding: 16px 10px;
  }

  .screen:not(#screen-intro):not(#screen-result) {
    padding: 24px 18px;
    border-radius: var(--radius);
  }

  .nav-row {
    flex-direction: column-reverse;
  }

  .btn-outline,
  .btn-primary {
    width: 100%;
  }

  .option-item {
    padding: 13px 14px;
    font-size: .9rem;
  }

  .intro-title {
    font-size: 1.5rem;
  }


  .bg-symbol {
    opacity: .13;
  }

  .sym-cherries { width: 56px; top: 7%; left: 2%; }
  .sym-diamond { width: 60px; top: 11%; right: 3%; }
  .sym-seven { width: 50px; top: 61%; left: 2.5%; }
  .sym-bell { width: 48px; bottom: 18%; left: 3%; }
  .sym-crown { width: 56px; bottom: 7%; right: 12%; }
  .sym-grapes { width: 52px; bottom: 12%; left: 20%; }
  .sym-slot { width: 74px; bottom: 8%; right: 1%; opacity: .11; }
  .sym-strawberry { width: 52px; top: 30%; left: .5%; }
  .sym-clover { width: 50px; top: 15%; left: 9%; }
  .sym-coins { width: 54px; top: 44%; right: .5%; }
  .sym-horseshoe { width: 50px; bottom: 29%; right: 3%; }
  .sym-dice { width: 44px; bottom: 24%; left: 11%; }
  .sym-bar { width: 46px; top: 34%; right: 5%; }

  .screen:not(#screen-intro):not(#screen-result)::before {
    opacity: .18;
    background-size: 32px, 36px, 32px, 34px;
    background-position: right 8px top 10px, left 6px bottom 14px, left 10px top 10px, right 8px bottom 10px;
  }

  .screen:not(#screen-intro):not(#screen-result)::after {
    opacity: .1;
    background-size: 36px, 34px, 32px;
    background-position: left -8px center, right -8px 32%, center calc(100% - 12px);
  }

  .result-bonus-note {
    font-size: .94rem;
    padding: 11px 14px;
  }

}