/********** Template CSS **********/
:root {
    --primary: #0463FA;
    --light: #EFF5FF;
    --dark: #1B2C51;
}

.fw-medium {
    font-weight: 500 !important;
}

.fw-bold {
    font-weight: 700 !important;
}

.fw-black {
    font-weight: 900 !important;
}

.back-to-top {
    position: fixed;
    display: none;
    right: 45px;
    bottom: 45px;
    z-index: 99;
}


/*** Spinner ***/
#spinner {
    opacity: 0;
    visibility: hidden;
    transition: opacity .5s ease-out, visibility 0s linear .5s;
    z-index: 99999;
}

#spinner.show {
    transition: opacity .5s ease-out, visibility 0s linear 0s;
    visibility: visible;
    opacity: 1;
}


/*** Button ***/
.btn {
    font-weight: 500;
    transition: .5s;
}

.btn.btn-primary,
.btn.btn-secondary {
    color: #FFFFFF;
}

.btn-square {
    width: 38px;
    height: 38px;
}

.btn-sm-square {
    width: 32px;
    height: 32px;
}

.btn-lg-square {
    width: 48px;
    height: 48px;
}

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: normal;
}


/*** Navbar ***/
.navbar .dropdown-toggle::after {
    border: none;
    content: "\f107";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    vertical-align: middle;
    margin-left: 8px;
}

.navbar .navbar-nav .nav-link {
    margin-right: 30px;
    padding: 25px 0;
    color: #FFFFFF;
    font-size: 15px;
    font-weight: 500;
    text-transform: uppercase;
    outline: none;
}

.navbar .navbar-nav .nav-link:hover,
.navbar .navbar-nav .nav-link.active {
    color: var(--primary);
}

@media (max-width: 991.98px) {
    .navbar .navbar-nav .nav-link  {
        margin-right: 0;
        padding: 10px 0;
    }

    .navbar .navbar-nav {
        border-top: 1px solid #EEEEEE;
    }
}

.navbar .navbar-brand,
.navbar a.btn {
    height: 75px;
}

.navbar .navbar-nav .nav-link {
    color: var(--dark);
    font-weight: 500;
}

.navbar.sticky-top {
    top: -100px;
    transition: .5s;
}

@media (min-width: 992px) {
    .navbar .nav-item .dropdown-menu {
        display: block;
        border: none;
        margin-top: 0;
        top: 150%;
        opacity: 0;
        visibility: hidden;
        transition: .5s;
    }

    .navbar .nav-item:hover .dropdown-menu {
        top: 100%;
        visibility: visible;
        transition: .5s;
        opacity: 1;
    }
}


/*** Header ***/
.header-carousel .owl-carousel-text {
    position: absolute;
    width: 100%;
    height: 100%;
    padding: 2rem; /* Reduced padding to reduce the vertical space */
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 0 30px rgba(0, 0, 0, .1);
}

.header-carousel .owl-carousel-text h1 {
    font-size: 2.5rem; /* Adjusted font size for carousel text */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7), /* Dark outline effect */
                 -2px -2px 4px rgba(0, 0, 0, 0.7); /* Optional double direction for more depth */
    color: #fff; /* Ensures the text remains white */
}

.number-plus-container {
    display: flex;
    align-items: center; /* Vertically centers the number and the + sign */
    justify-content: flex-start; /* Aligns both items side by side */
}

.plus-symbol {
    font-size: 1.5rem; /* Match size to the number */
    margin-left: 4px; /* Add space between the number and the + */
    font-weight: 900;
    color: white;
    line-height: 1; /* Adjust line-height to ensure proper vertical alignment */
    display: flex; /* Ensures proper alignment */
    align-items: center; /* Vertically centers the + sign within its container */
}

.header-carousel .owl-nav {
    position: absolute;
    width: 200px;
    height: 45px;
    bottom: 15px; /* Moved up slightly to reduce overall height */
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: space-between;
}

