/* ===================================
   ОБЩИЕ СТИЛИ
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --success-color: #27ae60;
    --bg-color: #ecf0f1;
    --text-color: #2c3e50;
    --border-color: #bdc3c7;
    --shadow: 0 2px 8px rgba(0,0,0,0.1);
    --max-width: 1200px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

.role-superadmin { background: #8e44ad; }

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 20px;
}

/* ===================================
   HEADER И НАВИГАЦИЯ
   =================================== */
.header {
    background: var(--primary-color);
    color: white;
    padding: 15px 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo-img {
    height: 80px;
    width: auto;
}

.site-title h1 {
    font-size: 1.3rem;
    font-weight: 600;
}

/* Гамбургер меню */
.hamburger {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 25px;
}

.nav-list a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-list a:hover {
    color: var(--secondary-color);
}

/* ===================================
   FOOTER
   =================================== */
.footer {
    background: var(--primary-color);
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}

/* ===================================
   MAIN CONTENT - ИСПРАВЛЕНО
   =================================== */
.main {
    
    padding: 30px 0; /* Уменьшил padding с 20px */
}

h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 2rem;
}

h3 {
    color: var(--primary-color);
    margin: 20px 0 10px;
    font-size: 1.5rem;
}

/* ===================================
   КНОПКИ
   =================================== */
.btn {
    display: inline-block;
    padding: 10px 20px;
    background: var(--secondary-color);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    background: #2980b9;
}

.btn-primary {
    background: var(--secondary-color);
}

.btn-secondary {
    background: #95a5a6;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

.btn-danger {
    background: var(--accent-color);
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-sm {
    padding: 5px 12px;
    font-size: 0.9rem;
}

/* ===================================
   КАРТОЧКИ ПРЕПОДАВАТЕЛЕЙ
   =================================== */
.teachers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.teacher-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}

.teacher-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.teacher-photo {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.teacher-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.no-photo-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: white;
    font-weight: bold;
}

.no-photo-placeholder.small {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
    border-radius: 50%;
}

.no-photo-placeholder.large {
    width: 300px;
    height: 300px;
    font-size: 6rem;
    border-radius: 10px;
}

.teacher-info {
    padding: 20px;
}

.teacher-info h3 {
    margin: 0 0 10px 0;
    font-size: 1.3rem;
}

.teacher-position {
    color: #7f8c8d;
    font-size: 0.95rem;
    margin: 5px 0;
}

.teacher-degree,
.teacher-title {
    font-size: 0.9rem;
    color: #555;
    margin: 3px 0;
}

.teacher-departments {
    font-size: 0.9rem;
    margin: 10px 0;
}

/* ===================================
   ДЕТАЛЬНАЯ СТРАНИЦА ПРЕПОДАВАТЕЛЯ
   =================================== */
.teacher-detail {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.teacher-detail-header {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.teacher-detail-photo {
    flex-shrink: 0;
}

.teacher-detail-photo img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 10px;
}

.teacher-detail-info {
    flex: 1;
}

.teacher-detail-info h2 {
    margin: 0 0 10px 0;
}

.teacher-detail-info .position {
    font-size: 1.2rem;
    color: #7f8c8d;
    margin-bottom: 15px;
}

.detail-section {
    margin: 20px 0; /* Уменьшил с 25px */
    padding: 20px;
    background: var(--bg-color);
    border-radius: 8px;
}

.detail-section h3 {
    margin-top: 0;
    color: var(--primary-color);
    border-bottom: 2px solid var(--secondary-color);
    padding-bottom: 10px;
}

.departments-list {
    list-style: none;
    padding: 0;
}

.departments-list li {
    padding: 10px;
    margin: 5px 0;
    background: white;
    border-radius: 5px;
}

.departments-list a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
}

.consultations-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.consultations-table th,
.consultations-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.consultations-table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
}

.consultations-table tr:hover {
    background: var(--bg-color);
}

.back-link {
    margin-top: 20px; /* Уменьшил с 30px */
}

/* ===================================
   КАФЕДРЫ
   =================================== */
.departments-list-page {
    display: grid;
    gap: 20px;
}

.department-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}

.department-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.department-card h3 {
    margin-top: 0;
}

.department-card h3 a {
    color: var(--primary-color);
    text-decoration: none;
}

.department-card h3 a:hover {
    color: var(--secondary-color);
}

.department-description {
    color: #555;
    margin: 15px 0;
}

.department-stats {
    color: #7f8c8d;
    font-size: 0.95rem;
}

.department-detail {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.department-description-full {
    margin-bottom: 30px;
    padding: 20px;
    background: var(--bg-color);
    border-radius: 8px;
}

.teachers-list {
    display: grid;
    gap: 15px;
}

.teacher-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    background: var(--bg-color);
    border-radius: 8px;
    align-items: center;
}

