:root{
    --font:'Press Start 2P',monospace;
    --q-xs:6px;
    --q-sm:7px;
    --q-body:8px;
    --q-label:10px;
    --q-card:12px;
    --q-title:24px;
}

[data-theme="dark"]{
    --q-bg:#1f252e;
    --q-bg-soft:#252c36;
    --q-panel:rgba(57,62,70,.48);
    --q-panel-solid:#292f38;

    --q-line:rgba(223,208,184,.18);
    --q-line-strong:rgba(223,208,184,.32);

    --q-text:#DFD0B8;
    --q-muted:rgba(223,208,184,.62);
    --q-dim:rgba(223,208,184,.34);

    --q-gold:#E9C46A;
    --q-gold-soft:rgba(233,196,106,.12);

    --q-red:#E76F51;
    --q-green:#70B77E;
    --q-shadow:#121820;
}

[data-theme="light"]{
    --q-bg:#249D8F;
    --q-bg-soft:#218F83;
    --q-panel:rgba(253,240,213,.10);
    --q-panel-solid:#238D82;

    --q-line:rgba(253,240,213,.22);
    --q-line-strong:rgba(253,240,213,.40);

    --q-text:#FDF0D5;
    --q-muted:rgba(253,240,213,.72);
    --q-dim:rgba(253,240,213,.42);

    --q-gold:#F0CB68;
    --q-gold-soft:rgba(240,203,104,.14);

    --q-red:#FF8A6D;
    --q-green:#A6D69F;
    --q-shadow:#176B63;
}

*{box-sizing:border-box}

body{
    color:var(--q-text);
    background:var(--q-bg);
    font-family:var(--font);
}

.screen{
    width:100%;
    min-height:100svh;
    padding:112px 24px 50px;

    display:flex;
    align-items:center;
    justify-content:center;

    background:
        radial-gradient(circle at 50% 42%,rgba(223,208,184,.045),transparent 34%),
        linear-gradient(180deg,var(--q-bg-soft),var(--q-bg));
}


/* =========================================================
   NAV
   ========================================================= */

.quiz-nav{
    position:fixed;
    z-index:9000;

    top:0;
    left:0;
    right:0;

    height:86px;
    padding:0 clamp(18px,5vw,40px);

    display:grid;
    grid-template-columns:1fr auto 1fr;
    align-items:center;

    background:rgba(31,37,46,.94);
    backdrop-filter:blur(14px);

    border-bottom:1px solid var(--q-line);
}

[data-theme="light"] .quiz-nav{
    background:rgba(36,157,143,.94);
}

.quiz-nav-back{
    justify-self:start;
    padding:8px 0;

    border:0;
    background:transparent;

    color:var(--q-text);

    font-family:var(--font);
    font-size:8px;

    cursor:pointer;
}

.quiz-nav-back span{
    margin-left:6px;
}

.quiz-nav-title{
    justify-self:center;

    color:var(--q-text);

    font-size:11px;
    letter-spacing:1px;

    white-space:nowrap;
}

.quiz-menu-btn{
    justify-self:end;

    width:46px;
    height:46px;
    padding:0;

    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:5px;

    border:1px solid var(--q-line);
    border-radius:14px;

    background:rgba(255,255,255,.025);

    cursor:pointer;
}

.quiz-menu-btn span{
    width:18px;
    height:2px;

    border-radius:2px;
    background:var(--q-text);

    transition:.25s;
}

.quiz-menu-btn.active span:nth-child(1){
    transform:translateY(7px) rotate(45deg);
}

.quiz-menu-btn.active span:nth-child(2){
    opacity:0;
}

.quiz-menu-btn.active span:nth-child(3){
    transform:translateY(-7px) rotate(-45deg);
}


/* =========================================================
   MENU
   ========================================================= */

.quiz-menu-overlay{
    position:fixed;
    z-index:9999;

    inset:86px 0 0;

    background:rgba(7,10,14,.30);
    backdrop-filter:blur(2px);
}

.quiz-menu{
    position:fixed;
    z-index:10000;

    top:96px;
    right:clamp(16px,4vw,36px);

    width:min(330px,calc(100vw - 32px));
    padding:18px;

    border:1px solid var(--q-line);
    border-radius:22px;

    background:rgba(41,47,56,.98);
    backdrop-filter:blur(18px);

    box-shadow:0 18px 50px rgba(0,0,0,.30);
}

[data-theme="light"] .quiz-menu{
    background:rgba(32,137,126,.98);
}

.quiz-menu-head{
    display:flex;
    align-items:center;
    gap:12px;

    padding:4px 4px 14px;

    border-bottom:1px solid var(--q-line);
}

.quiz-menu-avatar{
    width:42px;
    height:42px;
    flex:0 0 42px;

    display:grid;
    place-items:center;

    border-radius:12px;

    background:var(--q-gold);
    color:#222831;

    font-size:15px;
}

.quiz-menu-user{
    font-size:9px;
}

.quiz-menu-status{
    margin-top:5px;

    color:var(--q-dim);

    font-size:6px;
}

.quiz-menu-trisha{
    margin:14px 0;
    padding:10px;

    display:grid;
    grid-template-columns:64px 1fr;
    gap:10px;
    align-items:center;

    border-radius:15px;

    background:rgba(255,255,255,.035);
}

.quiz-menu-trisha img{
    width:64px;
    height:64px;

    object-fit:contain;
}

.quiz-menu-trisha p{
    margin:0;

    color:var(--q-muted);

    font-size:6px;
    line-height:1.9;
}

