/* Harmony Clinic — Common Styles */
:root {
    --header-bg: #000000;
    --header-text: #ffffff;
    --primary: #526154;
    --primary-dark: #3c493d;
    --text-dark: #222222;
    --text-grey: #555555;
    --bg-light: #f9f9f9;
    --border: #e5e5e5;
    --radius: 25px;
    --radius-btn: 50px;

    /* Minimalist Luxury — Shadow System */
    --shadow-card: 0 2px 8px rgba(0, 0, 0, 0.04), 0 8px 24px rgba(0, 0, 0, 0.06);
    --shadow-card-hover: 0 4px 12px rgba(0, 0, 0, 0.06), 0 16px 40px rgba(0, 0, 0, 0.10);
    --shadow-card-subtle: 0 1px 4px rgba(0, 0, 0, 0.03), 0 4px 16px rgba(0, 0, 0, 0.05);
}
html { scroll-behavior: smooth; scroll-padding-top: 100px; }
* { margin: 0; padding: 0; box-sizing: border-box; }
picture { display: contents; }
img, svg, video { max-width: 100%; height: auto; }

/* Skip link — visible only when focused from the keyboard (WCAG 2.4.1) */
.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 10000;
    padding: 12px 20px;
    background: var(--primary, #526154);
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    border-radius: 0 0 8px 0;
    text-decoration: none;
}
.skip-link:focus,
.skip-link:focus-visible {
    left: 0;
    outline: 3px solid #fff;
    outline-offset: -6px;
}

body { font-family: 'Manrope', sans-serif; color: var(--text-dark); background-color: #ffffff; line-height: 1.6; overflow-x: hidden; }
a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }
.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
h2.section-title { font-size: 32px; font-weight: 800; text-align: center; margin-bottom: 40px; color: var(--text-dark); }

.btn-primary { background: var(--primary); color: #fff; padding: 18px 40px; border-radius: var(--radius-btn); font-weight: 700; text-transform: uppercase; font-size: 14px; display: inline-block; border: none; cursor: pointer; transition: 0.4s; text-align: center; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-3px); box-shadow: 0 10px 25px rgba(82, 97, 84, 0.4); }

/* Header */
header { background-color: var(--header-bg); color: var(--header-text); padding: 15px 0; position: sticky; top: 0; z-index: 1000; border-bottom: 1px solid #222; }
.nav-wrapper { display: flex; justify-content: space-between; align-items: center; }
.logo img { width: auto; height: auto; max-height: 60px; filter: brightness(0) invert(1); }
.nav-menu { display: flex; gap: 20px; font-size: 14px; font-weight: 700; text-transform: uppercase; }
.nav-menu a { color: #ffffff; }
.nav-menu a:hover { color: var(--primary); }
.header-phone { color: #fff; font-weight: 700; border: 1px solid #fff; padding: 8px 15px; border-radius: 4px; font-size: 13px; white-space: nowrap; }
.header-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; flex-wrap: nowrap; }

/* ====== Language switcher (UA / RU) ====== */
.lang-switcher { display: flex; gap: 6px; align-items: center; }
.lang-switcher a { color: #fff; text-decoration: none; font-size: 12px; font-weight: 700; padding: 5px 11px; border: 1px solid rgba(255,255,255,0.55); border-radius: 50px; transition: 0.3s; line-height: 1; letter-spacing: 0.5px; }
.lang-switcher a.active, .lang-switcher a:hover { background: #fff; color: var(--primary); border-color: #fff; }
@media (max-width: 768px) { .lang-switcher a { padding: 4px 9px; font-size: 11px; } }

/* ====== UNIFIED MOBILE MENU ====== */
.mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.14);
    color: #fff;
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
    transition: background 0.25s ease, transform 0.2s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}
.mobile-toggle:hover { background: rgba(255,255,255,0.12); }
.mobile-toggle:active { transform: scale(0.95); }

.mobile-menu-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}
.mobile-menu-backdrop.active { opacity: 1; visibility: visible; }

.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 86%;
    max-width: 360px;
    height: 100vh;
    height: 100dvh;
    background: linear-gradient(180deg, #0a0a0a 0%, #1a1a1a 100%);
    color: #fff;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    padding: 22px 22px 26px;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -20px 0 60px rgba(0,0,0,0.45);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.mobile-menu.active { transform: translateX(0); }

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 18px;
    margin-bottom: 14px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
}
.mobile-menu-logo { display: inline-flex; align-items: center; }
.mobile-menu-logo img {
    height: 38px;
    width: auto;
    filter: brightness(0) invert(1);
}
.mobile-menu .close-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    color: #fff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.25s ease, transform 0.35s ease, border-color 0.25s ease;
    border: 1px solid rgba(255,255,255,0.1);
    padding: 0;
    font-family: inherit;
    position: static;
}
.mobile-menu .close-btn:hover {
    background: var(--primary);
    transform: rotate(90deg);
    border-color: var(--primary);
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}
.mobile-menu-nav a {
    color: #fff;
    font-size: 15.5px;
    font-weight: 600;
    letter-spacing: 0.2px;
    padding: 13px 14px;
    border-radius: 12px;
    transition: background 0.25s ease, color 0.25s ease, padding-left 0.25s ease;
    display: flex;
    align-items: center;
    position: relative;
    text-transform: none;
}
.mobile-menu-nav a::before {
    content: '';
    width: 0;
    height: 18px;
    background: var(--primary);
    border-radius: 2px;
    margin-right: 0;
    transition: width 0.25s ease, margin-right 0.25s ease, opacity 0.25s ease;
    opacity: 0;
    flex-shrink: 0;
}
.mobile-menu-nav a:hover,
.mobile-menu-nav a:active,
.mobile-menu-nav a.current {
    background: rgba(82, 97, 84, 0.18);
}
.mobile-menu-nav a:hover::before,
.mobile-menu-nav a:active::before,
.mobile-menu-nav a.current::before {
    width: 3px;
    margin-right: 10px;
    opacity: 1;
}

.mobile-menu-footer {
    padding-top: 16px;
    margin-top: 14px;
    border-top: 1px solid rgba(255,255,255,0.08);
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
}
.mobile-menu-phone {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 16px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50px;
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    transition: background 0.25s ease, border-color 0.25s ease;
}
.mobile-menu-phone svg { flex-shrink: 0; }
.mobile-menu-phone:hover {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.4);
    color: #fff;
}
.mobile-menu-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    background: var(--primary);
    color: #fff;
    border-radius: 50px;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    transition: background 0.25s ease, transform 0.25s ease;
}
.mobile-menu-cta:hover, .mobile-menu-cta:active {
    background: var(--primary-dark);
    transform: translateY(-2px);
    color: #fff;
}

