/* ============================================
   OPPETOO PAGE - UNIFIED WITH KONTAKT DESIGN
   Matches kontakt.php design system exactly
   ============================================ */

/* ============================================
   GLOBAL RESET & BASE STYLES
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

:root {
    --primary-color: #2563eb;
    --secondary-color: #7c3aed;
    --accent-color: #f59e0b;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --text-muted: rgba(255, 255, 255, 0.8);
    --text-white: white;
    --bg-light: #f8fafc;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --accent-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --success-gradient: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --warning-gradient: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    --info-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --dark-bg: #0f0f23;
    --card-bg: rgba(255, 255, 255, 0.1);
    --border-glass: rgba(255, 255, 255, 0.2);
    --shadow-glow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    --shadow-intense: 0 25px 50px rgba(0, 0, 0, 0.3);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --text-primary: rgba(255, 255, 255, 0.9);
    --text-secondary: rgba(255, 255, 255, 0.7);
}

/* ============================================
   CONTAINER - MATCHES KONTAKT
   ============================================ */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* ============================================
   MAIN CONTENT
   ============================================ */

.main-content {
    padding:  0px 0;
}

/* Section Styles - Match kontakt sections */
section {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    margin-bottom: 30px;
    padding: 30px;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
    transform: translateY(20px);
    animation: slideUp 0.8s ease-out forwards;
    transition: all 0.3s ease;
}

section:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

section:nth-child(2) { animation-delay: 0.1s; }
section:nth-child(3) { animation-delay: 0.2s; }
section:nth-child(4) { animation-delay: 0.3s; }
section:nth-child(5) { animation-delay: 0.4s; }
section:nth-child(6) { animation-delay: 0.5s; }

/* ============================================
   TYPOGRAPHY - MATCHES KONTAKT
   ============================================ */

.schedule-header {
    text-align: center;
    margin-bottom: 40px;
    color: var(--white);
    text-transform: uppercase;
}

.schedule-title {
    font-weight: 750;
    font-size: 1.3rem;
    margin-left: 6px;
}

.section-title {
    color: var(--text-white);
    font-size: 1.8rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--primary-color);
    position: relative;
    text-align: center;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: var(--secondary-color);
    transition: width 0.3s ease;
}

section:hover .section-title::after {
    width: 100px;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-white);
    font-weight: 500;
    text-align: center;
}

/* ============================================
   GRID LAYOUTS - MATCHES KONTAKT
   ============================================ */

.schedule-grid,
.cards-grid,
.info-grid,
.exam-categories,
.staff-grid,
.consultation-list,
.projects-grid,
.main-grid,
.download-grid,
.process-grid,
.documents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* ============================================
   CARD STYLES - MATCHES KONTAKT
   ============================================ */

.info-card,
.download-card,
.schedule-card,
.exam-category,
.staff-card,
.consultation-item,
.project-card,
.category-card,
.process-card,
.document-card,
.teacher-card {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    text-align: center;
    /* Flexbox for equal height alignment */
    display: flex;
    flex-direction: column;
}

.info-card::before,
.download-card::before,
.schedule-card::before,
.exam-category::before,
.staff-card::before,
.consultation-item::before,
.project-card::before,
.category-card::before,
.process-card::before,
.document-card::before,
.teacher-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.5s;
}

.info-card:hover::before,
.download-card:hover::before,
.schedule-card:hover::before,
.exam-category:hover::before,
.staff-card:hover::before,
.consultation-item:hover::before,
.project-card:hover::before,
.category-card:hover::before,
.process-card:hover::before,
.document-card:hover::before,
.teacher-card:hover::before {
    left: 100%;
}

.info-card:hover,
.download-card:hover,
.schedule-card:hover,
.exam-category:hover,
.staff-card:hover,
.consultation-item:hover,
.project-card:hover,
.category-card:hover,
.process-card:hover,
.document-card:hover,
.teacher-card:hover {
    transform: translateY(-2.5px) scale(1.02);
    border-color: var(--primary-color);
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.3);
}

/* ============================================
   CARD CONTENT
   ============================================ */

