/* ============================================
   火场逃生知识站 — 网站式布局扩展样式
   搭配 shared/style.css 使用
   桌面优先设计（960px 内容居中）
   ============================================ */

/* ============================================
   DESKTOP UNLOCK — 解除 480px 手机卡片限制
   （shared/style.css 中 .game-container 限 480px，
    这里同名选择器后加载，直接覆盖，无需 !important）
   ============================================ */
.game-container {
    max-width: none;
    max-height: none;
    border-radius: 0;
    box-shadow: none;
}

body {
    display: block;
}

/* --- 网站式顶部导航 --- */
.site-nav {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 32px;
    background: linear-gradient(135deg, #E74C3C, #c0392b);
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 12px rgba(231,76,60,0.3);
}

.site-nav .nav-brand {
    font-size: 20px;
    font-weight: 900;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.site-nav .nav-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.site-nav .nav-links a {
    text-decoration: none;
    color: rgba(255,255,255,0.9);
    font-weight: 700;
    font-size: 14px;
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(255,255,255,0.15);
    transition: all 0.2s;
    white-space: nowrap;
}

.site-nav .nav-links a:hover,
.site-nav .nav-links a.active {
    background: rgba(255,255,255,0.3);
    color: #fff;
}

/* --- Hero 横幅区 --- */
.hero-banner {
    width: 100%;
    background: linear-gradient(160deg, #fff3e0 0%, #ffccbc 40%, #ffab91 100%);
    padding: 48px 32px 36px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(241,196,15,0.3) 0%, transparent 70%);
    border-radius: 50%;
}

.hero-banner .hero-icon {
    font-size: 72px;
    display: block;
    margin-bottom: 8px;
    animation: heroFloat 2s ease-in-out infinite;
    position: relative;
}

@keyframes heroFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.hero-banner .hero-title {
    font-size: 38px;
    font-weight: 900;
    color: #bf360c;
    margin-bottom: 6px;
    position: relative;
}

.hero-banner .hero-subtitle {
    font-size: 18px;
    color: #e65100;
    font-weight: 600;
    position: relative;
}

/* --- 区块标题 --- */
.section-header {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.section-header .section-icon {
    font-size: 28px;
}

.section-header .section-title {
    font-size: 22px;
    font-weight: 800;
    color: #2c3e50;
}

.section-header .section-more {
    margin-left: auto;
    font-size: 15px;
    color: #E74C3C;
    text-decoration: none;
    font-weight: 700;
}

/* --- 知识卡片网格（桌面 3 列） --- */
.knowledge-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    width: 100%;
}

.knowledge-card-sm {
    background: #fff;
    border-radius: 16px;
    padding: 20px 16px;
    text-align: center;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
    text-decoration: none;
    color: inherit;
    display: block;
}

.knowledge-card-sm:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    border-color: #E74C3C;
}

.knowledge-card-sm:active {
    transform: scale(0.96);
}

.knowledge-card-sm .kc-icon {
    font-size: 40px;
    display: block;
    margin-bottom: 6px;
}

.knowledge-card-sm .kc-title {
    font-weight: 800;
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 4px;
}

.knowledge-card-sm .kc-desc {
    font-size: 13px;
    color: #95a5a6;
    line-height: 1.4;
}

/* --- 游戏入口卡片 --- */
.game-entry-cards {
    display: flex;
    gap: 20px;
    width: 100%;
}

.game-entry-card {
    flex: 1;
    background: #fff;
    border-radius: 20px;
    padding: 28px 20px;
    text-align: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.game-entry-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.game-entry-card:active {
    transform: scale(0.96);
}

.game-entry-card .ge-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 8px;
}

.game-entry-card .ge-title {
    font-weight: 800;
    font-size: 18px;
    color: #2c3e50;
    margin-bottom: 4px;
}

.game-entry-card .ge-desc {
    font-size: 13px;
    color: #95a5a6;
}

.game-entry-card.green { border-color: rgba(46,204,113,0.3); }
.game-entry-card.green:hover { border-color: #2ECC71; }
.game-entry-card.orange { border-color: rgba(255,152,0,0.3); }
.game-entry-card.orange:hover { border-color: #FF9800; }

/* --- 统计卡片行 --- */
.stats-row {
    display: flex;
    gap: 16px;
    width: 100%;
}

.stat-mini-card {
    flex: 1;
    background: #fff;
    border-radius: 16px;
    padding: 18px 12px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.2s;
}

.stat-mini-card:hover { transform: translateY(-2px); }

.stat-mini-card .sm-num {
    font-size: 32px;
    font-weight: 900;
    color: #2c3e50;
}

.stat-mini-card .sm-label {
    font-size: 13px;
    color: #95a5a6;
    font-weight: 600;
    margin-top: 2px;
}

.stat-mini-card .sm-icon {
    font-size: 22px;
    display: block;
    margin-bottom: 4px;
}

/* --- 网站底部 --- */
.site-footer {
    width: 100%;
    text-align: center;
    padding: 24px;
    background: rgba(0,0,0,0.03);
    border-top: 1px solid rgba(0,0,0,0.06);
    flex-shrink: 0;
}

.site-footer .footer-text {
    font-size: 13px;
    color: #bdbdbd;
    line-height: 1.8;
}

/* --- 知识详情页（knowledge.html） --- */
.knowledge-section {
    width: 100%;
    max-width: 800px;
    margin: 0 auto 20px;
}

.knowledge-section .ks-header {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 18px 24px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
    transition: all 0.2s;
}

.knowledge-section .ks-header:hover {
    box-shadow: 0 4px 18px rgba(0,0,0,0.08);
}

.knowledge-section .ks-icon {
    font-size: 34px;
}

.knowledge-section .ks-title {
    font-weight: 800;
    font-size: 18px;
    color: #2c3e50;
    flex: 1;
}

.knowledge-section .ks-arrow {
    font-size: 16px;
    color: #bdbdbd;
    transition: transform 0.3s;
}

.knowledge-section.open .ks-arrow {
    transform: rotate(180deg);
}

.knowledge-section .ks-body {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.4s ease;
}

.knowledge-section.open .ks-body {
    max-height: 4000px;
}

.knowledge-section .ks-content {
    padding: 6px 4px 10px;
}

.knowledge-tip {
    background: #fff;
    border-radius: 14px;
    padding: 16px 20px;
    margin-bottom: 8px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.03);
    border-left: 4px solid #E74C3C;
}

.knowledge-tip .tip-emoji {
    font-size: 22px;
    flex-shrink: 0;
    margin-top: 2px;
}

.knowledge-tip .tip-content {
    font-size: 15px;
    color: #2c3e50;
    line-height: 1.7;
    font-weight: 500;
}

.knowledge-tip .tip-content strong {
    color: #E74C3C;
}

/* 紧急号码突出卡片 */
.emergency-card {
    background: linear-gradient(135deg, #E74C3C, #c0392b);
    border-radius: 20px;
    padding: 24px 32px;
    color: #fff;
    text-align: center;
    margin: 0 auto 20px;
    max-width: 500px;
    box-shadow: 0 4px 20px rgba(231,76,60,0.3);
}

.emergency-card .em-icon {
    font-size: 44px;
    display: block;
    margin-bottom: 6px;
}

.emergency-card .em-title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 4px;
}

.emergency-card .em-number {
    font-size: 48px;
    font-weight: 900;
    letter-spacing: 3px;
    margin: 8px 0;
    font-family: monospace;
}

.emergency-card .em-desc {
    font-size: 14px;
    opacity: 0.9;
    line-height: 1.6;
}

/* 灭火器步骤 */
.steps-row-kb {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 12px 0 16px;
}

.step-card {
    background: #fff;
    border-radius: 16px;
    padding: 20px 16px;
    text-align: center;
    flex: 1;
    min-width: 80px;
    max-width: 140px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.step-card .step-num {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #E74C3C;
    color: #fff;
    font-weight: 900;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
}

.step-card .step-emoji {
    font-size: 28px;
    display: block;
    margin-bottom: 4px;
}

.step-card .step-text {
    font-size: 14px;
    font-weight: 700;
    color: #2c3e50;
}

/* --- 内容区 --- */
.content-area {
    flex: 1;
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    padding: 24px 32px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* --- 安全提示横幅 --- */
.safety-alert-bar {
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    background: linear-gradient(135deg, #fff3e0, #ffe0b2);
    border-radius: 12px;
    padding: 12px 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-left: 4px solid #FF9800;
    font-size: 15px;
    font-weight: 600;
    color: #e65100;
}

.safety-alert-bar .sa-icon {
    font-size: 26px;
    flex-shrink: 0;
}

/* --- 页面顶部简单导航（给子页面用） --- */
.sub-nav {
    width: 100%;
    flex-shrink: 0;
}

/* --- 游戏页导航栏居中包装 --- */
.nav-bar {
    max-width: 960px;
    margin: 0 auto;
    width: 100%;
}

/* --- 游戏页 .page 内容居中 --- */
.page {
    max-width: 960px;
    margin: 0 auto;
    width: 100%;
}

/* ============================================
   响应式设计（桌面优先，向下兼容）
   ============================================ */

/* 平板（768px - 960px） */
@media (max-width: 900px) {
    .content-area {
        max-width: 100%;
        padding: 20px 20px;
    }
    .site-nav {
        padding: 10px 20px;
    }
    .site-nav .nav-brand {
        font-size: 17px;
    }
    .site-nav .nav-links a {
        font-size: 12px;
        padding: 6px 12px;
    }
    .hero-banner {
        padding: 36px 24px 28px;
    }
    .hero-banner .hero-icon {
        font-size: 56px;
    }
    .hero-banner .hero-title {
        font-size: 30px;
    }
    .hero-banner .hero-subtitle {
        font-size: 15px;
    }
    .knowledge-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .game-entry-cards {
        gap: 14px;
    }
    .game-entry-card .ge-icon {
        font-size: 40px;
    }
    .knowledge-section {
        max-width: 100%;
    }
    .emergency-card {
        max-width: 100%;
    }
    .page {
        max-width: 100%;
        padding: 16px;
    }
    .nav-bar {
        max-width: 100%;
    }
}

/* 手机（< 480px，恢复紧凑布局） */
@media (max-width: 480px) {
    .content-area {
        padding: 14px 12px;
        gap: 16px;
    }
    .site-nav {
        padding: 8px 12px;
    }
    .site-nav .nav-brand {
        font-size: 15px;
    }
    .site-nav .nav-links {
        gap: 4px;
    }
    .site-nav .nav-links a {
        font-size: 11px;
        padding: 4px 8px;
    }
    .hero-banner {
        padding: 28px 16px 24px;
    }
    .hero-banner .hero-icon {
        font-size: 48px;
    }
    .hero-banner .hero-title {
        font-size: 26px;
    }
    .hero-banner .hero-subtitle {
        font-size: 14px;
    }
    .knowledge-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .knowledge-card-sm {
        padding: 14px 10px;
    }
    .knowledge-card-sm .kc-icon {
        font-size: 30px;
    }
    .knowledge-card-sm .kc-title {
        font-size: 14px;
    }
    .game-entry-cards {
        gap: 10px;
    }
    .game-entry-card {
        padding: 18px 12px;
    }
    .game-entry-card .ge-icon {
        font-size: 34px;
    }
    .game-entry-card .ge-title {
        font-size: 15px;
    }
    .stats-row {
        gap: 8px;
    }
    .stat-mini-card {
        padding: 12px 6px;
    }
    .stat-mini-card .sm-num {
        font-size: 24px;
    }
    .section-header .section-title {
        font-size: 17px;
    }
    .knowledge-tip {
        padding: 12px 14px;
    }
    .knowledge-tip .tip-content {
        font-size: 13px;
    }
    .emergency-card {
        padding: 18px 20px;
    }
    .emergency-card .em-number {
        font-size: 34px;
    }
    .page {
        max-width: 100%;
        padding: 12px;
    }
    .nav-bar {
        max-width: 100%;
    }
}
