/* pages/auth.css — trang Đăng nhập / Đăng ký (pages/public/login.html, register.html), phong cách C
   (khung AU_1_Login, AU_2_Register, AU_3_GuestUpgrade). Khung chung: pages/public.css. */

.auth { max-width: 400px; margin: 0 auto; padding: 40px 0; }
.auth-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; margin-bottom: 28px; }
.auth-logo { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; font-size: 20px; font-weight: 700; color: var(--ink); }
.auth-logo img { border-radius: 10px; object-fit: cover; }
.auth-title { margin: 0; font-size: 28px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); }
.auth-lead { margin: 4px 0 0; font-size: 15px; color: var(--muted); }
.auth-note { margin-bottom: 22px; }
.auth-note .callout-title { font-size: 14px; }

/* Ô nhập */
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-form-tight { gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font-size: 13px; font-weight: 500; color: var(--muted); }
.req { color: var(--red); }
.input {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: var(--r);
  background: var(--bg); color: var(--ink); font: inherit; font-size: 14px;
}
.input::placeholder { color: var(--faint); }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 44px; }
.pw-toggle {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  width: 36px; height: 34px; border: 0; border-radius: var(--r);
  background: none; color: var(--muted); display: grid; place-items: center; cursor: pointer;
}
.pw-toggle:hover { color: var(--ink); }
.pw-toggle span { display: grid; }
.pw-toggle span[hidden] { display: none; }
.select-wrap { position: relative; }
.select-wrap select { appearance: none; -webkit-appearance: none; padding-right: 36px; cursor: pointer; }
.select-wrap select.is-empty { color: var(--faint); }
.select-wrap select option { color: var(--ink); }
.select-wrap .icon { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.auth-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 12px; }

.consent {
  display: flex; align-items: flex-start; gap: 10px; margin: 4px 0 2px;
  padding: 12px 14px; border-radius: var(--r-md); background: var(--bg-side);
  font-size: 14px; line-height: 1.5; color: var(--text); cursor: pointer;
}
.consent input { margin: 2px 0 0; width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--accent); }
.consent-jp { font-size: 12px; color: var(--muted); }

/* Nút gửi + thông báo */
.auth-submit { width: 100%; height: 44px; font-size: 14px; }
.auth-submit.is-loading { opacity: 0.7; cursor: progress; }
.auth-msg { min-height: 20px; font-size: 14px; line-height: 1.5; text-align: center; color: var(--muted); }
.auth-msg:empty { min-height: 0; }
.auth-msg.is-good { color: var(--green); }
.auth-msg.is-bad { color: var(--red); }

/* Link dưới form */
.auth-divider { height: 1px; margin-top: 24px; background: var(--line); }
.auth-links { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: 22px; font-size: 14px; color: var(--muted); text-align: center; }
.auth-strong { font-weight: 600; color: var(--accent); text-decoration: none; }
.auth-small { font-size: 13px; color: var(--muted); text-decoration: none; }
.auth-small:hover { color: var(--ink); }
.auth-badges { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.auth-badges .icon { color: var(--faint); }

@media (max-width: 860px) {
  .auth { padding: 12px 20px 40px; }
  .input { height: 44px; font-size: 16px; } /* 16px: iPhone không tự phóng to khi gõ */
  .auth-grid { grid-template-columns: minmax(0, 1fr); }
}

/* Nút "Tiếp tục với Google" (_google_signin.html) + vạch "hoặc" */
.auth-google { display: flex; flex-direction: column; align-items: stretch; gap: 8px; margin-bottom: 4px; }
.auth-google-btn { min-height: 44px; display: flex; justify-content: center; }
.auth-google-note { margin: 0; font-size: 12px; line-height: 1.5; color: var(--muted); text-align: center; }
.auth-google-note a { color: var(--accent); text-decoration: none; }
.auth-or { display: flex; align-items: center; gap: 12px; margin: 14px 0 18px; font-size: 13px; color: var(--muted); }
.auth-or::before, .auth-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
