:root {
  color-scheme: dark;
  font: 16px/1.45 system-ui, sans-serif;
  --ink: #0e1419;
  --panel: #182229;
  --line: #35444b;
  --muted: #b1c0c9;
  --paper: #f3f7fb;
  --accent: #c7f878;
  --error: #ffbac0;
  background: var(--ink);
  color: var(--paper);
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: radial-gradient(ellipse at 50% 0%, #243630, transparent 28rem); }
.mini-app {
  --ink: #0d2019;
  --panel: #172f27;
  --line: #3f6656;
  --muted: #bed5ca;
  background: radial-gradient(ellipse at 50% 0%, #294a3a, #0e231c 30rem, #0b1c16 75rem);
}
.mini-app.winter {
  --panel: #172f3a;
  --line: #3b5967;
  --muted: #c2d7df;
  background: radial-gradient(ellipse at 15% 0%, #26493d, transparent 29rem),
    radial-gradient(ellipse at 85% 11rem, #233953, transparent 34rem), #0d1c26;
}
button, input, select { font: inherit; color: inherit; }
button, a, select { touch-action: manipulation; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .48; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px;
}
button, select, .secondary { border: 1px solid var(--line); border-radius: .8rem; min-height: 44px; background: var(--panel); }
a { color: var(--accent); text-underline-offset: .22em; }
[hidden] { display: none !important; }
.shell {
  margin: auto; max-width: 46rem; min-height: 100vh;
  padding: max(1rem, env(safe-area-inset-top), var(--tg-content-safe-area-inset-top, 0px))
    max(1rem, env(safe-area-inset-right)) calc(6.2rem + max(env(safe-area-inset-bottom), var(--tg-safe-area-inset-bottom, 0px)))
    max(1rem, env(safe-area-inset-left));
}
header, .intro, .device-row, .wheel-status { display: flex; align-items: center; justify-content: space-between; gap: .7rem; }
header { margin-bottom: 1.6rem; }
.brand { display: flex; align-items: center; gap: .55rem; font-size: 1.32rem; font-weight: 760; letter-spacing: -.04em; }
.brand b { color: var(--accent); }
.mark {
  display: block; width: 46px; height: 46px; flex: 0 0 46px;
  border: 1px solid #52674e; border-radius: .85rem; background: #092414;
}
.holiday-card {
  position: relative;
  display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between;
  gap: .2rem .7rem; padding: .9rem .85rem .7rem; margin: -.6rem 0 1rem;
  border: 1px solid #638a6e; border-radius: .85rem; background: linear-gradient(130deg, #24493c, #233637);
}
.holiday-garland {
  position: absolute; top: -.28rem; inset-inline: 1.2rem;
  display: flex; justify-content: space-between; align-items: start;
  border-top: 1px solid #577461; pointer-events: none;
}
.holiday-garland i {
  color: #fbd482; background: currentColor;
  width: .45rem; height: .56rem; border-radius: 35% 35% 55% 55%;
  box-shadow: 0 0 .48rem currentColor;
}
.holiday-garland i:nth-child(3n + 2) { color: #ff9cae; }
.holiday-garland i:nth-child(3n) { color: #a7eee9; }
.winter-decoration { display: none; }
.winter .winter-decoration { display: inline; }
.section-ornament, .quote-snowflake { margin-inline-start: .42rem; color: #aee9ec; font-size: .72em; }
.winter #quote { border-color: #73917a; }
.holiday-card p { font-size: .76rem; }
#holiday-count { font-weight: 760; font-variant-numeric: tabular-nums; color: #dbf7d7; }
.winter-snow {
  position: fixed; inset: 0; z-index: 1; pointer-events: none; user-select: none;
  overflow: hidden; max-width: 46rem; margin: auto;
}
.winter-snow span {
  position: absolute; top: -1.5rem; color: #e1faf5; opacity: .23; font-size: .82rem;
  animation: snow-fall 22s linear infinite;
}
.winter-snow span:nth-child(1) { left: 5%; animation-delay: -3s; }
.winter-snow span:nth-child(2) { left: 18%; animation-delay: -16s; }
.winter-snow span:nth-child(3) { left: 31%; animation-delay: -7s; font-size: .6rem; }
.winter-snow span:nth-child(4) { left: 44%; animation-delay: -19s; }
.winter-snow span:nth-child(5) { left: 57%; animation-delay: -11s; }
.winter-snow span:nth-child(6) { left: 68%; animation-delay: -2s; font-size: .6rem; }
.winter-snow span:nth-child(7) { left: 82%; animation-delay: -14s; }
.winter-snow span:nth-child(8) { left: 95%; animation-delay: -8s; }
@keyframes snow-fall { to { transform: translate(.8rem, calc(100vh + 3rem)); } }
.languages, .stepper { display: flex; gap: .25rem; align-items: center; }
.languages button, .stepper button { min-width: 44px; }
.languages button { font-size: .78rem; font-weight: 740; }
.languages button[aria-pressed="true"], .tabs [aria-current="page"] { background: #293c32; color: var(--accent); border-color: #57764e; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(1.9rem, 7vw, 2.55rem); line-height: 1.12; letter-spacing: -.045em; margin-bottom: .95rem; }
h2 { font-size: 1.02rem; }
p, label, dt { color: var(--muted); }
label { font-size: .85rem; }
.intro h1 { margin: 0; }
.intro { margin-bottom: 1rem; }
.intro p { margin-top: .35rem; }
select { padding: .35rem .5rem; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.offer {
  --offer-accent: var(--accent);
  padding: .85rem .72rem; min-width: 0; text-align: left;
  display: grid; grid-template-rows: auto auto 1fr; gap: .2rem;
}
.offer[data-days="30"] { --offer-accent: #a5dff2; background: linear-gradient(150deg, #1c3945, #192731 72%); border-color: #547e8e; }
.offer[data-days="90"] { --offer-accent: #b9e88c; background: linear-gradient(150deg, #324d29, #1d3024 72%); border-color: #749a58; }
.offer[data-days="180"] { --offer-accent: #8be1c4; background: linear-gradient(150deg, #23413a, #1b2b2c 72%); border-color: #4e8679; }
.offer[data-days="365"] { --offer-accent: #d1c3fa; background: linear-gradient(150deg, #37314c, #242435 72%); border-color: #766795; }
.offer[aria-pressed="true"] { border-color: var(--offer-accent); box-shadow: inset 0 0 0 1px var(--offer-accent); }
.offer:last-child { grid-column: 1 / -1; }
.offer-starter, .offer-value { grid-template-rows: minmax(2.35rem, auto) auto auto 1fr; gap: .32rem; }
.offer-starter {
  --offer-accent: #f5d78b;
  background: linear-gradient(150deg, #473721, #29241f 71%); border-color: #95794a;
}
.offer-value { background: linear-gradient(150deg, #324d29, #1d3024 72%); border-color: #749a58; }
.offer-badge {
  place-self: start; border-radius: .48rem; padding: .27rem .46rem;
  background: var(--offer-accent); color: #151c13; font-size: .75rem; font-weight: 800; line-height: 1.23;
}
.offer-period { font-size: .92rem; font-weight: 690; }
.offer-price { font-size: clamp(1.3rem, 5vw, 1.8rem); letter-spacing: -.025em; overflow-wrap: anywhere; }
.offer-price { color: var(--offer-accent); }
.offer-saving { color: var(--offer-accent); font-size: .85rem; font-weight: 750; }
.offer-detail { color: var(--muted); font-size: .8rem; }
.offer-cashback { color: #f8db9b; font-size: .85rem; font-weight: 740; }
#plan-comparison-note { margin: .55rem .15rem 0; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: .9rem; padding: .85rem; }
#checkout-discounts { margin-top: .65rem; background: #203c2e; border-color: #5c7f61; }
#checkout-discounts label { color: #e3f6d8; font-weight: 680; }
#checkout-discount { display: block; width: 100%; margin-top: .35rem; }
#quote-breakdown { margin: 0 0 .8rem; }
.device-row { margin-top: .75rem; }
.quote { margin-top: .75rem; border-color: #57764e; background: #1b2c25; }
.quote-total { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: .25rem .75rem; }
.quote-total strong { color: var(--accent); font-size: 1.45rem; }
.quote-warning { color: var(--error); }
#extra-total, #extra-warning { flex-basis: 100%; }
.device-row p, .note { font-size: .84rem; margin-top: .2rem; }
.stepper output { min-width: 2ch; text-align: center; font-weight: 720; }
.primary { width: 100%; border: 1px solid transparent; background: var(--accent); color: #172410; font-weight: 775; margin: .8rem 0 .35rem; }
.secondary { display: inline-flex; align-items: center; padding: .55rem .72rem; text-decoration: none; }
.banner, #feedback, .prize { border: 1px solid #526a58; background: #26372e; border-radius: .8rem; padding: .65rem .75rem; margin: .65rem 0; color: var(--paper); }
#feedback[data-error], #welcome-error, #banner[data-error] { color: var(--error); }
.wheel-hero {
  overflow: hidden; position: relative; margin-bottom: .6rem; display: grid; place-items: center;
  padding: .9rem; border-radius: 1rem; border: 1px solid #425247;
  background: radial-gradient(ellipse at 50% 60%, #384c24 0, #1c2b24 50%, #111f1d 80%);
}
.dial { width: min(100%, 15rem); aspect-ratio: 1; position: relative; margin: .45rem; }
.disc {
  width: 100%; height: 100%; position: relative; border: .4rem solid #a4d86a; border-radius: 50%;
  background: conic-gradient(from -30deg, #254330 60deg, #405a28 60deg 120deg, #225047 120deg 180deg,
    #395d39 180deg 240deg, #254330 240deg 300deg, #405a28 300deg);
  box-shadow: 0 0 0 .28rem #132219, 0 0 0 .36rem #55713b, 0 0 2rem #baf5804b, inset 0 0 1.3rem #101b17bc;
}
.wheel-hub {
  position: absolute; inset: 39%; display: grid; place-items: center; border: 2px solid #c7f878;
  border-radius: 50%; background: #192d24; box-shadow: 0 .25rem 1rem #07100fcc;
}
.wheel-hub img { width: 85%; height: auto; display: block; }
.disc span { position: absolute; font-weight: 790; font-size: .9rem; color: #f2ffe7; transform: translate(-50%, -50%); }
.disc span:nth-child(1) { left: 50%; top: 16%; }
.disc span:nth-child(2) { left: 79%; top: 33%; }
.disc span:nth-child(3) { left: 79%; top: 67%; }
.disc span:nth-child(4) { left: 50%; top: 84%; }
.disc span:nth-child(5) { left: 21%; top: 67%; }
.disc span:nth-child(6) { left: 21%; top: 33%; }
.disc.welcome-layout {
  background: conic-gradient(from -25.714deg, #254330 0% 14.286%, #405a28 14.286% 28.571%,
    #225047 28.571% 42.857%, #395d39 42.857% 57.143%, #254330 57.143% 71.429%,
    #405a28 71.429% 85.714%, #76561c 85.714% 100%);
}
.welcome-layout span:nth-child(2) { left: 77%; top: 29%; }
.welcome-layout span:nth-child(3) { left: 83%; top: 58%; }
.welcome-layout span:nth-child(4) { left: 65%; top: 81%; }
.welcome-layout span:nth-child(5) { left: 35%; top: 81%; }
.welcome-layout span:nth-child(6) { left: 17%; top: 58%; }
.welcome-layout span:nth-child(7) { left: 23%; top: 29%; color: #fff2bd; }
.pointer { width: 1.3rem; height: 1.15rem; background: var(--accent); clip-path: polygon(0 0, 100% 0, 50% 100%); position: absolute; left: 50%; top: -.32rem; transform: translateX(-50%); }
.wheel-hero.busy .pointer { animation: glow .75s alternate infinite; }
@keyframes glow { to { opacity: .55; } }
.wheel-flurries { display: none; }
.winter .wheel-hero {
  padding: 1.35rem .9rem; border-color: #74939e;
  background: radial-gradient(ellipse at 50% 62%, #27494f, #162e46 57%, #102235);
  box-shadow: inset 0 1px #e1faff35, 0 .55rem 1.4rem #040c1580;
}
.winter .dial { width: min(calc(100% - 1.1rem), 17rem); z-index: 1; }
.winter .dial::before {
  content: ""; position: absolute; inset: -.62rem; border-radius: 50%;
  background: repeating-conic-gradient(from 5deg, #ffe8a7 0 3deg, transparent 3deg 15deg,
    #a4e8ff 15deg 18deg, transparent 18deg 30deg);
  -webkit-mask: radial-gradient(transparent 67%, black 68% 70%, transparent 71%);
  mask: radial-gradient(transparent 67%, black 68% 70%, transparent 71%);
  opacity: .9;
}
.winter .wheel-hero.busy .dial::before { animation: wheel-lights 2.8s linear infinite; }
@keyframes wheel-lights { to { transform: rotate(1turn); } }
.winter .disc {
  border-color: #f7d389;
  background: repeating-conic-gradient(from -30deg, #ffe9bd66 0deg .7deg, transparent .7deg 60deg),
    conic-gradient(from -30deg, #a62d44 60deg, #216949 60deg 120deg, #25598e 120deg 180deg,
      #943d67 180deg 240deg, #534292 240deg 300deg, #8b5b23 300deg);
  box-shadow: 0 0 0 .23rem #563b25, 0 0 0 .34rem #e6ae66,
    0 0 1.65rem #ffc87961, inset 0 0 1rem #0b152883;
}
.winter .disc span { color: #fff9ee; text-shadow: 0 1px 3px #111626; font-size: clamp(.78rem, 3.4vw, 1rem); }
.winter .disc.welcome-layout {
  background: repeating-conic-gradient(from -25.714deg, #ffe9bd66 0deg .7deg, transparent .7deg 51.4286deg),
    conic-gradient(from -25.714deg, #a62d44 0% 14.286%, #216949 14.286% 28.571%,
      #25598e 28.571% 42.857%, #943d67 42.857% 57.143%, #534292 57.143% 71.429%,
      #8b5b23 71.429% 85.714%, #1f6070 85.714% 100%);
}
.winter .disc [data-winner] {
  color: #fff4bf; background: #182636; border-radius: 3rem; padding: .15rem .32rem;
  box-shadow: 0 0 0 1px #ffd998, 0 0 .9rem #ffe8a4a6;
}
.winter .wheel-hub { border-color: #ffe3a3; background: #15354b; z-index: 2; }
.winter .pointer { background: linear-gradient(#ffeccc, #f5b84b); height: 1.36rem; z-index: 3; }
.winter .wheel-flurries { display: block; position: absolute; inset: 0; color: #d8f8ff; pointer-events: none; }
.wheel-flurries span { position: absolute; top: var(--y); left: var(--x); font-size: 1rem; opacity: .55; }
.wheel-flurries span:nth-child(1) { --x: 5%; --y: 17%; }
.wheel-flurries span:nth-child(2) { --x: 87%; --y: 13%; color: #ffd795; }
.wheel-flurries span:nth-child(3) { --x: 92%; --y: 46%; }
.wheel-flurries span:nth-child(4) { --x: 8%; --y: 79%; color: #ffd795; }
.wheel-flurries span:nth-child(5) { --x: 88%; --y: 82%; }
.wheel-flurries span:nth-child(6) { --x: 12%; --y: 51%; color: #ffd795; }
.winter .wheel-hero.busy .wheel-flurries span { animation: wheel-flurry 2s ease-in-out infinite alternate; }
.winter .wheel-hero.busy .wheel-flurries span:nth-child(even) { animation-delay: -.9s; }
@keyframes wheel-flurry { to { transform: translate(.3rem, 1.25rem) rotate(55deg); opacity: 1; } }
.winter .wheel-hero.has-result { border-color: #f2c77e; }
.winter #spin { color: #322414; background: linear-gradient(135deg, #ffe7a9, #f2c471); }
.winter #reward-dialog { border-color: #dfbc77; background: linear-gradient(150deg, #253b51, #1c2939); }
@media (max-height: 720px) {
  .winter .wheel-hero { padding-block: .85rem; }
  .winter .dial { width: min(calc(100% - 1.1rem), 14.5rem); }
}
.wheel-status { padding: .5rem .1rem; align-items: flex-start; }
.wheel-status p { font-size: .8rem; margin-top: .15rem; }
.wheel-feed { margin-top: .65rem; }
.wheel-feed-items { list-style: none; margin: .4rem 0 0; padding: 0; max-height: 16rem; overflow-y: auto; }
.wheel-feed-items li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .12rem .65rem; padding: .55rem 0; }
.wheel-feed-items li + li { border-top: 1px solid var(--line); }
.wheel-feed-player { font-weight: 720; }
.wheel-feed-items strong { color: var(--accent); font-size: .86rem; text-align: right; max-width: 12rem; }
.wheel-feed-items time { color: var(--muted); font-size: .73rem; grid-column: 1 / -1; }
.bonus { text-align: right; }
.prize { background: #283a2a; color: var(--accent); font-weight: 750; }
.prizes, .promo { margin-top: .65rem; }
.prizes summary, .promo summary { cursor: pointer; }
#vault-panel { border-color: #9b8252; background: linear-gradient(145deg, #39442c, #29382b); }
#vault-panel summary { color: #ffe0a3; font-weight: 740; }
#vault-panel .secondary { color: #fff0ca; background: #4a4b31; border-color: #8f794e; }
.promo .promo-label { flex-basis: 100%; }
.promo input {
  flex: 1 1 10rem; min-width: 0; min-height: 44px; padding: .55rem .65rem;
  border: 1px solid var(--line); border-radius: .65rem; background: var(--ink);
}
.promo button { flex: 0 0 auto; }
#promo-result { margin-top: .6rem; }
#promo-result[data-error] { color: var(--error); }
.prizes p { margin-top: .5rem; }
.prizes ul { display: grid; grid-template-columns: 1fr 1fr; gap: .2rem .7rem; padding-left: 1.1rem; margin-bottom: .5rem; }
.prizes .reward-list { grid-template-columns: minmax(0, 1fr); padding-left: 0; }
dl { display: grid; grid-template-columns: 1fr auto; gap: .35rem .55rem; margin: .55rem 0; }
dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.profile { margin-bottom: .7rem; }
.profile p { margin: .3rem 0; }
.profile-subscription { border-color: #4c6950; background: #1b332b; }
.profile-subscription h2 { margin: 0; }
.profile-details summary { cursor: pointer; color: var(--paper); font-weight: 650; }
.profile-details[open] summary { margin-bottom: .6rem; }
.profile-footer { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1.2rem; }
.profile-footer a { padding: .55rem 0; text-decoration: none; }
.inline, .links { display: flex; align-items: center; flex-wrap: wrap; gap: .55rem; margin-top: .65rem; }
.inline label { flex: 1 0 45%; }
.inline button { margin-left: auto; }
.links a { min-height: 44px; display: inline-flex; align-items: center; }
#order-line { overflow-wrap: anywhere; }
.tabs {
  position: fixed; z-index: 2; inset: auto max(1rem, env(safe-area-inset-right)) max(.65rem, env(safe-area-inset-bottom), var(--tg-safe-area-inset-bottom, 0px)) max(1rem, env(safe-area-inset-left));
  max-width: 44rem; margin: auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .25rem;
  padding: .3rem; border: 1px solid var(--line); border-radius: 1rem; background: #172128;
}
.tabs button { background: transparent; border-color: transparent; font-size: .8rem; display: grid; place-items: center; padding: .2rem; }
.mini-app .tabs { background: #172e26; }
.tabs button span:first-child { font-size: 1.12rem; line-height: 1; }
@media (max-width: 360px) { .tabs button { font-size: .72rem; } }
dialog { background: var(--panel); color: var(--paper); width: min(23rem, calc(100% - 2rem)); border: 1px solid var(--line); border-radius: 1rem; padding: 1rem; }
dialog::backdrop { background: #080d11d9; }
.language-choices { display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; margin-top: .65rem; }
.reward-list { list-style: none; margin: .65rem 0 .2rem; padding: 0; }
.reward-list li { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .5rem; padding: .55rem 0; }
.reward-list li + li { border-top: 1px solid var(--line); }
.reward-actions { justify-content: space-between; }
.reward-actions .primary { flex-basis: 100%; }
#reward-dialog-detail { color: var(--paper); margin-top: .7rem; }
#reward-error, #promo-error { color: var(--error); }
.promo-form { display: grid; gap: .55rem; margin-top: .65rem; }
.promo-form input { border: 1px solid var(--line); border-radius: .65rem; padding: .65rem; min-width: 0; background: #13201f; }
.promo-form .secondary { justify-content: center; }
.referral-balance { padding: .65rem; background: #254936; border-radius: .7rem; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; }
  .winter-snow { display: none; }
}
