/* ============================================================
   СТРАНИЦА «АБИТУРИЕНТУ» v9.6 — ПОЛНЫЙ CSS
   Ярославское музыкальное училище (колледж) им. Л.В. Собинова
   ============================================================ */

/* ---------- ПЕРЕМЕННЫЕ ---------- */
:root {
  --c-primary:        #1a365d;
  --c-primary-light:  #2a4365;
  --c-primary-dark:   #102a4e;
  --c-accent:         #c53030;
  --c-accent-hover:   #9b2c2c;
  --c-text-main:      #2d3748;
  --c-text-muted:     #718096;
  --c-text-light:     #a0aec0;
  --c-bg-body:        #f7fafc;
  --c-bg-surface:     #ffffff;
  --c-bg-contrast:    #edf2f7;
  --c-bg-hover:       rgba(26, 54, 93, 0.02);
  --c-border:         #e2e8f0;
  --c-success:        #38a169;
  --c-warning:        #d69e2e;
  --font-sans:        'Inter', system-ui, -apple-system, sans-serif;
  --font-serif:       'Playfair Display', serif;
  --base-line-height: 1.6;
  --transition-base:  0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast:  0.15s ease;
  --shadow-sm:        0 1px 2px rgba(0,0,0,0.05);
  --shadow-md:        0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg:        0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-card:      0 2px 6px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.02);
  --shadow-card-hover: 0 6px 14px rgba(0,0,0,0.06), 0 2px 4px rgba(0,0,0,0.03);
  --radius-sm:        6px;
  --radius-md:        12px;
  --radius-lg:        20px;
  --container-width:  1240px;
}

/* ---------- СБРОС ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}
body {
  font-family: var(--font-sans);
  background-color: var(--c-bg-body);
  color: var(--c-text-main);
  line-height: var(--base-line-height);
  min-height: 100vh;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--c-primary); text-decoration: none; transition: color 0.2s ease-in-out; }
a:hover { color: var(--c-accent); }
ul, ol { list-style: none; }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  color: var(--c-primary);
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: 1rem;
}
p { margin-bottom: 1rem; }

/* ---------- УТИЛИТЫ ---------- */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.text-accent { color: var(--c-accent); }
.text-muted { color: var(--c-text-muted); }

/* ---------- ФОКУС ---------- */
:focus-visible {
  outline: 2px solid var(--c-accent);
  outline-offset: 2px;
}

/* ---------- КНОПКИ ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background-color: var(--c-primary);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background-color: var(--c-primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: #fff;
}
.btn-text {
  background: transparent;
  color: var(--c-primary);
  padding: 0;
}
.btn-text:hover { color: var(--c-accent); }
.btn-gosuslugi {
  background: linear-gradient(135deg, #0063B0 0%, #ED1B2E 100%);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-gosuslugi:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: #fff;
}

/* ---------- БЕЙДЖИ ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 9999px;
  line-height: 1;
}
.badge-outline {
  border: 1px solid var(--c-border);
  color: var(--c-text-muted);
  background: transparent;
}
.badge-filled {
  background-color: rgba(197, 48, 48, 0.1);
  color: var(--c-accent);
}

/* ---------- HERO ---------- */
.hero-section {
  position: relative;
  padding: 4rem 0 5rem;
  background-color: var(--c-bg-surface);
  border-bottom: 1px solid var(--c-border);
  overflow: hidden;
}
.hero-section::before {
  content: '';
  position: absolute;
  top: -50%; right: -20%;
  width: 80%; height: 200%;
  background: radial-gradient(circle at center, rgba(26,54,93,0.04) 0%, rgba(255,255,255,0) 60%);
  pointer-events: none;
  z-index: 0;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
  position: relative;
  z-index: 1;
}
.hero-content { max-width: 600px; }
.hero-badges {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
}
.hero-title {
  font-size: clamp(2rem, 5vw, 3.75rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.25rem;
  color: var(--c-primary);
}
.text-accent-hero {
  color: var(--c-accent);
  font-style: italic;
  padding-right: 0.2em;
}
.hero-subtitle {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--c-text-muted);
  margin-bottom: 2.5rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

/* Выпадающий список годов */
.hero-year-selector { position: relative; display: inline-block; }
#heroYearSelectorToggle {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
}
.hero-year-selector__arrow {
  font-size: 0.8em;
  transition: transform 0.2s ease-in-out;
}
#heroYearSelectorToggle[aria-expanded="true"] .hero-year-selector__arrow {
  transform: rotate(180deg);
}
.hero-year-selector__menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 1000;
  min-width: 100%;
  background-color: var(--c-bg-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  padding: 0.5rem 0;
  animation: fadeIn 0.15s ease-out;
}
.hero-year-selector__menu.show { display: block; }
.hero-year-selector__item {
  display: block;
  padding: 0.6rem 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--c-text-main);
  white-space: nowrap;
  text-decoration: none;
}
.hero-year-selector__item:hover,
.hero-year-selector__item:focus {
  background-color: var(--c-bg-contrast);
  color: var(--c-primary);
}
.hero-year-selector__item.active {
  background-color: var(--c-primary);
  color: #ffffff;
  cursor: default;
}

