/* ========================================
   AUTH PAGES — чистий мінімалістичний дизайн
   Використовує змінні з base.css
   ======================================== */

.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 96px);
    padding: 48px 24px;
}

.auth-card {
    width: 100%;
    max-width: 400px;
}

.auth-card--wide {
    max-width: 460px;
}

/* Заголовок */
.auth-header {
    margin-bottom: 32px;
}

.auth-header-title {
    font-family: 'PT Serif', Georgia, serif;
    font-size: 28px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}

.auth-header-subtitle {
    color: var(--gray-500);
    font-size: 15px;
    line-height: 1.5;
}

/* Форма */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.auth-field {
    display: flex;
    flex-direction: column;
}

.auth-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-600);
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}

.auth-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    background: var(--white);
    color: var(--dark);
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.15s ease;
}

.auth-input:focus {
    outline: none;
    border-color: var(--primary);
}

.auth-input:hover {
    border-color: var(--gray-300);
}

.auth-input::placeholder {
    color: var(--gray-400);
}

/* Два поля в рядку */
.auth-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* Кнопка */
.auth-button {
    width: 100%;
    padding: 11px 16px;
    margin-top: 4px;
    border: none;
    border-radius: 6px;
    background: var(--dark);
    color: var(--white);
    font-size: 15px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s ease;
    letter-spacing: 0.02em;
}

.auth-button:hover {
    background: var(--gray-700);
}

/* Посилання */
.auth-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
}

.auth-link:hover {
    color: var(--primary-dark);
}

.auth-forgot-link {
    display: inline-block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--gray-500);
    text-decoration: none;
    transition: color 0.15s ease;
}

.auth-forgot-link:hover {
    color: var(--primary);
}

/* Футер */
.auth-footer {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--gray-100);
    text-align: center;
}

.auth-footer-text {
    color: var(--gray-500);
    font-size: 14px;
}

/* Повідомлення */
.auth-messages {
    margin-bottom: 20px;
}

.auth-message {
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 8px;
}

.auth-message-success {
    background: rgba(34, 197, 94, 0.08);
    color: #16a34a;
    border: 1px solid rgba(34, 197, 94, 0.15);
}

.auth-message-error {
    background: rgba(239, 68, 68, 0.08);
    color: #dc2626;
    border: 1px solid rgba(239, 68, 68, 0.15);
}

.auth-message-info {
    background: rgba(59, 130, 246, 0.08);
    color: #2563eb;
    border: 1px solid rgba(59, 130, 246, 0.15);
}

/* Помилки полів */
.auth-error {
    margin-top: 4px;
    font-size: 13px;
    color: #dc2626;
}

/* Допоміжний текст */
.auth-help-text {
    margin-top: 6px;
    font-size: 12px;
    color: var(--gray-400);
    line-height: 1.5;
}

.auth-help-text ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.auth-help-text li {
    margin-bottom: 2px;
}

/* Іконка успіху */
.auth-success-icon {
    font-size: 40px;
    color: #16a34a;
    margin-bottom: 16px;
}

/* ========================================
   ТЕМНА ТЕМА
   ======================================== */

[data-theme="dark"] .auth-header-title {
    color: #FAFCFF;
}

[data-theme="dark"] .auth-header-subtitle {
    color: #7B9FCC;
}

[data-theme="dark"] .auth-label {
    color: #B4CCE4;
}

[data-theme="dark"] .auth-input {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.12);
    color: #FAFCFF;
}

[data-theme="dark"] .auth-input:focus {
    border-color: var(--primary);
}

[data-theme="dark"] .auth-input:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .auth-input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

[data-theme="dark"] .auth-button {
    background: #FAFCFF;
    color: #0D1520;
}

[data-theme="dark"] .auth-button:hover {
    background: var(--primary);
}

[data-theme="dark"] .auth-footer {
    border-top-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .auth-footer-text {
    color: #7B9FCC;
}

[data-theme="dark"] .auth-forgot-link {
    color: #7B9FCC;
}

[data-theme="dark"] .auth-error {
    color: #f87171;
}

[data-theme="dark"] .auth-message-success {
    background: rgba(34, 197, 94, 0.06);
    color: #4ade80;
    border-color: rgba(34, 197, 94, 0.12);
}

[data-theme="dark"] .auth-message-error {
    background: rgba(239, 68, 68, 0.06);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.12);
}

[data-theme="dark"] .auth-success-icon {
    color: #4ade80;
}

/* ========================================
   АДАПТИВНІСТЬ
   ======================================== */

@media (max-width: 768px) {
    .auth-page {
        min-height: calc(100vh - 56px);
        padding: 32px 16px;
        align-items: flex-start;
        padding-top: 48px;
    }

    .auth-field-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .auth-page {
        min-height: calc(100vh - 50px);
        padding: 24px 14px;
        padding-top: 36px;
    }

    .auth-header-title {
        font-size: 24px;
    }
}
