/* ============================================================
 * image-preview.css
 * 位置：static/runtime/content/image-preview.css（运行时容器目录）
 * ImagePreview 图片预览容器样式 —— 替代原 showAvatarZoom 全屏遮罩
 * ============================================================ */
.ip-overlay {
    position: fixed;
    inset: 0;
    z-index: 20000;       /* 高于 stdModal、PlainView */
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
    -webkit-tap-highlight-color: transparent;
    touch-action: none;
}

/* 图片舞台 */
.ip-stage {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    cursor: default;
    touch-action: none;
}

.ip-img-wrap {
    position: relative;
    max-width: 100%;
    max-height: 100%;
    cursor: grab;
}
.ip-img-wrap:active { cursor: grabbing; }

.ip-img {
    display: block;
    max-width: 100%;
    max-height: calc(100vh - 80px);
    transform-origin: 0 0;
    user-select: none;
    -webkit-user-select: none;
    pointer-events: auto;
    -webkit-user-drag: none;
}

/* 关闭按钮 */
.ip-close {
    position: absolute;
    top: calc(12px + env(safe-area-inset-top, 0px));
    right: 12px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
}
.ip-close:active { background: rgba(0, 0, 0, 0.7); }

/* 标题 + 计数（底部居中） */
.ip-title {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    text-align: center;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.88rem;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    pointer-events: none;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}
.ip-counter {
    margin-left: 8px;
    color: rgba(255, 255, 255, 0.65);
    font-variant-numeric: tabular-nums;
}

/* 多图左右切换 */
.ip-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 64px;
    border: none;
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-tap-highlight-color: transparent;
}
.ip-nav:active { background: rgba(0, 0, 0, 0.55); }
.ip-nav-prev { left: 12px; border-radius: 8px 8px 8px 8px; }
.ip-nav-next { right: 12px; border-radius: 8px 8px 8px 8px; }