/* ALFRED V6e — cinematic layer. Additive overlay over alfred-v6.css. Mark VII.
   Goal: glass depth, living glow, holographic sheen, supercomputer feel. Both displays. */

:root{
  --cy:#46e0ff; --cy-dim:#39c6d8; --gold:#ffd27a; --grn:#46e8a0; --red:#ff7a7a;
  --ink-0:#d9f7fd; --ink-1:#9fdcec; --ink-2:#5d8ea3;
  --glass:linear-gradient(155deg,rgba(16,36,52,.74),rgba(6,14,22,.88));
  --edge:rgba(86,224,255,.34);
  --halo:0 10px 44px rgba(0,0,0,.55), 0 0 0 1px rgba(86,224,255,.05) inset, 0 0 26px rgba(57,198,216,.10);
}

/* ============ PANELS: widgets, cards, stat tiles ============ */
.v6widget,.v6card,.v6tile,.v6acard{
  background:var(--glass) !important;
  -webkit-backdrop-filter:blur(16px) saturate(150%);
  backdrop-filter:blur(16px) saturate(150%);
  border:1px solid var(--edge) !important;
  border-radius:9px !important;
  box-shadow:var(--halo);
}
.v6widget,.v6card{ padding:14px 17px 15px !important; }

/* top accent bar (holographic) */
.v6widget::before, .v6card::before{
  content:'' !important; position:absolute; top:0; left:14px; right:14px; width:auto !important; height:2px !important;
  background:linear-gradient(90deg,transparent,var(--cy),transparent) !important;
  border:none !important; opacity:.7; filter:drop-shadow(0 0 6px var(--cy));
}
/* glowing corner bracket (bottom-right) */
.v6widget::after, .v6card::after{
  content:'' !important; position:absolute; bottom:0; right:0; width:24px !important; height:24px !important;
  border-bottom:2px solid rgba(86,224,255,.55) !important; border-right:2px solid rgba(86,224,255,.55) !important;
  border-radius:0 0 9px 0; box-shadow:6px 6px 14px -6px rgba(70,224,255,.5);
  top:auto !important; left:auto !important;
}
/* living breath on the border */
@keyframes v6breath{0%,100%{box-shadow:var(--halo)}50%{box-shadow:0 10px 44px rgba(0,0,0,.55), 0 0 0 1px rgba(86,224,255,.10) inset, 0 0 38px rgba(57,198,216,.20)}}
.v6widget.in,.v6card.in{ animation:v6breath 5.5s ease-in-out infinite; }

/* entrance: spring + clearing blur */
.v6widget,.v6card{ transition:transform .6s cubic-bezier(.16,1,.3,1),opacity .5s,filter .6s !important; filter:blur(4px); }
.v6widget.in,.v6card.in{ filter:blur(0); }

/* titles */
.v6widget .wt,.v6card .ct{
  font-family:'Michroma',monospace !important; color:var(--cy) !important;
  letter-spacing:3px !important; text-shadow:0 0 12px rgba(70,224,255,.45);
  display:flex; align-items:center; gap:9px;
}
.v6widget .wt::before, .v6card .ct::before{
  content:''; width:6px; height:6px; border-radius:50%; background:var(--cy);
  box-shadow:0 0 9px var(--cy); animation:v6pip 2.2s ease-in-out infinite; flex:0 0 auto;
}
@keyframes v6pip{0%,100%{opacity:.55;transform:scale(.85)}50%{opacity:1;transform:scale(1.15)}}
.v6widget .cl,.v6card .cl{ font-family:Rajdhani; color:var(--ink-0); line-height:1.5; }

/* close / expand controls */
.v6widget .wx,.v6widget .we{ transition:color .2s,transform .2s,text-shadow .2s; }
.v6widget .wx:hover{ color:var(--red); transform:scale(1.2); text-shadow:0 0 10px rgba(255,122,122,.6); }
.v6widget .we:hover{ color:var(--cy); text-shadow:0 0 10px var(--cy); }

/* sweep on arrival */
.v6widget.in::after{ /* keep base sweep but soften */ }

/* ============ STAT TILES ============ */
.v6tile{ padding:18px 20px !important; }
.v6tile .tv{ text-shadow:0 0 22px rgba(70,224,255,.5) !important; color:var(--ink-0) !important; }
.v6tile:hover{ border-color:var(--cy) !important; box-shadow:var(--halo),0 0 30px rgba(70,224,255,.18); }

