﻿/**
 * 明心台 - 公共样式表 v2.0
 * 中国风高级治愈系设计
 * 
 * @author 明心台团队
 * @version 2.0.0
 */

/* ========================================
   1. CSS变量定义 - 中国风治愈系配色
   ======================================== */

:root {
    /* 核心背景色 - 温暖米白 */
    --bg-primary: #FAF8F5;
    --bg-secondary: #F5F0E8;
    --bg-card: #FFFFFF;
    --bg-card-hover: #FEFEFE;
    
    /* 渐变背景 */
    --gradient-warm: linear-gradient(135deg, #FAF8F5 0%, #F5EDE0 100%);
    --gradient-sage: linear-gradient(135deg, #E8F0E8 0%, #D4E4D4 100%);
    --gradient-gold: linear-gradient(135deg, #F5EED8 0%, #E8DCC8 100%);
    
    /* 主色调 - 传统金色 */
    --gold-primary: #C9A962;
    --gold-light: #D4B896;
    --gold-deep: #A68B4B;
    --gold-pale: #E8DCC8;
    
    /* 辅助色 - 治愈绿 */
    --sage-primary: #8FA68A;
    --sage-light: #A8C4A2;
    --sage-deep: #6B8A6A;
    
    /* 点缀色 - 柔和珊瑚 */
    --coral-light: #E8B4B8;
    --coral-soft: #F0D0D2;
    
    /* 文字颜色 - 温暖炭黑 */
    --text-primary: #3D3632;
    --text-secondary: #6B635A;
    --text-muted: #9A948C;
    --text-light: #B8B4AC;
    
    /* 边框与阴影 */
    --border-subtle: rgba(201, 169, 98, 0.15);
    --border-light: rgba(201, 169, 98, 0.25);
    --border-hover: rgba(201, 169, 98, 0.4);
    
    --shadow-sm: 0 2px 8px rgba(61, 54, 50, 0.06);
    --shadow-md: 0 4px 16px rgba(61, 54, 50, 0.08);
    --shadow-lg: 0 8px 32px rgba(61, 54, 50, 0.12);
    --shadow-xl: 0 12px 48px rgba(61, 54, 50, 0.16);
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 32px;
    
    /* 动画曲线 */
    --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-slow: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    
    /* 间距 */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
}

/* 暗色模式支持（可选） */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-primary: #1A1816;
        --bg-secondary: #242220;
        --bg-card: #2D2A28;
        --text-primary: #F5F0E8;
        --text-secondary: #B8B4AC;
        --text-muted: #8A8480;
        --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
        --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.25);
        --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
    }
}

/* ========================================
   2. 基础样式重置
   ======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans SC', 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.75;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 字体层级 */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Noto Serif SC', 'Noto Serif SC', 'Microsoft YaHei', serif;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1em;
}

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

a:hover {
    color: var(--gold-deep);
}

/* ========================================
   3. 背景设计 - 水墨意境
   ======================================== */

.cosmos {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: var(--gradient-warm);
}

/* 水墨晕染效果 */
.ink-wash {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0.4;
}

.ink-wash-1 {
    background: radial-gradient(ellipse at 20% 20%, rgba(143, 166, 138, 0.15) 0%, transparent 50%);
    animation: inkFlow 20s ease-in-out infinite;
}

.ink-wash-2 {
    background: radial-gradient(ellipse at 80% 60%, rgba(201, 169, 98, 0.12) 0%, transparent 45%);
    animation: inkFlow 25s ease-in-out infinite reverse;
}

.ink-wash-3 {
    background: radial-gradient(ellipse at 50% 80%, rgba(232, 180, 184, 0.1) 0%, transparent 40%);
    animation: inkFlow 30s ease-in-out infinite;
}

@keyframes inkFlow {
    0%, 100% { 
        opacity: 0.4; 
        transform: scale(1) translate(0, 0);
    }
    50% { 
        opacity: 0.6; 
        transform: scale(1.02) translate(0.5%, 1%);
    }
}

/* 淡雅云纹 */
.cloud-pattern {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0.08;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cpath fill='none' stroke='%23C9A962' stroke-width='1' d='M50 100 Q75 80 100 100 T150 100 Q175 120 150 140 T100 140 T50 140 Q25 120 50 100'/%3E%3C/svg%3E");
    background-size: 200px 200px;
    animation: cloudDrift 60s linear infinite;
}

@keyframes cloudDrift {
    from { background-position: 0 0; }
    to { background-position: 200px 0; }
}

