/**
 * 手机预览面板 - 独立 CSS
 * 从 material-use-new 组件中提取，用于分屏编辑器预览
 * 仿照小红书笔记手机端布局
 */

/* ==================== 预览面板容器 ==================== */
.GX_preview_panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
    background: #f0f2f5;
}

/* 手机外壳包裹层（相对定位容器，关闭按钮以此为基准） */
.GX_preview_phone_wrap {
    position: relative;
    display: inline-block;
}

/* 预览面板右上角关闭按钮（悬浮在手机外壳右上角） */
.GX_preview_close_btn {
    position: absolute;
    top: 16px;
    right: 10px;
    width: 26px;
    height: 26px;
    line-height: 24px;
    text-align: center;
    font-size: 18px;
    color: #ccc;
    cursor: pointer;
    border-radius: 50%;
    background: rgba(0,0,0,0.3);
    z-index: 10;
    user-select: none;
    transition: all 0.2s;
}
.GX_preview_close_btn:hover {
    color: #fff;
    background: rgba(0,0,0,0.55);
}

.GX_preview_placeholder {
    text-align: center;
    padding: 40px;
    color: #999;
    font-size: 14px;
}

/* ==================== 手机外壳 ==================== */
.GX_phone_frame {
    width: 320px;
    height: 640px;
    background: #fff;
    border-radius: 35px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
    overflow: hidden;
    position: relative;
    border: 10px solid #1a1a1a;
}

/* 手机顶部状态栏 */
.GX_phone_status_bar {
    height: 44px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
}

.GX_phone_time {
    font-size: 15px;
}

.GX_phone_status_icons {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
}

/* ==================== 小红书内容区域 ==================== */
.GX_xhs_content {
    height: calc(100% - 44px);
    display: flex;
    flex-direction: column;
    background: #fff;
    position: relative;
}

/* 顶部导航栏 */
.GX_xhs_navbar {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
    flex-shrink: 0;
}

.GX_xhs_navbar_back {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 18px;
    cursor: pointer;
}

.GX_xhs_navbar_user {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 10px;
}

.GX_xhs_navbar_avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f0f0f0;
    overflow: hidden;
}

.GX_xhs_navbar_avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.GX_xhs_navbar_nickname {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.GX_xhs_follow_btn {
    padding: 4px 12px;
    font-size: 12px;
    color: #ff2442;
    border: 1px solid #ff2442;
    border-radius: 12px;
    background: transparent;
    cursor: pointer;
    margin-right: 10px;
}

.GX_xhs_navbar_share {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 18px;
    cursor: pointer;
}

/* 可滚动内容区域 */
.GX_xhs_scroll_content {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

/* 图片轮播 */
.GX_xhs_image_carousel {
    position: relative;
    width: 100%;
    background: #000;
    overflow: hidden;
}

.GX_xhs_carousel_track {
    display: flex;
    transition: transform 0.3s ease;
    height: 100%;
}

.GX_xhs_carousel_item {
    flex: 0 0 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}

.GX_xhs_carousel_item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 400px;
}

/* 轮播指示器 */
.GX_xhs_carousel_dots {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.GX_xhs_dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s;
}

.GX_xhs_dot.active {
    background: #ff2442;
    width: 12px;
    border-radius: 3px;
}

/* ==================== 小红书正文 ==================== */
.GX_xhs_body {
    padding: 15px;
    background: #fff;
}

.GX_xhs_title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    line-height: 1.5;
    margin-bottom: 10px;
}

.GX_xhs_text {
    font-size: 14px;
    color: #333;
    line-height: 1.8;
    white-space: pre-wrap;
    word-break: break-word;
}

.GX_xhs_text img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 6px 0;
    display: block;
}

.GX_xhs_text .emoji {
    font-size: 16px;
}

.GX_xhs_tags {
    margin-top: 12px;
}

.GX_xhs_tag {
    display: inline-block;
    font-size: 13px;
    color: #576b95;
    margin-right: 10px;
    cursor: pointer;
}

/* ==================== 底部操作栏 ==================== */
.GX_xhs_footer {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: #fff;
    border-top: 1px solid #f0f0f0;
    flex-shrink: 0;
}

.GX_xhs_footer_input {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 4px 10px;
    background: #f5f5f5;
    border-radius: 12px;
    font-size: 11px;
    color: #999;
    margin-right: 10px;
}

.GX_xhs_footer_actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.GX_xhs_footer_item {
    display: flex;
    align-items: center;
    gap: 3px;
    color: #666;
    font-size: 12px;
    cursor: pointer;
}

.GX_xhs_action_icon {
    width: 20px;
    height: 20px;
}

/* 滚动条 */
.GX_xhs_content::-webkit-scrollbar {
    width: 3px;
}

.GX_xhs_content::-webkit-scrollbar-track {
    background: transparent;
}

.GX_xhs_content::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 2px;
}

.GX_xhs_content::-webkit-scrollbar-thumb:hover {
    background: #ccc;
}
