/* static/css/accounts.css - Финальный стиль для входа и регистрации */

/* --- Контейнер для центрирования карточки --- */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 3rem 1rem;
    min-height: calc(100vh - 250px);
}

/* --- Карточка формы (стиль как у .blueprint-card) --- */
.auth-card {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 2rem;
    width: 100%;
    max-width: 450px;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}
.auth-header .fas {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}
.auth-header h1 {
    font-weight: 700;
    color: var(--secondary-color);
    font-size: 1.8rem;
}

/* --- Стили для полей формы с иконками --- */

.auth-form .form-field-group {
    margin-bottom: 1.25rem;
}
.auth-form label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.input-group-with-icon {
    position: relative;
}
.input-group-with-icon .fas {
    position: absolute;
    left: 15px;
    top: 24px; /* Фиксируем иконку по высоте для input */
    transform: translateY(-50%);
    color: var(--border-color);
    transition: color 0.2s ease-in-out;
    z-index: 3;
}
/* Смещаем иконку для textarea чуть ниже */
.input-group-with-icon textarea ~ .fas {
    top: 1.6rem;
}


/* --- ИСПРАВЛЕНИЕ ЗДЕСЬ: Общие стили для input и textarea --- */
.input-group-with-icon input,
.input-group-with-icon textarea {
    padding-left: 40px !important;
    width: 100%;
    font-family: var(--font-family);
    background-color: #f8f9fa;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Отдельно для input (однострочное поле) */
.input-group-with-icon input {
    height: 48px;
}
/* Отдельно для textarea (многострочное поле) */
.input-group-with-icon textarea {
    min-height: 120px;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
    resize: vertical;
}

/* Общий стиль для фокуса */
.input-group-with-icon input:focus,
.input-group-with-icon textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(230, 126, 34, 0.25);
}
.input-group-with-icon input:focus ~ .fas,
.input-group-with-icon textarea:focus ~ .fas {
    color: var(--primary-color);
}


.auth-form .invalid-feedback {
    font-size: 0.85rem;
    margin-top: 0.25rem;
}
.auth-form .helptext {
    font-size: 0.8rem;
    color: #7f8c8d;
}

/* --- Стили для кнопки (чтобы соответствовать main.css) --- */
.auth-form .btn-primary {
    padding: 0.8rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- Ссылки под формой --- */
.auth-footer-link {
    text-align: center;
    margin-top: 1.5rem;
}
.auth-footer-link a {
    color: var(--secondary-color);
    font-weight: 600;
    text-decoration: none;
}
.auth-footer-link a:hover {
    color: var(--primary-color);
}
.password-container {
    position: relative;
}

.password-container .form-control {
    padding-right: 45px; /* Оставляем место для иконки */
}

.toggle-password {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6c757d;
    z-index: 100;
}

/* --- Адаптивность для мобильных устройств --- */
@media (max-width: 576px) {
    .auth-container {
        padding: 1.5rem 1rem;
        min-height: auto;
    }
    .auth-card {
        padding: 2rem 1.5rem;
    }
    .auth-header h1 {
        font-size: 1.5rem;
    }
}