.teacher-item-photo {
    flex-shrink: 0;
}

.teacher-item-photo img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 50%;
}

.teacher-item-info h4 {
    margin: 0 0 5px 0;
}

.teacher-item-info h4 a {
    color: var(--primary-color);
    text-decoration: none;
}

.teacher-item-info h4 a:hover {
    color: var(--secondary-color);
}

.teacher-meta {
    font-size: 0.9rem;
    color: #555;
    margin: 3px 0;
}

/* ===================================
   РАСПИСАНИЕ КОНСУЛЬТАЦИЙ
   =================================== */
.consultations-schedule {
    display: grid;
    gap: 20px; /* Уменьшил с 25px */
}

.schedule-day {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.schedule-day h3 {
    margin-top: 0;
    background: var(--secondary-color);
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.schedule-table th,
.schedule-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.schedule-table th {
    background: var(--bg-color);
    font-weight: 600;
}

.schedule-table a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
}

.schedule-table a:hover {
    text-decoration: underline;
}

.time-cell {
    font-weight: 600;
    color: var(--primary-color);
    white-space: nowrap;
}

/* ===================================
   ГЛАВНАЯ СТРАНИЦА
   =================================== */
.welcome {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.welcome h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.welcome p {
    font-size: 1.2rem;
    color: #7f8c8d;
    margin-bottom: 30px;
}

.home-links {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===================================
   АДАПТИВНОСТЬ (Мобильные)
   =================================== */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: var(--primary-color);
        transition: right 0.3s;
        padding: 80px 20px 20px;
        box-shadow: -2px 0 10px rgba(0,0,0,0.3);
    }

    .nav.active {
        right: 0;
    }

    .nav-list {
        flex-direction: column;
        gap: 20px;
    }

    .header-content {
        flex-wrap: nowrap;
    }

    .site-title h1 {
        font-size: 1rem;
    }

    .teachers-grid {
        grid-template-columns: 1fr;
    }

    .teacher-detail-header {
        flex-direction: column;
    }

    .teacher-detail-photo img,
    .no-photo-placeholder.large {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .schedule-table {
        font-size: 0.9rem;
    }

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

    .main {
        padding: 20px 0;
    }
}

/* ===================================
   АДМИНИСТРАТИВНАЯ ПАНЕЛЬ
   =================================== */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.login-box h1 {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.login-box h2 {
    text-align: center;
    font-size: 1.3rem;
    color: #7f8c8d;
    margin-bottom: 30px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-hint {
    text-align: center;
    font-size: 0.85rem;
    color: #7f8c8d;
    margin-top: 15px;
}

/* Admin Layout */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 250px;
    background: var(--primary-color);
    color: white;
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.admin-logo {
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 20px;
}

.admin-logo h2 {
    color: white;
    font-size: 1.4rem;
    margin: 0;
}

.admin-nav ul {
    list-style: none;
}

.admin-nav li {
    margin: 5px 0;
}

.admin-nav a {
    display: block;
    padding: 12px 20px;
    color: white;
    text-decoration: none;
    transition: background 0.3s;
}

.admin-nav a:hover,
.admin-nav a.active {
    background: rgba(255,255,255,0.1);
    border-left: 3px solid var(--secondary-color);
}

.admin-content {
    margin-left: 250px;
    flex: 1;
    padding: 30px;
    background: var(--bg-color);
}

.admin-header {
    margin-bottom: 30px;
}

.admin-header h1 {
    color: var(--primary-color);
    margin-bottom: 5px;
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-card h3 {
    margin: 0 0 10px 0;
    color: #7f8c8d;
    font-size: 1rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--secondary-color);
    margin: 10px 0;
}

.quick-actions {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 15px;
}

/* Admin Forms */
.admin-form {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.form-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.form-section:last-of-type {
    border-bottom: none;
}

.form-section h3 {
    color: var(--primary-color);
    margin: 0 0 20px 0;
    font-size: 1.3rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-color);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="url"],
.form-group input[type="number"],
.form-group input[type="time"],
.form-group input[type="file"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group textarea {
    resize: vertical;
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: #7f8c8d;
    font-size: 0.85rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.checkbox-label {
    display: block;
    padding: 8px;
    margin: 5px 0;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    margin-right: 8px;
}

.consultation-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    align-items: center;
}

.consultation-row select,
.consultation-row input {
    flex: 1;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
}

.btn-remove {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
}

.btn-remove:hover {
    background: #c0392b;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* Admin Table */
.admin-table {
    width: 100%;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    border-collapse: collapse;
}

.admin-table thead {
    background: var(--primary-color);
    color: white;
}

.admin-table th,
.admin-table td {
    padding: 15px;
    text-align: left;
}

.admin-table tbody tr {
    border-bottom: 1px solid var(--border-color);
}

.admin-table tbody tr:hover {
    background: var(--bg-color);
}

.admin-table .actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.teacher-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 5px;
}

.no-photo {
    width: 60px;
    height: 60px;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    font-size: 0.8rem;
    color: #7f8c8d;
}

.current-photo {
    margin: 10px 0;
}

/* Messages */
.success-message,
.error-message {
    padding: 15px 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    font-weight: 500;
}

.success-message {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ===================================
   АДАПТИВНОСТЬ АДМИН-ПАНЕЛИ
   =================================== */
@media (max-width: 1024px) {
    .admin-sidebar {
        width: 200px;
    }

    .admin-content {
        margin-left: 200px;
    }
}

@media (max-width: 768px) {
    .admin-sidebar {
        position: fixed;
        left: -250px;
        transition: left 0.3s;
        z-index: 1000;
        width: 250px;
    }

    .admin-sidebar.active {
        left: 0;
    }

    .admin-content {
        margin-left: 0;
        padding: 15px;
    }

    .dashboard-stats {
        grid-template-columns: 1fr;
    }

    .admin-table {
        font-size: 0.85rem;
    }

    .admin-table th,
    .admin-table td {
        padding: 10px;
    }

    .form-actions {
        flex-direction: column;
    }

    .consultation-row {
        flex-direction: column;
    }
}

/* ===================================
   УТИЛИТЫ
   =================================== */
.text-center {
    text-align: center;
}

.text-muted {
    color: #7f8c8d;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}
/* ===================================
   РАБОЧЕЕ РЕШЕНИЕ - ПРАВИЛЬНЫЙ CSS GRID
   ЗАМЕНИТЕ ПРЕДЫДУЩИЙ БЛОК НА ЭТОТ
   =================================== */

/* CSS Grid без растягивания main */
body {
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    min-height: 100vh !important;
}

.header {
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important;
}

.main {
    padding: 0 !important;
    margin: 0 !important;
    align-self: start !important; /* Контент сверху, не растягивается */
}

.footer {
    margin-top: 0 !important;
}

/* Container без верхнего padding */
.container {
    padding: 0 20px 20px 20px !important;
}

/* Заголовки с минимальным отступом */
.container > h2:first-child,
h2 {
    margin-top: 20px !important;
    margin-bottom: 15px !important;
    padding-top: 0 !important;
}

/* Компактные элементы */
.departments-list-page,
.consultations-schedule,
.teachers-grid {
    gap: 15px !important;
    margin-top: 0 !important;
}

.department-card,
.schedule-day {
    padding: 20px !important;
    margin: 0 !important;
}

.welcome {
    padding: 40px 20px !important;
    margin: 0 !important;
}

.teacher-detail,
.department-detail {
    padding: 25px !important;
    margin: 0 !important;
}

.detail-section {
    margin: 15px 0 !important;
    padding: 15px !important;
}

/* Мобильная версия */
@media (max-width: 768px) {
    .container {
        padding: 0 15px 15px 15px !important;
    }
    
    .container > h2:first-child,
    h2 {
        margin-top: 15px !important;
    }
}
/* ===================================
   СТИЛИ ДЛЯ ГЛАВНОЙ СТРАНИЦЫ
   Добавьте в конец файла styles.css
   =================================== */

/* Hero секция */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    margin-bottom: 40px;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 15px;
    color: white !important;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 40px;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-large {
    padding: 15px 35px;
    font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
}

.btn-large:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

.btn-icon {
    font-size: 1.5rem;
}

.btn-accent {
    background: #e74c3c;
}

.btn-accent:hover {
    background: #c0392b;
}

/* Статистика */
.stats-section {
    padding: 40px 0;
    background: white;
    margin-bottom: 40px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.stat-box {
    text-align: center;
    padding: 30px;
    background: var(--bg-color);
    border-radius: 15px;
    transition: transform 0.3s;
}

.stat-box:hover {
    transform: translateY(-5px);
}

.stat-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.stat-label {
    color: #7f8c8d;
    font-size: 1rem;
}

/* Последние преподаватели */
.recent-section {
    padding: 40px 0;
    margin-bottom: 40px;
}

.section-title {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 30px;
    font-size: 2rem;
}

.recent-teachers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.recent-teacher-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
}

.recent-teacher-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.recent-teacher-photo {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.recent-teacher-photo img {
    
    height: 100%;
    object-fit: cover;
}

.recent-teacher-info {
    padding: 20px;
}

.recent-teacher-info h3 {
    margin: 0 0 10px 0;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.recent-teacher-info .teacher-position {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.recent-teacher-info .teacher-departments {
    font-size: 0.85rem;
    color: #555;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.icon {
    font-size: 1rem;
}

.section-footer {
    text-align: center;
}

/* Информационные карточки */
.info-section {
    padding: 40px 0;
    background: var(--bg-color);
    margin-bottom: 0;
}

.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.info-card {
    background: white;
    padding: 35px 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: all 0.3s;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.info-card-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.info-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.info-card p {
    color: #7f8c8d;
    margin-bottom: 20px;
    line-height: 1.6;
}

.info-link {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: color 0.3s;
}

.info-link:hover {
    color: #2980b9;
}

/* Анимации появления */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-box,
.recent-teacher-card,
.info-card {
    animation: fadeInUp 0.6s ease-out;
}

.stat-box:nth-child(2) {
    animation-delay: 0.1s;
}

.stat-box:nth-child(3) {
    animation-delay: 0.2s;
}

.stat-box:nth-child(4) {
    animation-delay: 0.3s;
}

/* Адаптивность */
@media (max-width: 768px) {
    .hero-section {
        padding: 50px 0;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-large {
        width: 100%;
        justify-content: center;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .stat-box {
        padding: 20px;
    }

    .stat-number {
        font-size: 2rem;
    }

    .recent-teachers-grid,
    .info-cards {
        grid-template-columns: 1fr;
    }
}
/* ===================================
   СТИЛИ ДЛЯ НОВЫХ СЕКЦИЙ
   Добавьте в конец файла styles.css
   =================================== */

/* Секция достижений */
.achievements-section {
    background: linear-gradient(135deg, #fff9e6 0%, #fffaf0 100%);
    border-left: 4px solid #f39c12;
}

.achievements-section h3 {
    color: #f39c12 !important;
    border-bottom-color: #f39c12 !important;
}

.achievements-content {
    line-height: 1.8;
    white-space: pre-line;
}

/* Секция дополнительной информации */
.additional-info-section {
    background: linear-gradient(135deg, #e8f4fd 0%, #f0f8ff 100%);
    border-left: 4px solid #3498db;
}

.additional-info-section h3 {
    color: #3498db !important;
    border-bottom-color: #3498db !important;
}

.additional-info-content {
    line-height: 1.8;
    white-space: pre-line;
}

/* Общие улучшения для секций */
.detail-section.achievements-section,
.detail-section.additional-info-section {
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* ===================================
   СТИЛИ ДЛЯ ВЫБОРА РОЛЕЙ
   Добавьте в styles.css
   =================================== */

/* Контейнер выбора роли */
.role-selection {
    margin: 20px 0;
}

/* Карточка роли */
.role-option {
    position: relative;
    padding: 20px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    display: block;
}

.role-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Активная (выбранная) карточка */
.role-option.selected,
.role-option:has(input[type="radio"]:checked) {
    border-color: #3498db;
    background: linear-gradient(135deg, #e8f4fd 0%, #f8f9fa 100%);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.2);
}

/* Радио кнопка внутри */
.role-option input[type="radio"] {
    margin-right: 12px;
    cursor: pointer;
    width: 20px;
    height: 20px;
    vertical-align: middle;
}

/* Заголовок роли */
.role-option strong {
    font-size: 1.1rem;
    color: #2c3e50;
    display: inline-flex;
    align-items: center;
}

/* Описание роли */
.role-description {
    margin: 10px 0 0 32px;
    color: #7f8c8d;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Иконки эмодзи в ролях */
.role-option strong::before {
    font-size: 1.3rem;
    margin-right: 8px;
}

/* Анимация при выборе */
.role-option input[type="radio"]:checked ~ * {
    color: #2c3e50;
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
    .role-option {
        padding: 15px;
    }

    .role-description {
        margin-left: 28px;
        font-size: 0.85rem;
    }
}

/* Альтернативный стиль - карточки */
.role-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.role-card {
    position: relative;
    padding: 25px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    text-align: center;
}

.role-card:hover {
    border-color: #3498db;
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
}

.role-card.selected {
    border-color: #3498db;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.role-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.role-card .role-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.role-card .role-title {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.role-card .role-desc {
    font-size: 0.9rem;
    color: rgba(0,0,0,0.6);
}

.role-card.selected .role-desc {
    color: rgba(255,255,255,0.9);
}
/* Гамбургер для админки */
.admin-hamburger {
    display: none;
    flex-direction: column;
    background: var(--primary-color);
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 5px;
    position: fixed;
    top: 10px;
    left: 15px;
    z-index: 1100;
}

.admin-hamburger span {
    width: 25px;
    height: 3px;
    background: white;
    margin: 3px 0;
    border-radius: 2px;
    transition: 0.3s;
}

.admin-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

.admin-overlay.active {
    display: block;
}

@media (max-width: 768px) {
    .admin-hamburger {
        display: flex;
    }

    .admin-content {
        padding-top: 60px; /* место под кнопку */
    }
}