.quiz-menu-row{
    width:100%;
    min-height:49px;
    padding:0 11px;

    display:grid;
    grid-template-columns:26px 1fr auto;
    align-items:center;

    border:0;
    border-top:1px solid var(--q-line);

    background:transparent;
    color:var(--q-text);

    font-family:var(--font);
    text-align:left;

    cursor:pointer;
}

.quiz-menu-row span:nth-child(2){
    font-size:7px;
}

.quiz-menu-row b{
    color:var(--q-dim);

    font-size:6px;
    font-weight:400;
}

.quiz-menu-row:hover{
    background:rgba(255,255,255,.035);
}

.quiz-menu-logout{
    color:var(--q-red);
}


/* =========================================================
   HOME
   ========================================================= */

.start-content{
    width:100%;
    max-width:680px;

    display:flex;
    flex-direction:column;
    align-items:center;

    text-align:center;
}

.game-logo{
    margin:34px 0 48px;
}

.game-logo-main{
    color:var(--q-text);

    font-size:clamp(50px,10vw,74px);
    line-height:1;
    letter-spacing:2px;

    text-shadow:
        2px 2px 0 #c4b49d,
        4px 4px 0 #aa9a83,
        6px 6px 0 #877866,
        8px 8px 0 #665849,
        10px 10px 0 #493f35,
        12px 12px 0 #302921,
        0 0 18px rgba(223,208,184,.30),
        0 0 42px rgba(223,208,184,.14);
}

.game-logo-sub{
    margin-top:24px;

    color:#A89780;

    font-size:clamp(11px,3vw,16px);
    letter-spacing:6px;

    text-shadow:
        2px 2px 0 #6F6254,
        4px 4px 0 #493F35;
}


/* TAHUKAH KAMU */

.home-fact{
    width:100%;
    max-width:640px;

    padding:25px 28px;

    border-top:1px solid var(--q-line);
    border-bottom:1px solid var(--q-line);
}

.home-fact-label{
    color:var(--q-gold);

    font-size:8px;
    line-height:1.6;
    letter-spacing:1px;
}

.home-fact-text{
    max-width:590px;

    margin:18px auto 0;

    color:var(--q-text);

    font-size:9px;
    line-height:2;
}

.home-fact-text strong{
    color:var(--q-gold);

    font-size:12px;
}

.home-fact-sub{
    max-width:575px;

    margin:12px auto 0;

    color:var(--q-muted);

    font-size:7px;
    line-height:2;
}

.home-playable-text{
    max-width:590px;

    margin:19px auto 0;

    color:var(--q-muted);

    font-size:8px;
    line-height:2;
}

.home-playable-text strong{
    color:var(--q-text);
}

.home-playable-text #home-total-songs{
    color:var(--q-gold);

    font-size:12px;
}


/* GAME BRIEF */

.home-brief{
    width:100%;
    max-width:610px;

    margin-top:31px;
}

.home-brief-main{
    margin:0;

    color:var(--q-text);

    font-size:8px;
    line-height:2;
}

.home-brief-sub{
    max-width:570px;

    margin:12px auto 0;

    color:var(--q-muted);

    font-size:7px;
    line-height:2;
}

.home-brief-sub strong{
    color:var(--q-text);
}

.home-stage-title{
    margin-top:23px;

    color:var(--q-dim);

    font-size:6px;
    letter-spacing:1.2px;
}


/* STAGES */

.start-stages{
    margin-top:13px;

    display:flex;
    justify-content:center;
    flex-wrap:wrap;
    gap:7px;
}

.start-stages span{
    min-width:66px;
    padding:9px 10px;

    border:2px solid var(--q-line-strong);
    border-radius:999px;

    background:rgba(255,255,255,.018);
    color:var(--q-text);

    font-size:6px;
}

.start-stages span:first-child{
    border-color:rgba(233,196,106,.48);

    background:rgba(233,196,106,.05);
    color:var(--q-gold);
}


/* MAIN BUTTON */

.pixel-main-btn{
    margin-top:32px;

    min-width:270px;
    padding:22px 30px;

    border:4px solid var(--q-text);

    background:#393E46;
    color:var(--q-text);

    box-shadow:8px 8px 0 var(--q-shadow);

    font-family:var(--font);
    font-size:15px;

    cursor:pointer;
}

.pixel-main-btn span{
    margin-right:14px;

    font-size:10px;
}

.pixel-main-btn:disabled{
    opacity:.35;

    cursor:not-allowed;
}

.home-start-btn{
    margin-top:33px;
}

.home-info-btn{
    margin-top:19px;
    padding:10px 12px;

    border:0;
    background:transparent;

    color:var(--q-muted);

    font-family:var(--font);
    font-size:6.5px;

    cursor:pointer;

    transition:.2s;
}

.home-info-btn:hover{
    color:var(--q-gold);
}


/* =========================================================
   FILTER
   ========================================================= */

.filter-content{
    width:100%;
    max-width:700px;

    display:flex;
    flex-direction:column;
    align-items:center;

    text-align:center;
}

.filter-title{
    margin:35px 0 28px;

    font-size:24px;
}

.filter-title span{
    margin-right:12px;

    color:#678798;
}

.filter-desc{
    margin-bottom:32px;

    color:var(--q-muted);

    font-size:8px;
}

.filter-options{
    width:100%;

    display:flex;
    flex-direction:column;
    gap:14px;
}

