/* Final auth consistency pass + global sticky footer shell. */
html{min-height:100%}
body{min-height:100vh;min-height:100dvh;display:flex;flex-direction:column}
.ag-footer{margin-top:auto}

/* Autofill-safe customer auth field icons: keep icons outside the input background layer. */
.ag-auth--login-final .ag-auth-field:has(#username),
.ag-auth--register-final .ag-auth-field:has(#reg_email){position:relative}
.ag-auth--login-final .ag-auth-field:has(#username)::after,
.ag-auth--register-final .ag-auth-field:has(#reg_email)::after{
  content:"";position:absolute;z-index:3;left:16px;bottom:16px;width:20px;height:20px;pointer-events:none;
  background:currentColor;-webkit-mask:url('../icons/auth-mail.svg') center/contain no-repeat;mask:url('../icons/auth-mail.svg') center/contain no-repeat;color:#14213d
}
.ag-auth--login-final #username,
.ag-auth--register-final #reg_email{padding-left:46px!important;background-image:none!important}
.ag-auth--login-final .ag-auth-password,
.ag-auth--register-final .ag-auth-password{position:relative}
.ag-auth--login-final .ag-auth-password::before,
.ag-auth--register-final .ag-auth-password::before{
  content:"";position:absolute;z-index:3;left:16px;top:50%;width:20px;height:20px;transform:translateY(-50%);pointer-events:none;
  background:#14213d;-webkit-mask:url('../icons/auth-lock.svg') center/contain no-repeat;mask:url('../icons/auth-lock.svg') center/contain no-repeat
}
.ag-auth--login-final .ag-auth-password input,
.ag-auth--register-final .ag-auth-password input{padding-left:46px!important;background-image:none!important}

/* Recovery mail icon spacing: the wrapper owns the icon, the input always reserves its space. */
.ag-auth--recovery-final .ag-auth-input-icon--mail::before{left:16px!important;width:20px!important;height:20px!important}
.ag-auth--recovery-final .ag-auth-input-icon--mail input{padding-left:52px!important;background-image:none!important}

/* One partner-card treatment across customer auth states. */
.ag-auth--recovery-final .ag-auth-partner-card,
.ag-auth-shell-reset-final .ag-auth-partner-card{
  display:grid!important;grid-template-columns:38px minmax(0,1fr)!important;gap:12px!important;align-items:center!important;
  width:min(100%,460px)!important;margin-top:22px!important;padding:13px 15px!important;border:1px solid rgba(167,117,43,.22)!important;
  border-radius:14px!important;background:rgba(255,253,248,.72)!important;backdrop-filter:blur(4px)
}
.ag-auth--recovery-final .ag-auth-partner-card::before,
.ag-auth-shell-reset-final .ag-auth-partner-card::before{
  content:"";display:block;width:38px;height:38px;border-radius:10px;background:#f6efe3 url('../icons/auth-car.svg') center/22px no-repeat
}
.ag-auth--recovery-final .ag-auth-partner-card strong,
.ag-auth-shell-reset-final .ag-auth-partner-card strong{display:block;margin:0 0 2px;color:#14213d;font-size:.92rem;line-height:1.35}
.ag-auth--recovery-final .ag-auth-partner-card a,
.ag-auth-shell-reset-final .ag-auth-partner-card a{color:#9a6a24!important;font-size:.86rem;font-weight:700;text-decoration:none}

/* Reset-password visual column must match the approved login/recovery treatment. */
.ag-auth-shell-reset-final .ag-auth-visual-copy h2{color:#14213d!important}
.ag-auth-shell-reset-final .ag-auth-visual-copy p{color:#334155!important}
.ag-auth-shell-reset-final .ag-auth-benefit strong{color:#14213d!important;margin-bottom:2px!important;font-size:1rem!important}
.ag-auth-shell-reset-final .ag-auth-benefit p{color:#475569!important;font-size:.88rem!important;line-height:1.42!important}
.ag-auth-shell-reset-final .ag-auth-benefit{align-items:start!important}
.ag-auth-shell-reset-final .ag-auth-benefit-icon{flex:0 0 auto}

/* Confirmation icon: use the supplied mail-check glyph instead of the hand-built envelope/arrow. */
.ag-auth--confirmation-final .ag-auth-state-icon-sent::before{
  content:""!important;position:absolute!important;inset:17px!important;border:0!important;border-radius:0!important;
  background:currentColor!important;-webkit-mask:url('../icons/auth-mail-check.svg') center/contain no-repeat!important;mask:url('../icons/auth-mail-check.svg') center/contain no-repeat!important
}
.ag-auth--confirmation-final .ag-auth-state-icon-sent::after{content:none!important;display:none!important}

/* One-time reset success is a standalone state, not part of the current dashboard composition. */
.ag-account-page .woocommerce:has(#ag-reset-success-title){display:block!important;width:min(calc(100% - 32px),760px)!important;margin:clamp(36px,6vw,72px) auto 72px!important;overflow:visible!important}
.ag-account-page .woocommerce:has(#ag-reset-success-title) .woocommerce-MyAccount-navigation{display:none!important}
.ag-account-page .woocommerce:has(#ag-reset-success-title) .woocommerce-MyAccount-content{float:none!important;width:100%!important;max-width:620px!important;margin:0 auto!important;padding:0!important}
.ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title)>*:not(.ag-auth--customer){display:none!important}
.ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title)>.ag-auth--customer.ag-auth--state{display:grid!important;place-items:center;min-height:0!important;max-width:620px!important;margin:0 auto!important}
.ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title)>.ag-auth--customer.ag-auth--state .ag-auth-state{width:100%;max-width:560px;gap:22px;padding:40px 38px;border-radius:22px}
.ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title) .ag-auth-state-actions{width:100%;max-width:440px}
.ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title) .ag-auth-state-actions .ag-button{width:100%;justify-content:center}

@media(max-width:1023px){
  .ag-auth--recovery-final .ag-auth-partner-card,
  .ag-auth-shell-reset-final .ag-auth-partner-card{display:none!important}
}
@media(max-width:640px){
  .ag-account-page .woocommerce:has(#ag-reset-success-title){width:calc(100% - 16px)!important;margin:26px auto 38px!important}
  .ag-account-page .woocommerce-MyAccount-content:has(#ag-reset-success-title)>.ag-auth--customer.ag-auth--state .ag-auth-state{gap:19px;padding:30px 18px;border-radius:18px}
}
