/* Desktop magnifier and mobile text enlargement for low-vision users. */

.admin-hover-zone,
.admin-entry-link {
    display: none !important;
}

.prestige-a11y-launcher {
    position: fixed;
    left: 9px;
    bottom: var(--prestige-a11y-launcher-bottom, 9px);
    z-index: 10008;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 0;
    min-height: 36px;
    max-width: min(280px, calc(100vw - 18px));
    padding: 5px 8px;
    border: 1px solid rgba(92, 59, 109, 0.22);
    border-radius: 8px;
    background: rgba(252, 249, 253, 0.94);
    color: var(--color-purple, #5c3b6d);
    box-shadow: 0 5px 16px rgba(92, 59, 109, 0.2);
    font: 800 10px/1.2 Arial, sans-serif;
    cursor: pointer;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.prestige-a11y-launcher__mark {
    font-size: 13px;
    letter-spacing: -0.08em;
}

.prestige-a11y-launcher:hover,
.prestige-a11y-launcher:focus-visible {
    outline: 3px solid rgba(92, 59, 109, 0.38);
    outline-offset: 3px;
}

.prestige-a11y-magnifier[hidden] {
    display: none !important;
}

.prestige-a11y-magnifier {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 10025;
    width: min(600px, calc(100vw - 32px));
    height: min(420px, calc(100vh - 32px));
    overflow: hidden;
    border: 5px solid var(--color-purple, #5c3b6d);
    border-radius: 50%;
    background: #dadddf;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.42);
    pointer-events: none;
    contain: strict;
    will-change: transform;
}

.prestige-a11y-magnifier__background,
.prestige-a11y-magnifier__source {
    position: absolute;
    top: 0;
    left: 0;
    margin: 0 !important;
    transform-origin: 0 0;
    pointer-events: none !important;
    will-change: transform;
}

.prestige-a11y-magnifier__background {
    z-index: 0;
}

.prestige-a11y-magnifier__source {
    z-index: 1;
}

.prestige-a11y-magnifier__source [data-a11y-ui] {
    display: none !important;
}

.prestige-a11y-magnifier-hint[hidden] {
    display: none !important;
}

.prestige-a11y-magnifier-hint {
    position: fixed;
    z-index: 10026;
    left: 50%;
    top: min(calc(50% + 226px), calc(100% - 92px));
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100vw - 32px);
    padding: 12px 20px;
    border: 2px solid var(--color-purple, #5c3b6d);
    border-radius: 16px;
    background: #fcf9fd;
    color: var(--color-purple, #5c3b6d);
    box-shadow: 0 8px 24px rgba(92, 59, 109, .22);
    font: 700 clamp(18px, 1.2vw, 24px)/1.4 Arial, sans-serif;
    text-align: center;
    pointer-events: none;
}

html.prestige-a11y-prompt-open,
html.prestige-a11y-prompt-open body {
    overflow: hidden !important;
}

.prestige-a11y-prompt[hidden] {
    display: none !important;
}

.prestige-a11y-prompt {
    position: fixed;
    inset: 0;
    z-index: 10030;
    display: grid;
    place-items: center;
    padding: 18px;
    font-family: Arial, Helvetica, sans-serif;
}

.prestige-a11y-prompt__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(35, 22, 42, 0.62);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    cursor: pointer;
}

.prestige-a11y-prompt__dialog {
    position: relative;
    width: min(660px, calc(100vw - 36px));
    padding: 42px 38px 36px;
    border: 3px solid var(--color-purple, #5c3b6d);
    border-radius: 26px;
    background: #fff;
    color: #2f2036;
    box-shadow: 0 24px 80px rgba(23, 14, 28, 0.42);
    text-align: center;
}

.prestige-a11y-prompt__close {
    position: absolute;
    top: 10px;
    right: 12px;
    display: grid;
    width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    border: 2px solid var(--color-purple, #5c3b6d);
    border-radius: 50%;
    background: transparent;
    color: var(--color-purple, #5c3b6d);
    font: 800 28px/1 Arial, sans-serif;
    cursor: pointer;
}

.prestige-a11y-prompt__title {
    margin: 0 48px 14px;
    color: var(--color-purple, #5c3b6d);
    font-size: clamp(34px, 5vw, 50px);
    font-weight: 900;
    line-height: 1.08;
}

.prestige-a11y-prompt__text {
    max-width: 560px;
    margin: 0 auto 28px;
    color: #2f2036;
    font-size: clamp(23px, 3vw, 30px);
    font-weight: 700;
    line-height: 1.35;
}

.prestige-a11y-prompt__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

.prestige-a11y-prompt__enable,
.prestige-a11y-prompt__dismiss {
    min-width: 180px;
    min-height: 56px;
    padding: 12px 22px;
    border: 2px solid var(--color-purple, #5c3b6d);
    border-radius: 12px;
    font: 800 20px/1.2 Arial, sans-serif;
    cursor: pointer;
}

.prestige-a11y-prompt__enable {
    background: var(--color-purple, #5c3b6d);
    color: #fff;
    box-shadow: 0 10px 28px rgba(92, 59, 109, 0.28);
}

.prestige-a11y-prompt__dismiss {
    background: transparent;
    color: var(--color-purple, #5c3b6d);
}

.prestige-a11y-prompt__close:focus-visible,
.prestige-a11y-prompt__enable:focus-visible,
.prestige-a11y-prompt__dismiss:focus-visible {
    outline: 4px solid #ff9d00;
    outline-offset: 4px;
}

@media (max-width: 700px), (hover: none) and (pointer: coarse) {
    .prestige-a11y-prompt {
        padding: 10px;
    }

    .prestige-a11y-prompt__dialog {
        width: calc(100vw - 20px);
        padding: 54px 18px 24px;
        border-radius: 20px;
    }

    .prestige-a11y-prompt__title {
        margin-inline: 18px;
        font-size: 34px;
    }

    .prestige-a11y-prompt__text {
        font-size: 23px;
    }

    .prestige-a11y-prompt__actions {
        flex-direction: column;
    }

    .prestige-a11y-prompt__enable,
    .prestige-a11y-prompt__dismiss {
        width: 100%;
    }

    .prestige-a11y-launcher,
    .privacy-settings-button {
        min-width: 0;
        max-width: calc(50vw - 8px);
        min-height: 36px;
        padding: 5px 7px;
        white-space: normal !important;
        overflow-wrap: anywhere;
        font-size: 11px !important;
        line-height: 1.2;
    }

    .prestige-a11y-launcher {
        left: 5px;
    }

    .privacy-settings-button {
        right: 5px;
        bottom: 5px;
    }

    .prestige-a11y-magnifier,
    .prestige-a11y-magnifier-hint {
        display: none !important;
    }

    html.prestige-a11y {
        max-width: 100%;
        overflow-x: hidden !important;
        font-size: 200%;
        scroll-behavior: auto !important;
    }

    html.prestige-a11y body {
        max-width: 100%;
        overflow-x: hidden !important;
    }

    html.prestige-a11y *,
    html.prestige-a11y *::before,
    html.prestige-a11y *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }

    html.prestige-a11y :focus-visible {
        outline: 3px solid #ff9d00 !important;
        outline-offset: 3px !important;
    }

    html.prestige-a11y :where(p, li, label, summary, .clinic-price-name, .clinic-service-info-text) {
        line-height: 1.55 !important;
    }

    html.prestige-a11y :where(
        button, a, label, summary, .service-tag, .category-tag, .clinic-price-name,
        .clinic-price-value, .clinic-service-info-text, .review-card
    ) {
        overflow-wrap: anywhere;
    }

    html.prestige-a11y :where(
        .clinic-header-link, .clinic-service-item, .clinic-service-heading,
        .clinic-about-documents-toggle, .clinic-about-documents-link,
        .clinic-price-category-toggle, .clinic-price-subcategory-toggle,
        .clinic-contacts-map-button, .submit-btn, .clinic-btn
    ) {
        height: auto !important;
        min-height: 2.75rem;
        white-space: normal !important;
    }

    html.prestige-a11y .main-section {
        min-height: 0;
    }

    html.prestige-a11y .header-container {
        min-height: 7rem;
    }

    html.prestige-a11y .main-content {
        min-height: 0;
        margin-top: 0;
        padding: 1rem 0 3rem;
    }

    html.prestige-a11y .clinics-grid {
        width: 100%;
        flex-direction: column;
        flex-wrap: wrap;
        gap: 1.25rem;
    }

    html.prestige-a11y .clinic-card {
        width: 100%;
        min-width: 0;
        min-height: 0;
        height: auto;
    }

    html.prestige-a11y .selection-arrow {
        order: -1;
        width: 100%;
        min-width: 0;
        height: auto;
    }

    html.prestige-a11y .clinic-name,
    html.prestige-a11y .clinic-contact-number,
    html.prestige-a11y .clinic-hours-line,
    html.prestige-a11y .service-tag,
    html.prestige-a11y .selection-text,
    html.prestige-a11y .selection-reviews-link {
        white-space: normal !important;
    }

    html.prestige-a11y .clinic-contact-panel,
    html.prestige-a11y .clinic-hours-panel {
        width: 100%;
        height: auto;
    }

    html.prestige-a11y .clinic-header-bar {
        position: relative;
        top: auto;
        grid-template-columns: 1fr;
        gap: 0.75rem;
        width: 100%;
        padding: 0.75rem;
    }

    html.prestige-a11y .clinic-header-nav,
    html.prestige-a11y .clinic-header-nav--left,
    html.prestige-a11y .clinic-header-nav--right {
        flex-wrap: wrap;
        justify-content: center;
        padding-right: 0;
        padding-left: 0;
    }

    html.prestige-a11y .clinic-brand-block {
        order: -1;
    }

    html.prestige-a11y .clinic-header-link {
        flex: 1 1 100%;
        min-width: 0;
    }

    html.prestige-a11y .clinic-page-shell,
    html.prestige-a11y .clinic-services-section,
    html.prestige-a11y .clinic-specialists-section,
    html.prestige-a11y .clinic-about-section,
    html.prestige-a11y .clinic-contacts-section,
    html.prestige-a11y .clinic-service-card,
    html.prestige-a11y .clinic-about-card,
    html.prestige-a11y .clinic-contacts-card,
    html.prestige-a11y .clinic-about-documents-card {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    html.prestige-a11y .clinic-specialists-grid {
        grid-template-columns: 1fr;
    }

    html.prestige-a11y .clinic-service-detail.is-visible,
    html.prestige-a11y .clinic-service-info-content.is-open,
    html.prestige-a11y .clinic-about-documents-content.is-open,
    html.prestige-a11y .clinic-price-category-content.is-open,
    html.prestige-a11y .clinic-price-subcategory-content.is-open {
        max-height: none !important;
        overflow: visible !important;
    }

    html.prestige-a11y .clinic-price-row {
        grid-template-columns: 1fr;
        gap: 0.35rem;
    }

    html.prestige-a11y .clinic-price-value {
        justify-self: start;
        text-align: left;
    }

    html.prestige-a11y .clinic-service-price {
        align-items: stretch;
        padding: 0.5rem;
        border-radius: 1rem;
        overflow: visible;
    }

    html.prestige-a11y .clinic-service-price-link {
        width: 100%;
        max-width: 100%;
        padding: 0.5rem 0.25rem;
        border-radius: 0.75rem;
        overflow-wrap: break-word;
        word-break: normal;
    }

    html.prestige-a11y .reviews-shell,
    html.prestige-a11y .review-card,
    html.prestige-a11y .review-form,
    html.prestige-a11y .review-privacy-note {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    html.prestige-a11y .reviews-filter {
        flex-wrap: wrap;
    }

    html.prestige-a11y .reviews-filter .clinic-btn {
        flex: 1 1 100%;
        min-width: 0;
    }

    html.prestige-a11y .form-input,
    html.prestige-a11y .form-textarea,
    html.prestige-a11y .custom-specialist-select,
    html.prestige-a11y .custom-specialist-select__button,
    html.prestige-a11y .submit-btn {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    html.prestige-a11y .privacy-consent__title { font-size: 26px; }
    html.prestige-a11y .privacy-consent__text { font-size: 22px; }
    html.prestige-a11y .privacy-consent__button { font-size: 24px; white-space: normal; }
    html.prestige-a11y .privacy-center__title { font-size: clamp(48px, 8vw, 68px); }
    html.prestige-a11y .privacy-center__lead,
    html.prestige-a11y .privacy-center__section p,
    html.prestige-a11y .privacy-center__section li { font-size: 28px; }
    html.prestige-a11y .privacy-center__section h3 { font-size: 32px; }
    html.prestige-a11y .privacy-center__button { font-size: 24px; white-space: normal; }

    html.prestige-a11y .logo,
    html.prestige-a11y .logo img,
    html.prestige-a11y .clinic-brand-block,
    html.prestige-a11y .clinic-brand-logo {
        visibility: visible !important;
        opacity: 1 !important;
        filter: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .prestige-a11y-launcher,
    .prestige-a11y-magnifier {
        transition: none !important;
    }
}