/* Карточка в hero */
.hero-card {
  background-color: var(--c-bg-surface);
  padding: 2.5rem 2rem;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
  border: 1px solid var(--c-border);
  text-align: center;
  max-width: 380px;
  margin-left: auto;
  transition: box-shadow 0.3s, transform 0.3s;
}
.hero-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 25px 30px -8px rgba(0,0,0,0.15);
}
.hero-card-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  color: var(--c-text-muted);
  margin-bottom: 1.5rem;
}
.status-dot {
  width: 10px; height: 10px;
  background-color: var(--c-accent);
  border-radius: 50%;
  display: inline-block;
}
.status-dot.pulsing { animation: pulse-red 2s infinite; }
@keyframes pulse-red {
  0% { box-shadow: 0 0 0 0 rgba(197, 48, 48, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(197, 48, 48, 0); }
  100% { box-shadow: 0 0 0 0 rgba(197, 48, 48, 0); }
}
.hero-card-body .date-big {
  display: block;
  font-family: var(--font-serif);
  font-size: 5.5rem;
  font-weight: 700;
  line-height: 1;
  color: var(--c-primary);
  margin-bottom: 0.5rem;
}
.hero-card-body .date-month {
  display: block;
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--c-text-main);
  margin-bottom: 2rem;
}
.btn-hero-card {
  width: 100%;
  background-color: var(--c-primary);
  color: #fff;
  padding: 1rem;
  font-size: 0.9rem;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.btn-hero-card:hover {
  background-color: var(--c-primary-light);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  color: #fff;
}

/* ---------- СЕТКА ---------- */
.layout-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  margin-top: 3rem;
  margin-bottom: 5rem;
}

/* ---------- САЙДБАР ---------- */
.sidebar { position: relative; }
.sticky-nav {
  position: sticky;
  top: 2rem;
  background-color: var(--c-bg-surface);
  padding: 1.5rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--c-border);
  box-shadow: var(--shadow-sm);
  z-index: 10;
}
.nav-list { display: flex; flex-direction: column; gap: 0.5rem; }
.nav-link {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  color: var(--c-text-muted);
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: var(--transition-base);
  border-left: 3px solid transparent;
}
.nav-link:hover {
  background-color: var(--c-bg-contrast);
  color: var(--c-primary);
}
.nav-link.active {
  background-color: rgba(26, 54, 93, 0.08);
  color: var(--c-primary);
  font-weight: 600;
  border-left-color: var(--c-primary);
}
.sidebar-widget {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--c-border);
}
.widget-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--c-text-muted);
  margin-bottom: 1rem;
}
.widget-contact {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.875rem;
  font-size: 0.9rem;
  font-weight: 500;
}
.widget-contact svg { color: var(--c-accent); flex-shrink: 0; }
.widget-contact a { color: var(--c-text-main); }
.widget-contact a:hover { color: var(--c-accent); }

/* ---------- КОНТЕНТ ---------- */
.content-area { display: flex; flex-direction: column; gap: 6rem; }
.content-section {
  scroll-margin-top: 2rem;
  animation: slideUpFade 0.6s ease-out forwards;
}
@keyframes slideUpFade {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
.section-title {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--c-primary);
  margin-bottom: 2.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--c-border);
  position: relative;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 80px; height: 3px;
  background-color: var(--c-accent);
  border-radius: 2px;
}

/* ---------- ПРАВИЛА ПРИЁМА ---------- */
.rules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}
.rule-card {
  background-color: var(--c-bg-surface);
  padding: 2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--c-border);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  position: relative;
  overflow: hidden;
}
.rule-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.rule-icon {
  font-family: var(--font-serif);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1;
  color: var(--c-accent);
  margin-bottom: 1.25rem;
}
.rule-card h3 {
  font-family: var(--font-sans);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--c-primary);
  margin-bottom: 0.75rem;
}
.rule-card p {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--c-text-muted);
}