.info-icon,
.download-icon,
.exam-icon,
.process-icon,
.card-icon,
.document-icon,
.contact-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    text-align: center;
    filter: drop-shadow(0 4px 8px rgba(102, 126, 234, 0.3));
}

.info-title,
.download-title,
.exam-title,
.card-title,
.process-title,
.document-title,
.project-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.75rem;
    text-align: center;
}

.info-description,
.download-subtitle,
.exam-description,
.card-subtitle,
.card-preview,
.process-description,
.project-description {
    color: #4a5568;
    font-size: 0.95rem;
    line-height: 1.6;
    text-align: center;
    flex-grow: 1; /* Allow content to grow and push badge to bottom */
}

/* ============================================
   STAFF SECTION
   ============================================ */

.staff-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.staff-tab {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    padding: 0.75rem 1.5rem;
    color: var(--text-primary);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.staff-tab:hover,
.staff-tab.active {
    background: var(--primary-gradient);
    color: white;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
}

.staff-content {
    display: none;
}

.staff-content.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

.staff-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}

.staff-name {
    font-size: 1.3rem;
    font-weight: bold;
    color: #2d3748;
    margin-bottom: 8px;
    text-align: center;
}

.staff-position {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 10px;
    text-align: center;
}

.staff-info,
.staff-room {
    background: var(--primary-gradient);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    display: inline-block;
    margin-top: 5px;
}

/* ============================================
   BUTTONS - MATCHES KONTAKT
   ============================================ */

.download-btn,
.catalog-link,
.facebook-link {
    background: var(--primary-gradient);
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    text-decoration: none;
    display: inline-block;
    margin-top: 1rem;
    text-align: center;
}

.info-button {
    background: var(--primary-gradient);
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    text-decoration: none;
    display: inline-block;
    /* Убираем margin-top или заменяем на margin: 0 */
    margin: 0;
    text-align: center;
    vertical-align: middle; /* Добавляем выравнивание */
}

.info-card {
    display: flex;
    flex-direction: column;

}

.info-description {
    flex-grow: 1;
}

.info-button {
    margin-top: auto;
}

.info-button::before,
.download-btn::before,
.catalog-link::before,
.facebook-link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.5s ease;
}

.info-button:hover::before,
.download-btn:hover::before,
.catalog-link:hover::before,
.facebook-link:hover::before {
    width: 300px;
    height: 300px;
}

.info-button:hover,
.download-btn:hover,
.catalog-link:hover,
.facebook-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.info-button:active,
.download-btn:active,
.catalog-link:active,
.facebook-link:active {
    transform: translateY(0);
}

.facebook-link {
    background: #1877f2;
    display: block;
    width: max-content; /* чтобы кнопка сжалась под текст */
    margin: 0 auto;
    border-radius: 22.5px;
}

.facebook-link:hover {
    background: #0e5bb8;
}

/* ============================================
   HIGHLIGHT BOXES
   ============================================ */

.contact-highlight,
.announcement {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border-left: 4px solid var(--primary-color);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.contact-highlight p,
.announcement p {
    color: var(--text-dark);
    margin: 0.5rem 0;
    line-height: 1.6;
}

.contact-highlight strong,
.announcement strong {
    color: var(--white);
    font-weight: 600;
}

/* ============================================
   INFO SECTIONS
   ============================================ */

.info-section,
.coordinator-section,
.mission-section,
.dance-section,
.contact-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    border: 1px solid var(--glass-border);
    margin-bottom: 30px;
    margin-top: 25px;
}

.info-section h2,
.general-info h2,
.coordinator-section h2,
.coordinator-title,
.mission-title,
.dance-title,
.contact-section h2 {
    color: var(--text-dark);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
}

.info-section p,
.general-info p,
.mission-text,
.dance-description,
.coordinator-info,
.contact-info {
    color: var(--text-light);
    line-height: 1.6;
    font-size: 1rem;
    text-align: center;
}

/* ============================================
   SCHEDULE TABLE - MATCHES KONTAKT
   ============================================ */

.schedule-wrapper {
    background: white;
    border-radius: 10px;
    padding: 20px;
    overflow-x: auto;
    box-shadow: var(--shadow-md);
}

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

