:root {
    --white: #ffffff;
    --header-h: 44px;
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    background: #eef2f0;
    color: #333;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* ========== 顶部导航 ========== */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    height: calc(var(--header-h) + var(--safe-top));
    padding-top: var(--safe-top);
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid #f0f0f0;
}

.nav-back {
    position: absolute;
    left: 12px;
    top: calc(50% + var(--safe-top) / 2);
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
}

.nav-back svg {
    width: 20px;
    height: 20px;
    display: block;
}

.nav-title {
    font-size: 17px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: #111;
}

.page {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background: #f3f4f6;
    padding-bottom: 28px;
}

/* ===== Hero 背景 ===== */
.hero {
    position: relative;
    height: 15.625rem;
    background:
        url("../images/bg.png") center top / cover no-repeat;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding-top: 36px;
}

.hero-title {
    font-size: 36px;
    font-weight: 800;
    color: #2e7d32;
    letter-spacing: 4px;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
    line-height: 1.2;
}

.hero-subtitle {
    margin-top: 8px;
    font-size: 14px;
    color: #4a5560;
    letter-spacing: 1px;
}

.hero-banner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 8px 20px;
    background: linear-gradient(90deg, #2e9e45, #3cb54f);
    color: #fff;
    font-size: 13px;
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(46, 158, 69, 0.35);
}

.hero-banner svg {
    flex-shrink: 0;
}

/* ===== 主卡片 ===== */
.card {
    position: relative;
    z-index: 3;
    margin: -70px 14px 0;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
    padding: 28px 18px 22px;
}

/* 品牌区 */
.brand {
    text-align: center;
}

.app-icon {
    width: 88px;
    height: 88px;
    margin: 0 auto;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(46, 125, 50, 0.25);
    background: linear-gradient(160deg, #87ceeb 0%, #90ee90 45%, #3cb371 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.app-icon svg {
    width: 64px;
    height: 64px;
}

.app-name {
    margin-top: 14px;
    font-size: 24px;
    font-weight: 800;
    color: #1a1a1a;
    letter-spacing: 2px;
}

.slogan {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 12px;
    color: #3cb54f;
    font-size: 13px;
}

.slogan::before,
.slogan::after {
    content: "";
    width: 36px;
    height: 1px;
    background: #3cb54f;
    opacity: 0.7;
}

/* 功能区 */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 28px;
    text-align: center;
    background-color: #e6ffe6;
    padding: 10px;
}

.feature-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 10px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-icon.green {
    background: #e8f7ec;
    color: #2e9e45;
}

.feature-icon.orange {
    background: #fff3e0;
    color: #f39c12;
}

.feature-title {
    font-size: 14px;
    font-weight: 700;
    color: #222;
    margin-bottom: 4px;
}

.feature-desc {
    font-size: 11px;
    color: #999;
    line-height: 1.4;
}

/* 下载区 */
.download-box {
    margin-top: 26px;
    background: #f7f8fa;
    border-radius: 14px;
    padding: 16px 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.qrcode {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
}

.qrcode canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.qrcode-logo {
    position: absolute;
    width: 22px;
    height: 22px;
    border-radius: 4px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 0 2px #fff;
}

.qrcode-logo svg {
    width: 18px;
    height: 18px;
}

.download-mid {
    flex: 1;
    min-width: 0;
    text-align: center;
}

.download-mid h3 {
    font-size: 15px;
    font-weight: 700;
    color: #222;
    margin-bottom: 4px;
}

.download-mid p {
    font-size: 11px;
    color: #999;
}

.download-btns {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 118px;
    height: 36px;
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
}

.btn-android {
    background: #3cb54f;
}

.btn-ios {
    background: #4a90e2;
}

.btn:active {
    opacity: 0.88;
}

.copy-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 14px;
    color: #3cb54f;
    font-size: 13px;
    cursor: pointer;
    background: none;
    border: none;
    width: 100%;
    font-family: inherit;
}

.copy-link:active {
    opacity: 0.7;
}

/* 版本信息 */
.version-bar {
    margin-top: 18px;
    background: #f7f8fa;
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 12px;
    color: #888;
}

.version-bar .label {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #555;
    font-weight: 700;
    margin-right: 4px;
}

.version-bar .sep {
    color: #ddd;
    margin: 0 2px;
}

/* 安全 / 安装 */
.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 14px;
}

.info-card {
    border-radius: 12px;
    padding: 14px 12px 12px;
    text-align: left;
}

.info-card.safe {
    background: #f3fbf5;
    border: 1px solid #d4efda;
}

.info-card.guide {
    background: #f3f8fd;
    border: 1px solid #d6e6f7;
}

.info-card .icon-wrap {
    margin-bottom: 8px;
}

.info-card h4 {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 8px;
}

.info-card.safe h4 {
    color: #2e9e45;
}

.info-card.guide h4 {
    color: #4a90e2;
}

.info-card p {
    font-size: 12px;
    color: #666;
    line-height: 1.55;
    margin-bottom: 10px;
    min-height: 56px;
}

.tag {
    display: inline-block;
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 999px;
    font-weight: 500;
}

.tag-green {
    background: #e4f6e8;
    color: #2e9e45;
}

.tag-blue {
    background: #e4f0fb;
    color: #4a90e2;
}

/* 页脚 */
.footer {
    margin-top: 22px;
    text-align: center;
    font-size: 12px;
    color: #aaa;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.footer-logo {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #cfd8dc;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.toast {
    position: fixed;
    left: 50%;
    bottom: 80px;
    transform: translateX(-50%) translateY(20px);
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 13px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.25s ease;
    z-index: 99;
    white-space: nowrap;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 380px) {
    .download-box {
        flex-wrap: wrap;
        justify-content: center;
    }

    .download-mid {
        width: 100%;
        order: -1;
        margin-bottom: 4px;
    }

    .hero-title {
        font-size: 30px;
    }
}