.filter-check{
    width:100%;
    min-height:82px;

    padding:0 28px;

    display:grid;
    grid-template-columns:48px 1fr auto;
    align-items:center;

    border:3px solid rgba(223,208,184,.13);
    border-radius:24px;

    background:var(--q-panel);

    cursor:pointer;
}

.filter-check input{
    display:none;
}

.check-box{
    width:36px;
    height:36px;

    display:grid;
    place-items:center;

    border:3px solid var(--q-line);
    border-radius:10px;
}

.filter-check input:checked + .check-box{
    border-color:var(--q-gold);

    background:var(--q-gold);
}

.filter-check input:checked + .check-box::after{
    content:'✓';

    color:#222831;

    font-size:19px;
}

.check-label{
    justify-self:start;

    font-size:11px;
}

.check-count{
    color:var(--q-dim);

    font-size:6px;
}

.filter-bulk{
    margin-top:26px;

    display:flex;
    gap:10px;
}

.btn-filter-bulk{
    padding:12px 17px;

    border:2px solid var(--q-line);
    border-radius:14px;

    background:var(--q-panel);
    color:var(--q-dim);

    font-family:var(--font);
    font-size:6px;

    cursor:pointer;
}

.filter-count{
    margin-top:26px;

    color:var(--q-text);

    font-size:8px;
}

.filter-progress{
    min-height:16px;

    margin-top:11px;

    color:var(--q-dim);

    font-size:5.5px;
    line-height:1.8;
}

.filter-start-btn{
    margin-top:24px;
}


/* =========================================================
   GAME
   ========================================================= */

.screen-quiz{
    align-items:center;
    justify-content:flex-start;

    padding-top:130px;
}

.quiz-game-wrap{
    width:100%;
    max-width:760px;

    display:flex;
    flex-direction:column;
    align-items:center;
}

.quiz-progress-wrap{
    width:100%;

    display:flex;
    align-items:center;
    gap:16px;
}

.quiz-progress-bar{
    flex:1;

    height:10px;

    overflow:hidden;

    border-radius:999px;

    background:rgba(223,208,184,.07);
}

