/**
 * 家族族谱管理系统 - 全局样式
 */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
}

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

/* Header */
.header {
    background: linear-gradient(135deg, #8b0000 0%, #a00000 100%);
    color: white;
    padding: 20px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.logo h1 {
    font-size: 28px;
    font-weight: bold;
}

.logo .subtitle {
    font-size: 14px;
    opacity: 0.9;
    margin-top: 5px;
}

.nav {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 4px;
    transition: all 0.3s;
}

.nav-link:hover {
    background: rgba(255,255,255,0.2);
}

.btn-login,
.btn-logout {
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
}

.btn-login:hover,
.btn-logout:hover {
    background: rgba(255,255,255,0.3);
}

.user-info {
    font-size: 14px;
    opacity: 0.9;
    padding: 8px 15px;
}

/* Main Content */
.main {
    padding: 40px 0;
    min-height: calc(100vh - 400px);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #8b0000 0%, #a00000 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    margin-bottom: 40px;
}

.hero h2 {
    font-size: 36px;
    margin-bottom: 15px;
}

.hero p {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 30px;
}

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

.btn-primary {
    background: white;
    color: #8b0000;
    margin-right: 15px;
}

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

.btn-secondary {
    background: rgba(255,255,255,0.2);
    color: white;
    border: 1px solid rgba(255,255,255,0.5);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.3);
}

/* Features */
.features {
    padding: 40px 0;
}

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

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
}

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

.feature-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.feature-card h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #333;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* Stats */
.stats {
    padding: 40px 0;
    background: white;
    margin-top: 40px;
}

.stats h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #333;
}

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

.stat-card {
    text-align: center;
    padding: 30px;
}

.stat-number {
    font-size: 48px;
    font-weight: bold;
    color: #8b0000;
    margin-bottom: 10px;
}

.stat-label {
    color: #666;
    font-size: 16px;
}

/* Footer */
.footer {
    background: #333;
    color: white;
    padding: 30px 0;
    text-align: center;
}

.footer p {
    margin-bottom: 10px;
    opacity: 0.8;
}

.footer-note {
    font-size: 14px;
    opacity: 0.6;
}

/* Responsive */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        text-align: center;
    }
    
    .nav {
        justify-content: center;
    }
    
    .hero h2 {
        font-size: 28px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .stat-number {
        font-size: 36px;
    }
}
