:root {
  --bg: #080a10;
  --glass: rgba(18, 22, 33, 0.62);
  --glass-hi: rgba(255, 255, 255, 0.055);
  --panel-2: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.09);
  --border-hi: rgba(255, 255, 255, 0.16);
  --text: #f2f5fc;
  --dim: #98a2b8;
  --accent: #8ab4ff;
  --accent-strong: #b6d0ff;
  --good: #7fe9b0;
  --warn: #ffcf7a;
  --bad: #ff9b9b;
  /* Landing palette — warm companions to the blue so the page reads for
     everyone (crafty/giftable warmth, not just techy cool). */
  --hue-violet: #c9a8ff;
  --hue-rose: #ff9fbe;
  --hue-amber: #ffcf98;
  --hue-teal: #8ce0d2;
  --radius: 14px;
  --shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.8);
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  /* One interaction system for marketing, the user studio, and Operations. */
  --control-h: 48px;
  --control-sm-h: 44px;
  --control-lg-h: 52px;
  --control-radius: 10px;
  --control-bg: rgba(255, 255, 255, 0.055);
  --control-bg-hover: rgba(255, 255, 255, 0.1);
  --control-bg-pressed: rgba(255, 255, 255, 0.075);
  --focus-ring: rgba(138, 180, 255, 0.42);
  --danger-bg: rgba(255, 138, 138, 0.1);
  --danger-bg-hover: rgba(255, 138, 138, 0.18);
  --font: "SF Pro Display", "SF Pro Text", -apple-system, system-ui, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
svg.lucide { width: 1.1em; height: 1.1em; flex: 0 0 auto; stroke: currentColor; }
html, body { margin: 0; height: 100%; }
body {
  background: radial-gradient(1200px 900px at 75% -15%, #17203a 0%, var(--bg) 55%);
  color: var(--text);
  font: 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  min-height: 100%;
}
a {
  color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px;
  text-underline-offset: 3px; transition: color 0.15s ease, text-decoration-color 0.15s ease;
}
a:hover { color: var(--accent-strong); text-decoration-color: currentColor; }
a:focus-visible {
  outline: 4px solid var(--focus-ring); outline-offset: 3px; border-radius: 4px;
}
a.brand, a.btnlink { text-decoration: none; }
.hidden { display: none !important; }
.muted { color: var(--dim); }
a.muted:hover { color: var(--text); }
.sm { font-size: 14px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
hr { border: none; border-top: 1px solid var(--border); margin: 18px 0; }

/* ---- Header -------------------------------------------------------------- */
header.top {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 56px; padding: 7px 20px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 20;
  background: rgba(8, 10, 16, 0.72); backdrop-filter: blur(16px) saturate(140%);
}
.skip-link {
  position: fixed; z-index: 500; top: 10px; left: 10px; padding: 10px 14px;
  min-height: var(--control-h); display: inline-flex; align-items: center;
  color: #08101f; background: #fff; border: 3px solid var(--accent);
  border-radius: var(--control-radius); font-weight: 750; text-decoration: none;
  transform: translateY(-160%); transition: transform 0.15s ease;
}
.skip-link:focus { color: #08101f; transform: translateY(0); }
.visually-hidden {
  position: absolute !important; width: 1px !important; height: 1px !important;
  padding: 0 !important; margin: -1px !important; overflow: hidden !important;
  clip: rect(0 0 0 0) !important; white-space: nowrap !important; border: 0 !important;
}
.brand { font-weight: 700; letter-spacing: 0.2px; display: flex; align-items: center; gap: 9px; }
.brand.big { font-size: 15px; margin-bottom: 20px; }
.brand .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, #d7e6ff, var(--accent));
  box-shadow: 0 0 10px rgba(138, 180, 255, 0.5);
}
.surface-label {
  margin-left: 3px; padding: 4px 7px; border: 1px solid var(--border); border-radius: 999px;
  color: var(--dim); font-size: 9px; font-weight: 750; letter-spacing: .1em; text-transform: uppercase;
}
.who { display: flex; align-items: center; gap: 12px; }
.account-menu-wrap { position: relative; }
.account-trigger {
  min-width: 0; min-height: 40px; gap: 8px; padding: 4px 9px 4px 5px; background: var(--control-bg);
  border-color: var(--border); text-align: left;
}
.account-trigger-copy { display: none; min-width: 0; line-height: 1.2; }
.account-trigger-copy b, .account-trigger-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-trigger-copy b { font-size: 14px; }
.account-trigger-copy small { max-width: 220px; color: var(--dim); font-size: 12px; font-weight: 550; }
.account-avatar {
  width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 auto;
  border-radius: 8px; color: var(--accent-strong); background: rgba(138, 180, 255, 0.13);
  border: 1px solid rgba(138, 180, 255, 0.22);
}
.account-avatar svg { width: 17px; height: 17px; }
.account-chevron { color: var(--dim); }
.account-popover {
  position: absolute; z-index: 80; top: calc(100% + 9px); right: 0; width: min(340px, calc(100vw - 24px));
  padding: 8px; border: 1px solid var(--border); border-radius: 15px;
  background: rgba(16, 20, 30, 0.98); box-shadow: 0 24px 70px -28px rgba(0, 0, 0, 0.8);
}
body.studio-light .account-popover { background: rgba(255, 255, 255, 0.99); box-shadow: 0 24px 70px -32px rgba(20, 34, 64, 0.42); }
.account-popover-head { display: flex; align-items: center; gap: 10px; padding: 8px 9px 12px; border-bottom: 1px solid var(--border); margin-bottom: 6px; }
.account-popover-head > span:last-child { min-width: 0; }
.account-popover-head b, .account-popover-head small { display: block; }
.account-popover-head small { overflow: hidden; text-overflow: ellipsis; color: var(--dim); white-space: nowrap; font-size: 11px; }
.account-menu-item {
  width: 100%; display: grid; grid-template-columns: 30px minmax(0, 1fr); align-items: center;
  gap: 10px; min-height: 60px; padding: 10px 12px; text-align: left; white-space: normal;
  background: transparent; border-color: transparent; box-shadow: none;
}
.account-menu-item:hover { background: var(--control-bg); border-color: transparent; transform: none; }
.account-menu-item > svg { width: 18px; height: 18px; color: var(--dim); }
.account-menu-item span, .account-menu-item b, .account-menu-item small { display: block; min-width: 0; }
.account-menu-item b { font-size: 14px; }
.account-menu-item small { margin-top: 2px; color: var(--dim); font-size: 12px; font-weight: 550; }
.account-menu-signout { margin-top: 6px; border-top: 1px solid var(--border); border-radius: 0 0 10px 10px; color: var(--bad); }
.account-menu-signout > svg { color: currentColor; }
@media (min-width: 620px) { .account-trigger-copy { display: block; } }

.wrap { max-width: 1140px; margin: 0 auto; padding: 30px 24px 90px; }

/* ---- Cards -------------------------------------------------------------- */
.card {
  background: linear-gradient(180deg, var(--glass-hi), rgba(255, 255, 255, 0.012)), var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), var(--shadow);
  padding: 20px;
}
h1 { font-size: 22px; font-weight: 650; margin: 0 0 4px; letter-spacing: 0.2px; }
h2 { font-size: 17px; font-weight: 600; margin: 0 0 12px; }
h3 { font-size: 11px; margin: 18px 0 9px; color: var(--dim); text-transform: uppercase; letter-spacing: 1px; font-weight: 700; }

/* ---- Inputs ------------------------------------------------------------- */
input, textarea {
  width: 100%; font: inherit; color: var(--text);
  background: var(--panel-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 11px 13px; outline: none;
  transition: border-color 0.15s ease, background 0.15s ease;
}
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]),
select { min-height: var(--control-h); font-size: 16px; }
input:focus, textarea:focus { border-color: var(--accent); background: rgba(255, 255, 255, 0.05); }
input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 4px solid var(--focus-ring); outline-offset: 2px;
}
textarea { resize: vertical; }
label { display: block; font-size: 13px; color: var(--dim); margin: 0 0 7px; }
.field { margin-bottom: 14px; }
.err { color: var(--bad); font-size: 13px; min-height: 18px; }