.quiz-progress-fill{
    width:0;
    height:100%;

    border-radius:inherit;

    background:linear-gradient(90deg,var(--q-gold),#D39850);
}

.quiz-counter{
    min-width:52px;

    color:var(--q-muted);

    font-size:8px;
}

.stage-track{
    width:100%;

    margin-top:20px;

    display:grid;
    grid-template-columns:repeat(6,1fr);
    gap:8px;
}

.stage-box{
    height:68px;

    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:8px;

    border:3px solid rgba(223,208,184,.12);
    border-radius:18px;
}

.stage-box.active{
    border-color:rgba(233,196,106,.48);
}

.stage-box.correct{
    border-color:var(--q-green);
}

.stage-box.wrong{
    border-color:var(--q-red);
}

.stage-box.skipped{
    border-color:rgba(233,196,106,.35);
}

.stage-label{
    color:var(--q-dim);

    font-size:6px;
}

.stage-icon{
    min-height:15px;

    font-size:15px;
}

.quiz-cover-wrap{
    position:relative;

    width:170px;
    height:170px;

    margin-top:26px;

    overflow:hidden;

    border-radius:30px;
}

.quiz-cover{
    width:100%;
    height:100%;

    object-fit:cover;

    filter:blur(24px) brightness(.28);
}

.quiz-cover.revealed{
    filter:none;
}

.quiz-cover-overlay{
    position:absolute;

    inset:0;

    display:grid;
    place-items:center;

    font-size:50px;
}

.quiz-cover-overlay.hidden-overlay{
    opacity:0;
}

.quiz-player{
    margin-top:22px;
}

.btn-audio{
    min-width:235px;

    padding:16px 22px;

    border:3px solid var(--q-line);
    border-radius:40px;

    background:var(--q-panel);
    color:var(--q-text);

    font-family:var(--font);
    font-size:7px;

    cursor:pointer;
}

.quiz-trisha{
    width:100%;

    margin-top:26px;

    display:grid;
    grid-template-columns:90px 1fr;
    gap:13px;
    align-items:center;
}

.quiz-trisha-img{
    width:90px;
    height:90px;

    object-fit:contain;
}

.quiz-trisha-dialog{
    min-height:78px;

    padding:17px 20px;

    display:flex;
    align-items:center;

    border:2px solid var(--q-line);
    border-radius:22px;

    background:var(--q-panel);
    color:var(--q-muted);

    font-size:8px;
    line-height:2;
}

.quiz-input-row{
    width:100%;

    margin-top:20px;
}

.quiz-input-wrap{
    position:relative;

    width:100%;

    display:grid;
    grid-template-columns:1fr 68px;
    gap:10px;
}

.quiz-input{
    height:70px;

    padding:0 21px;

    border:3px solid var(--q-line);
    border-radius:23px;

    background:var(--q-panel);
    color:var(--q-text);

    font-family:var(--font);
    font-size:8px;

    outline:none;
}

.quiz-input.shake{
    animation:shake .4s ease;
}

@keyframes shake{
    0%,100%{transform:translateX(0)}
    25%{transform:translateX(-7px)}
    50%{transform:translateX(7px)}
    75%{transform:translateX(-4px)}
}

.btn-submit{
    height:70px;

    border:0;
    border-radius:23px;

    background:rgba(74,79,89,.75);
    color:var(--q-text);

    font-size:20px;

    cursor:pointer;
}

.search-suggestions{
    position:absolute;

    left:0;
    right:78px;
    bottom:78px;

    max-height:240px;

    overflow-y:auto;

    display:none;
    z-index:600;

    border:1px solid var(--q-line);
    border-radius:16px;

    background:var(--q-panel-solid);
}

.search-suggestions.show{
    display:block;
}

.suggestion-item{
    padding:15px;

    color:var(--q-text);

    font-size:7px;
    line-height:1.7;

    cursor:pointer;
}

.suggestion-item.highlighted{
    background:var(--q-gold-soft);
}

.suggestion-type{
    display:block;

    margin-top:5px;

    color:var(--q-dim);

    font-size:5px;
}

.quiz-action-row{
    width:100%;

    margin-top:14px;

    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px;
}

.btn-action{
    height:56px;

    border-radius:19px;

    background:var(--q-panel);

    font-family:var(--font);
    font-size:7px;

    cursor:pointer;
}

.btn-skip{
    border:3px solid var(--q-line);

    color:var(--q-muted);
}

.btn-hint{
    border:3px solid rgba(231,111,81,.15);

    color:var(--q-red);
}

.hint-display{
    width:100%;

    margin-top:14px;

    color:var(--q-red);

    font-size:7px;
    line-height:2;

    text-align:center;
}


/* =========================================================
   AUDIO WAVE
   ========================================================= */

.audio-wave{
    height:26px;

    margin-top:10px;

    display:flex;
    align-items:center;
    justify-content:center;
    gap:4px;
}

.audio-wave span{
    width:4px;
    height:10px;

    background:var(--q-gold);

    animation:qWave .65s ease-in-out infinite alternate;
}

.audio-wave span:nth-child(2){
    height:22px;

    animation-delay:.1s;
}

.audio-wave span:nth-child(3){
    height:15px;

    animation-delay:.2s;
}

.audio-wave span:nth-child(4){
    height:25px;

    animation-delay:.3s;
}

.audio-wave span:nth-child(5){
    height:12px;

    animation-delay:.4s;
}

@keyframes qWave{
    to{
        transform:scaleY(.35);

        opacity:.45;
    }
}


/* =========================================================
   REVEAL
   ========================================================= */

.quiz-reveal{
    position:fixed;
    inset:0;

    z-index:15000;

    display:flex;
    align-items:center;
    justify-content:center;

    padding:7px;

    background:rgba(10,14,20,.78);

    backdrop-filter:blur(9px);
}

.reveal-card{
    width:100%;
    max-width:500px;
    max-height:97vh;

    overflow-y:auto;

    padding:14px 22px 17px;

    display:flex;
    flex-direction:column;
    align-items:center;

    border:3px solid var(--q-line);
    border-radius:25px;

    background:var(--q-panel-solid);
}

.reveal-status{
    font-size:27px;
    line-height:1;
}

.reveal-cover-small{
    width:104px;
    height:104px;

    margin-top:5px;

    overflow:hidden;

    border-radius:17px;
}

.reveal-cover-small img{
    width:100%;
    height:100%;

    object-fit:cover;
}

.reveal-song-title{
    margin-top:10px;

    color:var(--q-gold);

    font-size:11px;
    line-height:1.55;

    text-align:center;
}

.reveal-player-name{
    margin-top:5px;

    padding:5px 9px;

    border:1px solid rgba(233,196,106,.20);
    border-radius:999px;

    background:rgba(233,196,106,.055);
    color:var(--q-muted);

    font-size:5.5px;
    letter-spacing:.4px;
}

.reveal-trisha-row{
    width:100%;

    margin-top:10px;

    display:grid;
    grid-template-columns:68px 1fr;
    gap:10px;
    align-items:center;
}

.reveal-trisha-img{
    width:68px;
    height:68px;

    object-fit:cover;

    border-radius:14px;
}

.reveal-message{
    min-height:61px;

    padding:11px 13px;

    display:flex;
    align-items:center;

    border:1px solid var(--q-line);
    border-radius:15px;

    color:var(--q-muted);

    font-size:6.5px;
    line-height:1.75;
}

.reveal-player{
    width:100%;

    margin-top:10px;

    display:flex;
    align-items:center;
    justify-content:center;
    gap:11px;
}

.btn-reveal-play{
    min-width:148px;
    min-height:45px;

    padding:10px 13px;

    border:2px solid var(--q-line);
    border-radius:15px;

    background:var(--q-panel);
    color:var(--q-text);

    font-family:var(--font);
    font-size:6px;

    cursor:pointer;
}

.reveal-player .audio-wave{
    width:75px;
    height:35px;

    margin:0;

    display:flex;
    align-items:center;
    justify-content:center;
    gap:4px;
}

.reveal-player .audio-wave span{
    width:5px;
    height:12px;

    border-radius:3px;

    background:var(--q-gold);
}

.reveal-player .audio-wave span:nth-child(2){height:25px}
.reveal-player .audio-wave span:nth-child(3){height:18px}
.reveal-player .audio-wave span:nth-child(4){height:29px}
.reveal-player .audio-wave span:nth-child(5){height:15px}

.reveal-divider{
    width:100%;
    height:1px;

    margin:9px 0;

    background:var(--q-line);
}


/* =========================================================
   STATS
   ========================================================= */

.reveal-stats-title{
    color:var(--q-gold);

    font-size:10px;
    line-height:1.3;
    letter-spacing:.4px;
}

.reveal-stats{
    width:100%;

    margin-top:8px;

    display:flex;
    flex-direction:column;
    gap:3px;
}

.stat-row{
    width:100%;
    min-height:27px;

    padding:3px 5px;

    display:grid;
    grid-template-columns:45px 1fr 37px;
    gap:7px;
    align-items:center;

    border:1px solid transparent;
    border-radius:9px;
}

.stat-row.highlight{
    border-color:rgba(233,196,106,.42);

    background:rgba(233,196,106,.075);
}

.stat-label,
.stat-pct{
    color:var(--q-dim);

    font-size:6px;
    line-height:1;
}

.stat-label{
    text-align:right;
}

.stat-pct{
    text-align:left;
}

.stat-row.highlight .stat-label,
.stat-row.highlight .stat-pct{
    color:var(--q-gold);
}

.stat-bar-bg{
    width:100%;
    height:13px;

    overflow:hidden;

    border-radius:999px;

    background:rgba(255,255,255,.06);
}

.stat-bar-fill{
    width:0;
    height:100%;

    border-radius:inherit;

    background:rgba(223,208,184,.30);

    transition:width .75s cubic-bezier(.22,1,.36,1);
}

.stat-bar-fill.player-bar{
    background:var(--q-gold);

    box-shadow:0 0 8px rgba(233,196,106,.22);
}

.stat-bar-fill.fail-bar{
    background:rgba(231,111,81,.78);
}

.stats-loading,
.stats-error{
    padding:10px 6px;

    color:var(--q-dim);

    font-size:6px;

    text-align:center;
}

.reveal-stats-note{
    margin-top:8px;

    color:var(--q-muted);

    font-size:6px;
    line-height:1.45;

    text-align:center;
}

.reveal-game-link{
    margin-top:4px;

    color:var(--q-gold);

    font-size:6px;
    line-height:1.4;

    text-decoration:none;
}

.reveal-buttons{
    width:100%;

    margin-top:11px;

    display:flex;
    flex-direction:column;
    gap:7px;
}

.btn-reveal-download,
.btn-reveal-next{
    width:100%;
    min-height:48px;

    border-radius:16px;

    font-family:var(--font);
    font-size:7px;

    cursor:pointer;
}

.btn-reveal-download{
    border:2px solid var(--q-line);

    background:var(--q-panel);
    color:var(--q-text);
}

.btn-reveal-next{
    min-height:54px;

    border:3px solid rgba(233,196,106,.55);

    background:var(--q-gold);
    color:#292f38;

    box-shadow:4px 4px 0 rgba(0,0,0,.16);

    font-size:8px;
}

.reveal-card.capture-mode{
    height:auto!important;
    min-height:0!important;
    max-height:none!important;

    overflow:visible!important;

    padding-bottom:18px!important;
}

.reveal-card.capture-mode .reveal-buttons{
    display:none!important;
}


/* =========================================================
   RESULT - COMPACT
   ========================================================= */

.result-content{
    width:100%;
    max-width:680px;
    display:flex;
    flex-direction:column;
    align-items:center;
    text-align:center;
}

.result-title{
    margin:10px 0 20px;
    font-size:20px;
}

/* Trisha + caption */
.result-trisha-wrap{
    width:100%;
    display:grid;
    grid-template-columns:105px 1fr;
    gap:14px;
    align-items:center;
}

.result-trisha-img{
    width:105px;
    height:105px;
    object-fit:cover;
    border-radius:17px;
}

.result-trisha-caption{
    min-height:82px;
    padding:14px 16px;
    display:flex;
    align-items:center;

    border:2px solid var(--q-line);
    border-radius:18px;

    background:var(--q-panel);
    color:var(--q-muted);

    font-size:6.5px;
    line-height:1.8;
    text-align:left;
}

/* Summary */
.result-summary{
    width:100%;
    margin-top:16px;
    padding:13px 17px;

    display:flex;
    flex-direction:column;
    gap:8px;

    border:1px solid var(--q-line);
    border-radius:16px;

    font-size:6.5px;
}

.result-summary-item{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:14px;
}

.result-summary-label{
    color:var(--q-dim);
    text-align:left;
}

.result-summary-value{
    max-width:65%;
    color:var(--q-text);
    text-align:right;
    line-height:1.5;
}

/* Discovery progress */
.result-progress-wrap{
    width:100%;
    margin-top:13px;
}

.result-progress-head{
    display:flex;
    justify-content:space-between;
    align-items:center;

    color:var(--q-dim);
    font-size:5.5px;
}

.result-progress-bar{
    width:100%;
    height:8px;
    margin-top:6px;

    overflow:hidden;
    border-radius:999px;

    background:rgba(255,255,255,.055);
}

.result-progress-fill{
    height:100%;
    border-radius:inherit;
    background:var(--q-gold);
}

/* List 5 songs */
.result-table{
    width:100%;
    margin-top:18px;

    display:flex;
    flex-direction:column;
    gap:7px;
}

.result-row{
    min-height:54px;
    padding:10px 15px;

    display:grid;
    grid-template-columns:28px 1fr 58px;
    gap:8px;
    align-items:center;

    border:2px solid var(--q-line);
    border-radius:16px;

    background:var(--q-panel);
}

.result-num{
    color:var(--q-dim);
    font-size:5.5px;
}

.result-song-name{
    font-size:6.3px;
    line-height:1.55;
    text-align:left;
}

.result-stage{
    color:var(--q-dim);
    font-size:5.5px;
    line-height:1.4;
    text-align:right;
}

.correct-row .result-stage{
    color:var(--q-gold);
}

.wrong-row .result-stage{
    color:var(--q-red);
}

/* Buttons */
.result-actions{
    width:100%;
    margin-top:18px;

    display:grid;
    grid-template-columns:145px 1fr;
    gap:10px;
    align-items:stretch;
}

.btn-download{
    min-width:0;
    width:100%;
    min-height:54px;

    border:2px solid var(--q-line);
    border-radius:15px;

    background:var(--q-panel);
    color:var(--q-text);

    font-family:var(--font);
    font-size:6.5px;

    cursor:pointer;
}

.result-replay{
    width:100%;
    min-width:0;
    min-height:54px;

    margin:0;
    padding:14px 18px;

    border-width:3px;
    box-shadow:5px 5px 0 var(--q-shadow);

    font-size:10px;
}

.result-replay span{
    margin-right:10px;
    font-size:7px;
}

.result-game-link{
    margin-top:15px;
    color:var(--q-gold);
    font-size:5.5px;
    text-decoration:none;
}

/* =========================================================
   AUTH
   ========================================================= */

.auth-popup{
    position:fixed;
    inset:0;

    z-index:20000;

    display:flex;
    align-items:center;
    justify-content:center;

    padding:20px;
}

.auth-popup-backdrop{
    position:absolute;
    inset:0;

    background:rgba(10,14,20,.78);

    backdrop-filter:blur(8px);
}

.auth-popup-card{
    position:relative;
    z-index:2;

    width:100%;
    max-width:430px;

    padding:30px 27px 28px;

    border:2px solid var(--q-line);
    border-radius:28px;

    background:var(--q-panel-solid);

    text-align:center;
}

.auth-popup-close{
    position:absolute;

    top:13px;
    right:16px;

    border:0;
    background:none;

    color:var(--q-muted);

    font-size:24px;

    cursor:pointer;
}

.auth-popup-trisha{
    width:105px;
    height:105px;

    object-fit:contain;
}

.auth-popup-caption{
    max-width:350px;

    margin:13px auto 23px;

    color:var(--q-muted);

    font-size:7px;
    line-height:2;
}

.auth-popup-title{
    margin-bottom:16px;

    color:var(--q-gold);

    font-size:11px;
}

.auth-popup-input{
    width:100%;
    height:55px;

    margin-bottom:10px;
    padding:0 17px;

    border:2px solid var(--q-line);
    border-radius:15px;

    background:rgba(255,255,255,.035);
    color:var(--q-text);

    font-family:var(--font);
    font-size:7px;
}

.auth-popup-error{
    min-height:17px;

    color:var(--q-red);

    font-size:6px;
}

.auth-popup-main-btn{
    width:100%;
    height:57px;

    border:3px solid var(--q-gold);

    background:var(--q-gold);
    color:#222831;

    font-family:var(--font);
    font-size:9px;

    cursor:pointer;
}

.auth-popup-switch{
    margin-top:17px;

    color:var(--q-dim);

    font-size:6px;
}

.auth-popup-switch button{
    border:0;
    background:none;

    color:var(--q-gold);

    font-family:var(--font);
    font-size:6px;

    cursor:pointer;
}


/* =========================================================
   HOW TO PLAY POPUP
   ========================================================= */

.info-popup,
.confirm-popup{
    position:fixed;
    inset:0;

    z-index:22000;

    display:flex;
    align-items:center;
    justify-content:center;

    padding:18px;
}

.info-popup-backdrop,
.confirm-popup-backdrop{
    position:absolute;
    inset:0;

    background:rgba(8,11,16,.80);

    backdrop-filter:blur(8px);
}

.info-popup-card{
    position:relative;
    z-index:2;

    width:100%;
    max-width:500px;
    max-height:90vh;

    overflow-y:auto;

    padding:27px 28px 28px;

    border:2px solid var(--q-line);
    border-radius:26px;

    background:var(--q-panel-solid);

    box-shadow:0 20px 60px rgba(0,0,0,.32);
}

.info-popup-close{
    position:absolute;

    top:12px;
    right:15px;

    border:0;
    background:transparent;

    color:var(--q-muted);

    font-size:24px;

    cursor:pointer;
}

.info-popup-icon{
    color:var(--q-gold);

    font-size:19px;

    text-align:center;
}

.info-popup-title{
    margin-top:12px;

    color:var(--q-text);

    font-size:13px;
    letter-spacing:1px;

    text-align:center;
}

.info-popup-main{
    margin:18px 0 22px;

    color:var(--q-muted);

    font-size:7px;
    line-height:2;

    text-align:center;
}

.howto-block{
    margin-top:10px;
    padding:14px;

    display:grid;
    grid-template-columns:35px 1fr;
    gap:12px;
    align-items:flex-start;

    border:1px solid var(--q-line);
    border-radius:15px;

    background:rgba(255,255,255,.018);
}

.howto-number{
    color:var(--q-gold);

    font-size:7px;
    line-height:1.8;
}

.howto-block p{
    margin:0;

    color:var(--q-muted);

    font-size:6.5px;
    line-height:2;
}

.howto-block strong{
    color:var(--q-text);
}

.howto-stages{
    margin-top:11px;

    display:flex;
    flex-wrap:wrap;
    gap:6px;
}

.howto-stages span{
    padding:7px 8px;

    border:1px solid var(--q-line-strong);
    border-radius:999px;

    color:var(--q-text);

    font-size:5px;
}

.info-popup-ok{
    width:100%;
    min-height:54px;

    margin-top:18px;

    border:2px solid var(--q-gold);
    border-radius:15px;

    background:var(--q-gold);
    color:#292f38;

    font-family:var(--font);
    font-size:8px;

    cursor:pointer;
}


/* =========================================================
   LEAVE CONFIRM
   ========================================================= */

.confirm-popup-card{
    position:relative;
    z-index:2;

    width:100%;
    max-width:390px;

    padding:27px 24px;

    border:2px solid var(--q-line);
    border-radius:24px;

    background:var(--q-panel-solid);

    text-align:center;
}

.confirm-popup-icon{
    color:var(--q-red);

    font-size:25px;
}

.confirm-popup-title{
    margin-top:14px;

    color:var(--q-text);

    font-size:10px;
}

.confirm-popup-card p{
    margin:17px 0 22px;

    color:var(--q-muted);

    font-size:6px;
    line-height:2;
}

.confirm-popup-buttons{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:9px;
}

.confirm-popup-buttons button{
    min-height:50px;

    border:2px solid var(--q-line);
    border-radius:14px;

    background:var(--q-panel);
    color:var(--q-text);

    font-family:var(--font);
    font-size:6px;

    cursor:pointer;
}

.confirm-popup-buttons .danger{
    border-color:rgba(231,111,81,.45);

    background:rgba(231,111,81,.10);
    color:var(--q-red);
}


/* =========================================================
   MOBILE
   ========================================================= */

@media(max-width:600px){

    .screen{
        padding:105px 18px 42px;
    }

    .game-logo{
        margin:39px 0 42px;
    }

    .game-logo-main{
        font-size:clamp(47px,15vw,64px);
    }

    .game-logo-sub{
        margin-top:22px;

        font-size:clamp(10px,4vw,14px);
        letter-spacing:5px;
    }

    .home-fact{
        padding:22px 8px;
    }

    .home-fact-label{
        font-size:7px;
    }

    .home-fact-text{
        margin-top:15px;

        font-size:7.5px;
        line-height:1.95;
    }

    .home-fact-text strong{
        font-size:10px;
    }

    .home-fact-sub{
        margin-top:10px;

        font-size:6.2px;
        line-height:1.9;
    }

    .home-playable-text{
        margin-top:16px;

        font-size:7px;
        line-height:1.95;
    }

    .home-playable-text #home-total-songs{
        font-size:10px;
    }

    .home-brief{
        margin-top:27px;
    }

    .home-brief-main{
        font-size:7px;
        line-height:1.95;
    }

    .home-brief-sub{
        margin-top:10px;

        font-size:6.3px;
        line-height:1.9;
    }

    .home-stage-title{
        margin-top:20px;

        font-size:5.5px;
    }

    .start-stages{
        margin-top:11px;

        gap:6px;
    }

    .start-stages span{
        min-width:60px;

        padding:8px;

        font-size:5.5px;
    }

    .home-start-btn{
        margin-top:28px;
    }

    .home-info-btn{
        margin-top:17px;

        font-size:6px;
    }

    .filter-title{
        margin-top:55px;

        font-size:20px;
    }

    .filter-check{
        min-height:75px;

        padding:0 20px;

        grid-template-columns:44px 1fr auto;
    }

    .screen-quiz{
        padding-top:125px;
    }

    .stage-track{
        gap:5px;
    }

    .stage-box{
        height:61px;

        border-radius:15px;
    }

    .quiz-reveal{
        padding:5px;
    }

    .reveal-card{
        max-height:98vh;

        padding:12px 15px 14px;

        border-radius:22px;
    }

    .reveal-status{
        font-size:25px;
    }

    .reveal-cover-small{
        width:94px;
        height:94px;
    }

    .reveal-song-title{
        margin-top:8px;

        font-size:10px;
    }

    .reveal-player-name{
        margin-top:4px;

        font-size:5px;
    }

    .reveal-trisha-row{
        margin-top:8px;

        grid-template-columns:60px 1fr;
        gap:8px;
    }

    .reveal-trisha-img{
        width:60px;
        height:60px;
    }

    .reveal-message{
        min-height:56px;

        padding:9px 11px;

        font-size:6px;
        line-height:1.7;
    }

    .reveal-player{
        margin-top:8px;

        gap:8px;
    }

    .btn-reveal-play{
        min-width:136px;
        min-height:42px;

        font-size:5.5px;
    }

    .reveal-player .audio-wave{
        width:66px;
        height:30px;
    }

    .reveal-divider{
        margin:7px 0;
    }

    .reveal-stats{
        margin-top:6px;

        gap:2px;
    }

    .stat-row{
        min-height:25px;

        grid-template-columns:42px 1fr 34px;
        gap:6px;

        padding:2px 4px;
    }

    .stat-label,
    .stat-pct{
        font-size:5.5px;
    }

    .stat-bar-bg{
        height:12px;
    }

    .reveal-stats-note{
        margin-top:6px;

        font-size:5.5px;
    }

    .reveal-game-link{
        margin-top:3px;

        font-size:5.5px;
    }

    .reveal-buttons{
        margin-top:9px;

        gap:6px;
    }

    .btn-reveal-download{
        min-height:44px;
    }

    .btn-reveal-next{
        min-height:50px;
    }

    .info-popup-card{
        padding:24px 17px 20px;
    }

    .info-popup-title{
        font-size:11px;
    }

    .info-popup-main{
        font-size:6.5px;
    }

    .howto-block{
        padding:12px;

        grid-template-columns:29px 1fr;
        gap:9px;
    }

    .howto-number{
        font-size:6px;
    }

    .howto-block p{
        font-size:6px;
        line-height:1.9;
    }

    .howto-stages span{
        font-size:4.7px;
    }

    /* RESULT MOBILE COMPACT */

    .result-title{
        margin:6px 0 16px;
        font-size:18px;
    }

    .result-trisha-wrap{
        grid-template-columns:82px 1fr;
        gap:10px;
    }

    .result-trisha-img{
        width:82px;
        height:82px;
        border-radius:14px;
    }

    .result-trisha-caption{
        min-height:68px;
        padding:10px 12px;
        border-radius:15px;
        font-size:5.8px;
        line-height:1.7;
    }

    .result-summary{
        margin-top:12px;
        padding:11px 13px;
        gap:6px;
        border-radius:14px;
        font-size:5.8px;
    }

    .result-progress-wrap{
        margin-top:10px;
    }

    .result-progress-head{
        font-size:5px;
    }

    .result-progress-bar{
        height:7px;
        margin-top:5px;
    }

    .result-table{
        margin-top:13px;
        gap:6px;
    }

    .result-row{
        min-height:47px;
        padding:8px 11px;

        grid-template-columns:24px 1fr 52px;
        gap:6px;

        border-radius:14px;
    }

    .result-num{
        font-size:5px;
    }

    .result-song-name{
        font-size:5.7px;
        line-height:1.45;
    }

    .result-stage{
        font-size:5px;
    }

    .result-actions{
        margin-top:13px;
        grid-template-columns:120px 1fr;
        gap:8px;
    }

    .btn-download{
        min-height:48px;
        font-size:5.7px;
    }

    .result-replay{
        min-height:48px;
        padding:11px 12px;
        font-size:8px;
    }

    .result-replay span{
        margin-right:7px;
        font-size:6px;
    }

    .result-game-link{
        margin-top:10px;
        font-size:5px;
    }
}


