/* =============================================================================
   BillGrid public site: sign in, sign up, password reset (layout/auth.html).
   Loads after outer/site.css. Design source: docs/mocks/site/payday-signin.html.
   ============================================================================= */

/* the body is the grid; its other children (icon sprite, scripts) must not claim a row, so the two
   panes share one row that takes all the height */
.auth { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); grid-template-rows: minmax(100vh, 1fr); min-height: 100vh; }
.auth > :not(.auth__pane, .auth__story) { position: absolute; }

/* ---------- form pane ---------- */
.auth__pane { display: flex; flex-direction: column; padding: 28px clamp(20px, 5vw, 72px); }
.auth__top { display: flex; justify-content: space-between; align-items: center; }
.auth__back { font-size: var(--fs-sm); color: var(--text-muted); text-decoration: none; }
.auth__back:hover { color: var(--ink); }
.auth__body { width: 100%; max-width: 420px; margin: auto; padding-block: 48px; }
.auth__body h1 { font-size: clamp(30px, 3.2vw, 40px); }
.auth__lead { margin-top: 12px; font-size: var(--fs-body); color: var(--text-muted); }
.auth__foot { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; font-size: var(--fs-sm); color: var(--caption); }
.auth__foot a { color: inherit; text-decoration: none; }
.auth__foot a:hover { color: var(--ink); }

.auth__tabs { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 34px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.auth__tabs a { padding: 9px; border-radius: 9px; text-align: center; text-decoration: none; font-size: var(--fs-body); font-weight: 600; color: var(--text-muted); }
.auth__tabs a[aria-current="page"] { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(40, 32, 16, .1), 0 0 0 1px var(--line); }

.auth-form { display: grid; gap: 16px; margin-top: 26px; }
.auth-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.auth__secure { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: -4px; font-size: var(--fs-sm); color: var(--trust); }
.auth__switch { margin-top: 26px; text-align: center; font-size: var(--fs-body); color: var(--text-muted); }
.auth__switch a { font-weight: 600; color: var(--ink); text-underline-offset: 3px; }
.auth__legal { text-align: center; font-size: var(--fs-xs); color: var(--text-muted); }
.auth__legal a { color: var(--text); }
.auth__sent { text-align: center; }
.auth__sent-icon { display: grid; place-items: center; width: 56px; height: 56px; margin: 0 auto 18px; border-radius: 16px; background: var(--trust-bg); color: var(--trust); }
.auth__sent b { color: var(--ink); }
.auth__body > .btn { margin-top: 26px; }

.strength { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.strength i { height: 4px; border-radius: 2px; background: var(--sand-200); transition: background .25s; }
.strength[data-level="1"] i:nth-child(-n+1) { background: var(--overdue-fg); }
.strength[data-level="2"] i:nth-child(-n+2) { background: #c9912f; }
.strength[data-level="3"] i:nth-child(-n+3) { background: #7a9a3f; }
.strength[data-level="4"] i { background: var(--paid-fg); }

.plan-choice__options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.plan-choice__option { position: relative; display: block; padding: 13px 14px; border: 1px solid #d9d1bf; border-radius: 12px; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.plan-choice__option input { position: absolute; opacity: 0; pointer-events: none; }
.plan-choice__option b { display: block; font-size: var(--fs-body); color: var(--ink); }
.plan-choice__option span { display: block; font-size: var(--fs-xs); color: var(--text-muted); }
.plan-choice__option .plan-choice__price { margin-top: 2px; font-size: var(--fs-lg); font-weight: 600; letter-spacing: -.03em; color: var(--ink); }
.plan-choice__price small { font-size: var(--fs-xs); font-weight: 500; letter-spacing: 0; color: var(--caption); }
.plan-choice__option::after { content: ""; position: absolute; right: 12px; top: 12px; width: 16px; height: 16px; border: 1.5px solid #cfc6b1; border-radius: 50%; }
.plan-choice__option:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(40, 36, 28, .07); }
.plan-choice__option:has(input:checked)::after { border: 5px solid var(--ink); }
.plan-choice__option:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 2px; }

/* ---------- story panel ---------- */
.auth__story { position: relative; display: flex; flex-direction: column; overflow: hidden; padding: clamp(28px, 4vw, 56px); background: var(--ink); color: #e8e1d0; }
.auth__story::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 50% at 80% 10%, rgba(232, 207, 143, .22), transparent 70%), radial-gradient(50% 50% at 10% 100%, rgba(44, 106, 114, .35), transparent 70%); }
.auth__story > * { position: relative; }
.auth__story .kicker { color: #a99f84; }
.auth__headline { max-width: 15em; margin-top: 12px; font-size: clamp(28px, 2.8vw, 40px); font-weight: 600; letter-spacing: -.03em; line-height: 1.08; color: #faf6ea; }
.auth__headline .accent { color: var(--hl); }
.auth__window { position: relative; margin-block: auto; padding-block: 32px; }
.auth__window img { width: 118%; max-width: none; border-radius: 12px; box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .08); transform: perspective(1400px) rotateY(-8deg) rotateX(3deg); transform-origin: left center; }
.auth__window .toast { position: absolute; left: -10px; bottom: 26px; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .6); }
.auth__trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 0; padding: 22px 0 0; list-style: none; border-top: 1px solid rgba(255, 255, 255, .1); }
.auth__trust li { display: flex; gap: 9px; align-items: flex-start; font-size: var(--fs-sm); color: #cabfa6; }
.auth__trust svg { flex: none; margin-top: 1px; color: #8fc4cc; }
.auth__trust b { display: block; font-size: var(--fs-sm); font-weight: 600; color: #faf6ea; }

@media (max-width: 980px) { .auth { grid-template-columns: minmax(0, 1fr); } .auth__story { display: none; } }
@media (max-width: 480px) { .auth-form__row, .plan-choice__options { grid-template-columns: minmax(0, 1fr); } }
