/* 响应式设计补充样式 */

/* 超大屏幕 (>= 1440px) */
@media (min-width: 1440px) {
    .container {
        max-width: 1400px;
    }
    
    .hero-title {
        font-size: 4rem;
    }
    
    .device-mockup {
        width: 350px;
        height: 700px;
    }
}

/* 中等屏幕 (768px - 1023px) */
@media (max-width: 1023px) and (min-width: 768px) {
    .hero-content {
        grid-template-columns: 1.2fr 1fr;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .device-mockup {
        width: 280px;
        height: 560px;
    }
}

/* 小屏幕 (576px - 767px) */
@media (max-width: 767px) and (min-width: 576px) {
    .hero {
        padding-top: 6rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .hero-stats {
        gap: var(--space-lg);
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .feature-card {
        padding: var(--space-lg);
    }
}

/* 超小屏幕 (< 576px) */
@media (max-width: 575px) {
    .container {
        padding: 0 var(--space-sm);
    }
    
    .hero {
        padding-top: 5rem;
        padding-bottom: var(--space-xl);
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-description {
        font-size: 0.9375rem;
        line-height: 1.6;
    }
    
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: var(--space-md);
        align-items: center;
    }
    
    .stat-item {
        align-items: center;
    }
    
    .device-mockup {
        width: 220px;
        height: 440px;
        margin-top: var(--space-lg);
    }
    
    .screen-content {
        padding: 1rem;
    }
    
    .app-stats {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .features {
        padding: var(--space-xl) 0;
    }
    
    .section-header {
        margin-bottom: var(--space-xl);
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .feature-card {
        padding: var(--space-lg);
    }
    
    .feature-icon {
        width: 56px;
        height: 56px;
        font-size: 1.25rem;
    }
    
    .feature-title {
        font-size: 1.125rem;
    }
    
    .footer {
        padding: var(--space-lg) 0;
    }
}

/* 横屏模式 */
@media (max-height: 600px) and (orientation: landscape) {
    .hero {
        padding-top: 6rem;
        padding-bottom: var(--space-xl);
        min-height: auto;
    }
    
    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-lg);
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 0.9375rem;
        margin-bottom: var(--space-lg);
    }
    
    .hero-actions {
        margin-bottom: var(--space-lg);
    }
    
    .device-mockup {
        width: 200px;
        height: 400px;
    }
}

/* 高DPI屏幕 (Retina) */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-icon {
        text-rendering: optimizeLegibility;
    }
    
    .feature-icon i {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* 打印样式 */
@media print {
    .navbar,
    .hero-actions,
    .device-mockup,
    .footer {
        display: none;
    }
    
    .hero {
        padding-top: 2rem;
        background: none !important;
    }
    
    .hero-title {
        color: #000 !important;
        font-size: 2rem;
    }
    
    .hero-description {
        color: #333 !important;
    }
    
    .features {
        page-break-before: always;
    }
    
    .feature-card {
        break-inside: avoid;
        border: 1px solid #ddd !important;
        box-shadow: none !important;
    }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
    :root {
        --dark-color: #f9fafb;
        --light-color: #1f2937;
        --white: #111827;
        --gray-light: #374151;
        --gray-dark: #d1d5db;
    }
    
    body {
        background-color: #111827;
        color: #f9fafb;
    }
    
    .navbar {
        background-color: rgba(17, 24, 39, 0.95);
    }
    
    .logo {
        color: #f9fafb;
    }
    
    .logo-sub {
        background: #374151;
        color: #9ca3af;
    }
    
    .nav-links a {
        color: #d1d5db;
    }
    
    .hero {
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    }
    
    .hero::before {
        opacity: 0.1;
    }
    
    .feature-card {
        background: #1f2937;
        border-color: #374151;
    }
    
    .feature-description {
        color: #9ca3af;
    }
    
    .footer {
        background-color: #030712;
    }
}

/* 运动减少偏好 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .device-mockup {
        animation: none !important;
    }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-links a,
    .app-btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .feature-card {
        padding: var(--space-lg);
    }
    
    .hero-actions .btn {
        padding: 1rem 1.5rem;
    }
}

/* 折叠屏设备 */
@media (max-width: 400px) {
    .logo-text {
        font-size: 1.25rem;
    }
    
    .logo-sub {
        font-size: 0.625rem;
        padding: 0.125rem 0.375rem;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-description br {
        display: none;
    }
    
    .device-mockup {
        width: 180px;
        height: 360px;
    }
    
    .app-btn {
        font-size: 0.75rem;
        padding: 0.5rem;
    }
}

/* 性能优化：延迟加载非关键资源 */
@media (max-width: 768px) {
    .hero::before {
        opacity: 0.5;
    }
    
    .device-mockup {
        transform: none !important;
    }
}