* {
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
}

/* Loader styles */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    display: none;
    /* Hidden initially */
}

.prev-btn-duplicate {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 1;
    font-size: 24px;
    border-radius: 50%;
}

.next-btn-duplicate {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 1;
    font-size: 24px;
    border-radius: 50%;
}

.prev-btn-duplicate {
    left: 0;
    /* Move button to the far left side */
}

.next-btn-duplicate {
    right: 0;
    /* Move button to the far right side */
}

.loader {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #FFC107;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    background-color: #fff;
    border-bottom: 2px solid #FFC107;
    position: relative;
}

.navbar .left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.navbar .logo {
    display: flex;
    align-items: center;
}

.navbar .logo img {
    height: 40px;
    margin-right: 8px;
}

.navbar nav {
    display: flex;
    gap: 20px;
}

.navbar nav a {
    text-decoration: none;
    color: #000;
    font-weight: 600;
    font-size: 18px;
    font-family: system-ui;
}

.navbar nav a:hover {
    text-decoration: underline;
    color: #FFC107;
}

.navbar .right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.navbar .search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.navbar .search-container input {
    border-radius: 20px;
    border: 1px solid #ddd;
    padding: 5px 30px 5px 10px;
    outline: none;
    font-size: 0.9em;
    width: 150px;
}

.navbar .search-container .search-icon {
    position: absolute;
    right: 10px;
    cursor: pointer;
}

.navbar .language-dropdown {
    position: relative;
}

.navbar .language-dropdown select {
    border: none;
    background: none;
    font-size: 1em;
    cursor: pointer;
}

.navbar .auth-links {
    font-weight: 500;
}

.navbar .auth-links a {
    text-decoration: none;
    color: #000;
}

.toggle-button {
    display: none;
}

/* User menu dropdown styling */
.user-menu {
    position: relative;
    cursor: pointer;
}

.user-menu .dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background-color: white;
    color: black;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    z-index: 1;
    border-radius: 5px;
    overflow: hidden;
}

.user-menu:hover .dropdown-menu {
    display: block;
}

.dropdown-menu button {
    display: block;
    width: 100%;
    padding: 10px 20px;
    background: none;
    border: none;
    color: #333;
    text-align: left;
    cursor: pointer;
}

.dropdown-menu button:hover {
    background-color: #f0f0f0;
}

/* Overlay and Popup styling */
.overlay,
.popup {
    display: none;
}

.overlay.active,
.popup.active {
    display: block;
}

/* Popup Styles */
.popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #ffffff;
    /* border: 1px solid #7a2f95; */
    border-radius: 10px;
    /* Rounded corners */
    padding: 60px;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 85%;
    /* Responsive width */
    max-width: 400px;
    /* Maximum width */
    overflow: hidden;
    /* Hide overflow */
}

.popup .close {
    cursor: pointer;
    color: #FFC107;
    font-size: 35px;
    position: absolute;
    right: 10px;
    top: 10px;
}

.popup h2 {
    text-align: center;
    /* Center the title */
    color: #FFC107;
    /* Darker title color */
    margin-bottom: 35px;
    /* Space below title */
}

.popup .input-container {
    display: flex;
    align-items: center;
    gap: 10px;
    /* Space between country code and input */
}

.popup select {
    padding: 10px;
    border: 1px solid #FFC107;
    border-radius: 5px;
    font-size: 16px;
    width: auto;
    /* Make dropdown width auto */
    flex-shrink: 0;
    /* Prevent shrinking */
}

.popup input[type="text"] {
    border: 1px solid #FFC107;
    padding: 10px;
    border-radius: 5px;
    font-size: 16px;
    flex: 1;
    /* Allow input to grow */
    min-width: 0;
    /* Prevent overflow */
}

.popup .get-otp {
    background-color: #ffc001;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 35px;
    /* Space between input and button */
    width: 100%;
    /* Full width */
    font-size: 16px;
    transition: background-color 0.3s;
    /* Smooth transition */
}

.get-otp1 {
    background-color: #ffc001;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 35px;
    /* Space between input and button */
    width: 100%;
    /* Full width */
    font-size: 16px;
    transition: background-color 0.3s;
    /* Smooth transition */
}

