/* Mobile layout shared by sign-in and registration. */
@media screen and (max-width:860px) {
  html { -webkit-text-size-adjust:100%; }
  body {
    min-height:100svh;
    align-items:flex-start;
    padding:20px 16px max(24px, env(safe-area-inset-bottom));
    background-attachment:scroll;
  }
  .login-wrapper {
    grid-template-columns:minmax(0,1fr);
    max-width:560px;
    min-height:0;
  }
  .login-wrapper > *, .form-box, form, .field, .input-wrap { min-width:0; }
  .left-panel { padding:22px 28px; }
  .brand { margin-bottom:10px; gap:10px; }
  .brand-logo { width:40px; height:40px; flex:0 0 40px; }
  .brand-name { font-size:24px; }
  .subtitle { max-width:none; margin-bottom:0; font-size:13px; }
  .feature-list { display:none; }
  .right-panel { padding:28px; align-items:flex-start; }
  .form-box { max-width:none; }
  .form-box :is(.form-eyebrow, h2) { padding-right:44px; }
  .form-box :is(p, .alert, .field-err, .strength-label, .match-label) { overflow-wrap:anywhere; }
  .close-btn { top:14px; right:14px; width:44px; height:44px; }
  .field { margin-bottom:16px; }
  .field label { font-size:13px; margin-bottom:7px; }
  .field input:not([type=checkbox]):not([type=radio]), .verification-form input {
    min-width:0;
    max-width:100%;
    min-height:48px;
    font-size:16px;
    padding:12px 14px;
    scroll-margin-block:24px;
  }
  .input-wrap input { padding-right:72px !important; }
  .toggle-pass { right:4px; min-width:60px; min-height:44px; padding:8px; }
  .btn-primary { min-height:48px; font-size:15px; line-height:1.5; white-space:normal; }
  .btn-clear-link, .cancel-registration-button { min-height:44px; line-height:1.5; padding:10px 6px; }
  .forgot-link { display:inline-flex; align-items:center; min-height:44px; margin-top:2px; }
  .bottom-text { margin-top:20px; padding-top:16px; line-height:1.6; }
  .bottom-text a { display:inline-flex; align-items:center; min-height:44px; }
  .terms-field { padding:12px; }
  .terms-field label { font-size:13px; line-height:1.7; }
  .terms-field input[type=checkbox], .remember-device-row input[type=checkbox] {
    width:20px; height:20px; flex:0 0 20px; margin-top:2px;
  }
  .remember-device-row { display:flex; align-items:flex-start; gap:10px; min-height:44px; padding:12px; font-size:13px; line-height:1.6; }
  .terms-hint { font-size:12px; line-height:1.6; }
  .verification-form input { font-size:22px; letter-spacing:6px; }
  :is(a, button, input):focus-visible { outline:3px solid #2563eb; outline-offset:3px; }
}

@media screen and (max-width:480px) {
  body { padding:12px 12px max(20px, env(safe-area-inset-bottom)); }
  .login-wrapper { border-radius:16px; }
  .left-panel { padding:18px 20px; }
  .right-panel { padding:24px 20px; }
  .brand-name { font-size:22px; }
  .brand-logo { width:36px; height:36px; flex-basis:36px; }
  .form-box h2 { font-size:24px; line-height:1.25; }
  .form-box .desc { line-height:1.6; }
  .close-btn { top:12px; right:12px; }
}
