/* Course Page Specific Styles */

.course__nav {
    position: sticky;
    top: var(--header-height);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    padding: 0.75rem;
    margin-bottom: 2rem;
    z-index: 99;
    border-bottom: 1px solid rgba(14, 36, 49, 0.08);
}

.course__nav-list {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    list-style: none;
    padding: 0;
    margin: 0;
    max-width: 100%;
}

.course__nav-list::-webkit-scrollbar {
    display: none;
}

.course__nav-link {
    color: var(--black-color);
    font-size: var(--smaller-font-size);
    white-space: nowrap;
    text-decoration: none;
    padding: 0.25rem 0;
    position: relative;
    transition: color 0.3s ease;
}

.course__nav-link:hover {
    color: var(--first-color);
}

.course__nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: var(--first-color);
    transition: width 0.3s ease;
}

.course__nav-link:hover::after {
    width: 100%;
}

.course__nav-link.active {
    color: var(--first-color);
    font-weight: var(--font-semi);
}

.course__nav-link.active::after {
    width: 100%;
}

.course-title-wrapper {
    text-align: center;
    margin-bottom: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.course-title {
    font-size: var(--h2-font-size);
    color: var(--first-color);
    text-align: center;
    margin-top: 0;
    margin-bottom: 0.5rem;
    position: relative;
    padding-bottom: 0.5rem;
    font-size: calc(var(--h2-font-size) * 1.1);
}

.course-title::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    width: 80px;
    height: 0.18rem;
    background-color: var(--second-color);
}

.mqa-badge {
    display: inline-block;
    background-color: var(--third-color);
    color: var(--white-color);
    padding: 0.4rem 1rem;
    border-radius: 0.5rem;
    font-size: var(--smaller-font-size);
    font-weight: var(--font-semi);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}


@media screen and (min-width: 768px) {
    .course-title {
        font-size: calc(var(--h2-font-size) * 1.2);
        margin-top: 3rem;
    }
    
    .course-title::after {
        width: 130px;
    }

    .mqa-badge {
        font-size: var(--normal-font-size);
    }
}


.course__container {
    row-gap: 3rem;          /* Reduced from 1rem */
    padding-top: 2rem;
    margin-top: 0;
}

.course__content {
    background-color: var(--bg-color);
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0px 4px 25px rgba(14, 36, 49, 0.15);
    transition: transform 0.3s ease;
    scroll-margin-top: calc(var(--header-height) + 3rem);
}

.course__content:hover {
    transform: translateY(-5px);
    box-shadow: 0px 8px 35px rgba(14, 36, 49, 0.2);
}

.course__subtitle {
    font-size: var(--h2-font-size);
    color: var(--first-color);
    margin-bottom: var(--mb-2);
}

.course__text {
    margin-bottom: var(--mb-4);
    line-height: 1.6;
}

.course__list {
    list-style: none;
    padding: 0;
}

.course__item {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 1rem;
    font-size: var(--normal-font-size);
}

.course__item::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--second-color);
    font-weight: bold;
}

.module__list {
    margin-top: 2rem;
}

.module__item {
    margin-bottom: 0.75rem;
    border-radius: 0.5rem;
    overflow: hidden;
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.module__header {
    padding: 1rem 1.5rem;
    background: var(--bg-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.module__header:hover {
    background: #f0f0f0;
}

.module__title {
    margin: 0;
    font-size: var(--normal-font-size);
    color: var(--first-color);
    font-weight: var(--font-semi);
}

.module__icon {
    font-size: 1.5rem;
    color: var(--second-color);
    transition: transform 0.3s ease;
}

.module__content {
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.module__content-inner {
    padding: 1.5rem;
    background: white;
}

.module__content-inner ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.module__content-inner li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: var(--normal-font-size);
    line-height: 1.5;
}

.module__content-inner li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--first-color);
}

.module__item.active .module__header {
    background-color: var(--bg-color);
}

.module__item.active .module__icon {
    transform: rotate(180deg);
}

.module__item.active .module__content {
    max-height: 500px;
}


.course__section-heading {
    color: var(--first-color);
    margin-bottom: 1rem;
    font-size: calc(var(--normal-font-size) * 1.1);
    font-weight: var(--font-semi);
}

.course__section-heading--spaced {
    margin-top: 2rem;
}

.course__price {
    margin-bottom: 1rem;
    /* font-size: calc(var(--normal-font-size) * 1.2); */
}

.course__form-container {
    position: relative;
    width: 100%;
    min-height: 700px; /* Adjust based on your form's height */
    margin-top: var(--mb-4);
    border-radius: 0.5rem;
    overflow: hidden;
}

.course__form-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 0.5rem;
}

.course__contact-grid {
    display: grid;
    gap: 1.5rem;
    margin-top: 1rem;
}

.course__contact-item {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.course__contact-title {
    color: var(--first-color);
    font-weight: var(--font-semi);
    margin-bottom: 0.75rem;
    font-size: calc(var(--normal-font-size) * 1.05);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.course__contact-title i {
    font-size: 1.25rem;
    color: var(--second-color);
}

.course__contact-link {
    color: var(--first-color);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.course__contact-link:hover {
    color: var(--second-color);
}

.course__contact-info {
    margin-top: 0.75rem;
}

/* Media Queries */

@media screen and (min-width: 768px) {
    .course__contact-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media screen and (min-width: 768px) {
    .course__container {
        padding-top: calc(var(--header-height));
    }

    .course__content {
        padding: 3rem;
        scroll-margin-top: calc(var(--header-height) + 1.5rem);
    }

    .course__nav{
        top: calc(var(--header-height) + 1.5rem)
    }
}

@media screen and (min-width: 1024px) {
    .course__container {
        max-width: 968px;
        margin: 0 auto;
    }
}

/* Trainer Profile Styles */
.course__trainer-profile {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.course__trainer-img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto;
    box-shadow: 0 4px 25px rgba(14, 36, 49, 0.15);
}

.course__trainer-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 10%; /* Shift focus to upper part of image */
    transform: scale(1.1); /* Slightly zoom in to improve framing */
}

.course__trainer-text {
    flex: 1;
}

@media screen and (min-width: 768px) {
    .course__trainer-profile {
        flex-direction: row;
        align-items: center;
    }

    .course__trainer-img {
        margin: 0;
    }
}