.popup .get-otp:hover {
    background-color: #cb9d11;
    /* Darker shade on hover */
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 500;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .navbar .logo img {
        height: 30px;
        margin-right: 8px;
    }

    .navbar nav {
        display: none;
        flex-direction: column;
        position: absolute;
        background-color: #fff;
        top: 55px;
        left: 0px;
        z-index: 10;
        width: 100%;
    }

    .navbar.active nav {
        display: flex;
        width: 100%;
        padding-left: 10px;
    }

    .navbar .toggle-button {
        display: block;
        cursor: pointer;
    }

    .navbar .toggle-button i {
        font-size: 1.5em;
    }

    .navbar .right {
        display: none;
        flex-direction: column;
        gap: 15px;
        width: 100%;
        position: absolute;
        top: calc(150px + 45px);
        left: 0;
        background-color: #fff;
        z-index: 10;
    }

    .navbar.active .right {
        display: flex;
    }

    .popup {
        padding: 20px !important;
    }
}

#container {
    width: 100%;
    /* height: 100%; */
    display: flex;
    align-items: center;
    background-image: url('./images/Banner.jpg');
    background-repeat: no-repeat;
    background-position: 100%;
    background-size: cover;
    margin-top: 1%;
}

#container #main-container {
    width: 65vw;
    height: 80vh;
    display: flex;
    justify-content: space-around;
    align-items: center;
}

#container #main-container h1 {
    font-size: 4rem;
    color: #fdcd00;
    margin: 0;
    opacity: 0;
    /* Initial opacity for fade-in */
    transform: translateX(-100%);
    /* Start off the screen */
    animation: slideInLeft 1s ease-out forwards;
    /* Animation */
}

#container #main-container h2 {
    font-size: 3.5rem;
    color: #fff;
    margin: 0;
    opacity: 0;
    transform: translateX(-100%);
    animation: slideInLeft 1.2s ease-out forwards;
    animation-delay: 0.5s;
    /* Delay to appear after h1 */
}

#container #main-container h3 {
    color: #fff;
    font-size: 22px;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    opacity: 0;
    transform: translateX(-100%);
    animation: slideInLeft 1.5s ease-out forwards;
    animation-delay: 1s;
    /* Delay to appear after h2 */
    margin-top: 1%;
}

#container #main-container #line {
    width: 40vw;
    height: 5px;
    background-color: #fdcd00;
    opacity: 0;
    transform: scaleX(0);
    animation: lineExpand 1s ease-out forwards;
    animation-delay: 1.8s;
    /* Delay to appear after headings */
}

/* Keyframes for sliding in from the left */
@keyframes slideInLeft {
    to {
        opacity: 1;
        /* Fade in */
        transform: translateX(0);
        /* Slide to original position */
    }
}

/* Keyframes for line animation */
@keyframes lineExpand {
    to {
        opacity: 1;
        transform: scaleX(1);
        /* Expand the line */
    }
}

/* ----Upcoming-Events ---- */
.container {
    /* width: 100%; Full viewport width */
    overflow: hidden;
    /* Prevent overflow */
    margin: 0;
    /* No margins */
    position: relative;
    /* For buttons positioning */
}

.carousel-wrapper {
    overflow: hidden;
    width: 100vw;
    /* Full viewport width */
}

.section-title {
    font-size: 24px;
    margin: 10px;
    padding-left: 10px;
    /* Move "Top 10" to the left side */
    text-align: left;
    /* Align "Top 10" to the left */
}

.carousel-container {
    display: flex;
    overflow: hidden;
    width: 100vw;
    /* Full width for the carousel */
}
.carousel{
    overflow: visible !important;
}

.carousel {
    display: flex;
    transition: transform 0.4s ease-in-out;
    width: fit-content;
    /* Adjust width dynamically based on content */
    gap: 20px;
}

.card {
    position: relative;
    margin-left: 2%;
    width: calc(100vw / 2.07);
    height: calc(180px * 1.);
    /* width: calc(100vw / 4 * 0.8); /* Reduced width */
    /* height: calc(180px * 1.1); /* Reduced height */
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    /* box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); */
}

.card img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 10px;
}

