/* dress.css — wardrobe, contest tab, live contest */
.dr-root, .ct-root { position: absolute; inset: 0; }
.dr-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(14,6,22,.55), rgba(14,6,22,.35) 50%, rgba(14,6,22,.85)); }
.dr-hud { position: absolute; left: 10px; top: 10px; z-index: 5; }
.dr-petalchip { position: absolute; left: 10px; top: 46px; z-index: 5; }
.dr-prev { position: absolute; left: 8px; top: 80px; width: 227px; height: 340px; z-index: 2; }
.dr-prev img.girl { position: absolute; left: 0; top: 0; bottom: auto; margin: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom; filter: drop-shadow(0 6px 10px rgba(0,0,0,.6)); transition: opacity .15s, transform .2s; }
.dr-prev img.girl.swap { opacity: 0; transform: scale(.94); }
.dr-badges { position: absolute; left: 0; bottom: 4px; display: flex; gap: 6px; }
.dr-badge { min-width: 34px; height: 34px; border-radius: 17px; padding: 0 8px; display: flex; align-items: center; justify-content: center; background: rgba(20,8,26,.8); border: 1.5px solid var(--gold2); font-weight: 900; font-size: 14px; text-shadow: var(--outline); }
.dr-badge img { width: 24px; height: 24px; object-fit: contain; }
.dr-info { position: absolute; left: 240px; top: 72px; width: 150px; z-index: 4; display: flex; flex-direction: column; gap: 6px; }
.dr-infobox { background: rgba(20,8,28,.82); border: 1.5px solid var(--gold2); border-radius: 12px; padding: 8px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; text-shadow: var(--outline); animation: pop .25s cubic-bezier(.3,1.6,.5,1); }
.dr-iname { font-size: 16px; font-weight: 900; color: var(--gold); line-height: 1.15; }
.dr-row { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; line-height: 1.2; }
.dr-row img { width: 20px; height: 20px; object-fit: contain; }
.dr-dot { width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid #fff7ea; display: inline-block; }
.dr-tag { font-size: 12px; background: rgba(155,106,214,.35); border: 1px solid rgba(243,210,122,.5); border-radius: 8px; padding: 0 6px; }
.dr-bad { color: #ff7a8a; } .dr-good { color: #9be8a8; }
.dr-info .btn { width: 100%; }
.dr-tabs { position: absolute; left: 8px; right: 8px; top: 424px; display: flex; gap: 4px; z-index: 4; }
.dr-tab { flex: 1; min-height: 44px; min-width: 0; padding: 0 2px; border-radius: 10px; border: 1.5px solid rgba(243,210,122,.45); background: rgba(24,10,32,.85); color: var(--text); font-family: var(--font); font-weight: 800; font-size: 14px; text-shadow: var(--outline); cursor: pointer; transition: transform .1s; }
.dr-tab:active { transform: scale(.92); }
.dr-tab.on { background: linear-gradient(180deg, #d8405a, #7a1428); border-color: var(--gold); color: #fff1b8; }
.dr-grid { position: absolute; left: 6px; right: 6px; top: 474px; bottom: 70px; overflow-y: auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 4px; align-content: start; z-index: 3; }
.dr-grid::-webkit-scrollbar { width: 0; }
.dr-card { position: relative; display: flex; flex-direction: column; align-items: stretch; gap: 2px; padding: 4px; min-height: 150px; border-radius: 10px; background: rgba(28,12,36,.9); border: 2px solid rgba(243,210,122,.3); color: var(--text); font-family: var(--font); cursor: pointer; text-align: left; animation: pop .22s both; transition: transform .1s; }
.dr-card:active { transform: scale(.94); }
.dr-card.sel { border-color: #fff; }
.dr-card.wear { border-color: var(--gold); box-shadow: 0 0 10px rgba(243,210,122,.7); }
.dr-card.lock .dr-thumb { filter: grayscale(.7) brightness(.6); }
.dr-thumb { position: relative; width: 100%; height: 92px; border-radius: 7px; overflow: hidden; background: rgba(0,0,0,.35); display: flex; align-items: center; justify-content: center; flex: none; }
.dr-thumb img { position: static; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.dr-thumb.icon img { object-fit: contain; width: 80%; height: 80%; }
.dr-thumb.seal { font-size: 40px; font-weight: 900; color: var(--gold); text-shadow: var(--outline); }
.dr-cname { font-size: 13px; font-weight: 800; line-height: 1.15; text-shadow: var(--outline); min-height: 30px; }
.dr-cmeta { display: flex; align-items: center; gap: 4px; font-size: 12px; text-shadow: var(--outline); }
.dr-cmeta .dr-dot { width: 11px; height: 11px; }
.dr-mark { position: absolute; top: 2px; right: 2px; font-size: 12px; font-weight: 900; padding: 0 6px; border-radius: 8px; background: var(--gold); color: #3a1020; text-shadow: none; }
.dr-mark.own { background: #4f9a6a; color: #fff; }
.dr-petalbox { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 6px 8px; border-radius: 10px; background: rgba(60,20,50,.8); border: 1.5px solid var(--pink); font-weight: 800; font-size: 14px; text-shadow: var(--outline); }
.dr-petalbox img { width: 26px; height: 26px; object-fit: contain; }

/* contest tab */
.ct-bg { position: absolute; inset: 0; background: url(../../assets/bg-stage.webp) center / cover; filter: brightness(.45); }
.ct-scroll { position: absolute; left: 8px; right: 8px; top: 50px; bottom: 70px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 4px 2px 10px; }
.ct-scroll::-webkit-scrollbar { width: 0; }
.ct-banner { text-align: center; padding: 10px 8px; border-radius: 14px; border: 2px solid var(--gold); background: linear-gradient(180deg, rgba(179,36,58,.9), rgba(70,10,40,.92)); animation: pop .3s cubic-bezier(.3,1.6,.5,1); flex: none; }
.ct-banner .t { font-size: 26px; font-weight: 900; color: var(--gold); text-shadow: var(--outline); line-height: 1.15; }
.ct-banner .s { font-size: 14px; margin-top: 2px; text-shadow: var(--outline); }
.ct-card { padding: 8px 10px; border-radius: 12px; background: rgba(20,8,28,.85); border: 1.5px solid rgba(243,210,122,.55); display: flex; flex-direction: column; gap: 5px; font-size: 14px; text-shadow: var(--outline); flex: none; }
.ct-scroll > .btn { flex: none; align-self: center; }
.ct-h { font-size: 15px; font-weight: 900; color: var(--gold); }
.ct-line { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ct-chk { font-weight: 900; width: 20px; text-align: center; }
.ct-chk.y { color: #9be8a8; } .ct-chk.n { color: #8a7a90; }
.ct-rec { display: flex; align-items: center; gap: 8px; }
.ct-rec .th { width: 56px; height: 76px; border-radius: 8px; overflow: hidden; flex: none; border: 1.5px solid var(--gold2); }
.ct-rec .th img { position: static; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.ct-meds { display: flex; gap: 6px; flex-wrap: wrap; }
.medal { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 17px; color: #3a2008; text-shadow: none; border: 2px solid rgba(255,255,255,.8); box-shadow: inset 0 -4px 6px rgba(0,0,0,.25), 0 2px 4px rgba(0,0,0,.6); }
.medal.r1 { background: radial-gradient(circle at 35% 30%, #fff4b0, #d9a62e); }
.medal.r2 { background: radial-gradient(circle at 35% 30%, #ffffff, #a9b0c0); }
.medal.r3 { background: radial-gradient(circle at 35% 30%, #ffd0a0, #b0703a); }
.medal.r4 { background: radial-gradient(circle at 35% 30%, #cfc0d8, #6a5878); color: #fff; }
.medal.big { width: 110px; height: 110px; font-size: 56px; border-width: 4px; }

/* live contest */
.ct-live { position: absolute; inset: 0; background: #12081a url(../../assets/bg-stage.webp) center / cover; overflow: hidden; }
.ct-live .shade { position: absolute; inset: 0; background: rgba(10,4,16,.45); transition: background .5s; }
.ct-live.perf .shade { background: rgba(4,0,10,.72); }
.ct-spot { position: absolute; left: 50%; top: 0; width: 300px; height: 520px; margin-left: -150px; background: linear-gradient(180deg, rgba(255,240,200,.55), rgba(255,240,200,0) 95%); clip-path: polygon(40% 0, 60% 0, 100% 100%, 0 100%); opacity: 0; transition: opacity .6s; pointer-events: none; }
.ct-live.perf .ct-spot { opacity: 1; }
.ct-girl { position: absolute; left: 88px; top: 62px; height: 300px; width: 220px; bottom: auto; object-fit: contain; object-position: bottom; transition: left .8s ease, top .8s ease, height .8s ease, width .8s ease; filter: drop-shadow(0 6px 10px rgba(0,0,0,.7)); }
.ct-live.perf .ct-girl { left: 98px; top: 70px; height: 340px; width: 200px; }
.ct-live.rank .ct-girl { left: 8px; top: 60px; height: 190px; width: 120px; }
.ct-themecard { position: absolute; left: 20px; right: 20px; top: 190px; text-align: center; padding: 18px 10px; border-radius: 16px; border: 3px solid var(--gold); background: linear-gradient(180deg, rgba(179,36,58,.95), rgba(60,8,40,.95)); animation: slam .5s cubic-bezier(.3,1.7,.5,1) both; z-index: 5; }
.ct-themecard .t { font-size: 32px; font-weight: 900; color: var(--gold); text-shadow: var(--outline); line-height: 1.2; }
.ct-themecard .s { font-size: 15px; margin-top: 6px; text-shadow: var(--outline); }
@keyframes slam { 0% { transform: scale(2.4); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.ct-sub { position: absolute; left: 14px; right: 14px; bottom: 150px; text-align: center; font-size: 17px; font-weight: 800; line-height: 1.4; text-shadow: var(--outline); z-index: 9; pointer-events: none; transition: opacity .3s; }
.ct-dress { position: absolute; left: 0; right: 0; bottom: 0; padding: 6px 8px 10px; display: flex; flex-direction: column; gap: 6px; background: linear-gradient(180deg, rgba(14,6,22,0), rgba(14,6,22,.92) 14%); z-index: 6; animation: drop .25s ease-out; }
.ct-hrow { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 4px; flex: none; }
.ct-hrow::-webkit-scrollbar { height: 0; }
.ct-hrow .dr-card { flex: none; width: 88px; min-height: 0; }
.ct-hrow .dr-thumb { height: 72px; }
.ct-hrow .dr-cname { min-height: 0; font-size: 12px; }
.ct-chip { flex: none; min-height: 44px; min-width: 64px; padding: 2px 10px; border-radius: 22px; border: 2px solid rgba(243,210,122,.4); background: rgba(28,12,36,.9); color: var(--text); font-family: var(--font); font-weight: 800; font-size: 14px; text-shadow: var(--outline); cursor: pointer; display: flex; align-items: center; gap: 4px; }
.ct-chip.on { border-color: var(--gold); background: linear-gradient(180deg, #d8405a, #7a1428); }
.ct-chip img { position: static; width: 24px; height: 24px; object-fit: contain; }
.ct-match { display: flex; justify-content: space-between; align-items: center; gap: 4px; font-size: 14px; font-weight: 800; text-shadow: var(--outline); }
.ct-match span.m { padding: 2px 8px; border-radius: 10px; background: rgba(0,0,0,.5); }
.ct-est { font-size: 17px; color: var(--gold); font-weight: 900; }
.ct-judge { position: absolute; left: 18px; right: 18px; bottom: 60px; padding: 10px 14px; border-radius: 14px; background: rgba(14,6,22,.88); border: 2px solid var(--gold2); display: flex; flex-direction: column; gap: 4px; z-index: 6; animation: drop .25s ease-out; }
.ct-jrow { display: flex; justify-content: space-between; font-size: 17px; font-weight: 800; text-shadow: var(--outline); animation: pop .22s cubic-bezier(.3,1.6,.5,1); }
.ct-jrow.total { font-size: 24px; color: var(--gold); border-top: 1px solid var(--gold2); padding-top: 4px; }
.ct-rank { position: absolute; left: 12px; right: 12px; top: 270px; display: flex; flex-direction: column; gap: 8px; z-index: 6; }
.ct-bar { display: flex; align-items: center; gap: 6px; animation: drop .25s ease-out both; }
.ct-bar .rk { width: 36px; flex: none; }
.ct-bar .nm { width: 86px; flex: none; font-size: 14px; font-weight: 800; text-shadow: var(--outline); line-height: 1.1; }
.ct-bar .tr { flex: 1; height: 20px; background: rgba(0,0,0,.55); border-radius: 10px; border: 1.5px solid var(--gold2); overflow: hidden; }
.ct-bar .fl { height: 100%; width: 0; background: linear-gradient(90deg, #7a4fc9, #ff9ec0); transition: width 1.4s ease-out; }
.ct-bar.me .fl { background: linear-gradient(90deg, #c9973a, #fff1b8); }
.ct-bar .sc { width: 38px; text-align: right; font-weight: 900; font-size: 15px; text-shadow: var(--outline); }
.ct-result { width: 330px; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.ct-result .rt { font-size: 24px; font-weight: 900; color: var(--gold); text-shadow: var(--outline); }
.ct-result .rw { font-size: 16px; font-weight: 800; text-shadow: var(--outline); display: flex; align-items: center; gap: 5px; justify-content: center; }
.ct-result .rw img { width: 24px; height: 24px; object-fit: contain; }
.ct-result .medal { animation: slam .5s cubic-bezier(.3,1.7,.5,1) both; }
.ct-bar .rk .medal { width: 32px; height: 32px; font-size: 15px; }