/* ============ AGENT CARDS ============ */
.v6acard{ border-color:rgba(255,210,122,.4) !important; }
.v6acard.done{ border-color:rgba(70,232,160,.45) !important; }
.v6acard .dot{ box-shadow:0 0 9px var(--gold); }
.v6acard .dot.g{ box-shadow:0 0 9px var(--grn); }

/* ============ MAIN WINDOW ============ */
#v6win.glass{ background:var(--glass) !important; -webkit-backdrop-filter:blur(20px) saturate(140%); backdrop-filter:blur(20px) saturate(140%); border:1px solid var(--edge) !important; box-shadow:0 24px 80px rgba(0,0,0,.6),0 0 0 1px rgba(86,224,255,.06) inset,0 0 50px rgba(57,198,216,.10) !important; }
#v6win .v6tag{ color:var(--cy) !important; text-shadow:0 0 12px rgba(70,224,255,.5),0 0 8px rgba(0,0,0,.9) !important; }
#v6win .v6ctl button{ -webkit-backdrop-filter:blur(8px); backdrop-filter:blur(8px); transition:all .2s; }
#v6win .v6ctl button:hover{ box-shadow:0 0 14px rgba(70,224,255,.4); }

/* ============ DOCK LABELS ============ */
#v6dockL:has(.v6widget)::before,#v6dockR:has(.v6widget)::before{
  color:var(--cy) !important; text-shadow:0 0 12px rgba(70,224,255,.4); opacity:.85;
  animation:v6label 4s ease-in-out infinite;
}
@keyframes v6label{0%,100%{opacity:.6}50%{opacity:.95}}

/* ============ SUBTITLE (movie lower-third) ============ */
#v6subtitle{
  font-size:30px !important; font-weight:600; letter-spacing:.5px !important;
  color:#eafcff !important; max-width:78% !important;
  text-shadow:0 0 26px rgba(70,224,255,.55),0 2px 10px rgba(0,0,0,.95) !important;
  padding:10px 30px;
}
#v6subtitle.on::before{
  content:''; position:absolute; inset:-14px -28px; z-index:-1; border-radius:14px;
  background:radial-gradient(ellipse at center,rgba(6,16,24,.62),transparent 72%);
  -webkit-backdrop-filter:blur(3px); backdrop-filter:blur(3px);
}

/* ============ SLITHER ============ */
#v6sliver{ background:linear-gradient(155deg,rgba(8,18,28,.92),rgba(4,10,16,.96)) !important; -webkit-backdrop-filter:blur(14px); backdrop-filter:blur(14px); border-left:1px solid var(--edge) !important; }
#v6sliver .vclock{ text-shadow:0 0 14px rgba(70,224,255,.4); }
#v6sliver .vkpi b{ text-shadow:0 0 14px rgba(255,210,122,.4); }
#v6sliver .vq button{ -webkit-backdrop-filter:blur(8px); backdrop-filter:blur(8px); transition:all .2s; }
#v6sliver .vq button:hover{ box-shadow:0 0 14px rgba(70,224,255,.3); transform:translateX(-2px); }

/* ============ NOW-PLAYING PILL ============ */
#v6nowplay{ -webkit-backdrop-filter:blur(10px); backdrop-filter:blur(10px); box-shadow:0 0 22px rgba(57,198,216,.2); }

/* ============ MUSIC TAP overlay ============ */
.wplay{ -webkit-backdrop-filter:blur(6px); backdrop-filter:blur(6px); text-shadow:0 0 14px rgba(255,210,122,.6); }

/* ============ CINEMATIC SCROLLBARS ============ */
.v6agrid::-webkit-scrollbar,.v6console::-webkit-scrollbar,#v6body ::-webkit-scrollbar,.wb::-webkit-scrollbar{width:7px;height:7px;}
::-webkit-scrollbar-thumb{background:linear-gradient(180deg,rgba(70,224,255,.4),rgba(57,198,216,.2));border-radius:8px;}
::-webkit-scrollbar-track{background:rgba(10,24,33,.4);}

/* ============ PC STAGE: faint grid + vignette for depth ============ */
body.v6companion::before{
  content:''; position:fixed; inset:0; z-index:0; pointer-events:none;
  background:
    radial-gradient(ellipse at 50% 40%,transparent 40%,rgba(0,0,0,.45) 100%),
    linear-gradient(rgba(70,224,255,.018) 1px,transparent 1px),
    linear-gradient(90deg,rgba(70,224,255,.018) 1px,transparent 1px);
  background-size:100% 100%, 46px 46px, 46px 46px;
}
body.v6companion #v6dockL,body.v6companion #v6dockR,body.v6companion #v6subtitle,body.v6companion #v6cards{ z-index:9300; }

