/* =========================================
   1. 全局变量定义
   ========================================= */
:root {
    --primary: #ff7eb3;       /* 樱花粉 */
    --secondary: #7afcff;     /* 霓虹蓝 */
    --accent: #8e44ad;        /* 深紫 */
    --bg-deep: #1a1a2e;       /* 背景色 */
    --bg-card: rgba(255, 255, 255, 0.05);
    --text-main: #ffffff;
    --text-muted: #b3b3b3;
    
    --font-main: 'Poppins', sans-serif;
    --font-cn: 'Noto Sans SC', sans-serif;
}

/* =========================================
   2. 基础重置
   ========================================= */
* { margin: 0; padding: 0; box-sizing: border-box; scroll-behavior: smooth; }
body {
    background-color: var(--bg-deep);
    color: var(--text-main);
    font-family: var(--font-cn), var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
}
a { text-decoration: none; color: inherit; transition: 0.3s ease; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* =========================================
   3. 导航栏
   ========================================= */
.navbar { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; padding: 1.2rem 0; transition: 0.4s ease; }
.navbar.scrolled { background: rgba(26, 26, 46, 0.95); backdrop-filter: blur(12px); box-shadow: 0 5px 20px rgba(0,0,0,0.3); padding: 0.8rem 0; }
.nav-content { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.8rem; font-weight: 800; color: #fff; letter-spacing: 1px; display: flex; align-items: center; gap: 8px; }
.logo span { color: var(--primary); text-shadow: 0 0 10px rgba(255, 126, 179, 0.5); }
.logo i { color: var(--secondary); }

.nav-links { display: flex; gap: 20px; }
.nav-links a { font-weight: 500; font-size: 0.95rem; opacity: 0.8; position: relative; }
.nav-links a:hover { opacity: 1; color: var(--primary); }
.nav-links a::after { content: ''; position: absolute; width: 0; height: 2px; bottom: -5px; left: 0; background-color: var(--secondary); transition: width 0.3s; }
.nav-links a:hover::after { width: 100%; }

.auth-btns { display: flex; align-items: center; }
.btn-reg { padding: 8px 24px; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 30px; font-weight: 700; color: #fff; font-size: 0.9rem; box-shadow: 0 4px 15px rgba(255, 126, 179, 0.3); transition: all 0.3s ease; display: flex; align-items: center; gap: 8px; }
.btn-reg:hover { transform: translateY(-2px); filter: brightness(1.1); }
.mobile-menu-btn { display: none; font-size: 1.5rem; cursor: pointer; color: #fff; }

/* =========================================
   4. Hero & 特性
   ========================================= */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; justify-content: center; padding-top: 80px; background: url('https://api.yppp.net/api.php') no-repeat center center/cover; background-attachment: fixed; }
.bg-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, rgba(26,26,46,0.92), rgba(46,12,75,0.85)); z-index: 1; }
.floating-shapes div { position: absolute; background: rgba(255,255,255,0.05); backdrop-filter: blur(3px); border-radius: 50%; z-index: 1; animation: float 10s infinite ease-in-out; }
.s1 { width: 100px; height: 100px; top: 20%; left: 10%; box-shadow: 0 0 20px var(--primary); opacity: 0.3; }
.s2 { width: 150px; height: 150px; bottom: 20%; right: 10%; animation-delay: -2s; background: linear-gradient(45deg, var(--secondary), transparent); opacity: 0.2; }
.s3 { width: 60px; height: 60px; top: 15%; right: 30%; animation-delay: -5s; border: 1px solid rgba(255,255,255,0.1); }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-25px); } }