/* ---------- ПЛАТНЫЕ УСЛУГИ / БЛОКИ С ПРАВИЛАМИ ---------- */
.text-content-block {
  background-color: var(--c-bg-surface);
  border-radius: var(--radius-md);
  padding: 2rem;
  border: 1px solid var(--c-border);
  margin-bottom: 2rem;
}
.text-content-block p {
  color: var(--c-text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}
.text-content-block p:last-child { margin-bottom: 0; }
.text-content-block strong { color: var(--c-text-main); font-weight: 600; }
.cta-container { text-align: center; margin-top: 1rem; }

.rules-excerpt-block {
  background-color: var(--c-bg-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--c-border);
  border-left: 4px solid var(--c-primary);
  padding: 2rem;
}
.rules-preamble {
  font-style: italic;
  color: var(--c-text-muted);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px dashed var(--c-border);
}
.rules-excerpt-block ol {
  list-style: none;
  counter-reset: main-counter;
  padding-left: 0;
}
.rules-excerpt-block ol > li {
  counter-increment: main-counter;
  position: relative;
  padding-left: 2.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  line-height: 1.7;
}
.rules-excerpt-block ol > li::before {
  content: counter(main-counter) ".";
  position: absolute;
  left: 0; top: 0;
  font-weight: 700;
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: var(--c-primary);
}
.rules-excerpt-block ul {
  list-style: none;
  padding-left: 1rem;
  margin-top: 1rem;
}
.rules-excerpt-block ul > li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.75rem;
}
.rules-excerpt-block ul > li::before {
  content: '—';
  position: absolute;
  left: 0; top: 0;
  color: var(--c-accent);
  font-weight: 700;
}
.rules-excerpt-block .alpha-list {
  counter-reset: alpha-counter;
  margin-top: 1.5rem;
  padding-left: 1rem;
}
.rules-excerpt-block .alpha-list > li {
  counter-increment: alpha-counter;
  padding-left: 2rem;
}
.rules-excerpt-block .alpha-list > li::before {
  content: counter(alpha-counter, lower-alpha) ") ";
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--c-text-main);
}

