/* Public authentication only: deliberate spacing, readable contrast and a contained scroll area. */
#auth-modal.auth-refined {
 --auth-ink:#163f46; --auth-muted:#607a7e; --auth-green:#176e63;
 box-sizing:border-box; width:min(590px,calc(100% - 40px)); max-width:680px;
 max-height:calc(100dvh - 48px); padding:0; margin:auto; inset:0;
 border:1px solid #e0ebe7; border-radius:28px; background:#fff; color:var(--auth-ink);
 box-shadow:0 32px 100px #0c303947; overflow:hidden; outline:none;
 font-family:inherit; text-align:start;
}
#auth-modal.auth-refined[open] {display:flex; flex-direction:column;}
#auth-modal.auth-refined:has([data-auth-form="register"]:not([hidden])) {width:min(660px,calc(100% - 40px));}
#auth-modal.auth-refined::backdrop {background:#123b4680; backdrop-filter:blur(9px);}
#auth-modal .auth-refined-header {position:relative; flex:none; padding:29px 34px 0; background:linear-gradient(130deg,#f3faf6,#fff 75%); border-bottom:1px solid #e6eeeb;}
#auth-modal .modal-brand {display:flex; align-items:center; gap:9px; color:var(--auth-ink); font-size:25px; font-weight:720; letter-spacing:-.8px; line-height:1.2;}
#auth-modal .modal-brand .brand-logo {width:36px; height:36px; object-fit:contain;}
#auth-modal .dialog-close {position:absolute; top:27px; right:28px; display:grid; place-items:center; width:36px; height:36px; padding:9px; border:1px solid #dfeae5; border-radius:12px; color:#5c777a; background:#fff; cursor:pointer; box-shadow:none;}
#auth-modal .dialog-close svg {width:16px; height:16px;}
#auth-modal .dialog-close:hover {background:#eaf4ef; color:#174c49; border-color:#c2d9cd;}
#auth-modal .auth-tabs {display:flex; gap:24px; padding:0; margin:25px 0 0; border:0; border-radius:0; background:transparent;}
#auth-modal .auth-tabs button {flex:1; position:relative; display:flex; align-items:center; justify-content:center; min-height:47px; padding:10px 4px 14px; margin:0; border:0; border-radius:0; background:transparent; color:#6b8183; font:inherit; font-size:13px; font-weight:550; cursor:pointer; box-shadow:none;}
#auth-modal .auth-tabs button.selected {color:#17685f; font-weight:700; background:transparent;}
#auth-modal .auth-tabs button.selected::after {content:""; position:absolute; inset:auto 0 -1px; height:3px; border-radius:3px 3px 0 0; background:#238978;}
#auth-modal .auth-tabs button:hover {color:#17685f; background:#edf7f150;}
#auth-modal .auth-refined-content {padding:28px 34px 34px; min-height:0; overflow-y:auto; overscroll-behavior:contain; scrollbar-width:thin; scrollbar-color:#b7d4c7 transparent;}
#auth-modal .auth-refined-heading {margin-bottom:24px;}
#auth-modal #auth-modal-title {margin:0 0 9px; font-size:30px; line-height:1.2; letter-spacing:-1px; font-weight:700; color:var(--auth-ink);}
#auth-modal #auth-modal-intro {margin:0; font-size:13px; line-height:1.7; color:var(--auth-muted); max-width:470px;}
#auth-modal [data-auth-form] {display:block; margin:0;}
#auth-modal [data-auth-form][hidden] {display:none!important;}
#auth-modal label {display:block; margin:0 0 8px; font-size:12px; line-height:1.45; font-weight:600; color:#365c60;}
#auth-modal input:not([type="checkbox"]):not([type="radio"]) {box-sizing:border-box; display:block; width:100%; min-width:0; height:49px; margin:8px 0 0; padding:12px 14px; border:1px solid #d4e3de; border-radius:12px; background:#fbfdfc; color:var(--auth-ink); font:inherit; font-size:14px; line-height:1.4; box-shadow:none; transition:border-color .15s,box-shadow .15s,background .15s;}
#auth-modal input::placeholder {color:#8b9c9c; font-size:13px; font-weight:400; opacity:1;}
#auth-modal input:not([type="checkbox"]):not([type="radio"]):focus {outline:none; background:#fff; border-color:#4caa92; box-shadow:0 0 0 3px #298c7314;}
#auth-modal .auth-input-wrap {position:relative; margin:0;}
#auth-modal .auth-input-wrap input {margin-top:0!important;}
#auth-modal .auth-input-wrap:has(.auth-input-icon) input {padding-inline-start:43px!important;}
#auth-modal .auth-input-icon {position:absolute; inset-inline-start:15px; top:16px; width:17px; height:17px; color:#72918b; fill:none; stroke:currentColor; stroke-width:1.6; pointer-events:none;}
#auth-modal .auth-label-row {display:flex; align-items:center; justify-content:space-between; gap:14px; margin-top:20px; margin-bottom:8px;}
#auth-modal .auth-label-row label {margin:0;}
#auth-modal .auth-label-row a {font-size:11px; font-weight:550; color:#247466; text-decoration:none; text-underline-offset:3px;}
#auth-modal .auth-label-row a:hover {text-decoration:underline;}
#auth-modal .auth-password-wrap input {padding-inline-end:49px!important;}
#auth-modal .auth-password-toggle {display:grid; place-items:center; position:absolute; inset-inline-end:6px; top:6px; width:37px; height:37px; min-height:0; padding:9px; margin:0; border:0; border-radius:9px; background:transparent; color:#75918c; box-shadow:none; cursor:pointer;}
#auth-modal .auth-password-toggle:hover,#auth-modal .auth-password-toggle[aria-pressed="true"] {color:#176e63; background:#eaf4ef;}
#auth-modal .auth-password-toggle svg {width:19px; height:19px; fill:none; stroke:currentColor; stroke-width:1.6; stroke-linecap:round; stroke-linejoin:round;}
#auth-modal .auth-eye-slash {display:none;}
#auth-modal [aria-pressed="true"] .auth-eye-slash {display:block;}
#auth-modal .button.auth-submit {display:flex; justify-content:center; align-items:center; width:100%; min-height:49px; padding:13px 18px; margin:25px 0 0; border:1px solid #176e63; border-radius:12px; background:#176e63; color:#fff!important; box-shadow:0 5px 12px #176e6312; font-size:13px; font-weight:650; line-height:1.4; transition:background .15s,box-shadow .15s; transform:none;}
#auth-modal .button.auth-submit:hover {background:#115b53; border-color:#115b53; color:#fff!important; box-shadow:0 6px 16px #176e6320; transform:none;}
#auth-modal .button.auth-submit:disabled {opacity:.65; cursor:wait;}
#auth-modal .business-choice {margin:0 0 23px; padding:0; border:0; min-width:0;}
#auth-modal .business-choice legend {padding:0; margin:0 0 10px; color:#365c60; font-size:12px; font-weight:600;}
#auth-modal .business-choice>div {display:grid; grid-template-columns:1fr 1fr; gap:10px;}
#auth-modal .business-choice label {display:flex; align-items:center; gap:10px; margin:0; min-height:82px; padding:13px 12px; border:1px solid #dce7e2; border-radius:13px; background:#fff; box-shadow:none; cursor:pointer; transition:border-color .15s,background .15s;}
#auth-modal .business-choice label:has(input:checked) {border-color:#3f9a82; background:#eff8f3; box-shadow:inset 0 0 0 1px #3f9a8218;}
#auth-modal .business-choice label:hover {border-color:#91bead;}
#auth-modal .business-choice input {width:16px; height:16px; min-width:16px; margin:0; accent-color:#197b68;}
#auth-modal .business-choice label>span {display:block; min-width:0;}
#auth-modal .business-choice b {display:flex; align-items:center; gap:7px; color:#24544f; font-size:12px; font-weight:650;}
#auth-modal .business-choice-icon {display:inline-flex; width:17px; height:17px; color:#318271;}
#auth-modal .business-choice-icon svg {width:17px; height:17px;}
#auth-modal .business-choice small {display:block; font-size:10px; font-weight:400; color:#67817c; line-height:1.5; margin-top:5px;}
#auth-modal .auth-details-grid {display:grid; grid-template-columns:1fr 1fr; column-gap:16px; row-gap:17px; align-items:start;}
#auth-modal .auth-details-grid>label {margin:0;}
#auth-modal .auth-grid-wide {grid-column:1/-1;}
#auth-modal .auth-password-hint {display:block; margin-top:11px; color:#778a87; font-size:11px; line-height:1.6;}
#auth-modal .legal-accept {display:flex; align-items:flex-start; gap:10px; padding:16px 0 0; margin:17px 0 0; border-top:1px solid #e8eeeb; font-size:11px; font-weight:400; color:#657e79; line-height:1.7;}
#auth-modal .legal-accept input {flex:0 0 17px; width:17px; height:17px; margin:2px 0 0; accent-color:#176e63; border-radius:4px;}
#auth-modal .legal-accept a {color:#216c60; text-decoration:underline; text-underline-offset:3px;}
#auth-modal button:focus-visible,#auth-modal a:focus-visible {outline:2px solid #3b9e86; outline-offset:3px;}
#auth-modal #auth-modal-errors {margin:0 0 20px; border-radius:12px; font-size:12px;}
@media(max-width:560px) {
 #auth-modal.auth-refined,#auth-modal.auth-refined:has([data-auth-form="register"]:not([hidden])) {width:calc(100% - 24px); max-height:calc(100dvh - 24px); border-radius:23px;}
 #auth-modal .auth-refined-header {padding:23px 23px 0;}
 #auth-modal .dialog-close {top:23px; right:22px;}
 #auth-modal .auth-refined-content {padding:24px 23px 28px;}
 #auth-modal #auth-modal-title {font-size:28px;}
 #auth-modal .auth-tabs {gap:18px; margin-top:20px;}
 #auth-modal .business-choice>div {gap:8px;}
 #auth-modal .business-choice label {padding:12px 10px; gap:7px;}
 #auth-modal .business-choice b {gap:5px; font-size:11px;}
 #auth-modal .business-choice-icon {display:none;}
 #auth-modal .auth-details-grid {grid-template-columns:1fr; gap:16px;}
 #auth-modal .auth-refined-heading {margin-bottom:22px;}
}
@media(prefers-reduced-motion:no-preference) {
 #auth-modal.auth-refined[open] {animation:auth-refined-in .22s ease-out;}
 @keyframes auth-refined-in {from{opacity:0;transform:translateY(10px) scale(.99)}to{opacity:1;transform:none}}
}

html:has(#auth-modal.auth-refined[open]) {overflow:hidden; scrollbar-gutter:stable;}