.schedule-table thead tr {
    background: var(--primary-gradient);
}

.schedule-table th {
    color: white;
    padding: 15px;
    text-align: left;
    font-weight: 600;
    position: relative;
}

.schedule-table td {
    color: var(--text-light);
    padding: 12px 15px;
    border-bottom: 1px solid #e2e8f0;
    transition: background-color 0.3s ease;
}

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

.schedule-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.03);
}

/* ============================================
   STATS CONTAINER - MATCHES KONTAKT
   ============================================ */

/* .stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin: 40px 0;
} */

.stat-item {
    text-align: center;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 30px 20px;
    border: 1px solid var(--glass-border);
    cursor: pointer;
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: white;
    display: block;
    margin-bottom: 8px;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ============================================
   PROJECT/BADGE STYLES
   ============================================ */

.project-status,
.stats-badge {
    display: block;
    background: var(--primary-gradient);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 22.5px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-left: auto;
    margin-right: auto;
    margin-top: 10px; /* Push to bottom using flexbox */
    width: fit-content;
    align-self: center; /* Center horizontally within flex container */
}

.status-active {
    background: rgba(102, 126, 234, 0.2);
    color: var(--primary-color);
    border: 1px solid rgba(102, 126, 234, 0.3);
}

.status-planning {
    background: rgba(118, 75, 162, 0.2);
    color: var(--secondary-color);
    border: 1px solid rgba(118, 75, 162, 0.3);
}

.status-completed {
    background: rgba(147, 197, 253, 0.2);
    color: #3b82f6;
    border: 1px solid rgba(147, 197, 253, 0.3);
}

/* ============================================
   CONSULTATION SPECIFIC
   ============================================ */

.consultation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.consultation-subject {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2d3748;
}

.consultation-time {
    background: var(--primary-gradient);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    color: white;
    font-size: 0.9rem;
    font-weight: 500;
}

.consultation-teacher,
.consultation-location {
    color: #4a5568;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

/* ============================================
   SCHEDULE TIME/ACTIVITY
   ============================================ */

.schedule-time {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.schedule-activity {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.5rem;
}

.schedule-description {
    color: #4a5568;
    font-size: 0.95rem;
    text-align: center;
}

/* ============================================
   CATALOG SECTION
   ============================================ */

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

.catalog-description {
    font-size: 1.3rem;
    margin-bottom: 30px;
    color: #4a5568;
}

/* ============================================
   TEACHER/STAFF PHOTO
   ============================================ */

.teacher-photo {
    font-size: 5rem;
    margin-bottom: 1rem;
    text-align: center;
        display: flex;
    justify-content: center;
}

.teacher-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 0.5rem;
    text-align: center;
}

.teacher-name3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    text-align: center;
}

/* ============================================
   PROJECT IMAGE
   ============================================ */

.project-image {
    font-size: 4rem;
    text-align: center;
    margin-bottom: 1rem;
    filter: drop-shadow(0 4px 8px rgba(102, 126, 234, 0.3));
}

.project-content {
    text-align: left;
}

/* ============================================
   DOCUMENT HEADER
   ============================================ */

.document-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.document-card p {
    color: #4a5568;
    font-size: 0.95rem;
}

/* ============================================
   CONTACT INFO
   ============================================ */

.phone-number,
.email {
    font-weight: 600;
    color: var(--primary-color);
}

.email-link {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.email-link:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* ============================================
   FLOATING ELEMENTS (SUBTLE VERSION)
   ============================================ */

.kontakt-floating-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.kontakt-floating-element {
    position: absolute;
    background: var(--glass-bg);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.kontakt-floating-element:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.kontakt-floating-element:nth-child(2) {
    width: 60px;
    height: 60px;
    top: 60%;
    right: 10%;
    animation-delay: 2s;
}

.kontakt-floating-element:nth-child(3) {
    width: 40px;
    height: 40px;
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

/* ============================================
   MODAL LIST
   ============================================ */

.modal-list {
    margin: 20px 0;
    padding-left: 20px;
}

/* ============================================
   TEACHER MODAL SPECIFIC
   ============================================ */

.teacher-modal-avatar {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    color: white;
}

.teacher-modal-name {
    font-size: 1.8rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    font-weight: 700;
    text-align: center;
}

.teacher-modal-title {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-bottom: 1rem;
    text-align: center;
}

.teacher-modal-bio {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
}

.teacher-modal-bio h4 {
    color: var(--text-dark);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.teacher-modal-bio p {
    color: var(--text-light);
    line-height: 1.6;
}

.schedule-modal-footer {
    background: var(--primary-gradient);
    color: white;
    padding: 2rem;
    border-radius: 12px;
    margin-top: 2rem;
    text-align: center;
}

.schedule-modal-footer h4 {
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.schedule-modal-footer p {
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* ============================================
   EXAM GRID & ITEMS
   ============================================ */

.exam-grid {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.exam-item,
.level-item {
    background: rgba(102, 126, 234, 0.05);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
        border-left: 4px solid #4facfe;
}

.exam-item:hover,
.level-item:hover {
    background: rgba(102, 126, 234, 0.08);
    transform: translateY(-2px);
}

.exam-subject,
.level-subject {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.75rem;
}

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

.exam-type,
.level-type {
    color: #4a5568;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.exam-date,
.level-date {
    color: #667eea;
    font-size: 0.95rem;
    font-weight: 500;
}

/* ============================================
   MODAL SECTIONS
   ============================================ */

.modal-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
}

.modal-section:last-child {
    border-bottom: none;
}

.modal-section h3 {
    color: #2d3748;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.modal-info {
    margin-bottom: 1.5rem;
}

.modal-info h3 {
    color: var(--primary-color);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.modal-info p {
    color: var(--text-light);
    line-height: 1.6;
}

/* ============================================
   MODAL WINDOW STYLES (FIXED HEIGHT WITH SCROLL)
   ============================================ */

/* Modal overlay - prevents background scrolling */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(5px);
}

/* When modal is shown, use flexbox for proper centering */
.modal[style*="display: block"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Modal content container */
.modal-content {
    background: white;
    border-radius: 20px;
    /* max-width now controlled by CSS variable in modals.css */
    width: 90%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-intense);
    animation: modalSlideIn 0.3s ease-out;
    position: relative;
}

/* Modal header - fixed at top */
.modal-header {
    padding: 30px 30px 20px 30px;
    border-bottom: 2px solid #e2e8f0;
    flex-shrink: 0; /* Prevent header from shrinking */
}

/* Close button */
.close {
    color: var(--primary-color);
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 8px;
    border-radius: 8px;
    line-height: 1;
    z-index: 10;
}

.close:hover {
    color: var(--secondary-color);
    background: rgba(102, 126, 234, 0.1);
    transform: scale(1.1);
}

/* Modal body - scrollable content */
.modal-body {
    padding: 20px 30px 30px 30px;
    overflow-y: auto; /* Enable vertical scrolling */
    overflow-x: hidden;
    flex: 1; /* Take remaining space */
    max-height: calc(85vh - 100px); /* Account for header */
}

/* Custom scrollbar for modal */
.modal-body::-webkit-scrollbar {
    width: 10px;
}

.modal-body::-webkit-scrollbar-track {
    background: rgba(102, 126, 234, 0.05);
    border-radius: 10px;
    margin: 10px 0;
}

.modal-body::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 10px;
    transition: background 0.3s ease;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #7c8ef0, #8a5bb2);
}

/* Prevent body scroll when modal is open */
body.modal-open {
    overflow: hidden;
    background: var(--primary-gradient) !important;
    background-attachment: fixed !important;
}


/* Modal title styles */
.modal h2 {
    color: var(--text-dark);
    font-size: 1.7rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.modal h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    font-weight: 600;
    margin-top: 25px;
    margin-bottom: 15px;
}

.modal p {
    color: var(--text-dark);
    line-height: 1.8;
    margin-bottom: 15px;
}

.modal ul,
.modal ol {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 15px;
    padding-left: 25px;
}

.modal li {
    margin-bottom: 8px;
}

/* ============================================
   SCROLL INDICATOR (OPTIONAL)
   ============================================ */

.kontakt-scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 1000;
}

.kontakt-scroll-progress {
    height: 100%;
    background: linear-gradient(45deg, #FF6B6B, #4ECDC4);
    width: 0%;
    transition: width 0.3s ease;
}

/* ============================================
   CUSTOM SCROLLBARS
   ============================================ */

.schedule-wrapper::-webkit-scrollbar {
    height: 8px;
    width: 8px;
}

.schedule-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.schedule-wrapper::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 4px;
}

.schedule-wrapper::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #7c8ef0, #8a5bb2);
}

/* ============================================
   FOCUS STATES (ACCESSIBILITY)
   ============================================ */

.info-card:focus-visible,
.download-card:focus-visible,
.schedule-card:focus-visible,
.exam-category:focus-visible,
.staff-card:focus-visible,
.consultation-item:focus-visible,
.project-card:focus-visible,
.category-card:focus-visible,
.process-card:focus-visible,
.document-card:focus-visible,
.teacher-card:focus-visible {
    outline: 3px solid rgba(102, 126, 234, 0.6);
    outline-offset: 2px;
}

.staff-tab:focus-visible,
.info-button:focus-visible,
.facebook-link:focus-visible,
.catalog-link:focus-visible,
.download-btn:focus-visible {
    outline: 3px solid rgba(102, 126, 234, 0.8);
    outline-offset: 2px;
}

.downloads-grid {
    display: grid;
       grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

/* ============================================
   ANIMATIONS - MATCHES KONTAKT
   ============================================ */

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
    }
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.8);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ============================================
   RESPONSIVE DESIGN - MATCHES KONTAKT
   ============================================ */

@media (max-width: 992px) {
    .schedule-grid,
    .download-grid,
    .cards-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 1.5rem;
    }

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

    .section-subtitle {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    .main-content {
        padding: 20px 0;
    }

    section {
        padding: 20px;
    }

    .schedule-grid,
    .download-grid,
    .cards-grid,
    .info-grid,
    .exam-categories,
    .staff-grid,
    .consultation-list,
    .projects-grid,
    .main-grid,
    .process-grid,
    .documents-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .info-card,
    .download-card,
    .schedule-card {
        padding: 1.5rem;
    }

    .info-icon,
    .download-icon {
        font-size: 2.5rem;
    }

    .info-title,
    .download-title {
        font-size: 1.1rem;
    }

    .schedule-header {
        padding: 1.5rem;
    }

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

    .schedule-table th,
    .schedule-table td {
        padding: 0.75rem 0.5rem;
    }

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

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

    /* Modal responsive - tablet */
    .modal-content {
        width: 95%;
        max-width: 95vw;
        margin: 3% auto;
        max-height: 90vh;
    }

    .modal-header {
        padding: 25px 25px 15px 25px;
    }

    .modal-body {
        padding: 15px 25px 25px 25px;
    }

    .close {
        font-size: 26px;
        right: 15px;
        top: 15px;
        padding: 6px;
    }

    .modal h2 {
        font-size: 1.5rem;
    }

    .modal h3 {
        font-size: 1.2rem;
    }
}

@media (max-width: 576px) {
    .schedule-table {
        width: 100%;
        font-size: 0.9rem;
        border-collapse: collapse;
    }

    .schedule-table thead {
        display: none;
    }

    .schedule-table tbody,
    .schedule-table tr,
    .schedule-table td {
        display: block;
        width: 100%;
    }

    .schedule-table tr {
        margin-bottom: 20px;
        background: white;
        border-radius: 12px;
        padding: 15px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
        border: 1px solid #eaeaea;
    }

    .schedule-table td {
        text-align: center;
        padding: 12px 0;
        border: none;
        display: flex;
        align-items: center;
        border-bottom: 1px solid #f0f0f0;
        position: relative;
        justify-content: center;
    }

    .schedule-table td:last-child {
        border-bottom: none;
    }

    .schedule-table td::before {
        content: attr(data-label);
        position: absolute;
        left: 0;
        width: 110px;
        font-weight: 600;
        color: #667eea;
        font-size: 0.85rem;
    }

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

    /* Modal responsive - mobile */
    .modal-content {
        width: 98%;
        margin: 2% auto;
        max-height: 93vh;
        border-radius: 16px;
    }

    .modal-header {
        padding: 20px 20px 15px 20px;
    }

    .modal-body {
        padding: 15px 20px 20px 20px;

    }

    .close {
        font-size: 24px;
        right: 12px;
        top: 12px;
        padding: 5px;
    }

    .modal h2 {
        font-size: 1.3rem;
        margin-bottom: 15px;
    }

    .modal h3 {
        font-size: 1.1rem;
        margin-top: 20px;
    }

    .modal-body::-webkit-scrollbar {
        width: 6px;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.5rem;
    }

    .section-subtitle {
        font-size: 0.9rem;
    }

    .info-card,
    .download-card,
    .schedule-card {
        padding: 1.25rem;
    }

    .info-icon,
    .download-icon {
        font-size: 2rem;
    }

    .contact-highlight,
    .announcement {
        padding: 1rem;
    }

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

    /* Modal responsive - small mobile */
    .modal-content {
        width: 100%;
        margin: 1% auto;
        max-height: 95vh;
        border-radius: 12px;
    }

    .modal-header {
        padding: 18px 18px 12px 18px;

    }

    .modal-body {
        padding: 12px 18px 18px 18px;

    }

    .close {
        font-size: 22px;
        right: 10px;
        top: 10px;
        padding: 4px;
    }

    .modal h2 {
        font-size: 1.2rem;
        margin-bottom: 12px;
    }

    .modal h3 {
        font-size: 1rem;
        margin-top: 18px;
        margin-bottom: 12px;
    }

    .modal p,
    .modal li {
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .modal-body::-webkit-scrollbar {
        width: 5px;
    }
}

/* Extra Small Mobile (iPhone SE, small Android) */
@media (max-width: 374px) {
    .container {
        padding: 10px;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .schedule-grid,
    .download-grid,
    .cards-grid,
    .documents-grid,
    .level-item {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .schedule-card,
    .card,
    .info-item {
        padding: 1rem;
    }

    /* Improve touch targets */
    .btn,
    .close,
    button {
        min-height: 44px;
        min-width: 44px;
        padding: 0.75rem 1.5rem;
    }
}

/* ============================================
   ACCESSIBILITY - REDUCED MOTION
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================
   CSS for transferred blocks from index.php
   (Õpiabirühmad, Eelkool, Päevakava sections)
   ============================================ */

/* Schedule2 Section (Õpiabirühmad) */
.schedule2-section {
    margin: 4rem 0;
}

.schedule2-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    background: var(--secondary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: pulse 2s infinite;
}

.schedule2-grid {
    display: grid;
    /*grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); */
    gap: 3rem; 
}

.schedule2-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 25px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    animation: zoomIn 0.8s ease-out;
}

.schedule2-card:hover {
    transform: scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.schedule2-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-glass);
}

.schedule2-header h3 {
    color: white;
    font-size: 1.5rem;
    font-weight: 600;
}

.schedule2-table {
    width: 100%;
    border-collapse: collapse;
    color: white;
    font-weight: 600;
}

.schedule2-table th,
.schedule2-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.schedule2-table th {
    background: rgba(255, 255, 255, 0.1);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.schedule2-table tr:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(5px);
}

.teacher-name2 {
    color: var(--text-white);
    font-weight: 500;
}

/* Teachers Section (Eelkool) */
.teachers-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.teacher-card {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    animation: fadeInUp 1s ease-out;
}

.teacher-card:nth-child(2) {
    animation-delay: 0.2s;
}

.teacher-card:nth-child(3) {
    animation-delay: 0.4s;
}

.teacher-card:hover {
    transform: translateY(-2px);
    background: rgba(255,255,255,0.2);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}


.teacher-group {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.8);
    font-weight: 500;
}

/* Month Cards (Eelkool) */
.month-card {
    background: rgba(255,255,255,0.95);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    min-width: 0;
}

.month-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

.month-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 48px rgba(0,0,0,0.2);
}

.month-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.event-preview {
    font-size: 0.9rem;
    color: #718096;
    line-height: 1.4;
}

.fee-link {
    margin-top: 20px;
    display: inline-block;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    color: white;
    padding: 1rem 2rem;
    border-radius: 22.5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(238, 90, 36, 0.3);
}

.fee-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(238, 90, 36, 0.4);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .schedule2-grid {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 600px) {
    .schedule2-card {
        padding: 1rem;
        border-radius: 15px;
        font-size: 0.9rem;
        max-width: 100%;
        overflow-x: auto;
        white-space: nowrap;
    }

    .schedule2-card::-webkit-scrollbar {
        height: 6px;
    }

    .schedule2-card::-webkit-scrollbar-thumb {
        background-color: rgba(0,0,0,0.3);
        border-radius: 3px;
    }

    .schedule2-card::-webkit-scrollbar-track {
        background: transparent;
    }

    .schedule2-card {
        scrollbar-width: thin;
        scrollbar-color: rgba(0,0,0,0.3) transparent;
    }

    .schedule2-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

/* ============================================
   MODAL CONTENT STYLES - PÄEVAKAVA SECTION
   ============================================ */

/* Break Items (Koolivaheajad) */
.break-item {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border-left: 4px solid #667eea;
    padding: 20px;
    margin-bottom: 15px;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.break-item::before {
    content: '🌴';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2.5rem;
    opacity: 0.3;
}

.break-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15), rgba(118, 75, 162, 0.15));
}

/* Period Items (Õppeperioodid) */
.period-item {
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.1), rgba(0, 242, 254, 0.1));
    border-left: 4px solid #4facfe;
    padding: 20px;
    margin-bottom: 15px;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.period-item::before {
    content: '📚';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2.5rem;
    opacity: 0.3;
}

.period-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(79, 172, 254, 0.2);
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.15), rgba(0, 242, 254, 0.15));
}

