/* /cortex: Studio and Forge side by side. Each side wears its own app's palette; the one not chosen falls to grey. */
html[data-gsd-hub] main:not(#gsd-inline-canvas)>:not(.ch){display:none!important}
html:not([data-gsd-hub]) .ch{display:none!important}
html[data-gsd-hub]{--dynamic-bg-color:#0b0c0e!important;background:linear-gradient(90deg,#f3f1ee 0 50%,#151514 50% 100%)!important}
html[data-gsd-hub] body,html[data-gsd-hub] main{background:transparent!important}
html[data-gsd-hub] .gf{margin-top:0;background:#0b0c0e!important;border-top-color:rgb(255 255 255 / .08)!important}
html[data-gsd-hub]:not(.gsd-scrolled) div.relative:has(> nav.navbar) > div.absolute.inset-0{background-color:transparent!important;box-shadow:none}
html[data-gsd-hub].gsd-scrolled div.relative:has(> nav.navbar) > div.absolute.inset-0{background-color:rgb(11 12 14 / .72)!important;box-shadow:inset 0 -1px 0 rgb(255 255 255 / .08)}

.ch{position:relative;display:grid;grid-template-columns:1fr 1fr;min-height:calc(100vh - 65px);min-height:calc(100svh - 65px);overflow:hidden;-webkit-font-smoothing:antialiased;--ch-ease:cubic-bezier(.2,.8,.2,1)}
.ch *,.ch *::before,.ch *::after{box-sizing:border-box}
.ch :where(p,ul,h1){margin:0}
.ch-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.ch::after{content:"";position:absolute;z-index:3;top:0;bottom:0;left:50%;width:1px;background:linear-gradient(to bottom,transparent,rgb(255 255 255 / .14) 30%,rgb(255 255 255 / .14) 70%,transparent);pointer-events:none}

.ch-side{position:relative;isolation:isolate;display:flex;align-items:center;min-height:inherit;padding:60px clamp(28px,6vw,110px) 80px;color:inherit;text-decoration:none;overflow:hidden;
  filter:saturate(.38) brightness(.82);transition:filter .75s var(--ch-ease)}
.ch[data-active="studio"] .ch-studio,.ch[data-active="forge"] .ch-forge{filter:none}
.ch[data-active="studio"] .ch-forge,.ch[data-active="forge"] .ch-studio{filter:grayscale(1) brightness(.5)}
.ch-side:focus-visible{outline:none}
.ch-side:focus-visible .ch-go{outline:2px solid currentColor;outline-offset:6px}
.ch-bg{position:absolute;inset:0;z-index:-1;pointer-events:none}
.ch-bg canvas{position:absolute;inset:0;width:100%;height:100%}
.ch-in{position:relative;width:100%;max-width:470px;margin-inline:auto;transition:transform .75s var(--ch-ease)}
.ch-side:hover .ch-in,.ch-side:focus-visible .ch-in{transform:translateY(-6px)}
.ch-brand{display:flex;flex-direction:column;align-items:flex-start;gap:26px;min-height:200px;justify-content:flex-end;margin-bottom:30px}
.ch-for{margin-bottom:22px}
.ch-points{display:grid;gap:9px;padding:0;margin-bottom:38px;list-style:none}
.ch-points li{position:relative;padding-left:22px}
/* One button for both sides, the same pill as the home band: only the colours belong to each app. */
.ch-go{display:inline-flex;align-items:center;gap:12px;min-height:48px;padding:0 22px;border:1px solid transparent;border-radius:10px;text-shadow:none;
  font-family:var(--gsd-din,"Bahnschrift","DIN Alternate","DIN 2014","Roboto Condensed",ui-sans-serif,system-ui,sans-serif);font-weight:600;font-size:15.5px;letter-spacing:.01em;line-height:1;
  transition:background-color .3s,color .3s,border-color .3s}
.ch-go i{font-style:normal;transition:transform .45s var(--ch-ease)}
.ch-side:hover .ch-go i,.ch-side:focus-visible .ch-go i{transform:translateX(5px)}

/* Studio: deep space over a lit horizon, Sora and Instrument Sans, the facet blues and cream. */
.ch-studio{background:radial-gradient(120% 80% at 30% -10%,#0d1630 0%,#060a14 50%,#04060c 100%);color:#c4ccdc;font-family:"Cortex Instrument","Instrument Sans",ui-sans-serif,system-ui,sans-serif;font-size:17px;line-height:1.6}
.ch-nebula{position:absolute;left:-20%;top:-10%;width:90%;height:70%;border-radius:50%;background:radial-gradient(closest-side,rgb(59 102 184 / .32),rgb(59 102 184 / .08) 55%,transparent)}
.ch-horizon{position:absolute;left:-30%;right:-30%;bottom:-72%;height:100%;border-radius:50%;background:#04060c;
  box-shadow:0 -1px 0 rgb(143 178 251 / .55),0 -18px 60px rgb(102 144 238 / .32),0 -60px 160px rgb(59 102 184 / .2)}
.ch-mark{width:92px;height:auto;filter:drop-shadow(0 10px 30px rgb(102 144 238 / .35))}
.ch-wordmark{display:block;width:min(300px,62vw);height:auto}
.ch-studio .ch-for{color:#f1ede6;font-family:"Cortex Sora","Sora",ui-sans-serif,system-ui,sans-serif;font-weight:300;font-size:clamp(20px,1.7vw,25px);line-height:1.35;letter-spacing:-.01em}
.ch-points li::before{content:"";position:absolute;left:2px;width:7px;height:7px;border-radius:50%}
.ch-studio .ch-points li::before{top:.6em;background:#6690ee}
.ch-studio .ch-go{background:#f1ede6;color:#0a0f1d}
.ch-studio:hover .ch-go{background:#fff}

/* Forge: the pixel koi pond, Cascadia Mono, the heat ramp. */
.ch-forge{background:#151514;color:#d9d7d0;text-shadow:0 0 3px #151514,0 0 10px #151514;font-family:"Forge Mono","Cascadia Mono",ui-monospace,Consolas,monospace;font-size:14.5px;line-height:1.75}
.ch-forge .ch-in::before{content:"";position:absolute;inset:-40px -50px;z-index:-1;background:radial-gradient(closest-side,rgb(21 21 20 / .82),rgb(21 21 20 / .5) 60%,transparent);pointer-events:none}
.ch-word{display:block;width:min(290px,60vw);height:auto;overflow:visible}
.ch-word text{font-family:"Forge Mono",ui-monospace,monospace;font-size:6.2px}
.ch-forge .ch-for{color:#f3f1eb;font-size:clamp(17px,1.35vw,20px);line-height:1.45}
.ch-forge .ch-points li::before{top:.64em;background:#f0703a}
.ch-forge .ch-go{border-color:#f0703a;background:#f0703a;color:#151514}
.ch-forge:hover .ch-go{background:#ffb547;border-color:#ffb547}

@media(hover:none){.ch-side,.ch[data-active] .ch-side{filter:none}}
@media(max-width:820px){
  html[data-gsd-hub]{background:#0b0c0e!important}
  .ch{grid-template-columns:1fr}
  .ch::after{display:none}
  .ch-side{min-height:auto;padding:56px 24px 70px}
  .ch-forge{padding-top:70px}
  .ch-brand{min-height:0}
}
@media(prefers-reduced-motion:reduce){.ch-side,.ch-in,.ch-go i{transition:none}}

/* Forge side: the bars mark beside the pixel wordmark, as in the app's titlebar. */
.ch-forge .ch-brand{flex-direction:row;align-items:flex-end;justify-content:flex-start;gap:16px}
.ch-forge-mark{height:calc(min(290px,60vw) * 70 / 290 * .98);width:auto}
/* Studio side: the hex mark to the left of the wordmark, matching the Forge side's lockup. */
.ch-studio .ch-brand{flex-direction:row;align-items:center;justify-content:flex-start;gap:20px}
.ch-studio .ch-mark{width:auto;height:calc(min(300px,62vw) * 211 / 933 * 1.25);flex:none}
.ch-studio .ch-brand,.ch-forge .ch-brand{min-height:0}

/* Forge side: the bar-stroke wordmark and the bars at one height. */
.ch-word{width:min(260px,56vw)}
.ch-forge-mark{height:calc(min(260px,56vw) * 100 / 360)}

.ch-tag{display:flex;align-items:center;gap:.5em;align-self:flex-end;margin:0 0 .3em .6em;color:#f0703a;font-size:14px;letter-spacing:.02em;white-space:nowrap}
.ch-tag::before{content:"";width:7px;height:7px;border-radius:50%;background:#f0703a}
@media(max-width:820px){.ch-forge .ch-brand{flex-wrap:wrap}.ch-tag{flex-basis:100%;margin:-6px 0 0}}

/* Studio side in daylight, as on /studio: the blurred real capture, ink type, the ink wordmark and an ink button.
   Both sides keep the same rounded-rectangle button; only the colours belong to each app. */
.ch-studio{background:#ecebe8;color:#3a3e46;font-family:"Cortex Instrument","Instrument Sans",ui-sans-serif,system-ui,sans-serif}
.ch-day{position:absolute;inset:-4%;background:url(/img/cortex/daylight/scenes/hero.webp) center/cover no-repeat}
.ch-day::after{content:"";position:absolute;inset:0;background:radial-gradient(70% 60% at 40% 50%,rgb(251 251 250 / .55),rgb(251 251 250 / 0) 70%)}
.ch-studio .ch-mark{filter:drop-shadow(0 10px 24px rgb(20 24 40 / .18))}
.ch-studio .ch-for{color:#111317;font-family:"Cortex Instrument","Instrument Sans",ui-sans-serif,system-ui,sans-serif;font-weight:600;letter-spacing:-.025em}
.ch-studio .ch-points{color:#3a3e46}
.ch-studio .ch-points li::before{background:#3b66b8}
.ch-studio .ch-go{background:#16181d;color:#fff;font-family:"Cortex Instrument","Instrument Sans",ui-sans-serif,system-ui,sans-serif;box-shadow:0 10px 22px -10px rgb(17 19 23 / .55)}
.ch-studio:hover .ch-go{background:#2a2d35}
.ch-forge .ch-go{font-family:"Forge Mono","Cascadia Mono",ui-monospace,Consolas,monospace}
.ch::after{background:linear-gradient(to bottom,transparent,rgb(17 19 23 / .16) 30%,rgb(17 19 23 / .16) 70%,transparent)}
/* The side not chosen fades instead of going to black, so the daylight side stays light. */
.ch[data-active="forge"] .ch-studio{filter:grayscale(1) contrast(.85) brightness(.97)}
.ch-studio{filter:saturate(.6)}
@media(hover:none){.ch-studio{filter:none}}
/* The navbar's light links cross the daylight side, so the bar keeps its dark backing here. */
html[data-gsd-hub][data-gsd-hub][data-gsd-hub] div.relative:has(> nav.navbar) > div.absolute.inset-0{background-color:#0b0c0e!important;box-shadow:inset 0 -1px 0 rgb(255 255 255 / .08)!important}
