/* =============================================
   STUDIO85 IT — Компонент интерактивного зума
   ============================================= */

/* Контейнер */
.zoom-viewer {
    margin: 20px 0;
}

/* Viewport — область отображения с обрезкой */
.zoom-viewport {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background: #f5f5f7;
    cursor: default;
}

.zoom-viewport.zoomed {
    cursor: zoom-out;
}

/* Изображение */
.zoom-image {
    display: block;
    width: 100%;
    height: auto;
    transition: transform 0.6s cubic-bezier(0.25, 0.1, 0.25, 1);
    transform-origin: center center;
    will-change: transform;
}

/* Подпись при зуме */
.zoom-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 24px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.65));
    color: #fff;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s 0.15s, transform 0.3s 0.15s;
    pointer-events: none;
}

.zoom-caption.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Навигация по hotspot-ам */
.zoom-hotspots {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    align-items: center;
}

/* Кнопка hotspot */
.zoom-hotspot {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: #f5f5f7;
    border: 1px solid transparent;
    border-radius: 100px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.2s;
}

.zoom-hotspot:hover {
    background: #e8e8ed;
}

.zoom-hotspot.active {
    background: #1d1d1f;
    color: #fff;
}

/* Точка-индикатор перед названием */
.zoom-hotspot::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #86868b;
    border-radius: 50%;
    flex-shrink: 0;
    transition: background 0.2s;
}

.zoom-hotspot.active::before {
    background: #fff;
}

/* Кнопка «Сбросить» */
.zoom-reset {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background: none;
    border: 1px solid #d2d2d7;
    border-radius: 100px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    color: #86868b;
    cursor: pointer;
    transition: all 0.2s;
    opacity: 0;
    pointer-events: none;
}

.is-zoomed .zoom-reset {
    opacity: 1;
    pointer-events: auto;
}

.zoom-reset:hover {
    border-color: #1d1d1f;
    color: #1d1d1f;
}

/* Плейсхолдер когда нет изображения */
.zoom-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    background: #f5f5f7;
    border-radius: 12px;
    color: #a1a1a6;
    font-size: 15px;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .zoom-hotspots {
        gap: 6px;
    }

    .zoom-hotspot {
        padding: 6px 12px;
        font-size: 13px;
    }

    .zoom-reset {
        padding: 6px 12px;
        font-size: 13px;
    }

    .zoom-caption {
        font-size: 14px;
        padding: 16px 20px;
    }
}