body.menu-open { overflow: hidden; }

/* Booking strip */
.booking-strip { padding: 50px 0; background: #fff; text-align: center; border-bottom: 1px solid var(--border); }
.booking-buttons { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; margin-top: 25px; }
.btn-msg { display: flex; align-items: center; gap: 8px; padding: 12px 32px; border-radius: 50px; font-weight: 700; font-size: 14px; color: #fff; transition: 0.3s; cursor: pointer; background: var(--primary); border: none; }
.btn-msg svg { width: 20px; height: 20px; fill: currentColor; }
.btn-msg:hover { background: var(--primary-dark); transform: translateY(-3px); box-shadow: 0 8px 20px rgba(82, 97, 84, 0.3); }

/* Common section patterns */
.types-section, .advantages-section { padding: 100px 0; background: var(--bg-light); }
.types-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 25px; }
.type-item { padding: 35px 25px; background: #fff; border-radius: var(--radius); border: none; box-shadow: var(--shadow-card); transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.type-item:hover { transform: translateY(-5px); box-shadow: var(--shadow-card-hover); }
.type-item h3 { margin-bottom: 12px; font-weight: 800; font-size: 20px; color: var(--primary); }
.type-item p { color: var(--text-grey); font-size: 15px; }

.steps-section { padding: 100px 0; background: #fff; }
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 25px; }
.step-item { padding: 40px 30px; background: #fff; border-radius: var(--radius); border: none; box-shadow: var(--shadow-card); transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.step-item:hover { transform: translateY(-5px); box-shadow: var(--shadow-card-hover); }
.step-number { color: var(--primary); font-size: 13px; font-weight: 800; text-transform: uppercase; margin-bottom: 10px; display: block; }
.step-item h3 { margin-bottom: 15px; font-weight: 800; font-size: 20px; }

/* FAQ accordion */
.info-accordion { padding: 80px 0; background: var(--bg-light); }
.accordion-item { background: #fff; margin-bottom: 15px; border-radius: var(--radius); border: none; box-shadow: var(--shadow-card-subtle); overflow: hidden; transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); }
.accordion-item:hover { box-shadow: var(--shadow-card); }
.accordion-header { width: 100%; box-sizing: border-box; border: 0; background: transparent; text-align: left;
    font-family: inherit; padding: 25px; cursor: pointer; display: flex; justify-content: space-between;
    align-items: center; gap: 12px; font-weight: 800; font-size: 19px; color: var(--primary); }
/* Не сжимаем только иконку «+» справа; текст слева должен уметь сжиматься,
   иначе длинный заголовок выталкивает иконку за пределы экрана. */
.accordion-header > *:last-child { flex-shrink: 0; }
.accordion-header > *:first-child { min-width: 0; overflow-wrap: anywhere; }
.accordion-header:hover { background-color: #f0fdfa; }
.accordion-content { max-height: 0; overflow: hidden; transition: max-height 0.4s ease-out; }
.content-padding { padding: 0 25px 25px 25px; color: var(--text-grey); font-size: 15px; line-height: 1.7; }

/* Price table */
.prices { padding: 100px 0; background: #fff; }
.price-table { width: 100%; border-collapse: collapse; margin-top: 20px; background: #fff; border-radius: 15px; overflow: hidden; box-shadow: 0 10px 30px rgba(82, 97, 84, 0.1); }
.price-table th, .price-table td { padding: 18px 25px; text-align: left; border-bottom: 1px solid var(--border); }
.price-table th { background-color: var(--primary); color: #fff; text-transform: uppercase; font-size: 14px; }
.price-val { font-weight: 800; color: var(--primary); }

/* Footer */
.unified-footer { background: #000; color: #fff; padding: 60px 0 20px; text-align: left; }
.unified-footer .footer-content { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; text-align: left; }
.unified-footer h3 { color: #fff; margin-bottom: 20px; font-size: 18px; text-transform: uppercase; letter-spacing: 1px; }
.unified-footer p { color: #bbb; margin-bottom: 10px; font-size: 15px; }
.unified-footer .footer-logo-img { width: auto; height: 50px; filter: brightness(0) invert(1); margin-bottom: 15px; }
.unified-footer .social-icons { display: flex; gap: 15px; margin-top: 20px; }
.unified-footer .social-icons a { width: 40px; height: 40px; background: #222; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: 0.3s; color: #fff; border: 1px solid #333; }
.unified-footer .social-icons a:hover { background: #fff; color: #000; }
.unified-footer .social-icons svg { width: 20px; height: 20px; fill: currentColor; }
.unified-footer .footer-links a { color: #bbb; display: block; margin-bottom: 12px; text-decoration: none; font-size: 15px; transition: 0.3s; }
.unified-footer .footer-links a:hover { color: #fff; transform: translateX(5px); }
.unified-footer .copyright { text-align: center; padding-top: 30px; margin-top: 40px; border-top: 1px solid #222; color: #555; font-size: 13px; }

/* Floating widget */
.floating-widget { position: fixed; bottom: 30px; right: 25px; background-color: var(--primary); color: #fff; width: 60px; height: 60px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding: 0; text-decoration: none; box-shadow: 0 4px 15px rgba(82, 97, 84, 0.4); z-index: 1000; transition: transform 0.3s; animation: pulse-green 2s infinite; }
.floating-widget:hover { transform: scale(1.05); color: #fff; }
.floating-widget .widget-icon svg { width: 28px; height: 28px; fill: #fff; display: block; }
@keyframes pulse-green { 0% { box-shadow: 0 0 0 0 rgba(82, 97, 84, 0.7); } 70% { box-shadow: 0 0 0 15px rgba(82, 97, 84, 0); } 100% { box-shadow: 0 0 0 0 rgba(82, 97, 84, 0); } }

/* Responsive — common */
@media (max-width: 992px) {
    .nav-menu { display: none !important; }
    .mobile-toggle { display: flex !important; }
    .unified-footer .footer-content { grid-template-columns: 1fr; text-align: center; }
}
@media (max-width: 360px) {
    .mobile-menu { padding: 18px 16px 22px; }
    .mobile-menu-nav a { font-size: 15px; padding: 12px; }
    .mobile-menu-header { padding-bottom: 14px; margin-bottom: 10px; }
}
@media (max-width: 768px) {
    .footer-content { grid-template-columns: 1fr 1fr !important; gap: 25px !important; }
    .price-table { display: block; overflow-x: auto; }
    .floating-widget { bottom: 20px; right: 20px; width: 50px; height: 50px; }
    .floating-widget .widget-icon svg { width: 24px; height: 24px; }
    .booking-buttons { flex-direction: column; align-items: center; }
}
@media (max-width: 480px) {
    .footer-content { grid-template-columns: 1fr !important; gap: 20px !important; text-align: center !important; }
    .social-icons { justify-content: center; }
}


/* ===== Index Page Styles ===== */
/* КНОПКА ЗАПИСУ (Зменшена) */

        .hero {
            height: 100vh;
            min-height: 500px;
            background-image: url('images/clinic.jpg'); /* fallback for old browsers */
            background-image: -webkit-image-set(url('images/clinic-hero.webp') type('image/webp'), url('images/clinic.jpg') type('image/jpeg'));
            background-image: image-set(url('images/clinic-hero.webp') type('image/webp'), url('images/clinic.jpg') type('image/jpeg'));
            background-size: cover;
            background-position: center center;
            display: flex;
            align-items: center;
            justify-content: center;
            text-align: center;
            color: #ffffff;
        }

        /* Crisp high-res hero for large / retina screens */
        @media (min-width: 992px) {
            .hero {
                background-image: url('images/clinic.jpg');
                background-image: -webkit-image-set(url('images/clinic-hero-2x.webp') type('image/webp'), url('images/clinic.jpg') type('image/jpeg'));
                background-image: image-set(url('images/clinic-hero-2x.webp') type('image/webp'), url('images/clinic.jpg') type('image/jpeg'));
            }
        }

        /* Hero styles moved to .hero-slogan and .hero-sub */

        /* --- СТИЛІ КНОПОК МЕСЕНДЖЕРІВ --- */

        /* ------------------------------------------ */

        .features {
            padding: 80px 0;
            background: #fff;
        }

        .features-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 20px;
        }

        .feature-item {
            padding: 30px;
            background: #fff;
            border-radius: var(--radius);
            text-align: center;
            border: none;
            box-shadow: var(--shadow-card);
            transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        }

        .feature-item:hover {
            transform: translateY(-3px);
            box-shadow: var(--shadow-card-hover);
        }

        .feature-img {
            width: 60px;
            height: auto;
            margin-bottom: 15px;
        }

        .feature-item h3 {
            margin-bottom: 10px;
            font-weight: 700;
            font-size: 18px;
        }

        .about {
            padding: 80px 0;
            background: #fff;
        }

        .about-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 40px;
            align-items: center;
        }

        .about-img img {
            width: 70%;
            display: block;
            margin: 0 auto;
            border-radius: var(--radius);
        }

        .sterilization {
            padding: 80px 0;
            background: var(--bg-light);
        }

        .sterilization-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 60px;
            align-items: center;
        }

        .sterile-list li {
            display: flex;
            align-items: flex-start;
            gap: 15px;
            margin-bottom: 15px;
        }

        .check-icon {
            color: var(--primary);
            font-weight: 800;
            font-size: 18px;
        }

        .sterilization-img img {
            width: 100%;
            border-radius: var(--radius);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        }

        .digital {
            padding: 80px 0;
        }

        .digital-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 30px;
        }

        .digital-card {
            background: #fff;
            padding: 30px;
            border-radius: var(--radius);
            text-align: center;
            border: none;
            box-shadow: var(--shadow-card);
            transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        }

        .digital-card:hover {
            transform: translateY(-3px);
            box-shadow: var(--shadow-card-hover);
        }

        .digital-img {
            width: 100%;
            height: 220px;
            object-fit: cover;
            border-radius: var(--radius);
            margin-bottom: 20px;
        }

        .carousel-section {
            padding: 80px 0;
            background: #fff;
        }

        .carousel-wrapper {
            position: relative;
            max-width: 1140px;
            margin: 0 auto;
            padding: 0 45px;
        }

        .carousel-track-container {
            overflow: hidden;
        }

        .carousel-track {
            display: flex;
            transition: transform 0.5s ease-in-out;
        }

        .carousel-slide {
            padding: 10px;
            box-sizing: border-box;
            flex-shrink: 0;
        }

        .c-btn {
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
            background: #fff;
            border: 1px solid #ddd;
            width: 45px;
            height: 45px;
            border-radius: 50%;
            cursor: pointer;
            z-index: 10;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
            font-size: 20px;
        }

        .c-prev {
            left: 0;
        }

        .c-next {
            right: 0;
        }

        .team .carousel-slide {
            width: 33.333%;
        }

        .works .carousel-slide {
            width: 50%;
        }

        .reviews .carousel-slide {
            width: 33.333%;
        }

        .team-card,
        .case-card,
        .review-card {
            background: #fff;
            padding: 25px;
            border-radius: var(--radius);
            border: none;
            box-shadow: var(--shadow-card);
            height: 100%;
            display: flex;
            flex-direction: column;
            transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        }

        .team-card:hover,
        .case-card:hover,
        .review-card:hover {
            transform: translateY(-4px);
            box-shadow: var(--shadow-card-hover);
        }

        /* --- ВИПРАВЛЕНО: ФОТО ЛІКАРІВ --- */
        .team-photo {
            width: 100%;
            height: auto;
            /* Дозволяємо фото розтягуватися по висоті */
            aspect-ratio: 3/4;
            /* Фіксуємо портретну пропорцію */
            object-fit: cover;
            object-position: top center;
            /* Фіксуємо верх (обличчя), щоб не різало голову */
            border-radius: var(--radius);
            margin-bottom: 15px;
        }

        /* ------------------------------- */

        .photo-wrapper {
            position: relative;
            width: 100%;
        }

        .photo-wrapper img {
            width: 100%;
            aspect-ratio: 4/3;
            object-fit: cover;
            border-radius: 15px;
            border: 1px solid #eee;
        }

        .before-after-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            margin-top: 15px;
        }

        .label {
            position: absolute;
            top: 8px;
            left: 8px;
            background: rgba(0, 0, 0, 0.7);
            color: #fff;
            font-size: 11px;
            font-weight: 700;
            padding: 3px 8px;
            border-radius: 4px;
            text-transform: uppercase;
        }

        .review-card {
            text-align: left;
            background: #fff;
            justify-content: space-between;
            border: none;
        }

        .review-stars {
            color: #f59e0b;
            margin-bottom: 10px;
            font-size: 14px;
        }

        .review-text {
            font-size: 14px;
            font-style: italic;
            color: var(--text-grey);
            margin-bottom: 15px;
            flex-grow: 1;
            line-height: 1.5;
        }

        .review-author {
            font-weight: 700;
            color: var(--text-dark);
            display: block;
            margin-top: 10px;
        }

        .price-row {
            display: flex;
            justify-content: space-between;
            padding: 12px 20px;
            border-top: 1px solid #f9f9f9;
            font-size: 15px;
        }

        .map-section {
            width: 100%;
            height: auto;
            padding: 60px 0 0 0;
            background: #fff;
        }

        .map-section iframe {
            width: 100%;
            height: 450px;
            display: block;
            border: 0;
        }

        footer {
            background: #000;
            color: #fff;
            padding: 60px 0 20px;
        }

        .footer-content {
            display: grid;
            grid-template-columns: 1.5fr 1fr 1fr 1fr;
            gap: 40px;
        }

        .footer-logo img {
            height: 60px;
            filter: brightness(0) invert(1);
            margin-bottom: 20px;
        }

        .footer h3 {
            font-size: 18px;
            margin-bottom: 20px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .footer-links a {
            color: #bbb;
            display: block;
            margin-bottom: 12px;
        }

        .footer-links a:hover {
            color: #fff;
            transform: translateX(5px);
        }

        .social-icons {
            display: flex;
            gap: 15px;
            margin-top: 20px;
        }

        .social-icons a {
            width: 40px;
            height: 40px;
            background: #222;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            border: 1px solid #333;
            transition: 0.3s;
            color: #fff;
        }

        .social-icons a:hover {
            background: #fff;
            color: #000;
        }

        .social-icons svg {
            width: 20px;
            height: 20px;
            fill: currentColor;
        }

        .copyright {
            text-align: center;
            padding-top: 30px;
            margin-top: 40px;
            border-top: 1px solid #222;
            color: #555;
            font-size: 13px;
        }

        /* ПЛАВАЮЧИЙ ВІДЖЕТ (Круглий, без тексту) */

        .widget-icon svg {
            width: 28px;
            height: 28px;
            fill: #fff;
            display: block;
        }

        @media (max-width: 768px) {
            .hero {
                background-attachment: scroll !important;
                background-position: center center;
                background-image: url('images/clinic-mobile.webp');
            }

            /* mobile hero handled by .hero-slogan */
            .hero-title { font-size: 17px; padding: 0 15px; }
            .hero-slogan { font-size: 28px; }
            .hero-sub { font-size: 15px; padding: 0 15px; }
            .desktop-only { display: none; }
            .form-row { flex-direction: column; padding: 0 10px; }
            .form-input { min-width: auto; }
            .footer-content { grid-template-columns: 1fr 1fr; gap: 25px; }
            .btn-booking { width: 100%; max-width: 280px; }

            /* СІТКА ДЛЯ ПЕРЕВАГ НА МОБІЛЬНОМУ (2 КОЛОНКИ) */
            .features-grid {
                grid-template-columns: 1fr 1fr;
                /* 2 колонки */
                gap: 15px;
            }

            .feature-item {
                padding: 20px 10px;
            }

            .feature-item h3 {
                font-size: 16px;
                margin-bottom: 5px;
            }

            .feature-item p {
                font-size: 13px;
                line-height: 1.3;
            }

            .feature-img {
                width: 40px;
            }

            /* --- СТРІЛКИ КАРУСЕЛІ НА МОБІЛЬНОМУ --- */
            .c-btn {
                display: flex;
                /* Показуємо стрілки */
                width: 35px;
                height: 35px;
                font-size: 16px;
                background: rgba(255, 255, 255, 0.9);
                box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
            }

            .c-prev {
                left: 0;
            }

            .c-next {
                right: 0;
            }

            .carousel-wrapper {
                padding: 0 5px;
            }

            /* -------------------------------------- */

            /* --- ЗБІЛЬШЕНІ ФОТО ДО/ПІСЛЯ --- */
            .case-card {
                padding: 10px;
            }

            .before-after-row {
                gap: 8px;
            }

            /* ------------------------------- */

            /* Інші блоки залишаються в 1 колонку */
            .about-grid,
            .footer-content,
            .sterilization-grid,
            .digital-grid {
                grid-template-columns: 1fr;
            }

            .team .carousel-slide,
            .works .carousel-slide,
            .reviews .carousel-slide {
                width: 100%;
            }

            /* Скрол все ще працює, але тепер є і стрілки */
            .carousel-track-container {
                overflow-x: auto;
                scroll-snap-type: x mandatory;
            }

            .carousel-slide {
                scroll-snap-align: start;
            }

            .sterilization-text {
                order: 2;
            }

            .sterilization-img {
                order: 1;
            }

            .widget-icon svg {
                width: 24px;
                height: 24px;
            }
        }

        /* VISUALLY HIDDEN H1 FOR SEO */
        .visually-hidden {
            position: absolute;
            width: 1px;
            height: 1px;
            padding: 0;
            margin: -1px;
            overflow: hidden;
            clip: rect(0, 0, 0, 0);
            white-space: nowrap;
            border: 0;
        }

        .hero-title {
            font-size: 22px;
            font-weight: 600;
            margin-bottom: 12px;
            text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
            letter-spacing: 0.2px;
            line-height: 1.3;
        }
        .hero-title a:hover { opacity: 0.85; }

        .hero-slogan {
            font-size: 48px;
            font-weight: 800;
            margin-bottom: 15px;
            text-shadow: 0 2px 15px rgba(0, 0, 0, 0.8);
        }

        .hero-sub {
            font-size: 18px;
            margin-bottom: 40px;
            text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
            max-width: 700px;
            margin-left: auto;
            margin-right: auto;
            font-weight: 600;
        }

        /* CTA КНОПКА В ХЕДЕРІ */
        .btn-header-cta {
            background: var(--primary);
            color: #fff;
            padding: 8px 18px;
            border-radius: 50px;
            font-weight: 700;
            font-size: 12px;
            text-transform: uppercase;
            white-space: nowrap;
            transition: 0.3s;
            border: 1px solid rgba(255,255,255,0.3);
        }
        .btn-header-cta:hover {
            background: var(--primary-dark);
            color: #fff;
        }

        /* ФОРМА ЗАПИСУ */
        .booking-form-section {
            padding: 100px 0;
            background: #F4F6F4;
            color: var(--text-dark);
        }
        .booking-form-section .section-title {
            color: var(--primary);
        }
        .btn-booking {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            padding: 14px 28px;
            border-radius: 50px;
            font-size: 14px;
            font-weight: 700;
            font-family: 'Manrope', sans-serif;
            text-decoration: none;
            transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
            min-width: 150px;
            justify-content: center;
            background: var(--primary);
            color: #fff;
            border: 1px solid var(--primary);
            box-shadow: 0 4px 15px rgba(82,97,84,0.15);
        }
        .btn-booking svg {
            width: 20px;
            height: 20px;
            transition: transform 0.4s ease;
        }
        .btn-booking:hover {
            transform: translateY(-3px);
            box-shadow: 0 12px 25px rgba(82,97,84,0.3);
            background: var(--primary-dark);
            border-color: var(--primary-dark);
            color: #fff;
        }
        .btn-booking:hover svg {
            transform: scale(1.1);
        }
        .btn-viber, .btn-telegram, .btn-instagram {
            /* Inherit premium green styles from .btn-booking */
        }

        /* FAQ */
        .faq-section { padding: 80px 0; background: #fff; }

    
        @media (max-width: 480px) {
            .footer-content { grid-template-columns: 1fr; gap: 20px; text-align: center; }
            .social-icons { justify-content: center; }
        }

/* ====== MOBILE SAFETY NET — applies to every page ====== */
@media (max-width: 992px) {
    html, body { max-width: 100%; overflow-x: hidden; }
    img, picture, svg, video { max-width: 100%; height: auto; }
    table { max-width: 100%; }
    .container { padding-left: 16px; padding-right: 16px; }
    header .container,
    header .nav-wrapper { padding-left: 16px; padding-right: 16px; }
    .nav-wrapper { gap: 10px; }
    .logo img, header .logo img { max-height: 46px; height: auto; }
}
@media (max-width: 600px) {
    /* Compact header on phones */
    header { padding: 10px 0; }
    .logo img, header .logo img { max-height: 40px; }
    .header-phone { display: none; }
    .btn-header-cta { padding: 7px 14px; font-size: 11px; }
    /* Section titles */
    h1 { font-size: 28px !important; line-height: 1.2; }
    h2.section-title { font-size: 24px; margin-bottom: 24px; }
    /* Section padding */
    section { padding-left: 0; padding-right: 0; }
    .types-section, .advantages-section, .steps-section,
    .prices, .info-accordion, .faq-section,
    .booking-strip, .features, .about,
    .sterilization, .digital, .carousel-section,
    .booking-form-section { padding-top: 50px; padding-bottom: 50px; }
    /* Single-column grids */
    .types-grid, .steps-grid { grid-template-columns: 1fr; gap: 16px; }
    /* Cards */
    .type-item, .step-item { padding: 24px 20px; }
    /* Accordion */
    .accordion-header { padding: 18px; font-size: 16px; }
    .content-padding { padding: 0 18px 18px; font-size: 14px; }
    /* Price tables */
    .price-table { font-size: 13px; }
    .price-table th, .price-table td { padding: 12px 14px; }
    /* Forms */
    .form-input { font-size: 16px; padding: 12px 18px; } /* 16px обязательны: меньше — iOS зумит страницу при фокусе */
    /* Floating widget kept above safe-area */
    .floating-widget { bottom: 16px; right: 16px; }
}
@media (max-width: 380px) {
    .container { padding-left: 12px; padding-right: 12px; }
    .btn-primary { padding: 14px 28px; font-size: 13px; }
}

/* ==========================================================================
   MOBILE POLISH — 26.08.2026
   Правки по аудиту _work/audits/MOBILE-AUDIT-2026-08-26.md
   Блок намеренно идёт последним: он должен выигрывать каскад.
   ========================================================================== */

/* --- Единый горизонтальный отступ --------------------------------------- */
:root { --gutter: 20px; }
@media (max-width: 992px) { :root { --gutter: 16px; } }
@media (max-width: 380px) { :root { --gutter: 14px; } }

@media (max-width: 992px) {
    .container {
        padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
        padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
    }
    header .container,
    header .nav-wrapper {
        padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
        padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
    }
}

/* --- Шапка: ничего не переносится на вторую строку ----------------------- */
.header-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; flex-wrap: nowrap; }

@media (max-width: 992px) {
    .nav-wrapper { flex-wrap: nowrap; gap: 10px; }
    .logo { flex-shrink: 0; }
    .header-actions { gap: 8px; }
}
@media (max-width: 380px) { .header-actions { gap: 6px; } }

/* --- Тач-зоны: минимум 44px по HIG --------------------------------------- */
@media (max-width: 992px) {
    .lang-switcher { gap: 6px; flex-shrink: 0; }
    .lang-switcher a {
        min-width: 44px; min-height: 44px;
        display: inline-flex; align-items: center; justify-content: center;
        padding: 0 10px; font-size: 12px; box-sizing: border-box;
        -webkit-tap-highlight-color: transparent;
    }
    .btn-header-cta {
        min-height: 44px; display: inline-flex; align-items: center; justify-content: center;
        padding: 0 16px; font-size: 12.5px; white-space: nowrap; flex-shrink: 0;
    }
    .mobile-toggle { width: 44px; height: 44px; flex-shrink: 0; padding: 0; }
}
@media (max-width: 380px) {
    .lang-switcher a { min-width: 40px; padding: 0 7px; font-size: 11.5px; }
    .btn-header-cta { padding: 0 11px; font-size: 11.5px; }
}

/* Ссылки в подвале — тоже полноценные цели нажатия */
@media (max-width: 992px) {
    .unified-footer .footer-links a,
    .footer-links a {
        min-height: 44px; display: flex; align-items: center;
        margin-bottom: 0; padding: 2px 0;
    }
    .unified-footer .social-icons a { width: 44px; height: 44px; }
}

/* --- Подвал: ровный левый край вместо «лесенки» из > --------------------- */
@media (max-width: 768px) {
    .unified-footer { text-align: left; }
    .unified-footer .footer-content,
    .footer-content { text-align: left !important; }
    .unified-footer .social-icons,
    .social-icons { justify-content: flex-start !important; }
    .unified-footer .copyright { text-align: left; }
}

/* --- Плавающая кнопка звонка не должна перекрывать текст ------------------ */
.floating-widget {
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    right: calc(16px + env(safe-area-inset-right, 0px));
}
@media (max-width: 992px) {
    /* запас снизу, чтобы копирайт не оказался под кнопкой */
    .unified-footer .copyright,
    .copyright { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
}

/* --- Первый экран: 100dvh вместо 100vh (адресная строка) ----------------- */
.hero { height: 100vh; height: 100dvh; }

/* Плашка Google-отзывов не должна вставать вплотную к кнопке звонка */
@media (max-width: 992px) {
    .hero-google-badge { margin-right: 76px; }
}

/* --- Якоря не должны уезжать под липкую шапку ---------------------------- */
@media (max-width: 992px) { html { scroll-padding-top: 76px; } }

/* --- Таблицы сравнения: скролл + явная подсказка ------------------------- */
.table-responsive, .table-scroll, .table-wrap,
.compare-table-wrap, .comp-table-wrapper, .table-scroll-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
}
@media (max-width: 768px) {
    .table-responsive, .table-scroll, .table-wrap,
    .compare-table-wrap, .comp-table-wrapper, .table-scroll-wrap {
        position: relative;
    }
    /* Подсказка ставится ПЕРЕД таблицей: таблицы высокие, снизу её бы не увидели.
       sticky + left:0 держит подсказку на месте при горизонтальной прокрутке. */
    .table-responsive::before, .table-scroll::before, .table-wrap::before,
    .compare-table-wrap::before, .comp-table-wrapper::before, .table-scroll-wrap::before {
        content: "↔ гортайте таблицю вбік";
        display: block;
        padding: 0 2px 8px;
        font-size: 12.5px;
        font-weight: 600;
        color: var(--text-grey, #6b6b6b);
        position: sticky;
        left: 0;
        width: max-content;
        max-width: 100%;
    }
    html[lang="ru"] .table-responsive::before, html[lang="ru"] .table-scroll::before,
    html[lang="ru"] .table-wrap::before, html[lang="ru"] .compare-table-wrap::before,
    html[lang="ru"] .comp-table-wrapper::before, html[lang="ru"] .table-scroll-wrap::before {
        content: "↔ листайте таблицу вбок";
    }
}

/* --- Карусели: стрелки под треком, а не поверх фотографий ---------------- */
@media (max-width: 768px) {
    .carousel-wrapper {
        padding-left: 0; padding-right: 0;
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-areas: "track track" "prev next";
        row-gap: 16px;
    }
    .carousel-wrapper .carousel-track-container { grid-area: track; min-width: 0; }
    .carousel-wrapper .c-btn {
        position: static; transform: none;
        width: 44px; height: 44px; font-size: 18px;
        background: #fff; border: 1px solid #ddd;
    }
    .carousel-wrapper .c-prev { grid-area: prev; justify-self: end; margin-right: 6px; }
    .carousel-wrapper .c-next { grid-area: next; justify-self: start; margin-left: 6px; }
}

/* Карточки каруселей выравниваем по общему левому краю: слайд несёт
   внутренний padding 10px, поэтому контейнер трека вытягиваем на те же 10px.
   Ширина слайда остаётся 100% контейнера, поэтому JS-прокрутка не ломается. */
@media (max-width: 768px) {
    .carousel-wrapper .carousel-track-container { margin-left: -10px; margin-right: -10px; }
}

/* --- Фото «До/Після» крупнее: одна пара на всю ширину -------------------- */
@media (max-width: 768px) {
    .before-after-row { gap: 8px; }
    .before-after-row .photo-wrapper { flex: 1 1 0; min-width: 0; }
    .before-after-row .photo-wrapper img { width: 100%; display: block; }
}

/* Логотип и телефон в подвале — тоже полноценные цели нажатия */
@media (max-width: 992px) {
    header .logo { display: flex; align-items: center; min-height: 44px; }
    .unified-footer .footer-contact-line + p { margin-top: 6px; }
    .unified-footer .footer-contact-line + p a {
        min-height: 44px; display: inline-flex; align-items: center; gap: 8px;
    }
}

/* --- Подвал: контакты SVG-иконками вместо эмодзи ------------------------- */
.unified-footer .footer-contact-line,
.unified-footer .footer-contact-line + p a,
.footer-contact-line { display: flex; align-items: center; gap: 8px; }
.unified-footer .fi, .fi {
    width: 16px; height: 16px; flex: 0 0 16px;
    fill: currentColor; display: block;
}
.unified-footer .footer-contact-line .fi { align-self: flex-start; margin-top: 4px; }

/* Фото в блоке «о клинике»: 70% — правило для двухколоночной сетки десктопа.
   На мобильном колонка одна, поэтому фото тянем на всю ширину и ограничиваем высоту. */
@media (max-width: 768px) {
    .about-img img {
        width: 100%;
        max-height: 420px;
        object-fit: cover;
        object-position: center;
    }
}

/* Меню: прокручивается только список пунктов, шапка и CTA всегда на виду.
   Иначе кнопка «Записатися» уезжает за нижний край (а на iPhone ещё и под
   индикатор home). */
.mobile-menu { overflow: hidden; }
.mobile-menu-header { flex: 0 0 auto; }
.mobile-menu-nav { flex: 1 1 auto; overflow-y: auto; min-height: 0; -webkit-overflow-scrolling: touch; }
.mobile-menu-footer { flex: 0 0 auto; }

/* --- Инлайновые сетки из генераторов страниц ----------------------------- */
/* Часть страниц собрана скриптами и несёт grid прямо в style="", поэтому
   обычным правилом их не перекрыть — нужен !important и селектор по атрибуту.
   1) fr-колонки по умолчанию не уже min-content: длинное слово распирает сетку.
      min-width:0 разрешает колонке сжиматься — это снимает большую часть выносов.
   2) «Контент + сайдбар» и колонки в фиксированных px на телефоне складываем в одну.
   3) 3–4 колонки на 375px дают по 80–90px — режем до двух. */
@media (max-width: 768px) {
    [style*="display:grid"] > *, [style*="display: grid"] > *,
    [style*="display:flex"] > *, [style*="display: flex"] > * { min-width: 0; }

    [style*="1.2fr 0.8fr"], [style*="1.15fr 0.85fr"],
    [style*="1.1fr 1fr"],   [style*="1.2fr 1fr"],
    [style*="320px 1fr"],   [style*="280px 1fr"],
    [style*="1.5fr 1fr 1fr 1fr"] { grid-template-columns: 1fr !important; }

    [style*="repeat(4, 1fr)"], [style*="repeat(4,1fr)"],
    [style*="repeat(3, 1fr)"], [style*="repeat(3,1fr)"] {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    /* Инлайновый padding:50px съедает треть ширины телефона. Трогаем только
       горизонтальные стороны и только симметричную запись со ; на конце —
       иначе правило испортило бы секции с «padding: 50px 0». */
    [style*="padding:50px;"], [style*="padding: 50px;"] {
        padding-left: 22px !important; padding-right: 22px !important;
    }
}

/* --- Узкие экраны (≤ 480px): сетки и «выделенные» карточки ---------------- */
/* repeat(auto-fit, minmax(300px, 1fr)) не сжимается ниже 300px, поэтому на
   320–375px карточка вылезает за экран. Разрешаем колонке ужиматься до нуля. */
@media (max-width: 480px) {
    .packages-grid, .services-grid, .steps-grid, .types-grid,
    .tech-grid, .price-grid, .blog-grid,
    [style*="minmax(340px"], [style*="minmax(320px"], [style*="minmax(300px"],
    [style*="minmax(280px"], [style*="minmax(260px"], [style*="minmax(250px"] {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    /* Колонки в фиксированных px не умещаются рядом на телефоне */
    [style*="400px 1fr"], [style*="320px 1fr"], [style*="280px 1fr"] {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    /* Акцентный тариф увеличен на 5% — на узком экране это выносит его за край.
       Выделение остаётся за счёт рамки и тени. */
    .package-card.featured, .price-card.featured, .plan-card.featured { transform: none !important; }

    /* Крупные внутренние отступы карточек съедают ширину */
    .package-card, .service-card, .step-card, .type-item, .step-item {
        padding-left: 20px !important; padding-right: 20px !important;
    }
}

/* --- Навигационные ссылки: хлебные крошки, «назад», телефон на 404 -------- */
/* Это самостоятельные элементы навигации, а не ссылки внутри текста, поэтому
   на них распространяется требование к размеру цели нажатия. */
@media (max-width: 992px) {
    /* Хлебные крошки размечены по-разному: где-то класс, где-то только
       aria-label (и он в четырёх вариантах на двух языках) — ловим все. */
    .breadcrumb a, .breadcrumbs a,
    nav[aria-label*="крихт"] a, nav[aria-label*="крошк"] a,
    nav[aria-label*="ланцюж"] a, nav[aria-label*="цепочк"] a {
        display: inline-flex; align-items: center;
        min-height: 36px; padding: 4px 2px;
    }
    .back-btn, .phone-link {
        display: inline-flex; align-items: center; gap: 8px;
        min-height: 44px; padding: 4px 2px;
    }
}

/* --- Мобильное меню: CTA не должен уезжать под индикатор home ------------ */
.mobile-menu { padding-bottom: calc(26px + env(safe-area-inset-bottom, 0px)); }
@media (max-width: 360px) { .mobile-menu { padding-bottom: calc(22px + env(safe-area-inset-bottom, 0px)); } }
