/* 96视频 · 官方下载页（/dl2/ 预览版）
 * 纯原生 CSS，移动优先；深黑底 + 品牌青 #25F4EE / 红 #FE2C55 + Logo 橙点缀
 * 兼容 iPhone 刘海/底部安全区：env(safe-area-inset-*)
 */

:root {
    --bg: #08080C;
    --bg-soft: #101017;
    --card: #14141B;
    --card-2: #191922;
    --line: rgba(255, 255, 255, .085);
    --line-2: rgba(255, 255, 255, .14);
    --text: #F5F5F7;
    --text-2: #A9A9B8;
    --text-3: #6F6F80;
    --teal: #25F4EE;
    --red: #FE2C55;
    --orange: #FF8A3D;
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --max: 520px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-size-adjust: 100%;
}

body { min-height: 100vh; min-height: 100dvh; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; border: 0; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }

/* ============================ 顶栏 ============================ */

.topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    padding: calc(10px + var(--safe-top)) 16px 10px;
    background: rgba(8, 8, 12, .78);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}

.topbar-inner {
    max-width: var(--max);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }

.brand-logo {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 6px 18px rgba(0, 0, 0, .45);
}

.brand-name {
    font-size: 17px;
    font-weight: 800;
    letter-spacing: .2px;
    white-space: nowrap;
}

.brand-tag {
    margin-left: 2px;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    color: #0A0A0F;
    background: linear-gradient(135deg, var(--teal), #7CF9F5);
}

.top-actions { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }

.icon-btn {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, .055);
    border: 1px solid var(--line);
    transition: transform .12s ease, background .12s ease;
}

.icon-btn:active { transform: scale(.94); background: rgba(255, 255, 255, .1); }
.icon-btn svg { width: 18px; height: 18px; stroke: var(--text-2); fill: none; stroke-width: 1.8; }

/* ============================ 主体 ============================ */

.wrap {
    max-width: var(--max);
    margin: 0 auto;
    padding: 16px 16px calc(170px + var(--safe-bottom));
}

.promo {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: linear-gradient(160deg, #12121A, #0B0B11);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}

.promo img {
    width: 100%;
    height: auto;
    /* 不锁 2:3、不裁切：站主给的是长图，按原始比例完整展示 */
    object-fit: contain;
    background: #0E0E14;
}

/* 占位提示：只有图片缺失时出现，放在图片下方一行很淡的小字（不叠在图上，避免与图内文字重复） */
.promo-cap {
    margin: 8px 4px 0;
    font-size: 10.5px;
    line-height: 1.6;
    color: var(--text-3);
    text-align: center;
    letter-spacing: .2px;
}

.promo-cap[hidden] { display: none; }

/* 标题区 */
.hero { padding: 20px 2px 6px; }

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    color: var(--teal);
    background: rgba(37, 244, 238, .09);
    border: 1px solid rgba(37, 244, 238, .25);
}

.hero-badge i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 8px var(--teal);
}

.hero-title {
    margin: 12px 0 6px;
    font-size: 26px;
    line-height: 1.24;
    font-weight: 900;
    letter-spacing: -.3px;
}

.hero-title em {
    font-style: normal;
    background: linear-gradient(100deg, var(--teal), #9DFBF7 45%, var(--red));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-sub { margin: 0; font-size: 13.5px; line-height: 1.75; color: var(--text-2); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

.chip {
    padding: 6px 10px;
    border-radius: 10px;
    font-size: 11.5px;
    color: var(--text-2);
    background: rgba(255, 255, 255, .045);
    border: 1px solid var(--line);
}

.chip b { color: var(--text); font-weight: 700; }

/* 功能卡 */
.section { margin-top: 26px; }

.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 12px; }

.section-title { margin: 0; font-size: 16px; font-weight: 800; }

.section-more { font-size: 11.5px; color: var(--text-3); }

.feature-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }

