/*
 * 海报弹窗组件样式
 * 功能：创建一个全屏覆盖的海报弹窗，支持动画效果和响应式设计
 * 包含：遮罩层、弹窗主体、关闭按钮、操作按钮等元素
 * 修改：优化手机端显示，确保关闭按钮不被挤压
 */

/* 海报遮罩层样式 - 创建半透明黑色背景覆盖整个屏幕 */
.gg-haibao-overlay {
    position: fixed; /* 固定定位，不随页面滚动 */
    top: 0;
    left: 0;
    width: 100%; /* 全屏宽度 */
    height: 100vh; /* 全屏高度，使用视口高度单位 */
    background: rgba(0, 0, 0, 0.85); /* 半透明黑色背景 */
    z-index: 9999; /* 高层级，确保覆盖其他元素 */
    display: none; /* 默认隐藏 */
    backdrop-filter: blur(5px); /* 背景模糊效果 */
}

/* 海报弹窗主体样式 */
.gg-haibao-poster {
    position: fixed;
    top: -100vh; /* 初始位置在屏幕上方，不可见 */
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #003399 0%, #4A90E2 50%, #FFFFFF 100%); /* 渐变背景 */
    z-index: 10000; /* 比遮罩层更高 */
    display: flex;
    flex-direction: column; /* 垂直排列 */
    justify-content: flex-start; /* 顶部对齐 */
    align-items: center; /* 水平居中 */
    color: #FFFFFF;
    transition: top 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94); /* 平滑动画过渡 */
    padding: 60px 20px 20px; /* 内边距 */
    box-sizing: border-box; /* 盒模型计算方式 */
    overflow-y: auto; /* 垂直方向可滚动 */
    -webkit-overflow-scrolling: touch; /* iOS平滑滚动 */
}

/* 海报显示状态 - 动画结束时位置 */
.gg-haibao-poster.show {
    top: 0; /* 移动到屏幕顶部 */
}

/* 海报内容容器 */
.gg-haibao-content {
    text-align: center;
    max-width: 800px; /* 最大宽度限制 */
    width: 100%;
    background: rgba(255, 255, 255, 0.95); /* 半透明白色背景 */
    border-radius: 20px; /* 圆角 */
    padding: 30px 20px; /* 内边距 */
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1); /* 阴影效果 */
    backdrop-filter: blur(10px); /* 背景模糊 */
    color: #333; /* 文字颜色 */
    margin: 0 auto; /* 水平居中 */
}

/* 主标题样式 - 渐变文字效果 */
.gg-haibao-title {
    font-size: 2.3rem;
    font-weight: bold;
    color: #003399;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1); /* 文字阴影 */
    background: linear-gradient(135deg, #003399, #00FF7F); /* 渐变背景 */
    -webkit-background-clip: text; /* 背景裁剪为文字形状 */
    -webkit-text-fill-color: transparent; /* 文字颜色透明，显示背景 */
    background-clip: text;
}

/* 副标题样式 */
.gg-haibao-title-xia {
    font-size: 1.6rem;
    font-weight: bold;
    margin-bottom: 8px;
    color: #003399;
}

/* 小标题样式 */
.gg-haibao-subtitle {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: #666;
    font-weight: 500;
}

/* 描述文字样式 */
.gg-haibao-description {
    font-size: 1.1rem;
    line-height: 1.7; /* 行高 */
    margin-bottom: 25px;
    color: #444;
    text-align: left; /* 左对齐 */
}

/* 列表样式 - 修复双圆点问题 */
.gg-haibao-description ul {
    margin: 10px 0;
    padding-left: 20px;
    line-height: 0;
    list-style-type: none; /* 移除默认列表样式 */
    margin-bottom: 36px; /* 增加底部边距 */
}

/* 列表项样式 */
.gg-haibao-description li {
    margin-bottom: 8px;
    padding: 4px 0;
    line-height: 1.4;
    position: relative;
    padding-left: 0; /* 移除左内边距 */
}

/* 自定义列表圆点 */
.gg-haibao-description li::before {
    content: "•"; /* 使用圆点作为列表标记 */
    color: #00FF7F; /* 绿色圆点 */
    font-weight: bold;
    margin-right: 8px;
    position: absolute;
    left: -15px; /* 定位到列表项左侧 */
}

/* 强调文字样式 */
.gg-haibao-description strong {
    color: #003399;
    font-weight: 600;
    display: block; /* 块级显示 */
    margin: 15px 0 8px 0;
    font-size: 1.1rem;
}

/* 内联样式覆盖 */
.gg-haibao-description span {
    color: #00FF7F !important; /* 使用important确保优先级 */
    font-weight: 600;
}

/* 按钮组容器 */
.gg-haibao-buttons {
    display: flex;
    gap: 20px; /* 按钮间距 */
    justify-content: center; /* 水平居中 */
    flex-wrap: wrap; /* 允许换行 */
    margin-top: 30px;
}

/* 基础按钮样式 */
.gg-haibao-btn {
    padding: 14px 32px;
    border: none;
    border-radius: 30px; /* 圆角按钮 */
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer; /* 手型光标 */
    transition: all 0.3s ease; /* 过渡动画 */
    min-width: 160px; /* 最小宽度 */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2); /* 阴影效果 */
}

