/* 3D v2 (27 Nov 2026, round 2): additive finish for the one-panel shell. Tenant colours only (tokens of portal.css). No tool, auth or payment code involved.
   Motion = transform / opacity only; everything static under prefers-reduced-motion. Rollback: remove the fx.css / fx.js lines from index.html. */
@keyframes pfx-in{from{opacity:0;translate:0 14px}}
@keyframes pfx-bob{50%{translate:0 -3px}}
@keyframes pfx-tw{0%,100%{opacity:.25;scale:.85}50%{opacity:.9;scale:1.1}}
@keyframes pfx-orb{50%{translate:-8px 8px}}
@keyframes pfx-orb2{50%{translate:8px -8px}}
@keyframes pfx-sheen{to{translate:330% 0}}
@keyframes pfx-bounce{30%{translate:0 -4px}60%{translate:0 1px}}
@keyframes pfx-ring{0%{opacity:.5;scale:1}70%,100%{opacity:0;scale:1.14 1.35}}
@keyframes pfx-toast{from{opacity:0;translate:0 12px}}
/* signed-out: the sign-in card sits in the true centre (no empty menu column) + three plain benefit chips */
html.op-anon .op-app{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr);grid-template-areas:"top" "body";position:relative;isolation:isolate}
html.op-anon .tp-main>.tp-card{margin-top:clamp(30px,9vh,96px)!important}
.fx-ben{list-style:none;margin:22px auto 0;padding:0 12px;max-width:640px;display:flex;flex-wrap:wrap;justify-content:center;gap:10px 10px}
.fx-ben li{display:inline-flex;align-items:center;gap:9px;min-height:44px;padding:7px 16px 7px 8px;border-radius:999px;font:600 14px/1.2 var(--font-h,Poppins,system-ui,sans-serif);color:var(--ink);border:1px solid var(--line);background:var(--key-light-bg,#fff);box-shadow:var(--key-light-sh,0 3px 0 var(--b-rim))}
.fx-ben i{flex:none;width:30px;height:30px;border-radius:10px;display:grid;place-items:center;color:var(--on-brand,#fff);background:var(--key-bg,var(--brand));box-shadow:inset 0 1px 1px rgba(255,255,255,.5),0 3px 0 var(--b-edge),0 0 12px -3px var(--b-glow2)}
.fx-ben li:nth-child(2) i{background:linear-gradient(180deg,color-mix(in srgb,var(--brand2) 84%,#fff),var(--brand2) 50%,color-mix(in srgb,var(--brand2) 82%,#000));box-shadow:inset 0 1px 1px rgba(255,255,255,.5),0 3px 0 color-mix(in srgb,var(--brand2) 60%,#07041c)}
.fx-ben svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:2.3;stroke-linecap:round;stroke-linejoin:round}
/* signed-out ambience: two soft institute-colour orbs drifting 8 px (10 s) + a faint dot mesh on wide screens (Gemini F6 / D7) */
html.op-anon .op-app::before,html.op-anon .op-app::after{content:"";position:absolute;z-index:-1;border-radius:50%;pointer-events:none}
html.op-anon .op-app::before{left:-70px;top:12%;width:260px;height:260px;background:radial-gradient(circle at 35% 30%,rgba(255,255,255,.9),var(--b-soft) 40%,transparent 72%);animation:pfx-orb 10s ease-in-out infinite}
html.op-anon .op-app::after{right:-60px;bottom:8%;width:220px;height:220px;background:radial-gradient(circle at 35% 30%,rgba(255,255,255,.9),var(--a-tint,var(--b-tint)) 40%,transparent 72%);animation:pfx-orb2 12s ease-in-out infinite}
@media (min-width:1280px){html.op-anon .op-body{background:radial-gradient(circle,var(--b-rim) 1px,transparent 1.6px) 0 0/26px 26px}}
.fx-sp{position:absolute;z-index:-1;pointer-events:none;width:18px;height:18px;background:linear-gradient(135deg,#fff8d6,#ffd24a 55%,#f2a20c);clip-path:polygon(50% 0,61% 39%,100% 50%,61% 61%,50% 100%,39% 61%,0 50%,39% 39%);filter:drop-shadow(0 0 5px rgba(255,214,102,.95));animation:pfx-tw 3.5s ease-in-out infinite}
.fx-sp:nth-of-type(2){animation-delay:.9s;scale:.7}.fx-sp:nth-of-type(3){animation-delay:1.8s}.fx-sp:nth-of-type(4){animation-delay:2.6s;scale:.8}
@media (max-width:699px){.fx-sp:nth-of-type(n+3){display:none}}
/* dashboard: compact glossy welcome band in the institute colour */
.op-head[data-k="dashboard"] .op-head-row{position:relative;isolation:isolate;overflow:hidden;padding:16px 18px 18px;border-radius:var(--r,20px);color:var(--on-brand,#fff);background:var(--hero-bg,var(--brand));box-shadow:var(--hero-sh,0 6px 0 var(--b-edge));border:1px solid rgba(255,255,255,.36)}
.op-head[data-k="dashboard"] .op-head-row::before{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;background:var(--sparkle,none) right 12% top 8%/190px auto no-repeat;opacity:.9}
.op-head[data-k="dashboard"] .op-head-row::after{content:"";position:absolute;z-index:-1;right:-34px;bottom:-54px;width:130px;height:130px;border-radius:50%;pointer-events:none;background:radial-gradient(circle at 34% 30%,rgba(255,255,255,.95) 0 4%,rgba(255,255,255,.45) 11%,transparent 30%),radial-gradient(circle at 60% 70%,var(--a-lo,var(--accent)),var(--accent) 60%);box-shadow:inset -10px -14px 22px rgba(0,0,0,.2),inset 6px 8px 14px rgba(255,255,255,.28),0 0 30px -4px var(--a-glow);animation:pfx-orb 10s ease-in-out infinite}
.op-head[data-k="dashboard"] h1,.op-head[data-k="dashboard"] .op-hint,.op-head[data-k="dashboard"] .op-hint .op-next{color:inherit}
.op-head[data-k="dashboard"] h1{text-shadow:0 1px 0 rgba(0,0,0,.14)}
.op-head[data-k="dashboard"] .op-hint{opacity:.96}
.op-head[data-k="dashboard"] .op-head-row>.op-ic{background:var(--key-light-bg,#fff);box-shadow:inset 0 2px 1px #fff,0 4px 0 rgba(0,0,0,.2)}
.op-head[data-k="dashboard"] .op-head-row>.op-ic .op-gl{color:var(--brand-ink,var(--brand));background-color:var(--brand-ink,var(--brand))}
.op-head[data-k="dashboard"] .op-info{color:inherit}
/* phones: the orb moves to the top-right corner so it never sits behind the free-copies / wallet chips (Gemini B2-4) */
@media (max-width:699px){.op-head[data-k="dashboard"] .op-head-row::before{display:none}.op-head[data-k="dashboard"] .op-head-row::after{width:84px;height:84px;right:-34px;top:-44px;bottom:auto;opacity:.8}}
/* entrance on every section open (class fx-in is set by fx.js for 1 s): short rise, 30 ms stagger (Gemini B2-1) */
.fx-in .op-kpi,.fx-in .op-act,.fx-in .op-cols>*,.fx-in>.tp-card,.fx-in .op-state{animation:pfx-in .35s cubic-bezier(.2,.8,.2,1) both}
.fx-in .op-kpi:nth-child(2),.fx-in .op-act:nth-child(2),.fx-in>.tp-card:nth-child(2){animation-delay:.03s}
.fx-in .op-kpi:nth-child(3),.fx-in .op-act:nth-child(3),.fx-in>.tp-card:nth-child(3){animation-delay:.06s}
.fx-in .op-kpi:nth-child(4),.fx-in .op-act:nth-child(4),.fx-in>.tp-card:nth-child(n+4){animation-delay:.09s}
.fx-in .op-act:nth-child(5){animation-delay:.12s}.fx-in .op-act:nth-child(6){animation-delay:.15s}.fx-in .op-act:nth-child(7){animation-delay:.18s}.fx-in .op-act:nth-child(8){animation-delay:.21s}.fx-in .op-act:nth-child(n+9){animation-delay:.24s}
.fx-in .op-cols>*{animation-delay:.2s}
/* icon sheen: one light sweep across every keycap icon when a section opens (element i.fx-sh is added by fx.js) */
.op-ic .fx-sh{position:absolute;inset:0;border-radius:inherit;overflow:hidden;pointer-events:none}
.op-ic .fx-sh::before{content:"";position:absolute;top:0;bottom:0;left:0;width:45%;background:linear-gradient(105deg,transparent,rgba(255,255,255,.55),transparent);translate:-130% 0}
.fx-in .op-ic .fx-sh::before,.fx-in-head .op-ic .fx-sh::before{animation:pfx-sheen .9s .3s ease-in-out both}
/* KPI numbers count up once per session (fx.js); tabular digits keep the card width still while counting */
.op-kpi-v{font-variant-numeric:tabular-nums}
/* cards: hover lift + ground glow (mouse only), tap feedback on touch (Gemini F7) */
@media (hover:hover) and (pointer:fine){
  .op-act,.tp-grid>.tp-card,.op-cols>.tp-card{transition:transform .16s ease-out,box-shadow .16s ease-out}
  .op-act:hover{transform:translateY(-3px) scale(1.01);box-shadow:var(--slab-sh),0 18px 22px -14px var(--b-glow2)}
  .tp-grid>.tp-card:hover,.op-cols>.tp-card:hover{translate:none;transform:translateY(-3px) scale(1.01);box-shadow:var(--slab-sh),0 18px 22px -14px var(--b-glow2)}
}
@media (hover:none){.op-act:active{transform:translateY(2px) scale(.98)}}
/* active nav item: tiny gold sparkle + a short bounce when it becomes active */
.op-item.on{animation:pfx-bounce .45s ease-out both}
.op-item.on::after{content:"";position:absolute;right:4px;top:3px;width:10px;height:10px;pointer-events:none;background:linear-gradient(135deg,#fff8d6,#ffd24a 55%,#f2a20c);clip-path:polygon(50% 0,61% 39%,100% 50%,61% 61%,50% 100%,39% 61%,0 50%,39% 39%);filter:drop-shadow(0 0 3px rgba(255,214,102,.95));animation:pfx-tw 3.2s ease-in-out infinite}
@media (min-width:1100px) and (min-height:560px){.op-item.on::after{right:8px;top:50%;margin-top:-5px}}
/* empty state: the icon breathes; toast: rise in + one glow ring */
.op-empty .op-ic{animation:pfx-bob 4.5s ease-in-out infinite}
.tp-toast{animation:pfx-toast .3s ease-out both}
.tp-toast::after{content:"";position:absolute;inset:-3px;border-radius:inherit;border:2px solid var(--b-glow2);pointer-events:none;animation:pfx-ring 1.6s ease-out 2}
/* quick actions: 3 columns on desktop (9 tiles = 3 x 3, no orphan), 2 columns + full-width last tile on tablets (Gemini S4 / D2) */
@media (min-width:1100px){.op-acts{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media (min-width:700px) and (max-width:1099px){.op-acts{grid-template-columns:repeat(2,minmax(0,1fr))}.op-act:last-child:nth-child(odd){grid-column:1/-1}}
/* phones from 360px: KPI cards two per row (shorter scroll) */
@media (max-width:699px) and (min-width:360px){
  .op-kpis{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
  .op-app .op-kpi{padding:62px 12px 12px;min-height:0}
  .op-kpi>.op-ic{left:12px;top:12px}
  .op-kpi .op-kpi-v{font-size:26px}
  .op-kpi .op-kpi-l,.op-kpi .op-kpi-s{overflow-wrap:anywhere}
}
@media (prefers-reduced-motion:reduce){
  .fx-in .op-kpi,.fx-in .op-act,.fx-in .op-cols>*,.fx-in>.tp-card,.fx-in .op-state,.op-item.on,.op-item.on::after,.op-empty .op-ic,.tp-toast,.fx-sp,.op-head[data-k="dashboard"] .op-head-row::after,html.op-anon .op-app::before,html.op-anon .op-app::after,.fx-in .op-ic .fx-sh::before,.fx-in-head .op-ic .fx-sh::before{animation:none!important}
  .tp-toast::after{display:none}
  .op-act,.tp-grid>.tp-card,.op-cols>.tp-card{transition:none}
}