/* 星光点点 - 改为柔和光点 */
.stars-distant,
.stars-mid,
.stars-bright {
    position: absolute;
    width: 100%;
    height: 100%;
}

.glow-dot {
    position: absolute;
    border-radius: 50%;
    animation: glowPulse 4s ease-in-out infinite;
}

.glow-dot-1 {
    background: rgba(201, 169, 98, 0.3);
    animation-delay: 0s;
}

.glow-dot-2 {
    background: rgba(143, 166, 138, 0.3);
    animation-delay: -1s;
}

.glow-dot-3 {
    background: rgba(232, 180, 184, 0.3);
    animation-delay: -2s;
}

@keyframes glowPulse {
    0%, 100% { 
        opacity: 0.3; 
        transform: scale(1);
    }
    50% { 
        opacity: 0.6; 
        transform: scale(1.1);
    }
}

/* ========================================
   4. 布局容器
   ======================================== */

.container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.container-narrow {
    max-width: 800px;
}

.container-wide {
    max-width: 1400px;
}

/* 页面内边距 */
.page-padding {
    padding: var(--space-3xl) var(--space-lg);
}

@media (max-width: 768px) {
    .page-padding {
        padding: var(--space-2xl) var(--space-md);
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
}

/* ========================================
   5. 卡片组件
   ======================================== */

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    box-shadow: var(--shadow-sm);
    transition: var(--transition-normal);
}

.card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--border-light);
    transform: translateY(-2px);
}

.card-elevated {
    box-shadow: var(--shadow-md);
}

.card-elevated:hover {
    box-shadow: var(--shadow-lg);
}

/* 卡片装饰边框 */
.card-decorated {
    position: relative;
    overflow: hidden;
}

.card-decorated::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-gold);
}

.card-decorated::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20%;
    right: 20%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-light), transparent);
}

/* ========================================
   6. 按钮组件
   ======================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-xl);
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    line-height: 1;
    color: var(--bg-primary);
    background: var(--gold-primary);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition-fast);
    text-decoration: none;
}

.btn:hover {
    background: var(--gold-deep);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn:active {
    transform: translateY(0);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.btn svg {
    width: 18px;
    height: 18px;
}

/* 按钮变体 */
.btn-secondary {
    background: transparent;
    color: var(--gold-primary);
    border: 1.5px solid var(--gold-primary);
}

.btn-secondary:hover {
    background: var(--gold-primary);
    color: var(--bg-primary);
}

.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border: 1.5px solid var(--border-light);
}

.btn-outline:hover {
    border-color: var(--gold-primary);
    color: var(--gold-primary);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: none;
}

.btn-ghost:hover {
    color: var(--gold-primary);
    background: rgba(201, 169, 98, 0.08);
}

/* 按钮尺寸 */
.btn-sm {
    padding: var(--space-sm) var(--space-md);
    font-size: 0.875rem;
}

.btn-lg {
    padding: var(--space-lg) var(--space-2xl);
    font-size: 1.125rem;
    border-radius: var(--radius-lg);
}

.btn-icon {
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 50%;
}

/* ========================================
   7. 输入组件
   ======================================== */

.form-group {
    margin-bottom: var(--space-lg);
}

.form-label {
    display:block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: var(--space-md) var(--space-lg);
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 1rem;
    color: var(--text-primary);
    background: var(--bg-card);
    border: 1.5px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--gold-primary);
    box-shadow: 0 0 0 3px rgba(201, 169, 98, 0.15);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--text-light);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* ========================================
   8. 导航栏
   ======================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: var(--space-md) 0;
    background: rgba(250, 248, 245, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-subtle);
    transition: var(--transition-normal);
}

.navbar-scrolled {
    background: rgba(250, 248, 245, 0.95);
    box-shadow: var(--shadow-sm);
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-family: 'Noto Serif SC', serif;
    font-size: 1.375rem;
    font-weight: 600;
    color: var(--gold-deep);
    text-decoration: none;
}

.navbar-brand:hover {
    color: var(--gold-primary);
}

.navbar-nav {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
    list-style: none;
}

.navbar-nav a {
    position: relative;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition-fast);
}

.navbar-nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold-primary);
    transition: var(--transition-fast);
}

.navbar-nav a:hover,
.navbar-nav a.active {
    color: var(--gold-primary);
}

.navbar-nav a:hover::after,
.navbar-nav a.active::after {
    width: 100%;
}