/* 主要按钮样式 - 绿色渐变 */
.gg-haibao-btn-primary {
    background: linear-gradient(135deg, #00FF7F, #00CC66);
    color: white;
}

/* 主要按钮悬停效果 */
.gg-haibao-btn-primary:hover {
    background: linear-gradient(135deg, #00CC66, #00AA55);
    transform: translateY(-3px); /* 上移效果 */
    box-shadow: 0 6px 20px rgba(0, 255, 127, 0.3); /* 发光阴影 */
}

/* 次要按钮样式 - 边框式 */
.gg-haibao-btn-secondary {
    background: rgba(255, 255, 255, 0.9);
    color: #003399;
    border: 2px solid #003399; /* 蓝色边框 */
}

/* 次要按钮悬停效果 */
.gg-haibao-btn-secondary:hover {
    background: #003399; /* 蓝色背景 */
    color: white; /* 白色文字 */
    transform: translateY(-3px);
}

/* 关闭按钮样式 */
.gg-haibao-close-btn {
    position: fixed;
    top: 15px;
    right: 15px;
    width: 50px;
    height: 50px;
    border: none;
    background: rgba(255, 255, 255, 0.9); /* 半透明白色 */
    color: #FF6B6B; /* 红色关闭图标 */
    border-radius: 50%; /* 圆形按钮 */
    font-size: 1.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px); /* 背景模糊 */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    z-index: 10001; /* 最高层级 */
}

/* 关闭按钮悬停效果 */
.gg-haibao-close-btn:hover {
    background: #FF6B6B;
    color: white;
    transform: rotate(90deg) scale(1.1); /* 旋转和缩放动画 */
}

/* 手动打开按钮样式 */
.gg-haibao-manual-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #003399, #00FF7F); /* 渐变背景 */
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.6rem;
    cursor: pointer;
    z-index: 1001; /* 较高层级，但不覆盖弹窗 */
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

/* 手动打开按钮悬停效果 */
.gg-haibao-manual-btn:hover {
    transform: scale(1.1); /* 放大效果 */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* 手动打开按钮点击效果 */
.gg-haibao-manual-btn:active {
    transform: scale(0.95); /* 点击时缩小 */
}

/* 响应式设计 - 手机端适配 (屏幕宽度 ≤ 768px) */
@media (max-width: 768px) {
    .gg-haibao-poster {
        padding: 70px 15px 15px; /* 调整内边距 */
        justify-content: flex-start;
    }
    
    .gg-haibao-content {
        padding: 25px 15px;
        margin: 0;
        width: 100%;
        max-height: calc(100vh - 100px); /* 动态计算最大高度 */
        overflow-y: auto; /* 允许垂直滚动 */
    }
    
    /* 手机端文字大小调整 */
    .gg-haibao-title {
        font-size: 2rem;
        margin-bottom: 10px;
    }
    
    .gg-haibao-title-xia {
        font-size: 1.2rem;
        margin-bottom: 5px;
    }
    
    .gg-haibao-subtitle {
        font-size: 1rem;
        margin-bottom: 15px;
    }
    
    .gg-haibao-description {
        font-size: 0.95rem;
        line-height: 1.5;
        margin-bottom: 20px;
    }
    
    .gg-haibao-description ul {
        margin: 5px 0;
        padding-left: 15px;
        margin-bottom: 28px;
    }
    
    .gg-haibao-description li {
        margin-bottom: 6px;
        font-size: 0.9rem;
    }
    
    .gg-haibao-description strong {
        font-size: 1rem;
        margin: 12px 0 6px 0;
    }
    
    /* 手机端按钮布局调整 */
    .gg-haibao-buttons {
        flex-direction: column; /* 垂直排列 */
        align-items: center;
        gap: 12px;
        margin-top: 20px;
    }
    
    .gg-haibao-btn {
        width: 100%; /* 全宽按钮 */
        max-width: 280px; /* 最大宽度限制 */
        padding: 12px 20px;
        font-size: 1rem;
        min-width: auto; /* 移除最小宽度限制 */
    }
    
    /* 手机端关闭按钮优化 */
    .gg-haibao-close-btn {
        top: 10px;
        right: 10px;
        width: 45px;
        height: 45px;
        font-size: 1.6rem;
        background: rgba(255, 255, 255, 0.95);
    }
    
    /* 手机端手动打开按钮优化 */
    .gg-haibao-manual-btn {
        width: 38px;
        height: 38px;
        font-size: 1.4rem;
        top: 10px;
        right: 10px;
    }
}

/* 横屏模式优化 (手机横屏) */
@media (max-width: 768px) and (orientation: landscape) {
    .gg-haibao-poster {
        padding: 60px 10px 10px; /* 减少上下内边距 */
    }
    
    .gg-haibao-content {
        padding: 20px 15px;
        max-height: calc(100vh - 80px); /* 调整最大高度 */
    }
    
    .gg-haibao-close-btn {
        top: 8px;
        right: 8px;
        width: 40px;
        height: 40px;
    }
}

/* 超小屏幕优化 (屏幕宽度 ≤ 480px) */
@media (max-width: 480px) {
    .gg-haibao-poster {
        padding: 60px 10px 10px;
    }
    
    .gg-haibao-content {
        padding: 20px 12px;
        border-radius: 15px; /* 稍小的圆角 */
    }
    
    /* 超小屏幕文字调整 */
    .gg-haibao-title {
        font-size: 1.8rem;
    }
    
    .gg-haibao-title-xia {
        font-size: 1.1rem;
    }
    
    .gg-haibao-subtitle {
        font-size: 0.95rem;
    }
    
    /* 超小屏幕关闭按钮优化 */
    .gg-haibao-close-btn {
        top: 8px;
        right: 8px;
        width: 40px;
        height: 40px;
        font-size: 1.5rem;
    }
}