/**
 * ZEP-RE Academy Courses Page Styles
 *
 * Styles for the courses listing page including filters, course cards,
 * pagination, training calendar, and shared navigation/footer components.
 */

/* Hide breadcrumb and reset page wrapper spacing for seamless banner. */
.rui-breadcrumbs,
#page-header {
    display: none !important;
}

#page-content {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

#region-main {
    padding-top: 0 !important;
}

/* Center the navigation menu in the header. */
nav.navbar {
    justify-content: space-between !important;
}

.primary-navigation {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
}

.primary-navigation .navigation {
    justify-content: center !important;
}

#usernavigation {
    margin-left: 0 !important;
}

/* Navigation styles matching landing page. */
.primary-navigation .navigation .nav-link {
    padding: 9px 15px;
    margin: 0 .15rem;
    min-height: 40px;
    font-weight: 500;
    color: #212121 !important;
    border: none;
    border-radius: 5px;
}

.primary-navigation .navigation .nav-link:hover,
.primary-navigation .navigation .nav-link:focus {
    color: #0ea5e9 !important;
    background-color: rgba(14, 165, 233, 0.1);
}

.rui-topbar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    width: max-content;
    min-height: 40px;
    border: none;
    border-radius: 5px;
    font-size: .75rem;
    font-weight: 500;
    background-color: #EEE !important;
    color: #212121 !important;
}

.rui-topbar-btn:hover,
.rui-topbar-btn:focus {
    background-color: #DDD !important;
    color: #212121 !important;
}

.rui-login-btn {
    background-color: #ba9607 !important;
    color: white !important;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
}

/* Page Hero Banner */
.page-hero {
    position: relative;
    width: 100vw;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 100%);
    padding: 32px 20px;
    text-align: center;
    margin-top: -24px;
}

.page-hero h1 {
    color: white;
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.page-hero p {
    color: #94a3b8;
    font-size: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Filter Tabs */
.filter-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 20px 0;
}

.filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    background: white;
    padding: 8px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.filter-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #64748b;
    text-decoration: none;
    transition: all 0.2s ease;
    border: none;
    background: transparent;
}

.filter-tab:hover {
    color: #1e293b;
    background: #f1f5f9;
}

.filter-tab.active {
    color: white;
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
}

.filter-tab .count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

.filter-tab:not(.active) .count {
    background: #e2e8f0;
    color: #64748b;
}

.filter-tab.active .count {
    background: rgba(255,255,255,0.2);
    color: white;
}

/* Courses Section */
.courses-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 20px 48px;
}

.courses-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.courses-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.courses-count {
    font-size: 0.9rem;
    color: #64748b;
}

.no-courses-message {
    text-align: center;
    padding: 80px 20px;
    color: #64748b;
    font-size: 1.1rem;
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* Course Grid */
.course-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.course-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s ease;
    border: 1px solid #f1f5f9;
}

.course-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.course-card-image {
    height: 160px;
    background-size: cover;
    background-position: center;
    background-color: #e2e8f0;
}

.course-card-body {
    padding: 16px;
}

.course-card-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 12px;
    line-height: 1.4;
    min-height: 42px;
}

.course-card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.course-card-title a:hover {
    color: #0ea5e9;
}

.course-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid #f1f5f9;
}

.course-card-price {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
}

.course-card-price--paid {
    color: #0ea5e9;
}

.course-card-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: #0ea5e9;
    background: #e0f2fe;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.2s ease;
}

.course-card-btn:hover {
    background: #0ea5e9;
    color: white;
}

.course-card-btn svg {
    width: 18px;
    height: 18px;
}

/* Pagination */
.pagination-section {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #64748b;
    background: white;
    border: 1px solid #e2e8f0;
    text-decoration: none;
    transition: all 0.2s ease;
}

.pagination-btn:hover {
    color: #0ea5e9;
    border-color: #0ea5e9;
    background: #f0f9ff;
}

.pagination-btn.active {
    color: white;
    background: #0ea5e9;
    border-color: #0ea5e9;
}

.pagination-btn.disabled {
    opacity: 0.5;
    pointer-events: none;
}

.pagination-btn svg {
    width: 18px;
    height: 18px;
}

/* Training Calendar Section */
.calendar-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 48px;
}

.calendar-card {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 1px solid #fbbf24;
    border-radius: 16px;
    padding: 32px;
}

.calendar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.calendar-header svg {
    width: 28px;
    height: 28px;
    color: #d97706;
}