/* Carousel arrow styling */
.header-carousel .owl-nav .owl-prev,
.header-carousel .owl-nav .owl-next {
    width: 40px; /* Fixed width */
    height: 40px; /* Fixed height */
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary); /* Theme color for the arrows */
    background: none; /* Remove background color */
    border: none; /* Remove border to avoid oval effect */
    border-radius: 0; /* Ensure no border radius is applied */
    font-size: 2.5rem; /* Set a consistent font size for arrow icons */
    transition: color 0.3s;
    opacity: 1; /* Ensure visibility */
    visibility: visible; /* Ensure visibility */
    z-index: 1000;
    outline: none !important;
}

/* Hover effect */
.header-carousel .owl-nav .owl-prev:hover,
.header-carousel .owl-nav .owl-next:hover {
    color: #0056b3; /* Darker color on hover for visibility */
}

/* Positioning */
.header-carousel .owl-nav .owl-prev {
    left: -30px; /* Adjust positioning if needed */
}

.header-carousel .owl-nav .owl-next {
    right: -30px; /* Adjust positioning if needed */
}

/* Custom arrow content */
.header-carousel .owl-nav .owl-prev::before,
.header-carousel .owl-nav .owl-next::before {
    color: inherit; /* Inherit color from the button */
}

.header-carousel .owl-nav .owl-prev::before {
    content: '\2039'; /* Unicode for left arrow */
}

.header-carousel .owl-nav .owl-next::before {
    content: '\203A'; /* Unicode for right arrow */
}

.header-carousel .owl-dots {
    position: absolute;
    height: 30px; 
    bottom: 15px; 
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-carousel .owl-dot {
    position: relative;
    display: inline-block;
    margin: 0 5px;
    width: 12px; 
    height: 12px;
    background: transparent;
    border: 1px solid #FFFFFF;
    border-radius: 12px;
    transition: .5s;
}

/*.header-carousel .owl-dot::after {
    position: absolute;
    content: "";
    width: 4px; 
    height: 4px;
    top: 4px;
    left: 4px;
    background: #FFFFFF;
    border-radius: 4px;
}*/

.header-carousel .owl-dot.active {
    background: var(--primary);
    border-color: var(--primary);
}

.page-header {
    background: url(../img/header-page.jpg) top center no-repeat;
    background-size: cover;
    text-shadow: 0 0 30px rgba(0, 0, 0, .1);
    height: 200px; /* Example for smaller background section */
}

.breadcrumb-item + .breadcrumb-item::before {
    color: var(--light);
}

.header-carousel .owl-carousel-item img {
    width: 100%;              /* Make the image span the full width */
    height: 100%;             /* Ensure the image fills the height */
    object-fit: cover;        /* Ensures the image covers the area without leaving background visible */
    object-position: center;  /* Centers the image within its container */
    border-radius: 0;         /* Optional: remove border radius if you want a sharp edge */
}

.header-carousel .owl-carousel-item {
    height: 400px; /* Set a fixed height to ensure consistent behavior */
}

@media (max-width: 768px) {
    .header-carousel .owl-carousel-item {
        height: 300px; /* Adjust for smaller screens */
    }
}

@media (max-width: 576px) {
    .header-carousel .owl-carousel-item {
        height: 250px; /* Further adjustment for very small screens */
    }
}

.header h1 {
    font-size: 3rem; /* Adjusted font size for the main header */
}

.header-carousel .owl-carousel-item .owl-carousel-text h1 {
    font-size: 2.5rem; /* Adjusted font size for carousel text */
}

/*** Service ***/
.service-item {
    transition: .5s;
}

.service-item:hover {
    margin-top: -10px;
    box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .08);
}

.service-item .btn {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    background: #FFFFFF;
    border-radius: 40px;
    white-space: nowrap;
    overflow: hidden;
    transition: .5s;
}

.service-item:hover .btn {
    width: 140px;
}