/* keep motion smooth on a weak GPU */
.v6widget,.v6card,#v6win{ will-change:transform,opacity,filter; }

/* ============ COMMAND WALL (live mission-control on the stage) ============ */
#v6wall{position:fixed;inset:0;z-index:9200;display:flex;flex-direction:column;padding:30px 34px 26px;pointer-events:none;
  opacity:0;transition:opacity .7s;background:radial-gradient(ellipse at 50% 35%,rgba(6,16,26,.30),rgba(3,8,14,.66));}
#v6wall.on{opacity:1;}
#v6wall .wallhead{font-family:'Michroma',monospace;font-size:15px;letter-spacing:6px;color:var(--cy);
  text-shadow:0 0 16px rgba(70,224,255,.5);display:flex;align-items:center;gap:16px;margin-bottom:20px;opacity:.92;}
#v6wall .wallhead .wclk{margin-left:auto;color:var(--ink-1);font-size:14px;letter-spacing:3px;}
#v6wall .wallhead::before{content:'';width:9px;height:9px;border-radius:50%;background:var(--grn);box-shadow:0 0 12px var(--grn);animation:v6pip 2s ease-in-out infinite;}
#v6wall .wallgrid{flex:1;display:grid;grid-template-columns:repeat(4,1fr);grid-auto-rows:1fr;gap:18px;min-height:0;}
.wpanel{position:relative;background:var(--glass);-webkit-backdrop-filter:blur(16px) saturate(150%);backdrop-filter:blur(16px) saturate(150%);
  border:1px solid var(--edge);border-radius:11px;box-shadow:var(--halo);padding:18px 20px;display:flex;flex-direction:column;overflow:hidden;
  opacity:0;transform:translateY(16px) scale(.98);transition:opacity .6s,transform .6s cubic-bezier(.16,1,.3,1);}
.wpanel.in{opacity:1;transform:none;}
.wpanel::before{content:'';position:absolute;top:0;left:16px;right:16px;height:2px;background:linear-gradient(90deg,transparent,var(--pc,var(--cy)),transparent);filter:drop-shadow(0 0 6px var(--pc,var(--cy)));opacity:.75;}
.wpanel::after{content:'';position:absolute;bottom:0;right:0;width:26px;height:26px;border-bottom:2px solid var(--pc,rgba(86,224,255,.5));border-right:2px solid var(--pc,rgba(86,224,255,.5));border-radius:0 0 11px 0;opacity:.6;}
.wpanel .wpt{font-family:'Michroma',monospace;font-size:10.5px;letter-spacing:3.5px;color:var(--pc,var(--cy));text-shadow:0 0 10px rgba(70,224,255,.4);display:flex;align-items:center;gap:8px;margin-bottom:auto;}
.wpanel .wpt::before{content:'';width:6px;height:6px;border-radius:50%;background:var(--pc,var(--cy));box-shadow:0 0 8px var(--pc,var(--cy));animation:v6pip 2.4s ease-in-out infinite;}
.wpanel .wstat{font-family:Rajdhani;font-size:9px;letter-spacing:2px;color:var(--ink-2);margin-left:auto;}
.wpanel .wbig{display:flex;gap:22px;align-items:flex-end;flex-wrap:wrap;margin-top:14px;}
.wpanel .wmetric{display:flex;flex-direction:column;}
.wpanel .wmv{font-family:'Michroma',monospace;font-size:34px;line-height:1;color:var(--ink-0);text-shadow:0 0 22px var(--pc,rgba(70,224,255,.45));}
.wpanel .wml{font-family:Rajdhani;font-size:10px;letter-spacing:2px;color:var(--ink-2);text-transform:uppercase;margin-top:6px;}
.wpanel .wbody{font-family:Rajdhani;font-size:14px;color:var(--ink-1);margin-top:12px;line-height:1.5;}
.wpanel .wrow{display:flex;justify-content:space-between;font-family:Rajdhani;font-size:13px;color:var(--ink-1);padding:3px 0;border-bottom:1px solid rgba(70,240,255,.08);}
.wpanel.span2{grid-column:span 2;}
.wpanel .wspark{position:absolute;left:0;right:0;bottom:0;height:30%;opacity:.5;pointer-events:none;}
.wpanel.warn{border-color:rgba(255,210,122,.5);--pc:var(--gold);}
.wpanel.bad{border-color:rgba(255,122,122,.5);--pc:var(--red);}