.calendar-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #92400e;
    margin: 0;
    flex: 1;
}

.calendar-view-all-link {
    font-size: 0.875rem;
    font-weight: 500;
    color: #92400e;
    text-decoration: none;
    transition: color 0.2s ease;
}

.calendar-view-all-link:hover {
    color: #d97706;
}

.calendar-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.calendar-item {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: white;
    border-radius: 10px;
    transition: transform 0.2s ease;
    overflow: hidden;
    max-width: 100%;
}

.calendar-item:hover {
    transform: translateY(-2px);
}

.calendar-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 56px;
    width: 56px;
    flex-shrink: 0;
    height: 56px;
    background: #fef3c7;
    border-radius: 8px;
}

.calendar-date .month {
    font-size: 0.7rem;
    font-weight: 600;
    color: #d97706;
    text-transform: uppercase;
}

.calendar-date .day {
    font-size: 1.25rem;
    font-weight: 700;
    color: #92400e;
    line-height: 1;
}

.calendar-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.calendar-info h4 {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 4px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.3;
    max-height: 2.6em;
}

.calendar-info a {
    color: inherit;
    text-decoration: none;
    display: block;
}

.calendar-info a:hover {
    color: #0ea5e9;
}

.calendar-info p {
    font-size: 0.75rem;
    color: #64748b;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.calendar-empty {
    text-align: center;
    padding: 24px;
    color: #78716c;
    font-size: 0.95rem;
}

/* Footer */
.modern-footer {
    position: relative;
    width: 100vw;
    left: 50%;
    transform: translateX(-50%);
    background: #1e293b;
    color: white;
    padding: 30px 20px 20px;
    margin-top: 24px;
    margin-bottom: -100px;
    padding-bottom: 50px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.footer-block h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #0ea5e9;
    margin-bottom: 12px;
}

.footer-block p {
    font-size: 0.85rem;
    color: #94a3b8;
    line-height: 1.5;
    margin-bottom: 8px;
}

.footer-block ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-block ul li {
    margin-bottom: 8px;
}

.footer-block ul li a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-block ul li a:hover {
    color: #0ea5e9;
}

