/* ==========================================================================
   Auth modal
   ========================================================================== */

.hp-auth { position: fixed; inset: 0; z-index: 980; display: flex; align-items: center; justify-content: center; padding: 14px; }
.hp-auth[hidden] { display: none; }
.hp-auth__scrim { position: absolute; inset: 0; background: rgba(7, 19, 27, .58); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: hp-fade .2s ease both; }
.hp-auth__card {
  position: relative; width: min(460px, 100%); max-height: calc(100vh - 28px); overflow: auto;
  background: #fff; border-radius: 22px; box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .6);
  animation: hp-rise .3s cubic-bezier(.2, .7, .2, 1) both;
}
.hp-auth__photo { position: relative; height: 110px; background: var(--hp-ink); overflow: hidden; }
.hp-auth__photo img { width: 100%; height: 100%; object-fit: cover; opacity: .6; }
.hp-auth__photo-grad { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7, 19, 27, .1), rgba(7, 19, 27, .75)); }
.hp-auth__eyebrow { position: absolute; left: 22px; bottom: 14px; color: #fff; font-size: 12.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.hp-auth__close { position: absolute; right: 14px; top: 14px; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); display: inline-flex; align-items: center; justify-content: center; }
.hp-auth__close .hp-icon { width: 20px; height: 20px; }
.hp-auth__body { padding: 20px clamp(18px, 4vw, 26px) 24px; }

.hp-auth__tabs { display: grid; grid-template-columns: 1fr 1fr; background: var(--hp-bg); border-radius: 12px; padding: 4px; margin-bottom: 18px; }
.hp-auth__tab { border: 0; background: none; border-radius: 9px; padding: 10px; font-weight: 700; font-size: 14px; color: var(--hp-text-2); cursor: pointer; }
.hp-auth__tab.is-on { background: #fff; color: var(--hp-ink); box-shadow: var(--hp-shadow-sm); }

.hp-auth__h { font-family: var(--hp-font-display); font-size: 26px; font-weight: 700; letter-spacing: -.02em; margin: 0 0 6px; }
.hp-auth__sub { font-size: 14.5px; line-height: 1.5; color: var(--hp-text-2); margin: 0 0 16px; }

.hp-auth__google { width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px; border-radius: 12px; border: 1px solid var(--hp-line-16); background: #fff; font-size: 15px; font-weight: 700; min-height: 50px; cursor: pointer; }
.hp-auth__google:hover { border-color: var(--hp-ink); }
.hp-auth__google svg { width: 18px; height: 18px; }
.hp-auth__or { display: flex; align-items: center; gap: 12px; margin: 14px 0; color: var(--hp-muted); font-size: 12.5px; }
.hp-auth__or::before, .hp-auth__or::after { content: ""; flex: 1; height: 1px; background: var(--hp-line-12); }

.hp-auth__field { display: grid; gap: 6px; margin-bottom: 12px; }
.hp-auth__label { font-size: 13px; font-weight: 700; }
.hp-auth__input { width: 100%; padding: 14px; border-radius: 11px; border: 1px solid rgba(14, 27, 36, .2); font-size: 16px; background: #fff; }
.hp-auth__input:focus { outline: none; border-color: var(--hp-link); box-shadow: 0 0 0 3px rgba(28, 95, 212, .15); }
.hp-auth__input.is-error { border-color: var(--hp-danger); }
.hp-auth__input--code { letter-spacing: .5em; font-size: 22px; text-align: center; font-weight: 700; }
.hp-auth__err { font-size: 12.5px; font-weight: 600; color: var(--hp-danger); }

.hp-auth__row { display: flex; justify-content: space-between; font-size: 13.5px; margin: -2px 0 14px; }
.hp-auth__link { border: 0; background: none; color: var(--hp-link); font-weight: 600; cursor: pointer; padding: 0; font-size: inherit; }

.hp-auth__consent { display: grid; gap: 10px; margin: 4px 0 16px; }
.hp-auth__check { display: flex; gap: 10px; font-size: 13.5px; line-height: 1.45; color: #1F2E37; }
.hp-auth__check input { width: 18px; height: 18px; accent-color: var(--hp-ink); flex: 0 0 auto; margin-top: 1px; }
.hp-auth__req { color: var(--hp-danger-d); }

.hp-auth__note { background: var(--hp-green-tint); color: #0B5A3D; border-radius: 12px; padding: 12px 14px; font-size: 13.5px; line-height: 1.5; margin-bottom: 14px; }

.hp-auth__submit { width: 100%; padding: 15px; border-radius: 12px; background: var(--hp-saffron); color: var(--hp-ink); font-size: 16px; font-weight: 800; min-height: 52px; border: 0; cursor: pointer; }
.hp-auth__submit:hover { background: var(--hp-saffron-l); }
.hp-auth__switch { text-align: center; font-size: 14px; color: var(--hp-text-2); margin-top: 14px; }

/* Password show/hide toggle */
.hp-auth__pwwrap { position: relative; display: block; }
.hp-auth__input--pw { padding-right: 62px; }
.hp-auth__pwtoggle {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  background: none; border: 0; color: var(--hp-link); font-size: 12.5px; font-weight: 700;
  cursor: pointer; padding: 6px 9px; border-radius: 8px;
}
.hp-auth__pwtoggle:hover { background: var(--hp-line-08); }

/* Error-styled note (generic/API errors, not tied to one field) */
.hp-auth__note--err { background: var(--hp-danger-tint, #FDECEF); color: var(--hp-danger-d, #A3123F); }

/* Submit loading state */
.hp-auth__submit.is-loading { opacity: .72; cursor: progress; }
.hp-auth__submit:disabled { opacity: .72; cursor: not-allowed; }

/* ==== Responsive audit fix ==== */
.hp-auth__close { width: 44px; height: 44px; min-width: 44px; }