.feature {
    display: flex;
    gap: 12px;
    padding: 14px;
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--line);
}

.feature-ico {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    background: rgba(37, 244, 238, .08);
    border: 1px solid rgba(37, 244, 238, .18);
}

.feature-ico svg { width: 19px; height: 19px; stroke: var(--teal); fill: none; stroke-width: 1.8; }
.feature:nth-child(2) .feature-ico { background: rgba(254, 44, 85, .09); border-color: rgba(254, 44, 85, .2); }
.feature:nth-child(2) .feature-ico svg { stroke: var(--red); }
.feature:nth-child(3) .feature-ico { background: rgba(255, 138, 61, .1); border-color: rgba(255, 138, 61, .22); }
.feature:nth-child(3) .feature-ico svg { stroke: var(--orange); }

.feature-title { margin: 1px 0 4px; font-size: 13.5px; font-weight: 700; }
.feature-text { margin: 0; font-size: 12px; line-height: 1.65; color: var(--text-2); }

/* ============================ 底部固定下载条 ============================ */

.dlbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    padding: 10px 12px calc(10px + var(--safe-bottom));
    background: linear-gradient(180deg, rgba(8, 8, 12, 0), rgba(8, 8, 12, .9) 24%, #08080C 62%);
    pointer-events: none;
}

.dlbar-inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 11px;
    border-radius: 18px;
    background: rgba(19, 19, 26, .94);
    border: 1px solid var(--line-2);
    box-shadow: 0 18px 50px rgba(0, 0, 0, .55);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    pointer-events: auto;
}

.bar-pane[hidden] { display: none !important; }

.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 50px;
    padding: 0 18px;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: .2px;
    color: #fff;
    border: 1px solid transparent;
    transition: transform .12s ease, opacity .12s ease;
}

.btn:active { transform: scale(.985); opacity: .92; }
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.1; stroke-linecap: round; stroke-linejoin: round; }

