/* Folio. The Buzones SOL design system (tokens, Geist, Phosphor), one accent: cobalto.
   Shape rule: controls 8px; containers 12px; pills fully round. Light by default; dark when <html data-theme="dark">.
   Swiss: one grid, flush left, type and hairlines do the work; no cards. */
@font-face { font-family: "Geist"; src: url("/fonts/Geist-Variable.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --bg: #f5f6f8; --surface: #fcfcfd; --surface-2: #f0f2f5; --border: #e2e5ea; --border-strong: #cfd4dc;
  --text: #14181e; --muted: #5a6371; --accent: #1d4ed8; --accent-hover: #1e40af; --accent-ink: #ffffff; --accent-soft: #e8eefc;
  --danger: #b42318;
  --shadow: 0 1px 2px rgb(20 30 45 / .05), 0 2px 6px rgb(20 30 45 / .04);
  --r-control: 8px; --r-box: 12px;
  --ease-out: cubic-bezier(.23, 1, .32, 1);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0e1115; --surface: #151a20; --surface-2: #1c222a; --border: #283039; --border-strong: #36404b;
  --text: #e7eaee; --muted: #98a2af; --accent: #7ea6ff; --accent-hover: #97b8ff; --accent-ink: #0b1a40; --accent-soft: #16223d;
  --danger: #f2766b;
  --shadow: 0 1px 2px rgb(0 0 0 / .35);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 14px/1.5 "Geist", system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; font-feature-settings: "tnum" 1; }
::selection { background: var(--accent-soft); color: var(--text); }
* { scrollbar-color: var(--border-strong) transparent; }
[hidden] { display: none !important; }
/* One view at a time (<html data-view>, boot.js then app.js); the forms wait for Clerk (data-ready) so nothing is typed into a dead form */
:root:not([data-view="apps"]) #apps-view, :root[data-view="apps"] #login-view { display: none; }
:root:not([data-ready]) .door-forms { visibility: hidden; }
p { margin: 0 0 8px; }
.i { width: 18px; height: 18px; fill: currentColor; flex: none; }
.logo { width: 32px; height: 32px; border-radius: var(--r-control); background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: none; }
.logo .mark { width: 62%; height: 62%; fill: currentColor; }

/* Buttons and links */
.btn { appearance: none; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); border-radius: var(--r-control); padding: 9px 14px; font: inherit; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap; text-decoration: none; transition: background-color .15s, border-color .15s, transform .12s var(--ease-out); }
.btn:hover { background: var(--surface-2); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .65; cursor: progress; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.block { width: 100%; min-height: 44px; }
.icon-btn { appearance: none; border: 0; background: transparent; color: var(--muted); width: 36px; height: 36px; border-radius: var(--r-control); cursor: pointer; display: inline-grid; place-items: center; transition: background-color .15s, color .15s; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn:active { transform: scale(.96); }
.link { appearance: none; border: 0; background: none; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: none; }
.link-accent { color: var(--accent); font-weight: 500; font-size: 13px; }
.link-accent:hover { text-decoration: underline; text-underline-offset: 3px; }
:is(input, .btn, .icon-btn, .seg button, .link):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Forms (the Buzones SOL login, same fields and messages) */
input { font: inherit; color: var(--text); caret-color: var(--accent); background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--r-control); padding: 9px 11px; min-width: 0; width: 100%; }
input:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: var(--accent); }
.field { display: grid; gap: 6px; font-weight: 600; font-size: 13px; margin-bottom: 14px; }
.field input { font-weight: 400; font-size: 15px; }
.field .hint { margin: 0; font-weight: 400; color: var(--muted); font-size: 12.5px; }
.field-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.form-error { color: var(--danger); min-height: 1.2em; margin: 0 0 12px; font-size: 13px; }
.login .form-error:empty { min-height: 0; margin-bottom: 6px; }
.form-lead { margin: 0 0 16px; font-size: 14px; color: var(--muted); }
.seg { display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-control); padding: 3px; }
.seg button { appearance: none; border: 0; background: none; font: inherit; font-weight: 600; color: var(--muted); padding: 8px 12px; border-radius: 6px; cursor: pointer; white-space: nowrap; }
.seg button:hover { color: var(--text); }
.seg button.active { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }   /* the submit stays the only accent fill */
:root[data-theme="dark"] .seg button.active { background: var(--border); }   /* lifted above the darker track, not pressed into it */
.login-tabs { display: grid; width: 100%; margin: 0 0 18px; }
/* Google's own sign-in button: the four-colour G on its neutral fill (light), its dark variant in dark */
.btn-google { background: #fff; border-color: #747775; color: #1f1f1f; }
.btn-google img { width: 18px; height: 18px; flex: none; }
:root[data-theme="dark"] .btn-google { background: #131314; border-color: #8e918f; color: #e3e3e3; }
@media (hover: hover) and (pointer: fine) {
  .btn-google:hover { background: #f3f4f6; }
  :root[data-theme="dark"] .btn-google:hover { background: #1f2023; }
}
.or { display: flex; align-items: center; gap: 10px; margin: 16px 0; color: var(--muted); font-size: 12.5px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.login-alt { margin: 14px 0 0; text-align: center; font-size: 13.5px; color: var(--muted); }
.login-alt .link { color: var(--accent); font-weight: 500; }
.login-alt .link:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Signed out: the name owns the left of the grid, the forms sit on the right column's surface */
/* --wm: the wordmark size; --top: the grid's top margin; --cap: where the wordmark's cap line falls (Geist at line-height .86: .058em under the box top), the line the form's first text and the theme toggle sit on */
.door { --wm: clamp(96px, 12vw, 184px); --top: 56px; --gut: 56px; --cap: calc(var(--top) + var(--wm) * .058); min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 7fr) minmax(420px, 5fr); position: relative; }
.door-name { display: flex; flex-direction: column; justify-content: space-between; gap: 32px; padding: var(--top) 64px 64px; }
.wordmark { margin: 0 0 0 -.06em; font-size: var(--wm); line-height: .86; font-weight: 650; letter-spacing: -.04em; overflow-wrap: anywhere; }
.door-line { margin: 0; font-size: 20px; line-height: 1.3; letter-spacing: -.01em; color: var(--muted); max-width: 22ch; }
.door-form { display: grid; place-items: start center; padding: calc(var(--cap) - 6px) var(--gut) 64px; background: var(--surface); border-left: 1px solid var(--border); }
.door-forms { width: min(360px, 100%); }
.door-lead { margin: 0 0 20px; font-size: 15px; font-weight: 500; }
.door-theme { position: absolute; top: calc(var(--cap) - 13px); right: calc(var(--gut) - 9px); }   /* the glyph's edge on the gutter, its top on the cap line */

/* Signed in: a bar, then the apps as a register under one strong rule */
.bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; height: 64px; padding: 0 max(32px, calc((100% - 1136px) / 2)); background: var(--surface); border-bottom: 1px solid var(--border); }
.bar-name { font-size: 17px; font-weight: 650; letter-spacing: -.02em; white-space: nowrap; }
.bar-right { display: flex; align-items: center; gap: 2px; min-width: 0; }
.who { min-width: 0; margin-right: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 13px; }
.shelf { max-width: 1200px; margin: 0 auto; padding: 80px 32px 96px; }
.shelf-title { margin: 0 0 40px -.04em; font-size: clamp(40px, 5vw, 64px); line-height: 1; font-weight: 650; letter-spacing: -.035em; }
.register { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--text); }
.register li { border-bottom: 1px solid var(--border); }
/* The description hangs on a declared line: the start of column 5 of a 12-column, 24px-gutter grid, (100% + 24px) / 3 */
.entry { display: grid; grid-template-columns: 44px calc((100% + 24px) / 3 - 92px) minmax(0, 1fr) auto 20px; grid-template-areas: "logo name lead host go"; align-items: center; column-gap: 24px; padding: 24px 0; color: inherit; text-decoration: none; }
.entry .logo { grid-area: logo; width: 44px; height: 44px; }
.entry-name { grid-area: name; font-size: 22px; font-weight: 650; letter-spacing: -.02em; transition: color .15s; }
.entry-lead { grid-area: lead; color: var(--muted); font-size: 15px; }
.entry-host { grid-area: host; color: var(--muted); font-size: 13px; }
.entry-go { grid-area: go; width: 20px; height: 20px; color: var(--muted); transition: transform .2s var(--ease-out), color .15s; }
.entry:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: var(--r-control); }
.entry:active .entry-go { transform: translateX(6px); }
@media (hover: hover) and (pointer: fine) {
  .entry:hover .entry-name, .entry:hover .entry-go { color: var(--accent); }
  .entry:hover .entry-go { transform: translateX(4px); }
}
@media (prefers-reduced-motion: no-preference) {
  .register li { animation: rise .32s var(--ease-out) both; }
}
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }

/* Tablet: the form column keeps its width, the name gives way */
@media (max-width: 1024px) {
  .door { --top: 48px; --gut: 40px; }
  .door-name { padding: var(--top) 40px 56px; }
  .door-form { padding-bottom: 56px; }
  .entry { grid-template-columns: 44px minmax(0, 1fr) 20px; grid-template-areas: "logo name go" ". lead ." ". host ."; row-gap: 2px; }
}
/* Phone: one column, the name above the forms */
@media (max-width: 767px) {
  .door { --wm: clamp(64px, 22vw, 96px); --top: 40px; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .door-name { padding: var(--top) 20px 32px; gap: 20px; justify-content: flex-start; }
  .door-line { font-size: 17px; }
  .door-form { place-items: start center; padding: 32px 20px 48px; border-left: 0; border-top: 1px solid var(--border); }
  .door-theme { top: calc(var(--top) - 8px); right: 11px; }
  .bar { padding: 0 12px 0 20px; }
  .shelf { padding: 48px 20px 64px; }
  .shelf-title { margin-bottom: 28px; }
  .entry { column-gap: 16px; padding: 20px 0; }
  .entry-name { font-size: 19px; }
}