/* ---------- СПЕЦИАЛЬНОСТИ ---------- */
.specialties-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}
.spec-card {
  display: flex;
  flex-direction: column;
  background-color: var(--c-bg-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition-base);
}
.spec-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.spec-card__header { padding: 1.5rem; text-align: center; color: #fff; }
.spec-card--instrumental .spec-card__header { background: linear-gradient(135deg, #1a365d 0%, #2a4365 100%); }
.spec-card--vocal .spec-card__header        { background: linear-gradient(135deg, #c53030 0%, #e53e3e 100%); }
.spec-card--choral .spec-card__header       { background: linear-gradient(135deg, #2f855a 0%, #38a169 100%); }
.spec-card--theory .spec-card__header       { background: linear-gradient(135deg, #6b46c1 0%, #805ad5 100%); }
.spec-code {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  background-color: rgba(255,255,255,0.2);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.75rem;
}
.spec-name { font-family: var(--font-serif); font-size: 1.25rem; margin: 0; color: #fff; }
.spec-card__body { padding: 1.5rem; flex-grow: 1; }
.spec-desc { font-size: 0.9375rem; color: var(--c-text-main); margin-bottom: 1.5rem; }
.spec-instruments summary {
  font-size: 0.875rem; font-weight: 600; color: var(--c-primary);
  cursor: pointer; margin-bottom: 1rem; outline: none;
}
.spec-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.5rem; }
.tag {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  background-color: var(--c-bg-contrast);
  border-radius: 4px;
  color: var(--c-text-muted);
  transition: background-color 0.2s, color 0.2s;
}
.tag:hover { background-color: var(--c-primary); color: #fff; }
.alert-box {
  display: flex; gap: 0.75rem;
  padding: 0.75rem 1rem;
  background-color: #fff5f5;
  border-left: 3px solid var(--c-accent);
  border-radius: 4px;
  font-size: 0.875rem;
  color: #742a2a;
  margin-top: 1rem;
}
.alert-icon { flex-shrink: 0; color: var(--c-accent); margin-top: 2px; }
.spec-card__footer { background-color: var(--c-bg-contrast); border-top: 1px solid var(--c-border); }
.spec-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  text-align: center;
  padding: 1rem 0;
}
.stat-col { padding: 0 0.5rem; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.stat-col:nth-child(2) { border-left: 1px solid var(--c-border); border-right: 1px solid var(--c-border); }
.stat-val { font-family: var(--font-serif); font-size: 1.5rem; font-weight: 700; color: var(--c-primary); }
.stat-col--paid .stat-val { color: var(--c-text-muted); }
.stat-lbl { font-size: 0.75rem; text-transform: uppercase; font-weight: 600; color: var(--c-text-muted); }
.spec-exams-list { padding: 1.25rem 1.5rem; border-top: 1px solid var(--c-border); }
.exams-title { display: block; font-size: 0.875rem; font-weight: 700; margin-bottom: 1rem; color: var(--c-text-main); }
.exams-checklist { display: flex; flex-direction: column; gap: 0.75rem; }
.exams-checklist li {
  display: flex; align-items: flex-start; gap: 0.75rem;
  font-size: 0.9rem; color: var(--c-text-muted); line-height: 1.5;
}
.exams-checklist svg { color: var(--c-accent); flex-shrink: 0; width: 18px; height: 18px; margin-top: 3px; }

/* ---------- ТАЙМЛАЙН ---------- */
.timeline-wrapper { display: flex; flex-direction: column; }
.timeline-row { display: grid; grid-template-columns: 120px 40px 1fr; align-items: start; }
.timeline-date {
  text-align: right;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--c-primary);
  padding-top: 0.25rem;
  padding-right: 1rem;
}
.timeline-line-col { position: relative; display: flex; justify-content: center; height: 100%; }
.timeline-line-col::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0; left: 50%;
  width: 2px; margin-left: -1px;
  background-color: var(--c-border);
}
.timeline-row:last-child .timeline-line-col::before { bottom: auto; height: 1rem; }
.timeline-marker {
  width: 16px; height: 16px;
  background-color: #fff;
  border: 3px solid var(--c-border);
  border-radius: 50%;
  position: relative; z-index: 1;
  margin-top: 0.25rem;
}
.timeline-content { padding-left: 1rem; padding-bottom: 3rem; }
.timeline-row:last-child .timeline-content { padding-bottom: 0; }
.timeline-content h4 {
  font-family: var(--font-sans);
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--c-text-main);
}
.timeline-content p { font-size: 0.9375rem; color: var(--c-text-muted); }
.timeline-row.active .timeline-date { color: var(--c-accent); }
.timeline-row.active .timeline-marker {
  background-color: var(--c-accent);
  border-color: var(--c-accent);
  box-shadow: 0 0 0 4px rgba(197, 48, 48, 0.2);
  animation: pulse-red 2s infinite;
}
.timeline-note {
  margin-top: 3rem;
  padding: 1.25rem 1.5rem;
  background-color: var(--c-bg-contrast);
  border-left: 4px solid var(--c-accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.9rem;
  color: var(--c-text-main);
  font-style: italic;
  line-height: 1.6;
}

/* ============================================================
   РАСПИСАНИЕ — УНИКАЛЬНЫЙ ДИЗАЙН «КАРТОЧКИ В ДНЕ» v9.6
   ============================================================ */

/* --- Заголовок блока (Консультации / Экзамены) --- */
.schedule-block-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--c-primary);
  margin-bottom: 2rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--c-border);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.schedule-block-title svg {
  color: var(--c-accent);
  flex-shrink: 0;
}

/* --- Секция-обёртка --- */
.schedule-section {
  margin-bottom: 3.5rem;
}
.schedule-section:last-child {
  margin-bottom: 0;
}

/* --- Контейнер табов --- */
.schedule-tabs-container {
  background-color: var(--c-bg-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.02);
}

/* --- Навигация табов (улучшена для длинных названий) --- */
.schedule-nav-wrapper {
  position: relative;
  border-bottom: 1px solid var(--c-border);
  background-color: var(--c-bg-contrast);
}
.schedule-nav-wrapper::before,
.schedule-nav-wrapper::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0; z-index: 2;
  width: 28px; pointer-events: none;
}
.schedule-nav-wrapper::before {
  left: 0;
  background: linear-gradient(to right, var(--c-bg-contrast) 0%, transparent 100%);
}
.schedule-nav-wrapper::after {
  right: 0;
  background: linear-gradient(to left, var(--c-bg-contrast) 0%, transparent 100%);
}
.schedule-nav {
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 0.5rem 0.5rem 0 0.5rem;
  margin: 0;
}
.schedule-nav::-webkit-scrollbar { display: none; }

/* Таб – улучшен для длинных названий */
.tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.2rem;
  min-width: 110px;
  max-width: 180px;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--c-text-muted);
  flex-shrink: 0;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  gap: 0.25rem;
  margin-right: 0.25rem;
  border-radius: 8px 8px 0 0;
  word-break: break-word;
  hyphens: auto;
}
.tab-btn:hover {
  background-color: rgba(255,255,255,0.6);
  color: var(--c-primary);
}
.tab-btn.active {
  background-color: var(--c-bg-surface);
  color: var(--c-primary);
  border-bottom-color: var(--c-accent);
  font-weight: 600;
  box-shadow: 0 -2px 6px rgba(0,0,0,0.03);
}
.tab-code {
  font-size: 0.68rem;
  font-weight: 700;
  opacity: 0.55;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1;
}
.tab-title {
  font-size: 0.8rem;
  line-height: 1.25;
  text-align: center;
  max-width: 160px;
  overflow-wrap: break-word;
}

/* --- Тело панелей --- */
.schedule-body {
  padding: 2rem 2.5rem;
  min-height: 120px;
  background-color: var(--c-bg-surface);
}

/* --- Анимация панелей --- */
.tab-pane {
  display: none;
  animation: fadeIn 0.25s ease-in-out;
}
.tab-pane.active {
  display: block;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   СУБ-ТАБЫ (ПОДВКЛАДКИ) ДЛЯ ПОДГРУПП
   ============================================================ */
.schedule-subtabs-container {
  margin-top: 0.5rem;
}

/* Навигация суб-табов */
.schedule-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--c-border);
  padding-bottom: 0.5rem;
}

.subtab-btn {
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid var(--c-border);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--c-text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}
.subtab-btn:hover {
  background-color: var(--c-bg-contrast);
  color: var(--c-primary);
  border-color: #cbd5e0;
}
.subtab-btn.active {
  background-color: var(--c-primary);
  color: #fff;
  border-color: var(--c-primary);
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(26, 54, 93, 0.2);
}

/* Панели суб-табов */
.subtab-pane {
  display: none;
  animation: fadeIn 0.2s ease;
}
.subtab-pane.active {
  display: block;
}

/* Тело суб-панели (наследует стили от основного расписания) */

/* ============================================================
   ТАБЛИЦА-КАРТОЧКИ ВНУТРИ ДНЕЙ
   ============================================================ */

/* Группа по дате */
.schedule-day-group {
  margin-bottom: 2rem;
}
.schedule-day-group:last-child {
  margin-bottom: 0;
}

/* Заголовок дня */
.schedule-day-header {
  display: flex;
  align-items: baseline;
  gap: 0.8rem;
  margin-bottom: 0.75rem;
}
.schedule-day-date {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--c-primary);
  background: var(--c-bg-contrast);
  padding: 0.25em 0.75em;
  border-radius: 6px;
  line-height: 1.4;
}
.schedule-day-weekday {
  font-size: 0.8rem;
  color: var(--c-text-muted);
  font-weight: 500;
}

/* Контейнер таблицы */
.table-responsive {
  overflow-x: visible;
}

.schedule-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 0.6rem;
  margin-top: -0.3rem;
}

