@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #0f172a;
    --secondary-color: #1e293b;
    --accent-color: #3b82f6;
    --light-accent: #94a3b8;
    --dark-primary: #0f172a;
    --gold-accent: #d97706;
    --silver-accent: #cbd5e1;
    --bg-start: #ffffff;
    --bg-end: #f5f7fb;
    --bg-dark: rgba(255, 255, 255, 0.96);
    --bg-card: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --shadow-primary: rgba(15, 23, 42, 0.08);
    --verina-green: #22c55e;
    --panel-border: rgba(148, 163, 184, 0.35);
    --surface-muted: #f8fafc;
    --surface-contrast: #eef2ff;
    --content-max-offset: 70vh;
    --content-min-offset: 30vh;
    --content-shift: 0px;
}

body, html {
    margin: 0;
    padding: 0;
    font-family: 'Noto Sans SC', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--bg-start), var(--bg-end));
    color: var(--text-primary);
    position: relative;
    padding-bottom: calc(max(var(--content-max-offset, 70vh) - var(--content-min-offset, 30vh) - var(--content-shift, 0px), 0px) + 5px);
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 80%, rgba(255, 183, 77, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 215, 150, 0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: -2;
}

/* 卡片基础样式 */
.card {
    background: var(--bg-card);
    padding: 18px;
    border-radius: 18px;
    margin-bottom: 14px;
    box-shadow:
        0 16px 32px rgba(15, 23, 42, 0.08),
        0 4px 10px rgba(15, 23, 42, 0.04);
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
    border: 1px solid rgba(148, 163, 184, 0.3);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent,
        rgba(247, 208, 96, 0.25),
        transparent);
    transition: left 0.7s ease;
}

.card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(247, 208, 96, 0.7) 20%,
        rgba(217, 119, 6, 0.9) 50%,
        rgba(247, 208, 96, 0.7) 80%,
        transparent 100%);
    border-radius: 24px 24px 0 0;
    opacity: 0.8;
}

.card:hover {
    box-shadow:
        0 18px 36px rgba(15, 23, 42, 0.12),
        0 8px 18px rgba(15, 23, 42, 0.08);
    border-color: rgba(148, 163, 184, 0.5);
}

.card:hover::before {
    left: 100%;
}

.card:hover::after {
    opacity: 1;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 225, 150, 0.9) 20%,
        rgba(217, 119, 6, 1) 50%,
        rgba(255, 225, 150, 0.9) 80%,
        transparent 100%);
}

/* 标题样式 */
.card h2, .card h3 {
    color: var(--secondary-color);
    text-shadow:
        0 1px 3px rgba(148, 163, 184, 0.5);
    margin-top: 0;
    margin-bottom: 0.8em;
    position: relative;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.card h2 {
    font-size: 1.8em;
}

.card h3 {
    font-size: 1.5em;
}

.card h2::after,
.card h3::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 0;
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg,
        rgba(255, 225, 150, 1) 0%,
        rgba(217, 137, 6, 1) 60%,
        rgba(255, 225, 150, 1) 100%);
    border-radius: 2px;
    box-shadow: 0 1px 4px rgba(217, 137, 6, 0.4);
}

.card h2::before, .card h3::before {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 2px;
    width: 76px;
    height: 1px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 1px;
}

.card p {
    line-height: 1.5;
    margin-top: 0;
    margin-bottom: 0.6em;
}

/* 链接样式 */
.card a:not(.btn) {
    color: #2563eb;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border-bottom: 1px solid transparent;
    padding: 0;
    margin: 0;
    display: inline;
    line-height: inherit;
}

.card a:not(.btn):hover {
    color: var(--light-accent);
    border-bottom-color: var(--accent-color);
    text-decoration: none;
}

/* 按钮样式 - 扁平化设计 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 500;
    text-decoration: none;
    background: transparent;
    color: var(--accent-color) !important;
    border: 1.5px solid rgba(59, 130, 246, 0.6);
    box-shadow: none;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
    min-height: 34px;
    line-height: 1.3;
    text-align: center;
    font-size: 0.9em;
    white-space: nowrap;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
}

.btn:hover {
    background: rgba(59, 130, 246, 0.08);
    border-color: rgba(37, 99, 235, 0.8);
    color: #1d4ed8 !important;
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
    background: rgba(59, 130, 246, 0.12);
}

/* 特殊文本样式 */
.highlight-text {
    color: var(--gold-accent);
    font-weight: 600;
    text-shadow:
        0 1px 3px rgba(251, 191, 36, 0.35);
    position: relative;
}

.highlight-text::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent, 
        var(--gold-accent), 
        transparent);
    opacity: 0.6;
}

.accent-text {
    color: var(--primary-color);
    font-weight: 500;
    text-shadow: none;
}

/* 信息框样式 */
.info-box {
    background: rgba(248, 250, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 12px;
    padding: 12px;
    margin: 10px 0;
    position: relative;
    overflow: hidden;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.info-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg,
        var(--accent-color),
        var(--gold-accent),
        var(--accent-color));
    border-radius: 16px 16px 0 0;
}

.warning-box {
    background: rgba(253, 224, 71, 0.18);
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-left: 3px solid rgba(245, 158, 11, 0.9);
}

.warning-box::before {
    background: var(--gold-accent);
}

/* 代码块样式 */
code {
    background: rgba(226, 232, 240, 0.8);
    color: var(--primary-color);
    padding: 4px 8px;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-weight: 500;
    border: 1px solid rgba(148, 163, 184, 0.5);
    box-shadow:
        0 2px 4px rgba(15, 23, 42, 0.08);
    transition: all 0.2s ease;
    position: relative;
}

code:hover {
    background: linear-gradient(135deg, 
        rgba(58, 89, 152, 0.35), 
        rgba(123, 163, 217, 0.25));
    transform: translateY(-1px);
    box-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* 列表样式 */
ul {
    list-style: none;
    padding-left: 0;
}

ul li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 4px;
    line-height: 1.6;
}

ul li::before {
    content: '⋆';
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent-color);
    font-weight: 700;
}

/* 强调文本样式 */
strong {
    color: var(--secondary-color);
    font-weight: 600;
    text-shadow: none;
    position: relative;
}
