/* Nature Green Theme Customizations */

:root {
    /* 定义主题色变量 */
    --nature-primary: #16a34a; /* green-600 */
    --nature-primary-hover: #15803d; /* green-700 */
    --nature-bg: #fcfdf5; /* 暖米色 */
    --nature-text: #1c1917; /* 暖深褐 */
    --nature-text-light: #57534e; /* 暖灰褐 */
    --nature-card-bg: #ffffff;
    --nature-border: #e7e5e4;
}

/* =========================================
   1. 全局基础样式覆盖 (Global Base)
   ========================================= */

/* 使用 !important 覆盖 Tailwind 的 bg-neutral-50 和 text-neutral-900 */
body {
    background-color: var(--nature-bg) !important;
    color: var(--nature-text) !important;
    font-family: 'Merriweather', 'Georgia', serif !important;
    
    /* 添加细微的自然纹理，减少"数码感" */
    background-image: radial-gradient(#e5e7eb 1px, transparent 1px);
    background-size: 32px 32px;
}

/* 标题字体与颜色 */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif !important;
    color: #064e3b !important; /* emerald-900 */
    letter-spacing: -0.02em;
}

/* 链接基础样式 */
a {
    transition: color 0.2s ease;
}
a:hover {
    color: var(--nature-primary-hover);
}

/* =========================================
   2. 组件样式覆盖 (Components)
   ========================================= */

/* 导航栏 (Navbar) - 毛玻璃与绿色边框 */
header.sticky {
    background-color: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(12px);
    border-bottom: 3px solid #dcfce7 !important; /* 顶部增加一条嫩绿色装饰线 */
}

.navbar-brand a {
    color: var(--nature-primary) !important;
    font-weight: 900 !important;
    font-size: 1.5rem;
}

/* 导航链接 */
.navbar-link {
    color: var(--nature-text-light) !important;
    font-weight: 600;
}
.navbar-link:hover {
    color: var(--nature-primary) !important;
    background-color: #f0fdf4; /* green-50 */
    border-radius: 0.5rem;
}

/* 搜索框 (Search Input) */
.search-section input {
    background-color: #ffffff !important;
    border: 1px solid #86efac !important; /* green-300 */
    border-radius: 999px !important; /* 胶囊状 */
    color: var(--nature-primary) !important;
    padding-left: 1.25rem;
}
.search-section input:focus {
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2) !important; /* green ring */
}

/* 卡片 (Cards) - 悬浮感与圆角 */
.card {
    background-color: var(--nature-card-bg) !important;
    border: 1px solid rgba(231, 229, 228, 0.6) !important;
    border-radius: 1.25rem !important; /* 更大的圆角 */
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05) !important;
}

.card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 20px 25px -5px rgba(22, 163, 74, 0.1), 0 8px 10px -6px rgba(22, 163, 74, 0.1) !important; /* 绿色系阴影 */
    border-color: #86efac !important;
}

/* 文章元信息 (Meta info like date, tags) */
.card .text-neutral-500 {
    color: #78716c !important; /* stone-500 */
}

/* 标签 (Tags) - 药丸样式 */
.tag {
    background-color: #ecfccb !important; /* lime-100 */
    color: #3f6212 !important; /* lime-800 */
    border: 1px solid #bef264;
    border-radius: 999px !important;
    padding: 0.25rem 0.85rem !important;
    font-size: 0.85rem;
    font-weight: 700 !important;
}

.tag:hover {
    background-color: #84cc16 !important; /* lime-500 */
    color: #ffffff !important;
    border-color: #84cc16;
}

/* 主按钮 (Primary Button) */
.btn-primary {
    background-color: var(--nature-primary) !important;
    border-color: var(--nature-primary) !important;
    color: white !important;
    border-radius: 0.75rem !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 6px -1px rgba(22, 163, 74, 0.3);
}

.btn-primary:hover {
    background-color: var(--nature-primary-hover) !important;
    box-shadow: 0 10px 15px -3px rgba(22, 163, 74, 0.4);
}

/* 页脚 (Footer) */
footer {
    background-color: #1c1917 !important; /* 深色页脚 */
    color: #a8a29e !important; /* 浅灰文字 */
    border-top: none !important;
}

footer a {
    color: #dcfce7 !important; /* 浅绿链接 */
}
footer a:hover {
    color: #fff !important;
    text-decoration: underline;
}

/* =========================================
   3. 特定修正 (Specific Overrides)
   ========================================= */

/* Hero 区域渐变修正 */
.homepage header .absolute.inset-0 {
    /* 使用更自然的森林绿渐变 */
    background-image: linear-gradient(to bottom right, rgba(22, 101, 52, 0.85), rgba(20, 83, 45, 0.9)) !important;
}

/* 修正 Hero 标题阴影，使其在深绿背景上更清晰 */
.homepage header h1 {
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}