.wy-auth-modal[hidden] { display: none; }
.wy-auth-modal { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 1.25rem; }
.wy-auth-backdrop { position: absolute; inset: 0; border: 0; background: rgba(2, 4, 5, 0.76); backdrop-filter: blur(14px) saturate(0.75); cursor: default; }
.wy-auth-dialog { position: relative; width: min(460px, 100%); max-height: min(760px, calc(100vh - 2.5rem)); overflow: auto; border: 1px solid rgba(255,255,255,0.58); border-radius: 22px; background: #f4f2ed; color: #171817; box-shadow: 0 32px 100px rgba(0,0,0,0.58); }
.wy-auth-close { position: absolute; z-index: 2; top: 0.75rem; right: 0.8rem; display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border: 0; border-radius: 50%; background: transparent; color: #6d6d69; font-size: 1.45rem; cursor: pointer; }
.wy-auth-close:hover { background: rgba(0,0,0,0.06); color: #111; }
.wy-auth-tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 0.55rem 3.6rem 0 0.55rem; border-bottom: 1px solid rgba(0,0,0,0.12); }
.wy-auth-tabs button { border: 0; border-radius: 12px 12px 0 0; padding: 0.9rem; background: transparent; color: #777671; font: 800 0.9rem var(--wy-sans); cursor: pointer; }
.wy-auth-tabs button.is-active { background: #171817; color: #fff; }
.wy-auth-form { display: grid; gap: 0.95rem; padding: 2rem 2.1rem 2.15rem; }
.wy-auth-form[hidden] { display: none; }
.wy-auth-kicker { margin: 0; color: #767570; font: 700 0.66rem var(--wy-mono); letter-spacing: 0.16em; }
.wy-auth-form h2 { margin: -0.25rem 0 0.35rem; font-family: var(--wy-display); font-size: 2.1rem; font-weight: 600; letter-spacing: -0.055em; }
.wy-auth-form label { display: grid; gap: 0.42rem; color: #44443f; font-size: 0.78rem; font-weight: 750; }
.wy-auth-form input { width: 100%; border: 1px solid #d2d0ca; border-radius: 11px; padding: 0.84rem 0.9rem; background: #fff; color: #171817; outline: 0; }
.wy-auth-form input:focus { border-color: #a57b32; box-shadow: 0 0 0 3px rgba(202,158,78,0.18); }
.wy-auth-remember { display: flex !important; align-items: center; gap: 0.55rem !important; font-weight: 600 !important; cursor: pointer; }
.wy-auth-remember input { width: 1rem; height: 1rem; accent-color: #171817; }
.wy-auth-code { display: grid; grid-template-columns: 1fr auto; gap: 0.5rem; }
.wy-auth-code button { border: 1px solid #cbc9c3; border-radius: 11px; padding: 0.76rem 0.85rem; background: transparent; color: #171817; font-size: 0.76rem; font-weight: 800; cursor: pointer; }
.wy-auth-submit { border: 0; border-radius: 11px; padding: 0.95rem; background: #171817; color: #fff; font-weight: 900; cursor: pointer; }
.wy-auth-code button:hover, .wy-auth-submit:hover { transform: translateY(-1px); }
.wy-auth-submit:disabled, .wy-auth-code button:disabled { cursor: wait; opacity: 0.6; transform: none; }
.wy-auth-link { justify-self: center; border: 0; padding: 0.2rem; background: transparent; color: #676661; font-size: 0.76rem; font-weight: 700; text-decoration: underline; text-underline-offset: 0.24rem; cursor: pointer; }
.wy-auth-message { min-height: 1.4em; margin: 0; color: #777671; font-size: 0.72rem; line-height: 1.55; text-align: center; }
body.wy-auth-open { overflow: hidden; }
@media (max-width: 520px) { .wy-auth-modal { padding: 0.75rem; } .wy-auth-dialog { max-height: calc(100vh - 1.5rem); border-radius: 17px; } .wy-auth-form { padding: 1.55rem 1.25rem 1.65rem; } .wy-auth-code { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: no-preference) { .wy-auth-dialog { animation: wy-auth-enter 180ms ease-out both; } @keyframes wy-auth-enter { from { opacity: 0; transform: translateY(12px) scale(0.985); } } }

/* Google sign-in (shown only when the provider is enabled) */
.wy-auth-oauth { display: grid; gap: 0.6rem; }
.wy-auth-oauth[hidden] { display: none; }
.wy-auth-divider { display: flex; align-items: center; gap: 0.8rem; color: rgba(20, 20, 20, 0.5); font-size: 0.76rem; }
.wy-auth-divider::before, .wy-auth-divider::after { flex: 1; height: 1px; content: ""; background: rgba(20, 20, 20, 0.15); }
.wy-auth-google { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; border: 1px solid rgba(20, 20, 20, 0.2); border-radius: 12px; padding: 0.8rem 1rem; background: #fff; color: #1f1f1f; font-weight: 700; cursor: pointer; }
.wy-auth-google:hover { background: #f4f4f4; }
.wy-auth-google:disabled { opacity: 0.6; cursor: wait; }
.wy-auth-google svg { width: 18px; height: 18px; }

/* Errors are red and shake once so a failed login cannot be missed. */
.wy-auth-message.is-error { color: #d93b2b; font-size: 0.8rem; font-weight: 800; animation: wy-auth-shake 420ms ease; }
@keyframes wy-auth-shake { 0%, 100% { transform: none; } 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.wy-auth-message.is-ok { color: #1f8a5b; font-size: 0.8rem; font-weight: 800; }
