/* Adam Ru Ngủ — ADAM-APP-0057 · theo HUONG-DAN-NHAN-DIEN-APP + TIEU-CHI-GIAO-DIEN */
:root,[data-theme="dodo-light"]{--bg:#f3f3f1;--surface:#fff;--surface2:#ecece9;--text:#2f3237;--muted:#6b7078;--line:#d8d8d4;--accent:#d71920;--accent-ink:#fff;--accent2:#3a3d42;--on:#fdecec;--f:"Be Vietnam Pro",system-ui,sans-serif;--fm:"JetBrains Mono",ui-monospace,monospace}
[data-theme="dodo-dark"]{--bg:#0d0d0e;--surface:#17171a;--surface2:#222226;--text:#ececec;--muted:#9a9aa0;--line:#2f2f34;--accent:#ff2b34;--accent-ink:#fff;--accent2:#f1f1f1;--on:#2a1416}
[data-theme="holo-light"]{--bg:#eaf4fa;--surface:rgba(255,255,255,.72);--surface2:rgba(0,150,199,.08);--text:#08293a;--muted:#4c7285;--line:rgba(0,140,190,.32);--accent:#0090c0;--accent-ink:#fff;--accent2:#c2189f;--on:rgba(0,144,192,.12);--f:"Exo 2",system-ui,sans-serif;--fm:"Orbitron",ui-monospace,monospace}
[data-theme="holo-dark"]{--bg:#040712;--surface:rgba(8,22,40,.62);--surface2:rgba(0,229,255,.07);--text:#d9f7ff;--muted:#79a9bd;--line:rgba(0,229,255,.28);--accent:#00e5ff;--accent-ink:#021018;--accent2:#ff3df2;--on:rgba(0,229,255,.12);--f:"Exo 2",system-ui,sans-serif;--fm:"Orbitron",ui-monospace,monospace}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--text);font:15px/1.5 var(--f);min-height:100vh;min-height:100dvh;display:flex;flex-direction:column}
[data-theme="holo-dark"] body{background:radial-gradient(1200px 600px at 70% -10%,rgba(0,229,255,.12),transparent),var(--bg)}
body>main{flex:1 0 auto;width:100%;max-width:1100px;margin:0 auto;padding:14px 16px 28px}
body>footer.foot{margin-top:auto}
button,select,input{font:inherit;color:inherit}
button{cursor:pointer}
.mono{font-family:var(--fm)}
.muted{color:var(--muted)}.small{font-size:13px}
a{color:var(--accent)}
[hidden]{display:none!important}

/* header */
.top{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:10px 16px;border-bottom:1px solid var(--line);background:var(--surface);position:sticky;top:0;z-index:20;backdrop-filter:blur(8px)}
.brand{display:flex;align-items:center;gap:10px;font-weight:700;font-size:18px;letter-spacing:-.01em;white-space:nowrap;margin:0}
.logo{width:30px;height:30px;border-radius:9px;background:var(--accent);color:var(--accent-ink);display:grid;place-items:center}
[data-theme^="holo"] .logo{box-shadow:0 0 16px color-mix(in srgb,var(--accent) 60%,transparent)}
.brand-by{display:flex;flex-direction:column;line-height:1.2;padding-left:12px;border-left:2px solid var(--line)}
.brand-by b{font-size:13px;font-weight:600;color:var(--text)}
.brand-by small{font-size:11.5px;font-weight:600;color:var(--accent);text-transform:uppercase;letter-spacing:.06em}
.right{margin-left:auto;display:flex;align-items:center;gap:8px}
.swatches{display:flex;gap:4px;padding:4px;border:1px solid var(--line);border-radius:999px;background:var(--surface)}
.sw{width:24px;height:24px;border-radius:999px;border:2px solid transparent;padding:0}
.sw[data-t="dd-light"]{background:linear-gradient(135deg,#fff 50%,#d7141f 50%)}
.sw[data-t="dd-dark"]{background:linear-gradient(135deg,#111 50%,#ff2d3a 50%)}
.sw[data-t="holo-light"]{background:linear-gradient(135deg,#e6f6ff 45%,#0091c2 45%,#0091c2 72%,#8a2be2 72%)}
.sw[data-t="holo-dark"]{background:linear-gradient(135deg,#04060d 45%,#2ef2ff 45%,#2ef2ff 72%,#ff4df5 72%)}
.sw[aria-checked="true"]{border-color:var(--text)}
.hbtn{height:38px;border-radius:11px;font-size:13.5px;font-weight:600;padding:0 12px;display:inline-flex;align-items:center;gap:4px;border:1px solid var(--line);background:var(--surface);color:var(--text);text-decoration:none;white-space:nowrap}
.hbtn.signup{background:#e11d2e;border-color:#e11d2e;color:#fff;text-shadow:0 1px 1px rgba(0,0,0,.2)}
.hbtn.signup:hover{filter:brightness(1.08)}
[data-theme^="holo"] .hbtn.signup{box-shadow:0 0 14px rgba(225,29,46,.5)}
.s-short{display:none}
.icon-btn{width:38px;height:38px;border-radius:11px;border:1px solid var(--line);background:var(--surface);font-size:17px;display:grid;place-items:center;padding:0}
.icon-btn:hover,.hbtn:not(.signup):hover{border-color:var(--accent)}
.pop-wrap{position:relative}
.pop{position:absolute;right:0;top:46px;width:250px;background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:14px;box-shadow:0 12px 34px rgba(0,0,0,.18);z-index:40;text-align:center;font-size:13.5px}
[data-theme$="dark"] .pop{background:#1b1b1f}
.pop p{margin:6px 0 10px;color:var(--muted)}
.pop img{border-radius:10px;cursor:zoom-in;max-width:100%}
.lnk{border:0;background:none;color:var(--accent);font-weight:600;padding:0;font-size:13.5px}

/* hint */
.hint{display:flex;align-items:flex-start;gap:8px;background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:8px 12px;margin-bottom:14px;font-size:14px}
.hint .x{margin-left:auto;border:0;background:none;color:var(--muted);font-size:15px}

/* player */
.player{display:flex;align-items:center;gap:16px;flex-wrap:wrap;background:var(--surface);border:1px solid var(--line);border-radius:18px;padding:14px 16px;min-height:88px}
.big-play{width:60px;height:60px;border-radius:999px;border:0;background:var(--accent);color:var(--accent-ink);font-size:24px;flex:0 0 auto;transition:transform .12s}
.big-play:active{transform:scale(.94)}
[data-theme^="holo"] .big-play{box-shadow:0 0 22px color-mix(in srgb,var(--accent) 55%,transparent)}
.pl-mid{flex:1 1 220px;min-width:0}
.now{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-height:22px}
.mvol{display:flex;align-items:center;gap:8px;color:var(--muted);margin-top:6px}
.mvol input{flex:1}
.timer{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.timer label{color:var(--muted);font-size:14px}
select{height:36px;border-radius:10px;border:1px solid var(--line);background:var(--surface);padding:0 8px}
.timer .left{min-width:58px;color:var(--accent);font-weight:600}
input[type=range]{accent-color:var(--accent);height:22px}

.sec{font-size:15px;font-weight:600;margin:22px 0 10px;color:var(--text)}
.sec small{font-weight:400;color:var(--muted);font-size:13px;margin-left:6px}
.presets{display:flex;gap:8px;flex-wrap:wrap}
.pre{border:1px solid var(--line);background:var(--surface);border-radius:999px;padding:7px 14px;font-size:14px;transition:border-color .15s,background .15s}
.pre:hover{border-color:var(--accent)}
.pre.on{background:var(--on);border-color:var(--accent);color:var(--text)}

.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(205px,1fr));gap:10px}
.card{position:relative;background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:12px 12px 10px;transition:border-color .15s,background .15s,box-shadow .15s;cursor:pointer;user-select:none;min-height:122px}
.card:hover{border-color:color-mix(in srgb,var(--accent) 55%,var(--line))}
.card.on{border-color:var(--accent);background:var(--on)}
[data-theme^="holo"] .card.on{box-shadow:0 0 18px color-mix(in srgb,var(--accent) 30%,transparent)}
.c-top{display:flex;align-items:center;gap:10px}
.c-emo{font-size:28px;line-height:1;width:40px;height:40px;display:grid;place-items:center;border-radius:12px;background:var(--surface2)}
.c-name{font-weight:600}
.c-sub{font-size:12.5px;color:var(--muted)}
.c-state{margin-left:auto;width:12px;height:12px;border-radius:99px;border:2px solid var(--line)}
.card.on .c-state{background:var(--accent);border-color:var(--accent)}
.card.load .c-state{border-color:var(--accent);border-top-color:transparent;animation:sp .8s linear infinite}
@keyframes sp{to{transform:rotate(360deg)}}
.c-vol{display:flex;align-items:center;gap:6px;margin-top:10px;color:var(--muted);font-size:13px}
.c-vol input{flex:1;min-width:0}
.c-var{display:flex;gap:4px;margin-top:8px;flex-wrap:wrap;min-height:24px}
.c-var button{border:1px solid var(--line);background:transparent;border-radius:8px;font-size:12px;padding:1px 8px;color:var(--muted)}
.c-var button.sel{border-color:var(--accent);color:var(--accent);font-weight:600}
.c-dev{font-size:11px;color:var(--muted);margin-top:4px;word-break:break-all}
.note{color:var(--muted);font-size:13.5px;margin:10px 2px 0}

/* footer */
.foot{display:flex;justify-content:center;flex-wrap:wrap;gap:8px 16px;font-size:13px;color:var(--muted);align-items:center;padding:16px;border-top:1px solid var(--line)}
.foot b{color:var(--text);font-weight:600}
.foot button{border:0;background:none;padding:0;color:var(--muted);text-decoration:underline;font-size:13px}
.foot button:hover,.foot a.lk:hover{color:var(--accent)}
.foot .don{color:var(--accent);font-weight:600;text-decoration:none}
.foot a.lk{color:var(--text);font-weight:600;text-decoration:none;border-bottom:1px solid var(--line)}
.foot .sep{width:1px;height:14px;background:var(--line)}
.ft-signup{color:#e11d2e;font-weight:600;text-decoration:none}

/* dialogs */
.dlg{position:fixed;inset:0;background:rgba(10,12,16,.45);z-index:60;display:grid;place-items:center;padding:16px;animation:fi .15s}
@keyframes fi{from{opacity:0}}
.dlg-box{background:var(--surface);border:1px solid var(--line);border-radius:16px;width:min(760px,100%);max-height:calc(100dvh - 32px);display:flex;flex-direction:column;box-shadow:0 24px 60px rgba(0,0,0,.25);position:relative}
[data-theme$="dark"] .dlg-box{background:#17171a}
[data-theme="holo-dark"] .dlg-box{background:#071527}
[data-theme="holo-light"] .dlg-box{background:#f6fbfe}
.dlg-box.sm{width:min(420px,100%)}
.dlg-bar{display:flex;align-items:center;gap:6px;padding:10px 12px 10px 16px;border-bottom:1px solid var(--line);cursor:move;touch-action:none;user-select:none}
.dlg-bar .sp{flex:1}
.dlg-bar button{border:0;background:none;color:var(--muted);width:30px;height:30px;border-radius:8px;font-size:15px}
.dlg-bar button:hover{background:var(--surface2);color:var(--text)}
.dlg-body{padding:16px;overflow:auto}
.dlg.mini{background:transparent;pointer-events:none;place-items:end start}
.dlg.mini .dlg-box{pointer-events:auto;width:260px}
.dlg.mini .dlg-body{display:none}
.center{text-align:center}
.qr{max-width:300px;width:100%;border-radius:12px;box-shadow:0 6px 18px rgba(0,0,0,.12)}
.acct{background:var(--surface2);border-radius:12px;padding:10px;margin:12px 0}
.acct small{color:var(--muted)}
.num{font-size:22px;font-weight:600;margin:4px 0;letter-spacing:.04em}
.btn{border:1px solid var(--line);background:var(--surface);border-radius:10px;padding:7px 14px;font-size:14px;text-decoration:none;color:var(--text);display:inline-flex;align-items:center;gap:4px}
.btn:hover{border-color:var(--accent)}
.btn.primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink);font-weight:600}
.row{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}
.row-c{display:flex;gap:8px;justify-content:center;flex-wrap:wrap;margin-top:14px}
.lbl{font-weight:600;margin:14px 0 6px}.lbl:first-child{margin-top:0}
.theme-list{display:grid;gap:6px}
.chk{display:flex;gap:8px;align-items:center;margin:4px 0}
.hero{display:flex;gap:14px;align-items:center}
.hero-logo{font-size:40px;width:72px;height:72px;border-radius:20px;background:linear-gradient(135deg,#0f1a2b,#28426b);display:grid;place-items:center;flex:0 0 auto}
.hero h3{margin:0 0 4px;font-size:18px}
.author{display:flex;gap:14px;margin:18px 0;padding:14px;border:1px solid var(--line);border-radius:14px}
.av{width:88px;height:88px;border-radius:999px;background:var(--accent);color:var(--accent-ink);display:grid;place-items:center;font-weight:700;font-size:26px;flex:0 0 auto}
.author h4{margin:0;font-size:20px}
.role{color:var(--accent);font-size:13.5px;font-weight:600;margin:2px 0 6px}
.author p{margin:4px 0}
.dlg-body h4{margin:18px 0 8px}
.feats{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:8px}
.feats div{border:1px solid var(--line);border-radius:12px;padding:10px;display:flex;flex-direction:column;gap:2px;font-size:13.5px}
.feats span{color:var(--muted)}
.steps{counter-reset:s;list-style:none;padding:0;margin:0;display:grid;gap:8px}
.steps li{counter-increment:s;display:flex;gap:10px;align-items:center}
.steps li::before{content:counter(s);width:26px;height:26px;border-radius:99px;background:var(--accent);color:var(--accent-ink);display:grid;place-items:center;font-weight:600;flex:0 0 auto;font-size:13px}
.tips{margin:0;padding-left:20px;color:var(--text)}
.support{border:2px solid var(--accent);border-radius:14px;padding:12px;margin-top:18px}
.support h4{margin-top:0}
.sup-row{display:flex;gap:14px;align-items:center;flex-wrap:wrap}
.sup-row img{border-radius:10px}
.credits{padding-left:18px;font-size:13px;margin:0;display:grid;gap:3px}
.credits a{color:var(--text)}
.credits .lic{color:var(--muted)}
.meta{display:flex;flex-direction:column;gap:2px;margin-top:16px;padding-top:12px;border-top:1px solid var(--line);font-size:13px;color:var(--muted)}
.meta b{color:var(--text);font-weight:600}

/* night */
.night{position:fixed;inset:0;background:#000;z-index:90;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;cursor:pointer;color:#5a5f6a}
.n-clock{font-size:min(22vw,120px);font-weight:500;color:#3d424c;letter-spacing:.02em}
.n-sub{font-size:15px;color:#454a54;min-height:22px}
.n-hint{position:absolute;bottom:28px;font-size:12px;color:#2c3038}

.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:#2f3237;color:#fff;padding:9px 16px;border-radius:10px;z-index:99;font-size:14px;box-shadow:0 8px 24px rgba(0,0,0,.25)}

@media (max-width:860px){.s-long{display:none}.s-short{display:inline}.brand-by{display:none}}
@media (max-width:640px){.player{gap:12px}.timer{width:100%}}
@media (max-width:600px){.swatches{display:none}.top{padding:8px 12px}body>main{padding:12px 12px 24px}.grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.card{padding:10px 10px 8px;min-height:112px}.c-emo{font-size:22px;width:34px;height:34px}.c-name{font-size:14px}}
@media (max-width:480px){.author{flex-direction:column;align-items:center;text-align:center}.author .row{justify-content:center}.hero{flex-direction:column;text-align:center}}
@media (max-width:420px){.hbtn,.icon-btn{height:34px}.icon-btn{width:34px}.right{gap:5px}.brand{font-size:16px}.app-name{font-size:16px}.c-sub{display:none}}
@media (max-width:360px){.grid{grid-template-columns:1fr 1fr}}
