/* ==========================================================================
   青睿不锈钢 · 全站统一设计系统 (site.css)
   --------------------------------------------------------------------------
   唯一视觉样式来源。所有页面只需引入：
     <link rel="stylesheet" href="./assets/tailwind.css">
     <link rel="stylesheet" href="./assets/site.css">
   site.css 必须放在 tailwind.css 之后，用于覆盖与扩展基础工具类。
   ========================================================================== */

/* ===== 1. 设计 Tokens ===== */
:root {
    /* 品牌色：深海蓝 → 青 */
    --brand-900: #020617;
    --brand-800: #0f172a;
    --brand-700: #1e3a5f;
    --brand-600: #0e7490;
    --brand-500: #0891b2;
    --brand-400: #22d3ee;

    /* 中性色 */
    --ink-900: #0f172a;
    --ink-700: #334155;
    --ink-500: #64748b;
    --ink-400: #94a3b8;
    --ink-300: #cbd5e1;
    --ink-200: #e2e8f0;
    --ink-100: #f1f5f9;
    --ink-50:  #f8fafc;

    /* 圆角 / 阴影 / 动效 */
    --radius-sm: 0.5rem;
    --radius:    1rem;
    --radius-lg: 1.5rem;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
    --shadow:    0 4px 12px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.15), 0 4px 12px rgba(15, 23, 42, 0.08);
    --ease: cubic-bezier(0.4, 0, 0.2, 1);

    /* 布局 */
    --header-h: 80px;
    --container: 80rem;

    /* 字体：国内优先的系统字体栈（不依赖 Google Fonts，零额外请求） */
    --font-sans: 'PingFang SC', 'HarmonyOS Sans SC', 'Microsoft YaHei', '微软雅黑',
                 'Hiragino Sans GB', 'Source Han Sans SC', 'Noto Sans CJK SC', 'Noto Sans SC',
                 -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* ===== 2. 基础排版 ===== */
html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink-900);
    background: var(--ink-50);
}

h1, h2, h3, h4, h5, h6 {
    line-height: 1.25;
    letter-spacing: -0.01em;
}

a { text-decoration: none; }

:focus-visible {
    outline: 2px solid var(--brand-500);
    outline-offset: 2px;
}

/* ===== 3. 布局容器 ===== */
.container-page {
    width: 100%;
    max-width: var(--container);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 640px)  { .container-page { padding-left: 1.5rem; padding-right: 1.5rem; } }
@media (min-width: 1024px) { .container-page { padding-left: 2rem;   padding-right: 2rem; } }

/* ===== 4. 品牌视觉 ===== */
.brand-gradient {
    background: linear-gradient(135deg, var(--brand-700) 0%, var(--brand-600) 60%, var(--brand-400) 100%);
}
.hero-gradient {
    background: linear-gradient(135deg, var(--brand-900) 0%, var(--brand-800) 45%, var(--brand-700) 75%, var(--brand-500) 100%);
}
.brand-text {
    background: linear-gradient(135deg, var(--brand-700) 0%, var(--brand-600) 60%, var(--brand-400) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.text-shadow { text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3); }
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* 标题下方的品牌色短分割线 */
.divider-accent {
    width: 3rem;
    height: 2px;
    border-radius: 9999px;
    background: linear-gradient(90deg, var(--brand-600) 0%, var(--brand-400) 100%);
}

/* ===== 5. 区块标题 ===== */
.section-title {
    font-size: 1.875rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 0.5rem;
    /* 不写死颜色：深色区块内可继承白色文字 */
}
@media (min-width: 768px) { .section-title { font-size: 2.25rem; } }

.section-subtitle {
    color: var(--ink-500);
    margin-bottom: 1.5rem;
}

/* ===== 6. 卡片 ===== */
.card-hover {
    position: relative;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.4s var(--ease);
}
.card-hover::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--brand-700) 0%, var(--brand-600) 55%, var(--brand-400) 100%);
    opacity: 0.9;
}
.card-hover:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

