/********** Template CSS **********/
:root {
    --primary: #3185bf;
    --secondary: #354F8E;
    --light: #EFF5F9;
    --dark: #1D2A4D;
}

.btn {
    font-weight: 700;
    transition: .5s;
}

.btn:hover {
    -webkit-box-shadow: 0 8px 6px -6px #555555;
    -moz-box-shadow: 0 8px 6px -6px #555555;
    box-shadow: 0 8px 6px -6px #555555;
}

.btn-primary {
    color: #FFFFFF;
}

.btn-primary:hover,
.btn-primary:active,
.btn-primary:focus {
    background-color: #ffffff !important;
    color: var(--primary) !important;
    border-color: #ffffff !important;
    box-shadow: 0 8px 15px rgba(0,0,0,0.15) !important;
}

/* Specific fix for buttons in services/diseases/team to ensure white background on hover */
.service-item a.btn:hover,
.team-item .text-center a.btn:hover,
.team-item a.btn:hover,
.back-to-top:hover {
    background-color: #ffffff !important;
    color: var(--primary) !important;
}

.btn-square {
    width: 36px;
    height: 36px;
}

.btn-sm-square {
    width: 28px;
    height: 28px;
}

.btn-lg-square {
    width: 46px;
    height: 46px;
}

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: normal;
}

.back-to-top {
    position: fixed;
    display: none;
    right: 30px;
    bottom: 0;
    border-radius: 50% 50% 0 0;
    z-index: 99;
}

/* Floating mobile buttons (справа внизу) */
.floating-mobile-btns {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 1040;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
}

.floating-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.floating-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* Кнопка відгуків - золота */
.floating-btn-reviews {
    height: 50px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #000;
    border: none;
    border-radius: 25px;
    padding: 0 20px;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
}

.floating-btn-reviews:hover {
    color: #000;
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.5);
}

