/* "Midnight" theme (2026-11-23) after Musemind's fantasy-sports app: deep midnight navy with a blue
   glow, glassy cards edged in a thin luminous blue line, royal-blue gradient hero tiles, gold accents,
   bold italic headings (Poppins), pill chips. Applies when <html data-theme="midnight">; Settings → Design. */
html[data-theme="midnight"]{
  --bg:#070d24; --bg2:#0b1433; --panel:rgba(17,27,66,.82); --panel2:rgba(20,32,80,.6); --line:rgba(96,128,255,.16); --line2:rgba(96,128,255,.34);
  --text:#eef2ff; --mute:#94a0c9; --dim:#5d6894;
  --royal:#2f5bff; --royal2:#1b2f9e; --gold:#f5c518;
  --acc:var(--gold); --acc2:#e0b000; --acc-text:var(--gold); --ink:#070d24;
  --dark:var(--royal); --dark2:#244ae0; --on-dark:#fff; --on-dark-mute:rgba(255,255,255,.72);
  --good:#3ddc84; --mid:var(--gold); --bad:#ff5c7a; --blue:#6f9bff; --pitch:#123b2a; --pitch2:#164532;
  --head:"Poppins",system-ui,sans-serif; --body:"Poppins",system-ui,sans-serif;
  --r:22px; --r-sm:14px;
  --edge:0 0 0 1px rgba(96,128,255,.32),inset 0 1px 0 rgba(255,255,255,.06);
  --shadow:var(--edge),0 18px 40px -22px rgba(47,91,255,.55);
}
html[data-theme="midnight"] body{background:
  radial-gradient(90% 60% at 85% -10%,rgba(47,91,255,.35),transparent 60%),
  radial-gradient(70% 50% at -10% 110%,rgba(47,91,255,.22),transparent 60%),var(--bg);background-attachment:fixed}
html[data-theme="midnight"] .top{background:rgba(7,13,36,.82);box-shadow:0 1px 0 var(--line)}

