@font-face {
  font-family: "Space Grotesk";
  src: url("/brand/space-grotesk.woff2") format("woff2");
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
}

.account-gate {
  --account-bg: #0d151e;
  --account-ink: #f3f7f8;
  --account-muted: #bccbd4;
  --account-edge: #3a505d;
  --account-accent: #a4eed3;
  --account-gutter: clamp(19px, 5.8vw, 96px);
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  color-scheme: dark;
  color: var(--account-ink);
  background: radial-gradient(ellipse at right bottom, #172630, transparent 49%), var(--account-bg);
  font-family: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
}
.account-gate :focus-visible { outline: 2px solid var(--account-accent); outline-offset: 4px; }
.account-nav { width: min(calc(100% - 2 * var(--account-gutter)), 1240px); min-height: 74px; margin-inline: auto; display: flex; justify-content: space-between; align-items: center; gap: 17px; border-bottom: 1px solid #2a3e49; }
.account-logo { display: inline-flex; align-items: center; gap: 10px; color: var(--account-ink); text-decoration: none; font-size: 1.27rem; font-weight: 700; letter-spacing: -.035em; white-space: nowrap; }
.account-glyph { display: block; flex: none; width: 33px; height: 33px; object-fit: contain; }
.account-home { color: var(--account-muted); text-decoration: none; font-size: .95rem; }
.account-home:hover { color: var(--account-ink); text-decoration: underline; text-underline-offset: 5px; }

.account-layout { display: grid; grid-template-columns: minmax(0, .89fr) minmax(0, 1.11fr); align-items: center; gap: clamp(28px, 5vw, 73px); flex: 1; width: min(calc(100% - 2 * var(--account-gutter)), 1240px); margin-inline: auto; padding-block: clamp(31px, 5vw, 72px); }
.account-panel { position: relative; width: min(100%, 470px); justify-self: center; padding: clamp(20px, 3.1vw, 44px); border: 1px solid var(--account-edge); border-radius: 13px; background: #15222c; box-shadow: 0 17px 63px #030a105e; }
.account-heading { margin-bottom: 24px; }
.account-heading h1 { color: var(--account-ink); font-size: clamp(2.17rem, 3.6vw, 3.35rem); font-weight: 650; letter-spacing: -.063em; word-spacing: .025em; line-height: 1.02; }
.account-heading > p:not(.account-eyebrow) { margin-top: 11px; color: var(--account-muted); font-size: 1.02rem; line-height: 1.5; }
.account-eyebrow { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; color: var(--account-accent); font: 600 .735rem/1.45 var(--mono); letter-spacing: .085em; text-transform: uppercase; }
.account-eyebrow::before { content: ""; width: 13px; height: 7px; border-block: 2px solid currentColor; transform: skewX(-28deg); }

.account-form { display: grid; gap: 7px; }
.account-form label { color: var(--ink); font-size: .9rem; font-weight: 650; }
.account-form input {
  width: 100%; min-height: 44px; padding: 9px 12px; margin-bottom: 9px;
  background: var(--studio-input, #151521); color: var(--ink); border: 1px solid var(--edge); border-radius: 7px;
}
.account-form small { color: var(--muted); margin: -5px 0 5px; font-size: .8rem; }
.account-gate .account-form label { color: var(--account-ink); }
.account-gate .account-form input { min-height: 49px; margin-bottom: 9px; color: var(--account-ink); background: #0f1923; border-color: #59717d; }
.account-gate .account-form input:focus { border-color: #a5ecd5; outline: 2px solid #94d4c3; outline-offset: 1px; }
.account-gate .account-form small, .account-gate .status { color: var(--account-muted); }
.account-gate .status.is-error { color: #ffbbb6; }
.account-gate .account-form .primary { border: 1px solid var(--account-accent); border-radius: 6px; background: var(--account-accent); color: #132e25; }
.account-gate .account-form .primary:hover { border-color: #c5f8e6; background: #c5f8e6; }
.account-submit { width: 100%; min-height: 49px; margin-top: 4px; }
.account-form .error { margin: 2px 0; min-height: 0; }
.account-gate .account-form .error { color: #ffbbb6; }
.account-form .error:empty { display: none; }
.account-gate #login-passkey { width: 100%; min-height: 45px; margin-top: 10px; border: 1px solid #5b7280; border-radius: 6px; background: #1c2c37; color: var(--account-ink); font-size: .93rem; font-weight: 650; }
.account-gate #login-passkey:hover { background: #29414d; border-color: #8599a3; }
.account-help { margin-top: 20px; padding-top: 13px; border-top: 1px solid var(--account-edge); }
.account-recovery-link { padding: 3px 0; color: var(--account-muted, var(--muted)); background: transparent; border: 0; text-decoration: underline; text-underline-offset: 4px; font-size: .89rem; }
.account-recovery-link:hover { color: var(--account-ink, var(--ink)); }

.account-art { position: relative; min-width: 0; min-height: clamp(365px, 40vw, 570px); overflow: hidden; border: 1px solid #445d68; border-radius: 13px; background: url("/brand/instrument.webp") 62% center / cover no-repeat, #121d28; }
.account-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(156deg, #10313a10, transparent 45%, #0d151e4a); }
.account-gate > .account-panel { margin: clamp(39px, 8vh, 89px) auto; width: min(calc(100% - 2 * var(--account-gutter)), 470px); }

#owner-account { width: min(calc(100% - 24px), 482px); max-height: calc(100dvh - 24px); overflow: auto; }
#owner-account > p { margin-bottom: 18px; color: var(--muted); }
.account-recovery-actions { display: flex; gap: 9px; flex-wrap: wrap; margin-top: 8px; }
#account-status { min-height: 18px; margin-top: 3px; }

body:has(#gate:not([hidden])) #owner-account {
  --ink: #f3f7f8;
  --muted: #bccbd4;
  --edge: #4b646f;
  --ring: #a4eed3;
  --studio-input: #0f1923;
  background: #15222c;
  border-color: #57717d;
}
body:has(#gate:not([hidden])) #owner-account .primary { background: #a4eed3; color: #132e25; }
body:has(#gate:not([hidden])) #owner-account .ghost { background: #1c2c37; border-color: #5b7280; color: #f3f7f8; }

@media (max-width: 790px) {
  .account-layout { grid-template-columns: minmax(0, 1fr); align-items: start; padding-block: clamp(32px, 8vh, 68px) 38px; }
  .account-art { display: none; }
}
@media (max-width: 530px) {
  .account-nav { min-height: 65px; }
  .account-glyph { width: 31px; height: 31px; }
  .account-layout { padding-top: 32px; }
  .account-panel { padding: 22px 17px 19px; border-radius: 10px; }
  .account-heading { margin-bottom: 20px; }
}
@media (max-height: 600px) {
  .account-layout { padding-block: 23px 30px; }
}
