:root {
    --primary-color: #005239;
    --secondary-color: #003d2b;
    --success-color: #2ec4b6;
    --danger-color: #ef233c;
    --bg-light: #f4f7f6;
    --card-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

body {
    background-color: var(--bg-light);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: #2b2d42;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
}

/* Центрирование контейнеров */
.container {
    max-width: 1140px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px;
    padding-right: 15px;
    width: 100%;
}

/* Обертка для страницы логина */
.login-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 15px;
}

.navbar {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
    padding: 0.75rem 0;
    margin-bottom: 1rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.card {
    border: none;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    background: #fff;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    width: 100%;
}

/* Стилизация форм */
.form-control {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 12px 15px;
    transition: all 0.3s ease;
    font-size: 16px !important; /* Предотвращает зум на iPhone */
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 82, 57, 0.1);
}

.btn {
    border-radius: 8px;
    padding: 12px 20px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    border: none;
    color: white;
}

/* Поиск */
.search-box {
    position: relative;
    width: 100%;
}

.search-box .form-control {
    padding-left: 45px !important;
    height: 54px;
}

.search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
}

/* Таблицы */
.table-responsive {
    border-radius: 10px;
    border: 1px solid #eee;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table thead th {
    background-color: #f8f9fa;
    color: #6c757d;
    padding: 15px;
    font-size: 0.7rem;
    text-transform: uppercase;
    white-space: nowrap;
}

.table td {
    padding: 15px;
    vertical-align: middle;
    font-size: 14px;
}

.badge-status {
    font-weight: 600;
    padding: 0.5em 0.8em;
    border-radius: 6px;
    font-size: 11px;
}

/* Мобильная адаптация (КРИТИЧЕСКИЕ ИСПРАВЛЕНИЯ) */
@media (max-width: 767.98px) {
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }

    .card {
        padding: 1.25rem 1rem;
        margin-bottom: 1rem;
    }

    .navbar-brand {
        font-size: 1rem;
    }

    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
        padding: 14px; /* Больше область нажатия */
    }

    .table td, .table th {
        padding: 12px 8px;
    }

    .display-flex-mobile {
        display: flex;
        flex-direction: column;
    }
}