.schedule-table thead {
  display: none;
}

/* Каждая строка – карточка */
.schedule-table tbody tr {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  background: var(--c-bg-surface);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-card);
  padding: 1rem 1.25rem;
  margin-bottom: 0.5rem;
  transition: box-shadow var(--transition-fast), transform var(--transition-fast);
  border-left: 4px solid transparent;
  position: relative;
}
.schedule-table tbody tr:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-1px);
  border-left-color: var(--c-accent);
  background-color: #fff;
}

/* Ячейки внутри карточки */
.schedule-table td {
  border: none;
  padding: 0.25rem 0.8rem;
  vertical-align: middle;
  display: flex;
  align-items: center;
}

/* Колонка: время */
.cell-time {
  font-weight: 700;
  color: var(--c-primary);
  font-size: 0.9rem;
  min-width: 80px;
  justify-content: center;
  text-align: center;
  background: var(--c-bg-contrast);
  border-radius: 6px;
  padding: 0.3em 0.8em;
  margin-right: 1rem;
  white-space: nowrap;
}

/* Дисциплина (основной текст) */
.cell-subject {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--c-text-main);
  flex: 2;
  min-width: 180px;
  line-height: 1.4;
}

/* Преподаватель */
.cell-teacher {
  color: var(--c-text-muted);
  font-size: 0.8rem;
  flex: 1;
  min-width: 140px;
  justify-content: flex-start;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-right: 1rem;
  padding-left: 0.5rem;
}

