:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #3b82f6;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --bg-primary: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-logo i {
    font-size: 1.8rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: var(--transition);
}

.nav-menu a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: var(--transition);
}

/* 主页横幅 */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: var(--bg-gradient);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.05"/><circle cx="10" cy="60" r="0.5" fill="white" opacity="0.05"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content {
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    animation: fadeInUp 1s ease-out;
}

.gradient-text {
    background: linear-gradient(45deg, #fff, #f0f9ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    animation: fadeInUp 1s ease-out 0.4s both;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: white;
    color: var(--primary-color);
    box-shadow: var(--shadow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: var(--primary-color);
}

/* 时钟预览 */
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeIn 1s ease-out 0.6s both;
}

.clock-preview {
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    position: relative;
}

.clock-face {
    width: 250px;
    height: 250px;
    background: white;
    border-radius: 50%;
    position: relative;
    box-shadow: var(--shadow-lg);
}

.clock-hand {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: bottom center;
    border-radius: 10px;
}

.hour-hand {
    width: 4px;
    height: 60px;
    background: var(--text-primary);
    margin-left: -2px;
    margin-top: -60px;
    animation: rotateHour 43200s linear infinite;
}

.minute-hand {
    width: 3px;
    height: 80px;
    background: var(--text-secondary);
    margin-left: -1.5px;
    margin-top: -80px;
    animation: rotateMinute 3600s linear infinite;
}

.second-hand {
    width: 2px;
    height: 90px;
    background: var(--primary-color);
    margin-left: -1px;
    margin-top: -90px;
    animation: rotateSecond 60s linear infinite;
}

.clock-center {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

/* 功能区域 */
.features {
    padding: 100px 0;
    background: var(--bg-secondary);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 60px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.feature-card {
    background: white;
    padding: 40px 30px;
    border-radius: var(--border-radius);
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--bg-gradient);
    transform: scaleX(0);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--bg-gradient);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 20px;
    color: white;
    font-size: 2rem;
}

.feature-card h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* 应用特色 */
.highlights {
    padding: 100px 0;
    background: white;
}

.highlights-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    text-align: center;
}

.highlight-item {
    padding: 30px;
    border-radius: var(--border-radius);
    background: var(--bg-secondary);
    transition: var(--transition);
}

.highlight-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.highlight-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.highlight-item h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.highlight-item p {
    color: var(--text-secondary);
}

/* 海报展示 */
.gallery {
    padding: 100px 0;
    background: var(--bg-secondary);
}

.poster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.poster-item {
    aspect-ratio: 9/16;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
}

.poster-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.poster-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.poster-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 1.2rem;
}

.poster-placeholder i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.8;
}

.upload-instruction {
    text-align: center;
    padding: 30px;
    background: white;
    border-radius: var(--border-radius);
    border: 2px dashed var(--text-secondary);
    color: var(--text-secondary);
}

.upload-instruction i {
    font-size: 2rem;
    margin-bottom: 15px;
    display: block;
}

/* 下载区域 */
.download {
    padding: 100px 0;
    background: white;
}

.download-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.download-info {
    margin-bottom: 40px;
}

.download-info h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.download-info p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

.download-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.download-btn {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px 30px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
    min-width: 200px;
}

.download-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.download-btn i {
    font-size: 2rem;
}

.download-text {
    display: block;
    font-weight: 600;
    font-size: 1.1rem;
}

.download-subtext {
    display: block;
    font-size: 0.9rem;
    opacity: 0.7;
}

/* 页脚 */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    text-align: center;
    margin-bottom: 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-description {
    font-size: 1.1rem;
    opacity: 0.8;
    margin-bottom: 30px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-links a {
    color: white;
    font-size: 1.5rem;
    transition: var(--transition);
    opacity: 0.7;
}

.footer-links a:hover {
    opacity: 1;
    transform: translateY(-2px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.6;
}

/* 动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes rotateHour {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes rotateMinute {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes rotateSecond {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* 二维码弹窗 */
.qrcode-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #ffffff;
    border-radius: var(--border-radius);
    box-shadow: 0 18px 50px -10px rgba(0,0,0,.35);
    padding: 40px 36px 32px;
    width: 90%;
    max-width: 440px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 3000;
    display: none; /* 初始隐藏 */
}

.qrcode-modal.active { display: block; }

.qrcode-modal h3 { margin-top: 0; }

.qrcode-modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    font-size: 26px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: transform .3s ease, color .3s ease;
    line-height: 1;
}

.qrcode-modal-close:hover { color: var(--primary-color); transform: rotate(90deg); }

.qrcode-image { display:block; margin:16px auto 0; width:260px; height:260px; object-fit:contain; background:#fafafa; border-radius:12px; box-shadow: var(--shadow); }

@media (max-width:600px){
  .qrcode-modal{ padding:32px 26px 26px; max-height:calc(100vh - 80px); }
  .qrcode-image{ width:220px; height:220px; }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }

    .clock-preview {
        width: 250px;
        height: 250px;
    }

    .clock-face {
        width: 200px;
        height: 200px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .highlights-content {
        grid-template-columns: 1fr;
    }

    .poster-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
    }

    .download-buttons {
        flex-direction: column;
        align-items: center;
    }

    .qrcode-modal-content {
        padding: 30px 24px;
        max-height: calc(100vh - 40px);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .clock-preview {
        width: 200px;
        height: 200px;
    }

    .clock-face {
        width: 160px;
        height: 160px;
    }

    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }

    .features {
        padding: 60px 0;
    }

    .highlights {
        padding: 60px 0;
    }

    .gallery {
        padding: 60px 0;
    }

    .download {
        padding: 60px 0;
    }
}

/* 滚动时导航栏效果 */
.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow);
}

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}
