@font-face {
  font-family: Inter;
  src: url("./assets/inter.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("./assets/display.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

.account-page {
  --tkui-font: Inter, "Helvetica Neue", Arial, sans-serif;
  --tkui-ink: #1b1915;
  --tkui-muted: #645f56;
  --tkui-line: #d4cfc5;
  --tkui-accent: #795b20;
  --display: "Bricolage Grotesque", Inter, sans-serif;
  min-height: 100vh;
  margin: 0;
  background: #faf9f6;
  -webkit-font-smoothing: antialiased;
}

.account-layout {
  width: min(100%, 1440px);
  margin: 0 auto;
  padding: 0 clamp(24px, 4.8vw, 76px) clamp(24px, 4vw, 64px);
}

.account-mast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: clamp(78px, 12vh, 108px);
}

.account-brand {
  display: flex;
  align-items: center;
  gap: 0.22em;
  color: var(--tkui-ink);
  white-space: nowrap;
  font: 780 clamp(1.4rem, 2.3vw, 2rem)/1 var(--display);
  letter-spacing: -0.066em;
}

.account-brand img { display: block; width: 1.1em; height: 1.1em; }
.account-brand b { font-weight: 430; }
.account-page svg { display: block; flex: none; width: 18px; height: 18px; }

.account-page .account-back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 42px;
  color: var(--tkui-muted);
  font-size: 0.875rem;
  font-weight: 570;
  text-decoration: none;
}

.account-back svg { width: 15px; height: 15px; }
.account-page .account-back:hover { color: var(--tkui-ink); text-decoration: underline; text-underline-offset: 4px; }

.account-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  padding: 9px;
  background: #fff;
  border: 1px solid #e1dcd2;
  border-radius: 26px;
}

.account-pane {
  display: grid;
  min-width: 0;
  align-items: center;
  justify-items: center;
  padding: clamp(30px, 4.5vw, 68px);
}

.account-content { width: 100%; max-width: 404px; }
.account-page p { margin: 0; }

.account-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #6a6355;
  font-size: 0.875rem;
  font-weight: 590;
}

.account-page h1 {
  margin: 16px 0 10px;
  font: 700 clamp(2.7rem, 4vw, 3.7rem)/1.02 var(--display);
  letter-spacing: -0.055em;
}

.account-description { color: var(--tkui-muted); font-size: 1rem; line-height: 1.55; }

#account-form { display: grid; gap: 18px; margin-top: clamp(24px, 3.2vh, 34px); }
.account-field { min-width: 0; }

.account-field label {
  display: block;
  margin-bottom: 7px;
  font-size: 0.9rem;
  font-weight: 630;
}

.account-input-wrap { position: relative; }
.account-input-wrap .account-input-icon {
  position: absolute;
  top: 50%;
  left: 14px;
  color: #756f64;
  transform: translateY(-50%);
  pointer-events: none;
}

.account-input-wrap input {
  width: 100%;
  min-width: 0;
  height: 49px;
  padding: 8px 14px 8px 42px;
  border: 1px solid var(--tkui-line);
  border-radius: 9px;
  color: var(--tkui-ink);
  background: #fff;
  font: 400 1rem/1.4 var(--tkui-font);
}

#account-password { padding-right: 104px; }
.account-input-wrap input::placeholder { color: #777166; opacity: 1; }

.account-reveal {
  position: absolute;
  top: 3px;
  right: 3px;
  bottom: 3px;
  padding: 0 8px;
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: var(--tkui-muted);
  font-size: 0.83rem;
  font-weight: 600;
  cursor: pointer;
}

.account-reveal:hover { background: #f3f1eb; }
.account-page :focus-visible { outline: 2px solid #89691f; outline-offset: 3px; }
.account-input-wrap input:focus-visible { border-color: #8a702f; outline-offset: 1px; }
.account-input-wrap input[aria-invalid="true"] { border-color: #92372c; }

.account-page .account-submit,
.account-page .account-sso {
  width: 100%;
  min-height: 48px;
  justify-content: center;
  border-radius: 9px;
  font-size: 0.94rem;
  font-weight: 620;
}

.account-page .account-submit { margin-top: 3px; border-color: #25231f; background: #25231f; color: #fff; }
.account-page .account-submit:hover:not(:disabled) { background: #38352e; }
.account-page .account-sso { margin-top: 10px; border: 1px solid var(--tkui-line); background: #fff; color: var(--tkui-ink); }
.account-page .account-sso:hover { background: #f7f5f0; }
.account-page .account-switch { margin-top: 20px; font-size: 0.9rem; color: var(--tkui-muted); }
.account-switch a { margin-left: 3px; font-weight: 640; text-underline-offset: 0.22em; }

.account-page .account-error {
  padding: 10px 13px;
  border-left: 3px solid #a64f32;
  border-radius: 6px;
  color: #713224;
  background: #fbf1eb;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}
.account-page noscript .account-error { margin-top: 16px; }

.account-art {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: clamp(520px, 73vh, 760px);
  border-radius: 18px;
  background: #201b13 url("./assets/brass.webp") 52% center/cover no-repeat;
}

.account-art::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background: linear-gradient(125deg, #17140d99, #17140d22 45%, transparent 67%);
}

.account-art-title {
  margin: clamp(32px, 4.2vw, 68px);
  color: #fff9ec;
  font: 560 clamp(3.8rem, 7vw, 6.6rem)/0.92 var(--display);
  letter-spacing: -0.065em;
}

.account-art-title span { display: block; }
.account-art-title b { color: #e4b653; font-weight: inherit; }

@media (max-width: 840px) {
  .account-layout { padding-inline: 24px; }
  .account-shell { grid-template-columns: minmax(0, 1.13fr) minmax(0, 0.87fr); }
  .account-pane { padding: 30px 22px; }
}

@media (max-width: 660px) {
  .account-page { background: #fff; }
  .account-layout { padding-inline: max(18px, env(safe-area-inset-left)); padding-bottom: max(28px, env(safe-area-inset-bottom)); }
  .account-mast { min-height: 72px; gap: 8px; }
  .account-brand { font-size: clamp(1.1rem, 5.25vw, 1.5rem); }
  .account-back { font-size: 0.82rem; }
  .account-shell { display: flex; flex-direction: column; gap: 26px; padding: 0; border: 0; }
  .account-pane { padding: 0; }
  .account-content { max-width: 460px; }
  .account-art { display: grid; align-items: center; order: -1; min-height: 0; height: clamp(94px, 15vh, 134px); border-radius: 13px; background-position: center 54%; }
  .account-art-title { margin: 0; padding: 0 20px; font-size: clamp(2.15rem, 8vw, 3.1rem); }
  .account-art-title span { display: inline; }
  .account-page h1 { margin-top: 12px; }
}

@media (max-width: 350px) {
  .account-layout { padding-inline: 14px; }
  .account-page .account-back { font-size: 0.76rem; }
}

@media (forced-colors: active) {
  .account-art { border: 1px solid CanvasText; }
  .account-art-title, .account-art-title b { color: CanvasText; }
}

.account-field-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.account-field-head a { font-size: .84rem; font-weight: 590; text-underline-offset: .22em; }
.account-content h1 { overflow-wrap: anywhere; }
.account-description, .account-note { overflow-wrap: anywhere; }
.account-page .account-note {
  margin-top: 18px;
  padding: 14px;
  border-radius: 10px;
  background: #f9f4e8;
  color: #644c1b;
  font-size: .9rem;
}
.account-page #request-help a { margin-left: 0; }
.account-page #request-help:not([hidden]) + .account-switch { margin-top: 12px; }
#account-form[hidden] { display: none; }