.footer-block i {
    color: #0ea5e9;
    margin-right: 8px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 24px auto 0;
    padding-top: 16px;
    border-top: 1px solid #334155;
    text-align: center;
    color: #64748b;
    font-size: 0.85rem;
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
    .course-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .calendar-list {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
    .page-hero h1 {
        font-size: 1.5rem;
    }

    .page-hero {
        padding: 24px 16px;
    }

    .filter-tabs {
        flex-direction: column;
    }

    .filter-tab {
        width: 100%;
        justify-content: space-between;
    }

    .course-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .calendar-list {
        grid-template-columns: 1fr;
    }

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

/* Responsive - Small Mobile */
@media (max-width: 480px) {
    .course-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Interactive Training Calendar
   ============================================ */

.training-calendar {
    position: relative;
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    overflow: hidden;
}

/* Calendar Toolbar */
.calendar-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 16px 20px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.calendar-nav-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.calendar-nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-nav-btn:hover {
    color: #0ea5e9;
    border-color: #0ea5e9;
    background: #f0f9ff;
}

.calendar-nav-arrow {
    padding: 8px;
}

.calendar-nav-arrow svg {
    display: block;
}

.calendar-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-left: 8px;
}

.calendar-view-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.calendar-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #d97706;
    background: #fef3c7;
    border: 1px solid #fbbf24;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.calendar-download-btn:hover {
    background: #fde68a;
    color: #b45309;
}

.calendar-download-btn svg {
    flex-shrink: 0;
}

.calendar-toggle-group {
    display: flex;
    background: #e2e8f0;
    border-radius: 8px;
    padding: 4px;
}

.calendar-toggle-btn {
    padding: 8px 16px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-toggle-btn.active {
    color: white;
    background: #0ea5e9;
}

.calendar-view-buttons {
    display: flex;
    background: #e2e8f0;
    border-radius: 8px;
    padding: 4px;
}

.calendar-view-btn {
    padding: 8px 12px;
    font-size: 0.8rem;
    font-weight: 500;
    color: #64748b;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-view-btn:hover {
    color: #1e293b;
}

.calendar-view-btn.active {
    color: white;
    background: #0ea5e9;
}

/* Calendar Legend */
.calendar-legend {
    display: flex;
    justify-content: center;
    gap: 24px;
    padding: 12px 20px;
    background: #fafafa;
    border-bottom: 1px solid #f1f5f9;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: #64748b;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* Calendar Body */
.calendar-body {
    min-height: 400px;
    padding: 20px;
}

.calendar-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    gap: 16px;
    color: #64748b;
}

.calendar-loading .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e2e8f0;
    border-top-color: #0ea5e9;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.calendar-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    gap: 16px;
    color: #64748b;
    text-align: center;
}

.calendar-error svg {
    color: #f59e0b;
}

.calendar-retry-btn {
    padding: 10px 20px;
    font-size: 0.875rem;
    font-weight: 500;
    color: white;
    background: #0ea5e9;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.calendar-retry-btn:hover {
    background: #0284c7;
}

/* Day View */
.day-view {
    max-width: 800px;
    margin: 0 auto;
}

.day-header {
    text-align: center;
    padding: 24px;
    background: #f8fafc;
    border-radius: 12px;
    margin-bottom: 24px;
}

.day-header.is-today {
    background: linear-gradient(135deg, #dbeafe 0%, #e0f2fe 100%);
    border: 1px solid #0ea5e9;
}

.day-header .day-name {
    display: block;
    font-size: 1rem;
    color: #64748b;
    margin-bottom: 4px;
}

.day-header .day-number {
    font-size: 3rem;
    font-weight: 700;
    color: #1e293b;
}

.day-header.is-today .day-number {
    color: #0ea5e9;
}

.day-courses {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.no-courses {
    text-align: center;
    padding: 48px 20px;
    color: #94a3b8;
    font-size: 1rem;
}

/* Calendar Course Card */
.calendar-course-card {
    display: block;
    padding: 16px 20px;
    background: white;
    border: 1px solid #e2e8f0;
    border-left-width: 4px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.calendar-course-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.course-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.course-category {
    display: inline-block;
    padding: 4px 10px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 4px;
}

.course-price {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
}

.calendar-course-card .course-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
    line-height: 1.4;
}

.course-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.85rem;
    color: #64748b;
}

.course-dates {
    display: flex;
    align-items: center;
    gap: 6px;
}

.course-dates svg {
    color: #94a3b8;
}

.course-duration {
    padding: 2px 8px;
    background: #f1f5f9;
    border-radius: 4px;
    font-size: 0.75rem;
}

/* Week View */
.week-view {
    overflow-x: auto;
}

.week-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    border-bottom: 1px solid #e2e8f0;
}

.week-day-header {
    padding: 12px 8px;
    text-align: center;
    border-right: 1px solid #f1f5f9;
}

.week-day-header:last-child {
    border-right: none;
}

.week-day-header.is-today {
    background: #f0f9ff;
}

.week-day-name {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    color: #94a3b8;
    text-transform: uppercase;
}

.week-day-number {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
}

.week-day-header.is-today .week-day-number {
    color: #0ea5e9;
}

.week-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    min-height: 300px;
}