/*** Feature Mobile Optimization ***/
@media (max-width: 767px) {
    #whyus {
        padding: 0;
        overflow: hidden;
    }
    
    #whyus .container {
        padding: 0 !important; /* Remove container padding on mobile */
    }
    
    #whyus .row {
        margin: 0 !important; /* Remove row margin on mobile */
    }

    #whyus .feature-text {
        padding: 1rem;
        text-align: center;
    }
    
    #whyus h1 {
        font-size: 1.75rem;
        margin-bottom: 1rem;
    }
    
    #whyus p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    #whyus .col-6 {
        flex: 0 0 100%;
        max-width: 100%;
        margin-bottom: 1rem;
    }
    
    #whyus .col-6 .d-flex {
        justify-content: center;
    }

    #whyus .feature-text .row .d-flex {
        padding: 0.5rem;
    }

    #whyus .feature-text h5, #whyus .feature-text p {
        text-align: center;
    }
    
    #whyus .feature-text .rounded-circle {
        width: 45px;
        height: 45px;
    }

    #whyus .col-lg-6.pe-lg-0 {
        min-height: 250px;
        max-width: 100%;
        flex: 0 0 100%;
        padding: 0;
    }

    #whyus .position-relative img {
        width: 100vw;
        height: auto;
        object-fit: cover;
    }
}

/*** Team ***/
.hearing-aid-item img {
    width: auto; /* Maintain aspect ratio */
    height: 300px; /* Keep consistent image height */
    max-width: 100%; /* Ensure the image doesn't exceed the container */
    object-fit: contain; /* Ensure the image fits inside the container without being distorted */
    position: relative;
    top: 0;
    transition: transform 0.5s ease; /* Smooth hover transition */
}

.hearing-aid-item:hover img {
    transform: translateY(-10px); /* Slide image up on hover */
}

.hearing-aid-item {
    display: flex;
    flex-direction: column; /* Align content vertically */
    align-items: center; /* Center the content */
    justify-content: space-between; /* Distribute space evenly */
    height: 100%; /* Ensure the item takes full height */
}

.hearing-aid-text {
    text-align: center;
    margin-top: 10px;
    padding: 15px 20px; /* Add horizontal padding to make the text section wider */
    width: 100%; /* Allow the text section to expand to its full width */
    max-width: 300px; /* Set a maximum width for the text section to control the width */
    background-color: #f8f9fa; /* Optional: Add background color */
    flex-grow: 1; /* Allow text container to grow */
}

.hearing-aid-item .hearing-aid-text {
    position: relative;
    transition: .5s;
}

.hearing-aid-item:hover .hearing-aid-text {
    margin-top: -10px; /* Slight hover effect for the text section */
}

.hearing-aid-item .hearing-aid-text .btn {
    display: inline-flex;
    color: var(--primary);
    background: #FFFFFF;
    border-radius: 40px;
}

.hearing-aid-item .hearing-aid-text .btn:hover {
    color: #FFFFFF;
    background: var(--primary);
}

/* General arrow styling for both desktop and mobile */
.owl-carousel .owl-nav .owl-prev,
.owl-carousel .owl-nav .owl-next {
    width: auto;
    height: auto;
    background: none; /* No background */
    border: none; /* No border */
    color: var(--primary); /* Set color to theme */
    font-size: 3rem; /* Same font size */
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: color 0.3s ease;
    opacity: 1; /* Always visible */
    visibility: visible; /* Ensure visibility */
    z-index: 1000;
}

/* Hover effect for both desktop and mobile */
.owl-carousel .owl-nav .owl-prev:hover,
.owl-carousel .owl-nav .owl-next:hover {
    color: #0056b3; /* Change arrow color on hover */
}

/* Position adjustments for arrows on desktop */
.owl-carousel .owl-nav .owl-prev {
    left: -40px; /* Adjust position */
}

.owl-carousel .owl-nav .owl-next {
    right: -40px; /* Adjust position */
}

/* Custom arrow content for both desktop and mobile */
.owl-carousel .owl-nav .owl-prev::before,
.owl-carousel .owl-nav .owl-next::before {
    color: inherit; /* Use inherited color */
}

.owl-carousel .owl-nav .owl-prev::before {
    content: '\2039'; /* Left arrow */
}

.owl-carousel .owl-nav .owl-next::before {
    content: '\203A'; /* Right arrow */
}