/* Аудитория */
.cell-room {
  color: var(--c-text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  min-width: 70px;
  justify-content: flex-end;
  text-align: right;
  background: var(--c-bg-contrast);
  border-radius: 6px;
  padding: 0.3em 0.8em;
  white-space: nowrap;
}

/* Убираем границу у последней строки */
.schedule-table tbody tr:last-child {
  margin-bottom: 0;
}

/* ============================================================
   АДАПТИВ: ПЛАНШЕТЫ (РАСПИСАНИЕ)
   ============================================================ */
@media (max-width: 1023px) {
  .schedule-body {
    padding: 1.5rem;
  }
  .schedule-block-title {
    font-size: 1.35rem;
    margin-bottom: 1.5rem;
  }
  .schedule-section {
    margin-bottom: 3rem;
  }
  .tab-btn {
    min-width: 100px;
    max-width: 160px;
  }
  .schedule-table td {
    padding: 0.25rem 0.5rem;
  }
}

/* ============================================================
   АДАПТИВ: МОБИЛЬНЫЕ (РАСПИСАНИЕ)
   ============================================================ */
@media (max-width: 767px) {
  .schedule-body {
    padding: 1rem;
  }

  .schedule-block-title {
    font-size: 1.2rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    gap: 0.5rem;
  }
  .schedule-block-title svg {
    width: 18px;
    height: 18px;
  }
  .schedule-section {
    margin-bottom: 2.5rem;
  }

  /* Табы */
  .tab-btn {
    padding: 0.65rem 0.85rem;
    min-width: 80px;
    font-size: 0.72rem;
  }
  .tab-code {
    font-size: 0.62rem;
  }
  .tab-title {
    font-size: 0.72rem;
  }

  /* Суб-табы */
  .schedule-subnav {
    gap: 0.35rem;
    margin-bottom: 1rem;
    padding-bottom: 0.35rem;
  }
  .subtab-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.72rem;
  }

  /* Группировка по дням */
  .schedule-day-group {
    margin-bottom: 1.5rem;
  }
  .schedule-day-header {
    padding-left: 0;
    flex-direction: column;
    gap: 0.1rem;
    margin-bottom: 0.6rem;
    padding-bottom: 0.35rem;
  }
  .schedule-day-date {
    font-size: 0.95rem;
  }
  .schedule-day-weekday {
    font-size: 0.75rem;
  }

  /* Карточки-строки становятся вертикальными */
  .schedule-table tbody tr {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem;
    gap: 0.4rem;
    border-left: 4px solid var(--c-accent);
  }

  .cell-time {
    margin-right: 0;
    order: 1;
    background: none;
    padding: 0;
    font-size: 0.9rem;
    color: var(--c-primary);
    justify-content: flex-start;
  }
  .cell-subject {
    order: 2;
    font-size: 0.95rem;
    min-width: auto;
    flex: unset;
    width: 100%;
  }
  .cell-teacher {
    order: 3;
    margin-right: 0;
    font-size: 0.8rem;
    min-width: auto;
    flex: unset;
    width: 100%;
    background: none;
    padding: 0;
    white-space: normal;
  }
  .cell-room {
    order: 4;
    justify-content: flex-start;
    background: none;
    padding: 0;
    font-size: 0.8rem;
    width: 100%;
    text-align: left;
  }

  .cell-teacher::before {
    content: 'Преподаватель: ';
    font-weight: 400;
    color: var(--c-text-light);
    font-size: 0.7rem;
  }
  .cell-room::before {
    content: 'Аудитория: ';
    font-weight: 400;
    color: var(--c-text-light);
    font-size: 0.7rem;
  }
}