/* ---- Buttons ------------------------------------------------------------ */
button, .btnlink {
  min-height: var(--control-h); font: inherit; font-size: 15px; font-weight: 680; line-height: 1.25;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  color: var(--text); background: var(--control-bg); border: 1px solid var(--border);
  padding: 9px 14px; border-radius: var(--control-radius); text-decoration: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease,
    color 0.15s ease, transform 0.12s ease, opacity 0.15s ease;
  white-space: nowrap; -webkit-tap-highlight-color: transparent;
}
button:hover, .btnlink:hover {
  color: var(--text); text-decoration: none; background: var(--control-bg-hover);
  border-color: var(--border-hi); transform: translateY(-1px);
}
button:active, .btnlink:active { background: var(--control-bg-pressed); transform: translateY(0); }
button:focus-visible, .btnlink:focus-visible {
  outline: 4px solid var(--focus-ring); outline-offset: 2px; border-color: var(--accent);
}
:is(button, .btnlink).primary {
  color: #0a1120; background: linear-gradient(180deg, var(--accent-strong), var(--accent));
  border-color: transparent; box-shadow: 0 8px 20px -10px rgba(138, 180, 255, 0.7);
}
:is(button, .btnlink).primary:hover { color: #0a1120; filter: brightness(1.06); border-color: transparent; }
:is(button, .btnlink).secondary { background: var(--control-bg); }
:is(button, .btnlink).secondary:hover { background: var(--control-bg-hover); }
:is(button, .btnlink).good {
  color: #06170f; background: linear-gradient(180deg, #9cf1c6, var(--good)); border-color: transparent;
}
:is(button, .btnlink).good:hover { color: #06170f; filter: brightness(1.04); border-color: transparent; }
:is(button, .btnlink).bad {
  color: var(--bad); background: var(--danger-bg); border-color: rgba(255, 138, 138, 0.34);
}
:is(button, .btnlink).bad:hover { color: var(--bad); background: var(--danger-bg-hover); border-color: rgba(255, 138, 138, 0.48); }
:is(button, .btnlink).ghost { background: transparent; box-shadow: none; }
:is(button, .btnlink).ghost:hover { background: var(--control-bg-hover); }
:is(button, .btnlink).sm { min-height: var(--control-sm-h); padding: 8px 12px; font-size: 14px; }
:is(button, .btnlink).lg { min-height: var(--control-lg-h); padding: 13px 22px; font-size: 16px; border-radius: 12px; }
:is(button, .btnlink).block { width: 100%; justify-content: center; margin-top: 6px; }
:is(button, .btnlink).link {
  min-height: var(--control-sm-h); background: transparent; border-color: transparent;
  box-shadow: none; color: var(--accent); padding: 6px 8px;
}
:is(button, .btnlink).link:hover { color: var(--accent-strong); background: transparent; transform: none; text-decoration: underline; text-underline-offset: 3px; }
:is(button, .btnlink).icon {
  width: var(--control-h); min-width: var(--control-h); padding: 0; font-size: 15px; line-height: 1;
}
:is(button, .btnlink).icon.sm { width: var(--control-sm-h); min-width: var(--control-sm-h); padding: 0; }
.close-button {
  color: var(--text); background: var(--control-bg); border-color: var(--border-hi);
  box-shadow: 0 7px 18px -12px rgba(0, 0, 0, 0.7);
}
.close-button:hover { color: var(--text); background: var(--control-bg-hover); border-color: var(--accent); }
button:disabled, .btnlink[aria-disabled="true"] {
  opacity: 0.42; cursor: not-allowed; transform: none; filter: none; box-shadow: none;
}
.back {
  min-height: var(--control-sm-h); background: transparent; border-color: transparent; box-shadow: none;
  color: var(--dim); padding: 4px 6px; margin: 0 0 14px -6px; font-weight: 650;
}
.back:hover { color: var(--text); background: var(--control-bg); border-color: transparent; transform: none; }

/* ---- Auth --------------------------------------------------------------- */
#view-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100dvh - 65px);
  padding: clamp(22px, 5vw, 60px);
}
.auth-shell {
  width: min(940px, 100%);
  min-height: 610px;
  display: grid;
  grid-template-columns: minmax(300px, .88fr) minmax(360px, 1.12fr);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(255, 255, 255, .7);
  box-shadow: 0 36px 90px -48px rgba(50, 59, 84, .38), inset 0 1px rgba(255, 255, 255, .9);
}
.auth-context {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 30px;
  color: #2e3a36;
  background:
    radial-gradient(circle at 14% 8%, rgba(206, 120, 78, .2), transparent 32%),
    radial-gradient(circle at 88% 84%, rgba(94, 129, 116, .23), transparent 40%),
    linear-gradient(145deg, #f7ead9, #e8eee4);
  border-right: 1px solid rgba(91, 83, 66, .12);
}
.auth-context .back { align-self: flex-start; color: #6f5b50; }
.auth-context .back:hover { color: #3d312b; background: rgba(255,255,255,.44); }
.auth-context__copy { padding: 52px 2px; }
.auth-context__copy .kicker { color: #9b553f; }
.auth-context__copy h2 {
  max-width: 360px;
  margin: 12px 0 20px;
  color: #2d3835;
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 620;
  letter-spacing: -.055em;
  line-height: 1;
}
.auth-context__copy p { max-width: 350px; margin: 0; color: rgba(55, 67, 62, .7); font-size: 14px; line-height: 1.7; }
.auth-context__trust { display: flex; flex-wrap: wrap; gap: 9px 16px; color: rgba(55, 67, 62, .66); font-size: 11px; font-weight: 650; }
.auth-context__trust span { display: inline-flex; align-items: center; gap: 6px; }
.auth-context__trust svg { width: 14px; height: 14px; color: #607d71; }
.auth-card {
  width: 100%;
  max-width: 470px;
  align-self: center;
  justify-self: center;
  padding: clamp(32px, 6vw, 64px);
}
.auth-heading { margin-bottom: 30px; }
.auth-heading h1 { margin: 8px 0 9px; font-size: clamp(28px, 4vw, 38px); font-weight: 670; letter-spacing: -.04em; }
.auth-heading p { margin: 0; line-height: 1.6; }
.auth-card .field { margin-bottom: 17px; }
.auth-card label { color: var(--text); font-size: 12px; font-weight: 680; }
.auth-card input { background: rgba(255,255,255,.72); }
.password-control { position: relative; }
.password-control input { padding-right: 72px; }
.password-control button {
  position: absolute;
  top: 50%;
  right: 6px;
  min-height: 36px;
  padding: 6px 10px;
  border-color: transparent;
  color: var(--dim);
  background: transparent;
  font-size: 12px;
}
.password-control button:hover { color: var(--text); background: var(--control-bg-hover); border-color: transparent; transform: translateY(-50%); }
.password-control button, .password-control button:active { transform: translateY(-50%); }
.auth-card .err { min-height: 22px; margin-top: -4px; }
.auth-note { margin: 0 0 14px; padding: 11px 12px; border-radius: 9px; color: #285f4a; background: rgba(65, 150, 111, .1); font-size: 12px; line-height: 1.55; }
.auth-signup-plans { margin-bottom: 16px; }
.auth-signup-plans .plan-picker { margin: 12px 0 4px; }
.signup-social-start { margin-bottom: 18px; }
.signup-social-start .auth-consent { margin: 12px 0 0; }
.social-signup-summary {
  display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px;
  margin: 0 0 18px; padding: 11px 12px; border: 1px solid rgba(40, 107, 80, .22);
  border-radius: 11px; background: rgba(65, 150, 111, .09);
}
.social-signup-summary > .s-ic { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: var(--panel-2); font-weight: 800; }
.social-signup-summary span, .social-signup-summary b, .social-signup-summary small { min-width: 0; display: block; }
.social-signup-summary small { overflow: hidden; color: var(--dim); font-size: 11.5px; text-overflow: ellipsis; white-space: nowrap; }
.social-signup-summary .link { width: auto; min-height: 36px; padding: 4px 7px; }
.signup-step { display: grid; grid-template-columns: 22px auto 1fr 22px auto; align-items: center; gap: 7px; margin-bottom: 14px; color: var(--dim); font-size: 10px; letter-spacing: .05em; text-transform: uppercase; }
.signup-step span { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--accent); font-size: 10px; }
.signup-step span:nth-of-type(2) { color: var(--dim); background: var(--panel-2); border: 1px solid var(--border); }
.signup-step i { height: 1px; background: var(--border); }
.signup-paid-summary { display: flex; align-items: center; gap: 11px; margin: 0 0 18px; padding: 12px 14px; border: 1px solid rgba(40, 107, 80, .22); border-radius: 11px; color: #285f4a; background: rgba(65, 150, 111, .09); }
.signup-paid-summary > svg { width: 22px; height: 22px; flex: 0 0 auto; }
.signup-paid-summary span, .signup-paid-summary b, .signup-paid-summary small { display: block; }
.signup-paid-summary small { color: var(--dim); font-size: 11.5px; line-height: 1.45; }
.auth-switch { display: flex; align-items: center; justify-content: center; gap: 2px; margin-top: 16px; color: var(--dim); font-size: 13px; }
.auth-switch .link { width: auto; min-height: 36px; margin: 0; padding: 4px 7px; }
.auth-card .legal-line { margin: 18px 0 0; font-size: 11px; }
@media (max-width: 760px) {
  #view-auth { align-items: flex-start; padding: 18px; }
  .auth-shell { min-height: 0; grid-template-columns: 1fr; }
  .auth-context { min-height: 180px; padding: 22px; border-right: 0; border-bottom: 1px solid rgba(91, 83, 66, .12); }
  .auth-context__copy { padding: 28px 0 12px; }
  .auth-context__copy h2 { max-width: 520px; margin: 8px 0 10px; font-size: 30px; }
  .auth-context__copy p, .auth-context__trust { display: none; }
  .auth-card { max-width: none; padding: 32px 24px 36px; }
}

/* ---- Landing ------------------------------------------------------------- */
#view-landing { max-width: 1140px; margin: 0 auto; padding: 40px 24px 70px; position: relative; }
.workspace-entry {
  min-height: calc(100dvh - 65px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.workspace-gate {
  width: min(960px, 100%);
  margin: auto;
  padding: clamp(48px, 9vw, 110px) 0;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr);
  gap: clamp(50px, 10vw, 120px);
  align-items: center;
}
.workspace-gate__marketing {
  width: fit-content;
  margin: 0 0 24px -12px;
  color: var(--dim);
}
.workspace-gate__marketing > svg { width: 16px; height: 16px; }
.workspace-gate__copy h1 {
  margin: 10px 0 22px;
  max-width: 650px;
  font-size: clamp(44px, 7vw, 82px);
  font-weight: 650;
  letter-spacing: -.065em;
  line-height: .94;
}
.workspace-gate__copy > p {
  max-width: 480px;
  margin: 0;
  color: var(--dim);
  font-size: 16px;
  line-height: 1.7;
}
.workspace-gate__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 30px; }
.workspace-gate__aside {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 0 15px;
  padding: 8px 0;
  border-top: 1px solid var(--border);
}
.workspace-gate__number,
.workspace-gate__aside > div { padding: 18px 0; border-bottom: 1px solid var(--border); }
.workspace-gate__number { color: var(--accent); font: 700 11px/1.4 var(--mono); letter-spacing: .08em; }
.workspace-gate__aside b, .workspace-gate__aside small { display: block; }
.workspace-gate__aside b { color: var(--text); font-size: 14px; }
.workspace-gate__aside small { margin-top: 3px; color: var(--dim); font-size: 12px; }
.workspace-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--dim);
  font-size: 12px;
}
.workspace-footer p { margin: 0; }
.workspace-footer nav { display: flex; gap: 18px; }
.workspace-footer a { color: var(--dim); text-decoration: none; }
.workspace-footer a:hover { color: var(--text); text-decoration: underline; }
@media (max-width: 720px) {
  .workspace-entry { min-height: calc(100dvh - 65px); }
  .workspace-gate { grid-template-columns: 1fr; gap: 56px; padding: 64px 0; }
  .workspace-footer { align-items: flex-start; flex-direction: column; }
}
/* Primary CTA with a slow sheen sweep on hover. */
button.shine { position: relative; overflow: hidden; }
button.shine::after {
  content: ""; position: absolute; top: -40%; bottom: -40%; left: -70%; width: 42%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  transform: skewX(-18deg); transition: left 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); pointer-events: none;
}
button.shine:hover::after { left: 130%; }

/* Starfield + aurora atmosphere behind the hero (pure CSS, deterministic). */
.hero {
  display: flex; align-items: center; gap: 40px; padding: 54px 0 70px; flex-wrap: wrap;
  position: relative; isolation: isolate;
}
.hero::before {
  content: ""; position: absolute; inset: -60px -120px 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(1.5px 1.5px at 12% 20%, rgba(255,255,255,0.5), transparent 100%),
    radial-gradient(1px 1px at 28% 68%, rgba(255,255,255,0.34), transparent 100%),
    radial-gradient(1.5px 1.5px at 44% 12%, rgba(255,255,255,0.4), transparent 100%),
    radial-gradient(1px 1px at 58% 44%, rgba(255,255,255,0.3), transparent 100%),
    radial-gradient(1.5px 1.5px at 71% 26%, rgba(255,255,255,0.45), transparent 100%),
    radial-gradient(1px 1px at 83% 60%, rgba(255,255,255,0.32), transparent 100%),
    radial-gradient(1.5px 1.5px at 92% 14%, rgba(255,255,255,0.38), transparent 100%),
    radial-gradient(1px 1px at 8% 84%, rgba(255,255,255,0.3), transparent 100%),
    radial-gradient(1px 1px at 66% 82%, rgba(255,255,255,0.28), transparent 100%),
    radial-gradient(600px 340px at 78% 30%, rgba(90, 130, 220, 0.14), transparent 70%),
    radial-gradient(520px 300px at 8% 20%, rgba(200, 110, 160, 0.10), transparent 70%),
    radial-gradient(460px 280px at 55% 92%, rgba(230, 160, 90, 0.07), transparent 70%),
    radial-gradient(500px 300px at 15% 75%, rgba(120, 90, 200, 0.10), transparent 70%);
}
.hero-copy { flex: 1 1 460px; min-width: 320px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 700;
  letter-spacing: 2px; text-transform: uppercase; color: var(--accent);
  margin-bottom: 18px;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: radial-gradient(circle at 32% 30%, #d7e6ff, var(--accent)); box-shadow: 0 0 9px rgba(138, 180, 255, 0.5); }
.hero-title {
  font-size: clamp(36px, 5.4vw, 58px); line-height: 1.06; font-weight: 700; letter-spacing: -1px;
  margin: 0 0 18px;
  background: linear-gradient(180deg, #ffffff 30%, #aebbd6);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-title em, .price-pitch em, .cta-band em {
  font-style: normal;
  background: linear-gradient(92deg, #9dbfff, var(--hue-violet) 45%, var(--hue-rose) 85%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-sub { max-width: 520px; font-size: 15.5px; line-height: 1.65; color: var(--dim); margin: 0 0 26px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.hero-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  font-size: 12px; font-weight: 600; color: var(--dim); padding: 6px 12px; border-radius: 999px;
  border: 1px solid var(--border); background: rgba(255, 255, 255, 0.03);
}
.hero-chips .chip:nth-child(1) { border-color: rgba(138, 180, 255, 0.32); background: rgba(138, 180, 255, 0.07); color: #b9cff5; }
.hero-chips .chip:nth-child(2) { border-color: rgba(201, 168, 255, 0.30); background: rgba(201, 168, 255, 0.07); color: #d4c2f2; }
.hero-chips .chip:nth-child(3) { border-color: rgba(255, 159, 190, 0.28); background: rgba(255, 159, 190, 0.06); color: #eec0d0; }
.hero-chips .chip:nth-child(4) { border-color: rgba(255, 207, 152, 0.28); background: rgba(255, 207, 152, 0.06); color: #ecd4b4; }

/* Staggered entrance for the hero copy. */
.rise { opacity: 0; transform: translateY(14px); animation: rise-in 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) forwards; }
.rise.r1 { animation-delay: 0.05s; } .rise.r2 { animation-delay: 0.14s; }
.rise.r3 { animation-delay: 0.24s; } .rise.r4 { animation-delay: 0.34s; }
.rise.r5 { animation-delay: 0.44s; }
@keyframes rise-in { to { opacity: 1; transform: none; } }

/* The hero visual — a slowly orbiting echo of the real 3D gallery. */
.hero-visual { position: relative; flex: 1 1 340px; min-width: 300px; height: 400px; pointer-events: none; }
@media (max-width: 960px) {
  .hero-visual { margin-top: 46px; } /* keep orbiting cards clear of the copy when wrapped */
}
.orbit-web { position: absolute; inset: 0; width: 100%; height: 100%; animation: web-pulse 6s ease-in-out infinite; }
.orbit-core {
  position: absolute; left: 50%; top: 50%; width: 112px; height: 112px; margin: -56px 0 0 -56px;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 32%, #b9d2ff 0%, #6f8fd8 34%, #1d2c55 72%, #0c1428 100%);
  box-shadow: 0 0 70px 10px rgba(120, 160, 255, 0.22), inset 0 0 24px rgba(255, 255, 255, 0.12);
  animation: core-breathe 7s ease-in-out infinite;
}
.orbit-ring {
  position: absolute; left: 50%; top: 50%; width: 350px; height: 216px; margin: -108px 0 0 -175px;
  border: 1px solid rgba(255, 255, 255, 0.09); border-radius: 50%;
  transform: rotate(-16deg);
}
.orbit-ring.r2 { width: 260px; height: 160px; margin: -80px 0 0 -130px; transform: rotate(22deg); border-style: dashed; border-color: rgba(255, 159, 190, 0.16); opacity: 0.7; }

/* The rotor slowly revolves the cards around the core; each card counter-spins
   so its "photo" stays upright, and gently floats on its own phase. */
.orbit-rotor { position: absolute; inset: 0; animation: spin 80s linear infinite; }
.orbit-card { position: absolute; animation: spin-rev 80s linear infinite; }
.orbit-card > i {
  display: block; width: 100%; height: 100%; border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 18px 40px -16px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  animation: card-float 9s ease-in-out infinite;
}
.orbit-card.c1 { left: 1%;  top: 10%;   width: 118px; height: 79px; }
.orbit-card.c2 { right: 4%; top: 4%;    width: 96px;  height: 64px; }
.orbit-card.c3 { right: -2%; top: 50%;  width: 112px; height: 75px; }
.orbit-card.c4 { left: 5%;  bottom: 6%; width: 104px; height: 70px; }
.orbit-card.c5 { right: 20%; bottom: 0; width: 88px;  height: 59px; }
/* Real sample moments (optimized stills served same-origin). */
.orbit-card > i { background-size: cover; background-position: center; }
.orbit-card.c1 > i { background-image: url("/landing/s1.jpg"); animation-delay: 0s; }
.orbit-card.c2 > i { background-image: url("/landing/s2.jpg"); animation-delay: -1.8s; }
.orbit-card.c3 > i { background-image: url("/landing/s3.jpg"); animation-delay: -3.4s; }
.orbit-card.c4 > i { background-image: url("/landing/s4.jpg"); animation-delay: -5.1s; }
.orbit-card.c5 > i { background-image: url("/landing/s5.jpg"); animation-delay: -6.7s; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spin-rev { to { transform: rotate(-360deg); } }
@keyframes card-float {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-12px) rotate(2deg); }
}
@keyframes core-breathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}
@keyframes web-pulse {
  0%, 100% { opacity: 0.55; }
  50% { opacity: 1; }
}

/* Scroll-reveal for below-the-fold sections. */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .orbit-card, .orbit-core, .orbit-rotor, .orbit-card > i, .orbit-web { animation: none; }
  .rise { animation: none; opacity: 1; transform: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-bottom: 18px; }
.feature { padding: 26px 24px; position: relative; overflow: hidden; transition: transform 0.18s ease, border-color 0.18s ease; }
.feature { --f-hue: 138, 180, 255; }
.features .feature:nth-child(2) { --f-hue: 255, 159, 190; }
.features .feature:nth-child(3) { --f-hue: 255, 207, 152; }
.feature::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--f-hue), 0.6), transparent);
  opacity: 0; transition: opacity 0.25s ease;
}
.feature:hover { transform: translateY(-3px); border-color: rgba(var(--f-hue), 0.35); }
.feature:hover::before { opacity: 1; }
.feature .f-chip {
  width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 21px; margin-bottom: 14px;
  background: linear-gradient(180deg, rgba(var(--f-hue), 0.17), rgba(var(--f-hue), 0.05));
  border: 1px solid rgba(var(--f-hue), 0.26);
}
.kicker { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: 1.6px; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.feature .kicker { color: rgb(var(--f-hue)); }
.feature h3 { margin: 0 0 8px; font-size: 15.5px; font-weight: 650; color: var(--text); text-transform: none; letter-spacing: 0; }
.feature p { margin: 0; font-size: 13px; line-height: 1.6; }

.how { display: flex; align-items: center; gap: 18px; padding: 20px 24px; flex-wrap: wrap; margin-bottom: 34px; }
.how-step { display: flex; align-items: center; gap: 12px; }
.how-step .num {
  display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px;
  border-radius: 50%; font-size: 12.5px; font-weight: 700; flex: 0 0 auto;
  background: linear-gradient(180deg, var(--accent-strong), var(--accent)); color: #0a1120;
}
.how .how-step:nth-of-type(2) .num { background: linear-gradient(180deg, #ddc8ff, var(--hue-violet)); }
.how .how-step:nth-of-type(3) .num { background: linear-gradient(180deg, #ffc4d6, var(--hue-rose)); }
.how-step b { font-size: 13.5px; }
.how-step p { margin: 1px 0 0; }
.how-sep { width: 26px; height: 1px; background: var(--border); }

/* ---- Pricing ------------------------------------------------------------- */
.pricing { display: flex; gap: 34px; align-items: center; flex-wrap: wrap; margin-bottom: 40px; }
.marketing-plan-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; flex: 1 1 380px; min-width: 300px; }
.price-card { flex: 0 1 380px; min-width: 300px; padding: 28px 26px; position: relative; }
.marketing-plan-list .price-card { min-width: 0; }
.price-card h3 { margin: 8px 0 0; font-size: 19px; }
.price-card::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, transparent 4%, rgba(138, 180, 255, 0.7) 30%, rgba(201, 168, 255, 0.7) 55%, rgba(255, 159, 190, 0.6) 80%, transparent 96%);
}
.price-line { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 4px; }
.price { font-size: 52px; font-weight: 700; letter-spacing: -2px;
  background: linear-gradient(180deg, #fff 30%, #aebbd6);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.per { font-size: 12.5px; line-height: 1.35; color: var(--dim); font-weight: 600; }
.price-list { list-style: none; margin: 18px 0 22px; padding: 0; display: grid; gap: 10px; }
.price-list li { display: flex; align-items: flex-start; gap: 9px; font-size: 13px; color: var(--dim); line-height: 1.5; }
.price-list li > svg { width: 17px; height: 17px; margin-top: 1px; padding: 3px; border-radius: 50%; background: rgba(127, 233, 176, 0.16); color: var(--good); }
.price-pitch { flex: 1 1 380px; min-width: 300px; }
.price-pitch h2 { font-size: clamp(24px, 3.2vw, 34px); line-height: 1.15; font-weight: 700; letter-spacing: -0.5px; margin: 0 0 14px; }
.price-pitch p { max-width: 460px; line-height: 1.7; margin: 0; }

/* ---- Closing CTA band ---------------------------------------------------- */
.cta-band {
  text-align: center; padding: 46px 28px; margin-bottom: 8px; position: relative; overflow: hidden;
}
.cta-band::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(420px 200px at 38% 0%, rgba(120, 160, 255, 0.12), transparent 70%),
    radial-gradient(380px 190px at 68% 0%, rgba(220, 130, 170, 0.10), transparent 70%);
}
.cta-band h2 { font-size: clamp(24px, 3.4vw, 36px); line-height: 1.15; font-weight: 700; letter-spacing: -0.5px; margin: 0 0 22px; }

#view-auth .auth-card .back { margin-bottom: 6px; }
.legal-line { margin: 14px 0 4px; text-align: center; line-height: 1.55; }
.legal-line a { color: var(--dim); text-decoration: underline; text-underline-offset: 2px; }
.legal-line a:hover { color: var(--text); }
.auth-consent { display: flex; align-items: flex-start; gap: 10px; margin: 14px 0; color: var(--dim); font-size: 12px; line-height: 1.5; cursor: pointer; }
.auth-consent input { width: auto; margin: 3px 0 0; accent-color: var(--accent); flex: 0 0 auto; }
.auth-consent a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.auth-consent a:hover { color: var(--text); }

.site-footer {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--border);
}
.site-footer nav { display: flex; gap: 18px; }
.site-footer nav a { color: var(--dim); text-decoration: none; font-weight: 600; }
.site-footer nav a:hover { color: var(--text); text-decoration: underline; }

/* ---- Bright (signed-out / marketing) theme -------------------------------
   Applied to <body> on the landing, auth, and legal pages: a warm, airy cream
   surface that reads friendly and giftable, while the signed-in studio keeps
   its dark premium look. Most components restyle themselves via the vars. */
body.bright {
  --glass: rgba(255, 255, 255, 0.78);
  --glass-hi: rgba(255, 255, 255, 0.95);
  --panel-2: rgba(28, 38, 62, 0.05);
  --border: rgba(28, 38, 62, 0.13);
  --border-hi: rgba(28, 38, 62, 0.24);
  --text: #202839;
  --dim: #5c6579;
  --accent: #9f513d;
  --accent-strong: #b9684d;
  --shadow: 0 22px 44px -26px rgba(46, 64, 110, 0.28);
  --control-bg: rgba(28, 38, 62, 0.05);
  --control-bg-hover: rgba(28, 38, 62, 0.09);
  --control-bg-pressed: rgba(28, 38, 62, 0.07);
  --focus-ring: rgba(159, 81, 61, .42);
  --danger-bg: rgba(201, 70, 80, 0.08);
  --danger-bg-hover: rgba(201, 70, 80, 0.14);
  background:
    radial-gradient(950px 620px at 8% 10%, rgba(225, 157, 112, .3), transparent 62%),
    radial-gradient(860px 580px at 90% 8%, rgba(132, 165, 148, .24), transparent 62%),
    radial-gradient(900px 620px at 50% 112%, rgba(105, 139, 154, .16), transparent 60%),
    #fbf5ea;
  color: var(--text);
  font-weight: 520;
}
body.bright header.top { background: rgba(250, 247, 242, 0.82); }
body.bright .hero::before {
  background:
    radial-gradient(560px 320px at 78% 28%, rgba(120, 156, 255, 0.13), transparent 70%),
    radial-gradient(500px 300px at 10% 22%, rgba(255, 150, 180, 0.12), transparent 70%),
    radial-gradient(460px 280px at 55% 94%, rgba(255, 190, 120, 0.12), transparent 70%);
}
body.bright .hero-title,
body.bright .price {
  background: linear-gradient(180deg, #222a3d 30%, #45526e);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
body.bright .orbit-ring { border-color: rgba(40, 54, 90, 0.16); }
body.bright .orbit-ring.r2 { border-color: rgba(225, 110, 150, 0.22); }
body.bright .orbit-card > i { border-color: rgba(255, 255, 255, 0.9); }
body.bright .hero-chips .chip:nth-child(1) { color: #3c66c8; background: rgba(90, 130, 230, 0.09); }
body.bright .hero-chips .chip:nth-child(2) { color: #7a52c8; background: rgba(150, 110, 230, 0.09); }
body.bright .hero-chips .chip:nth-child(3) { color: #c04a78; background: rgba(230, 110, 150, 0.09); }
body.bright .hero-chips .chip:nth-child(4) { color: #a2691e; background: rgba(230, 170, 90, 0.11); }
body.bright .feature { --f-hue: 70, 110, 220; }
body.bright .features .feature:nth-child(2) { --f-hue: 208, 78, 128; }
body.bright .features .feature:nth-child(3) { --f-hue: 186, 120, 34; }
body.bright :is(button, .btnlink).primary {
  color: #ffffff;
  background: #7d382a;
  box-shadow: 0 10px 22px -10px rgba(91, 43, 32, .55);
}
body.bright :is(button, .btnlink).primary:hover { color: #fff; filter: none; background: #672d22; }
body.bright .social-btn { background: rgba(28, 38, 62, 0.04); }
body.bright .price-list li::before { background: rgba(29, 158, 99, 0.14); color: #1d9e63; }
body.bright #toast { background: rgba(255, 255, 255, 0.95); color: var(--text); box-shadow: var(--shadow); }
body.bright .eyebrow .dot,
body.bright .brand .dot { background: conic-gradient(from 210deg, #c86c4b, #dfa45b, #91a58e, #6f92a0, #c86c4b); box-shadow: 0 0 9px rgba(160, 91, 62, .32); }

/* ---- Light studio -------------------------------------------------------
   The signed-in workspace follows the device on first visit and can be
   changed from the header. Unlike the warm marketing theme, this is a neutral
   working surface so photos keep their true visual weight. */
body.studio-light {
  --bg: #fbf5ea;
  --glass: rgba(255, 255, 255, 0.78);
  --glass-hi: rgba(255, 255, 255, 0.95);
  --panel-2: rgba(28, 38, 62, 0.05);
  --border: rgba(28, 38, 62, 0.13);
  --border-hi: rgba(28, 38, 62, 0.24);
  --text: #202839;
  --dim: #5c6579;
  --accent: #9f513d;
  --accent-strong: #b9684d;
  --good: #286b50;
  --warn: #99611d;
  --bad: #c94650;
  --shadow: 0 22px 48px -30px rgba(29, 46, 83, 0.32);
  --control-bg: rgba(28, 38, 62, 0.05);
  --control-bg-hover: rgba(28, 38, 62, 0.09);
  --control-bg-pressed: rgba(28, 38, 62, 0.07);
  --focus-ring: rgba(159, 81, 61, .42);
  --danger-bg: rgba(201, 70, 80, 0.08);
  --danger-bg-hover: rgba(201, 70, 80, 0.14);
  background:
    radial-gradient(950px 620px at 8% 10%, rgba(225, 157, 112, .22), transparent 62%),
    radial-gradient(860px 580px at 90% 8%, rgba(132, 165, 148, .18), transparent 62%),
    var(--bg);
}
body.studio-light header.top { background: rgba(250, 247, 242, 0.88); }
body.studio-light :is(button, .btnlink).primary {
  color: #fff;
  background: #7d382a;
  box-shadow: 0 10px 22px -12px rgba(91, 43, 32, .55);
}
body.studio-light :is(button, .btnlink).primary:hover { color: #fff; }
body.studio-light :is(button, .btnlink).good { color: #fff; background: linear-gradient(180deg, #197f58, var(--good)); }
body.studio-light :is(button, .btnlink).good:hover { color: #fff; }
body.studio-light input:focus,
body.studio-light textarea:focus { background: rgba(28, 38, 62, 0.035); }
body.studio-light .modal-card {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 28px 80px -32px rgba(20, 34, 64, 0.45);
}
body.studio-light #toast { background: rgba(255, 255, 255, 0.97); color: var(--text); box-shadow: var(--shadow); }

/* ---- Legal pages --------------------------------------------------------- */
.legal-wrap { max-width: 760px; }
.legal-wrap h1 { font-size: 28px; margin-bottom: 2px; }
.legal-wrap h2 { font-size: 15.5px; margin: 28px 0 8px; color: var(--text); }
.legal-wrap p { color: var(--dim); line-height: 1.7; margin: 0 0 10px; }
.legal-wrap p b { color: var(--text); font-weight: 600; }
.legal-wrap a { text-decoration: underline; text-underline-offset: 2px; }
.legal-wrap ul { color: var(--dim); line-height: 1.7; margin: 0 0 10px; padding-left: 20px; }
.legal-wrap li { margin-bottom: 6px; }
.legal-wrap li b { color: var(--text); font-weight: 600; }
/* The pre-launch placeholder notices, and anything else a reader must not skim past. */
.legal-callout {
  border: 1px solid rgba(138, 180, 255, 0.3); background: rgba(138, 180, 255, 0.07);
  border-radius: 10px; padding: 14px 16px; margin: 18px 0;
  color: var(--dim); line-height: 1.7; font-size: 13.5px;
}
.legal-callout b { color: var(--text); }
/* Subprocessors and the rights table. Scrolls rather than forcing the page wide.
   Uses --border/--panel-2 so it reads correctly on the light legal pages
   (body.bright) as well as the dark studio. */
.legal-table { width: 100%; border-collapse: collapse; margin: 12px 0 16px; font-size: 13px; }
.legal-table th, .legal-table td {
  border: 1px solid var(--border); padding: 8px 10px;
  text-align: left; vertical-align: top; color: var(--dim); line-height: 1.6;
}
.legal-table th { color: var(--text); font-weight: 600; background: var(--panel-2); }
.legal-table td b { color: var(--text); font-weight: 600; }
@media (max-width: 620px) {
  .legal-table { display: block; overflow-x: auto; white-space: nowrap; }
  .legal-table td, .legal-table th { white-space: normal; min-width: 130px; }
}

/* ---- Social sign-in ------------------------------------------------------ */
.or { display: flex; align-items: center; gap: 12px; margin: 16px 0 12px; color: var(--dim); font-size: 11.5px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.social { display: flex; flex-direction: column; gap: 8px; }
.social-btn {
  width: 100%; justify-content: center; gap: 9px; padding: 10px 14px;
  background: var(--control-bg); font-weight: 650;
}
.social-btn .s-ic { font-weight: 800; font-size: 14px; opacity: 0.9; }
/* Apple's sign-in button is deliberately monochrome to preserve its distinct
   brand treatment even when Gallmo is using the light theme. */
.social-btn.social-apple, body.bright .social-btn.social-apple {
  color: #fff; background: #000; border-color: #000;
}
.social-btn.social-apple:hover, body.bright .social-btn.social-apple:hover {
  color: #fff; background: #1d1d1f; border-color: #1d1d1f;
}

/* ---- Modals ------------------------------------------------------------- */
.modal { position: fixed; inset: 0; z-index: 150; display: none; align-items: center; justify-content: center; padding: 24px; background: rgba(4, 6, 11, 0.72); backdrop-filter: blur(10px); }
.modal.open { display: flex; }
.modal-card { width: 100%; max-width: 420px; padding: 24px; border-radius: var(--radius); overflow-y: auto; overscroll-behavior: contain;
  background: linear-gradient(180deg, var(--glass-hi), rgba(255, 255, 255, 0.012)), rgba(16, 20, 30, 0.96);
  border: 1px solid var(--border); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), var(--shadow);
  animation: pop 0.2s cubic-bezier(0.2, 0.7, 0.2, 1); }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: none; } }
.modal-head {
  position: sticky; top: -24px; z-index: 4; display: flex; align-items: flex-start;
  justify-content: space-between; gap: 14px; margin: -24px -24px 18px; padding: 18px 24px 14px;
  border-bottom: 1px solid var(--border); background: rgba(16, 20, 30, 0.985);
}
body.studio-light .modal-head, body.studio-light .modal-footer { background: rgba(255, 255, 255, 0.99); }
.modal-head h2 { margin: 3px 0 0; font-size: 19px; }
.modal-head .kicker { display: block; }
.modal-body { min-height: 0; }
.modal-footer {
  position: sticky; bottom: -24px; z-index: 4; margin: 18px -24px -24px; padding: 14px 24px 18px;
  border-top: 1px solid var(--border); background: rgba(16, 20, 30, 0.985);
}
.modal-footer button { min-width: 112px; }

/* ---- Customer subscriptions ------------------------------------------- */
.subscriptions-shell { max-width: 1080px; }
.subscription-page-head { align-items: flex-start; }
.subscription-page-head .back { margin-bottom: 18px; }
.subscription-page-head h1 { margin-top: 4px; font-size: clamp(26px, 5vw, 36px); }
.subscription-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 18px 0 24px; }
.subscription-metric { display: flex; gap: 12px; align-items: flex-start; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--glass); }
.subscription-metric > svg { width: 20px; height: 20px; margin-top: 3px; color: var(--accent); }
.subscription-metric span, .subscription-metric small { display: block; color: var(--dim); font-size: 11.5px; }
.subscription-metric b { display: block; margin: 2px 0; font-size: 24px; }
.subscription-list { display: grid; gap: 12px; }
.subscription-card { padding: 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--glass); }
.subscription-card-head { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.subscription-card-head h2 { margin: 0; font-size: 16px; }
.subscription-card-head p { margin: 2px 0 0; }
.subscription-card-icon { width: 42px; height: 42px; display: grid; place-items: center; color: var(--accent); border-radius: 12px; background: rgba(138, 180, 255, 0.1); }
.subscription-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 18px 0 14px; }
.subscription-facts > div { padding: 11px 12px; border-radius: 10px; background: var(--panel-2); }
.subscription-facts span, .subscription-facts small { display: block; color: var(--dim); font-size: 10.5px; }
.subscription-facts b { display: block; margin: 3px 0; font-size: 15px; }
.subscription-capacity { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 10px; }
.subscription-capacity > span { height: 6px; overflow: hidden; border-radius: 999px; background: var(--panel-2); }
.subscription-capacity i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.subscription-capacity small { color: var(--dim); }
.subscription-card-actions { display: flex; justify-content: flex-end; margin-top: 14px; }
@media (max-width: 700px) {
  .subscription-summary, .subscription-facts { grid-template-columns: 1fr; }
  .subscription-card-head { grid-template-columns: 42px minmax(0, 1fr); }
  .subscription-card-head .badge { grid-column: 2; justify-self: start; }
  .subscription-card-actions button { width: 100%; }
}

@media (hover: none) {
  button:hover, .btnlink:hover, .gallery-card:hover { transform: none; }
}

/* ---- Billing plan picker ------------------------------------------------ */
.plan-picker { display: grid; gap: 9px; margin: 16px 0; }
.plan-choice { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid var(--border); border-radius: 11px; background: var(--panel-2); cursor: pointer; }
.plan-choice:has(input:checked) { border-color: rgba(138, 180, 255, 0.65); background: rgba(138, 180, 255, 0.08); }
.plan-choice input, .renew-choice input { width: auto; margin: 4px 0 0; accent-color: var(--accent); }
.plan-choice span, .renew-choice span { display: grid; gap: 2px; }
.plan-choice small, .renew-choice small { color: var(--dim); font-size: 12px; }
.renew-choice { display: flex; align-items: flex-start; gap: 10px; padding: 12px 0 18px; margin: 0; color: var(--text); cursor: pointer; }
.renew-choice.consent-choice { border-top: 1px solid var(--line); padding-top: 16px; }

.admin-plan-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 12px; margin: 0 0 18px; }
.admin-plan {
  display: grid; gap: 14px; padding: 17px; border: 1px solid var(--border);
  border-radius: 13px; background: var(--panel-2);
}
.admin-plan-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.admin-plan h3 { margin: 4px 0 0; font-size: 16px; }
.admin-plan-id { color: var(--dim); font: 10px/1.2 var(--mono); }
.admin-plan-price { font-size: 26px; font-weight: 700; letter-spacing: -0.03em; }
.admin-plan-price small { display: block; margin-top: 2px; color: var(--dim); font-size: 11px; font-weight: 500; letter-spacing: 0; }
.admin-plan-facts { display: grid; gap: 8px; margin: 0; }
.admin-plan-facts > div { display: flex; justify-content: space-between; gap: 12px; padding-top: 8px; border-top: 1px solid var(--border); }
.admin-plan-facts dt { color: var(--dim); font-size: 11px; }
.admin-plan-facts dd { margin: 0; text-align: right; font-size: 11.5px; }
.admin-plan-actions { display: flex; gap: 7px; flex-wrap: wrap; }
.admin-plan-actions button { flex: 1 1 auto; justify-content: center; }
.modal-title-row { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 6px; }
.modal-title-row h2 { margin: 4px 0 0; }
.admin-modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 16px; }
.admin-modal-grid .field { margin: 0; }
.admin-modal-grid .wide { grid-column: 1 / -1; }
.admin-modal-grid .field > small { display: block; margin-top: 5px; color: var(--dim); font-size: 10.5px; }
.admin-check { display: flex; align-items: flex-start; gap: 10px; padding: 11px; margin: 14px 0; border: 1px solid var(--border); border-radius: 10px; background: var(--panel-2); color: var(--text); }
.admin-check input { width: auto; margin: 3px 0 0; accent-color: var(--accent); }
.admin-check span { display: grid; gap: 2px; }
.admin-check small { color: var(--dim); font-size: 11px; }
@media (max-width: 560px) { .admin-modal-grid { grid-template-columns: 1fr; } .admin-modal-grid .wide { grid-column: auto; } }

/* ---- Toast -------------------------------------------------------------- */
#toast {
  position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(10px);
  background: rgba(20, 24, 34, 0.92); border: 1px solid var(--border); backdrop-filter: blur(12px);
  padding: 11px 18px; border-radius: 11px; font-size: 13px; font-weight: 500;
  opacity: 0; visibility: hidden; transition: opacity 0.2s, transform 0.2s; z-index: 300; box-shadow: var(--shadow);
}
#toast.show { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
#toast.bad { border-color: rgba(255, 138, 138, 0.5); color: var(--bad); }

/* Accessibility preferences ------------------------------------------------
   Keep the interface usable when the operating system requests stronger
   contrast, reduced motion, or forced system colors. */
@media (prefers-contrast: more) {
  :root {
    --border: rgba(255, 255, 255, 0.28);
    --border-hi: rgba(255, 255, 255, 0.5);
    --dim: #c3ccdd;
    --focus-ring: rgba(182, 208, 255, 0.9);
  }
  body.bright, body.studio-light {
    --border: rgba(23, 32, 51, 0.32);
    --border-hi: rgba(23, 32, 51, 0.58);
    --dim: #3f4a60;
    --focus-ring: rgba(35, 80, 190, 0.78);
  }
  button, .btnlink, input, textarea, select { box-shadow: none; }
}

@media (forced-colors: active) {
  * { forced-color-adjust: auto; }
  button, .btnlink, input, textarea, select, .card, .modal-card, .account-popover {
    border: 1px solid ButtonText;
  }
  :focus-visible { outline: 3px solid Highlight !important; outline-offset: 3px !important; }
  .primary, .good, .bad { forced-color-adjust: none; color: ButtonText !important; background: ButtonFace !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
