/* 引入字体：Roboto (内容) 和 Montserrat (标题) */
/* 确保在 HTML 中也引入了 Google Fonts 链接 */

:root {
    --primary-color: #5d67e7; /* 柔和的紫色/蓝色 */
    --secondary-color: #38c172; /* 绿色 */
    --internal-color: #ffaa00; /* 琥珀色 */
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --bg-light: #ecf0f1;
    --card-bg: white;
}

body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
}

/* Header 样式 */
header {
    background: linear-gradient(135deg, #4a50e5, var(--primary-color));
    color: white;
    padding: 60px 20px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

header h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.5em;
    margin-bottom: 5px;
}

header p {
    opacity: 0.9;
}

/* 网站卡片容器 (Grid 布局) */
.sites-container {
    display: grid;
    /* 自动适应，最小宽度 320px */
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    padding: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

/* 单个网站卡片样式 */
.site-card {
    background-color: var(--card-bg);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.site-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15); /* 更明显的阴影 */
    transform: translateY(-5px); 
}

/* 卡片信息区 */
.site-info {
    flex-grow: 1; /* 占据剩余空间 */
}

.site-logo {
    font-size: 2.5em;
    margin-bottom: 15px;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background-color: rgba(var(--primary-color), 0.1); /* 柔和背景 */
}

.site-card h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3em;
    color: var(--text-dark);
    margin: 10px 0 5px 0;
}

.description {
    font-size: 0.9em;
    color: var(--text-light);
    margin-bottom: 20px;
}

/* 链接按钮容器 */
.links {
    display: flex;
    gap: 10px;
    margin-top: 15px; /* 与描述保持间隔 */
}

.links a {
    text-decoration: none;
    padding: 12px 15px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.9em;
    text-align: center;
    flex-grow: 1;
    transition: background-color 0.2s ease, transform 0.1s;
}

/* 外网链接（绿色） */
.external-link {
    background-color: var(--secondary-color);
    color: white;
}

.external-link:hover {
    background-color: #33a863;
    transform: translateY(-1px);
}

/* 内网链接（琥珀色/黄色） */
.internal-link {
    background-color: var(--internal-color);
    color: var(--text-dark);
}

.internal-link:hover {
    background-color: #e69500;
    color: white;
    transform: translateY(-1px);
}

/* 底部 */
footer {
    text-align: center;
    padding: 25px;
    margin-top: 30px;
    background-color: var(--text-dark);
    color: #bdc3c7;
    font-size: 0.85em;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .sites-container {
        padding: 20px;
        gap: 20px;
    }
    
    header {
        padding: 40px 15px;
    }

    .links {
        flex-direction: column; /* 链接堆叠 */
    }
}