/* ---------- ИТОГИ КАМПАНИИ ---------- */
.results-header-group {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}
.update-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--c-text-muted);
  background-color: var(--c-bg-contrast);
  padding: 0.25rem 0.75rem;
  border-radius: 99px;
  margin-top: 0.5rem;
}
.dot {
  width: 8px;
  height: 8px;
  background-color: var(--c-text-muted);
  border-radius: 50%;
  display: inline-block;
}
.dot.live {
  width: 8px; height: 8px;
  background-color: var(--c-success);
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(56, 161, 105, 0.2);
}
.results-protocols-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}
.protocol-card {
  background-color: var(--c-bg-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-md);
  display: flex; flex-direction: column;
  position: relative; overflow: hidden;
  transition: all 0.3s ease;
}
.protocol-card--published:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--c-success);
}
.protocol-card--published { border-top: 4px solid var(--c-success); }
.protocol-card--published .card-bg-icon { color: var(--c-success); }
.protocol-card--pending { border-top: 4px solid var(--c-warning); background-color: #fffaf0; }
.protocol-card--pending .card-bg-icon { color: var(--c-warning); }
.protocol-card--locked { border-top: 4px solid var(--c-text-muted); opacity: 0.8; background-color: #f7fafc; }
.protocol-card--locked .card-bg-icon { color: var(--c-text-muted); }
.card-bg-icon {
  position: absolute;
  top: -10px; right: -10px;
  opacity: 0.05;
  transform: rotate(15deg) scale(5);
  pointer-events: none;
  transition: transform 0.5s ease;
}
.protocol-card:hover .card-bg-icon { transform: rotate(0deg) scale(5.5); }
.protocol-header { padding: 1.5rem 1.5rem 0; }
.protocol-status {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.75rem;
}
.status-badge {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-weight: 700; text-transform: uppercase;
  border-radius: 99px; padding: 0.25rem 0.6rem;
}
.status-badge.success { color: #1e4620; background-color: #d4edda; }
.status-badge.pending { color: #856404; background-color: #fff3cd; }
.status-badge.locked  { color: #383d41; background-color: #e2e3e5; }
.protocol-date { color: var(--c-text-muted); font-weight: 500; }
.protocol-body { flex-grow: 1; padding: 1rem 1.5rem; }
.protocol-title { font-family: var(--font-serif); font-size: 1.25rem; line-height: 1.3; color: var(--c-primary); margin-bottom: 0.5rem; }
.protocol-subtitle { font-family: var(--font-sans); font-size: 0.9rem; color: var(--c-text-muted); }
.protocol-footer { margin-top: auto; padding: 0 1.5rem 1.5rem; }
.btn-protocol {
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
  width: 100%; padding: 0.75rem;
  border-radius: var(--radius-sm);
  font-weight: 600; font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.2s;
  background-color: var(--c-primary);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-protocol:hover { background-color: var(--c-primary-light); transform: translateY(-2px); color: #fff; }
.btn-protocol.disabled {
  background-color: transparent;
  border: 1px dashed var(--c-border);
  color: var(--c-text-muted);
  cursor: not-allowed;
  box-shadow: none; transform: none;
}
.btn-protocol.disabled:hover { background-color: transparent; color: var(--c-text-muted); }

/* ---------- ПОДАЧА ДОКУМЕНТОВ ---------- */
.docs-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 3rem;
  align-items: start;
}
.docs-list-wrapper h3 { margin-bottom: 1.5rem; }
.check-list li {
  display: flex; align-items: flex-start; gap: 1rem;
  margin-bottom: 1.25rem; font-size: 1rem;
}
.check-list li svg { color: var(--c-accent); flex-shrink: 0; margin-top: 3px; width: 20px; height: 20px; }
.gosuslugi-promo {
  background: linear-gradient(135deg, #f1f5f9 0%, #e0e7ff 100%);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  text-align: center;
  border: 1px solid #dae1e7;
}
.gosuslugi-promo .promo-content h3 { font-family: var(--font-serif); font-size: 1.5rem; margin-bottom: 0.5rem; }
.gosuslugi-promo .btn-gosuslugi { width: 100%; margin-top: 1.5rem; }

/* ---------- БЛАНКИ И ФАЙЛЫ ---------- */
.downloads-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 1.5rem;
}
.doc-card {
  display: flex; align-items: center;
  background-color: var(--c-bg-surface);
  padding: 1.25rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  position: relative;
  transition: all var(--transition-base);
}
.doc-card:hover {
  border-color: var(--c-accent);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}
.doc-icon {
  flex-shrink: 0;
  width: 48px; height: 48px;
  background-color: rgba(197, 48, 48, 0.1);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  margin-right: 1rem;
  color: var(--c-accent);
  transition: background-color 0.2s, color 0.2s;
}
.doc-card:hover .doc-icon { background-color: var(--c-accent); color: #fff; }
.doc-info { flex-grow: 1; overflow: hidden; }
.doc-title {
  font-family: var(--font-sans);
  font-size: 1rem; font-weight: 600;
  color: var(--c-text-main);
  margin-bottom: 0.25rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.doc-card:hover .doc-title { color: var(--c-accent); }
.doc-meta { display: flex; align-items: center; gap: 0.75rem; font-size: 0.75rem; color: var(--c-text-muted); }
.doc-type { font-weight: 700; text-transform: uppercase; background-color: var(--c-bg-contrast); padding: 2px 6px; border-radius: 4px; }
.doc-badge {
  position: absolute;
  top: -8px; right: -8px;
  width: 20px; height: 20px;
  background-color: var(--c-accent);
  color: #fff; font-size: 12px; font-weight: 700;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* ---------- КОНТАКТЫ ---------- */
.contacts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}
.contact-card {
  background-color: var(--c-bg-surface);
  padding: 1.5rem;
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  display: flex; flex-direction: column;
}
.contact-card.full-width { grid-column: 1 / -1; }
.cc-label {
  font-size: 0.75rem; text-transform: uppercase;
  font-weight: 700; color: var(--c-text-muted);
  margin-bottom: 0.5rem;
}
.cc-value { font-size: 1.125rem; font-weight: 600; color: var(--c-primary); word-break: break-word; }
.cc-value a:hover { color: var(--c-accent); }

/* ============================================================
   АДАПТИВНОСТЬ (ОБЩАЯ)
   ============================================================ */

@media (max-width: 1023px) {
  .layout-grid {
    grid-template-columns: 100%;
    gap: 2rem;
    margin-top: 2rem;
    margin-bottom: 3rem;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 999;
    margin-left: -1.5rem;
    margin-right: -1.5rem;
    width: calc(100% + 3rem);
  }
  .sticky-nav {
    border-radius: 0;
    border: none;
    border-bottom: 1px solid var(--c-border);
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    padding: 0.75rem 0;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
  }
  .nav-list {
    flex-direction: row;
    overflow-x: auto;
    padding: 0 1.5rem;
    gap: 0.75rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .nav-list::-webkit-scrollbar { display: none; }
  .nav-link {
    white-space: nowrap;
    padding: 0.5rem 1rem;
    background-color: #f1f5f9;
    border: 1px solid transparent;
    border-radius: 99px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--c-text-main);
    border-left: none;
  }
  .nav-link.active {
    background-color: var(--c-primary);
    color: #fff;
    border-color: var(--c-primary);
    box-shadow: 0 2px 4px rgba(26, 54, 93, 0.3);
    border-left: none;
  }
  .sidebar-widget { display: none; }
  .content-area { gap: 4rem; }

  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero-content { text-align: center; margin: 0 auto; }
  .hero-actions { justify-content: center; }
  .hero-card { margin: 0 auto; max-width: 400px; }

  .specialties-grid { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
  .docs-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

@media (max-width: 767px) {
  .container {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
    overflow-x: clip;
  }

  .hero-section { padding: 2.5rem 0 3.5rem; }
  .hero-title { font-size: 2rem; line-height: 1.15; }
  .hero-actions { flex-direction: column; width: 100%; }
  .hero-actions .btn { width: 100%; }
  .hero-badges { justify-content: center; }
  .hero-card {
    width: 100%;
    max-width: 100%;
    padding: 2rem 1.5rem;
    margin-left: 0;
  }
  .hero-card-body .date-big { font-size: 3.5rem; }

  .content-area { gap: 3.5rem; }
  .section-title { font-size: 1.75rem; margin-bottom: 1.5rem; text-align: left; }

  .rules-grid,
  .specialties-grid,
  .results-protocols-grid,
  .downloads-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .spec-card { box-shadow: 0 4px 6px rgba(0,0,0,0.05); }
  .spec-card__header { padding: 1rem; }
  .spec-name { font-size: 1.1rem; }
  .spec-stats-grid .stat-val { font-size: 1.25rem; }

  /* Таймлайн */
  .timeline-row { display: flex; gap: 1rem; }
  .timeline-date { display: none; }
  .timeline-line-col { min-width: 24px; flex-shrink: 0; }
  .timeline-content { padding-left: 0; padding-bottom: 2rem; }
  .timeline-content h4 { display: flex; flex-direction: column; font-size: 1.1rem; }
  .timeline-content h4::before {
    content: attr(data-date);
    display: block;
    font-size: 0.85rem;
    color: var(--c-accent);
    font-weight: 700;
    margin-bottom: 0.25rem;
    opacity: 0.9;
  }
  .timeline-note { margin-top: 2rem; padding: 1rem; font-size: 0.85rem; border-left-width: 3px; }

  /* Карточки документов */
  .doc-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem;
    gap: 0.75rem;
  }
  .doc-icon {
    width: 40px;
    height: 40px;
    margin-right: 0;
  }
  .doc-info {
    width: 100%;
    overflow: visible;
  }
  .doc-title {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
    line-height: 1.4;
  }
  .doc-meta { font-size: 0.75rem; }
  .doc-badge {
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    font-size: 10px;
  }

  /* Протоколы */
  .protocol-card { padding: 1.5rem; }
  .protocol-title { font-size: 1.1rem; }

  /* Контакты */
  .contact-card { padding: 1.25rem; }
  .cc-value { font-size: 1rem; }

  /* Госуслуги */
  .gosuslugi-promo { padding: 1.5rem; margin-top: 1rem; }
  .gosuslugi-promo .promo-content h3 { font-size: 1.25rem; }
}