/* ============ V8PATCH-WD: WINDOW DECK — view cards on side rails ============ */
.vcprev{position:relative;cursor:pointer;border-radius:5px;overflow:hidden;height:112px;background:#000;box-shadow:inset 0 0 0 1px rgba(86,224,255,.18);}
.vcprev .vcfrwrap{position:absolute;inset:0;overflow:hidden;border-radius:5px;}
.vcprev .vcfr{position:absolute;left:0;top:0;width:200%;height:200%;transform:scale(.5);transform-origin:0 0;border:none;background:#000;pointer-events:none;}
.vcprev .vcph{height:112px;display:flex;align-items:center;justify-content:center;color:#9fdcec;font-family:'Michroma',monospace;letter-spacing:3px;font-size:11px;background:radial-gradient(ellipse at center,rgba(70,224,255,.08),rgba(0,0,0,.4));text-shadow:0 0 12px rgba(70,224,255,.4);}
.vcprev .vcopen{position:absolute;left:0;right:0;bottom:0;padding:5px 8px;background:linear-gradient(0deg,rgba(6,14,22,.92),rgba(6,14,22,0));color:var(--cy);font-family:'Michroma',monospace;font-size:8.5px;letter-spacing:2.5px;text-align:center;text-shadow:0 0 8px rgba(70,224,255,.45);opacity:.85;transition:opacity .2s,text-shadow .2s;}
.vcprev:hover .vcopen{opacity:1;text-shadow:0 0 14px var(--cy);}
.vcprev:hover{box-shadow:inset 0 0 0 1px rgba(86,224,255,.5),0 0 18px rgba(70,224,255,.18);}
.vcprev::before{content:'';position:absolute;top:0;left:8px;right:8px;height:1px;background:linear-gradient(90deg,transparent,var(--cy),transparent);opacity:.5;z-index:2;pointer-events:none;}

/* ============ V8PATCH-WD: COMPLETED TASKS DOCK (bottom of PC stage) ============ */
#v6tdock{position:fixed;left:0;right:0;bottom:0;z-index:9400;pointer-events:none;padding:10px 30px 14px;display:flex;flex-direction:column;align-items:center;gap:7px;}
#v6tdock .tdlab{font-family:'Michroma',monospace;font-size:9px;letter-spacing:4px;color:rgba(57,198,216,.55);text-shadow:0 0 10px rgba(57,198,216,.25);opacity:.85;animation:v6label 4s ease-in-out infinite;}
#v6tdock .tdcards{display:flex;gap:9px;flex-wrap:wrap;justify-content:center;pointer-events:auto;max-width:80%;}
.v6tcard{
 position:relative;background:var(--glass);-webkit-backdrop-filter:blur(14px) saturate(140%);backdrop-filter:blur(14px) saturate(140%);
 border:1px solid rgba(70,232,160,.36);border-radius:7px;padding:6px 11px 7px 10px;cursor:pointer;
 font-family:Rajdhani;font-size:12.5px;color:var(--ink-0);display:flex;align-items:center;gap:7px;
 opacity:0;transform:translateY(22px) scale(.94);
 transition:transform .55s cubic-bezier(.22,.9,.3,1),opacity .5s,border-color .25s,box-shadow .25s,background .25s;
 box-shadow:0 6px 22px rgba(0,0,0,.55),0 0 0 1px rgba(70,232,160,.06) inset,0 0 14px rgba(70,232,160,.08);
}
.v6tcard.in{opacity:1;transform:none;}
.v6tcard:hover{border-color:rgba(70,232,160,.75);box-shadow:0 6px 26px rgba(0,0,0,.65),0 0 22px rgba(70,232,160,.22);transform:translateY(-2px);}
.v6tcard::before{content:'';position:absolute;top:0;left:8px;right:8px;height:1px;background:linear-gradient(90deg,transparent,var(--grn),transparent);opacity:.55;filter:drop-shadow(0 0 4px var(--grn));}
.v6tcard .tdtk{color:#46e8a0;font-weight:800;font-size:13px;text-shadow:0 0 10px rgba(70,232,160,.7);flex:0 0 auto;}
.v6tcard .tdname{letter-spacing:1.4px;font-weight:600;color:var(--ink-0);}
.v6tcard .tdx{margin-left:4px;color:#5d8ea3;font-size:13px;line-height:1;opacity:.55;transition:color .2s,opacity .2s;padding:0 2px;}
.v6tcard:hover .tdx{opacity:.9;}
.v6tcard .tdx:hover{color:var(--red);text-shadow:0 0 8px rgba(255,122,122,.5);}

/* dim the bottom dock when the big window is up so it doesn't compete */
body.v6-on #v6tdock{opacity:.18;pointer-events:none;transition:opacity .5s;}
body.v6-on #v6tdock .v6tcard{transition:opacity .5s;}
