/* ==========================================================================
   ОБЩИЕ СТИЛИ ДЛЯ ВСЕХ СТРАНИЦ
   ========================================================================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: linear-gradient(135deg, #f4f7f6 0%, #e9f0ee 100%);
    color: #1a1a1a;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

/* Элегантная премиум-карточка */
.page-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 480px; 
    background-color: #ffffff;
    padding: 40px;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 127, 110, 0.03), 
                0 30px 60px rgba(0, 0, 0, 0.04);
}

/* Для страниц личных кабинетов делаем карточку чуть шире */
.page-container.wide {
    max-width: 650px;
}

/* Шапка клиники */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.company-name {
    color: #0d4f45; /* Глубокий темно-изумрудный */
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}

.company-name.admin-title {
    color: #801f00; /* Бордовый для админки */
}

.company-mission {
    color: #8a9996;
    font-size: 13px;
    font-weight: 400;
}

/* Блоки уведомлений и информации */
.info-section {
    text-align: center;
    background-color: #f0f6f4;
    padding: 14px 20px;
    border-radius: 12px;
    margin-bottom: 30px;
    font-size: 13px;
    line-height: 1.5;
    color: #4a5c58;
}

/* Предупреждение о неподтвержденной почте */
.info-section.warning {
    background-color: #ffebe6;
    color: #801f00;
    border: 1px solid #ffc2b3;
}

/* Инфо-блок для админки */
.info-section.admin {
    background-color: #f0f4f8;
    color: #1c3d5a;
    border: 1px solid #bcdefa;
    font-weight: bold;
}

.auth-container {
    flex: 1;
    margin-bottom: 30px;
}

.auth-title {
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 25px;
    color: #007f6e;
}

/* ==========================================================================
   ПОЛЯ ВВОДА И ВАЛИДАЦИЯ (Работа №6)
   ========================================================================== */
.form-group {
    display: flex;
    flex-direction: column; 
    margin-bottom: 20px;
}

.form-group label {
    width: 100%;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #7f918e;
    margin-bottom: 6px;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    background-color: #f7faf9;
    border: 1px solid transparent; 
    border-radius: 12px;
    font-size: 15px;
    color: #1a1a1a;
    transition: all 0.25s ease;
}

/* Интерактивная подсветка валидации встроенными средствами браузера */
.form-group input:valid:not(:placeholder-shown) {
    border-color: #007f6e;
    background-color: #f0f6f4;
}

.form-group input:invalid:not(:placeholder-shown) {
    border-color: #cc0000;
    background-color: #ffe6e6;
}

.form-group input:focus {
    background-color: #ffffff;
    border-color: #007f6e;
    box-shadow: 0 0 0 4px rgba(0, 127, 110, 0.1);
    outline: none;
}

/* Выбор роли (кружочки) */
.radio-group {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    background: #f0f6f4;
    padding: 14px;
    border-radius: 12px;
    justify-content: center;
}

.radio-option {
    display: flex;
    align-items: center;
    font-size: 14px;
    color: #0d4f45;
    font-weight: 600;
    cursor: pointer;
}

.radio-option input {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    accent-color: #007f6e;
}

.checkbox-group {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    font-size: 13px;
    color: #4a5c58;
}

.checkbox-group input {
    margin-right: 10px;
    width: 16px;
    height: 16px;
    accent-color: #007f6e;
}

/* Подсказки под полями */
.file-hint {
    font-size: 11px;
    color: #8a9996;
    margin-top: 4px;
    font-style: italic;
}

/* ==========================================================================
   КНОПКИ И ССЫЛКИ
   ========================================================================== */
.form-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Градиентная изумрудная кнопка */
.btn-submit {
    background: linear-gradient(135deg, #009684 0%, #007f6e 100%);
    color: #ffffff;
    border: none;
    padding: 16px;
    font-size: 15px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(0, 127, 110, 0.2);
    transition: all 0.2s ease;
    text-align: center;
    text-decoration: none;
    display: block;
    width: 100%;
}

.btn-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 127, 110, 0.3);
}

/* Темно-синяя кнопка для админки */
.btn-submit.btn-admin {
    background: linear-gradient(135deg, #2c5282 0%, #1a365d 100%);
    box-shadow: 0 4px 15px rgba(26, 54, 93, 0.2);
}

.btn-reg {
    background: #ffffff;
    color: #007f6e;
    border: 2px solid #007f6e;
    padding: 14px;
    font-size: 15px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-reg:hover {
    background-color: #f0f6f4;
}

.auth-link {
    font-size: 13px;
    color: #7f918e;
    text-decoration: none;
    text-align: center;
    font-weight: 500;
    transition: color 0.2s;
    display: block;
}

.auth-link:hover {
    color: #007f6e;
    text-decoration: underline;
}

/* ==========================================================================
   МЕДИЦИНСКИЕ ТАБЛИЦЫ И СТРУКТУРЫ (Кабинеты и Ошибки)
   ========================================================================== */
table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 25px;
    margin-top: 15px;
}

th {
    background-color: #007f6e;
    color: white;
    padding: 12px 14px;
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Синяя шапка для таблиц админа */
.admin-table th {
    background-color: #1c3d5a;
}

td {
    padding: 12px 14px;
    font-size: 14px;
    border-bottom: 1px solid #e9f0ee;
    color: #1a1a1a;
}

.profile-table td:first-child {
    font-weight: 600;
    color: #7f918e;
    width: 45%;
}

h3 {
    color: #0d4f45;
    font-size: 15px;
    font-weight: 700;
    margin-top: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer {
    text-align: center;
    border-top: 1px solid #f0f3f2;
    padding-top: 20px;
    font-size: 11px;
    color: #9aa8a5;
    line-height: 1.6;
}

/* Технические детали и контейнеры файлов */
.tech-details {
    background-color: #f7faf9;
    padding: 14px;
    border-radius: 12px;
    font-size: 12px;
    color: #7f918e;
    font-family: monospace;
    word-break: break-all;
    margin-bottom: 25px;
    border: 1px solid #e9f0ee;
}
