body:not(.auth-mode) aside#sidebar{background:radial-gradient(ellipse at 2% 5%,#77584b99,transparent 42%),linear-gradient(165deg,#402c2c,#201b20 75%,#50312c);border-color:#bca09666}
body:not(.auth-mode) #nav a.active,body:not(.auth-mode) #nav button.active{background:linear-gradient(90deg,#82515a,#67444655);color:#fff3ec;box-shadow:inset 3px 0 #e7b6ac}
body:not(.auth-mode) .shell:has(.ws-day-metrics){background:radial-gradient(ellipse at 88% 14%,#b88876,transparent 45%),linear-gradient(130deg,#d9cbc3,#ebd6ce 55%,#c2a395);color:#38282b}
.shell:has(.ws-day-metrics) .titlebar{background:linear-gradient(120deg,#632438,#a0465d 72%,#68293e);padding:26px;border-radius:16px;color:#fff4ec}
.shell:has(.ws-day-metrics) .titlebar :is(h1,.sub){color:inherit}.ws-day-metrics a.card{background:linear-gradient(145deg,#fff8f1ec,#ecd9cf);border-color:#fff9;color:#422e32}
.ws-day-metrics a.card :is(span,strong,small){color:inherit}.ws-day-grid .panel{background:#fffbf3eb;border-color:#fff8;color:#432e32}.ws-day-grid .panel :is(h2,h3,.text-button,small){color:inherit}

/* Shared workspace surfaces, including the default dashboard and sign-in. */
:root {
  --hk-paper: #faf2ec;
  --hk-ink: #362729;
  --hk-muted: #705955;
  --hk-edge: #cbb8ae;
  --hk-wine: #742d43;
  --hk-backdrop: radial-gradient(ellipse at 86% 16%, #f6e1d0 0, transparent 42%),
    radial-gradient(ellipse at 8% 82%, #ad8178 0, transparent 53%),
    linear-gradient(130deg, #c0a99b, #e1ccc0 48%, #bf9b93);
}
body .shell, body.auth-mode, body.auth-mode main {
  background: var(--hk-backdrop);
}
body.auth-mode main {
  max-width: none;
  min-height: 100dvh;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 430px);
  padding: clamp(24px, 7vw, 110px);
  gap: clamp(20px, 5vw, 80px);
}
.auth-mode .veltrix-story {
  align-self: center;
  min-height: clamp(320px, 53vh, 590px);
  padding: clamp(26px, 4vw, 68px);
  overflow: hidden;
  border: 1px solid #fff7;
  border-radius: 26px;
  color: #fff3e8;
  background: radial-gradient(ellipse at 82% 86%, #c88381, transparent 42%),
    linear-gradient(120deg, #542034, #84374e 64%, #a96268);
  box-shadow: 0 22px 65px #52252f36;
}
.auth-mode .veltrix-story h2 {max-width: 13em; color: inherit}
.auth-mode .veltrix-story h2 em {color: #f7cfbf}
.auth-mode .veltrix-story > p {color: #f5ded5}
.auth-mode .veltrix-story::after {
  content: ''; position: absolute; z-index: -1;
  width: 52%; aspect-ratio: 1; bottom: -34%; right: -5%;
  border: 1px solid #ffe6d2aa; border-radius: 50%;
  box-shadow: 0 0 0 14px #ffe4cd14, 0 0 0 33px #ffe4cd0e;
}
.auth-mode .veltrix-story {isolation: isolate}
.auth-mode .veltrix-orbit, .auth-mode .veltrix-principles {display: none}
.auth-mode .auth-card, body .shell :is(.panel,.card,.nx-card,.prod-card), body dialog:not(:has(.hk-work)) {
  --ink: var(--hk-ink); --muted: var(--hk-muted); --line: var(--hk-edge);
  --brand: var(--hk-wine); --surface: var(--hk-paper);
  background: linear-gradient(135deg,#fffaf4f5,#f3e5dcee);
  color: var(--ink); border: 1px solid #fffc; border-radius: 18px;
  box-shadow: 0 10px 32px #5135301c; color-scheme: light;
}
.auth-mode .auth-card::before {background: linear-gradient(90deg,transparent,#a86a73,transparent)}
.auth-mode .auth-card .logo {background:#532737; width:fit-content; padding:8px 18px; border-radius:12px}
body .shell :is(header,footer) {background:#f9eee5e6; border-color:var(--hk-edge); color:var(--hk-muted)}
body #crumb, body .header-right>span {color:var(--hk-muted)}
body .shell .titlebar {
  padding: clamp(18px, 3vw, 40px); border-radius: 18px;
  background: radial-gradient(ellipse at 86% 120%,#be7b78,transparent 46%),linear-gradient(115deg,#5b2338,#8e4053);
  color:#fff5ee; border:1px solid #fff7; box-shadow:0 10px 32px #51353025;
}
body .shell .titlebar :is(h1,.sub){color:inherit}
body .shell .card::before{background:var(--hk-wine)}
body :is(.auth-card,.shell,dialog) :is(input:not([type=checkbox]):not([type=radio]),select,textarea,option) {
  color:var(--hk-ink); background-color:#fffbf6; border-color:var(--hk-edge); color-scheme:light;
}
body :is(.auth-card,.shell,dialog) :is(input,textarea)::placeholder {color:#806c66}
body :is(.shell,.auth-card,dialog) button.primary {background:var(--hk-wine);color:#fff8f2;border-color:#682a3e}
body .shell :is(th,.ws-table th),body dialog:not(:has(.hk-work)) .panel-head {background:#ecdbd1;color:#503b38}
body .shell :is(td,.ws-table td){background:#fff8f1;color:var(--hk-ink);border-color:#e4d4cb}
body .shell tbody tr:hover td {background:#f2e3db}
body .shell .ws-selected-row td {background:#eed4d6!important}
body :is(.shell,.auth-card,dialog:not(:has(.hk-work))) :is(.notice,.secret,.detail-grid div,.ws-notice,.ws-search-result,.nx-note,.nx-preview,.nx-linkbar,.nx-message,.prod-message,.column,.lead-card,.ws-card-tabs,.form-actions) {
  background:#f3e5dd;color:var(--hk-ink);border-color:var(--hk-edge)
}
body :is(.shell,.auth-card,dialog) :is(.metric-icon,.ws-avatar){color:#762f48;background:#f1d8da}
body .shell .bar div {background:linear-gradient(90deg,#76324b,#c48b84)}
body .shell .header-right button,body .shell .titlebar button {background:#50343b;color:#fff4ea;border-color:#89666c}
body .shell .text-button:hover {background:#eed8d9;color:#642b40}
@media (max-width:980px) {
  body.auth-mode main {grid-template-columns:minmax(0,1fr);align-content:center;padding:24px}
  .auth-mode .veltrix-story {width:min(100%,460px);min-height:0;justify-self:center;padding:24px;text-align:left;align-items:flex-start}
  .auth-mode .veltrix-story h2 {font-size:clamp(24px,5vw,34px)}
}

body:not(.auth-mode) aside#sidebar.curved-rail {
  --rail-width:72px;
  position:fixed;inset:50% auto auto 12px;width:var(--rail-width);
  height:min(716px,calc(100dvh - 24px));padding:8px 10px;
  box-sizing:border-box;transform:translateY(-50%);border-radius:16px;
  isolation:isolate;overflow:hidden;z-index:40;color:#fff4ea;
  background:linear-gradient(176deg,#896650 0%,#573a30 20%,#2b201d 43%,#201919 69%,#63453d 100%);
  border:1px solid #d5afa1;box-shadow:inset 0 0 0 2px #f7d9c230,inset 0 0 16px #f9d0b72f,0 6px 26px #3a282644;
  transition:width 360ms cubic-bezier(.22,.75,.22,1);
}
body:not(.auth-mode) aside#sidebar.rail-expanded {--rail-width:266px}
body:not(.auth-mode) aside.curved-rail::before,body:not(.auth-mode) aside.curved-rail::after{
  content:'';pointer-events:none;position:absolute;z-index:-1;left:-85%;width:205%;height:28%;
  border-radius:50%;transform:rotate(12deg);top:25%;border-top:2px solid #ffdec3;
  filter:blur(1px);box-shadow:0 -4px 11px -4px #ffae69,inset 0 6px 14px -9px #ffd6aa
}
body:not(.auth-mode) aside.curved-rail::after{
  top:5%;left:-55%;transform:rotate(-5deg);border:0;border-bottom:2px solid #f6a699;
  box-shadow:0 6px 13px -7px #ff766c,inset 0 -7px 18px -10px #ff8273
}
.curved-rail .rail-top{display:flex;align-items:center;justify-content:center;position:relative;height:34px;flex-shrink:0;border-bottom:1px solid #f7d1b747}
.curved-rail .rail-top a{display:flex;gap:8px;align-items:center;color:#fff3e8;font-weight:650;font-size:14px;text-decoration:none}
.curved-rail .rail-top b,.curved-rail .rail-toggle,.curved-rail #nav :is(.ico,summary i),.curved-rail .rail-logout i{display:inline-grid;place-items:center;width:25px;height:25px;flex:0 0 25px;border-radius:7px;background:linear-gradient(145deg,#fff3,#fff1);font-style:normal;color:inherit}
.curved-rail .rail-top button{position:absolute;right:2px;min-height:26px;width:26px;padding:0;border:1px solid #ffe4c74d;color:#fff3e6}
.curved-rail>.logo,.curved-rail>.workspace,.curved-rail>.nav-label,.curved-rail .shield,.curved-rail .side-bottom>small{display:none}
.curved-rail>.profile{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:4px;padding:9px 0;margin:0;height:117px;flex-shrink:0;border:0;text-align:center;overflow:hidden}
.curved-rail>.profile i{display:grid;place-items:center;position:relative;width:49px;height:49px;background:linear-gradient(140deg,#2c1e28,#674447);border:2px solid #dbc1aa;color:#fff4df;border-radius:50%;font:600 16px/1 system-ui}
.curved-rail>.profile i::after{content:'';position:absolute;bottom:0;right:0;width:10px;height:10px;border:2px solid #4f4136;border-radius:50%;background:#32df87}
.curved-rail>.profile b,.curved-rail>.profile small{color:#fff1df;white-space:nowrap;display:block}.curved-rail>.profile small{font-size:10px;color:#dac4b7}
.curved-rail .nav-search{position:relative;margin:0 2px 6px;border-top:1px solid #f4d0b64a;padding-top:7px}
.curved-rail .nav-search:after{content:'⚲';position:absolute;left:11px;top:11px;transform:rotate(-45deg);pointer-events:none;color:#f6ddd1}
.curved-rail .nav-search input{min-height:32px;height:32px;padding:4px 10px 4px 34px;border:1px solid #dbc0b22f;border-radius:8px;background:#ffffff0c;color:#fff5e8}
.curved-rail #nav{overflow:auto;overflow-x:hidden;margin:0;padding:2px;scrollbar-width:thin;scrollbar-color:#ad928166 transparent}
.curved-rail #nav :is(a,button,summary),.curved-rail .rail-logout{display:flex;align-items:center;gap:10px;width:100%;margin:2px 0;padding:3px 6px;min-height:31px;height:auto;box-sizing:border-box;background:transparent;color:#eadbd1;border:1px solid transparent;border-radius:8px;white-space:nowrap;text-decoration:none;font:500 13px/1.3 system-ui;text-align:left;cursor:pointer}
.curved-rail #nav summary{list-style:none}.curved-rail #nav summary::-webkit-details-marker{display:none}
.curved-rail #nav summary::after{content:'›';margin-left:auto;transition:rotate .2s}.curved-rail #nav details[open]>summary::after{rotate:90deg}
.curved-rail #nav :is(a,button,summary):hover,.curved-rail #nav a.active,.curved-rail #nav .rail-current>summary{color:#fff5e6;background:linear-gradient(100deg,#fff4,#ffe2c710);border-color:#fbe2d454;box-shadow:inset 2px 0 #f7d9be}
.curved-rail #nav a.active .ico,.curved-rail #nav .rail-current>summary i{background:#ffead3;color:#4e382f}
.curved-rail #nav [hidden]{display:none}
.curved-rail #nav .rail-children{margin-left:20px;padding-left:9px;border-left:1px solid #e8cbb15e}
.curved-rail #nav .rail-children :is(a,button){min-height:26px;font-size:12px;white-space:normal}
.curved-rail #nav .rail-children .ico{display:none}
.curved-rail #nav [data-action="hakko-open"]::before{content:'H';display:grid;place-items:center;width:25px;flex:0 0 25px;height:25px;border-radius:7px;background:#ffffff20}
.curved-rail .side-bottom{margin:5px 0 0;padding:6px 0 0;border-top:1px solid #e3c2b54d}
.curved-rail .rail-logout{margin-top:5px}
@media(min-width:981px){
  body:not(.auth-mode) .shell{margin-left:96px}
  .curved-rail:not(.rail-expanded) .rail-top a,.curved-rail:not(.rail-expanded)>.profile div,.curved-rail:not(.rail-expanded) #nav summary span,.curved-rail:not(.rail-expanded) #nav summary::after,.curved-rail:not(.rail-expanded) .rail-children,.curved-rail:not(.rail-expanded) .rail-logout span{display:none}
  .curved-rail:not(.rail-expanded) .rail-toggle{right:50%;transform:translateX(50%)}
  .curved-rail:not(.rail-expanded) #nav :is(a,button){font-size:0;gap:0}
  .curved-rail:not(.rail-expanded) #nav [data-action="hakko-open"]::before{font-size:13px}
  .curved-rail:not(.rail-expanded) #nav :is(a,button,summary),.curved-rail:not(.rail-expanded) .rail-logout{justify-content:center}
  .curved-rail:not(.rail-expanded) .nav-search input::placeholder{color:transparent}
}
@media(max-width:980px){
  body:not(.auth-mode) aside#sidebar.curved-rail{--rail-width:266px;transform:translate(-115%,-50%);visibility:hidden}
  body.nav-open:not(.auth-mode) aside#sidebar.curved-rail{transform:translate(0,-50%);visibility:visible}
  .curved-rail .rail-toggle{display:none}
  .curved-rail #menu-close{position:absolute;right:10px;top:10px;z-index:2;min-height:26px;width:26px;height:26px;padding:0;background:#ffffff18;color:#fff}
}
@media(prefers-reduced-motion:reduce){body:not(.auth-mode) aside#sidebar.curved-rail{transition:none}}
body:not(.auth-mode) aside#sidebar.curved-rail {
 clip-path:polygon(5% 0,95% 0,99% .8%,100% 2%,99% 14%,97.8% 30%,97.2% 48%,97.6% 65%,98.8% 83%,100% 98%,99% 99.3%,95% 100%,5% 100%,1% 99.3%,0 98%,1.2% 83%,2.4% 65%,2.8% 48%,2.2% 30%,1% 14%,0 2%,1% .8%);
 background-image:radial-gradient(ellipse 4% 79% at -1% 49%,#ffe8d6a8 83%,#fce5cc36 95%,transparent),radial-gradient(ellipse 4% 79% at 101% 49%,#ffe8d6a8 83%,#fce5cc36 95%,transparent),linear-gradient(176deg,#896650,#573a30 20%,#2b201d 43%,#201919 69%,#63453d);
}
.curved-rail .rail-settings{display:flex;align-items:center;gap:10px;width:100%;margin:5px 0 0;padding:3px 6px;min-height:31px;color:#eadbd1;border:1px solid transparent;background:transparent;text-align:left;font:500 13px/1.3 system-ui}
.curved-rail .rail-settings i{display:inline-grid;place-items:center;width:25px;height:25px;border-radius:7px;background:#ffffff16;color:#fff4ea;font-style:normal}
body:not(.auth-mode) .curved-rail #nav :is(a,button,summary){min-height:31px;margin:2px 0}
body:not(.auth-mode) .curved-rail #nav :is(a,button):not(:hover):not(.active){color:#eadbd1}
@media(min-width:981px){.curved-rail:not(.rail-expanded) .rail-settings{justify-content:center}.curved-rail:not(.rail-expanded) .rail-settings span{display:none}}

/* Width samples from frames 22–34 at 30 fps. */
body:not(.auth-mode) aside#sidebar.curved-rail {
  transition:width 400ms linear(0,.087 8.33%,.322 16.67%,.639 25%,.858 33.33%,.907 41.67%,.94 50%,.962 58.33%,.978 66.67%,.989 75%,.995 83.33%,1);
}
.curved-rail #nav details {interpolate-size:allow-keywords}
.curved-rail #nav details::details-content {
  block-size:0;opacity:0;overflow:clip;
  transition:block-size 205ms cubic-bezier(.27,.05,.22,1), opacity 150ms ease,content-visibility 205ms allow-discrete;
}
.curved-rail #nav details[open]::details-content {block-size:auto;opacity:1}
.curved-rail #nav details[open] .rail-children > * {animation:rail-child-in 160ms ease-out backwards}
.curved-rail #nav details[open] .rail-children > :nth-child(2){animation-delay:25ms}
.curved-rail #nav details[open] .rail-children > :nth-child(n+3){animation-delay:45ms}
@keyframes rail-child-in {from{opacity:0;transform:translateY(-4px)}}
.curved-rail .rail-marker {
  position:absolute;left:0;top:0;pointer-events:none;box-sizing:border-box;
  border:1px solid #fff0dd69;border-radius:8px;
  background:linear-gradient(100deg,#fff1dc36,#fff3df0b);
  box-shadow:inset 2px 0 #f7d9be;
  transition:transform 230ms cubic-bezier(.32,.08,.23,1),width 180ms ease-out,height 170ms ease-out;
}
.curved-rail .rail-marker[hidden]{display:none}
body:not(.auth-mode) .curved-rail #nav a.active,
body:not(.auth-mode) .curved-rail #nav .rail-current>summary {background:transparent;box-shadow:none;border-color:transparent}
@media(min-width:981px){
 .curved-rail.rail-expanded :is(.profile div,.rail-top a,#nav summary span,.rail-logout span,.rail-settings span){animation:rail-label-in 190ms 40ms both}
 @keyframes rail-label-in {from{opacity:0;transform:translateX(-4px)}}
}
@media(prefers-reduced-motion:reduce){
 body:not(.auth-mode) aside#sidebar.curved-rail,.curved-rail .rail-marker,.curved-rail #nav details::details-content{transition:none}
 .curved-rail #nav details[open] .rail-children > *,.curved-rail.rail-expanded :is(.profile div,.rail-top a,#nav summary span,.rail-logout span,.rail-settings span){animation:none}
}

.header-right:has(.command-dock){display:flex;align-items:center;gap:12px;flex-wrap:nowrap}
.command-dock{position:relative;display:flex;align-items:center;isolation:isolate;padding:4px;gap:1px;border-radius:99px;background:linear-gradient(170deg,#28252a,#242122 58%,#423c38);border:1px solid #fff8;box-shadow:inset 0 1px 2px #fff3,0 5px 16px #21181940}
body .shell .header-right .command-dock>button{z-index:1;display:inline-flex;align-items:center;justify-content:center;gap:7px;min-width:0;min-height:37px;margin:0;padding:5px 12px;border:0;border-radius:99px;background:transparent;color:#fff4ea;font:500 13px/1.2 system-ui;white-space:nowrap;box-shadow:none}
.command-dock svg{width:16px;height:16px;flex:none}
.command-dock kbd{display:none}.command-dock .ws-count{font-size:10px;min-width:14px;height:14px;padding:0 3px}
.command-indicator{position:absolute;left:0;top:4px;bottom:4px;border-radius:99px;border:1px solid #fff9;background:linear-gradient(150deg,#535057,#29262d);box-shadow:0 2px 6px #0007,inset 0 1px 2px #fffa;transition:transform 245ms cubic-bezier(.22,.85,.25,1),width 225ms}
.command-dock{margin-inline-end:54px}.command-orbit{position:absolute;left:calc(100% + 8px);top:50%;width:46px;height:46px;transform:translateY(-50%);transition:top 240ms cubic-bezier(.2,.8,.2,1),left 240ms cubic-bezier(.2,.8,.2,1);z-index:3}
.command-orbit.is-open{left:calc(100% - 78px);top:calc(100% + 110px)}
body .shell .header-right .command-orbit button{position:absolute;inset:0;display:grid;place-items:center;min-height:0;min-width:0;margin:0;padding:0;border-radius:50%;border:1px solid #f9ecdcaa;color:white;box-shadow:inset 0 1px 3px #ffffff5c,0 3px 8px #2c202354}
body .shell .header-right .command-trigger{z-index:2;background:linear-gradient(145deg,#49464b,#252328 75%);outline-offset:3px}
.command-trigger svg{width:21px;height:21px;transition:transform 220ms}.is-open .command-trigger svg{transform:rotate(45deg)}
body .shell .header-right .command-satellite{inset:3px;background:linear-gradient(140deg,color-mix(in srgb,var(--tint) 75%,white),color-mix(in srgb,var(--tint) 62%,#38333c));opacity:0;transform:scale(.3);pointer-events:none;transition:transform 250ms cubic-bezier(.22,.82,.22,1),opacity 170ms}
body .shell .header-right .is-open .command-satellite{opacity:1;pointer-events:auto;transform:translate(var(--dx),var(--dy)) scale(1)}
body .shell .header-right .is-open .command-satellite:hover{filter:brightness(1.12)}
@media(max-width:850px){body .shell .header-right .command-dock>button{font-size:0;padding-inline:9px;gap:0}.header-right:has(.command-dock)>span{display:none}}
@media(max-width:480px){body .shell header:has(.command-dock){padding-inline:8px;gap:4px}.shell header:has(.command-dock) #crumb{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}}
@media(prefers-reduced-motion:reduce){.command-indicator,.command-orbit,.command-trigger svg,body .shell .header-right .command-satellite{transition:none}}

body .shell .ws-day-metrics.metric-carousel {
  display:block;position:relative;overflow:hidden;isolation:isolate;
  height:clamp(240px,27vw,390px);margin:0 0 24px;padding:0;
  background:linear-gradient(125deg,#f8f6f7,#ecebf0 58%,#f7f5f6);
  border-radius:14px;touch-action:pan-y;user-select:none
}
.metric-carousel canvas{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
body .shell .metric-carousel a.card{position:absolute;display:block;margin:0;padding:0;background:transparent;border:none;box-shadow:none;border-radius:12px;-webkit-user-drag:none}
body .shell .metric-carousel a.card::before{display:none}
body .shell .metric-carousel a.card>*{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
body .shell .metric-carousel a.card:focus-visible{outline:2px solid #663a51;outline-offset:3px}
.metric-carousel .metric-modes{position:absolute;inset:10px auto auto 12px;display:flex;gap:3px;z-index:2}
body .shell .metric-carousel .metric-modes button{min-height:28px;padding:4px 9px;border:0;border-radius:20px;background:transparent;color:#655e67;font:500 12px system-ui}
body .shell .metric-carousel .metric-modes button[aria-pressed=true]{background:#fffc;color:#29232b;box-shadow:0 1px 5px #31243620}

/* Dashboard V63 work area. All surfaces are scoped below the signed-in shell. */
body:not(.auth-mode) #main,body:not(.auth-mode) #modal {
 --ink:#2c1c21;--muted:#665253;--line:#cbb6ae;--brand:#812344;
 --surface:#f2e3dc;--bg:#e5cdc0;--accent:#ead1d4;--ws-teal:#812344;
 color:var(--ink);color-scheme:light
}
body:not(.auth-mode) #main {
 min-height:calc(100dvh - 90px);max-width:1800px;margin:12px auto;
 padding:clamp(18px,2.4vw,36px);border:1px solid #fff6;border-radius:22px;
 background:
 radial-gradient(ellipse at 86% 4%,#eacdc8 0,transparent 36%),
 radial-gradient(ellipse at 63% 8%,#976c5a 0,transparent 32%),
 radial-gradient(ellipse at 3% 55%,#a78070 0,transparent 40%),
 linear-gradient(120deg,#c1a397,#d9bbb2 48%,#c7a18e 80%,#e6d3c6);
}
body:not(.auth-mode) #main .titlebar {background:none;border:0;border-radius:0;box-shadow:none;padding:0;margin:0 0 18px;color:var(--ink);align-items:flex-start}

body:not(.auth-mode) #main .titlebar .sub{color:#5d4949;margin-top:6px}
body:not(.auth-mode) :is(#main,#modal) :is(.panel,.nx-card,.prod-card,.lead-card,.column,.ws-notice,.ws-search-result,.nx-note,.hub-blockers,.hub-approval),
body:not(.auth-mode) #main .cards>.card {
 background:linear-gradient(125deg,#fff6f0dc,#e8d0cae0 78%,#f0dfdae8);
 border:1px solid #fff7;border-radius:18px;color:var(--ink);
 box-shadow:inset 0 1px 0 #fff6,0 5px 16px #63373112;
}
body:not(.auth-mode) :is(#main,#modal) .panel-head{padding:var(--crm-panel-y,16px) var(--crm-panel-x,20px);border-color:#805a5a26;background:transparent}
body:not(.auth-mode) :is(#main,#modal) .panel-body{padding:var(--crm-panel-y,16px) var(--crm-panel-x,20px)}
body:not(.auth-mode) :is(#main,#modal) :is(th,.ws-table th){background:#e8d4cd;color:#504044;border-color:#bfa6a04f}
body:not(.auth-mode) :is(#main,#modal) :is(td,.ws-table td){background:#fcf4efc9;color:#322428;border-color:#bfa6a04f}
body:not(.auth-mode) :is(#main,#modal) tbody tr:hover td{background:#f2dedd}
body:not(.auth-mode) :is(#main,#modal) :is(button,.button){border-radius:999px}
body:not(.auth-mode) :is(#main,#modal) :is(.actions button,.toolbar button,.form-actions button,.panel-head button,.ws-views button,.ws-secondary-actions button,.nx-tabs button){background:#f8ece5;color:#442d33;border-color:#bea099}
body:not(.auth-mode) :is(#main,#modal) :is(button.primary,.actions .primary,.form-actions .primary,.ws-views [aria-pressed=true],.nx-tabs .active){background:#2b2023;color:#fff4ed;border-color:#35282c}
body:not(.auth-mode) :is(#main,#modal) :is(.detail-grid div,.notice,.nx-preview,.nx-linkbar,.nx-step,.prod-empty,.ws-card-tabs,.ws-day-item,.prod-message,.nx-message){color:#38262d;border-color:#cdb6ae}
body:not(.auth-mode) :is(#main,#modal) :is(.detail-grid div,.notice,.nx-preview,.nx-linkbar,.nx-step,.prod-empty,.ws-card-tabs,.prod-message,.nx-message){background:#f3e3da}
body:not(.auth-mode) #modal:not(:has(.hk-work)){background:linear-gradient(130deg,#f9eee8,#e8d1c9);box-shadow:0 20px 70px #48293555;border:1px solid #fff8}
body:not(.auth-mode) #main .cards{gap:12px}
body:not(.auth-mode) #main .cards>.card{position:relative;padding:16px 18px;display:flex;flex-direction:column;justify-content:center;min-height:120px;transition:transform 180ms ease,box-shadow 180ms}
body:not(.auth-mode) #main .cards>.card::before{display:none}
body:not(.auth-mode) #main .cards>.card:nth-child(3){background:linear-gradient(135deg,#a1365a,#681832);color:#fff3ec}
body:not(.auth-mode) #main .cards>.card:nth-child(3) :is(.value,.metric-label,.trend){color:inherit}
body:not(.auth-mode) #main .cards .metric-label{order:2;font-weight:650;color:#402c32}
body:not(.auth-mode) #main .cards .value{order:1;font-size:clamp(24px,2.5vw,39px);line-height:1.3}
body:not(.auth-mode) #main .cards .trend{order:3;font-size:12px}
.v63-overview,.v63-clients{display:grid;grid-template-columns:minmax(0,2fr) minmax(240px,1fr);gap:14px;margin-bottom:16px}
.v63-hero{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:clamp(22px,3vw,48px);min-height:235px;color:#fff6ee;border-radius:18px;
 background:radial-gradient(ellipse at 92% 10%,#a25572,transparent 49%),linear-gradient(130deg,#a34a65,#811c41 50%,#57132f);box-shadow:inset 0 1px #fff3,0 8px 26px #63373124}
.v63-hero h2{color:inherit;margin:12px 0 4px;font-size:clamp(26px,3vw,44px);letter-spacing:-.04em}
.v63-hero p{color:#f2d1d9;margin:6px 0 16px}
.v63-hero small{display:inline-block;background:#ffffff1a;border-radius:30px;padding:3px 10px}
body:not(.auth-mode) #main .v63-hero .button{display:inline-flex;align-items:center;background:#fff2e9;color:#4b2032;border:0;text-decoration:none;padding:6px 16px;min-height:36px}
.v63-ring,.v63-donut{display:grid;place-items:center;aspect-ratio:1;border-radius:50%;flex:none}
.v63-ring{width:clamp(82px,9vw,145px);background:conic-gradient(#fff4ec var(--sweep),#ffffff36 0)}
.v63-ring b,.v63-donut strong{width:86%;aspect-ratio:1;border-radius:50%;display:grid;place-items:center;background:#782544;color:white;font-size:clamp(22px,2.5vw,38px)}
body:not(.auth-mode) #main .v63-agenda{padding:18px 20px;margin:0}.v63-agenda h2{margin:0;text-transform:capitalize}.v63-agenda small,.v63-agenda p{color:#695354}
.v63-agenda>div{display:flex;gap:10px;align-items:center;margin-top:6px;border-radius:9px;padding:6px 8px;background:#fff7f08f;font-size:13px}.v63-agenda time{border-right:2px solid #a34a65;padding-right:8px}
.v63-ranking{padding:12px 20px}.v63-ranking>div{display:grid;grid-template-columns:minmax(80px,1fr) 2fr 3ch;gap:12px;align-items:center;margin:10px 0;font-size:13px}
.v63-ranking i{height:7px;background:#a580781f;border-radius:9px}.v63-ranking b{display:block;height:100%;border-radius:inherit}
.v63-donut{width:128px;margin:18px auto}.v63-donut strong{background:#ecd9d1;color:#453036;font-size:24px}
.v63-columns{padding:12px 24px 20px;display:flex;align-items:end;gap:14px;min-height:170px;overflow-x:auto}.v63-columns>div{flex:1;min-width:64px;display:grid;justify-items:center;gap:6px;font-size:12px;text-align:center}.v63-columns i{width:min(42px,75%);border-radius:7px;background:repeating-linear-gradient(130deg,#982f53 0 3px,#b45571 3px 5px)}
@media(hover:hover) and (prefers-reduced-motion:no-preference){body:not(.auth-mode) #main .cards>.card:hover{transform:translateY(-5px);box-shadow:0 9px 22px #63373129}}
@media(prefers-reduced-motion:no-preference){body:not(.auth-mode) #main.v63-enter{animation:v63-enter .42s ease-out both}@keyframes v63-enter{from{opacity:.55;filter:blur(4px);transform:translateY(4px)}to{opacity:1;filter:blur(0);transform:none}}}
@media(max-width:720px){.v63-overview,.v63-clients{grid-template-columns:minmax(0,1fr)}.v63-hero{min-height:170px}body:not(.auth-mode) #main{padding:16px 12px;margin:6px 0; border-radius:14px}}

body:not(.auth-mode) #main:has(.v63-queue,.v63-day-stats){max-width:1390px;padding:clamp(16px,2vw,30px);margin:14px auto;min-height:calc(100dvh - 110px)}
body:not(.auth-mode) #main .v63-queue-filter{margin:0;padding:16px 18px}
.v63-queue-filter h2{margin:0 0 8px;font-size:17px}
.v63-queue-filter #hub-filter{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px 8px;align-items:center}
.v63-queue-filter #hub-filter .field{min-width:0;font-size:12px}
.v63-queue-filter #hub-filter :is(input:not([type=checkbox]),select){width:100%;min-height:33px;padding:4px 8px;font-size:13px}
.v63-queue-filter #hub-filter>label:not(.field){padding:0;font-size:12px}
.v63-queue-filter #hub-filter button{grid-column:1/-1;min-height:30px}
#main .v63-queue .v63-hero button{background:#fff3ec;color:#552439;min-height:34px;border:0}
body:not(.auth-mode) #main:has(.v63-queue) .empty{min-height:0;padding:14px}
body:not(.auth-mode) #main:has(.v63-queue) .empty::before{display:none}
body:not(.auth-mode) #main:has(.v63-queue) .ws-pagination{margin:10px 0}
body:not(.auth-mode) #main .v63-day-stats a.card{align-items:flex-start;gap:4px;text-decoration:none}
body:not(.auth-mode) #main .v63-day-stats a.card:nth-child(3){color:#fff4ed}
.v63-day-stats .card strong{font-size:30px;line-height:1.15}
.v63-carousel-switch{margin:0 0 14px}.v63-carousel-switch summary{width:fit-content;cursor:pointer;color:#593c43;font-size:13px}.v63-carousel-switch[open] summary{margin-bottom:8px}
@media(min-width:950px){.v63-queue{grid-template-columns:minmax(0,1.9fr) minmax(330px,1fr)}}

body:not(.auth-mode) #main .v63-overview:not(.v63-queue){grid-template-columns:minmax(0,2fr) minmax(240px,1fr);gap:clamp(10px,1.3vw,20px)}
body:not(.auth-mode) #main .v63-overview:not(.v63-queue) .v63-hero{min-height:clamp(235px,21vw,335px);padding:clamp(20px,2.4vw,36px);background:radial-gradient(ellipse at 86% 12%,#a05c75aa,transparent 58%),linear-gradient(115deg,#963951,#760a37 54%,#5b102e)}
.v63-task-counts{display:flex;gap:20px;margin:12px 0}.v63-task-counts div{display:flex;flex-direction:column-reverse;border-left:1px solid #fff4;padding-left:9px}.v63-task-counts dt{font-size:11px;color:#f2d6dc}.v63-task-counts dd{margin:0;font-size:19px;color:#fff4ed}
body:not(.auth-mode) #main .v63-agenda{display:flex;flex-direction:column;justify-content:flex-start;background:linear-gradient(125deg,#f8e4dfd9,#d6b7b3db)}
.v63-agenda>.v63-date,.v63-agenda>.v63-week{background:none;padding:0;margin:0}.v63-date>strong{font-size:clamp(38px,3vw,56px);letter-spacing:-.06em;line-height:1;color:#852345}.v63-date h2{font-size:17px}
.v63-agenda>.v63-week{display:grid;grid-template-columns:repeat(7,1fr);gap:2px;background:#fff5ee73;border-radius:10px;padding:4px;margin:12px 0 6px}
.v63-week span{display:grid;justify-items:center;gap:2px;padding:4px 0;font-size:13px;border-radius:8px}.v63-week span[aria-current]{background:#822245;color:white}.v63-week span[aria-current] small{color:#f9dbe3}.v63-week small{font-size:10px}
.v63-agenda .v63-no-event{padding:10px;border-radius:8px;background:#fff4ed70;font-size:13px}
body:not(.auth-mode) #main .cards>.card:has(.v63-stat-icon){min-height:clamp(142px,13vw,196px);padding:clamp(14px,1.6vw,24px);justify-content:flex-end;background:linear-gradient(135deg,#f2dfd9d9,#d4b8b2df)}
body:not(.auth-mode) #main .cards>.card:nth-child(3):has(.v63-stat-icon){background:linear-gradient(140deg,#953251,#651536)}
.v63-stat-icon{align-self:flex-start;display:grid;place-items:center;width:30px;height:30px;margin-bottom:auto;border-radius:50%;background:#fff5efb8;color:#543d44;font-size:16px}
.v63-neutral{background:#baa19d}
@media(max-width:720px){body:not(.auth-mode) #main .v63-overview:not(.v63-queue){grid-template-columns:1fr}}

/* Code XR · Dashboard V63: workspace components from the supplied HTML. */
body:not(.auth-mode) #main#main{
 --ink:#1c1416;--mute:#8a7377;--muted:var(--mute);--wine:#8e1f40;--green:#1f9d62;--red:#d23b4a;
 background:linear-gradient(rgba(255,240,236,.55),rgba(255,240,236,.55)),radial-gradient(70% 60% at 20% 90%,#a98a7b 0,transparent 70%),radial-gradient(60% 60% at 85% 10%,#e9ddd3 0,transparent 70%),linear-gradient(135deg,#6c5a55,#b9a094 55%,#8a6f66);
 backdrop-filter:blur(30px);border:0;border-radius:32px;padding:22px 20px;font:13px/1.4 Inter,system-ui,sans-serif;color:var(--ink)
}
body:not(.auth-mode) #main .titlebar h1{margin:0;font:600 clamp(24px,2.4vw,30px)/1.16 Inter,system-ui,sans-serif;letter-spacing:-.025em}
body:not(.auth-mode) #main .panel{background:linear-gradient(160deg,rgba(255,246,243,.78),rgba(244,225,220,.62));border:0;border-radius:24px;box-shadow:0 1px 0 rgba(255,255,255,.7) inset,0 10px 30px rgba(80,30,40,.12)}
body:not(.auth-mode) #main .xr-view :where(h2,h3,p){margin:0}
body:not(.auth-mode) #main .xr-view .hd{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:16px;flex-wrap:wrap}
body:not(.auth-mode) #main .xr-view h1{font-size:30px;font-weight:600;letter-spacing:-.02em}
body:not(.auth-mode) #main .xr-view .sub{color:var(--mute);margin-top:4px}
body:not(.auth-mode) #main .xr-view .btn{background:rgba(255,235,228,.7);border-radius:99px;padding:9px 16px;font-weight:500}
body:not(.auth-mode) #main .xr-view .btn.dk{background:#161012;color:#fff}
body:not(.auth-mode) #main .xr-view .seg{display:inline-flex;background:rgba(255,245,242,.7);border-radius:99px;padding:3px}
body:not(.auth-mode) #main .xr-view .seg button{padding:6px 14px;border-radius:99px;font-weight:500;color:#5b4a4e}
body:not(.auth-mode) #main .xr-view .seg button.on{background:#161012;color:#fff}
body:not(.auth-mode) #main .xr-view .g{display:grid;gap:14px}
body:not(.auth-mode) #main .xr-view .c{background:linear-gradient(160deg,rgba(255,246,243,.78),rgba(244,225,220,.62));border-radius:24px;padding:18px;box-shadow:0 1px 0 rgba(255,255,255,.7) inset,0 10px 30px rgba(80,30,40,.12);min-width:0}
body:not(.auth-mode) #main .xr-view .c.w{background:linear-gradient(135deg,#7e1636,#b23a56);color:#fff}
body:not(.auth-mode) #main .xr-view .top{grid-template-columns:2fr 1fr}
body:not(.auth-mode) #main .xr-view .hero{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:22px}
body:not(.auth-mode) #main .xr-view .pill{display:inline-block;background:rgba(255,255,255,.16);border-radius:99px;padding:4px 10px;font-size:11px;margin-bottom:16px}
body:not(.auth-mode) #main .xr-view .hero h2{font-size:30px;line-height:1.1;font-weight:600;letter-spacing:-.02em;max-width:360px}
body:not(.auth-mode) #main .xr-view .hero h2 em{font:italic 34px "Instrument Serif",Georgia,serif;font-weight:400}
body:not(.auth-mode) #main .xr-view .hero p{opacity:.85;margin:10px 0 16px;max-width:340px}
body:not(.auth-mode) #main .xr-view .kp{display:flex;gap:22px;margin-bottom:16px}
body:not(.auth-mode) #main .xr-view .kp b{font-size:16px;display:block}
body:not(.auth-mode) #main .xr-view .kp span{font-size:10px;opacity:.6}
body:not(.auth-mode) #main .xr-view .hb{background:#fff;color:var(--ink);border-radius:99px;padding:8px 16px;font-weight:600;margin-right:8px}
body:not(.auth-mode) #main .xr-view .hb.o{background:none;color:#fff;border:1px solid rgba(255,255,255,.5);font-weight:500}
body:not(.auth-mode) #main .xr-view .ring{position:relative;width:150px;height:150px;flex:none}
body:not(.auth-mode) #main .xr-view .ring b{position:absolute;inset:0;display:grid;place-content:center;text-align:center;font-size:26px;font-weight:600}
body:not(.auth-mode) #main .xr-view .ring b small{font-size:10px;font-weight:400;opacity:.7}
body:not(.auth-mode) #main .xr-view .cal .d{display:flex;gap:10px;align-items:center;margin-bottom:12px}
body:not(.auth-mode) #main .xr-view .cal .d big{font-size:34px;font-weight:600;color:var(--wine)}
body:not(.auth-mode) #main .xr-view .cal .d small{display:block;color:var(--mute);font-size:11px}
body:not(.auth-mode) #main .xr-view .wk{display:grid;grid-template-columns:repeat(7,1fr);background:rgba(255,255,255,.5);border-radius:16px;padding:6px;text-align:center;font-size:11px;margin-bottom:10px}
body:not(.auth-mode) #main .xr-view .wk div{padding:4px 0;color:#6a565a}
body:not(.auth-mode) #main .xr-view .wk div b{display:block;font-size:12px;color:var(--ink)}
body:not(.auth-mode) #main .xr-view .wk .t{background:var(--wine);color:#fff;border-radius:10px}
body:not(.auth-mode) #main .xr-view .wk .t b{color:#fff}
body:not(.auth-mode) #main .xr-view .ev{display:flex;gap:10px;align-items:center;background:rgba(255,255,255,.55);border-radius:12px;padding:9px 10px;margin-bottom:7px;font-size:11px}
body:not(.auth-mode) #main .xr-view .ev i{width:3px;height:26px;border-radius:2px}
body:not(.auth-mode) #main .xr-view .ev b{display:block;font-size:12px}
body:not(.auth-mode) #main .xr-view .ev small{color:var(--mute)}
body:not(.auth-mode) #main .xr-view .nx{margin-left:auto;background:#f4d9d6;color:var(--wine);border-radius:99px;padding:2px 8px;font-size:10px}
body:not(.auth-mode) #main .xr-view .st{grid-template-columns:repeat(4,1fr);margin-top:14px}
body:not(.auth-mode) #main .xr-view .sc{height:170px;display:flex;flex-direction:column;justify-content:space-between}
body:not(.auth-mode) #main .xr-view .sc .r{display:flex;justify-content:space-between}
body:not(.auth-mode) #main .xr-view .ic{width:30px;height:30px;border-radius:50%;background:rgba(255,255,255,.8);display:grid;place-items:center;font-size:12px}
body:not(.auth-mode) #main .xr-view .w .ic{background:rgba(255,255,255,.2)}
body:not(.auth-mode) #main .xr-view .ch{font-size:10px;border-radius:99px;padding:3px 8px;height:fit-content;font-weight:600}
body:not(.auth-mode) #main .xr-view .up{background:#e0f5e9;color:var(--green)}
body:not(.auth-mode) #main .xr-view .dn{background:#fbe0e2;color:var(--red)}
body:not(.auth-mode) #main .xr-view .sc strong{font-size:30px;letter-spacing:-.02em;display:block;margin-bottom:4px}
body:not(.auth-mode) #main .xr-view .sc small{display:block;opacity:.7;font-size:11px}
body:not(.auth-mode) #main .xr-view .sc svg{position:absolute;right:16px;bottom:18px}
body:not(.auth-mode) #main .xr-view .sc{position:relative}
body:not(.auth-mode) #main .xr-view .chart{margin-top:14px}
body:not(.auth-mode) #main .xr-view .ch-h{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}
body:not(.auth-mode) #main .xr-view .lg{display:flex;gap:12px;margin:8px 0;font-size:11px}
body:not(.auth-mode) #main .xr-view .lg i{display:inline-block;width:7px;height:7px;border-radius:50%;margin-right:5px}
body:not(.auth-mode) #main .xr-view .bars{display:flex;align-items:flex-end;gap:10px;height:290px;padding-left:36px;position:relative;border-bottom:1px solid rgba(0,0,0,.05)}
body:not(.auth-mode) #main .xr-view .yl{position:absolute;left:0;top:0;bottom:0;display:flex;flex-direction:column;justify-content:space-between;font-size:10px;color:var(--mute)}
body:not(.auth-mode) #main .xr-view .bc{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;height:100%;gap:4px}
body:not(.auth-mode) #main .xr-view .bc .p{width:min(44px,60%);border-radius:10px;background:repeating-linear-gradient(135deg,#c33a5c 0 3px,#8e1f40 3px 6px);border:1px solid #d46784}
body:not(.auth-mode) #main .xr-view .bc .k{width:min(44px,60%);border-radius:10px;background:#120d0f}
body:not(.auth-mode) #main .xr-view .bc span{font-size:10px;color:var(--mute);position:absolute;bottom:-20px}
body:not(.auth-mode) #main .xr-view .bars{margin-bottom:26px}
body:not(.auth-mode) #main .xr-view .bc{position:relative}
body:not(.auth-mode) #main .xr-view .cl{grid-template-columns:2fr 1fr}
body:not(.auth-mode) #main .xr-view .row{display:flex;align-items:center;gap:12px;margin:14px 0;font-size:12px}
body:not(.auth-mode) #main .xr-view .row .n{width:150px;display:flex;gap:10px;align-items:center;font-weight:500}
body:not(.auth-mode) #main .xr-view .row .tr{flex:1;height:7px;border-radius:9px;background:rgba(0,0,0,.08)}
body:not(.auth-mode) #main .xr-view .row .tr i{display:block;height:100%;border-radius:9px}
body:not(.auth-mode) #main .xr-view .row b{width:54px;text-align:right}
body:not(.auth-mode) #main .xr-view .bg{width:26px;height:26px;border-radius:8px;color:#fff;display:grid;place-items:center;font-size:9px;font-weight:700;flex:none}
body:not(.auth-mode) #main .xr-view .dl{display:grid;grid-template-columns:1fr 1fr;gap:12px 14px;font-size:11px;margin-top:10px}
body:not(.auth-mode) #main .xr-view .dl b{display:block;font-size:12px}
body:not(.auth-mode) #main .xr-view .dl span{display:flex;gap:6px}
body:not(.auth-mode) #main .xr-view .dl i{width:7px;height:7px;border-radius:50%;margin-top:4px;flex:none}
body:not(.auth-mode) #main .xr-view .si{background:rgba(255,235,228,.7);border-radius:99px;padding:10px 16px;width:min(340px,100%);margin:14px 0;color:var(--mute)}
body:not(.auth-mode) #main .xr-view .cg{grid-template-columns:repeat(4,1fr)}
body:not(.auth-mode) #main .xr-view .cc .tp{display:flex;justify-content:space-between;margin-bottom:12px}
body:not(.auth-mode) #main .xr-view .cc .bg{width:42px;height:42px;border-radius:13px;font-size:15px}
body:not(.auth-mode) #main .xr-view .tg{font-size:10px;border-radius:99px;padding:3px 8px;height:fit-content;font-weight:600}
body:not(.auth-mode) #main .xr-view .cc h3{font-size:15px}
body:not(.auth-mode) #main .xr-view .cc p{color:var(--mute);font-size:11px;margin:2px 0 12px}
body:not(.auth-mode) #main .xr-view .cc .m{background:rgba(255,255,255,.7);border-radius:12px;padding:10px;display:flex;justify-content:space-between;font-weight:600}


body:not(.auth-mode) #main .xr-view{margin-bottom:14px}
body:not(.auth-mode) #main .xr-view .hero a.hb{display:inline-block;text-decoration:none}
body:not(.auth-mode) #main .xr-view .hero button.hb{min-height:0;font:inherit}
body:not(.auth-mode) #main .xr-view .cg button.cc{text-align:left;color:var(--ink)}
body:not(.auth-mode) #main .xr-view .bars{overflow-x:auto;overflow-y:hidden;padding-bottom:24px}
body:not(.auth-mode) #main .xr-view .bc{min-width:45px}
@media(max-width:1000px){body:not(.auth-mode) #main .xr-view :is(.top,.cl){grid-template-columns:1fr}body:not(.auth-mode) #main .xr-view :is(.st,.cg){grid-template-columns:1fr 1fr}}
@media(max-width:560px){body:not(.auth-mode) #main .xr-view :is(.st,.cg){grid-template-columns:1fr}body:not(.auth-mode) #main .xr-view .hero{flex-direction:column;align-items:flex-start}}

/* Glassy Login Form v3 */
body.auth-mode,body.auth-mode .shell,body.auth-mode #main{
 background-color:#05090d;color:#e5f3fc;color-scheme:dark
}
body.auth-mode #main{
 display:grid;place-items:center;grid-template-columns:minmax(0,1fr);margin:0;max-width:none;
 min-height:100dvh;padding:32px 16px;isolation:isolate;overflow:hidden;
 background:
 radial-gradient(ellipse 138% 82% at 110% -15%,transparent 68%,#465962 68.3%,#10171e 69%,#06090c 70%,#1d4e60 71%,#05090d 72%,transparent 73%),
 radial-gradient(ellipse 140% 85% at 105% -32%,transparent 90%,#326272 90.5%,#1294bb 91%,#163847 94%,#0b1117 95%,#414d56 95.6%,transparent 96%),
 radial-gradient(ellipse 125% 115% at -45% 152%,#101318 72%,#57616a 73%,#141b20 74%,#05070a 80%,#333c44 81%,transparent 82%),
 linear-gradient(24deg,#0e141b 4%,#354049 4.5%,#080d12 6%,#030608 25%,#13262f 25.5%,#215269 26%,#04090d 27%,#0b1219 71%,#235568 72%,#060a10 74%);
}
.glass-auth{--cut:clamp(32px,6vw,65px);width:min(100%,458px);position:relative;filter:drop-shadow(0 14px 26px #0008);color:#e4f0f9}
.glass-auth::before,.glass-auth::after{content:'';position:absolute;width:var(--cut);height:var(--cut);border:1px solid #7591a188;border-radius:12px;background:linear-gradient(135deg,#45515b88,#101c28bb);pointer-events:none}
.glass-auth::before{top:0;left:0;clip-path:polygon(0 0,100% 0,0 100%)}
.glass-auth::after{bottom:0;right:0;clip-path:polygon(100% 0,100% 100%,0 100%)}
.glass-face{position:relative;isolation:isolate;border-radius:24px;padding:26px 34px 22px;
 clip-path:polygon(var(--cut) 0,100% 0,100% calc(100% - var(--cut)),calc(100% - var(--cut)) 100%,0 100%,0 var(--cut));
 background:linear-gradient(145deg,#83969e,#1f3543 28%,#4c6778 60%,#314855);
 animation:glass-reveal .68s ease-out both}
.glass-face::before{content:'';position:absolute;inset:1.5px;z-index:-1;border-radius:23px;clip-path:inherit;background:radial-gradient(ellipse at 87% 35%,#0b3344ab,transparent 58%),linear-gradient(148deg,#243544fa,#0a1722fa 52%,#172431fa);backdrop-filter:blur(20px)}
.glass-heading{padding-left:26px;margin:0 0 42px}.glass-heading h1{font:650 26px/1.18 system-ui,sans-serif;letter-spacing:-.03em;color:#e8f4fc;margin:0}
.glass-heading p,.glass-switch{font:400 12px/1.5 system-ui,sans-serif;color:#9badbc;margin:5px 0}
.glass-auth .form-grid{display:grid;grid-template-columns:1fr;gap:12px}
.glass-auth label.field{display:grid;gap:5px;margin:0;font:500 12px/1.4 system-ui,sans-serif;color:#c3d6e4}
body.auth-mode .glass-auth input{width:100%;min-height:36px;border-radius:8px;padding:7px 12px;border:1px solid #44607566;background:#1a2934c4;color:#edf8ff;font-size:15px}
body.auth-mode .glass-auth input:focus{outline:2px solid #53bde7;outline-offset:1px}
.glass-auth .form-actions{margin-top:16px;display:block;background:transparent}
body.auth-mode .glass-auth button.primary{width:100%;border:1px solid #70d7f499;background:linear-gradient(#59cafa,#25a3da);color:#072c40;border-radius:9px;font-weight:650;min-height:36px;box-shadow:0 0 22px #1299d12e}
.glass-auth .form-error{color:#ffb4bc;margin:8px 0}.glass-auth .form-error:empty{display:none}
.glass-switch{text-align:center;margin:22px 0 0;padding-top:12px;border-top:1px solid #46607255}.glass-switch a{color:#8bdcfa;text-decoration:none}.glass-switch a:hover{text-decoration:underline}
@keyframes glass-reveal{from{opacity:.2;transform:perspective(850px) rotateY(-16deg) scale(.96);filter:blur(5px)}to{opacity:1;transform:none;filter:none}}
@media(max-width:480px){.glass-face{padding:24px}.glass-heading{margin-bottom:26px}}
@media(prefers-reduced-motion:reduce){.glass-face{animation:none}}

/* One continuous background for signed-out and signed-in pages. */
body,body.auth-mode {
 background:#752237;isolation:isolate;
}
body .shell,body.auth-mode .shell,body:not(.auth-mode) .shell:has(.ws-day-metrics),
body.auth-mode #main,body:not(.auth-mode) #main#main {
 background:transparent;
}
body:not(.auth-mode) #main#main {backdrop-filter:none}

/* Backdrop treatments over the shared wallpaper. */
body .shell .ws-day-metrics.metric-carousel {
  background:linear-gradient(120deg,rgba(255,255,255,.66),rgba(249,245,250,.48));
  backdrop-filter:blur(18px);
  border:1px solid #fff6;
}
.metric-carousel canvas {opacity:.92}

body:not(.auth-mode) .shell header {
  background:linear-gradient(180deg,rgba(255,246,236,.31),rgba(255,246,236,.10));
  border-bottom-color:transparent;
  box-shadow:none;
  backdrop-filter:none;
}
body:not(.auth-mode) .shell header :is(#crumb,.header-right>span) {
  color:#39232c;background:#fff2e6b8;
  border-radius:12px;padding:2px 8px;
}
.command-dock,
body .shell .header-right .command-trigger {
  background:linear-gradient(150deg,rgba(46,39,44,.78),rgba(26,22,25,.66));
  backdrop-filter:blur(16px);
}
.command-indicator {background:linear-gradient(145deg,#fff3,#ffffff0d)}

body:not(.auth-mode) #main .xr-view .c.w.hero {
  background:linear-gradient(135deg,rgba(106,14,46,.80),rgba(155,30,69,.65));
  backdrop-filter:blur(20px);
}
body.auth-mode .glass-auth {filter:none}
body.auth-mode .glass-face {
  background:linear-gradient(145deg,rgba(27,48,64,.85),rgba(8,28,40,.70));
  backdrop-filter:blur(22px);
  box-shadow:inset 0 0 0 1px #bde8ff55;
}
body.auth-mode .glass-face::before {
  background:radial-gradient(ellipse at 86% 30%,#1485aa12,transparent 58%);
  backdrop-filter:none;
}
body.auth-mode #main .glass-auth input {
  background:rgba(13,30,43,.52);border:1px solid #b1dbec50;color:#fff;
}
body.auth-mode #main .glass-auth .form-actions {background:transparent}
body.auth-mode .glass-heading p,body.auth-mode .glass-switch {color:#dae4ee}

/* Shared wine glass for workspace and dialog surfaces. */
body:not(.auth-mode) {
  --crm-wine-glass:linear-gradient(135deg,rgba(107,16,48,.75),rgba(145,28,64,.61));
  --crm-wine-blur:blur(20px);
}
body:not(.auth-mode) :is(#main,#modal) :is(.v63-overview .v63-hero,.cards>.card:nth-child(3),.xr-view .c.w,.hk-hero,.hk-card[data-index="2"]),
body:not(.auth-mode) #main .v63-overview:not(.v63-queue) .v63-hero,
body:not(.auth-mode) #main .xr-view .c.w.hero {
  background:var(--crm-wine-glass);
  backdrop-filter:var(--crm-wine-blur);
  color:#fff6f2;
}
body:not(.auth-mode) :is(#main,#modal) :is(.xr-view .wk .t,.v63-week span[aria-current],.v63-ring b){
  background:rgba(105,20,52,.73);
  backdrop-filter:var(--crm-wine-blur);
}

/* Pair foregrounds with their own surface across authenticated routes. */
body:not(.auth-mode) #main#main,body:not(.auth-mode) #modal {
 --ink:#271b20;--muted:#534248;--mute:var(--muted);--ws-muted:var(--muted);
 color:var(--ink);font-size:15px;line-height:1.5
}
body:not(.auth-mode) #main#main {
 background-color:rgba(255,244,238,.73);
}
body:not(.auth-mode) :is(#main,#modal) :where(button,.button){
 background-color:#f6e8e3;color:#38232a;border-color:#a88f90
}
body:not(.auth-mode) :is(#main,#modal) :where(button,.button):hover{
 background-color:#e8d4ce;color:#321b23
}
body:not(.auth-mode) :is(#main,#modal) :is(button.primary,.button.primary,[aria-pressed=true]:not(.hk-card),.nx-tabs .active){
 background-color:#492536;color:#fff8f5
}
body:not(.auth-mode) :is(#main,#modal) :is(button:disabled,.button[aria-disabled=true]){
 background-color:#e5d9d4;color:#604f54;opacity:1;border-color:#bca9a4
}
body:not(.auth-mode) :is(#main,#modal) :is(.text-button,.ws-person,.ws-table th button){background:transparent;color:#64273e}
body:not(.auth-mode) :is(#main,#modal) :is(.field,.sub,.muted,.trend,.metric-label,.ws-empty-small,.hub-id,.ws-pagination,.nx-help,.prod-muted,.detail-grid small){color:var(--muted)}
body:not(.auth-mode) :is(#main,#modal) :is(input,textarea)::placeholder{color:#65545a;opacity:1}
body:not(.auth-mode) :is(#main,#modal) :is(.form-error,.ws-save-status[data-state=error]){color:#89203a}
body:not(.auth-mode) :is(#main,#modal) :is(.xr-view .c.w,.v63-hero,.hk-hero,.hk-card,.cards>.card:nth-child(3)){
 --ink:#fff8f5;--muted:#fff1ed;--mute:var(--muted);color:var(--ink)
}
body:not(.auth-mode) #main .xr-view :is(.hero p,.kp span,.sc small,.ring b small){opacity:1}
body:not(.auth-mode) #main .xr-view :is(.kp span,.sc small,.ev small,.cal .d small){font-size:12px}
body.auth-mode #main .glass-auth :is(.field,.glass-heading p,.glass-switch){color:#f3f6fa}
body.auth-mode #main .glass-auth input::placeholder{color:#c6d4df;opacity:1}
body:not(.auth-mode) :is(#main,#modal) input:is([type=checkbox],[type=radio]){
 color-scheme:light;color:#39232c;background-color:#fff8f4;accent-color:#762342
}

/* Shared popup surface for dialogs, drawers and their fallback presentation. */
body:not(.auth-mode) dialog#modal[open] {
  background:linear-gradient(135deg,rgba(255,249,245,.78),rgba(247,228,222,.67));
  -webkit-backdrop-filter:blur(22px) saturate(115%);
  backdrop-filter:blur(22px) saturate(115%);
  color:#291d23;border-color:#fff9;
  box-shadow:inset 0 1px 0 #fffa,0 20px 70px #39152a38;
}
body:not(.auth-mode) dialog#modal::backdrop,
body:not(.auth-mode) .dialog-fallback-backdrop {
  background:rgba(35,18,29,.28);
  backdrop-filter:blur(3px);
}
body:not(.auth-mode) dialog#modal[open]>.panel-head,
body:not(.auth-mode) dialog#modal[open] .form-actions {
  background:rgba(255,246,240,.62);
}
body:not(.auth-mode) dialog#modal[open] :is(th,.ws-table th) {
  background:rgba(219,192,185,.72);color:#39272e;
}
body:not(.auth-mode) dialog#modal[open] :is(td,.ws-table td) {
  background:rgba(255,248,244,.58);color:#302128;
}
body:not(.auth-mode) dialog#modal[open] tbody tr:hover td{background:#fff3ecdf}
@supports not (backdrop-filter:blur(1px)){
  body:not(.auth-mode) dialog#modal[open]{background:#f5e6dfed}
}

/* Nested tool panels share the dialog's backdrop instead of obscuring it. */
body:not(.auth-mode) dialog#modal[open]:not(:has(.hk-work)) {
  background:linear-gradient(130deg,rgba(255,249,245,.71),rgba(247,228,222,.57));
  backdrop-filter:blur(24px) saturate(115%);
}
body:not(.auth-mode) dialog#modal[open]>.body {background:transparent}
body:not(.auth-mode) dialog#modal[open] .body :is(.panel,.card,.nx-card,.prod-card,.detail-grid>div,.nx-note,.notice,.ws-filters,.ws-notice,.nx-preview,.nx-linkbar,.nx-step,.prod-toolbar,.ws-search-result,.table-wrap,.ws-table,.ws-card-tabs){
  background:rgba(255,246,240,.42);
  color:#302128;border-color:rgba(104,75,83,.26);
}
body:not(.auth-mode) dialog#modal[open] .body :is(.panel-head,.panel-body){background:transparent}
body:not(.auth-mode) dialog#modal[open] .body :is(th,.ws-table th){background:rgba(221,196,189,.65)}
body:not(.auth-mode) dialog#modal[open] .body :is(td,.ws-table td){background:rgba(255,248,244,.37)}
body:not(.auth-mode) dialog#modal[open] .body tbody tr:hover td{background:rgba(255,248,244,.77)}

body:not(.auth-mode) dialog#modal:has(.hk-work){width:min(980px,96vw);max-width:96vw}
#modal:has(.hk-work)>.body{padding:clamp(12px,2vw,24px)}
#modal:has(.hk-work) #modal-title:focus:not(:focus-visible){outline:none}
.hk-work{display:grid;gap:18px;min-width:0}
.hk-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
body:not(.auth-mode) #modal .hk-tabs button{min-width:0;min-height:44px;display:flex;align-items:center;justify-content:space-between;gap:6px;border:1px solid #bba7aa99;border-radius:12px;padding:8px 14px;background:#fffcfa99;color:#422c35;line-height:1.25}
body:not(.auth-mode) #modal .hk-tabs button[aria-pressed=true]{background:#63253e;color:#fff7f4;border-color:#63253e}
.hk-tabs b{font-variant-numeric:tabular-nums;padding:2px 7px;border-radius:6px;background:#8b4e6117}.hk-tabs [aria-pressed=true] b{background:#ffffff24}
.hk-records{overflow:hidden;min-width:0;border:1px solid #8a63652e;border-radius:14px;background:#fff9f462}
.hk-heading,.hk-pages{display:flex;align-items:center;gap:10px;padding:12px 16px}.hk-heading{justify-content:space-between;flex-wrap:wrap}.hk-heading h2{margin:0;font-size:19px}.hk-heading span,.hk-pages span{font-size:13px;color:#563f48}
.hk-records .table-wrap{overflow:auto;max-height:min(51dvh,460px)}.hk-records th{position:sticky;top:0;z-index:1}.hk-records table{width:100%}
body:not(.auth-mode) #modal .hk-records :is(td,th){padding:9px 16px;font-size:14px}
body:not(.auth-mode) #modal .hk-records th{background:#eadbd6}
.hk-pages{justify-content:flex-end;border-top:1px solid #8a63652e}.hk-pages span{margin-right:auto}.hk-pages button{min-height:32px;padding:4px 12px}
@media(max-width:550px){body:not(.auth-mode) #modal .hk-tabs button{flex-direction:column;align-items:flex-start;padding:8px;font-size:12px}.hk-tabs{gap:4px}.hk-records table{min-width:480px}.hk-pages,.hk-heading{padding:10px}.hk-pages{gap:4px}}

body::before {
  content:"";position:fixed;inset:-3px;z-index:-1;pointer-events:none;
  background:url("/assets/crm-background.png") center / cover no-repeat;
  filter:brightness(.92) blur(1.5px);
}
body:not(.auth-mode) aside#sidebar.curved-rail {
  background:linear-gradient(#220d1945,#220d193b),url("/assets/rail-background.png") center / cover no-repeat;
}
body:not(.auth-mode) aside.curved-rail::before,
body:not(.auth-mode) aside.curved-rail::after {content:none}

/* Mobile workspace: retain document scrolling and contain wide records locally. */
@media(max-width:980px){
  body:not(.auth-mode) #main#main{max-width:100%;margin:8px 0;padding:16px max(14px,env(safe-area-inset-right)) 20px max(14px,env(safe-area-inset-left));border-radius:18px}
  body:not(.auth-mode) .shell header{padding-left:max(8px,env(safe-area-inset-left));padding-right:max(8px,env(safe-area-inset-right));padding-top:max(6px,env(safe-area-inset-top))}
  body:not(.auth-mode) aside#sidebar.curved-rail{left:max(8px,env(safe-area-inset-left));height:calc(100vh - 24px);height:min(716px,calc(100dvh - max(24px,env(safe-area-inset-top) + env(safe-area-inset-bottom))));max-height:716px}
  body:not(.auth-mode) :is(#main,#modal) :is(.table-wrap,.ws-table,.board){max-width:100%;min-width:0;overflow-x:auto;-webkit-overflow-scrolling:touch}
  body:not(.auth-mode) :is(#main,#modal) :is(.grid,.panel,.panel-body,.cards,.card,.form-grid,.field,.toolbar,.xr-view,.hk-records){min-width:0}
  body:not(.auth-mode) #modal{max-height:calc(100vh - 20px);max-height:calc(100dvh - 20px);overscroll-behavior:contain}
}
@media(max-width:720px){
  body:not(.auth-mode) #main .titlebar .actions{max-width:100%;flex-wrap:wrap}
  #main .v63-overview,#main .v63-clients,#main .v63-queue{grid-template-columns:minmax(0,1fr)}
  body:not(.auth-mode) :is(#main,#modal) :is(.toolbar,.actions,.panel-head,.ws-pagination,.form-actions){flex-wrap:wrap}
  body:not(.auth-mode) :is(#main,#modal) :is(h1,h2,h3,.notice,.detail-grid,.sub,.field){overflow-wrap:anywhere}
  body:not(.auth-mode) dialog#modal.ws-drawer{width:100%;max-width:100%;height:100vh;height:100dvh;max-height:100vh;max-height:100dvh}
  body:not(.auth-mode) #modal .body{padding:14px max(12px,env(safe-area-inset-right)) max(16px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left))}
  body:not(.auth-mode) #main .v63-hero{min-width:0;flex-wrap:wrap}
  body .shell .header-right .command-dock>button{width:clamp(34px,9vw,44px);min-height:44px;padding:0;flex:none}
  body .shell .header-right{min-width:0;margin-left:auto}
  .command-dock{margin-inline-end:50px}
  body.auth-mode #main{padding:max(16px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) max(16px,env(safe-area-inset-bottom)) max(12px,env(safe-area-inset-left))}
  .glass-auth{min-width:0}
}
@media(max-height:500px) and (max-width:980px){
  .curved-rail>.profile{height:auto;flex-direction:row;padding:4px 0}
  .curved-rail>.profile i{width:30px;height:30px}
  .curved-rail .side-bottom{margin:0;padding:0}
  body.auth-mode #main{align-items:start}
}
@supports not (background:color-mix(in srgb,red,white)){
  body .shell .header-right .command-satellite{background:#5b424f;color:white}
}
@media(pointer:coarse){
  .hk-pages button,.metric-modes button,.curved-rail #nav :is(a,button,summary){min-height:44px}
}

/* Common reading and action rhythm for CRM work surfaces. */
body:not(.auth-mode) :is(#main,#modal){
  --crm-panel-x:clamp(14px,1.6vw,20px);
  --crm-panel-y:clamp(12px,1.25vw,16px);
}
body:not(.auth-mode) :is(#main,#modal) .panel-head{gap:8px 14px;align-items:center}
body:not(.auth-mode) :is(#main,#modal) .panel-head h2{
  margin:0;font-size:clamp(16px,1.4vw,19px);font-weight:650;line-height:1.28;letter-spacing:-.015em
}
body:not(.auth-mode) #main .titlebar>.actions:empty{display:none}
body:not(.auth-mode) :is(#main,#modal) :is(.titlebar,.panel-head,.form-actions,.toolbar) button{
  font-family:inherit;font-size:14px;line-height:1.25;min-height:38px
}
body:not(.auth-mode) #main>.panel+.panel,
body:not(.auth-mode) #modal>.body>.panel+.panel{margin-top:14px}
body:not(.auth-mode) :is(#main,#modal) :is(td,th){line-height:1.42}
body:not(.auth-mode) :is(#main,#modal) .ws-pagination{
  gap:8px 14px;font-size:13px;font-variant-numeric:tabular-nums
}
body:not(.auth-mode) :is(#main,#modal) .empty-row .empty{
  min-height:0;padding:clamp(16px,3vw,32px) 12px;line-height:1.45
}
@media(max-width:720px){
  body:not(.auth-mode) #main .titlebar{align-items:stretch;gap:10px;margin-bottom:16px}
  body:not(.auth-mode) #main .titlebar>.actions{width:auto;gap:8px}
  body:not(.auth-mode) #main .titlebar>.actions button{flex:0 1 auto}
}
@media(pointer:coarse){
  body:not(.auth-mode) :is(#main,#modal) :is(.titlebar,.panel-head,.form-actions,.toolbar) button{min-height:44px}
}
.hakko-auth-logo{display:block;width:min(210px,90%);height:auto;margin:0 0 10px}
.curved-rail .rail-top .hakko-rail-logo{display:block;width:132px;height:auto;max-height:42px;object-fit:contain}
.curved-rail.rail-expanded .rail-top{height:46px}
@media(max-width:980px){.curved-rail .rail-top{height:46px}}
