.judo-schedule-wrapper {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #ccc;
    border-radius: 8px;
    margin: 20px 0;
    font-family: Arial, sans-serif !important;
}

/* Override any site styles that might interfere */
.judo-schedule-wrapper * {
    box-sizing: border-box !important;
}

.judo-schedule-wrapper table {
    border-collapse: collapse !important;
    border-spacing: 0 !important;
}

.judo-schedule-table {
    width: 100%;
    min-width: 800px;
    border-collapse: collapse;
    font-family: Arial, sans-serif;
    table-layout: fixed;
    font-size: 0.7em;
    line-height: 1.2;
}

.judo-schedule-table th,
.judo-schedule-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
    vertical-align: top;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
}

/* First column (Aika) is narrower */
.judo-schedule-table th:first-child,
.judo-schedule-table td:first-child {
    width: 8%;
}

/* Other columns share the remaining space */
.judo-schedule-table th:not(:first-child),
.judo-schedule-table td:not(:first-child) {
    width: 13.14%;
}

.judo-schedule-table th {
    background-color: #f2f2f2 !important;
    font-weight: bold !important;
    text-align: center !important;
    color: #333 !important;
    padding: 8px !important;
    border: 1px solid #ddd !important;
}

.judo-schedule-table .judo-time-header {
    background-color: #e8e8e8 !important;
    font-weight: bold !important;
    text-align: center !important;
    min-width: 80px !important;
    color: #333 !important;
    font-family: var(--e-global-typography-text-font-family), Sans-serif !important;
    font-size: 0.7em !important;
    line-height: 1.2 !important;
}

.judo-schedule-table .judo-weekday-header {
    background-color: #f2f2f2 !important;
    font-weight: bold !important;
    text-align: center !important;
    color: #333 !important;
    font-family: var(--e-global-typography-text-font-family), Sans-serif !important;
    font-size: 0.7em !important;
    line-height: 1.2 !important;
    padding: 8px !important;
    border: 1px solid #ddd !important;
}

.judo-schedule-table thead th {
    background-color: #f2f2f2 !important;
    font-weight: bold !important;
    text-align: center !important;
    color: #333 !important;
    padding: 8px !important;
    border: 1px solid #ddd !important;
}

.judo-schedule-table thead .judo-time-header {
    background-color: #e8e8e8 !important;
}

.judo-schedule-table .judo-time-slot {
    background-color: #e8e8e8 !important;
    font-weight: bold !important;
    text-align: center !important;
    color: #333 !important;
    font-family: var(--e-global-typography-text-font-family), Sans-serif !important;
    font-size: 0.7em !important;
    line-height: 1.2 !important;
    padding: 8px !important;
    border: 1px solid #ddd !important;
}

.judo-class-item {
    margin-bottom: 8px;
    padding: 4px;
    background-color: #f9f9f9;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
    font-family: var(--e-global-typography-text-font-family), Sans-serif;
    font-size: 0.7em;
    line-height: 1.2;
}

.judo-class-item:hover {
    background-color: #e6f3ff;
}

.judo-class-item:last-child {
    margin-bottom: 0;
}

/* Color classes for different class types */
.judo-class-item.judo-color-yellow {
    background-color: #ffffd0 !important;
}

.judo-class-item.judo-color-green {
    background-color: #d4edda !important;
}

.judo-class-item.judo-color-orange {
    background-color: #ffe4b5 !important;
}

.judo-class-item.judo-color-gray {
    background-color: #e9ecef !important;
}

/* Hover states for colored items */
.judo-class-item.judo-color-yellow:hover {
    background-color: #ffff90 !important;
}

.judo-class-item.judo-color-green:hover {
    background-color: #c3e6cb !important;
}

.judo-class-item.judo-color-orange:hover {
    background-color: #ffd58a !important;
}

.judo-class-item.judo-color-gray:hover {
    background-color: #dee2e6 !important;
}

.judo-class-time {
    color: #666;
}

.judo-class-topic {
    font-weight: bold;
    color: #003366;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
}

.judo-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 9999;
}

.judo-popup-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.judo-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    font-weight: bold;
}

.judo-popup-close:hover {
    color: #000;
}

.judo-popup-title {
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 10px;
    margin-top: 20px;
}

.judo-popup-time {
    font-size: 1.1em;
    color: #666;
    margin-bottom: 15px;
}

.judo-popup-description {
    margin-bottom: 15px;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
}

.judo-popup-instructors {
    margin-bottom: 10px;
}

.judo-popup-instructors strong {
    display: block;
    margin-bottom: 5px;
}

.judo-popup-body {
    /* Additional styling for popup body if needed */
}

.judo-schedule-wrapper .loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .judo-schedule-table {
        min-width: 600px;
        font-family: var(--e-global-typography-text-font-family), Sans-serif;;
    }

    .judo-popup-content {
        width: 95%;
        margin: 10px;
    }
}