.btn-primary { background: linear-gradient(135deg, var(--red), #FF5C7C 58%, #FF8A3D); box-shadow: 0 8px 26px rgba(254, 44, 85, .38); }
.btn-ios { background: linear-gradient(135deg, #12C9C4, var(--teal) 60%, #9DFBF7); color: #041B1A; box-shadow: 0 8px 26px rgba(37, 244, 238, .26); }
.btn-primary small, .btn-ios small { font-size: 11px; font-weight: 700; opacity: .8; }

.bar-hint { margin: 8px 2px 0; font-size: 11.5px; line-height: 1.55; color: var(--text-2); text-align: center; }
.bar-hint .link { color: var(--teal); text-decoration: underline; text-underline-offset: 2px; }

/* PC：扫码 */
.pc-qr { display: flex; align-items: center; gap: 14px; }

.qr-frame {
    flex: 0 0 auto;
    width: 104px;
    height: 104px;
    padding: 7px;
    border-radius: 12px;
    background: #fff;
    display: grid;
    place-items: center;
}

.qr-frame canvas { width: 90px; height: 90px; display: block; }

.qr-meta { min-width: 0; }
.qr-title { margin: 0 0 5px; font-size: 14px; font-weight: 800; }
.qr-text { margin: 0; font-size: 11.5px; line-height: 1.6; color: var(--text-2); }
.qr-url { margin: 6px 0 0; font-size: 10.5px; color: var(--text-3); word-break: break-all; }

/* ============================ 安装指引弹窗 ============================ */

.modal {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 0;
    background: rgba(0, 0, 0, .62);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.modal[hidden] { display: none !important; }

.modal-card {
    width: 100%;
    max-width: var(--max);
    max-height: 86vh;
    max-height: 86dvh;
    display: flex;
    flex-direction: column;
    background: #101018;
    border: 1px solid var(--line-2);
    border-bottom: 0;
    border-radius: 20px 20px 0 0;
    padding-bottom: calc(12px + var(--safe-bottom));
    animation: sheetUp .22s ease-out;
}

@keyframes sheetUp { from { transform: translateY(28px); opacity: .6; } to { transform: none; opacity: 1; } }

.modal-head {
    position: relative;
    padding: 18px 18px 10px;
    border-bottom: 1px solid var(--line);
}

.modal-grab {
    position: absolute;
    top: 7px;
    left: 50%;
    width: 38px;
    height: 4px;
    margin-left: -19px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .18);
}

.modal-title { margin: 4px 0 4px; font-size: 17px; font-weight: 800; text-align: center; }
.modal-sub { margin: 0; font-size: 12px; line-height: 1.6; color: var(--text-2); text-align: center; }

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, .07);
}

.modal-close svg { width: 15px; height: 15px; stroke: var(--text-2); stroke-width: 2; }

.brand-tabs {
    display: flex;
    gap: 7px;
    padding: 12px 14px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.brand-tabs::-webkit-scrollbar { display: none; }

.brand-tab {
    flex: 0 0 auto;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-2);
    background: rgba(255, 255, 255, .05);
    border: 1px solid var(--line);
    white-space: nowrap;
}

.brand-tab.is-on {
    color: #041B1A;
    background: var(--teal);
    border-color: var(--teal);
    font-weight: 800;
}

.modal-body { padding: 4px 18px 14px; overflow-y: auto; -webkit-overflow-scrolling: touch; }

.guide-steps { margin: 0; padding: 0; list-style: none; counter-reset: gs; }

.guide-steps li {
    position: relative;
    padding: 0 0 14px 38px;
    font-size: 13px;
    line-height: 1.72;
    color: var(--text-2);
    counter-increment: gs;
}

.guide-steps li::before {
    content: counter(gs);
    position: absolute;
    left: 0;
    top: 1px;
    width: 24px;
    height: 24px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    font-size: 11.5px;
    font-weight: 800;
    color: var(--teal);
    background: rgba(37, 244, 238, .09);
    border: 1px solid rgba(37, 244, 238, .22);
}

.guide-steps li b { color: var(--text); font-weight: 700; }

.guide-tip {
    margin: 2px 0 14px;
    padding: 11px 13px;
    border-radius: 12px;
    font-size: 11.5px;
    line-height: 1.7;
    color: #FFD9C9;
    background: rgba(255, 138, 61, .09);
    border: 1px solid rgba(255, 138, 61, .22);
}

.guide-tip b { color: var(--orange); }

.modal-actions { display: flex; gap: 10px; padding: 0 18px; }
.modal-actions .btn { min-height: 46px; font-size: 15px; }
.btn-ghost { background: rgba(255, 255, 255, .06); border-color: var(--line-2); color: var(--text-2); flex: 0 0 34%; }
.btn-continue { flex: 1 1 auto; }

/* ============================ 其它 ============================ */

.foot {
    margin: 28px 0 0;
    padding: 0 4px;
    font-size: 11px;
    line-height: 1.8;
    color: var(--text-3);
    text-align: center;
}

.foot a { color: var(--text-2); text-decoration: underline; text-underline-offset: 2px; }

.toast {
    position: fixed;
    left: 50%;
    bottom: calc(120px + var(--safe-bottom));
    z-index: 80;
    transform: translateX(-50%) translateY(8px);
    padding: 9px 16px;
    border-radius: 999px;
    font-size: 12.5px;
    color: #fff;
    background: rgba(20, 20, 27, .96);
    border: 1px solid var(--line-2);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
    max-width: 86vw;
    text-align: center;
}

.toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (min-width: 620px) {
    .wrap { padding-top: 22px; }
    .hero-title { font-size: 30px; }
    .feature-grid { grid-template-columns: 1fr 1fr 1fr; }
    .feature { flex-direction: column; }
    .dlbar { padding-bottom: calc(16px + var(--safe-bottom)); }
}
