/**
 * CarpCat Theme Styles
 * Version: 1.0.0
 * 
 * Color Scheme: Green & Gray (避免紫色和渐变)
 * Primary: #18a058
 * Secondary: #333333
 * Accent: #13c2c2
 */

/* Import additional stylesheets - MUST be at the top */
@import url('pages.css');
@import url('components.css');

/* ========================================
   CSS Variables
   ======================================== */
:root {
    --primary-color: #18a058;
    --primary-hover: #148a4a;
    --secondary-color: #333333;
    --accent-color: #13c2c2;
    --text-color: #333333;
    --text-light: #666666;
    --text-lighter: #999999;
    --border-color: #e0e0e0;
    --background-color: #ffffff;
    --background-light: #f8f9fa;
    --background-dark: #f0f0f0;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --transition: all 0.3s ease;
}

/* ========================================
   Reset & Base
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    color: var(--text-color);
    background-color: var(--background-color);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
}

/* ========================================
   Header & Navigation
   ======================================== */
.site-header {
    background-color: #ffffff;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 15px 0;
}

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

.navbar-brand .logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
}

.navbar-brand .logo i {
    font-size: 28px;
}

.navbar-toggler {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-color);
    cursor: pointer;
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 30px;
}

.navbar-nav {
    display: flex;
    list-style: none;
    gap: 5px;
}

.nav-item.active .nav-link {
    color: var(--primary-color);
    background-color: var(--background-light);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 16px;
    color: var(--text-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary-color);
    background-color: var(--background-light);
}

.nav-link i {
    font-size: 18px;
}

.navbar-search .search-form {
    display: flex;
    align-items: center;
    gap: 5px;
}

.search-input {
    padding: 8px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    width: 200px;
    transition: var(--transition);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.search-btn {
    background-color: var(--primary-color);
    color: #ffffff;
    border: none;
    padding: 8px 15px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
}

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

/* Mobile Menu */
@media (max-width: 768px) {
    .navbar-toggler {
        display: block;
    }
    
    .navbar-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: #ffffff;
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow-md);
        display: none;
        gap: 15px;
    }
    
    .navbar-menu.active {
        display: flex;
    }
    
    .navbar-nav {
        flex-direction: column;
        width: 100%;
        gap: 5px;
    }
    
    .nav-link {
        width: 100%;
    }
    
    .navbar-search {
        width: 100%;
    }
    
    .search-form {
        width: 100%;
    }
    
    .search-input {
        flex: 1;
    }
}

/* ========================================
   Buttons
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn i {
    font-size: 18px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #ffffff;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: #ffffff;
}

.btn-secondary:hover {
    background-color: #1a1a1a;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* ========================================
   Hero Section
   ======================================== */
.hero-section {
    padding: 100px 0;
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
    text-align: center;
}

.hero-title {
    font-size: 56px;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.hero-subtitle {
    font-size: 28px;
    color: var(--text-color);
    margin-bottom: 10px;
    font-weight: 600;
}

.hero-description {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .hero-section {
        padding: 60px 0;
    }
    
    .hero-title {
        font-size: 36px;
    }
    
    .hero-subtitle {
        font-size: 20px;
    }
    
    .hero-description {
        font-size: 16px;
    }
}

/* ========================================
   Features Section
   ======================================== */
.features-section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 50px;
    color: var(--text-color);
}

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

.feature-card {
    padding: 30px;
    background-color: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: var(--transition);
    text-align: center;
}

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

.feature-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--background-light);
    border-radius: 50%;
    color: var(--primary-color);
}

.feature-icon i {
    font-size: 28px;
}

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

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

@media (max-width: 992px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Articles Section
   ======================================== */
.articles-section {
    padding: 80px 0;
    background-color: var(--background-light);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.view-more {
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--primary-color);
    font-weight: 500;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.article-card {
    background-color: #ffffff;
    border-radius: var(--radius-lg);
    padding: 25px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.article-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.article-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 12px;
    font-size: 13px;
    color: var(--text-lighter);
}

.article-category {
    color: var(--primary-color);
}

.article-title {
    font-size: 18px;
    margin-bottom: 12px;
}

.article-title a {
    color: var(--text-color);
}

.article-title a:hover {
    color: var(--primary-color);
}

.article-excerpt {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.7;
}

@media (max-width: 992px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   CTA Section
   ======================================== */
.cta-section {
    padding: 80px 0;
    background-color: var(--secondary-color);
    color: #ffffff;
    text-align: center;
}

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

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

.cta-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ========================================
   Footer
   ======================================== */
.site-footer {
    background-color: var(--secondary-color);
    color: #ffffff;
    padding: 50px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 15px;
}

.footer-logo i {
    font-size: 28px;
}

.footer-desc {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
    margin-bottom: 20px;
}

.footer-social {
    display: flex;
    gap: 10px;
}

.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    line-height: 1;
}

.footer-social a i {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    line-height: 1;
}

.footer-col h4 {
    margin-bottom: 20px;
    font-size: 16px;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 10px;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer-col a:hover {
    color: #ffffff;
    padding-left: 5px;
}

.footer-col i {
    margin-right: 8px;
    font-size: 14px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.footer-bottom .copyright {
    flex: 1;
    text-align: left;
}

.footer-bottom .beian {
    flex: 1;
    text-align: center;
}

.footer-bottom .powered {
    flex: 1;
    text-align: right;
}

.footer-bottom a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom a:hover {
    color: #fff;
}

@media (max-width: 992px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

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