:root {
    --primary: #c13d73;
    --primary-dark: #8f2854;
    --primary-light: #f3a9c5;
    --accent: #e77da4;
    --text: #4a2d3b;
    --muted: #806477;
    --bg: #fff5f9;
    --card-bg: #fffafd;
    --border: #efc3d4;
    --radius: 10px;
    --shadow: 0 5px 15px rgba(0,0,0,0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 24px 16px 0;
    font-family: 'Roboto', "Segoe UI", Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color .2s ease;
}

a:hover {
    color: var(--primary-dark);
}

hr {
    border: none;
    height: 2px;
    background: var(--primary);
    opacity: .2;
    margin: 20px 0;
}

.page-title {
    text-align: center;
    color: var(--text);
    font-size: clamp(20px, 4vw, 30px);
    font-weight: 700;
    margin: 0 0 12px;
}

.layout {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    align-items: start;
}

/* Стили сайдбара */
.sidebar {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 20px 18px;
    position: sticky;
    top: 16px;
}

.sidebar h3 {
    color: var(--primary-dark);
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 10px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--border);
}

.sidebar h3.sidebar-contacts-title {
    margin-top: 20px;
}

.sidebar ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar li {
    margin: 0 0 6px 0;
}

.sidebar li a {
    display: block;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 500;
    color: var(--text);
    background: #fff7fa;
    border: 1px solid transparent;
}

.sidebar li a:hover {
    background: #fceaf1;
    color: var(--primary-color);
    border-color: var(--border);
}

.sidebar li a.active {
    background: var(--primary);
    color: #fff;
    font-weight: 600;
}

.sidebar ul li:not(:has(a)) {
    padding: 6px 10px;
    color: var(--muted);
    font-size: 14px;
    word-break: break-word;
}

.content-block {
    background: transparent;
    min-width: 0;
}

.footer-block {
    text-align: center;
    padding: 24px 16px 30px;
    margin-top: 32px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 14px;
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: stretch;
}
/* ============================================================
   ТАБЛИЦА РАСПИСАНИЯ (training.html)
   ============================================================ */
.table-responsive {
    overflow-x: auto;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(117, 36, 76, 0.08);
    background: #ffffff;
    border: 1px solid #f0cbd8;
    margin-bottom: 30px;
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    text-align: center;
    min-width: 640px;
}

.schedule-table th {
    background: linear-gradient(135deg, #c13d73 0%, #75244c 100%);
    color: #fff;
    font-weight: 600;
    padding: 14px 10px;
    white-space: nowrap;
    border: none;
}

.schedule-table td {
    padding: 13px 10px;
    border-bottom: 1px solid #f0cbd8;
    color: #1f2d3d;
}

.schedule-table tbody tr:last-child td {
    border-bottom: none;
}

/* Чередование цветов строк для читаемости */
.schedule-table tbody tr:nth-child(even) {
    background: #f8fafc;
}

/* Плавная подсветка строки при наведении мыши */
.schedule-table tbody tr {
    transition: background-color 0.2s ease;
}

.schedule-table tbody tr:hover {
    background: #fceaf1;
}

.schedule-table td:first-child {
    font-weight: 600;
    text-align: left;
    padding-left: 20px;
    color: #75244c;
}
/* ============================================================
   ФОРМА ЗАПИСИ (training.html)
   ============================================================ */
#form {
    background: #ffffff;
    border: 1px solid #f0cbd8;
    border-top: 1px solid #f0cbd8;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(117, 36, 76, 0.08);
    padding: 32px;
    width: 100%;
    max-width: 580px;
    margin: 0 auto;
}

#form .form-block {
    margin-bottom: 20px;
}

#form .form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14.5px;
    color: #75244c;
}

#form input[type="text"],
#form input[type="date"],
#form select {
    width: 100%;
    padding: 11px 14px;
    border-radius: 8px;
    border: 1px solid #f0cbd8;
    font-size: 15px;
    color: #75244c;
    background-color: #f8fafc;
    transition: all 0.2s ease;
    font-family: inherit;
}

#form input[type="text"]:hover,
#form input[type="date"]:hover,
#form select:hover {
    border-color: #b5c3d6;
    background-color: #ffffff;
}

#form input[type="text"]:focus,
#form input[type="date"]:focus,
#form select:focus {
    outline: none;
    background-color: #ffffff;
    border-color: #c13d73;
    box-shadow: 0 0 0 3px rgba(193, 61, 115, 0.14);
}

/* Группа чекбоксов (выбор снаряда) в виде аккуратных плашек */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #f8fafc;
    border: 1px solid #f0cbd8;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    color: #1f2d3d;
    margin: 0;
}

.checkbox-item:hover {
    background: #fceaf1;
    border-color: #c13d73;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: #c13d73;
    cursor: pointer;
}

/* Подсветка выбранного снаряда (поддерживается всеми современными браузерами) */
.checkbox-item:has(input[type="checkbox"]:checked) {
    background: #fceaf1;
    border-color: #c13d73;
    color: #75244c;
    font-weight: 600;
}

#form .error {
    min-height: 20px;
    margin-top: 6px;
    color: #d9534f;
    font-size: 13.5px;
    font-weight: 500;
}

/* Ряд кнопок */
#form .button-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 24px;
}

