/* ============================================================
   Tema "new" — moderne layout med topbar. Alt er afgrænset af
   html[data-ui="new"], så "classic" (styles.css) er uændret.
   Farver: rolig, lys flade til læsning; indigo til handlinger;
   guld KUN til mønter/belønning; pink til spil-credits; grøn for
   rigtigt og en blød koral for fejl (ikke skarp rød).
   ============================================================ */

/* ---------- gælder begge temaer ---------- */
.topbar{display:none;}
.settings-theme{margin-top:22px; padding-top:18px; border-top:1px solid rgba(0,0,0,.08);}
.settings-label{font-weight:700; margin:0 0 8px;}
.theme-opts{display:grid; grid-template-columns:1fr 1fr; gap:10px;}
.theme-opt{display:flex; flex-direction:column; gap:6px; padding:10px; border-radius:14px; border:2px solid #dcdfe8; cursor:pointer; background:#fff; position:relative;}
.theme-opt input{position:absolute; opacity:0; pointer-events:none;}
.theme-opt:has(input:checked){border-color:#4F46E5; box-shadow:0 0 0 3px rgba(79,70,229,.18);}
.theme-opt:has(input:focus-visible){outline:3px solid #4F46E5; outline-offset:2px;}
.theme-opt b{display:block; font-size:.95rem;} .theme-opt small{display:block; font-size:.75rem; opacity:.7; line-height:1.3;}
.theme-sw{height:34px; border-radius:8px; display:block;}
.theme-opt-new .theme-sw{background:linear-gradient(90deg, #4F46E5 0 40%, #F5F6FC 40% 70%, #FCD34D 70% 85%, #EC4899 85%);}
.theme-opt-classic .theme-sw{background:linear-gradient(90deg, #1478A0 0 40%, #FBF6EA 40% 70%, #FF8A3D 70% 85%, #3FA06B 85%);}
.settings-field.is-off{opacity:.45;}

/* ---------- farver og typografi ---------- */
html[data-ui="new"]{
  --ink:#1E1B4B; --ink-2:#55527A; --line:#E4E5F1; --surface:#FFFFFF; --bg:#F5F6FC;
  --primary:#4F46E5; --primary-dark:#3730A3; --primary-soft:#EEF0FF; --primary-ring:rgba(79,70,229,.22);
  --teal:#0D9488; --teal-soft:#E6F7F5; --gold:#F59E0B; --gold-soft:#FFF7DB; --pink:#EC4899; --pink-soft:#FDECF5;
  --accent-primary:#4F46E5; --accent-primary-dark:#2E2A85;
  --accent-secondary:#14B8A6; --accent-secondary-dark:#0F766E;
  --bg-warm:#F2F3FF; --bg-warm-dark:#DCDDFB;
  --text-dark:#1E1B4B;
  --accent-cta:#4F46E5; --accent-cta-dark:#3730A3;
  --accent-pink:#EC4899; --accent-highlight:#FCD34D;
  --bg-base:#F5F6FC; --state-ok:#16A34A; --state-error:#E5534B;
  --radius:22px; --radius-sm:14px;
  --shadow:0 1px 2px rgba(30,27,75,.06), 0 10px 30px rgba(30,27,75,.09);
  --shadow-sm:0 1px 2px rgba(30,27,75,.06), 0 4px 14px rgba(30,27,75,.07);
  --focus:3px solid #4F46E5;
  --tb-h:68px;
}
html[data-ui="new"] body{
  font-family:'Nunito', system-ui, sans-serif; font-weight:500; color:var(--ink);
  background:
    radial-gradient(1100px 520px at 105% -10%, rgba(124,108,255,.13), transparent 60%),
    radial-gradient(800px 480px at -10% 110%, rgba(20,184,166,.10), transparent 60%),
    var(--bg);
  background-attachment:fixed;
}
html[data-ui="new"] h1, html[data-ui="new"] h2, html[data-ui="new"] h3, html[data-ui="new"] .kicker, html[data-ui="new"] .brandtitel{font-family:'Fredoka', 'Nunito', sans-serif; font-weight:600; letter-spacing:-.01em;}
html[data-ui="new"] button{font-family:'Nunito', system-ui, sans-serif; font-weight:800;}
html[data-ui="new"] h1{color:var(--ink); font-size:2.4rem;}
html[data-ui="new"] h2.topic-title{color:var(--ink);}

/* ---------- layout: topbar + sidebar ---------- */
html[data-ui="new"] .app-shell{display:grid; grid-template-columns:272px minmax(0, 1fr); grid-template-rows:auto 1fr; min-height:100vh;}
html[data-ui="new"] .topbar{
  grid-column:1 / -1; position:sticky; top:0; z-index:60; height:var(--tb-h);
  display:flex; align-items:center; gap:14px; padding:0 18px;
  background:rgba(255,255,255,.82); -webkit-backdrop-filter:saturate(1.6) blur(14px); backdrop-filter:saturate(1.6) blur(14px);
  border-bottom:1px solid var(--line);
}
html[data-ui="new"] .tb-brand{display:flex; align-items:center; gap:10px; min-width:0; flex:1 1 auto;}
html[data-ui="new"] .tb-logo svg{width:36px; height:36px; display:block; filter:drop-shadow(0 4px 8px rgba(79,70,229,.35));}
html[data-ui="new"] .tb-title{display:flex; flex-direction:column; line-height:1.1; min-width:0;}
html[data-ui="new"] .tb-title b{font-family:'Fredoka', sans-serif; font-weight:600; font-size:1.12rem; color:var(--ink);}
html[data-ui="new"] .tb-title small{font-size:.8rem; color:var(--ink-2); font-weight:700; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:34ch;}
html[data-ui="new"] .tb-wallet{display:flex; gap:8px; flex-shrink:0;}
html[data-ui="new"] .tb-chip{
  display:inline-flex; align-items:center; gap:6px; height:42px; padding:0 14px 0 6px; border-radius:999px;
  border:1.5px solid transparent; font-variant-numeric:tabular-nums; position:relative; transition:transform .15s ease, box-shadow .2s ease;
}
html[data-ui="new"] .tb-chip-ico svg{width:30px; height:30px; display:block;}
html[data-ui="new"] .tb-num{font-size:1.15rem; font-weight:900; min-width:1.4ch; text-align:left;}
html[data-ui="new"] .tb-lbl{font-size:.78rem; font-weight:800; opacity:.75;}
html[data-ui="new"] .tb-coins{background:var(--gold-soft); color:#7A4A00; border-color:#FBE3A0;}
html[data-ui="new"] .tb-credits{background:var(--pink-soft); color:#9D1C5E; border-color:#F9CDE3;}
html[data-ui="new"] .tb-credits:not(.has){filter:saturate(.35); opacity:.8;}
html[data-ui="new"] .tb-chip:hover{transform:translateY(-1px); box-shadow:var(--shadow-sm);}
html[data-ui="new"] .tb-bump{animation:tbBump .32s cubic-bezier(.3,1.8,.5,1);}
@keyframes tbBump{40%{transform:scale(1.16);} 100%{transform:scale(1);}}
html[data-ui="new"] .tb-coins.tb-glow{box-shadow:0 0 0 4px rgba(252,211,77,.55), 0 0 28px rgba(245,158,11,.55);}
html[data-ui="new"] .tb-credits.tb-glow{box-shadow:0 0 0 4px rgba(249,168,212,.6), 0 0 28px rgba(236,72,153,.5);}
html[data-ui="new"] .tb-nav{display:flex; gap:6px; flex-shrink:0;}
html[data-ui="new"] .tb-btn{
  display:inline-flex; align-items:center; gap:8px; height:42px; padding:0 14px; border-radius:12px;
  background:transparent; color:var(--ink); font-size:.92rem; transition:background .15s ease, color .15s ease;
}
html[data-ui="new"] .tb-btn svg{width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; flex-shrink:0;}
html[data-ui="new"] .tb-btn:hover{background:var(--primary-soft); color:var(--primary);}
html[data-ui="new"] .tb-arcade{background:linear-gradient(135deg, #6D5BFF, #4F46E5); color:#fff; box-shadow:0 4px 14px rgba(79,70,229,.35);}
html[data-ui="new"] .tb-arcade:hover{background:linear-gradient(135deg, #7C6CFF, #4338CA); color:#fff;}
html[data-ui="new"] .tb-ghost{color:var(--ink-2);}
html[data-ui="new"] .tb-btn:focus-visible, html[data-ui="new"] .tb-chip:focus-visible{outline:3px solid var(--primary); outline-offset:2px; border-radius:12px;}

/* sidebar: din rejse */
html[data-ui="new"] .rail{
  width:auto; position:sticky; top:var(--tb-h); height:calc(100vh - var(--tb-h)); padding:22px 14px;
  background:rgba(255,255,255,.7); color:var(--ink); box-shadow:none; border-right:1px solid var(--line);
}
html[data-ui="new"] .rail h2{color:var(--ink-2); opacity:1; font-family:'Nunito', sans-serif; font-weight:900; font-size:.75rem; letter-spacing:.12em;}
html[data-ui="new"] .rail-list::before{left:27px; background:linear-gradient(180deg, var(--line), var(--line)); width:2px;}
html[data-ui="new"] .rail-item{color:var(--ink); opacity:1; font-weight:700; border-radius:14px; border:1.5px solid transparent; padding:9px 10px;}
html[data-ui="new"] .rail-item .badge{background:#fff; border:2px solid var(--line); color:var(--ink-2); width:34px; height:34px;}
html[data-ui="new"] .rail-item:not(.locked):hover{background:var(--primary-soft); transform:none;}
html[data-ui="new"] .rail-item.current{background:var(--primary-soft); border-color:#C9CCFF; transform:none; color:var(--primary-dark);}
html[data-ui="new"] .rail-item.current .badge{background:var(--primary); border-color:var(--primary); color:#fff; box-shadow:0 0 0 4px var(--primary-ring);}
html[data-ui="new"] .rail-item.done .badge{background:var(--teal); border-color:var(--teal); color:#fff;}
html[data-ui="new"] .rail-item.locked{opacity:.45;}
html[data-ui="new"] .rail-switch{display:none;}

/* ---------- indhold ---------- */
html[data-ui="new"] .section{padding:40px 28px 96px;}
html[data-ui="new"] .kicker{background:var(--primary-soft); color:var(--primary); border:none; box-shadow:none; font-family:'Nunito', sans-serif; font-weight:800; font-size:.82rem; letter-spacing:.04em; text-transform:uppercase;}
html[data-ui="new"] .topic-emoji{background:linear-gradient(135deg, #EEF0FF, #E6F7F5); border:none; box-shadow:inset 0 0 0 2px #fff, 0 6px 16px rgba(79,70,229,.15); border-radius:18px;}
html[data-ui="new"] .speak-btn{background:var(--surface); color:var(--primary); box-shadow:inset 0 0 0 2px #D9DBFB; font-weight:800;}
html[data-ui="new"] .speak-btn:hover{background:var(--primary-soft);}
html[data-ui="new"] .speak-btn[aria-pressed="true"]{background:var(--primary); color:#fff; box-shadow:none;}
html[data-ui="new"] .speak-btn.speak-mini, html[data-ui="new"] .seq-item .speak-btn.speak-mini{background:var(--primary-soft); color:var(--primary); box-shadow:none;}
html[data-ui="new"] .card{border:1px solid var(--line); border-radius:var(--radius); box-shadow:var(--shadow-sm);}
html[data-ui="new"] .kortfortalt{background:linear-gradient(180deg, #FFFDF5, #fff); border:1px solid #F6E3B0; box-shadow:var(--shadow-sm);}
html[data-ui="new"] .kortfortalt::before{background:#FFFDF5;}
html[data-ui="new"] .kortfortalt h3{color:#8A5A00;}
html[data-ui="new"] .foto-kort{outline:none; border:6px solid #fff; box-shadow:var(--shadow);}
html[data-ui="new"] .minigame{border:1px solid var(--line); background:var(--surface); box-shadow:var(--shadow-sm);}
html[data-ui="new"] .minigame::before{background:linear-gradient(135deg, #14B8A6, #0D9488); box-shadow:0 4px 12px rgba(13,148,136,.3);}
html[data-ui="new"] .control-questions{border:1px solid var(--line); box-shadow:var(--shadow); position:relative; overflow:hidden;}
html[data-ui="new"] .control-questions::before{content:""; position:absolute; inset:0 0 auto 0; height:5px; background:linear-gradient(90deg, #6D5BFF, #14B8A6);}
html[data-ui="new"] .control-questions h3{color:var(--ink);}
html[data-ui="new"] .cq-options li label{background:var(--surface); border:2px solid var(--line); transition:border-color .12s ease, background .12s ease, transform .12s ease;}
html[data-ui="new"] .cq-options li label:hover{border-color:#B9BCF7; background:#FAFAFF;}
html[data-ui="new"] .cq-options li label:has(input:checked){border-color:var(--primary); background:var(--primary-soft);}
html[data-ui="new"] .cq-options input{accent-color:var(--primary);}
html[data-ui="new"] .chip, html[data-ui="new"] .seq-item{background:var(--surface); border:2px solid var(--line);}
html[data-ui="new"] .chip.selected{border-color:var(--primary); background:var(--primary-soft);}
html[data-ui="new"] .bin{background:#FAFAFF; border:2px dashed #CFD1F5;}
html[data-ui="new"] .bin.bin-hover{background:var(--primary-soft); border-color:var(--primary);}
html[data-ui="new"] .locked-msg{background:#FFF6E8; border:1px solid #F8D9A8;}
html[data-ui="new"] .quiz-explain{background:var(--teal-soft); border:1px solid #BDEBE4;}

/* knapper */
html[data-ui="new"] .btn{border-radius:14px; padding:13px 24px; box-shadow:none; font-weight:800; letter-spacing:.01em;}
html[data-ui="new"] .btn-primary{background:linear-gradient(135deg, #6D5BFF, #4F46E5); color:#fff; box-shadow:0 6px 18px rgba(79,70,229,.32), inset 0 -2px 0 rgba(0,0,0,.12);}
html[data-ui="new"] .btn-primary:hover:not(:disabled){box-shadow:0 10px 24px rgba(79,70,229,.4), inset 0 -2px 0 rgba(0,0,0,.12);}
html[data-ui="new"] .btn-primary:disabled{background:#E7E8F3; color:#9A9BB5; box-shadow:none;}
html[data-ui="new"] .btn-secondary{background:var(--surface); color:var(--primary); border:2px solid #D9DBFB;}
html[data-ui="new"] .btn-secondary:hover:not(:disabled){border-color:var(--primary);}
html[data-ui="new"] .intro-name input{border:2px solid #D9DBFB; border-radius:14px; font-family:'Nunito', sans-serif; font-weight:700;}
html[data-ui="new"] .intro-name input:focus{border-color:var(--primary); outline:none; box-shadow:0 0 0 4px var(--primary-ring);}

/* diplom */
html[data-ui="new"] .diploma-card{border:none; box-shadow:0 0 0 3px #fff, 0 0 0 6px #FCD34D, var(--shadow); background:linear-gradient(180deg, #FFFDF4, #fff);}
html[data-ui="new"] table.oversigt th{background:var(--primary-soft);}
html[data-ui="new"] table.oversigt td{border-bottom:1px solid var(--line);}
html[data-ui="new"] .arkanoid-diploma-teaser.credit-teaser{background:linear-gradient(135deg, #2E1065, #4C1D95 60%, #831843); border:none; box-shadow:0 14px 40px rgba(76,29,149,.35);}

/* paneler (Mit arkade, Mine opgaver, Kontrolpanel) */
html[data-ui="new"] .settings-panel{background:rgba(17,16,48,.5); -webkit-backdrop-filter:blur(6px); backdrop-filter:blur(6px);}
html[data-ui="new"] .settings-inner{border:none; border-radius:26px; box-shadow:0 30px 80px rgba(17,16,48,.35); animation:uiPop .28s cubic-bezier(.2,1.2,.4,1);}
@keyframes uiPop{from{transform:translateY(14px) scale(.97); opacity:0;}}
html[data-ui="new"] .settings-inner h2{color:var(--ink);}
html[data-ui="new"] .settings-close{top:14px; right:14px; background:var(--bg); color:var(--ink); box-shadow:none; width:38px; height:38px;}
html[data-ui="new"] .settings-close:hover{background:var(--primary-soft); color:var(--primary);}
html[data-ui="new"] .settings-field label{color:var(--ink);}
html[data-ui="new"] .settings-field select{border:2px solid var(--line); font-family:'Nunito', sans-serif; font-weight:700;}
html[data-ui="new"] .arcade-rank-card{background:linear-gradient(135deg, #EEF0FF, #F5F0FF); border:1px solid #DCDDFB;}
html[data-ui="new"] .arcade-coin-card{background:var(--gold-soft); border:1px solid #FBE3A0;}
html[data-ui="new"] .arcade-score-row{border:1px solid var(--line); border-radius:14px;}
html[data-ui="new"] .arcade-credit-card{background:linear-gradient(135deg, #FDECF5, #F3EEFF); border:1px solid #F5C6DF; box-shadow:var(--shadow-sm);}
html[data-ui="new"] .arcade-credit-game{border:1.5px solid #F5C6DF; border-radius:14px;}
html[data-ui="new"] .arcade-credit-game:hover{border-color:var(--pink); box-shadow:0 6px 16px rgba(236,72,153,.2);}
html[data-ui="new"] .variant-choice-btn{border:2px solid var(--line); box-shadow:var(--shadow-sm);}
html[data-ui="new"] .variant-choice-btn:hover{border-color:var(--primary); background:var(--primary-soft);}
html[data-ui="new"] .arcade-modal-inner{border-radius:24px;}

/* gamle beskeder skjules (det nye tema viser flyvende mønter i stedet) */
html[data-ui="new"] .coin-toast{display:none;}
html[data-ui="new"] .hover-pill{top:calc(var(--tb-h) + 12px); background:rgba(30,27,75,.92);}

/* forside */
html[data-ui="new"] .landing-card{background:rgba(255,255,255,.9); border:none; border-radius:28px; box-shadow:0 30px 70px rgba(30,27,75,.3);}
html[data-ui="new"] .landing-card h1{font-family:'Fredoka', sans-serif;}
html[data-ui="new"] .code-ticket{border:2px dashed #C9CCFF;}
html[data-ui="new"] .code-ticket::before, html[data-ui="new"] .code-ticket::after{border:2px dashed #C9CCFF; background:#fff;}
html[data-ui="new"] .landing-card input{font-family:'Fredoka', sans-serif; background:#F5F6FC; color:var(--ink);}
html[data-ui="new"] .landing-card input:focus{outline:3px solid var(--primary);}
html[data-ui="new"] .landing-go{box-shadow:0 8px 20px rgba(79,70,229,.35);}
html[data-ui="new"] .landing-go:hover{box-shadow:0 12px 26px rgba(79,70,229,.45);}
html[data-ui="new"] .landing-go:active{box-shadow:0 4px 10px rgba(79,70,229,.35);}
html[data-ui="new"] .landing-steps li{background:var(--primary-soft); color:var(--primary-dark);}

/* ---------- store belønninger ---------- */
.ue-burst{position:fixed; z-index:9800; transform:translate(-50%,-50%); pointer-events:none; animation:ueIn .5s cubic-bezier(.2,1.6,.4,1) both;}
.ue-burst.ue-out{animation:ueOut .4s ease-in forwards;}
@keyframes ueIn{from{transform:translate(-50%,-50%) scale(.2); opacity:0;}}
@keyframes ueOut{to{transform:translate(-50%,-80%) scale(.9); opacity:0;}}
.ue-rays{position:absolute; left:50%; top:50%; width:420px; height:420px; margin:-210px 0 0 -210px; border-radius:50%;
  background:repeating-conic-gradient(rgba(252,211,77,.55) 0 9deg, transparent 9deg 24deg);
  -webkit-mask:radial-gradient(circle, #000 20%, transparent 68%); mask:radial-gradient(circle, #000 20%, transparent 68%);
  animation:ueSpin 6s linear infinite;}
.ue-credit .ue-rays{background:repeating-conic-gradient(rgba(249,168,212,.6) 0 9deg, transparent 9deg 24deg);}
.ue-burst:not(.ue-big) .ue-rays{width:260px; height:260px; margin:-130px 0 0 -130px;}
@keyframes ueSpin{to{transform:rotate(360deg);}}
.ue-pill{position:relative; display:flex; align-items:center; gap:10px; padding:10px 24px 10px 12px; border-radius:999px; white-space:nowrap;
  font-family:'Fredoka', 'Nunito', sans-serif; color:#5A3600; background:linear-gradient(180deg, #FFF6CC, #FCD34D); box-shadow:0 6px 0 #D08A06, 0 18px 40px rgba(245,158,11,.5);}
.ue-credit .ue-pill{color:#fff; background:linear-gradient(180deg, #F472B6, #DB2777); box-shadow:0 6px 0 #9D174D, 0 18px 40px rgba(236,72,153,.5);}
.ue-ico svg{width:46px; height:46px; display:block; animation:ueSpinY 1s linear infinite;}
@keyframes ueSpinY{50%{transform:scaleX(.2);}}
.ue-n{font-size:2.6rem; font-weight:700; line-height:1;}
.ue-w{font-size:1.1rem; font-weight:600; opacity:.9;}
.ue-big .ue-n{font-size:3.4rem;}
.ue-big .ue-ico svg{width:58px; height:58px;}
.ue-fly{position:fixed; left:0; top:0; z-index:9900; width:32px; height:32px; pointer-events:none; will-change:transform;}
.ue-fly svg{width:100%; height:100%; display:block; filter:drop-shadow(0 3px 4px rgba(0,0,0,.25));}
.ue-fly-credit{width:36px; height:36px;}
.ue-spark{position:fixed; z-index:9850; border-radius:50%; pointer-events:none;}
.ue-spend{position:fixed; z-index:9850; transform:translateX(-50%); font:900 1.1rem 'Nunito', sans-serif; color:#B45309; background:#FFF7DB; padding:2px 10px; border-radius:999px; box-shadow:var(--shadow-sm); pointer-events:none; animation:ueSpend 1.3s ease-out forwards;}
@keyframes ueSpend{to{transform:translate(-50%, 26px); opacity:0;}}

/* ---------- skærmstørrelser ---------- */
@media (max-width:960px){
  html[data-ui="new"] .tb-btn:not(.tb-arcade) .tb-txt{position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap;}
  html[data-ui="new"] .tb-btn:not(.tb-arcade){padding:0 10px;}
  html[data-ui="new"] .tb-title small{max-width:22ch;}
}
@media (max-width:820px){
  html[data-ui="new"]{--tb-h:60px;}
  html[data-ui="new"] .app-shell{grid-template-columns:minmax(0, 1fr); grid-template-rows:auto auto 1fr;}
  html[data-ui="new"] .rail{position:relative; top:0; height:auto; border-right:none; border-bottom:1px solid var(--line); padding:10px 12px;}
  html[data-ui="new"] .tb-arcade .tb-txt{position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap;}
  html[data-ui="new"] .tb-arcade{padding:0 10px;}
  html[data-ui="new"] .tb-title small{display:none;}
  html[data-ui="new"] .section{padding:28px 18px 80px;}
}
@media (max-width:600px){
  html[data-ui="new"] .topbar{gap:8px; padding:0 10px;}
  html[data-ui="new"] .tb-title{display:none;}
  html[data-ui="new"] .tb-lbl{display:none;}
  html[data-ui="new"] .tb-chip{height:38px; padding:0 10px 0 4px; gap:4px;}
  html[data-ui="new"] .tb-chip-ico svg{width:26px; height:26px;}
  html[data-ui="new"] .tb-num{font-size:1rem;}
  html[data-ui="new"] .tb-btn{height:38px; padding:0 8px !important;}
  html[data-ui="new"] .tb-nav{gap:2px;}
  html[data-ui="new"] .tb-wallet{gap:6px;}
  html[data-ui="new"] h1{font-size:1.9rem;}
}
@media (max-width:380px){
  html[data-ui="new"] .tb-logo{display:none;}
}
@media print{ html[data-ui="new"] .topbar{display:none !important;} html[data-ui="new"] .app-shell{display:block;} }
html.calm-motion .ue-burst,html.calm-motion .ue-rays,html.calm-motion .ue-ico svg,html.calm-motion .tb-bump{animation:none !important;}
html[data-ui="new"] .nav-label, html[data-ui="new"] .rail-item{font-family:'Nunito', system-ui, sans-serif;}
.ue-dim{position:fixed; inset:0; z-index:9790; pointer-events:none; background:radial-gradient(circle at 50% 42%, rgba(17,16,48,.06), rgba(17,16,48,.28)); animation:ueFade .35s ease-out both;}
.ue-dim.ue-out{animation:ueFadeOut .4s ease-in forwards;}
@keyframes ueFade{from{opacity:0;}} @keyframes ueFadeOut{to{opacity:0;}}
.settings-theme-top{margin-top:0; padding-top:0; border-top:none;}
#settingsPanel .settings-field:has(#uiSoundToggle){padding-bottom:16px; border-bottom:1px solid rgba(0,0,0,.08);}
.settings-code{margin-top:22px; padding-top:18px; border-top:1px solid rgba(0,0,0,.08);}

/* ---------- forside (kode) i "new" ---------- */
.landing-new-bg, .landing-logo, .landing-perks{display:none;}
html[data-ui="new"] .landing{background:linear-gradient(160deg, #312E81 0%, #4F46E5 45%, #7C3AED 80%, #9D4EDD 100%);}
html[data-ui="new"] .landing-scene{display:none;}
html[data-ui="new"] .landing-new-bg{display:block; position:absolute; inset:0; z-index:0; overflow:hidden; pointer-events:none;}
.lnb-blob{position:absolute; border-radius:50%; filter:blur(60px); opacity:.55;}
.lnb-blob.b1{width:520px; height:520px; left:-140px; top:-160px; background:#14B8A6; animation:lnbDrift 18s ease-in-out infinite alternate;}
.lnb-blob.b2{width:460px; height:460px; right:-120px; bottom:-140px; background:#EC4899; opacity:.45; animation:lnbDrift 22s ease-in-out infinite alternate-reverse;}
.lnb-blob.b3{width:360px; height:360px; right:20%; top:-180px; background:#FCD34D; opacity:.28; animation:lnbDrift 26s ease-in-out infinite alternate;}
@keyframes lnbDrift{to{transform:translate(60px, 40px) scale(1.08);}}
.lnb-grid{position:absolute; inset:0; opacity:.12;
  background-image:radial-gradient(circle at 1px 1px, #fff 1.2px, transparent 0); background-size:28px 28px;
  -webkit-mask:radial-gradient(ellipse at center, #000 30%, transparent 75%); mask:radial-gradient(ellipse at center, #000 30%, transparent 75%);}
.lnb-item{position:absolute; display:block; aspect-ratio:1; filter:drop-shadow(0 10px 16px rgba(17,16,48,.35)); animation:lnbFloat var(--d) ease-in-out var(--dl) infinite alternate;}
.lnb-item svg{width:100%; height:100%; display:block;}
.lnb-pad{aspect-ratio:40/32;}
@keyframes lnbFloat{from{transform:translateY(-10px) rotate(-8deg);} to{transform:translateY(14px) rotate(8deg);}}

html[data-ui="new"] .landing-card{
  max-width:470px; padding:38px 34px 28px; border:none; border-radius:30px;
  background:rgba(255,255,255,.96); box-shadow:0 2px 0 rgba(255,255,255,.6) inset, 0 40px 90px rgba(17,16,48,.45);
}
html[data-ui="new"] .landing-card::before{display:none;}
html[data-ui="new"] .landing-card .landing-badge{display:none;}
html[data-ui="new"] .landing-logo{display:block; width:84px; height:84px; margin:-80px auto 12px; padding:10px; border-radius:26px; background:#fff; box-shadow:0 14px 34px rgba(49,46,129,.35);}
html[data-ui="new"] .landing-logo svg{width:100%; height:100%; display:block; animation:lnLogo 3.2s ease-in-out infinite;}
@keyframes lnLogo{0%,100%{transform:rotate(0) scale(1);} 50%{transform:rotate(-4deg) scale(1.05);}}
html[data-ui="new"] .landing-kicker{display:inline-block; padding:5px 12px; border-radius:999px; background:var(--primary-soft); color:var(--primary); font-family:'Nunito', sans-serif; font-weight:900; font-size:.72rem; letter-spacing:.12em; margin-bottom:10px;}
html[data-ui="new"] .landing-card h1{font-family:'Fredoka', 'Nunito', sans-serif; font-weight:600; color:var(--ink); font-size:clamp(2.1rem, 6vw, 2.8rem);
  background:linear-gradient(90deg, #312E81, #4F46E5 50%, #7C3AED); -webkit-background-clip:text; background-clip:text; -webkit-text-fill-color:transparent;}
html[data-ui="new"] .landing-lead{color:var(--ink-2); font-weight:600;}
html[data-ui="new"] .landing-card label{color:var(--ink); font-family:'Nunito', sans-serif; font-weight:800;}
html[data-ui="new"] .code-ticket{border:none; padding:0; background:none; box-shadow:none;}
html[data-ui="new"] .code-ticket::before, html[data-ui="new"] .code-ticket::after{display:none;}
html[data-ui="new"] .landing-card input{
  width:100%; box-sizing:border-box; height:64px; border-radius:18px; border:2px solid #DCDDFB; background:#F7F7FF;
  font-family:'Fredoka', 'Nunito', sans-serif; font-weight:600; font-size:1.6rem; letter-spacing:.06em; text-align:center; color:var(--ink);
  transition:border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
html[data-ui="new"] .landing-card input::placeholder{color:#A5A7C9; font-weight:500; letter-spacing:.02em; font-size:1.25rem;}
html[data-ui="new"] .landing-card input:focus{outline:none; border-color:var(--primary); background:#fff; box-shadow:0 0 0 5px var(--primary-ring);}
html[data-ui="new"] .landing-go{height:60px; border-radius:18px; font-size:1.15rem; background:linear-gradient(135deg, #6D5BFF, #4F46E5); box-shadow:0 10px 26px rgba(79,70,229,.45), inset 0 -3px 0 rgba(0,0,0,.15);}
html[data-ui="new"] .landing-go:hover{transform:translateY(-2px); box-shadow:0 14px 30px rgba(79,70,229,.5), inset 0 -3px 0 rgba(0,0,0,.15);}
html[data-ui="new"] .landing-go:active{transform:translateY(1px); box-shadow:0 6px 14px rgba(79,70,229,.4), inset 0 -3px 0 rgba(0,0,0,.15);}
html[data-ui="new"] .landing-go span{display:inline-block; transition:transform .2s ease;}
html[data-ui="new"] .landing-go:hover span{transform:translateX(4px);}
html[data-ui="new"] .landing-error{color:#D9443C;}
html[data-ui="new"] .landing-steps{display:none;}
html[data-ui="new"] .landing-perks{display:grid; grid-template-columns:repeat(3, 1fr); gap:8px; list-style:none; padding:16px 0 0; margin:12px 0 0; border-top:1px solid var(--line);}
html[data-ui="new"] .landing-perks li{display:flex; flex-direction:column; align-items:center; gap:6px; font-size:.82rem; font-weight:800; color:var(--ink-2);}
html[data-ui="new"] .lp-ico{width:44px; height:44px; border-radius:14px; display:flex; align-items:center; justify-content:center; background:var(--primary-soft);}
html[data-ui="new"] .landing-perks li:nth-child(1) .lp-ico{background:var(--gold-soft);}
html[data-ui="new"] .landing-perks li:nth-child(2) .lp-ico{background:var(--teal-soft);}
html[data-ui="new"] .landing-perks li:nth-child(3) .lp-ico{background:#FEF9C3;}
html[data-ui="new"] .lp-ico svg{width:28px; height:28px;}
html[data-ui="new"] .landing-perks li:nth-child(3) .lp-ico svg path{fill:#F59E0B;}
html[data-ui="new"] .browser-tip{background:var(--primary-soft); border:none; border-radius:18px; box-shadow:none;}
html[data-ui="new"] .browser-tip-head{color:var(--primary-dark); font-family:'Fredoka', sans-serif; font-weight:600;}
html[data-ui="new"] .browser-tip p{color:var(--ink-2);}
html[data-ui="new"] .browser-tip-btn{background:var(--primary); box-shadow:none; border-radius:14px;}
html[data-ui="new"] .browser-tip-btn:hover{background:var(--primary-dark);}
html[data-ui="new"] .catalog-status{color:var(--ink-2);}
@media (max-width:520px){
  html[data-ui="new"] .landing{padding:84px 14px 24px;}
  html[data-ui="new"] .landing-card{padding:32px 20px 22px;}
  html[data-ui="new"] .lnb-item{opacity:.55;}
  html[data-ui="new"] .landing-card input{height:58px; font-size:1.35rem;}
}
html.calm-motion .lnb-item,html.calm-motion .lnb-blob,html.calm-motion .landing-logo svg{animation:none !important;}
html[data-ui="new"] .landing{align-items:flex-start; padding-top:76px; padding-bottom:32px;}
html[data-ui="new"] .landing > .landing-card{margin:auto 0;}

/* tilstande på knapper/kort skal stadig kunne ses i "new" (sandt/falsk, quiz, sortering, rækkefølge) */
html[data-ui="new"] .chip.correct{background:#16A34A; border-color:#15803D; color:#fff;}
html[data-ui="new"] .chip.wrong{background:#E5534B; border-color:#C2410C; color:#fff;}
html[data-ui="new"] .chip:disabled:not(.correct):not(.wrong){opacity:.6;}
html[data-ui="new"] .drag-chip.armed{border-color:var(--primary); background:var(--primary-soft); box-shadow:0 0 0 4px var(--primary-ring);}
html[data-ui="new"] .seq-item.seq-locked{background:var(--teal-soft); border-color:#7DD3C7;}
html[data-ui="new"] .bin-item.placed-correct{background:#DCFCE7; border-color:#16A34A;}
html[data-ui="new"] .bin-item.placed-wrong{background:#FDE5E3; border-color:#E5534B;}

/* mønter og credits er knapperne til Mit arkade */
html[data-ui="new"] .tb-chip{cursor:pointer;}
html[data-ui="new"] .tb-chip:hover{box-shadow:0 0 0 3px rgba(79,70,229,.15), var(--shadow-sm);}

/* fremskridt mod det legendariske spil */
html[data-ui="new"] .tb-legend{display:inline-flex; align-items:center; gap:6px; height:42px; padding:0 12px 0 8px; border-radius:999px; flex-shrink:0; cursor:pointer;
  background:linear-gradient(135deg, #2E1A55, #1B1036); color:#FCD34D; border:1.5px solid rgba(252,211,77,.6); box-shadow:0 0 0 0 rgba(252,211,77,0);}
html[data-ui="new"] .tb-legend[hidden]{display:none;}
html[data-ui="new"] .tb-lg-crown{font-size:1.15rem;}
html[data-ui="new"] .tb-lg-bar{position:relative; width:64px; height:8px; border-radius:999px; background:rgba(255,255,255,.18); overflow:hidden;}
html[data-ui="new"] .tb-lg-bar i{position:absolute; inset:0 auto 0 0; border-radius:999px; background:linear-gradient(90deg, #F59E0B, #FCD34D); transition:width .4s ease;}
html[data-ui="new"] .tb-legend b{font-size:.8rem; font-weight:900; font-variant-numeric:tabular-nums; color:#FFF3B0;}
html[data-ui="new"] .tb-legend.ready{animation:tbLegendGlow 1.2s ease-in-out infinite;}
@keyframes tbLegendGlow{50%{box-shadow:0 0 0 4px rgba(252,211,77,.45), 0 0 22px rgba(252,211,77,.6);}}
@media (max-width:820px){ html[data-ui="new"] .tb-lg-bar{width:40px;} }
@media (max-width:600px){ html[data-ui="new"] .tb-legend{height:38px; padding:0 8px;} html[data-ui="new"] .tb-lg-bar{display:none;} html[data-ui="new"] .tb-legend b{font-size:.72rem;} }
@media (max-width:420px){ html[data-ui="new"] .tb-legend b{display:none;} html[data-ui="new"] .tb-legend{padding:0 6px;} }