/* Class Times (Tundide ajad) */
.class-time {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(251, 191, 36, 0.1));
    border-left: 4px solid #f59e0b;
    padding: 15px 20px;
    margin-bottom: 12px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.class-time:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.2);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(251, 191, 36, 0.15));
}

/* Lunch Groups (Söögivahetunnid) */
.lunch-group {
    background: linear-gradient(135deg, rgba(67, 233, 123, 0.1), rgba(56, 249, 215, 0.1));
    border-left: 4px solid #43e97b;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.lunch-group:hover {
    box-shadow: 0 4px 15px rgba(67, 233, 123, 0.2);
    background: linear-gradient(135deg, rgba(67, 233, 123, 0.15), rgba(56, 249, 215, 0.15));
}

/* Item Title */
.item-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Time Badge */
.time-badge {
    display: inline-block;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.95rem;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

.time-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Item Details */
.item-details {
    color: #6b7280;
    font-size: 0.9rem;
    margin-top: 8px;
    font-style: italic;
}

/* Class List */
.class-list {
    margin-top: 15px;
}

.class-list h4 {
    color: #374151;
    font-size: 0.95rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.classes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* Class Badge */
.class-badge {
    display: inline-block;
    background: linear-gradient(135deg, #f093fb, #f5576c);
    color: white;
    padding: 6px 14px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(240, 147, 251, 0.3);
    transition: all 0.3s ease;
}

.class-badge:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 4px 10px rgba(240, 147, 251, 0.5);
}

/* Modal Body Enhancements */
.modal-body {
    padding: 25px 30px;
}

.modal-body > :first-child {
    margin-top: 0;
}

.modal-body > :last-child {
    margin-bottom: 0;
}

/* Enhanced Modal Header */
.modal-header {
    padding-bottom: 20px;
}



/* Modal Section Dividers */
.modal-section {
    padding: 20px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.modal-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

/* ============================================
   EVENT ITEMS - EELKOOL MODAL CONTENT
   ============================================ */

/* Event Item Container */
.event-item {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(248, 249, 250, 0.95));
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border-left: 5px solid #667eea;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

/* Gradient overlay effect on hover */
.event-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.6s ease;
    pointer-events: none;
}

.event-item:hover::before {
    left: 100%;
}

/* Hover effect */
.event-item:hover {
    transform: translateX(8px) translateY(-4px);
    box-shadow: 0 12px 28px rgba(102, 126, 234, 0.25);
    border-left-color: #764ba2;
}

/* Event Date */
.event-date {
    font-size: 1.1rem;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 12px;
    display: inline-block;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.15), rgba(118, 75, 162, 0.15));
    padding: 8px 18px;
    border-radius: 25px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

/* Event Time */
.event-time {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.event-time::before {
    content: '🕐';
    font-size: 1.2rem;
    filter: grayscale(0.3);
}

/* Event Subject */
.event-subject {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.event-subject::before {
    content: '📖';
    font-size: 1.3rem;
}

/* Event Teacher */
.event-teacher {
    font-size: 1rem;
    font-weight: 500;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(102, 126, 234, 0.15);
    margin-top: 8px;
}

.event-teacher::before {
    content: '👨‍🏫';
    font-size: 1.1rem;
}

/* Special Event Styles (like LÕPUPIDU) */
.event-item[style*="linear-gradient"] {
    border-left-color: #ff6b6b;
    animation: pulse-glow 2s infinite;
}

.event-item[style*="linear-gradient"] .event-date,
.event-item[style*="linear-gradient"] .event-time,
.event-item[style*="linear-gradient"] .event-subject,
.event-item[style*="linear-gradient"] .event-teacher {
    color: white !important;
}

.event-item[style*="linear-gradient"] .event-date {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
}

.event-item[style*="linear-gradient"] .event-teacher {
    border-top-color: rgba(255, 255, 255, 0.3);
}

/* Empty state for "No events scheduled" */
.event-item .event-date:only-child {
    margin: 0;
    padding: 30px;
    text-align: center;
    background: linear-gradient(135deg, rgba(107, 114, 128, 0.1), rgba(156, 163, 175, 0.1));
    border-radius: 12px;
    color: #9ca3af;
    font-style: italic;
    font-weight: 500;
    font-size: 1rem;
    box-shadow: none;
}

/* Animation for special events */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3), 0 0 20px rgba(238, 90, 36, 0.2);
    }
    50% {
        box-shadow: 0 8px 25px rgba(255, 107, 107, 0.5), 0 0 35px rgba(238, 90, 36, 0.4);
    }
}