.navbar-actions {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

/* ========================================
   9. 模态框
   ======================================== */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(61, 54, 50, 0.5);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: var(--space-lg);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: var(--space-2xl);
    max-width: 560px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    transform: translateY(20px) scale(0.95);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0) scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-xl);
}

.modal-title {
    font-size: 1.375rem;
    color: var(--text-primary);
}

.modal-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--text-muted);
    background: none;
    border: none;
    cursor: pointer;
    border-radius: 50%;
    transition: var(--transition-fast);
}

.modal-close:hover {
    color: var(--text-primary);
    background: var(--bg-secondary);
}

.modal-actions {
    display: flex;
    gap: var(--space-md);
    margin-top: var(--space-xl);
    justify-content: flex-end;
}

/* ========================================
   10. 标签页
   ======================================== */

.tabs {
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: var(--space-xl);
}

.tabs-nav {
    display: flex;
    gap: var(--space-lg);
    list-style: none;
}

.tabs-nav button {
    position: relative;
    padding: var(--space-md) 0;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-muted);
    background: none;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
}

.tabs-nav button::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--gold-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.tabs-nav button:hover {
    color: var(--text-secondary);
}

.tabs-nav button.active {
    color: var(--gold-primary);
}

.tabs-nav button.active::after {
    transform: scaleX(1);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

/* ========================================
   11. 列表组件
   ======================================== */

.list {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.list-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: var(--transition-fast);
}

.list-item:hover {
    border-color: var(--border-light);
    box-shadow: var(--shadow-sm);
}

/* ========================================
   12. 徽章与标签
   ======================================== */

.badge {
    display: inline-flex;
    align-items: center;
    padding: var(--space-xs) var(--space-sm);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-gold {
    background: var(--gold-pale);
    color: var(--gold-deep);
}

.badge-sage {
    background: rgba(143, 166, 138, 0.2);
    color: var(--sage-deep);
}

.badge-coral {
    background: var(--coral-soft);
    color: #B88A8E;
}

/* ========================================
   13. 加载与过渡动画
   ======================================== */

/* 淡入动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

/* 淡入上移动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease forwards;
}

/* 缩放淡入动画 */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fade-in-scale {
    animation: fadeInScale 0.4s ease forwards;
}

/* 交错动画延迟 */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }

/* 浮动动画 */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.float {
    animation: float 6s ease-in-out infinite;
}

/* 脉冲动画 */
@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
}

.pulse {
    animation: pulse 3s ease-in-out infinite;
}

/* 旋转动画 */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.spin {
    animation: spin 2s linear infinite;
}

/* 骨架屏加载 */
.skeleton {
    background: linear-gradient(90deg, 
        var(--bg-secondary) 25%, 
        var(--bg-card) 50%, 
        var(--bg-secondary) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ========================================
   14. 工具类
   ======================================== */

/* 显示隐藏 */
.hidden { display: none !important; }
.visible { visibility: visible; }
.invisible { visibility: hidden; }

/* 文本对齐 */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

/* 文本颜色 */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-gold { color: var(--gold-primary); }
.text-sage { color: var(--sage-primary); }

/* 背景 */
.bg-primary { background: var(--bg-primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-card { background: var(--bg-card); }

/* 间距 */
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

/* Flexbox */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }

/* 圆角 */
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: 9999px; }

/* 阴影 */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }

/* 响应式显示 */
@media (max-width: 768px) {
    .hide-mobile { display: none !important; }
}

@media (min-width: 769px) {
    .show-mobile { display: none !important; }
}

/* ========================================
   15. 滚动条美化
   ======================================== */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold-pale);
}

/* Firefox滚动条 */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--border-light) var(--bg-secondary);
}

/* ========================================
   16. 选择框样式
   ======================================== */

::-webkit-select {
    appearance: none;
}

/* 自定义单选按钮 */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.radio-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    cursor: pointer;
}

.radio-input {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-light);
    border-radius: 50%;
    appearance: none;
    cursor: pointer;
    transition: var(--transition-fast);
    position: relative;
}

.radio-input:checked {
    border-color: var(--gold-primary);
}

.radio-input:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--gold-primary);
    border-radius: 50%;
}

/* 自定义复选框 */
.checkbox-input {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-light);
    border-radius: var(--radius-sm);
    appearance: none;
    cursor: pointer;
    transition: var(--transition-fast);
    position: relative;
}

.checkbox-input:checked {
    background: var(--gold-primary);
    border-color: var(--gold-primary);
}