/* Hide Bootstrap's default arrows */
.bi-chevron-right,
.bi-chevron-left {
    display: none;
}

/* Mobile-specific positioning */
@media (max-width: 768px) {
    .owl-carousel .owl-nav .owl-prev {
        left: 10px; /* Aligns the left arrow in view on mobile */
    }

    .owl-carousel .owl-nav .owl-next {
        right: 10px; /* Aligns the right arrow in view on mobile */
    }
}

/*** Testimonial ***/
.testimonial-carousel::before {
    position: absolute;
    content: "";
    top: 0;
    left: 0;
    height: 100%;
    width: 0;
    background: linear-gradient(to right, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
    z-index: 1;
}

.testimonial-carousel::after {
    position: absolute;
    content: "";
    top: 0;
    right: 0;
    height: 100%;
    width: 0;
    background: linear-gradient(to left, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
    z-index: 1;
}

@media (min-width: 768px) {
    .testimonial-carousel::before,
    .testimonial-carousel::after {
        width: 200px;
    }
}

@media (min-width: 992px) {
    .testimonial-carousel::before,
    .testimonial-carousel::after {
        width: 300px;
    }
}

.testimonial-carousel .owl-item .testimonial-text {
    background: var(--light);
    transform: scale(.8);
    transition: .5s;
}

.testimonial-carousel .owl-item.center .testimonial-text {
    background: var(--primary);
    transform: scale(1);
}

.testimonial-carousel .owl-item .testimonial-text *,
.testimonial-carousel .owl-item .testimonial-item img {
    transition: .5s;
}

.testimonial-carousel .owl-item.center .testimonial-text * {
    color: var(--light) !important;
}

.testimonial-carousel .owl-item.center .testimonial-item img {
    background: var(--primary) !important;
} 

.testimonial-carousel .owl-nav {
    position: absolute;
    width: 350px;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: space-between;
    opacity: 1; /* Set opacity to 1 to keep arrows visible */
    z-index: 1;
}

.testimonial-carousel:hover .owl-nav {
    width: 300px;
    opacity: 1;
}

.testimonial-carousel .owl-nav .owl-prev,
.testimonial-carousel .owl-nav .owl-next {
    position: relative;
    color: var(--primary);
    font-size: 45px;
    transition: .5s;
}

.testimonial-carousel .owl-nav .owl-prev:hover,
.testimonial-carousel .owl-nav .owl-next:hover {
    color: var(--dark);
}

.bi-arrow-right,
.bi-arrow-left {
    display: none;
}

/*** Footer ***/
.footer .btn.btn-social {
    margin-right: 5px;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    border: 1px solid #FFFFFF;
    transition: .3s;
}

.footer .btn.btn-social:hover {
    color: var(--primary);
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: #FFFFFF;
    font-size: 15px;
    font-weight: normal;
    text-transform: capitalize;
    transition: .3s;
}

.footer .btn.btn-link::before {
    position: relative;
    content: "\f105";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 10px;
}

.footer .btn.btn-link:hover {
    color: var(--primary);
    letter-spacing: 1px;
    box-shadow: none;
}

.footer .copyright {
    padding: 25px 0;
    font-size: 15px;
    border-top: 1px solid rgba(256, 256, 256, .1);
}

.footer .copyright a {
    color: var(--light);
}

.footer .copyright a:hover {
    color: var(--primary);
}

/* Scoped styles for hearing aid page */
.hearing-aid-page {
    margin-top: 30px;
    padding: 20px;
}

.hearing-aid-img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Adjustments for characteristics */
.hearing-aid-page h2 {
    color: #0463FA;
    font-weight: bold;
}

.hearing-aid-page ul {
    list-style-type: disc;
    padding-left: 20px;
}

/* Carousel for similar hearing aids */
.similar-hearing-aids-carousel .hearing-aid-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.similar-hearing-aids-carousel img {
    max-width: 150px;
    height: auto;
}

.similar-hearing-aids-carousel p {
    margin-top: 10px;
    font-size: 1rem;
}

.similar-hearing-aids-carousel .owl-nav {
    display: none; /* Hide arrows if unnecessary */
}

/* Ensure smooth scroll for appointment */
a[href^="#"] {
    cursor: pointer;
    transition: color 0.3s ease-in-out;
}

#hearingAidCarousel {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.carousel-item img {
    max-width: 100%;
    max-height: 450px;
    object-fit: contain;
}

/* Carousel Controls Always Visible */
.carousel-control-prev,
.carousel-control-next {
    display: flex !important;
    align-items: center;
    justify-content: center;
    color: var(--primary); /* Set arrow color to theme color */
    background: none; /* Remove background */
    border: none; /* Remove border */
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem; /* Adjust size of the arrow */
    opacity: 1 !important; /* Always fully visible */
    visibility: visible !important; /* Always visible */
    pointer-events: auto !important; /* Ensure controls are clickable */
}

/* Remove all transitions to keep arrows visible at all times */
.carousel-control-prev,
.carousel-control-next,
.carousel-control-prev-icon,
.carousel-control-next-icon {
    transition: none;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Custom content for the arrows */
.carousel-control-prev-icon::before,
.carousel-control-next-icon::before {
    color: inherit;
    content: '\2039'; /* Left arrow for previous */
}

.carousel-control-next-icon::before {
    content: '\203A'; /* Right arrow for next */
}

/* Adjust dot indicators styling */
.carousel-indicators [data-bs-target] {
    width: 15px;
    height: 15px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    transition: background-color 0.3s;
}

.carousel-indicators .active {
    background-color: var(--primary); /* Highlight active dot */
}

.carousel-indicators {
    bottom: -60px; /* Position dots slightly below the carousel */
}

/* Ensures visibility of arrows on click */
.carousel-control-prev-icon, 
.carousel-control-next-icon {
    opacity: 1 !important;
    visibility: visible !important;
    background-image: none !important; /* Remove any Bootstrap background images */
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    color: #0056b3; /* Darker color on hover for visibility */
}

/*** Map Container Padding Adjustment on Mobile ***/
@media (max-width: 767px) {
    #contact .col-lg-6 .bg-light {
        padding: 0 !important; /* Remove padding only around the map section */
    }

    #contact iframe {
        height: 400px !important; /* Increase map height for better visibility on mobile */
        width: 100% !important; /* Ensure it takes full width */
    }

    /* Add padding back to the contact information containers */
    #contact .col-lg-6:first-child .bg-light {
        padding: 1.5rem !important; /* Adjust padding for contact details */
    }
}