/* ===== 7. 按钮 ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.25s var(--ease);
}
.btn:active { transform: translateY(1px); }

.btn-primary {
    background: var(--brand-800);
    color: #fff;
    border-color: var(--brand-800);
}
.btn-primary:hover {
    background: var(--brand-700);
    border-color: var(--brand-700);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.18);
}

.btn-accent {
    background: linear-gradient(135deg, var(--brand-700) 0%, var(--brand-600) 60%, var(--brand-400) 100%);
    color: #fff;
}
.btn-accent:hover { filter: brightness(1.08); box-shadow: 0 8px 20px rgba(14, 116, 144, 0.28); }

.btn-outline {
    background: #fff;
    color: var(--ink-900);
    border-color: var(--ink-200);
}
.btn-outline:hover { border-color: var(--brand-600); color: var(--brand-600); }

.btn-light {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}
.btn-light:hover { background: rgba(255, 255, 255, 0.22); }

.btn-lg { padding: 0.875rem 1.75rem; font-size: 1rem; }
.btn-sm { padding: 0.375rem 0.875rem; font-size: 0.875rem; }

/* ===== 8. 徽标 ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 600;
    border: 1px solid transparent;
}
.badge-brand { background: #ecfeff; color: var(--brand-600); border-color: #a5f3fc; }
.badge-muted { background: var(--ink-100); color: var(--ink-700); border-color: var(--ink-200); }
.badge-dark  { background: var(--brand-800); color: #fff; }

/* ===== 9. 顶部信息条 ===== */
.site-topbar {
    background: var(--brand-900);
    color: #fff;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    font-size: 0.8125rem;
}
@media (min-width: 640px) { .site-topbar { font-size: 0.875rem; } }
.site-topbar a { color: rgba(255, 255, 255, 0.85); }
.site-topbar a:hover { color: #fff; }

/* ===== 10. 主导航 ===== */
.site-header {
    background: #fff;
    box-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.06);
    position: sticky;
    top: 0;
    z-index: 50;
}
.site-brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink-900);
    margin: 0;
}
.site-brand-en {
    font-size: 0.75rem;
    color: var(--ink-500);
    letter-spacing: 0.08em;
    margin: 0;
}

/* 导航项（PC） */
.site-nav a {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink-500);
    padding-bottom: 0.25rem;
    border-bottom: 2px solid transparent;
    transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
    white-space: nowrap;
}
.site-nav a:hover { color: var(--ink-900); }
.site-nav a.is-active {
    color: var(--ink-900);
    border-bottom-color: var(--brand-600);
}

/* 导航项（移动端） */
.site-mobile-menu a {
    display: block;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink-500);
    transition: background-color 0.2s var(--ease), color 0.2s var(--ease);
}
.site-mobile-menu a:hover { background: var(--ink-100); color: var(--ink-900); }
.site-mobile-menu a.is-active { color: var(--ink-900); background: var(--ink-100); }

/* 无 JS / Tailwind 失效时的响应式兜底（原 nav.css） */
.site-header .site-nav { display: none; }
.site-header .mobile-menu-btn { display: flex; }
.site-header .pc-phone-area { display: none; }
@media (min-width: 768px) {
    .site-header .pc-phone-area { display: flex !important; }
}
@media (min-width: 1024px) {
    .site-header .site-nav { display: flex !important; }
    .site-header .mobile-menu-btn { display: none !important; }
    .site-header #mobileMenu { display: none !important; }
}

/* ===== 11. 页脚 ===== */
.site-footer {
    background: var(--brand-900);
    color: #fff;
    padding-top: 3rem;
    padding-bottom: 3rem;
}
.site-footer-title { font-weight: 700; margin: 0; }
.site-footer-en {
    font-size: 0.75rem;
    color: var(--ink-400);
    letter-spacing: 0.08em;
    margin: 0;
}
.site-footer-link {
    font-size: 0.875rem;
    color: var(--ink-400);
    transition: color 0.2s var(--ease);
}
.site-footer-link:hover { color: #fff; }
.site-footer-copy { font-size: 0.875rem; color: var(--ink-400); }
.site-footer-heading {
    font-size: 0.875rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.75rem;
}

/* ===== 12. 正文排版（新闻详情等富文本） ===== */
.news-content { line-height: 1.8; }
.news-content p { margin-bottom: 1.5rem; }
.news-content h2 { font-size: 1.5rem; font-weight: 700; margin: 2rem 0 1rem; }
.news-content h3 { font-size: 1.25rem; font-weight: 600; margin: 1.5rem 0 1rem; }
.news-content ul, .news-content ol { margin: 1rem 0; padding-left: 2rem; }
.news-content li { margin-bottom: 0.5rem; }
.news-content img { max-width: 100%; height: auto; margin: 1.5rem 0; border-radius: var(--radius-sm); }

/* ===== 13. 动画 ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}
.animate-fade-in-up { animation: fadeInUp 0.8s ease-out forwards; }
.animate-delay-200 { animation-delay: 0.2s; }
.animate-delay-400 { animation-delay: 0.4s; }

/* 无障碍：尊重"减少动效"偏好 */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        transition-delay: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ===== 14. 工具类 ===== */
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
