/* Shared public authentication composition. Form behavior stays page-owned. */
html:has(body.auth-entry) {
  min-height: 100%; height: auto; background: #e9edf1;
  overflow-x: clip; overflow-y: auto;
}
body.auth-entry {
  --lpc-focus: #385f9e;
  --lpc-gold: #6495ed;
  min-height: 100dvh; height: auto; padding: clamp(12px, 2dvh, 24px);
  display: flex; align-items: center; justify-content: center;
  /* Keep the document as the scroll owner. An overflow-x:hidden body creates
     a non-scrolling container that traps wheel input with overscroll contain. */
  overflow-x: clip; overflow-y: visible; overscroll-behavior-y: auto;
  background: radial-gradient(ellipse at 4% 0%, #dce6fb, transparent 46%),
    radial-gradient(ellipse at 100% 100%, #ccd9e5, transparent 50%), #edf0f3;
}
.auth-entry .overlay {
  display: grid; grid-template-columns: 48% 52%; align-items: stretch;
  width: 100%; max-width: 1440px; min-height: min(740px, calc(100dvh - 48px)); padding: 10px;
  background: rgba(255, 255, 255, .72); border-radius: 28px; overflow: hidden;
  box-shadow: 0 24px 80px rgba(24, 42, 60, .12);
}
.auth-entry .overlay::after { display: none; }
.auth-entry .left-panel {
  width: 100%; max-width: none; min-height: 0; margin: 0;
  padding: 72px 36px 24px; border-radius: 0; background: transparent;
  position: relative; display: flex; align-items: center; justify-content: center;
}
.auth-entry .form-container { width: 100%; max-width: 350px; }
.auth-entry .brand, .auth-entry .brand-fixed {
  position: absolute; top: 24px; left: 30px; margin: 0;
  font-size: 21px; letter-spacing: -.02em; z-index: 2;
}
.auth-entry .brand-heading { margin: 0; }
.auth-entry .left-panel h1, .auth-entry #signupHeading {
  margin: 0 0 20px; padding: 0; font-family: 'Sarabun', sans-serif;
  font-size: 24px; font-weight: 500; line-height: 1.22; letter-spacing: -.035em;
  text-wrap: initial; text-align: left;
}
.auth-entry #signupHeading em { font-style: normal; font-weight: inherit; }
.auth-entry .left-panel h2 { font-family: 'Sarabun', sans-serif; font-size: 24px; font-weight: 500; letter-spacing: -.025em; }
.auth-entry .login-actions { margin-top: 20px; }
.auth-entry .extra-links { font-size: 13px; }
.auth-entry .auth-divider { margin: 12px 0; }
.auth-entry.signup-page.attorney-step-two .left-panel { padding-bottom: 36px; }
.auth-entry.signup-page.attorney-step-two #attorneySubmitLegal { position: static; width: auto; transform: none; margin: 20px 0 0; }
.auth-entry :is(.login-aside-copy, .signup-aside-copy) {
  position: relative; inset: auto; display: flex; flex-direction: column;
  justify-content: space-between; align-items: stretch; gap: 16px; padding: 26px 30px 18px;
  border-radius: 20px; overflow: hidden; pointer-events: auto;
  background: radial-gradient(ellipse at 100% 0%, #e4ecff, transparent 65%),
    linear-gradient(155deg, #cfddfb, #b8cdf5); color: #27394d;
}
.auth-entry .auth-story { max-width: 440px; }
.auth-entry .auth-story__eyebrow { margin: 0 0 10px; color: #425b7a; font-size: 11px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.auth-entry .auth-story__title { margin: 0 0 10px; font: 500 clamp(26px, 4dvh, 38px)/1.13 'Sarabun', sans-serif; letter-spacing: -.035em; color: #27394d; }
.auth-entry .auth-story__text { max-width: 35ch; margin: 0; color: #425b7a; font: 300 clamp(14px, 1.8dvh, 16px)/1.5 'Sarabun', sans-serif; }
.auth-workspace { position: relative; background: #fff; color: #27394d; border-radius: 14px; box-shadow: 0 18px 40px #355b9126; overflow: hidden; font-size: 12px; font-weight: 400; }
.auth-workspace__bar { display: flex; justify-content: space-between; gap: 12px; padding: 16px 18px; background: #f5f7f9; border-bottom: 1px solid #e6ebef; }
.auth-workspace__bar strong { font-weight: 600; }
.auth-workspace__bar span { color: #607186; font-size: 11px; }
.auth-workspace__body { padding: 24px 20px; }
.auth-workspace__meta { margin: 0 0 9px; color: #66758a; font-size: 11px; }
.auth-workspace h3 { margin: 0 0 14px; font: 500 21px/1.2 'Sarabun', sans-serif; letter-spacing: -.025em; color: #27394d; }
.auth-workspace__status { display: inline-block; background: #edf4ef; color: #376246; padding: 6px 9px; border-radius: 5px; font-size: 11px; }
.auth-workspace__tabs { display: flex; gap: 22px; margin: 24px 0 0; border-bottom: 1px solid #e6ebef; color: #68778a; }
.auth-workspace__tabs span { padding-bottom: 10px; }
.auth-workspace__tabs span:first-child { color: #27394d; border-bottom: 2px solid #27394d; }
.auth-workspace__file { display: flex; gap: 12px; align-items: center; padding: 15px 0; border-bottom: 1px solid #eef1f4; }
.auth-workspace__icon { padding: 9px 6px; background: #edf3ff; color: #385b96; border-radius: 5px; font-size: 9px; }
.auth-workspace__file strong { display: block; font-size: 12px; font-weight: 500; }
.auth-workspace__file small { display: block; margin-top: 3px; color: #6a7888; font-size: 11px; }
.auth-workspace__note { margin: 16px 0 0; color: #68778a; font-size: 11px; line-height: 1.5; }
.auth-story__footer { display: flex; flex-wrap: wrap; justify-content: center; text-align: center; gap: 6px 16px; padding-top: 12px; border-top: 1px solid #52729e40; color: #425b7a; font-size: 12px; font-weight: 300; }
@media (max-width: 1050px) and (min-width: 769px) {
  body.auth-entry { padding: clamp(12px, 2dvh, 24px); }
  .auth-entry .left-panel { padding-inline: 24px; }
  .auth-entry :is(.login-aside-copy, .signup-aside-copy) { padding: 26px 22px 18px; }
}
/* Smaller two-column windows keep the message, without miniature feature cards. */
@media (min-width: 769px) and (max-width: 1100px), (min-width: 769px) and (max-height: 700px) {
  .auth-entry :is(.login-aside-copy, .signup-aside-copy) {
    justify-content: center; align-items: center; text-align: center;
  }
  .auth-entry .lpc-entry-preview, .auth-entry .auth-story__footer { display: none; }
  .auth-entry .auth-story__text { margin-inline: auto; }
}
@media (max-width: 768px) {
  body.auth-entry { padding: 16px; }
  .auth-entry .overlay { display: block; width: 100%; min-height: 0; padding: 0; border-radius: 22px; }
  .auth-entry .left-panel { width: 100%; padding: 90px 24px 30px; }
  .auth-entry .brand, .auth-entry .brand-fixed { top: 26px; left: 24px; font-size: 20px; }
  .auth-entry :is(.login-aside-copy, .signup-aside-copy) { display: none; }
  .auth-entry .left-panel h1, .auth-entry #signupHeading { font-size: 26px; }
  .auth-entry .left-panel input:not([type="checkbox"]):not([type="hidden"]):not([type="file"]),
  .auth-entry .select-field { font-size: 16px; }
}
@media (max-width: 768px) and (max-height: 700px) {
  .auth-entry .left-panel { padding-top: 64px; padding-bottom: 20px; }
  .auth-entry .brand, .auth-entry .brand-fixed { top: 20px; }
  .auth-entry .left-panel h1, .auth-entry #signupHeading { margin-bottom: 14px; }
  .auth-entry .left-panel input:not([type="checkbox"]):not([type="hidden"]):not([type="file"]) { margin-bottom: 10px; }
  .auth-entry .login-actions { margin-top: 12px; }
}
@media (max-width: 360px) {
  body.auth-entry { padding: 12px; }
  .auth-entry .left-panel { padding-inline: 18px; }
  .auth-entry .brand, .auth-entry .brand-fixed { left: 18px; }
}

/* Compact desktop forms; retain roomy touch controls and input text on phones. */
@media (min-width: 769px) {
  .auth-entry .left-panel input:not([type="checkbox"]):not([type="hidden"]):not([type="file"]),
  .auth-entry .select-field { min-height: 44px; padding-block: 10px; font-size: 14px; margin-bottom: 12px; }
  .auth-entry .google-auth-button, .auth-entry .login-btn, .auth-entry .btn { min-height: 44px; padding-block: 10px; font-size: 14px; }
  .auth-entry .show-toggle, .auth-entry #togglePw { height: 44px; min-height: 44px; font-size: 12px; }
  .auth-entry .btn { margin-top: 12px; }
}
/* Readable public confirmation links and bounded error messages. */
.auth-entry :is(.signup-confirmation__eyebrow, .signup-confirmation__home, .extra-links a, .forgot-password) { color: #385f9e; }
.auth-entry #toastBanner { max-width: calc(100vw - 24px); width: max-content; max-height: 25dvh; overflow-y: auto; overflow-wrap: anywhere; bottom: 12px; }