#form button {
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

#form button[type="submit"] {
    background: linear-gradient(135deg, #c13d73 0%, #75244c 100%);
    color: #fff;
    box-shadow: 0 4px 10px rgba(193, 61, 115, 0.2);
}

#form button[type="submit"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(193, 61, 115, 0.28);
}

#form button[type="reset"] {
    background: #fceaf1;
    color: #75244c;
    border: 1px solid #f0cbd8;
}

#form button[type="reset"]:hover {
    background: #dfe8f6;
}

#form button:active {
    transform: scale(0.98);
}

@media (max-width: 560px) {
    #form {
        padding: 22px 18px;
    }
    #form .button-row {
        grid-template-columns: 1fr;
    }
}

body {
    color: #4a2d3b !important;
    background: #fff5f9 !important;
}

.site-header,
.sidebar,
.content-card,
.filters-section,
.teacher-card,
.announcement-banner,
.card,
.student-form,
.service-card,
.event-card,
#form,
.table-responsive {
    background-color: #fffafd !important;
    border-color: #efc3d4 !important;
    box-shadow: 0 4px 15px rgba(143, 40, 84, .1) !important;
}

.page-hero,
.modal-header {
    background: linear-gradient(135deg, #e8739d 0%, #a83264 100%) !important;
}

.page-title,
.section-title,
.sub-title,
.sidebar h3,
.card h1,
.card h2,
.card h3,
.teacher-name,
.modal-section h3,
.teacher-degree,
.teacher-position,
.announcement-banner,
.card-link {
    color: #8f2854 !important;
}

.sidebar li a {
    color: #8f2854 !important;
    background-color: #fce7ef !important;
    border-color: #efc3d4 !important;
}

.sidebar li a:hover {
    color: #7d2149 !important;
    background-color: #f5c2d4 !important;
    border-color: #e8adc3 !important;
}

.sidebar li a.active {
    color: #fff !important;
    background: linear-gradient(135deg, #d95f8b 0%, #a83264 100%) !important;
    border-color: #c13d73 !important;
}

a,
.button-link,
.external-link,
.event-link {
    color: #ad315f !important;
}

a:hover,
.button-link:hover,
.external-link:hover,
.event-link:hover {
    color: #7d2149 !important;
}

.announcement-banner a,
a[href="index.html"] {
    color: #c13d73 !important;
}

.announcement-banner a:hover,
a[href="index.html"]:hover {
    color: #8f2854 !important;
}

button,
.btn-primary,
.tab.active,
#form button[type="submit"] {
    color: #fff !important;
    background: linear-gradient(135deg, #d95f8b 0%, #a83264 100%) !important;
    border-color: #c13d73 !important;
}

button:hover,
.btn-primary:hover,
#form button[type="submit"]:hover {
    background: #8f2854 !important;
}

.delete-button {
    background: #b83b6c !important;
}

.btn-light,
#form button[type="reset"] {
    color: #8f2854 !important;
    background: #fce7ef !important;
    border-color: #efc3d4 !important;
}

input,
select,
textarea,
#form input[type="text"],
#form input[type="date"],
#form select {
    color: #4a2d3b !important;
    background-color: #fff8fb !important;
    border-color: #e8adc3 !important;
}

input:focus,
select:focus,
textarea:focus,
#form input[type="text"]:focus,
#form input[type="date"]:focus,
#form select:focus {
    border-color: #c13d73 !important;
    box-shadow: 0 0 0 3px rgba(193, 61, 115, .16) !important;
}

input[type="checkbox"],
input[type="radio"] {
    accent-color: #c13d73 !important;
}

.checkbox-item,
.checkbox-item:has(input[type="checkbox"]:checked) {
    color: #71364f !important;
    background: #fff1f6 !important;
    border-color: #efc3d4 !important;
}

table {
    border-color: #efc3d4 !important;
}

th,
.schedule-table th {
    color: #fff !important;
    background: linear-gradient(135deg, #d95f8b 0%, #a83264 100%) !important;
}

td,
.schedule-table td {
    color: #4a2d3b !important;
    border-color: #f2d5e0 !important;
}

tbody tr:nth-child(even),
.schedule-table tbody tr:nth-child(even) {
    background: #fff0f5 !important;
}

tbody tr:hover,
.schedule-table tbody tr:hover {
    background: #fce2ec !important;
}

.interest-tag,
.tab {
    color: #8f2854 !important;
    background: #fce7ef !important;
    border-color: #efc3d4 !important;
}

.tab.active {
    color: #fff !important;
}

.message {
    color: #8f2854 !important;
    background: #fce7ef !important;
}

.teacher-interests,
.service-card,
.event-card {
    border-color: #efc3d4 !important;
}

.announcement-banner,
.event-card {
    border-left: 1px solid #efc3d4 !important;
}

.service-documents {
    margin: 30px 0;
    padding: 20px;
    border: 1px solid #efc3d4;
    border-radius: 12px;
    background: #fffafd;
}

.service-documents h2 {
    margin-top: 0;
}

.service-pdf-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.service-pdf-list li {
    padding: 10px 0;
    border-bottom: 1px solid #f2d5e0;
}

.service-pdf-list li:last-child {
    border-bottom: 0;
}

.service-pdf-list a {
    font-weight: 600;
}