.checkbox-input:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* ========================================
   17. 空状态
   ======================================== */

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-3xl) var(--space-lg);
    text-align: center;
    color: var(--text-muted);
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin-bottom: var(--space-lg);
    opacity: 0.5;
}

.empty-state p {
    font-size: 1rem;
    margin-bottom: var(--space-lg);
}

/* ========================================
   18. 加载指示器
   ======================================== */

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-subtle);
    border-top-color: var(--gold-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-dots {
    display: flex;
    gap: var(--space-sm);
}

.loading-dots span {
    width: 8px;
    height: 8px;
    background: var(--gold-primary);
    border-radius: 50%;
    animation: bounce 1.4s ease-in-out infinite;
}

.loading-dots span:nth-child(1) { animation-delay: 0s; }
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

/* ========================================
   19. 提示消息
   ======================================== */

.toast {
    position: fixed;
    top: var(--space-xl);
    left: 50%;
    transform: translateX(-50%);
    padding: var(--space-md) var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    animation: toastSlideDown 0.3s ease;
}

.toast-success {
    border-color: var(--sage-primary);
    background: linear-gradient(135deg, var(--bg-card), rgba(143, 166, 138, 0.1));
}

.toast-error {
    border-color: #D4A5A5;
    background: linear-gradient(135deg, var(--bg-card), rgba(212, 165, 165, 0.1));
}

@keyframes toastSlideDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* ========================================
   20. 进度条
   ======================================== */

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-gold);
    border-radius: var(--radius-sm);
    transition: width 0.6s ease;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-top: var(--space-sm);
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ========================================
   21. 分割线
   ======================================== */

.divider {
    height: 1px;
    background: var(--border-subtle);
    margin: var(--space-xl) 0;
}

.divider-text {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin: var(--space-xl) 0;
}

.divider-text::before,
.divider-text::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-subtle);
}

.divider-text span {
    font-size: 0.875rem;
    color: var(--text-muted);
    white-space: nowrap;
}

/* ========================================
   22. 响应式网格
   ======================================== */

.grid {
    display: grid;
    gap: var(--space-lg);
}

.grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

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

@media (max-width: 768px) {
    .grid-4,
    .grid-3,
    .grid-2 { 
        grid-template-columns: 1fr; 
    }
}

/* ========================================
   装饰增强样式 - 点缀设计
   ======================================== */

/* ---- 1. 细微纹理/图案 ---- */

/* 卡片纸张纹理 */
.card-texture {
    position: relative;
}

.card-texture::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.02;
    pointer-events: none;
    border-radius: inherit;
}

/* 微妙的几何图案背景 */
.decorative-pattern {
    position: relative;
    overflow: hidden;
}

.decorative-pattern::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(201, 169, 98, 0.03) 0%, transparent 70%);
    pointer-events: none;
}

/* 边框图案 - 角落装饰 */
.corner-decoration {
    position: relative;
}

.corner-decoration::before,
.corner-decoration::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border-color: var(--gold-primary);
    border-style: solid;
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

.corner-decoration::before {
    top: 8px;
    left: 8px;
    border-width: 1px 0 0 1px;
    border-radius: 4px 0 0 0;
}

.corner-decoration::after {
    bottom: 8px;
    right: 8px;
    border-width: 0 1px 1px 0;
    border-radius: 0 0 4px 0;
}

.corner-decoration:hover::before,
.corner-decoration:hover::after {
    opacity: 0.6;
}

/* ---- 2. 动态元素 ---- */

/* 卡片悬停光晕 */
.card-glow {
    position: relative;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.card-glow::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.4s ease;
    box-shadow: 0 0 30px rgba(201, 169, 98, 0.15);
    pointer-events: none;
}

.card-glow:hover::before {
    opacity: 1;
}

.card-glow:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

/* 淡入动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* 交错动画延迟 */
.fade-in-up-delay-1 { animation-delay: 0.1s; }
.fade-in-up-delay-2 { animation-delay: 0.2s; }
.fade-in-up-delay-3 { animation-delay: 0.3s; }
.fade-in-up-delay-4 { animation-delay: 0.4s; }
.fade-in-up-delay-5 { animation-delay: 0.5s; }

/* 微妙视差效果 */
.parallax-card {
    transition: transform 0.3s ease;
}

.parallax-card:hover {
    transform: translateY(-2px);
}

/* 按钮悬停光晕 */
.btn-glow {
    position: relative;
    transition: all 0.3s ease;
}