.week-day {
    padding: 8px;
    border-right: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
    min-height: 120px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.week-day:last-child {
    border-right: none;
}

.week-day.is-today {
    background: #f0f9ff;
}

/* Course Chip */
.calendar-course-chip {
    display: block;
    padding: 4px 8px;
    font-size: 0.7rem;
    font-weight: 500;
    color: white;
    border-radius: 4px;
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: opacity 0.2s ease;
}

.calendar-course-chip:hover {
    opacity: 0.9;
    color: white;
}

.course-start {
    border-radius: 4px 0 0 4px;
    margin-right: -8px;
    padding-right: 16px;
}

.course-end {
    border-radius: 0 4px 4px 0;
    margin-left: -8px;
    padding-left: 16px;
}

.course-continue {
    border-radius: 0;
    margin-left: -8px;
    margin-right: -8px;
    padding-left: 16px;
    padding-right: 16px;
}

/* Month View */
.month-view {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
}

.month-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.month-day-name {
    padding: 12px 8px;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
}

.month-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.month-cell {
    min-height: 100px;
    padding: 8px;
    border-right: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: background 0.2s ease;
}

.month-cell:nth-child(7n) {
    border-right: none;
}

.month-cell:hover {
    background: #f8fafc;
}

.month-cell.is-today {
    background: #f0f9ff;
}

.month-cell-empty {
    background: #fafafa;
    cursor: default;
}

.month-cell-date {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b;
    margin-bottom: 4px;
}

.month-cell.is-today .month-cell-date {
    background: #0ea5e9;
    color: white;
    border-radius: 50%;
}

.month-cell-courses {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.month-cell-more {
    font-size: 0.7rem;
    color: #0ea5e9;
    padding: 2px 4px;
}

/* Quarter View */
.quarter-view {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.quarter-month {
    background: #f8fafc;
    border-radius: 12px;
    padding: 16px;
}

.quarter-month-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 12px 0;
    text-align: center;
}

.quarter-month-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    margin-bottom: 8px;
}

.quarter-month-header span {
    text-align: center;
    font-size: 0.65rem;
    font-weight: 600;
    color: #94a3b8;
    padding: 4px;
}

.quarter-month-body {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}

.quarter-day {
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
    font-size: 0.75rem;
    color: #64748b;
    border-radius: 4px;
    cursor: default;
}

.quarter-day.empty {
    visibility: hidden;
}

.quarter-day.is-today {
    background: #0ea5e9;
    color: white;
    font-weight: 600;
}

.quarter-day.has-course {
    background: #dbeafe;
    color: #0ea5e9;
    font-weight: 600;
    cursor: pointer;
}

.quarter-day.has-course:hover {
    background: #0ea5e9;
    color: white;
}

/* Year View */
.year-view {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.year-month {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    background: #f8fafc;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.year-month:hover {
    background: #f0f9ff;
    border-color: #0ea5e9;
}

.year-month.is-current {
    border-color: #0ea5e9;
    background: #f0f9ff;
}

.year-month.low {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
}

.year-month.medium {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
}

.year-month.high {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
}

.year-month-name {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 4px;
}

.year-month-count {
    font-size: 0.8rem;
    color: #64748b;
}

/* Calendar Tooltip */
.calendar-tooltip {
    position: absolute;
    z-index: 1000;
    width: 280px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    padding: 16px;
    pointer-events: none;
}

.tooltip-header {
    border-left: 3px solid;
    padding-left: 12px;
    margin-bottom: 8px;
}

.tooltip-category {
    display: inline-block;
    padding: 3px 8px;
    font-size: 0.65rem;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
    border-radius: 4px;
}

.tooltip-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 12px 0;
    line-height: 1.4;
}

.tooltip-meta p {
    font-size: 0.8rem;
    color: #64748b;
    margin: 4px 0;
}

.tooltip-meta strong {
    color: #1e293b;
}

.tooltip-cta {
    display: block;
    margin-top: 12px;
    font-size: 0.75rem;
    color: #0ea5e9;
    font-weight: 500;
}

/* PDF Container */
.calendar-pdf-container {
    padding: 16px;
}

.pdf-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.pdf-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    font-size: 0.875rem;
    font-weight: 500;
    color: white;
    background: #0ea5e9;
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.2s ease;
}

.pdf-download-btn:hover {
    background: #0284c7;
    color: white;
}

.pdf-frame {
    width: 100%;
    height: 600px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

/* Calendar Responsive - Tablet */
@media (max-width: 1024px) {
    .calendar-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .calendar-nav-group {
        justify-content: center;
    }

    .calendar-view-group {
        justify-content: center;
    }

    .quarter-view {
        grid-template-columns: 1fr;
    }

    .year-view {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Calendar Responsive - Mobile */
@media (max-width: 768px) {
    .calendar-toolbar {
        padding: 12px;
    }

    .calendar-title {
        font-size: 1rem;
        margin-left: 0;
        margin-top: 8px;
        order: 3;
        width: 100%;
        text-align: center;
    }

    .calendar-view-buttons {
        flex-wrap: wrap;
        justify-content: center;
    }

    .calendar-view-btn {
        padding: 6px 10px;
        font-size: 0.75rem;
    }

    .calendar-legend {
        flex-wrap: wrap;
        gap: 12px;
    }

    .week-header,
    .week-body {
        min-width: 600px;
    }

    .month-cell {
        min-height: 70px;
        padding: 4px;
    }

    .month-cell-date {
        width: 24px;
        height: 24px;
        font-size: 0.75rem;
    }

    .year-view {
        grid-template-columns: repeat(2, 1fr);
    }

    .pdf-frame {
        height: 400px;
    }
}

/* Calendar Responsive - Small Mobile */
@media (max-width: 480px) {
    .calendar-nav-group {
        flex-wrap: wrap;
    }

    .calendar-toggle-group,
    .calendar-view-buttons {
        width: 100%;
        justify-content: center;
    }

    .month-cell-courses .calendar-course-chip {
        font-size: 0.6rem;
        padding: 2px 4px;
    }

    .year-view {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .year-month {
        padding: 16px 8px;
    }
}
