/* Tema "Jarvis": interfaccia HUD scura (blu notte, ciano luminoso, bordi che brillano).
   Si attiva con <html data-theme="jarvis">; senza l'attributo resta il tema classico. */
html[data-theme="jarvis"]{
  --bg:#030a14;--card:rgba(7,24,42,.78);--ink:#d9f4ff;--mute:#7fa9c0;--line:rgba(25,211,255,.24);
  --brand:#19d3ff;--ok:#2dffb0;--bad:#ff5d6c;--warn:#ffb02e;--glow:0 0 14px rgba(25,211,255,.35);
  color-scheme:dark;
}
html[data-theme="jarvis"] body{
  font-family:"Rajdhani","Segoe UI",-apple-system,BlinkMacSystemFont,sans-serif;font-size:15px;font-weight:500;letter-spacing:.01em;
  background:
    radial-gradient(1100px 600px at 78% -8%,rgba(0,150,255,.20),transparent 60%),
    radial-gradient(900px 600px at 5% 105%,rgba(255,150,30,.08),transparent 60%),
    linear-gradient(rgba(25,211,255,.045) 1px,transparent 1px) 0 0/44px 44px,
    linear-gradient(90deg,rgba(25,211,255,.045) 1px,transparent 1px) 0 0/44px 44px,
    #030a14;
  background-attachment:fixed;
}
/* intestazione */
html[data-theme="jarvis"] header{background:rgba(3,12,24,.82);backdrop-filter:blur(10px);border-bottom:1px solid rgba(25,211,255,.35);box-shadow:0 6px 30px rgba(0,120,200,.18)}
html[data-theme="jarvis"] header::after{content:"";position:absolute;left:0;bottom:-1px;height:2px;width:160px;background:linear-gradient(90deg,transparent,#19d3ff,transparent);animation:hud-scan 5s linear infinite}
@keyframes hud-scan{from{left:-160px}to{left:100%}}
html[data-theme="jarvis"] h1,html[data-theme="jarvis"] h2{font-family:"Orbitron","Rajdhani",sans-serif;text-transform:uppercase;letter-spacing:.14em;text-shadow:0 0 12px rgba(25,211,255,.55)}
html[data-theme="jarvis"] h1{font-size:17px;color:#e8fbff}
html[data-theme="jarvis"] h2{font-size:13px;color:#8fe6ff}
html[data-theme="jarvis"] .brand-sub{color:#ffb02e;letter-spacing:.3em;text-shadow:0 0 8px rgba(255,176,46,.5)}
html[data-theme="jarvis"] .brand-logo-box{border-radius:50%;background:#000;box-shadow:0 0 0 2px rgba(25,211,255,.8),0 0 22px rgba(25,211,255,.55),inset 0 0 12px rgba(25,211,255,.4);position:relative}
html[data-theme="jarvis"] .brand-logo{transform:scale(1.22)}
html[data-theme="jarvis"] .brand-logo-box::after{content:"";position:absolute;inset:-6px;border-radius:50%;border:1px dashed rgba(25,211,255,.65);animation:hud-spin 18s linear infinite;pointer-events:none}
@keyframes hud-spin{to{transform:rotate(360deg)}}
html[data-theme="jarvis"] .brand-logo-box{overflow:visible}
html[data-theme="jarvis"] .brand-logo{border-radius:50%}
/* schede */
html[data-theme="jarvis"] nav button{font-family:"Orbitron","Rajdhani",sans-serif;font-size:11px;text-transform:uppercase;letter-spacing:.12em;padding:10px 14px;border:1px solid transparent;border-radius:3px;color:#7fb4cc;transition:.18s}
html[data-theme="jarvis"] nav button:hover{color:#d9f4ff;border-color:rgba(25,211,255,.35);background:rgba(25,211,255,.06)}
html[data-theme="jarvis"] nav button.on{background:linear-gradient(180deg,rgba(25,211,255,.18),rgba(25,211,255,.04));color:#fff;border-color:rgba(25,211,255,.7);box-shadow:var(--glow),inset 0 -2px 0 #19d3ff;text-shadow:0 0 10px rgba(25,211,255,.8)}
html[data-theme="jarvis"] .badge{background:#ffb02e;color:#1a0f00;font-weight:700}
html[data-theme="jarvis"] #health,html[data-theme="jarvis"] .hint{color:#6f9fb8}
/* riquadri con angoli "a staffa" */
html[data-theme="jarvis"] .panel,html[data-theme="jarvis"] .card{position:relative;background:linear-gradient(160deg,rgba(10,34,58,.82),rgba(4,14,28,.86));border:1px solid rgba(25,211,255,.28);border-radius:4px;box-shadow:0 0 0 1px rgba(0,0,0,.4),0 10px 30px rgba(0,0,0,.35),inset 0 0 40px rgba(25,211,255,.04)}
html[data-theme="jarvis"] .panel::before,html[data-theme="jarvis"] .card::before{content:"";position:absolute;inset:-1px;pointer-events:none;border-radius:4px;
  background:
    linear-gradient(#19d3ff,#19d3ff) top left/16px 2px no-repeat,linear-gradient(#19d3ff,#19d3ff) top left/2px 16px no-repeat,
    linear-gradient(#19d3ff,#19d3ff) top right/16px 2px no-repeat,linear-gradient(#19d3ff,#19d3ff) top right/2px 16px no-repeat,
    linear-gradient(#19d3ff,#19d3ff) bottom left/16px 2px no-repeat,linear-gradient(#19d3ff,#19d3ff) bottom left/2px 16px no-repeat,
    linear-gradient(#19d3ff,#19d3ff) bottom right/16px 2px no-repeat,linear-gradient(#19d3ff,#19d3ff) bottom right/2px 16px no-repeat;
  filter:drop-shadow(0 0 4px rgba(25,211,255,.8))}
html[data-theme="jarvis"] .tile,html[data-theme="jarvis"] .dad{background:rgba(6,22,40,.85);border:1px solid rgba(25,211,255,.25);border-radius:4px;transition:.18s}
html[data-theme="jarvis"] .tile:hover,html[data-theme="jarvis"] .dad:hover{border-color:#19d3ff;box-shadow:var(--glow)}
html[data-theme="jarvis"] .grid.sel .tile.picked{outline:2px solid #19d3ff;box-shadow:0 0 18px rgba(25,211,255,.6)}
html[data-theme="jarvis"] .tile.libpicked{outline:2px solid #ff5d6c;box-shadow:0 0 16px rgba(255,93,108,.55)}
html[data-theme="jarvis"] .tile .tick{background:#19d3ff;color:#001420}
html[data-theme="jarvis"] .selbox{background:rgba(3,12,24,.85);border:1px solid rgba(25,211,255,.5)}
html[data-theme="jarvis"] .cat-title{color:#19d3ff;font-family:"Orbitron","Rajdhani",sans-serif;font-size:11px;letter-spacing:.2em}
html[data-theme="jarvis"] .spunto{background:rgba(25,211,255,.06);border-left-color:#19d3ff}
html[data-theme="jarvis"] #lib-bulk{background:rgba(3,10,20,.9)}
/* campi e pulsanti */
html[data-theme="jarvis"] input,html[data-theme="jarvis"] select,html[data-theme="jarvis"] textarea{background:rgba(2,12,24,.85);border:1px solid rgba(25,211,255,.28);border-radius:3px;color:#e3f8ff;transition:.15s}
html[data-theme="jarvis"] input:focus,html[data-theme="jarvis"] select:focus,html[data-theme="jarvis"] textarea:focus{outline:none;border-color:#19d3ff;box-shadow:0 0 0 1px #19d3ff,0 0 16px rgba(25,211,255,.35)}
html[data-theme="jarvis"] label{color:#7fb4cc;text-transform:uppercase;font-size:11px;letter-spacing:.1em}
html[data-theme="jarvis"] label.check,html[data-theme="jarvis"] .seg label,html[data-theme="jarvis"] #m-enh label{text-transform:none;letter-spacing:0;font-size:14px;color:#d9f4ff}
html[data-theme="jarvis"] button.primary{background:linear-gradient(180deg,#27dcff,#0a9ad6);color:#00131f;border:1px solid #7fefff;border-radius:3px;font-family:"Orbitron","Rajdhani",sans-serif;font-size:12px;text-transform:uppercase;letter-spacing:.12em;box-shadow:0 0 18px rgba(25,211,255,.5);transition:.15s}
html[data-theme="jarvis"] button.primary:hover:not(:disabled){box-shadow:0 0 28px rgba(25,211,255,.9);filter:brightness(1.12)}
html[data-theme="jarvis"] button.ghost{border:1px solid rgba(25,211,255,.4);color:#bfeeff;border-radius:3px;background:rgba(25,211,255,.04);text-transform:uppercase;letter-spacing:.08em;font-size:11px}
html[data-theme="jarvis"] button.ghost:hover{border-color:#19d3ff;box-shadow:var(--glow);color:#fff}
html[data-theme="jarvis"] button.danger{color:#ff7d8a;border-color:rgba(255,93,108,.5)}
html[data-theme="jarvis"] label.file{background:rgba(25,211,255,.05);border:1px dashed #19d3ff;color:#19d3ff;border-radius:3px;text-transform:uppercase;letter-spacing:.08em;font-size:11px}
html[data-theme="jarvis"] pre{background:rgba(2,10,20,.9);border:1px solid rgba(25,211,255,.2);border-radius:3px;color:#cfeeff}
html[data-theme="jarvis"] .ph{background:rgba(25,211,255,.04);border:1px dashed rgba(25,211,255,.25)}
html[data-theme="jarvis"] .st{background:rgba(25,211,255,.1);color:#7fd9f5;border:1px solid rgba(25,211,255,.25);border-radius:3px;letter-spacing:.06em}
html[data-theme="jarvis"] .st.done{border-color:rgba(45,255,176,.5)}
html[data-theme="jarvis"] .st.failed{border-color:rgba(255,93,108,.5)}
html[data-theme="jarvis"] .st.review{border-color:rgba(255,176,46,.5)}
html[data-theme="jarvis"] #toast{background:rgba(3,14,28,.96);color:#e8fbff;border:1px solid #19d3ff;box-shadow:0 0 24px rgba(25,211,255,.5);border-radius:3px}
html[data-theme="jarvis"] .dep,html[data-theme="jarvis"] #m-live{border-radius:3px}
html[data-theme="jarvis"] .voice-bar .mic.rec{background:#ff3b4e;border-color:#ff3b4e}
html[data-theme="jarvis"] .logo-prev{border-radius:4px;border-color:rgba(25,211,255,.4)}
/* barre di scorrimento */
html[data-theme="jarvis"] ::-webkit-scrollbar{width:10px;height:10px}
html[data-theme="jarvis"] ::-webkit-scrollbar-track{background:#020812}
html[data-theme="jarvis"] ::-webkit-scrollbar-thumb{background:rgba(25,211,255,.35);border-radius:5px}
html[data-theme="jarvis"] ::-webkit-scrollbar-thumb:hover{background:#19d3ff}
html[data-theme="jarvis"] ::selection{background:rgba(25,211,255,.4);color:#fff}
/* interruttore tema */
#theme{font-size:11px}
