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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
}

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

/* 导航栏 */
.navbar {
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

.nav-brand a {
    font-size: 20px;
    font-weight: bold;
    color: #007bff;
    text-decoration: none;
}

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

.nav-menu a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s;
}

.nav-menu a:hover {
    color: #007bff;
}

/* 英雄区域 */
.hero {
    padding: 150px 20px 100px;
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero p {
    font-size: 20px;
    margin-bottom: 40px;
    opacity: 0.9;
}

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

.btn {
    padding: 12px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 16px;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: white;
    color: #667eea;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

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

.btn-secondary:hover {
    background: white;
    color: #667eea;
}

/* 文章区域 */
.articles-section {
    padding: 80px 0;
}

.articles-section h2 {
    text-align: center;
    margin-bottom: 50px;
    font-size: 32px;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.article-item {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s;
    padding: 25px;
}

.article-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.article-item .article-title {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    display: block;
    margin-bottom: 15px;
    line-height: 1.4;
}

.article-item .article-title:hover {
    color: #007bff;
}

.article-item .article-excerpt {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.article-item .article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 13px;
    color: #999;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

/* 文章卡片样式（兼容） */
.article-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.article-card:hover {
    transform: translateY(-5px);
}

.article-card h3 {
    padding: 20px;
    font-size: 20px;
    color: #333;
}

.article-card p {
    padding: 0 20px 20px;
    color: #666;
    font-size: 14px;
    line-height: 1.6;
}

.article-card .meta {
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #999;
}

/* 订阅区域 */
.subscribe-section {
    padding: 80px 0;
    background: #007bff;
    color: white;
    text-align: center;
}

.subscribe-section h2 {
    margin-bottom: 15px;
}

.subscribe-section p {
    margin-bottom: 30px;
    opacity: 0.9;
}

.subscribe-form {
    display: flex;
    gap: 10px;
    justify-content: center;
    max-width: 500px;
    margin: 0 auto;
}

.subscribe-form input {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
}

/* 邀请码申请区域 */
.invite-section {
    padding: 80px 0;
}

.invite-section h2 {
    text-align: center;
    margin-bottom: 15px;
}

.invite-section > .container > p {
    text-align: center;
    margin-bottom: 30px;
    color: #666;
}

.apply-form {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #666;
    font-weight: 500;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    font-family: inherit;
}

.form-group textarea {
    resize: vertical;
}

/* 页脚 */
.footer {
    padding: 40px 0;
    text-align: center;
    background: #333;
    color: #999;
}

/* 申请页面 */
.apply-container {
    max-width: 600px;
    margin: 100px auto;
    padding: 40px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.apply-container h1 {
    text-align: center;
    margin-bottom: 30px;
}

.message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
    display: none;
}

.message.success {
    background: #d4edda;
    color: #155724;
    display: block;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    display: block;
}

/* 响应式 */
@media (max-width: 768px) {
    .navbar .container {
        flex-direction: column;
        height: auto;
        padding: 15px 20px;
    }
    .nav-menu {
        margin-top: 15px;
        gap: 20px;
    }
    .hero h1 {
        font-size: 32px;
    }
    .hero-buttons {
        flex-direction: column;
    }
    .articles-grid {
        grid-template-columns: 1fr;
    }
    .subscribe-form {
        flex-direction: column;
    }
}
