/* Auth pages */
.auth-section {
    padding: 3rem 1.5rem 5rem;
    display: flex;
    justify-content: center;
    background: linear-gradient(180deg, var(--color-bg-subtle) 0%, var(--color-bg) 100%);
    min-height: calc(100vh - 72px - 120px);
}

.auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    box-shadow: var(--shadow-md);
}

.auth-header {
    text-align: center;
    margin-bottom: 1.75rem;
}

.auth-header h1 {
    font-size: 1.625rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-text);
}

.form-input {
    width: 100%;
    padding: 0.75rem 0.875rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.9375rem;
    color: var(--color-text);
    background: var(--color-bg);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.field-error,
.form-errors {
    color: #dc2626;
    font-size: 0.8125rem;
}

.form-errors {
    padding: 0.75rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--radius-sm);
}

.auth-switch {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.9375rem;
    color: var(--color-text-secondary);
}

.auth-switch a {
    color: var(--color-primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-switch a:hover {
    text-decoration: underline;
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
    color: var(--color-text-muted);
    font-size: 0.8125rem;
    font-weight: 500;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--color-border);
}

.google-signin-wrap {
    display: flex;
    justify-content: center;
    min-height: 44px;
    width: 100%;
}

.google-signin-mount {
    width: 100%;
    max-width: 360px;
    min-height: 44px;
}

.google-signin-fallback,
.google-signin-disabled {
    margin: 0;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
    text-align: center;
    line-height: 1.5;
}

.google-signin-error {
    display: none;
    margin-top: 0.75rem;
    color: #dc2626;
    font-size: 0.8125rem;
    text-align: center;
}

.google-signin-error.is-visible {
    display: block;
}

/* Messages */
.messages-wrap {
    padding-top: 1rem;
}

.alert {
    padding: 0.875rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    margin-bottom: 0.5rem;
}

.alert-success {
    background: var(--color-accent-soft);
    color: #047857;
    border: 1px solid #a7f3d0;
}

.alert-error,
.alert-danger {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.alert-warning {
    background: var(--color-warning-soft);
    color: #b45309;
    border: 1px solid #fde68a;
}

.alert-info {
    background: var(--color-primary-soft);
    color: #1d4ed8;
    border: 1px solid #bfdbfe;
}

/* Profile */
.profile-card {
    max-width: 560px;
    margin: 0 auto;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
}

.profile-greeting {
    color: var(--color-text-secondary);
    margin-bottom: 1.5rem;
}

.profile-details {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 2rem;
}

.profile-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border-light);
}

.profile-row dt {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.profile-row dd {
    font-size: 0.9375rem;
    font-weight: 600;
    text-align: right;
}

.profile-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

@media (max-width: 540px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .auth-card {
        padding: 1.5rem;
    }
}