.hero-content { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; width: 100%; }
.hero-text { flex: 1; max-width: 600px; padding-right: 50px; }
.tag { display: inline-block; background: rgba(122, 252, 255, 0.1); color: var(--secondary); padding: 6px 14px; border-radius: 4px; font-size: 0.85rem; font-weight: 600; margin-bottom: 20px; border: 1px solid rgba(122, 252, 255, 0.3); }
.hero-text h1 { font-size: 3.5rem; line-height: 1.2; margin-bottom: 25px; font-weight: 800; }
.highlight { background: linear-gradient(to right, var(--secondary), var(--primary)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-text p { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 35px; }

.hero-btns { display: flex; gap: 20px; margin-bottom: 45px; }
.btn { padding: 14px 32px; border-radius: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 8px; transition: 0.3s; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 0 25px rgba(255, 126, 179, 0.4); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 10px 35px rgba(255, 126, 179, 0.6); }
.btn-secondary { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.2); color: #fff; backdrop-filter: blur(5px); }
.btn-secondary:hover { background: rgba(255,255,255,0.15); border-color: #fff; }

.hero-stats { display: flex; gap: 50px; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 25px; }
.stat { display: flex; flex-direction: column; }
.stat b { font-size: 1.6rem; color: #fff; }
.stat span { font-size: 0.85rem; color: var(--text-muted); }

.hero-visual { flex: 1; display: flex; justify-content: flex-end; }
.glass-panel { width: 380px; background: linear-gradient(160deg, rgba(30, 30, 60, 0.7), rgba(20, 20, 40, 0.8)); backdrop-filter: blur(20px); border: 1px solid rgba(255,255,255,0.1); border-radius: 20px; padding: 25px; box-shadow: 0 20px 60px rgba(0,0,0,0.6); transform: perspective(1000px) rotateY(-10deg) rotateX(5deg); transition: 0.5s ease-out; }
.glass-panel:hover { transform: perspective(1000px) rotateY(0deg) rotateX(0deg); border-color: rgba(122, 252, 255, 0.3); }
.panel-header { display: flex; gap: 8px; margin-bottom: 20px; }
.dot { width: 12px; height: 12px; border-radius: 50%; }
.red { background: #ff5f56; } .yellow { background: #ffbd2e; } .green { background: #27c93f; }
.status-row { display: flex; justify-content: space-between; margin-bottom: 12px; font-size: 0.9rem; color: #ccc; font-family: monospace; }
.online { color: var(--secondary); text-shadow: 0 0 8px var(--secondary); }
.ping { color: var(--primary); font-weight: bold; }
.graph-box { height: 80px; background: rgba(0,0,0,0.4); border-radius: 8px; margin: 20px 0; overflow: hidden; position: relative; border: 1px solid rgba(255,255,255,0.05); }
.wave { position: absolute; bottom: 0; left: 0; width: 200%; height: 100%; background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%237afcff" fill-opacity="0.3" d="M0,192L48,197.3C96,203,192,213,288,229.3C384,245,480,267,576,250.7C672,235,768,181,864,181.3C960,181,1056,235,1152,234.7C1248,235,1344,181,1392,154.7L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>'); background-size: 50% 100%; animation: waveMove 6s linear infinite; }
@keyframes waveMove { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.code-text { font-family: monospace; font-size: 0.75rem; color: #888; border-top: 1px dashed rgba(255,255,255,0.1); padding-top: 10px; }

.section { padding: 80px 0; position: relative; }
.section-title { text-align: center; margin-bottom: 60px; }
.section-title h2 { font-size: 2.5rem; margin-bottom: 15px; background: linear-gradient(to right, #fff, #ccc); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.section-title p { color: var(--text-muted); font-size: 1.1rem; }

/* Grid Box */
.grid-box { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 30px; }
.feature-card { background: var(--bg-card); padding: 40px 30px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.05); transition: 0.4s; position: relative; overflow: hidden; }
.feature-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px; background: linear-gradient(90deg, transparent, var(--primary), var(--secondary), transparent); transform: translateX(-100%); transition: 0.5s; }
.feature-card:hover { transform: translateY(-10px); background: rgba(255,255,255,0.08); }
.feature-card:hover::before { transform: translateX(100%); }
.icon-box { width: 65px; height: 65px; background: linear-gradient(135deg, rgba(255, 126, 179, 0.15), rgba(122, 252, 255, 0.15)); border-radius: 18px; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; color: #fff; margin-bottom: 25px; border: 1px solid rgba(255,255,255,0.05); }
.feature-card h3 { font-size: 1.3rem; margin-bottom: 15px; color: #fff; }
.feature-card p { font-size: 0.95rem; color: var(--text-muted); }

/* =========================================
   5. 网络检测
   ========================================= */
.network-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.network-card { background: var(--bg-card); border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; padding: 15px 20px; display: flex; flex-direction: column; justify-content: space-between; transition: 0.3s; position: relative; overflow: hidden; height: 90px; }
.network-card:hover { background: rgba(255,255,255,0.08); transform: translateY(-3px); box-shadow: 0 10px 20px rgba(0,0,0,0.2); }
.card-top { display: flex; justify-content: space-between; align-items: center; }
.site-info { display: flex; align-items: center; gap: 10px; font-weight: 600; color: #fff; font-size: 0.95rem; }
.site-info i { font-size: 1.1rem; width: 20px; text-align: center; }
.custom-icon { display: flex; align-items: center; justify-content: center; width: 20px; height: 20px; }
.custom-icon svg { width: 100%; height: 100%; }
.fa-bilibili { color: #23ade5; } .fa-weixin { color: #09b83e; } .fa-bag-shopping { color: #ff5000; } .fa-github { color: #fff; } .fa-youtube { color: #ff0000; }
.ping-info { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.ping-val { font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 1rem; }
.ping-val.loading { font-size: 0.8rem; color: #888; animation: pulse 1s infinite; }
.region-tag { font-size: 0.65rem; padding: 2px 6px; border-radius: 4px; background: rgba(255,255,255,0.1); color: #bbb; }
.status-bar-container { display: flex; gap: 4px; margin-top: 10px; }
.status-bar { height: 4px; flex: 1; border-radius: 2px; background: rgba(255,255,255,0.1); transition: background 0.5s ease; }
.status-green .ping-val { color: #27c93f; } .status-green .region-tag { background: rgba(39, 201, 63, 0.15); color: #27c93f; } .status-green.active .status-bar { background: #27c93f; }
.status-orange .ping-val { color: #ff6901; } .status-orange .region-tag { background: rgba(255, 105, 1, 0.15); color: #ff8a3d; } .status-orange.active .status-bar { background: #ff6901; }
@keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.5; } }

/* =========================================
   6. 三步上手 (Guide) - 紧凑设计
   ========================================= */
.guide-section { background: rgba(0,0,0,0.1); }
.left-align { text-align: left; margin-bottom: 30px; }
/* Grid 布局 */
.guide-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 30px; }

/* 紧凑卡片 */
.guide-card {
    background: var(--bg-card);
    border: 1px solid rgba(255,255,255,0.08);
    padding: 25px; /* 减小内边距 */
    border-radius: 16px;
    transition: 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.guide-card:hover { transform: translateY(-5px); border-color: var(--secondary); background: rgba(255,255,255,0.08); }

.step-header { display: flex; align-items: center; gap: 15px; margin-bottom: 15px; }
.step-num { width: 32px; height: 32px; border: 1px solid rgba(255,255,255,0.2); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: bold; font-family: 'Poppins'; color: var(--text-muted); font-size: 0.8rem; }
.guide-card h3 { font-size: 1.1rem; color: #fff; margin: 0; }
.guide-card p { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 15px; flex-grow: 1; line-height: 1.5; }

.guide-link { color: var(--secondary); font-size: 0.85rem; font-weight: 600; }
.code-preview { background: rgba(0,0,0,0.3); padding: 8px 12px; border-radius: 8px; font-family: monospace; font-size: 0.75rem; color: #aaa; border: 1px dashed rgba(255,255,255,0.1); word-break: break-all; margin-top: auto; }
.tags-group { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.g-tag { font-size: 0.7rem; padding: 3px 8px; border-radius: 20px; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); color: #ccc; }

.guide-footer-bar { background: rgba(255,255,255,0.05); border-radius: 16px; padding: 20px 30px; display: flex; align-items: center; justify-content: space-between; border: 1px solid rgba(255,255,255,0.05); }
.gf-text h3 { margin-bottom: 5px; font-size: 1.1rem; }
.gf-text p { font-size: 0.85rem; color: var(--text-muted); }
.gf-btns { display: flex; gap: 15px; }
.small-btn { padding: 8px 20px; font-size: 0.85rem; }

/* =========================================
   7. 客户端下载区 (精简版)
   ========================================= */
.client-section.compact { padding: 30px 0; border-top: 1px solid rgba(255,255,255,0.05); border-bottom: 1px solid rgba(255,255,255,0.05); }
.client-mini-wrapper { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.client-header h2 { font-size: 1.4rem; margin-bottom: 5px; }
.client-header p { font-size: 0.9rem; color: var(--text-muted); }
.client-mini-icons { display: flex; gap: 30px; }
.mini-os { display: flex; flex-direction: column; align-items: center; gap: 5px; color: var(--text-muted); transition: 0.3s; cursor: default; }
.mini-os i { font-size: 1.6rem; }
.mini-os span { font-size: 0.8rem; }
.mini-os:hover { color: var(--primary); transform: translateY(-3px); }

/* =========================================
   8. 订阅计划
   ========================================= */
.pricing-grid { display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; }
.price-card { background: var(--bg-card); border: 1px solid rgba(255,255,255,0.08); border-radius: 24px; padding: 40px; width: 340px; text-align: center; position: relative; transition: 0.3s; display: flex; flex-direction: column; }
.price-card:hover { transform: scale(1.02); background: rgba(22, 22, 40, 0.9); border-color: rgba(255,255,255,0.2); }
.price-card.popular { border: 2px solid var(--primary); background: rgba(255, 126, 179, 0.03); box-shadow: 0 0 40px rgba(255, 126, 179, 0.1); }
.badge-pop { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); background: var(--primary); color: #fff; padding: 6px 20px; border-radius: 20px; font-weight: bold; }
.price-header h3 { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 20px; }
.price { font-size: 3rem; font-weight: 700; color: #fff; margin-bottom: 10px; }
.price span { font-size: 1rem; font-weight: 400; color: #888; }
.price-features { margin: 30px 0; text-align: left; flex-grow: 1; }
.price-features li { margin-bottom: 18px; color: #ccc; display: flex; align-items: center; }
.price-features i { color: var(--secondary); margin-right: 12px; }
.btn-price { display: block; width: 100%; padding: 14px; border-radius: 12px; border: 1px solid rgba(255,255,255,0.2); margin-top: 20px; font-weight: 600; transition: 0.3s; color: #fff; }
.btn-price:hover { background: #fff; color: #000; }
.btn-price.primary { background: var(--primary); border: none; }
.btn-price.primary:hover { background: #ff5f9e; color: #fff; }

/* =========================================
   9. 关于我们
   ========================================= */
.about-wrapper { text-align: center; padding: 20px 0; }
.about-header { margin-bottom: 30px; }
.about-text-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; text-align: left; }
.about-p { background: rgba(255,255,255,0.03); padding: 30px; border-radius: 15px; border: 1px solid rgba(255,255,255,0.05); transition: 0.3s; }
.about-p:hover { background: rgba(255,255,255,0.06); transform: translateY(-5px); }
.about-p p { color: var(--text-muted); margin-bottom: 0; font-size: 0.95rem; line-height: 1.8; }

/* =========================================
   10. FAQ 问答
   ========================================= */
.faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 40px; }
.faq-item { background: var(--bg-card); border: 1px solid rgba(255,255,255,0.08); border-radius: 12px; overflow: hidden; transition: 0.3s; }
.faq-item:hover { background: rgba(255,255,255,0.08); }
.faq-question { padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; font-weight: 600; font-size: 0.9rem; }
.faq-question i { transition: 0.3s; color: var(--text-muted); }
.faq-answer { max-height: 0; overflow: hidden; transition: 0.3s ease; padding: 0 20px; color: var(--text-muted); font-size: 0.85rem; line-height: 1.6; }
.faq-item.active { border-color: var(--primary); background: rgba(255,255,255,0.08); }
.faq-item.active .faq-question i { transform: rotate(180deg); color: var(--primary); }
.faq-item.active .faq-answer { max-height: 150px; padding-bottom: 20px; }

/* =========================================
   11. 页脚与适配
   ========================================= */
footer { background: #0f0f1a; padding: 60px 0 30px; border-top: 1px solid rgba(255,255,255,0.05); }
.footer-content { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 50px; margin-bottom: 40px; }
.footer-col h4 { color: #fff; margin-bottom: 20px; font-size: 1.2rem; }
.footer-col p { color: #888; font-size: 0.9rem; max-width: 300px; }
.footer-col a { display: block; color: #888; margin-bottom: 10px; transition: 0.3s; }
.footer-col a:hover { color: var(--primary); transform: translateX(5px); }
.copyright { text-align: center; border-top: 1px solid rgba(255,255,255,0.05); padding-top: 20px; color: #555; font-size: 0.85rem; }

/* 移动端适配 (核心优化) */
@media (max-width: 992px) {
    .client-mini-wrapper { flex-direction: column; text-align: center; gap: 20px; }
    .about-text-grid { grid-template-columns: 1fr; gap: 20px; }
    .guide-grid { grid-template-columns: 1fr; } /* 三步引导变单列 */
    .faq-grid { grid-template-columns: 1fr; }   /* FAQ变单列 */
    .guide-footer-bar { flex-direction: column; text-align: center; gap: 20px; }
}

@media (max-width: 768px) {
    .navbar { padding: 1rem 0; }
    .nav-links { display: none; }
    .mobile-menu-btn { display: block; font-size: 1.4rem; }
    .auth-btns { position: absolute; right: 60px; top: 50%; transform: translateY(-50%); }
    .btn-reg { padding: 6px 16px; font-size: 0.8rem; }
    
    .hero { padding-top: 100px; text-align: center; padding-bottom: 60px; }
    .hero-content { flex-direction: column; }
    .hero-text { padding-right: 0; margin-bottom: 50px; }
    .hero-btns { justify-content: center; flex-wrap: wrap; }
    .hero-stats { justify-content: center; gap: 25px; }
    .hero-visual { width: 100%; justify-content: center; }
    .glass-panel { width: 100%; transform: none; margin-top: 20px; }
    
    .pricing-grid { flex-direction: column; align-items: center; }
    .price-card { width: 100%; max-width: 340px; }
    .footer-content { grid-template-columns: 1fr; text-align: center; gap: 30px; }
    
    /* 网络卡片2列 */
    .network-grid { grid-template-columns: repeat(2, 1fr); }
    .network-card { height: 80px; padding: 10px; }
}