@media(max-width:390px){

    .quiz-nav{
        padding:0 14px;
    }

    .quiz-nav-title{
        font-size:9px;
    }

    .quiz-nav-back span{
        display:none;
    }

    .quiz-menu-btn{
        width:42px;
        height:42px;
    }

    .game-logo-main{
        font-size:50px;
    }

    .game-logo-sub{
        font-size:9px;
        letter-spacing:4px;
    }

    .home-fact-text{
        font-size:7px;
    }

    .home-fact-sub{
        font-size:5.8px;
    }

    .home-playable-text{
        font-size:6.5px;
    }

    .home-brief-main{
        font-size:6.5px;
    }

    .home-brief-sub{
        font-size:5.9px;
    }

    .start-stages span{
        min-width:56px;

        font-size:5px;
    }

    .quiz-trisha{
        grid-template-columns:72px 1fr;
    }

    .quiz-trisha-img{
        width:72px;
        height:72px;
    }

    .quiz-input-wrap{
        grid-template-columns:1fr 60px;
    }

    .quiz-input,
    .btn-submit{
        height:64px;
    }

    .reveal-card{
        padding:11px 12px 13px;
    }

    .reveal-cover-small{
        width:88px;
        height:88px;
    }

    .reveal-song-title{
        font-size:9px;
    }

    .reveal-player-name{
        font-size:4.8px;
    }

    .reveal-trisha-row{
        grid-template-columns:56px 1fr;
    }

    .reveal-trisha-img{
        width:56px;
        height:56px;
    }

    .reveal-message{
        min-height:52px;

        font-size:5.5px;
    }

    .btn-reveal-play{
        min-width:128px;
    }

    .reveal-player .audio-wave{
        width:60px;

        gap:3px;
    }

    .stat-row{
        grid-template-columns:40px 1fr 33px;
    }

    .stat-label,
    .stat-pct{
        font-size:5.2px;
    }
    .result-title{
        font-size:16px;
    }

    .result-trisha-wrap{
        grid-template-columns:72px 1fr;
    }

    .result-trisha-img{
        width:72px;
        height:72px;
    }

    .result-trisha-caption{
        min-height:60px;
        font-size:5.3px;
    }

    .result-summary{
        font-size:5.3px;
    }

    .result-row{
        min-height:43px;
        grid-template-columns:21px 1fr 48px;
    }

    .result-song-name{
        font-size:5.2px;
    }

    .result-actions{
        grid-template-columns:105px 1fr;
    }

    .btn-download{
        font-size:5.2px;
    }

    .result-replay{
        font-size:7.2px;
    }

}

