/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
    overflow-x: hidden;
}

/* 应用容器 */
.app-container {
    max-width: 414px;
    margin: 0 auto;
    background: #f8f9fa;
    min-height: 100vh;
    position: relative;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.1);
}

/* 顶部导航栏 */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 50px 24px 24px;
    color: white;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.logo-icon:hover {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.3);
}

.logo-text {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.notification-btn {
    background: rgba(255, 255, 255, 0.25);
    border: none;
    border-radius: 16px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: relative;
}

.notification-btn:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(1.05);
}

.notification-btn:active {
    transform: scale(0.95);
}

.notification-btn::after {
    content: '';
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: #ff4757;
    border-radius: 50%;
    border: 2px solid white;
    opacity: 0;
    animation: pulse 2s infinite;
}

.notification-btn.has-notification::after {
    opacity: 1;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* 主要内容区域 */
.main-content {
    padding: 0 0 100px 0;
    min-height: calc(100vh - 160px);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 欢迎横幅 */
.welcome-banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: -1px 0 0 0;
    padding: 48px 24px 56px;
    color: white;
    position: relative;
    overflow: hidden;
}

.banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.banner-title {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.8px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    line-height: 1.2;
}

.banner-subtitle {
    font-size: 18px;
    opacity: 0.95;
    font-weight: 500;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: 0.2px;
}

.banner-decoration {
    position: absolute;
    top: -80px;
    right: -80px;
    width: 280px;
    height: 280px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    z-index: 1;
}

.banner-decoration::before {
    content: '';
    position: absolute;
    top: 40px;
    left: 40px;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
}

.banner-decoration::after {
    content: '';
    position: absolute;
    top: 80px;
    left: 80px;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 50%;
}

/* 通用区块样式 */
.section-title {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1a1a1a;
    padding: 0 20px;
}

/* 服务卡片网格 */
.services-section {
    padding: 30px 0;
    background: white;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding: 0 20px;
}

.service-card {
    background: white;
    border-radius: 16px;
    padding: 24px 16px;
    text-align: center;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.service-icon {
    font-size: 32px;
    margin-bottom: 12px;
    display: block;
}

.service-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.service-desc {
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

/* 服务优势 */
.advantages-section {
    padding: 30px 20px;
    background: #f8f9fa;
}

.advantages-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.advantage-item {
    display: flex;
    align-items: center;
    gap: 16px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.advantage-icon {
    font-size: 24px;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.advantage-content h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1a1a1a;
}

.advantage-content p {
    font-size: 14px;
    color: #666;
}

/* 统计数据 */
.stats-section {
    padding: 30px 20px;
    background: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.stat-card {
    text-align: center;
    padding: 24px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    color: white;
}

.stat-number {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 13px;
    opacity: 0.9;
}

/* 站点页面 */
.sites-section {
    padding: 30px 20px;
    background: white;
    min-height: calc(100vh - 200px);
}

.sites-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.site-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid #f0f0f0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.site-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.site-icon {
    font-size: 28px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.site-info {
    flex: 1;
}

.site-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1a1a1a;
}

.site-desc {
    font-size: 13px;
    color: #666;
    margin-bottom: 6px;
}

.site-url {
    font-size: 12px;
    color: #667eea;
    font-weight: 500;
}

.site-arrow {
    font-size: 18px;
    color: #ccc;
    font-weight: 600;
}

/* 联系页面 */
.contact-section {
    padding: 30px 20px;
    background: white;
    min-height: calc(100vh - 200px);
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}

.contact-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid #f0f0f0;
}

.contact-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.contact-icon.wechat {
    background: linear-gradient(135deg, #07c160 0%, #00d4aa 100%);
}

.contact-icon.qq {
    background: linear-gradient(135deg, #12b7f5 0%, #0099ff 100%);
}

.contact-icon.email {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
}

.contact-icon.phone {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.contact-info {
    flex: 1;
}

.contact-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1a1a1a;
}

.contact-detail {
    font-size: 14px;
    color: #666;
    margin-bottom: 12px;
}

.contact-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.contact-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.business-hours {
    background: #f8f9fa;
    padding: 24px;
    border-radius: 16px;
}

.hours-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    color: #1a1a1a;
}

.hours-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hours-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hours-day {
    font-size: 14px;
    color: #666;
}

.hours-time {
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
}

/* 简介页面 */
.about-section {
    padding: 30px 20px;
    background: white;
    min-height: calc(100vh - 200px);
}

.team-intro {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 40px;
}

.intro-card {
    display: flex;
    gap: 16px;
    background: white;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    border: 1px solid #f0f0f0;
}

.intro-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.intro-content {
    flex: 1;
}

.intro-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.intro-text {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

.team-stats {
    background: #f8f9fa;
    padding: 24px;
    border-radius: 16px;
}

.stats-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1a1a1a;
    text-align: center;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 4px;
}

.stat-desc {
    font-size: 12px;
    color: #666;
}

/* 底部导航栏 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 414px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
    z-index: 1000;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 8px 4px;
    border-radius: 12px;
    margin: 0 4px;
}

.nav-item:hover {
    background: rgba(102, 126, 234, 0.1);
}

.nav-item.active {
    background: rgba(102, 126, 234, 0.15);
}

.nav-item.active .nav-icon {
    transform: scale(1.1);
}

.nav-item.active .nav-label {
    color: #667eea;
    font-weight: 600;
}

.nav-icon {
    font-size: 20px;
    transition: all 0.3s ease;
}

.nav-label {
    font-size: 11px;
    color: #666;
    font-weight: 500;
    transition: all 0.3s ease;
}

/* Toast 提示 */
.toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    z-index: 10000;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.toast.show {
    transform: translate(-50%, -50%) scale(1);
}

/* 响应式设计 */
@media (max-width: 375px) {
    .services-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .stats-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .service-card,
    .stat-card {
        padding: 20px 16px;
    }
    
    .banner-title {
        font-size: 24px;
    }
    
    .section-title {
        font-size: 20px;
    }
}

@media (min-width: 415px) {
    .app-container {
        border-radius: 0;
    }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
    }
    
    .app-container {
        background: #1a202c;
    }
    
    .main-content {
        background: #1a202c;
    }
    
    .services-section,
    .stats-section,
    .sites-section,
    .contact-section,
    .about-section {
        background: #1a202c;
    }
    
    .service-card,
    .site-card,
    .contact-card,
    .intro-card,
    .advantage-item {
        background: #2d3748;
        border-color: #4a5568;
    }
    
    .section-title,
    .service-title,
    .site-title,
    .contact-title,
    .intro-title,
    .advantage-content h4 {
        color: #e2e8f0;
    }
    
    .service-desc,
    .site-desc,
    .contact-detail,
    .intro-text,
    .advantage-content p,
    .hours-day,
    .hours-time,
    .stat-desc {
        color: #a0aec0;
    }
    
    .business-hours,
    .team-stats {
        background: #2d3748;
    }
    
    .bottom-nav {
        background: rgba(26, 32, 44, 0.95);
        border-top-color: rgba(255, 255, 255, 0.1);
    }
    
    .nav-label {
        color: #a0aec0;
    }
    
    .nav-item.active .nav-label {
        color: #667eea;
    }
}

/* 动画效果 */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.service-card,
.advantage-item,
.stat-card,
.site-card,
.contact-card,
.intro-card {
    animation: slideUp 0.6s ease-out;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }
.service-card:nth-child(4) { animation-delay: 0.4s; }
.service-card:nth-child(5) { animation-delay: 0.5s; }

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 4px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.3);
    border-radius: 2px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.5);
}

/* 安全区域适配 */
@supports (padding: max(0px)) {
    .header {
        padding-top: max(44px, env(safe-area-inset-top));
    }
    
    .bottom-nav {
        padding-bottom: max(12px, env(safe-area-inset-bottom));
    }
}
