/* ============================================
   Course Details Pages
   ============================================ */

.course-glance-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 25px 0 35px;
}

.course-glance-card {
    background: #f4f6fb;
    border: 1px solid #dde3f0;
    border-radius: 12px;
    padding: 20px 18px 16px;
    border-left: 4px solid #8b1a2b;
}

.course-glance-label {
    display: block;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 14px;
    color: #8b1a2b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 8px;
}

.course-glance-value {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 17px;
    color: #1e3a8a;
    font-weight: 700;
    line-height: 1.5;
}

/* Section headings */
.course-section-heading {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 32px;
    font-weight: 700;
    color: #1e3a8a;
    font-style: italic;
    margin: 50px 0 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid #e5e8f0;
}

.course-section-title {
    color: var(--primary-color);
    margin: 28px 0 14px;
    font-size: 27px;
    font-weight: 800;
}

/* Rule blocks */
.course-rule-block {
    background: #fff;
    border: 1px solid #e5e8f0;
    border-radius: 12px;
    padding: 28px 30px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.course-rule-block::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: #8b1a2b;
}

.course-rule-number {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 15px;
    font-weight: 700;
    color: #8b1a2b;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.course-rule-title {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 22px;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 14px;
}

.course-rule-body {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-style: italic;
}

.course-rule-body p {
    font-size: 18px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 14px;
}

.course-rule-body ol {
    padding-left: 24px;
    margin: 0;
}

.course-rule-body ol li {
    font-size: 18px;
    line-height: 1.8;
    color: #333;
    margin-bottom: 10px;
}

.course-rule-body b,
.course-rule-body strong {
    color: #1e3a8a;
    font-weight: 700;
}

/* Marks / Stats cards */
.course-marks-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin: 20px 0;
}

.course-marks-card {
    background: #f4f6fb;
    border: 1px solid #dde3f0;
    border-radius: 12px;
    padding: 22px 18px;
    text-align: center;
}

.marks-value {
    display: block;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 36px;
    font-weight: 700;
    color: #1e3a8a;
    line-height: 1.1;
    margin-bottom: 8px;
}

.marks-label {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 16px;
    color: #555;
    font-style: italic;
    line-height: 1.5;
}

.marks-label small {
    display: block;
    font-size: 14px;
    color: #888;
    margin-top: 4px;
}

/* Semester heading */
.semester-heading {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 25px;
    font-weight: 700;
    color: #8b1a2b;
    font-style: italic;
    margin: 30px 0 16px;
}

/* Semester table tweaks */
.semester-table thead th:first-child {
    width: 90px;
}

.semester-table tbody td:first-child {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 15px;
    font-weight: 700;
    color: #1e3a8a;
    font-style: normal;
    white-space: nowrap;
    text-align: center;
    width: 90px;
}

.semester-table thead th:nth-child(n+3),
.semester-table tbody td:nth-child(n+3) {
    text-align: center;
    width: 90px;
}

.semester-table tfoot tr {
    background: #1e3a8a !important;
}

.semester-table tfoot td {
    padding: 14px 22px;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 17px;
    color: #fff !important;
    font-style: normal !important;
    font-weight: 700;
    text-align: center;
    border: none !important;
}

.semester-table tfoot td:first-child {
    text-align: left;
    color: #fff !important;
}

.semester-table tfoot td b {
    color: #fff;
}

.course-note {
    background: #fef7f0;
    border: 1px solid #f0d4b8;
    border-left: 4px solid #8b1a2b;
    color: #333;
    padding: 20px 24px;
    border-radius: 10px;
    margin: 30px 0;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 18px;
    font-style: italic;
    line-height: 1.7;
}

.course-note b {
    color: #1e3a8a;
    font-style: italic;
}

.course-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 20px;
}

.course-cta-row a {
    text-decoration: none;
}

.btn-course-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 10px;
    background: var(--primary-color);
    color: white;
    font-weight: 700;
    border: 1px solid var(--primary-color);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.btn-course-primary:hover {
    transform: translateY(-1px);
    opacity: 0.95;
}

.btn-course-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 10px;
    background: white;
    color: var(--primary-color);
    font-weight: 800;
    border: 1px solid rgba(30, 47, 122, 0.25);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.btn-course-secondary:hover {
    transform: translateY(-1px);
    border-color: rgba(30, 47, 122, 0.45);
}

.course-faq {
    margin-top: 18px;
}

.course-faq details {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 12px;
}

.course-faq summary {
    cursor: pointer;
    font-weight: 800;
    color: var(--text-dark);
}

.course-faq summary::-webkit-details-marker {
    display: none;
}

.course-faq details p {
    margin-top: 10px;
    color: #475569;
    line-height: 1.75;
}

/* Fee Structure Table */
.fee-structure-table {
    min-width: 900px;
}

.fee-structure-table thead th {
    font-size: 15px;
    padding: 14px 12px;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
}

.fee-structure-table thead th:first-child {
    text-align: left;
    min-width: 200px;
    white-space: normal;
}

.fee-structure-table tbody td {
    text-align: center;
    padding: 11px 12px;
    font-size: 16px;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-style: normal;
    white-space: nowrap;
}

.fee-structure-table tbody td:first-child {
    text-align: left;
    font-style: italic;
    color: #333;
    white-space: normal;
}

.fee-structure-table tfoot tr {
    background: #f4f6fb !important;
}

.fee-structure-table tfoot tr:last-child {
    background: #1e3a8a !important;
}

.fee-structure-table tfoot td {
    padding: 13px 12px;
    text-align: center;
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 16px;
    font-style: normal !important;
    border-top: 2px solid #dde3f0;
}

.fee-structure-table tfoot tr:last-child td {
    color: #fff !important;
    border: none !important;
}

.fee-structure-table tfoot tr:last-child td b {
    color: #fff;
}

.fee-structure-table tfoot td:first-child {
    text-align: left;
}

.fee-pdf-section {
    margin-top: 30px;
    border: 1px solid #dde3f0;
    border-radius: 12px;
    overflow: hidden;
    background: #f9fafb;
}

.fee-pdf-section iframe {
    border: none;
    display: block;
}

@media (max-width: 1024px) {
    .course-glance-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .course-section-heading {
        font-size: 27px;
    }
}

@media (max-width: 768px) {
    .course-marks-grid {
        grid-template-columns: 1fr;
    }

    .course-rule-block {
        padding: 22px 20px;
    }

    .course-rule-title {
        font-size: 20px;
    }

    .course-rule-body p,
    .course-rule-body ol li {
        font-size: 17px;
    }

    .marks-value {
        font-size: 32px;
    }

    .course-section-heading {
        font-size: 25px;
        margin: 40px 0 18px;
    }

    .semester-heading {
        font-size: 22px;
    }

    .semester-table thead th:nth-child(n+3),
    .semester-table tbody td:nth-child(n+3) {
        width: 70px;
    }

    .semester-table thead th:first-child,
    .semester-table tbody td:first-child {
        width: 70px;
    }
}

@media (max-width: 600px) {
    .course-glance-grid {
        grid-template-columns: 1fr;
    }

    .editorial-table-container {
        overflow-x: auto;
    }

    .semester-table {
        min-width: 600px;
    }

    .course-section-heading {
        font-size: 22px;
    }

    .semester-heading {
        font-size: 20px;
    }
}