/* Container pembungkus Input + Tombol Enter */
.quiz-input-wrap, 
.search-wrapper,
div:has(> #quiz-input) {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
}

/* Kotak Input Tebak Lagu */
#quiz-input,
.quiz-input {
    font-size: 16px !important; /* Wajib 16px agar Safari/Chrome tidak auto-zoom */
    transform: scale(0.85) !important; /* Kecilkan visual font piksel sebesar 15% */
    transform-origin: left center !important; /* Kunci titik susut dari kiri agar tetap sejajar */
    width: 117% !important; /* Kompensasi lebar akibat efek scale */
    margin-right: -15% !important; /* Kompensasi margin agar tidak mendorong tombol enter */
    
    padding: 10px 14px !important;
    height: 46px !important;
    line-height: 1.2 !important;
    box-sizing: border-box !important;
    
    border-radius: 14px !important;
    -webkit-text-size-adjust: 100% !important;
}

/* Tombol Submit / Enter (Panah ↵) di Sebelah Kanan Input */
#btn-submit,
.btn-submit,
button:has(> .fa-arrow-right),
#quiz-input + button {
    height: 46px !important; /* Samakan tinggi persis dengan kotak input */
    min-width: 46px !important;
    padding: 0 12px !important;
    
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    
    border-radius: 14px !important;
    flex-shrink: 0 !important; /* Cegah tombol gepeng/tertekan */
}