/* Different color schemes for variety */
.event-item:nth-child(4n+1) {
    border-left-color: #667eea;
}

.event-item:nth-child(4n+2) {
    border-left-color: #4facfe;
}

.event-item:nth-child(4n+3) {
    border-left-color: #43e97b;
}

.event-item:nth-child(4n+4) {
    border-left-color: #f093fb;
}

.event-item:nth-child(4n+1):hover {
    border-left-color: #764ba2;
}

.event-item:nth-child(4n+2):hover {
    border-left-color: #00f2fe;
}

.event-item:nth-child(4n+3):hover {
    border-left-color: #38f9d7;
}

.event-item:nth-child(4n+4):hover {
    border-left-color: #f5576c;
}

/* Update date colors based on variant */
.event-item:nth-child(4n+1) .event-date {
    color: #667eea;
}

.event-item:nth-child(4n+2) .event-date {
    color: #4facfe;
}

.event-item:nth-child(4n+3) .event-date {
    color: #43e97b;
}

.event-item:nth-child(4n+4) .event-date {
    color: #f093fb;
}

/* Responsive Design for Modal Content */
@media (max-width: 768px) {
    .class-time {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .break-item::before,
    .period-item::before {
        display: none;
    }

    .time-badge {
        font-size: 0.85rem;
        padding: 6px 12px;
    }

    .class-badge {
        font-size: 0.8rem;
        padding: 5px 12px;
    }

    /* Event Items Mobile Responsive */
    .event-item {
        padding: 18px;
        margin-bottom: 16px;
    }

    .event-date {
        font-size: 1rem;
        padding: 6px 14px;
    }

    .event-time {
        font-size: 0.95rem;
    }

    .event-subject {
        font-size: 1.1rem;
    }

    .event-teacher {
        font-size: 0.95rem;
    }

    .event-item:hover {
        transform: translateX(4px) translateY(-2px);
    }
}
