/* Update51 — additive UI. Maintains Update50 original brand design. */
.al51-search-wrap{position:relative;min-width:0}.al51-search-wrap>input{width:100%;height:100%}.al51-search-suggest{position:absolute;top:calc(100% + 6px);left:0;right:0;z-index:86;max-height:340px;overflow:auto;background:#1c1429;border:1px solid #8b5cf666;border-radius:15px;box-shadow:0 16px 34px #0009;padding:5px}.al51-search-suggest[hidden]{display:none}.al51-search-row{display:flex;align-items:center;gap:10px;width:100%;border:0;border-bottom:1px solid #ffffff1a;background:transparent;color:white;text-align:start;padding:8px;border-radius:8px}.al51-search-row:hover,.al51-search-row:focus{background:#8b5cf626}.al51-search-row img{width:36px;height:50px;object-fit:cover;border-radius:6px}.al51-search-row span:nth-child(2){display:grid;gap:4px;flex:1}.al51-search-row small{font-size:11px;color:#baaac9}.al51-search-no{padding:15px;color:#d6c7e1;font-size:13px}
.al51-theme-btn,.al51-settings-btn{flex:0 0 40px}
.al51-dialog[hidden]{display:none!important}.al51-dialog{position:fixed;inset:0;z-index:150;display:grid;place-items:center;padding:16px}.al51-shade{position:absolute;inset:0;background:#08050fd9;backdrop-filter:blur(5px)}.al51-dialog-card{position:relative;width:min(460px,95vw);background:#1b1427;border:1px solid #8b5cf66b;box-shadow:0 25px 80px #000b;border-radius:20px;padding:22px;color:#fff;display:grid;gap:15px}.al51-dialog-card h2{margin:5px 0}.al51-dialog-card p,.al51-dialog-card small{color:#c5b6d2}.al51-dialog-card label{display:grid;gap:6px}.al51-dialog-card select{padding:12px;background:#0f0919;border:1px solid #ffffff30;color:#fff;border-radius:10px}.al51-check{display:flex!important;flex-direction:row;align-items:flex-start;gap:9px}.al51-check input{width:18px;height:18px;flex:0 0 auto}.al51-main{padding:12px;border:0;border-radius:10px;background:#8852dc;color:#fff;font-weight:800}.al51-x{position:absolute;left:14px;top:12px;border:0;background:transparent;color:#fff;font-size:26px}
.al51-reviews{margin:22px 0;border-radius:20px;padding:18px;background:linear-gradient(145deg,#26172e,#120d1d);border:1px solid #8853b65e;color:#f9f3ff}.al51-reviews h3{margin-top:0}.al51-rating{display:flex;align-items:center;gap:15px;flex-wrap:wrap}.al51-stars{display:flex;gap:4px}.al51-stars button{border:0;background:none;color:#ffca63;font-size:29px;line-height:1;min-width:34px}.al51-reviews label{display:grid;gap:7px;font-size:13px}.al51-reviews form{display:grid;gap:11px;margin-top:18px}.al51-reviews input,.al51-reviews textarea,.al51-reviews select{width:100%;padding:11px;border:1px solid #ffffff32;border-radius:10px;background:#10091b;color:#fff}.al51-comment-actions,.al51-sort{display:flex;justify-content:space-between;align-items:center;gap:12px}.al51-comment-actions button,.al51-admin button,.al51-reviews button[type=submit],#al51MoreComments{background:#8153cc;border:0;border-radius:9px;padding:9px 13px;color:#fff;font-weight:700}.al51-comment-actions small,.al51-muted{font-size:12px;color:#b3a3c4}.al51-comment{border-top:1px solid #ffffff2b;padding:12px 0;margin-top:8px}.al51-comment small{display:block;color:#ab9fba;margin:5px 0}.al51-comment p{overflow-wrap:anywhere;white-space:pre-wrap;line-height:1.6}.al51-comment div{display:flex;gap:6px}.al51-comment button{background:#ffffff12;border:1px solid #ffffff28;color:#ded4e4;padding:6px 12px;border-radius:8px}.al51-next-box{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:10px 0;padding:13px;border:1px solid #9962ed;border-radius:14px;background:#241331;color:#fff}.al51-next-box[hidden]{display:none}.al51-next-box strong{margin-inline-end:10px}.al51-next-box button{border-radius:10px;padding:10px;color:#fff;border:1px solid #ffffff35;background:#5c3679}
.al51-admin{max-width:1200px;margin:25px auto;padding:20px!important;color:#f8f1ff;background:linear-gradient(160deg,#1c1229,#0d0914);border:1px solid #915bc06b;border-radius:22px}.al51-admin[hidden]{display:none}.al51-studio-open{margin:15px 0;background:#763abe;border:1px solid #9864d6;color:#fff;border-radius:13px;padding:12px 17px;font-weight:bold}.al51-admin-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.al51-admin-head h2{margin:7px 0}.al51-admin-head p,.al51-admin p{color:#c1b5d0;line-height:1.7}.al51-tabs{display:flex;gap:7px;flex-wrap:wrap;margin:14px 0}.al51-admin button{cursor:pointer}.al51-tabs button{background:#ffffff10;border:1px solid #ffffff26}.al51-tabs button.active{background:#8153cc}.al51-admin input:not([type=checkbox]),.al51-admin select,.al51-admin textarea{width:100%;border:1px solid #ffffff29;border-radius:10px;padding:10px;background:#10091b;color:#fff;display:block;margin:5px 0 12px}.al51-admin label{display:block;line-height:1.6;margin-top:10px}.al51-admin-list{display:grid;gap:12px;max-height:600px;overflow:auto}.al51-admin-row{padding:13px;border-radius:13px;border:1px solid #ffffff28;background:#ffffff07}.al51-admin-row small{display:block;color:#b6a1c6;margin-top:5px}.al51-admin-row p{margin:8px 0;word-break:break-word}.al51-admin-row div{display:flex;gap:8px;flex-wrap:wrap}.al51-admin-row div button{padding:8px 10px}.al51-two{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.al51-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:12px 0}.al51-stats div{border:1px solid #ffffff24;background:#ffffff0b;padding:12px;border-radius:12px;display:grid;gap:8px}.al51-stats strong{font-size:24px}.al51-stats span{font-size:12px;color:#c4b6d0}.al51-backup-reminder{padding:14px;background:#3c2555;border:1px solid #b185eb;border-radius:12px;color:#fff}.al51-backup-reminder button{margin-inline-start:10px;padding:8px;border-radius:8px}.al51-admin pre{white-space:pre-wrap;overflow-wrap:anywhere;font-size:11px}
/* Soft lavender light theme. Player stays dark in all modes. */
html.al51-light{--bg:#eeebf4;--panel:#ffffff;--txt:#2e2341;--mut:#6c627b;--line:#4a2f6a25}
html.al51-light body{background:linear-gradient(150deg,#f4f0f8,#e7e0f2);color:#302543}
html.al51-light header{background:#f7f3faee;color:#302543;border-bottom-color:#7857a434}
html.al51-light header .brand,html.al51-light header .icon,html.al51-light .nav button{color:#342644}
html.al51-light .nav button.active,html.al51-light .nav button:hover{background:#d9c6ef65;color:#492a69}
html.al51-light .card,html.al51-light .studio-card{background:#fff;color:#2e2341;box-shadow:0 10px 35px #5a3f7130}
html.al51-light .section-head h2,html.al51-light .title,html.al51-light .section h2{color:#3c2954}
html.al51-light .search input,html.al51-light #browseInput{background:#fff;color:#2e2341;border-color:#8b5cf638}
html.al51-light #browse .chip,html.al51-light #genres .genre{background:#ffffffdd;color:#38284c}
html.al51-light .panel:not(#playerModal .panel){background:#faf7fd;color:#2e2341}
html.al51-light .sub,html.al51-light .meta,html.al51-light .tag{color:#5c5070}
html.al51-light #home .hero,html.al51-light #home .hero *:not(button){color:#fff}
html.al51-light #playerModal,html.al51-light #playerModal *{--bg:#08050f;--panel:#151021;--txt:#fff;--line:#ffffff28;color:revert-layer}
html.al51-light #playerModal{color:#fff;background:#08050f}html.al51-light #playerModal button{color:#fff}
html.al51-light .al51-reviews,html.al51-light .al51-admin{color:#f9f3ff}
@media(max-width:680px){.al51-reviews{padding:12px;margin:12px 0}.al51-admin{padding:13px!important}.al51-stats{grid-template-columns:repeat(2,1fr)}.al51-admin-head{align-items:flex-start}.al51-admin-head h2{font-size:21px}.al51-two{grid-template-columns:1fr}.al51-next-box{flex-wrap:wrap}.al51-search-row img{width:30px;height:42px}.al51-theme-btn,.al51-settings-btn{width:34px;height:37px;flex-basis:34px}}

/* Some older redesign sheets used fixed dark page/header colors. Explicitly
   lift those surfaces in light mode; keep hero and video cinematic and dark. */
html.al51-light .page{background:#f0ebf5!important;color:#342342}
html.al51-light header{background:#f7f3fbed!important;color:#31233e!important;border-bottom:1px solid #8c6cb74a!important}
html.al51-light .section:not(.al51-admin),html.al51-light #browse,html.al51-light #genres,html.al51-light #schedule,html.al51-light #mylist{color:#342342}
html.al51-light .card,html.al51-light .al47-follow-card,html.al51-light .al47-home-link,html.al51-light .al45-group,html.al51-light .studio-card{background:#fff!important;color:#38294a!important;box-shadow:0 10px 25px #57456a22!important}
html.al51-light .section-head p,html.al51-light .al47-muted,html.al51-light #browse .sub{color:#675874!important}
html.al51-light .nav button,html.al51-light header .brand,html.al51-light header .icon{color:#392b4d!important}
html.al51-light #home .hero{color:#fff;background:linear-gradient(90deg,#08050ff5,#08050fc4 46%,#08050f42 75%,#08050fc7)!important}
html.al51-light #playerModal{background:#08050f!important;color:#fff!important}

#searchModal.al51-show-suggestions #results{display:none!important}
html.al51-light #modalInput{background:#fff!important;color:#342342!important;border-color:#9b7cbe55!important}


/* Update51.1 hotfix: keep original hamburger visible on narrow phones.
   New Update51 theme/settings controls are reachable inside the existing drawer. */
.al51-mobile-side-actions{display:none}
@media (max-width:720px){
  body.al-cinema header{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:7px!important;padding:9px 11px!important;box-sizing:border-box!important;min-width:0!important;width:100%!important}
  body.al-cinema header .brand-wrap{flex:1 1 auto;min-width:0;overflow:hidden}
  body.al-cinema header .brand{min-width:0;max-width:100%;gap:7px!important}
  body.al-cinema header .brandmark{width:36px!important;height:36px!important;flex:0 0 36px!important}
  body.al-cinema header .brand strong{font-size:clamp(10px,3.2vw,14px)!important;letter-spacing:.035em!important;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  body.al-cinema header .actions{display:flex!important;flex:0 0 auto!important;align-items:center!important;margin-left:0!important;min-width:0!important;gap:6px!important}
  body.al-cinema header .actions .al51-theme-btn,
  body.al-cinema header .actions .al51-settings-btn{display:none!important}
  body.al-cinema header .al13-online-badge{flex:0 0 auto;min-width:0;padding:6px 7px!important;gap:4px!important}
  body.al-cinema header .al13-online-badge>span{display:none!important}
  body.al-cinema header .actions #searchBtn{width:32px!important;min-width:32px!important;flex:0 0 32px!important;margin:0!important}
  body.al-cinema header .actions .cin-menu-toggle{display:grid!important;flex:0 0 42px!important;min-width:42px!important;width:42px!important;order:99;margin:0!important}
  body.al-cinema .al51-mobile-side-actions{display:grid;gap:9px;margin:16px 0 0;padding:16px 3px 0;border-top:1px solid #ffffff22}
  body.al-cinema .al51-mobile-side-actions button{width:100%;min-height:44px;padding:12px 14px;border:1px solid #6c507b6b;border-radius:12px;background:#292036;color:#f7eaff;text-align:left;font-weight:750;cursor:pointer}
  html.al51-light body.al-cinema .al51-mobile-side-actions button{background:#efe5f5;color:#332243;border-color:#b69dc9}
}
@media (max-width:350px){
  body.al-cinema header .actions{gap:4px!important}
  body.al-cinema header .brand strong{font-size:10px!important;letter-spacing:0!important}
}