.card-hover {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 10px;
    text-align: left;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover .card-hover {
    opacity: 1;
}

.card-hover h3 {
    font-size: 16px;
    margin-bottom: 5px;
}

.card-hover p {
    font-size: 14px;
    margin: 0;
}

/* Navigation Buttons */
.prev-btn2,
.next-btn2 {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 1;
    font-size: 24px;
    border-radius: 50%;
}

.prev-btn,
.next-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 1;
    font-size: 24px;
    border-radius: 50%;
}

.prev-btn1,
.next-btn1 {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 1;
    font-size: 24px;
    border-radius: 50%;
}

.prev-btn {
    left: 0;
    /* Move button to the far left side */
}

.prev-btn2 {
    left: 0;
    /* Move button to the far left side */
}

.next-btn {
    right: 0;
    /* Move button to the far right side */
}

.next-btn2 {
    right: 0;
    /* Move button to the far right side */
}

.prev-btn:hover,
.next-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

@media (max-width: 768px) {
    .navbar .logo img {
        height: 30px;
        margin-right: 8px;
    }

    .navbar nav {
        display: none;
        flex-direction: column;
        position: absolute;
        background-color: #fff;
        top: 55px;
        left: 0px;
        z-index: 10;
        width: 100%;

    }

    .navbar.active nav {
        display: flex;
    }

    .navbar .toggle-button {
        display: block;
        cursor: pointer;
    }

    .navbar .toggle-button i {
        font-size: 1.5em;
    }

    .navbar .right {
        display: none;
        flex-direction: column;
        gap: 15px;
        width: 100%;
        position: absolute;
        top: calc(109px + 32px);
        left: 0;
        background-color: #fff;
        z-index: 10;
    }

    .navbar.active .right {
        display: flex;
    }

    .popup {
        padding: 20px;
    }

    #container {
        height: 25vh !important;
        width: 100%;
        background-position: 100%;
    }

    #container #main-container h1 {
        font-size: 15px;
    }

    #container #main-container h2 {
        font-size: 12px;
    }

    #container #main-container h3 {
        font-size: 6px;
        margin-top: 3%;
        font-weight: normal;
    }

    #container #main-container #line {
        height: 1px;
    }

    .card {
        scroll-snap-align: start;
    }

    .section-title {
        font-size: 14px;
        margin: 10px;
        padding-left: 0px;
        text-align: left;
    }

    /* Hide buttons on mobile */
    .prev-btn,
    .next-btn,
    .prev-btn1,
    .next-btn1,
    .prev-btn2,
    .next-btn2 {
        display: none !important;
    }

    .card img {
        height: auto;
        object-fit: contain;
    }

    .card-hover h3 {
        font-size: 8px;
        margin-bottom: 2px;
    }

    .card-hover p {
        font-size: 8px;
        margin-bottom: 2px;
    }

    /* For mobile devices */
    .card {
        width: calc(150vw / 2* 0.6);
        height: calc(170px* 0.6);
        scroll-snap-align: start;
    }

    .carousel-container {
        overflow-x: scroll;
        /* Allow touch scrolling */
        scroll-snap-type: x mandatory;
        /* Snap to cards */
    }

    .carousel {
        width: auto;
        flex-wrap: nowrap;
        margin: auto;
    }

    /* Hide buttons on mobile */
    .prev-btn,
    .next-btn,
    .prev-btn1,
    .next-btn1,
    .prev-btn2,
    .next-btn2,
    .next-btn-infertility,
    .prev-btn-infertility,
    .next-btn-akademi,
    .prev-btn-akademi,
    .next-btn-flemiclave,
    .prev-btn-flemiclave {
        display: none !important;
    }

    .card img {
        height: auto;
        object-fit: contain;
    }

    .carousel-container,
    .carousel-container-infertility,
    .carousel-container-allergy,
    .carousel-container-searpharma,
    .carousel-container-akademi,
    .carousel-container-flemiclave {
        overflow-x: auto !important;
        overflow-y: hidden !important;
        white-space: nowrap !important;
        scroll-behavior: smooth !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .carousel {
        display: flex !important;
        flex-wrap: nowrap !important;
    }

    .card {
        flex: 0 0 auto;
        scroll-snap-align: start;
    }

    /* Optional: smooth snapping effect */
    .carousel-container {
        scroll-snap-type: x mandatory;
    }

    .navbar nav {
        gap: 8px;
    }

}