/* ==========================================================================
   全局按钮与容器样式
   ========================================================================== */

/* 1. 全局按钮容器 */
.button-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 25px 0;
}

/* 2. 彻底清除按钮组内 a 标签的默认链接样式（防止变蓝、变紫、出现下划线） */
.button-group a,
.button-group a:link,
.button-group a:visited,
.button-group a:hover,
.button-group a:active {
    text-decoration: none !important; /* 强制去除下划线 */
    color: inherit;                  /* 继承父级颜色 */
    display: inline-flex;            /* 保持内部布局对齐 */
    outline: none;
}

/* 3. 全局按钮基础样式 */
button, 
input[type="button"], 
input[type="submit"],
a.button-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 22px;
    
    background-color: #f3f4f6;
    border: 1px solid transparent;
    border-radius: 12px;
    
    color: #4b5563 !important; /* 显式指定文字颜色，防止被浏览器默认链接颜色覆盖 */
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    
    cursor: pointer;
    user-select: none;
    
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 4. 确保包裹在 a 标签内部的 button 也能保持一致的颜色 */
.button-group a button {
    color: #4b5563 !important;
}

/* 5. 全局鼠标悬停与聚焦状态 */
button:hover,
input[type="button"]:hover,
input[type="submit"]:hover,
a.button-link:hover,
.button-group a:hover button {
    background-color: #ffffff;
    border-color: #e5e7eb;
    color: #111827 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transform: translateY(-1px);
}

/* 6. 全局点击（激活）状态 */
button:active,
input[type="button"]:active,
input[type="submit"]:active,
a.button-link:active,
.button-group a:active button {
    background-color: #f3f4f6;
    border-color: transparent;
    transform: translateY(1px);
    box-shadow: none;
}

/* ==========================================================================
   文章排版与组件样式
   ========================================================================== */

/* 文章内标题间距微调 */
.content h2 {
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-top: 45px;
    margin-bottom: 16px;
    color: #1f2937;
}

.content h3 {
    font-size: 18px;
    font-weight: 600;
    margin-top: 28px;
    margin-bottom: 12px;
    color: #374151;
}

/* 表格全局样式 */
.med-effect-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 25px 0;
    font-size: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.med-effect-table th, .med-effect-table td {
    padding: 14px 18px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

.med-effect-table th {
    background-color: #f9fafb;
    color: #4b5563;
    font-weight: 600;
}

.med-effect-table tr:last-child td {
    border-bottom: none;
}

.med-effect-table tr:nth-child(even) {
    background-color: #f9fafb;
}

/* 结语引用块样式 */
.info-quote {
    margin: 35px 0;
    padding: 18px 22px;
    background-color: #f8fafc;
    border-left: 4px solid #6366f1;
    border-radius: 4px 12px 12px 4px;
    color: #475569;
    line-height: 1.65;
}
/* 强制清除全站所有超链接的下划线，并将文字颜色统一恢复为黑色 */
a, 
a:link, 
a:visited, 
a:hover, 
a:active,
.header-nav a,
.nav-links a,
.button-group a,
.button-group a button {
    text-decoration: none !important;
    color: #000000 !important;
}

/* 保持导航栏激活项（当前页面）的字重，但颜色同样为黑 */
.nav-links a.active {
    font-weight: 600;
}

