/* Tab Navigation Styles */
.tab-navigation {
    display: flex;
    gap: 5px;
    margin-bottom: 0;
    border-bottom: 3px solid #ddd;
    flex-wrap: wrap;
}

.tab-button {
    padding: 12px 24px;
    border: none;
    background: #f5f5f5;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 8px 8px 0 0;
    border: 2px solid #ddd;
    border-bottom: none;
    position: relative;
    bottom: -3px;
}

/* Odd semester tabs - Blue theme */
.tab-button.odd-sem {
    background: linear-gradient(to bottom, #e3f2fd 0%, #bbdefb 100%);
    color: #1565c0;
    border-color: #90caf9;
}

.tab-button.odd-sem:hover {
    background: linear-gradient(to bottom, #64b5f6 0%, #42a5f5 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(66, 165, 245, 0.4);
}

.tab-button.odd-sem.active {
    background: linear-gradient(to bottom, #0d47a1 0%, #1565c0 100%);
    color: white;
    border-color: #0d47a1;
    box-shadow: 0 6px 12px rgba(13, 71, 161, 0.5);
    font-weight: 700;
    transform: scale(1.05);
}

/* Even semester tabs - Green theme */
.tab-button.even-sem {
    background: linear-gradient(to bottom, #e8f5e9 0%, #c8e6c9 100%);
    color: #2e7d32;
    border-color: #a5d6a7;
}

.tab-button.even-sem:hover {
    background: linear-gradient(to bottom, #66bb6a 0%, #4caf50 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(76, 175, 80, 0.4);
}

.tab-button.even-sem.active {
    background: linear-gradient(to bottom, #1b5e20 0%, #2e7d32 100%);
    color: white;
    border-color: #1b5e20;
    box-shadow: 0 6px 12px rgba(27, 94, 32, 0.5);
    font-weight: 700;
    transform: scale(1.05);
}

/* Tab Content */
.tab-content {
    display: none;
    animation: fadeIn 0.4s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.semester-content {
    max-height: 65vh;
    overflow: auto;
    padding: 20px;
    border: 2px solid #ddd;
    border-top: none;
    border-radius: 0 8px 8px 8px;
    background: white;
}

table.curriculum {
    width: 100%;
    border-collapse: collapse;
    font-family: Arial, sans-serif;
}

table.curriculum th,
table.curriculum td {
    border: 1px solid #999;
    padding: 10px 12px;
    font-size: 14px;
    text-align: left;
}

/* Column width controls */
table.curriculum th:nth-child(1),
table.curriculum td:nth-child(1) {
    width: 4%;
}

/* Sem */
table.curriculum th:nth-child(2),
table.curriculum td:nth-child(2) {
    width: 8%;
}

/* Course No */
table.curriculum th:nth-child(3),
table.curriculum td:nth-child(3) {
    width: 30%;
}

/* Course Name */
table.curriculum th:nth-child(4),
table.curriculum td:nth-child(4) {
    width: 6%;
}

/* Lecture */
table.curriculum th:nth-child(5),
table.curriculum td:nth-child(5) {
    width: 6%;
}

/* Tutorial */
table.curriculum th:nth-child(6),
table.curriculum td:nth-child(6) {
    width: 6%;
}

/* Ext. Tut. */
table.curriculum th:nth-child(7),
table.curriculum td:nth-child(7) {
    width: 5%;
}

/* Lab */
table.curriculum th:nth-child(8),
table.curriculum td:nth-child(8) {
    width: 12%;
    white-space: normal;
    word-wrap: break-word;
}

/* Time outside class */
table.curriculum th:nth-child(9),
table.curriculum td:nth-child(9) {
    width: 6%;
}

/* Credits */
table.curriculum th:nth-child(10),
table.curriculum td:nth-child(10) {
    width: 7%;
}

/* Category */

/* Center align numeric columns */
table.curriculum td:nth-child(1),
table.curriculum td:nth-child(4),
table.curriculum td:nth-child(5),
table.curriculum td:nth-child(6),
table.curriculum td:nth-child(7),
table.curriculum td:nth-child(8),
table.curriculum td:nth-child(9),
table.curriculum td:nth-child(10) {
    text-align: center;
}

table.curriculum th {
    font-size: 15px;
    font-weight: bold;
    text-align: center;
    background: #f8f9fa;
    position: sticky;
    top: 0;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

table.curriculum tr:hover {
    background-color: #f5f5f5;
}

/* Credit total rows */
tr.credit-row td {
    border: none;
    background: #e9ecef;
    font-weight: bold;
    font-size: 16px;
    padding: 15px 12px;
}

/* Semester badge */
.semester-badge {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: bold;
    margin-bottom: 20px;
    font-size: 18px;
}

.semester-badge.odd {
    background: linear-gradient(135deg, #1976d2 0%, #1565c0 100%);
    color: white;
    box-shadow: 0 3px 6px rgba(25, 118, 210, 0.3);
}

.semester-badge.even {
    background: linear-gradient(135deg, #388e3c 0%, #2e7d32 100%);
    color: white;
    box-shadow: 0 3px 6px rgba(56, 142, 60, 0.3);
}

/* Scrollbar styling */
.semester-content::-webkit-scrollbar {
    width: 10px;
}

.semester-content::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.semester-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 5px;
}

.semester-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}