/* =========================
   LOGIN — style.css da raiz
   Usado apenas por index.html
========================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --background: #f5f7fb;
    --surface: #ffffff;
    --text: #172033;
    --text-secondary: #687386;
    --border: #e7eaf0;
}

body,
body.login-page {
    margin: 0;
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--background);
}

#app {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    padding: 36px 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(20, 30, 50, 0.08);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.logo {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-bottom: 12px;
}

.logo-icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.logo-icon img {
    width: 70px;
    height: 70px;
    object-fit: contain;
    display: block;
}

.logo-text {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo-text strong {
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
}

.logo-text span {
    margin-top: 3px;
    font-size: 12px;
    color: var(--text-secondary);
}

#loading {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(245, 247, 251, 0.90);
    z-index: 9999;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #dbe4f5;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.startHidden {
    display: none !important;
}

#auth,
#auth.center,
.center {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
}

#authForm {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    width: 100%;
}

#authFormTitle {
    display: block;
    width: 100%;
    margin: 8px 0 16px;
    font-size: 18px;
    line-height: 1.35;
    text-align: center;
}

#authForm label {
    display: block;
    width: 100%;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
}

#authForm input {
    display: block;
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 14px;
    outline: none;
}

#authForm input:focus {
    border-color: var(--primary);
}

#submitAuthForm,
.google-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    margin-top: 10px;
    border: 0;
    background-color: var(--primary);
    color: #fff;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

#submitAuthForm:hover {
    background-color: var(--primary-dark);
}

.google-button {
    background-color: #111827;
}

.google-button:hover {
    background-color: #000;
}

.google-button img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    pointer-events: none;
}

#auth p {
    display: block;
    width: 100%;
    margin-top: 14px;
    font-size: 13px;
    color: var(--text-secondary);
    text-align: center;
}

button.alternative {
    border: 0;
    background: transparent;
    color: var(--primary);
    font-weight: 600;
    cursor: pointer;
}

.social-login {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    width: 100%;
}