@media (max-width: 767px) {
    .row.g-5 {
        flex-direction: column;
    }

    .col-lg-6 {
        order: unset;
        margin-top: 20px;
    }

    .info-section {
        margin-top: 20px;
    }

    .features-section {
        margin-top: 20px;
    }
}

.carousel-item img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Default layout for smaller screens */
.info-features-container {
    display: block;
    margin-top: 20px;
}

.features-section h3 {
    margin-top: 20px; /* Minimal margin for small screens */
}

/* Medium screens (768px and up) */
@media (min-width: 768px) {
    .info-features-container {
        display: flex;
        flex-direction: column; /* Stack the sections vertically */
    }

    .info-section,
    .features-section {
        flex-basis: 100%; /* Take up full width in each column */
    }

    .features-section h3 {
        margin-top: 30px; /* Adjust spacing for medium screens */
    }
}

/* Large screens (992px and up) */
@media (min-width: 992px) {
    .info-features-container {
        display: flex;
        align-items: flex-start;
        gap: 2rem; /* Space between sections */
    }

    .info-section,
    .features-section {
        flex-basis: 50%; /* Each section takes up half of the container */
    }

    .features-section h3 {
        margin-top: 50px; /* Align Xüsusiyyətlər heading with Kind Rega R heading */
    }

    .info-section h1 {
        margin-top: 0; /* Align heading to the top */
    }
}

/* Extra-large screens (1200px and up) */
@media (min-width: 1200px) {
    .features-section h3 {
        margin-top: 70px; /* Additional margin for larger screens if needed */
    }
}