.btn-glow::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(201, 169, 98, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.btn-glow:hover::before {
    width: 200%;
    height: 200%;
}

/* ---- 3. 色彩层次 ---- */

/* 卡片暖色渐变角落 */
.card-gradient-corner {
    position: relative;
    background: var(--bg-card);
}

.card-gradient-corner::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, transparent 50%, rgba(201, 169, 98, 0.03) 100%);
    border-radius: 0 var(--radius-md) 0 0;
    pointer-events: none;
}

/* 金色边框变体 */
.border-gold {
    border: 1px solid var(--border-light);
    transition: border-color 0.3s ease;
}

.border-gold:hover {
    border-color: var(--gold-primary);
}

.border-gold-light {
    border: 1px solid rgba(201, 169, 98, 0.1);
}

.border-gold-hover:hover {
    border-color: var(--gold-primary);
}

/* 图标双色调 */
.icon-duotone {
    position: relative;
}

.icon-duotone svg {
    position: relative;
    z-index: 1;
}

.icon-duotone::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    background: currentColor;
    opacity: 0.1;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    filter: blur(8px);
}

/* ---- 4. 细节装饰 ---- */

/* 标题下方渐变分隔线 */
.title-decoration {
    display: flex;
    align-items: center;
    gap: 12px;
}

.title-decoration::before,
.title-decoration::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201, 169, 98, 0.3), transparent);
}

.title-decoration-center {
    text-align: center;
}

.title-decoration-center::before,
.title-decoration-center::after {
    flex: 1;
    max-width: 60px;
}

/* 小型装饰线 */
.decorative-line {
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, var(--gold-primary), var(--gold-light));
    border-radius: 2px;
    margin: 8px auto;
}

.decorative-line-left {
    margin: 8px 0;
}

/* 卡片角落几何装饰 */
.card-corner-ornament {
    position: relative;
}

.card-corner-ornament .ornament {
    position: absolute;
    width: 24px;
    height: 24px;
    opacity: 0.15;
}

.card-corner-ornament .ornament-top-right {
    top: 0;
    right: 0;
    border-top: 1px solid var(--gold-primary);
    border-right: 1px solid var(--gold-primary);
}

.card-corner-ornament .ornament-bottom-left {
    bottom: 0;
    left: 0;
    border-bottom: 1px solid var(--gold-primary);
    border-left: 1px solid var(--gold-primary);
}

/* 按钮微妙的阴影层次 */
.btn-shadow {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06),
                0 4px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
}

.btn-shadow:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08),
                0 8px 16px rgba(0, 0, 0, 0.06),
                0 0 0 1px rgba(201, 169, 98, 0.1);
    transform: translateY(-1px);
}

.btn-shadow:active {
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    transform: translateY(0);
}

/* 内发光效果 */
.inner-glow {
    box-shadow: inset 0 0 20px rgba(201, 169, 98, 0.05);
}

/* 悬停时边框高亮 */
.hover-border-highlight {
    transition: all 0.3s ease;
}

.hover-border-highlight:hover {
    border-color: var(--gold-light);
    box-shadow: 0 0 0 1px var(--gold-light),
                0 4px 12px rgba(201, 169, 98, 0.1);
}

/* 浮雕效果 */
.embossed {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5),
                0 1px 2px rgba(0, 0, 0, 0.05);
}

/* 装饰性圆点 */
.decorative-dot {
    display: inline-block;
    width: 4px;
    height: 4px;
    background: var(--gold-light);
    border-radius: 50%;
    margin: 0 8px;
    opacity: 0.5;
}

.decorative-dot-large {
    width: 6px;
    height: 6px;
}

/* 悬停时的小动画 */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.02);
}

.hover-lift {
    transition: all 0.3s ease;
}

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

/* 持续性微动动画 */
@keyframes gentlePulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(201, 169, 98, 0);
    }
    50% {
        box-shadow: 0 0 0 4px rgba(201, 169, 98, 0.1);
    }
}

.gentle-pulse {
    animation: gentlePulse 3s ease-in-out infinite;
}

/* 装饰性V形图案 */
.v-pattern {
    position: relative;
}

.v-pattern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid rgba(201, 169, 98, 0.2);
}

/* 背景装饰性渐变 */
.bg-decorative-gradient {
    background: linear-gradient(180deg, 
        rgba(201, 169, 98, 0.02) 0%, 
        transparent 50%,
        rgba(201, 169, 98, 0.02) 100%);
}

