.lottery-premium { container: lottery / inline-size; }
.lottery-feature { border:1px solid var(--border); border-radius:26px; overflow:hidden; background:var(--card); box-shadow:var(--shadow); margin-bottom:28px; }
.lottery-feature-heading { display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:16px; padding:24px 28px; border-bottom:1px solid var(--border); }
.lottery-feature-heading h2 { margin:8px 0 0; }
.lottery-feature-heading p { margin:0; }
.lottery-eyebrow { color:var(--muted); font-size:10px; font-weight:600; letter-spacing:1.7px; }
.lottery-mode { display:inline-flex; align-items:center; gap:8px; border:1px solid #c7dba75c; background:var(--gold-soft); color:var(--emerald-deep); padding:8px 12px; border-radius:30px; font-size:10px; font-weight:700; letter-spacing:.7px; }
.lottery-mode::before { content:''; width:6px; height:6px; border-radius:50%; background:var(--accent-2); }
.lottery-preview-grid,.lottery-player-grid { display:grid; grid-template-columns:minmax(0,1.25fr) minmax(285px,1fr); }
.lottery-scene { min-width:0; position:relative; isolation:isolate; overflow:hidden; display:flex; flex-direction:column; align-items:center; justify-content:center; padding:24px clamp(12px,3cqi,32px) 28px; background:radial-gradient(ellipse at 60% 62%,#355341 0%,#1c322b 55%,#172a24 100%); color:#edf0d9; }
.lottery-scene::before { content:''; position:absolute; inset:0; z-index:-1; pointer-events:none; background-image:linear-gradient(#d5e6aa07 1px,transparent 1px),linear-gradient(90deg,#d5e6aa07 1px,transparent 1px); background-size:40px 40px; mask-image:radial-gradient(ellipse,black,transparent 75%); }
.lottery-scene-caption { margin:0; font-size:10px; letter-spacing:2px; color:#c0d0b8; text-align:center; }
.lottery-scene-note { margin:0; max-width:40ch; text-align:center; font-size:11px; line-height:1.7; color:#b8c9b9; }
.fortune-wheel { width:100%; max-width:560px; aspect-ratio:600/610; position:relative; margin:4px auto; filter:drop-shadow(0 15px 25px #0003); }
.fortune-svg { display:block; width:100%; height:auto; overflow:visible; }
.fortune-segment>path { stroke:#edf0d94d; stroke-width:1.2; transition:stroke .3s,filter .3s; }
.fortune-segment.inactive { opacity:.36; }
.fortune-segment svg { filter:drop-shadow(0 2px 1px #172a2438); }
.fortune-segment.winning>path { stroke:#f4f7e8; stroke-width:5; filter:drop-shadow(0 0 9px #d5e6aa); }
.fortune-wheel.rare-glow { filter:drop-shadow(0 0 30px #c6db9d88); }
.fortune-sheen { opacity:.85; animation:fortune-shine 7s ease-in-out infinite alternate; }
.no-shine .fortune-sheen { display:none; }
.fortune-pointer { transform-box:view-box; transform-origin:300px 31px; }
.fortune-confetti { position:absolute; inset:0; overflow:hidden; pointer-events:none; }
.fortune-confetti i { position:absolute; left:var(--x); top:6%; width:5px; height:9px; border-radius:2px; background:#d5e6aa; animation:fortune-confetti var(--duration) var(--delay) ease-out both; }
.fortune-confetti i:nth-child(3n) { background:#edf0d9; }.fortune-confetti i:nth-child(3n+1) { background:#83965f; }
.lottery-controls { min-width:0; padding:28px; background:var(--card); }
.lottery-controls h3 { margin:0 0 10px; font-size:18px; }
.lottery-controls label { display:block; font-size:12px; font-weight:600; margin:16px 0 6px; }
.lottery-controls select,.lottery-controls input:not([type=checkbox]) { width:100%; margin:0; }
.lottery-controls .lottery-check { display:flex; gap:10px; align-items:center; font-weight:400; margin:12px 0; }
.lottery-check input { width:16px!important; min-height:16px!important; margin:0; accent-color:var(--emerald); }
.lottery-two-fields { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.lottery-actions { display:flex; flex-wrap:wrap; gap:10px; margin-top:20px; }
body .lottery-controls .lottery-launch { width:100%; min-height:48px; margin-top:20px; background:var(--accent); color:#f4f7e8; border:1px solid var(--accent); border-radius:9px; font-weight:600; }
body .lottery-controls .lottery-launch:hover { background:var(--emerald-soft); }
.lottery-settings { margin-top:24px; border-top:1px solid var(--border); padding-top:20px; }
.lottery-settings summary { cursor:pointer; font-size:12px; font-weight:600; }
.lottery-help { color:var(--muted); font-size:11px; line-height:1.8; margin:12px 0 0; }
.lottery-result { margin-top:24px; padding:20px; border:1px solid var(--border); border-radius:14px; background:var(--bg-soft); }
.lottery-result h3 { margin:6px 0; font-size:19px; overflow-wrap:anywhere; }
.lottery-result p { margin:6px 0; font-size:12px; line-height:1.7; }
.lottery-result.legendary { border-color:#83965f; background:linear-gradient(120deg,#e8efdc,#fbfcf7); box-shadow:0 0 28px #c6db9d3a; }
.lottery-result-icon { display:inline-grid; place-items:center; width:46px; height:46px; float:right; color:var(--accent-2); }
.wheel-reward-icon { width:32px; height:32px; }
.wheel-rewards { list-style:none; padding:0; margin:16px 0 0; }
.wheel-reward-row { display:flex; align-items:center; gap:12px; padding:14px 0; border-bottom:1px solid var(--border-soft); }
.wheel-reward-row:last-child { border:0; }
.wheel-reward-row>span:nth-child(2) { flex:1; min-width:0; overflow-wrap:anywhere; }
.wheel-reward-row strong { display:block; font-size:12px; }.wheel-reward-row small { display:block; color:var(--muted); font-size:11px; margin-top:3px; }
.wheel-reward-symbol { display:grid; place-items:center; flex:0 0 46px; height:46px; border-radius:12px; background:#eef1e7; color:#293e2e; border:1px solid var(--border); }
.wheel-reward-symbol.tone-1 { background:#c7dba7; }.wheel-reward-symbol.tone-2 { background:#83965f;color:#edf0d9; }.wheel-reward-symbol.tone-3 { background:#355341;color:#d5e6aa; }.wheel-reward-symbol.tone-4 { background:#d5e6aa; }.wheel-reward-symbol.tone-5 { background:#526d45;color:#edf0d9; }
.wheel-probability { font-size:11px; font-weight:650; color:var(--accent-2); white-space:nowrap; }
.lottery-simulation-results { margin-bottom:28px; }.lottery-simulation-results header { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:16px; }
.lottery-simulation-results h2 { margin:0; }.lottery-simulation-results table { margin-top:16px; }
.lottery-player-bottom { display:grid; grid-template-columns:1fr 1fr; gap:24px; align-items:start; }
.lottery-player-bottom>.card { min-width:0; }.lottery-history-row { padding:16px 0; border-bottom:1px solid var(--border-soft); }.lottery-history-row strong { display:block; font-size:13px; }.lottery-history-row small { color:var(--muted); font-size:11px; }
.lottery-live-link { display:block; font-size:12px; margin-top:14px; }
@keyframes fortune-shine { from { opacity:.45; } to { opacity:1; } }
@keyframes fortune-confetti { to { transform:translate(var(--drift),450px) rotate(280deg); opacity:0; } }
@container lottery (max-width:780px) { .lottery-preview-grid,.lottery-player-grid { grid-template-columns:minmax(0,1fr); }.lottery-controls { padding:24px; }.lottery-scene { padding:20px; }.fortune-wheel { max-width:460px; } }
@media(max-width:600px) { .lottery-preview-grid,.lottery-player-grid { grid-template-columns:minmax(0,1fr); }.lottery-feature { border-radius:20px; }.lottery-feature-heading { padding:20px; }.lottery-scene { padding:16px 8px 24px; }.lottery-controls { padding:20px; }.lottery-player-bottom { grid-template-columns:1fr; gap:16px; }.lottery-two-fields { gap:10px; }.lottery-actions>button { flex:1 1 140px; } }
@media(prefers-reduced-motion:reduce) { .fortune-wheel *,.lottery-result { animation:none!important; transition:none!important; } }

@media(min-width:901px) { .wheel-player-page .player-sidebar.collapsed .side-top,.wheel-player-page .player-sidebar.collapsed .user { display:none; }.wheel-player-page .player-sidebar.collapsed .player-collapse { font-size:0; min-width:42px; }.wheel-player-page .player-sidebar.collapsed .player-collapse::before { content:"→"; font-size:18px; } }