/* ---------- type: bold italic display, gold eyebrows ---------- */
html[data-theme="midnight"] h1{font:italic 800 clamp(30px,4.4vw,48px)/1.05 var(--head);letter-spacing:-.02em}
html[data-theme="midnight"] h2{font:italic 700 19px/1.2 var(--head)}
html[data-theme="midnight"] .head h3{color:var(--gold);font:600 12px var(--body);letter-spacing:.06em;text-transform:uppercase}
html[data-theme="midnight"] h3{color:var(--mute)}
html[data-theme="midnight"] .brand .wm{font:italic 800 21px/.95 var(--head)}
html[data-theme="midnight"] .brand .wm small{color:var(--gold);font-style:normal}
html[data-theme="midnight"] .lg-tile{fill:var(--royal)}
html[data-theme="midnight"] .lg-mark{fill:#fff}


html[data-theme="midnight"] .big{color:var(--text);font-weight:800;font-style:italic;letter-spacing:-.03em}
html[data-theme="midnight"] .kpi .v,html[data-theme="midnight"] .countdown,html[data-theme="midnight"] .statgrid b{font-style:italic;font-weight:800}

/* ---------- surfaces: glass cards with a glowing edge; hero tile in royal-blue gradient ---------- */
html[data-theme="midnight"] .card,html[data-theme="midnight"] .tbl,html[data-theme="midnight"] .tile{background:var(--panel);backdrop-filter:blur(10px)}
html[data-theme="midnight"] .kpi{background:var(--panel);color:var(--text);box-shadow:var(--shadow)}
html[data-theme="midnight"] .kpi .l,html[data-theme="midnight"] .kpi .s,html[data-theme="midnight"] .kpi .mute{color:var(--mute)}
html[data-theme="midnight"] .kpi:has(.big){background:linear-gradient(135deg,var(--royal) 0%,var(--royal2) 100%);color:#fff;box-shadow:0 0 0 1px rgba(140,170,255,.5),0 20px 40px -18px rgba(47,91,255,.9)}
html[data-theme="midnight"] .kpi:has(.big) .l,html[data-theme="midnight"] .kpi:has(.big) .s{color:rgba(255,255,255,.78)}
html[data-theme="midnight"] .kpi .accent{color:var(--gold)}
html[data-theme="midnight"] .kpi .good{color:var(--good)}
html[data-theme="midnight"] .kpi .bad{color:var(--bad)}
html[data-theme="midnight"] .statgrid div{background:rgba(20,32,80,.7);color:var(--text);box-shadow:var(--edge)}
html[data-theme="midnight"] .statgrid div:nth-child(6n+1){background:linear-gradient(135deg,var(--royal),var(--royal2));color:#fff}
html[data-theme="midnight"] .statgrid div:nth-child(6n+1) small{color:rgba(255,255,255,.75)}
html[data-theme="midnight"] .statgrid small{color:var(--mute)}

/* ---------- chips, buttons ---------- */
html[data-theme="midnight"] .tabs{background:rgba(17,27,66,.7);box-shadow:var(--edge)}
html[data-theme="midnight"] .tabs button{color:var(--mute)}
html[data-theme="midnight"] .tabs button:hover{color:var(--text)}
html[data-theme="midnight"] .tabs button.on{background:linear-gradient(135deg,var(--royal),var(--royal2));color:#fff;box-shadow:0 6px 18px -8px rgba(47,91,255,.9)}
html[data-theme="midnight"] .btn{background:rgba(20,32,80,.7);border-color:var(--line2);color:var(--text)}
html[data-theme="midnight"] .btn:hover{border-color:var(--blue)}
html[data-theme="midnight"] .btn.acc{background:linear-gradient(135deg,var(--royal),var(--royal2));border-color:rgba(140,170,255,.5);color:#fff}
html[data-theme="midnight"] .tag{background:rgba(20,32,80,.7);border-color:var(--line2);color:var(--text)}
html[data-theme="midnight"] .tag.acc{background:var(--gold);border-color:var(--gold);color:var(--ink)}
html[data-theme="midnight"] .tag.good{background:rgba(61,220,132,.14);border-color:transparent;color:var(--good)}
html[data-theme="midnight"] .tag.bad{background:rgba(255,92,122,.14);border-color:transparent;color:var(--bad)}
html[data-theme="midnight"] .tag.mid{background:rgba(245,197,24,.14);border-color:transparent;color:var(--gold)}
html[data-theme="midnight"] .score{background:rgba(20,32,80,.9);color:#fff;box-shadow:var(--edge);font-style:italic}
html[data-theme="midnight"] .score.live{background:linear-gradient(135deg,var(--royal),var(--royal2))}
html[data-theme="midnight"] .gwinfo .live{background:var(--bad);color:#fff}
html[data-theme="midnight"] .gwinfo .live:before{background:#fff}
html[data-theme="midnight"] .refresh{background:rgba(20,32,80,.8);color:var(--text);box-shadow:var(--edge)}
html[data-theme="midnight"] input[type=text],html[data-theme="midnight"] input[type=number],html[data-theme="midnight"] input[type=search],html[data-theme="midnight"] select{background:rgba(20,32,80,.8);border-color:var(--line2);color:var(--text)}
html[data-theme="midnight"] input:focus,html[data-theme="midnight"] select:focus{border-color:var(--blue)}
html[data-theme="midnight"] :focus-visible{outline-color:var(--gold)}
html[data-theme="midnight"] .toggle{background:#1c2a63}
html[data-theme="midnight"] .toggle:checked{background:var(--royal)}
html[data-theme="midnight"] .toggle:checked:before{background:var(--gold)}
html[data-theme="midnight"] .bar,html[data-theme="midnight"] .worm{background:#1c2a63}
html[data-theme="midnight"] .bar i{background:linear-gradient(90deg,var(--royal),var(--blue))}
html[data-theme="midnight"] .w-g{background:var(--gold)}
html[data-theme="midnight"] .w-a{background:var(--blue)}
html[data-theme="midnight"] .w-app{background:#3b4a80}
html[data-theme="midnight"] .w-cs{background:var(--royal)}

/* ---------- navigation ---------- */
html[data-theme="midnight"] .side a i{background:rgba(20,32,80,.8);color:var(--text);box-shadow:var(--edge)}
html[data-theme="midnight"] .side a:hover{background:rgba(20,32,80,.6)}
html[data-theme="midnight"] .side a.on{background:linear-gradient(135deg,var(--royal),var(--royal2));color:#fff;box-shadow:0 10px 24px -12px rgba(47,91,255,.9)}
html[data-theme="midnight"] .side a.on i{background:var(--gold);color:var(--ink);box-shadow:none}
html[data-theme="midnight"] .sheet{background:#0e1840;box-shadow:var(--edge),0 20px 50px rgba(0,0,0,.6)}
html[data-theme="midnight"] .sheet a{background:rgba(30,45,105,.7)}
html[data-theme="midnight"] .sheet a i{background:var(--royal);color:#fff}
html[data-theme="midnight"] .tile i{background:var(--royal);color:#fff}
html[data-theme="midnight"] .tile:hover{background:linear-gradient(135deg,var(--royal),var(--royal2))}
html[data-theme="midnight"] .tile:hover small{color:rgba(255,255,255,.8)}
html[data-theme="midnight"] .tile b{font-style:italic}
html[data-theme="midnight"] .close{background:var(--royal);color:#fff}
html[data-theme="midnight"] .toast{background:linear-gradient(135deg,var(--royal),var(--royal2));color:#fff;box-shadow:var(--shadow)}
html[data-theme="midnight"] .modal{background:rgba(3,6,20,.65)}
html[data-theme="midnight"] .modal .pane{background:#0a1230}
html[data-theme="midnight"] .phead img{background:linear-gradient(160deg,var(--royal),var(--royal2))}

/* ---------- tables ---------- */
html[data-theme="midnight"] .tbl th{background:rgba(14,24,64,.95);color:var(--mute)}
html[data-theme="midnight"] .tbl th.sorted{color:var(--gold);box-shadow:inset 0 -3px 0 var(--gold)}
html[data-theme="midnight"] .tbl td{border-top-color:var(--line)}
html[data-theme="midnight"] .tbl tbody tr:hover{background:rgba(47,91,255,.1)}
html[data-theme="midnight"] .tbl tr.me{background:rgba(245,197,24,.1)}
html[data-theme="midnight"] .tbl tr.mine{background:rgba(61,220,132,.08)}
html[data-theme="midnight"] .tbl tr.rival{background:rgba(111,155,255,.1)}
html[data-theme="midnight"] .err{background:rgba(255,92,122,.1)}

/* ---------- pitch: dark floodlit pitch, gold points ---------- */
html[data-theme="midnight"] .pitch{box-shadow:var(--edge)}
html[data-theme="midnight"] .pl .nm{background:rgba(7,13,36,.85);color:#fff}
html[data-theme="midnight"] .pl .pt{background:var(--gold);color:var(--ink)}
html[data-theme="midnight"] .pl .pt.zero{background:#1c2a63;color:var(--mute)}
html[data-theme="midnight"] .pl .badge{background:var(--gold);color:var(--ink)}
html[data-theme="midnight"] .bench{background:rgba(17,27,66,.82);box-shadow:var(--edge)}

@media (max-width:820px){
  html[data-theme="midnight"] .bottom{background:rgba(10,18,48,.95);box-shadow:var(--edge),0 14px 30px -10px rgba(0,0,0,.7)}
  html[data-theme="midnight"] .bottom i{border-color:var(--line2)}
  html[data-theme="midnight"] .bottom .on i{background:linear-gradient(135deg,var(--royal),var(--royal2));border-color:transparent;color:#fff}
}

/* player card colours (card.js) */
html[data-theme="midnight"]{--card-bg:#2f5bff;--card-ink:#ffffff;--card-bar:#0a1230;--card-bar-ink:#f5c518}

/* fixture chips: the traffic-light colours under a navy wash, white text, so they sit in the dark design */
html[data-theme="midnight"] .ticker .c:not(.blank),html[data-theme="midnight"] .ticker .c.dbl > span{color:#fff !important;box-shadow:inset 0 0 0 99px rgba(7,13,36,.28),inset 0 0 0 1px rgba(255,255,255,.18);text-shadow:0 1px 2px rgba(7,13,36,.55)}
html[data-theme="midnight"] .ticker .c.dbl{box-shadow:none}
html[data-theme="midnight"] .ticker .c small{color:rgba(255,255,255,.85) !important;opacity:1}
html[data-theme="midnight"] .ticker .c.blank{background:rgba(20,32,80,.7);color:var(--mute)}