/* Кнопка запису - подовжена */
.floating-btn-appointment {
    height: 50px;
    background-color: var(--secondary);
    color: #fff;
    border-radius: 25px;
    padding: 0 24px;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.floating-btn-appointment:hover {
    color: #fff;
    background-color: var(--primary);
}

@media (max-width: 991.98px) {
    .back-to-top {
        right: 20px;
        bottom: 150px !important;
    }
    
    /* Виправлення мобільного меню */
    .navbar-collapse {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        padding: 15px 20px;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        z-index: 1000;
        max-height: calc(100vh - 80px);
        overflow-y: auto;
    }
    
    .navbar-collapse .navbar-nav {
        flex-direction: column;
        align-items: flex-start !important;
    }
}

@media (max-width: 400px) {
    .floating-mobile-btns {
        right: 15px;
        bottom: 15px;
    }
    
    .floating-btn-reviews {
        height: 46px;
        padding: 0 16px;
        font-size: 13px;
    }
    
    .floating-btn-appointment {
        height: 46px;
        padding: 0 18px;
        font-size: 13px;
    }
}

.navbar-light .navbar-nav .nav-link {
    font-family: 'Jost', sans-serif;
    position: relative;
    margin-left: 15px;
    padding: 15px 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--dark);
    outline: none;
    transition: .5s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    line-height: 1.2;
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link.active {
    color: var(--primary);
}

@media (min-width: 992px) {
    .navbar-light .navbar-nav .nav-link::before {
        position: absolute;
        content: "";
        width: 0;
        height: 3px;
        bottom: 8px;
        left: 50%;
        background: var(--primary);
        transition: .5s;
    }

    .navbar-light .navbar-nav .nav-link:hover::before,
    .navbar-light .navbar-nav .nav-link.active::before {
        width: calc(100% - 16px);
        left: 8px;
    }
}

.navbar-light .navbar-nav {
    align-items: center;
}

.navbar-light .navbar-nav .nav-item {
    display: flex;
    align-items: center;
}

.navbar {
    padding: 0.5rem 0 !important;
    flex-wrap: nowrap;
}

.logo-img {
    height: 35px;
    max-width: 250px;
    width: auto;
    transition: .5s;
}

.navbar-brand {
    flex-shrink: 0;
}

/* Мобільні кнопки в хедері */
.mobile-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Кнопка телефону */
.mobile-actions .btn-mobile-phone {
    width: 38px;
    height: 38px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    font-size: 16px;
}

/* Кнопка запису */
.mobile-actions .btn-mobile-appointment {
    height: 38px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Вирівнювання navbar-toggler */
@media (max-width: 991.98px) {
    .navbar-toggler {
        width: 38px;
        height: 38px;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 4px;
        border: 1px solid #dee2e6;
    }
    
    .logo-img {
        height: 30px;
        max-width: 150px;
    }
}

@media (max-width: 575.98px) {
    .logo-img {
        height: 28px;
        max-width: 110px;
    }
    
    .mobile-actions {
        gap: 6px;
    }
    
    .mobile-actions .btn-mobile-phone {
        width: 36px;
        height: 36px;
        font-size: 15px;
    }
    
    .mobile-actions .btn-mobile-appointment {
        height: 36px;
        padding: 0 10px;
        font-size: 10px;
    }
    
    .navbar-toggler {
        width: 36px !important;
        height: 36px !important;
    }
}

@media (max-width: 380px) {
    .logo-img {
        height: 24px;
        max-width: 90px;
    }
    
    .mobile-actions .btn-mobile-phone {
        width: 34px;
        height: 34px;
    }
    
    .mobile-actions .btn-mobile-appointment {
        height: 34px;
        padding: 0 8px;
        font-size: 9px;
    }
    
    .navbar-toggler {
        width: 34px !important;
        height: 34px !important;
    }
}

.navbar-brand h1 {
    font-size: 1.5rem;
    margin: 0;
}

.navbar-brand .fa-clinic-medical {
    font-size: 1.3rem;
}

@media (max-width: 991.98px) {
    .navbar-light .navbar-nav .nav-link  {
        margin-left: 0;
        padding: 10px 0;
    }
}

.hero-header {
    background: url(../img/hero.jpg) top right no-repeat;
    background-size: cover;
}

/* Hero Full Width - Modern Style */
.hero-header-fullwidth {
    width: 100%;
    min-height: 600px;
    display: flex;
    align-items: center;
    margin-top: 0;
    margin-bottom: 0;
}

.hero-modern {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.hero-content-left {
    padding: 30px 35px;
    background: rgba(0, 40, 80, 0.45);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.hero-subtitle {
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 2px;
    display: inline-block;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    margin-bottom: 25px !important;
}

.hero-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.5px;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.35);
    margin-bottom: 20px !important;
}

.hero-buttons {
    margin-top: 20px;
}

/* Фонове відео слайдера */
.hero-bg-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}

/* Фоновий embed (YouTube/Vimeo) */
.hero-bg-embed {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 177.78vh; /* 16:9 */
    height: 56.25vw; /* 16:9 */
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.hero-bg-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Права панель слайдера — дзеркально лівій */
.hero-right-info {
    padding: 22px 28px;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
    color: #1a2a4a;
}

.hero-right-subtitle {
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #354F8E;
    padding-bottom: 8px;
    border-bottom: 2px solid rgba(53, 79, 142, 0.25);
    margin-bottom: 14px;
}

.hero-right-cta {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a2a4a;
    margin-bottom: 12px;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 10px;
}

.hero-right-cta .hero-ear-icon {
    width: 42px;
    height: 42px;
    background: #354F8E;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.hero-right-cta .hero-ear-icon i {
    color: #fff;
    font-size: 1rem;
}

.hero-right-phone {
    font-size: 0.95rem;
    font-weight: 600;
    color: #354F8E;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.hero-right-address {
    font-size: 0.88rem;
    color: #4a5568;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}


@media (max-width: 992px) {
    .hero-right-info {
        padding: 16px 18px;
    }
}

@media (max-width: 768px) {
    .hero-right-info {
        padding: 12px 14px;
        border-radius: 12px;
    }
}

.btn-hero-primary,
.btn-hero-secondary {
    padding: 14px 35px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

.btn-hero-primary {
    background-color: #ffffff;
    color: #354F8E;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.btn-hero-primary:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    color: #354F8E;
}

.btn-hero-secondary {
    background-color: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.8);
}

.btn-hero-secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
    color: #ffffff;
    transform: translateY(-2px);
}

@media (max-width: 1200px) {
    .hero-title {
        font-size: 2rem;
    }
    .hero-content-left {
        padding: 25px 28px;
    }
}

@media (max-width: 992px) {
    .hero-header-fullwidth {
        min-height: 500px;
    }
    .hero-content-left {
        padding: 22px 22px;
        margin-bottom: 40px;
    }
    .hero-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .hero-header-fullwidth {
        min-height: 450px;
        padding: 60px 30px !important;
    }
    .hero-content-left {
        padding: 20px 18px;
        border-radius: 14px;
        overflow-y: auto;
    }
    .hero-title {
        font-size: 1.6rem;
        margin-bottom: 15px !important;
    }
    .hero-subtitle {
        font-size: 0.8rem;
        margin-bottom: 12px !important;
    }
    .hero-content-left .text-white.mb-3 {
        font-size: 15px !important;
        margin-bottom: 10px !important;
    }
    .btn-hero-primary,
    .btn-hero-secondary {
        padding: 10px 22px;
        font-size: 0.9rem;
        display: block;
        width: 100%;
        margin-bottom: 10px !important;
    }
    .hero-buttons {
        margin-top: 15px;
    }
}

.service-item {
    position: relative;
    height: 350px;
    padding: 0 30px;
    transition: .5s;
}

.service-item .service-icon {
    width: 150px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border-radius: 50%;
    transform: rotate(-14deg);
}

.service-item .service-icon i {
    transform: rotate(15deg);
}

.service-item a.btn {
    position: absolute;
    width: 60px;
    bottom: -48px;
    left: 50%;
    margin-left: -30px;
    opacity: 0;
}

.service-item:hover a.btn {
    bottom: -12px;
    opacity: 1;
}

.team-item {
    position: relative;
    transition: .5s;
}

.team-item .text-center {
    position: relative;
}

.team-item .text-center a.btn {
    position: absolute;
    width: 60px;
    bottom: -48px;
    left: 50%;
    margin-left: -30px;
    opacity: 0;
    transition: .5s;
    z-index: 10;
}

.team-item:hover .text-center a.btn {
    bottom: -12px;
    opacity: 1;
}

/* Стилі для секцій головної сторінки */
.home-section-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.home-section-content h2,
.home-section-content h3,
.home-section-content h4 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #3185bf;
}

.home-section-content p {
    margin-bottom: 1.5rem;
}

.home-section-content ul,
.home-section-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.home-section-content li {
    margin-bottom: 0.5rem;
}

.home-section-content strong {
    color: #354F8E;
    font-weight: 600;
}

/* Стилі для зображень в контенті */
.home-section-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.content-image-wrapper {
    text-align: center;
    margin: 2rem 0;
}

.content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.price-carousel::after {
    position: absolute;
    content: "";
    width: 100%;
    height: 50%;
    bottom: 0;
    left: 0;
    background: var(--primary);
    border-radius: 8px 8px 50% 50%;
    z-index: -1;
}

.price-carousel .owl-nav {
    margin-top: 35px;
    width: 100%;
    text-align: center;
    display: flex;
    justify-content: center;
}

.price-carousel .owl-nav .owl-prev,
.price-carousel .owl-nav .owl-next{
    position: relative;
    margin: 0 5px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    background: #FFFFFF;
    font-size: 22px;
    border-radius: 45px;
    transition: .5s;
}

.price-carousel .owl-nav .owl-prev:hover,
.price-carousel .owl-nav .owl-next:hover {
    color: var(--dark);
}

@media (min-width: 576px) {
    .team-item .row {
        height: 350px;
    }
}

.team-carousel .owl-nav {
    position: absolute;
    padding: 0 45px;
    width: 100%;
    height: 45px;
    top: calc(50% - 22.5px);
    left: 0;
    display: flex;
    justify-content: space-between;
}

.team-carousel .owl-nav .owl-prev,
.team-carousel .owl-nav .owl-next {
    position: relative;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    background: var(--primary);
    border-radius: 45px;
    font-size: 22px;
    transition: .5s;
}

.team-carousel .owl-nav .owl-prev:hover,
.team-carousel .owl-nav .owl-next:hover {
    background: var(--dark);
}

.testimonial-carousel .owl-dots {
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.testimonial-carousel .owl-dot {
    position: relative;
    display: inline-block;
    margin: 0 5px;
    width: 20px;
    height: 20px;
    background: var(--light);
    border: 2px solid var(--primary);
    border-radius: 20px;
    transition: .5s;
}

.testimonial-carousel .owl-dot.active {
    width: 40px;
    height: 40px;
    background: var(--primary);
}

.testimonial-carousel .owl-item img {
    width: 150px;
    height: 150px;
}

.testimonial-carousel .owl-item img {
    width: 150px;
    height: 150px;
}

/* --- Плавна анімація появи (Reveal Animation) --- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(80px);
    transition: all 1.5s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, opacity;
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Затримки для каскадного ефекту */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }




