/* {模板路径}/static/css/style.css */
:root {
    --primary-color: #4CAF50;
    --secondary-color: #2E7D32;
    --accent-color: #8BC34A;
    --text-color: #333333;
    --light-text: #666666;
    --bg-color: #FFFFFF;
    --light-bg: #F5F5F5;
    --border-color: #E0E0E0;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --radius: 8px;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-color);
}

img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--secondary-color);
}

ul {
    list-style: none;
}

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

/* Header */
/* {模板路径}/static/css/style.css 继续 */
header {
    background-color: var(--bg-color);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 15px 0;
}

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

.logo h1 {
    color: var(--primary-color);
    font-size: 28px;
    margin: 0;
}

nav ul {
    display: flex;
}

nav ul li {
    margin-left: 25px;
}

nav ul li a {
    color: var(--text-color);
    font-weight: 500;
    padding: 5px 0;
    position: relative;
}

nav ul li a:hover {
    color: var(--primary-color);
}

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

nav ul li a:hover::after {
    width: 100%;
}

/* Banner Section */
.banner {
    padding: 80px 0;
    background-color: var(--light-bg);
}

.banner .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.banner-content {
    flex: 1;
    padding-right: 50px;
}

.banner-content h2 {
    font-size: 42px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.banner-content p {
    font-size: 18px;
    margin-bottom: 30px;
    color: var(--light-text);
}

.banner-image {
    flex: 1;
}

.banner-image img {
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.search-box {
    display: flex;
    margin-top: 20px;
}

.search-box input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius) 0 0 var(--radius);
    font-size: 16px;
    outline: none;
}

.search-box button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0 25px;
    border-radius: 0 var(--radius) var(--radius) 0;
    cursor: pointer;
    font-size: 16px;
    transition: var(--transition);
}

.search-box button:hover {
    background-color: var(--secondary-color);
}

/* Section Common Styles */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.section-header p {
    font-size: 18px;
    color: var(--light-text);
}

/* Video Section */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 30px;
}

.video-card {
    background-color: var(--bg-color);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

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

.video-thumbnail {
    position: relative;
}

.video-thumbnail img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: var(--radius) var(--radius) 0 0;
}

.duration {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.video-info {
    padding: 15px;
}

.video-info h3 {
    font-size: 16px;
    margin-bottom: 8px;
    line-height: 1.4;
}

.author, .views {
    font-size: 14px;
    color: var(--light-text);
    margin-bottom: 5px;
}

/* Hot Section */
.hot-section {
    background-color: var(--light-bg);
}

.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ranking-item {
    display: flex;
    align-items: center;
    background-color: var(--bg-color);
    border-radius: var(--radius);
    padding: 15px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.ranking-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.rank {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color);
    margin-right: 20px;
    min-width: 30px;
    text-align: center;
}

.ranking-thumbnail {
    width: 120px;
    height: 70px;
    margin-right: 20px;
    flex-shrink: 0;
}

.ranking-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ranking-info {
    flex: 1;
}

.ranking-info h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.stats {
    font-size: 14px;
    color: var(--light-text);
}

/* Category Section */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 25px;
}

.category-card {
    text-align: center;
    transition: var(--transition);
}

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

.category-card img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: var(--radius);
    margin-bottom: 15px;
}

.category-card h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.category-card p {
    font-size: 14px;
    color: var(--light-text);
}

/* Latest Section */
.latest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 30px;
}

.latest-card {
    background-color: var(--bg-color);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

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

.latest-thumbnail {
    position: relative;
}

.latest-thumbnail img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: var(--radius) var(--radius) 0 0;
}

.time {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background-color: var(--primary-color);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.latest-info {
    padding: 15px;
}

.latest-info h3 {
    font-size: 16px;
    margin-bottom: 8px;
    line-height: 1.4;
}

/* Creator Section */
.creator-section {
    background-color: var(--light-bg);
}

.creator-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.creator-info {
    flex: 1;
}

.creator-info h3 {
    font-size: 28px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.creator-info p {
    margin-bottom: 20px;
}

.creator-benefits {
    margin: 25px 0;
}

.creator-benefits li {
    margin-bottom: 10px;
    position: relative;
    padding-left: 25px;
}

.creator-benefits li:before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.creator-image {
    flex: 1;
}

.creator-image img {
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 12px 25px;
    border-radius: var(--radius);
    font-weight: 500;
    transition: var(--transition);
}

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

/* Articles Section */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.article-card {
    background-color: var(--bg-color);
    border-radius: var(--radius);
    padding: 25px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

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

.article-card h3 {
    font-size: 20px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.article-card p {
    font-size: 15px;
    line-height: 1.7;
}

/* About Section */
.about-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-image {
    flex: 1;
}

.about-image img {
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.about-info {
    flex: 1;
}

.about-info h3 {
    font-size: 24px;
    margin-bottom: 15px;
    margin-top: 25px;
    color: var(--primary-color);
}

.about-info h3:first-child {
    margin-top: 0;
}

.about-info p {
    margin-bottom: 15px;
}

/* Footer */
footer {
    background-color: #333;
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
}

.footer-logo h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: var(--accent-color);
}

.footer-logo p {
    color: #ccc;
}

.footer-links {
    display: flex;
    gap: 50px;
}

.link-group h4 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--accent-color);
}

.link-group ul li {
    margin-bottom: 10px;
}

.link-group ul li a {
    color: #ccc;
    transition: var(--transition);
}

.link-group ul li a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
}

.footer-bottom p {
    color: #999;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 992px) {
    .banner .container,
    .creator-content,
    .about-content {
        flex-direction: column;
    }
    
    .banner-content {
        padding-right: 0;
        margin-bottom: 30px;
    }
    
    .creator-info,
    .about-info {
        order: 2;
    }
    
    .creator-image,
    .about-image {
        order: 1;
        margin-bottom: 30px;
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .footer-logo {
        margin-bottom: 30px;
    }
    
    .footer-links {
        flex-wrap: wrap;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    header .container {
        flex-direction: column;
    }
    
    .logo {
        margin-bottom: 15px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    nav ul li {
        margin: 5px 10px;
    }
    
    .section-header h2 {
        font-size: 28px;
    }
    
    .banner-content h2 {
        font-size: 32px;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .video-grid,
    .latest-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }
}