.auth-page { min-height: 100vh; display: flex; flex-direction: column; }
.auth-page .background-grid { height: 100vh; opacity: .65; }
.auth-header-link { color: #a0a0aa; font-size: 13px; font-weight: 600; }
.auth-header-link:hover { color: #fff; }
.auth-header-link span { margin-left: 10px; }
.auth-layout { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 430px); align-items: center; gap: 90px; flex: 1; padding-block: 78px 100px; }
.auth-intro { align-self: center; }
.auth-overline { color: #98a0ff; font-size: 10px; font-weight: 700; letter-spacing: .16em; }
.auth-intro h1 { margin: 19px 0 24px; font-size: clamp(54px, 6vw, 79px); font-weight: 600; line-height: 1.04; letter-spacing: -.064em; }
.auth-intro h1 span { color: #a6a7c7; }
.auth-intro p { max-width: 400px; margin: 0; color: #a0a0aa; font-size: 16px; line-height: 1.7; }
.auth-intro > a { display: inline-block; margin-top: 32px; color: #b5bbff; font-size: 13px; font-weight: 600; }
.auth-intro > a span { margin-left: 10px; }
.auth-panel { padding: 36px; border: 1px solid #2d2d37; border-radius: 18px; background: #141418; box-shadow: 0 24px 70px rgba(0,0,0,.28); }
.auth-panel h2 { margin: 0 0 8px; font-size: 25px; font-weight: 600; letter-spacing: -.04em; }
.panel-intro { margin: 0 0 31px; color: #8e8e9b; font-size: 13px; line-height: 1.6; }
.auth-panel form { display: flex; flex-direction: column; }
.auth-panel form[hidden], .auth-panel form [hidden] { display: none; }
.mail-fields { display: flex; flex-direction: column; }
.auth-submit:disabled { opacity: .65; cursor: wait; }
.auth-panel label { margin: 0 0 9px; color: #d6d6df; font-size: 12px; font-weight: 600; }
.auth-panel input { display: block; width: 100%; height: 45px; margin: 0 0 21px; padding: 0 13px; border: 1px solid #34343f; border-radius: 8px; outline: none; background: #1b1b21; color: #f7f7f8; font: inherit; font-size: 13px; }
.auth-panel input::placeholder { color: #6f6f7c; }
.auth-panel input:focus { border-color: #8f97ff; box-shadow: 0 0 0 3px rgba(88,101,242,.14); }
.auth-panel input[aria-invalid="true"] { border-color: #d67785; }
.password-field { position: relative; }
.password-field input { padding-right: 83px; }
.password-toggle { position: absolute; top: 9px; right: 10px; padding: 5px 2px; border: 0; background: transparent; color: #a5a5b2; font-size: 11px; }
.password-toggle:hover { color: #fff; }
.auth-submit { display: flex; align-items: center; justify-content: space-between; height: 48px; margin-top: 6px; padding: 0 16px; border: 0; border-radius: 8px; background: #5865f2; color: #fff; font-size: 13px; font-weight: 700; }
.auth-submit:hover { background: #707bff; }
.auth-submit span { font-size: 19px; font-weight: 400; }
.auth-status { margin: 17px 0 0; padding: 12px 13px; border-radius: 8px; background: #242430; color: #cdd1ff; font-size: 12px; line-height: 1.6; }
.auth-status.is-error { background: #2b2026; color: #eeb5bf; }
.auth-divider { margin: 20px 0 12px; color: #858591; text-align: center; font-size: 12px; }
.discord-auth-button { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 46px; padding: 10px 16px; border: 1px solid #626de2; border-radius: 8px; background: #232746; color: #fff; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.discord-auth-button:hover { background: #30365d; }
.discord-auth-button:focus-visible { outline: 2px solid #aeb5ff; outline-offset: 3px; }
.discord-auth-button:disabled { opacity: .65; cursor: wait; }
.auth-panel .merge-confirm { display: flex; align-items: flex-start; gap: 10px; margin: 1px 0 17px; color: #d6d9f0; line-height: 1.5; }
.auth-panel .merge-confirm[hidden] { display: none; }
.auth-panel .merge-confirm input { width: 17px; height: 17px; flex: 0 0 17px; margin: 1px 0 0; accent-color: #6874ff; }
.auth-switch { margin: 26px 0 0; color: #858591; text-align: center; font-size: 12px; }
.auth-switch a { margin-left: 3px; color: #c4c8ff; font-weight: 600; }
.auth-switch a:hover { color: #fff; }
.auth-footer { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 75px; color: #666673; font-size: 11px; }
.auth-footer a:hover { color: #fff; }
.auth-footer { flex-wrap: wrap; padding-block: 20px; }
.auth-footer nav { display: flex; flex-wrap: wrap; gap: 12px 20px; }
.auth-footer a:focus-visible { outline: 2px solid #a8afff; outline-offset: 4px; }

@media (max-width: 900px) {
  .auth-layout { grid-template-columns: 1fr 1fr; gap: 45px; }
  .auth-intro h1 { font-size: clamp(48px, 6vw, 68px); }
}

@media (max-width: 700px) {
  .auth-layout { display: block; padding-block: 55px 75px; }
  .auth-intro { margin-bottom: 40px; }
  .auth-intro h1 { font-size: clamp(47px, 11vw, 65px); }
  .auth-intro p { font-size: 14px; }
  .auth-intro > a { margin-top: 22px; }
  .auth-panel { max-width: 470px; padding: 28px; }
}

@media (max-width: 430px) {
  .auth-layout { padding-top: 43px; }
  .auth-intro h1 { font-size: 45px; }
  .auth-panel { padding: 24px 20px; }
}
