/* ==========================================
   健康太极拳学习网 - 全站样式表
   风格：传统水墨 + 现代简约
   配色：墨黑 #1a1a1a | 宣纸米白 #f5f0e8 | 朱砂红 #c0392b
========================================== */

/* ---- 基础重置 ---- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background-color: #f5f0e8;
    color: #1a1a1a;
    line-height: 1.8;
    overflow-x: hidden;
}

/* ---- CSS 变量 ---- */
:root {
    --ink: #1a1a1a;
    --paper: #f5f0e8;
    --red: #c0392b;
    --red-light: #e74c3c;
    --gold: #b8860b;
    --gray: #6b6b6b;
    --light-gray: #e8e3d8;
    --navbar-height: 70px;
    --container-max: 1200px;
    --radius: 4px;
    --shadow: 0 2px 20px rgba(26,26,26,0.1);
    --shadow-deep: 0 8px 40px rgba(26,26,26,0.15);
    --transition: 0.3s ease;
}

/* ---- 通用容器 ---- */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---- 导航栏 ---- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: var(--navbar-height);
    background: rgba(245, 240, 232, 0.96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(192, 57, 43, 0.15);
    box-shadow: 0 2px 12px rgba(26,26,26,0.08);
    transition: background var(--transition);
}

.navbar-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--ink);
}

.logo-icon {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
}

.logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.logo-text {
    font-family: 'Noto Serif SC', 'STSong', serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 2px;
    line-height: 1.2;
}

.logo-sub {
    font-size: 0.6rem;
    color: var(--red);
    letter-spacing: 3px;
    font-weight: 300;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 4px;
}

.nav-menu a {
    display: block;
    padding: 8px 14px;
    text-decoration: none;
    color: var(--gray);
    font-size: 0.9rem;
    letter-spacing: 1px;
    border-radius: var(--radius);
    transition: all var(--transition);
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--red);
    transform: translateX(-50%);
    transition: width var(--transition);
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--ink);
    background: rgba(192, 57, 43, 0.06);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 60%;
}

.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 6px;
}

.mobile-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--ink);
    transition: all var(--transition);
}

/* ---- Banner ---- */
.banner {
    min-height: 100vh;
    background: linear-gradient(160deg, #1a1a1a 0%, #2c2c2c 50%, #1a1a1a 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: var(--navbar-height);
}

.banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(192,57,43,0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(245,240,232,0.03) 0%, transparent 50%);
}

.banner-taiji {
    width: 176px;
    height: 176px;
    margin: 40px auto 36px;
    animation: rotate 20s linear infinite;
    opacity: 0.85;
}

.banner-taiji svg {
    width: 100%;
    height: 100%;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.banner-content {
    text-align: center;
    color: var(--paper);
    position: relative;
    z-index: 1;
    padding: 0 20px;
}

.banner-title {
    font-family: 'Noto Serif SC', serif;
    font-size: clamp(2rem, 6vw, 3.5rem);
    font-weight: 700;
    letter-spacing: 6px;
    margin-bottom: 16px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.5);
}

.banner-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    letter-spacing: 6px;
    color: rgba(245,240,232,0.7);
    margin-bottom: 20px;
    font-weight: 300;
}

.banner-desc {
    font-size: 0.95rem;
    line-height: 2;
    color: rgba(245,240,232,0.6);
    margin-bottom: 40px;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.banner-scroll {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(245,240,232,0.4);
    font-size: 0.8rem;
    letter-spacing: 2px;
    cursor: pointer;
    animation: float 2s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(6px); }
}

/* ---- 按钮 ---- */
.btn {
    display: inline-block;
    padding: 12px 32px;
    border-radius: var(--radius);
    text-decoration: none;
    font-size: 0.95rem;
    letter-spacing: 2px;
    transition: all var(--transition);
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--red);
    color: #fff;
    border-color: var(--red);
}

.btn-primary:hover {
    background: transparent;
    color: var(--red);
    border-color: var(--red);
}

.btn-outline {
    background: transparent;
    color: var(--paper);
    border-color: rgba(245,240,232,0.5);
}

.btn-outline:hover {
    background: rgba(245,240,232,0.1);
    border-color: var(--paper);
}

.btn-dark {
    background: var(--ink);
    color: var(--paper);
    border-color: var(--ink);
}

.btn-dark:hover {
    background: transparent;
    color: var(--ink);
}

/* ---- Section 通用 ---- */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 56px;
}

.section-tag {
    display: inline-block;
    font-size: 0.75rem;
    letter-spacing: 4px;
    color: var(--red);
    margin-bottom: 12px;
    text-transform: uppercase;
}

.section-title {
    font-family: 'Noto Serif SC', serif;
    font-size: clamp(1.6rem, 4vw, 2.2rem);
    font-weight: 700;
    letter-spacing: 4px;
    margin-bottom: 16px;
    color: var(--ink);
}

.section-title span {
    color: var(--red);
}

.section-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}

.section-divider::before,
.section-divider::after {
    content: '';
    width: 60px;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--red));
}

.section-divider::after {
    background: linear-gradient(to left, transparent, var(--red));
}

.section-divider .diamond {
    width: 8px;
    height: 8px;
    background: var(--red);
    transform: rotate(45deg);
}

.section-desc {
    color: var(--gray);
    font-size: 0.95rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ---- 特色板块（首页四大入口）---- */
.features {
    background: var(--paper);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.feature-card {
    background: #fff;
    border-radius: 8px;
    padding: 36px 28px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: all var(--transition);
    border: 1px solid rgba(26,26,26,0.06);
    text-decoration: none;
    color: inherit;
    display: block;
}

.feature-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-deep);
    border-color: rgba(192,57,43,0.2);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.feature-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 3px;
    margin-bottom: 12px;
    color: var(--ink);
}

.feature-desc {
    font-size: 0.88rem;
    color: var(--gray);
    line-height: 1.8;
    margin-bottom: 20px;
}

.feature-link {
    font-size: 0.8rem;
    color: var(--red);
    letter-spacing: 1px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

/* ---- 每日推荐 ---- */
.daily-tip {
    background: var(--ink);
    color: var(--paper);
    text-align: center;
    padding: 60px 0;
}

.tip-label {
    font-size: 0.75rem;
    letter-spacing: 4px;
    color: rgba(245,240,232,0.4);
    margin-bottom: 20px;
    text-transform: uppercase;
}

.tip-content {
    font-family: 'Noto Serif SC', serif;
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    letter-spacing: 4px;
    line-height: 1.8;
    max-width: 700px;
    margin: 0 auto 16px;
    min-height: 80px;
    transition: opacity 0.5s ease;
}

.tip-author {
    font-size: 0.85rem;
    color: rgba(245,240,232,0.4);
    letter-spacing: 2px;
    margin-bottom: 28px;
}

/* ---- 内容页通用 ---- */
.page-header {
    background: linear-gradient(160deg, #1a1a1a 0%, #2c2c2c 100%);
    padding: calc(var(--navbar-height) + 50px) 0 60px;
    text-align: center;
    color: var(--paper);
}

.page-header .page-title {
    font-family: 'Noto Serif SC', serif;
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    letter-spacing: 6px;
    margin-bottom: 12px;
}

.page-header .page-subtitle {
    color: rgba(245,240,232,0.6);
    font-size: 0.95rem;
    letter-spacing: 2px;
}

/* 面包屑 */
.breadcrumb {
    padding: 14px 0;
    border-bottom: 1px solid var(--light-gray);
    margin-bottom: 0;
}

.breadcrumb-list {
    display: flex;
    list-style: none;
    gap: 8px;
    align-items: center;
    font-size: 0.85rem;
    color: var(--gray);
}

.breadcrumb-list a {
    color: var(--gray);
    text-decoration: none;
}

.breadcrumb-list a:hover {
    color: var(--red);
}

.breadcrumb-list .sep {
    color: rgba(26,26,26,0.3);
}

.breadcrumb-list .current {
    color: var(--ink);
}

/* ---- 卡片网格 ---- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.card {
    display: block;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all var(--transition);
    border: 1px solid rgba(26,26,26,0.06);
}

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

.card-header {
    background: var(--ink);
    color: var(--paper);
    padding: 24px;
    font-family: 'Noto Serif SC', serif;
    font-size: 1.1rem;
    letter-spacing: 3px;
}

.card-body {
    padding: 24px;
}

.card-text {
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.9;
    margin-bottom: 16px;
}

/* ---- 文章内容区 ---- */
.article-content {
    max-width: 820px;
    margin: 0 auto;
    padding: 60px 24px;
}

.article-content h2 {
    font-family: 'Noto Serif SC', serif;
    font-size: 1.5rem;
    letter-spacing: 3px;
    margin: 48px 0 20px;
    color: var(--ink);
    padding-left: 16px;
    border-left: 4px solid var(--red);
}

.article-content h3 {
    font-family: 'Noto Serif SC', serif;
    font-size: 1.15rem;
    letter-spacing: 2px;
    margin: 32px 0 14px;
    color: var(--ink);
}

.article-content p {
    margin-bottom: 16px;
    color: #333;
    font-size: 0.95rem;
    line-height: 2;
    text-indent: 2em;
}

.article-content blockquote {
    border-left: 3px solid var(--red);
    padding: 16px 24px;
    margin: 24px 0;
    background: rgba(192,57,43,0.04);
    color: var(--gray);
    font-style: italic;
}

.article-content ul, .article-content ol {
    padding-left: 24px;
    margin-bottom: 16px;
}

.article-content li {
    margin-bottom: 8px;
    font-size: 0.95rem;
    line-height: 1.9;
    color: #333;
}

/* ---- 古典引用框 ---- */
.classic-quote {
    background: var(--ink);
    color: var(--paper);
    padding: 32px 40px;
    border-radius: 8px;
    margin: 32px 0;
    text-align: center;
    position: relative;
}

.classic-quote::before {
    content: '❝';
    position: absolute;
    top: 12px;
    left: 20px;
    font-size: 2rem;
    color: rgba(245,240,232,0.2);
}

.classic-quote .quote-text {
    font-family: 'Noto Serif SC', serif;
    font-size: 1.1rem;
    letter-spacing: 3px;
    line-height: 2.2;
    margin-bottom: 12px;
}

.classic-quote .quote-source {
    font-size: 0.8rem;
    color: rgba(245,240,232,0.5);
    letter-spacing: 2px;
}

/* ---- 视频占位 ---- */
.video-placeholder {
    background: linear-gradient(135deg, #1a1a1a 0%, #2c2c2c 100%);
    border-radius: 8px;
    aspect-ratio: 16/9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--paper);
    cursor: pointer;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.video-placeholder:hover {
    transform: scale(1.01);
}

.video-placeholder .play-icon {
    width: 64px;
    height: 64px;
    border: 2px solid rgba(245,240,232,0.5);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    font-size: 1.5rem;
    transition: all var(--transition);
}

.video-placeholder:hover .play-icon {
    background: rgba(192,57,43,0.3);
    border-color: var(--red);
}

.video-placeholder .video-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 1rem;
    letter-spacing: 2px;
    color: rgba(245,240,232,0.8);
}

.video-placeholder .video-label {
    font-size: 0.75rem;
    color: rgba(245,240,232,0.4);
    margin-top: 6px;
    letter-spacing: 1px;
}

/* ---- 音频播放器 ---- */
.audio-card {
    background: #fff;
    border-radius: 8px;
    padding: 24px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(26,26,26,0.06);
    transition: all var(--transition);
}

.audio-card:hover {
    box-shadow: var(--shadow-deep);
}

.audio-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 1rem;
    letter-spacing: 2px;
    margin-bottom: 6px;
    color: var(--ink);
}

.audio-desc {
    font-size: 0.82rem;
    color: var(--gray);
    margin-bottom: 16px;
    line-height: 1.7;
}

.audio-player {
    background: var(--ink);
    border-radius: 6px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--paper);
}

.audio-player .play-btn {
    width: 36px;
    height: 36px;
    border: 1px solid rgba(245,240,232,0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    font-size: 0.8rem;
    transition: all var(--transition);
}

.audio-player .play-btn:hover {
    background: var(--red);
    border-color: var(--red);
}

.audio-player .track-info {
    flex: 1;
    font-size: 0.82rem;
    color: rgba(245,240,232,0.6);
    letter-spacing: 1px;
}

.audio-coming {
    font-size: 0.78rem;
    color: var(--red);
    letter-spacing: 1px;
}

/* ---- 步骤列表 ---- */
.steps-list {
    list-style: none;
    counter-reset: step-counter;
}

.steps-list li {
    counter-increment: step-counter;
    padding: 16px 16px 16px 64px;
    position: relative;
    margin-bottom: 12px;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 1px 8px rgba(26,26,26,0.06);
    font-size: 0.92rem;
    line-height: 1.8;
    color: #333;
}

.steps-list li::before {
    content: counter(step-counter);
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: var(--red);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
}

/* ---- 关键词标签 ---- */
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 16px 0;
}

.tag {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(192,57,43,0.08);
    color: var(--red);
    border: 1px solid rgba(192,57,43,0.2);
    border-radius: 20px;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

/* ---- 二列布局 ---- */
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

@media (max-width: 768px) {
    .two-col {
        grid-template-columns: 1fr;
    }
}

/* ---- 信息框 ---- */
.info-box {
    background: rgba(192,57,43,0.05);
    border: 1px solid rgba(192,57,43,0.2);
    border-radius: 6px;
    padding: 20px 24px;
    margin: 24px 0;
}

.info-box .info-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 0.95rem;
    letter-spacing: 2px;
    color: var(--red);
    margin-bottom: 10px;
}

.info-box p {
    font-size: 0.88rem;
    color: var(--gray);
    line-height: 1.8;
    text-indent: 0;
    margin: 0;
}

/* ---- 套路表格 ---- */
.routine-table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 0.9rem;
}

.routine-table th {
    background: var(--ink);
    color: var(--paper);
    padding: 12px 16px;
    text-align: left;
    letter-spacing: 1px;
    font-weight: 500;
}

.routine-table td {
    padding: 10px 16px;
    border-bottom: 1px solid var(--light-gray);
    color: #333;
}

.routine-table tr:hover td {
    background: rgba(192,57,43,0.03);
}

.routine-table .num {
    font-weight: 700;
    color: var(--red);
}

/* ---- 页脚 ---- */
.footer {
    background: var(--ink);
    color: rgba(245,240,232,0.6);
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 40px;
}

.footer-brand .brand-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 1.2rem;
    letter-spacing: 3px;
    color: var(--paper);
    margin-bottom: 12px;
}

.footer-brand p {
    font-size: 0.85rem;
    line-height: 1.9;
}

.footer-col h4 {
    font-size: 0.85rem;
    letter-spacing: 2px;
    color: var(--paper);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(245,240,232,0.1);
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 8px;
}

.footer-col a {
    color: rgba(245,240,232,0.5);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color var(--transition);
}

.footer-col a:hover {
    color: var(--paper);
}

.footer-bottom {
    border-top: 1px solid rgba(245,240,232,0.08);
    padding-top: 24px;
    text-align: center;
    font-size: 0.8rem;
    color: rgba(245,240,232,0.3);
}

/* ---- 返回顶部 ---- */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 44px;
    height: 44px;
    background: var(--red);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(192,57,43,0.4);
    transition: all var(--transition);
    opacity: 0;
    pointer-events: none;
    font-size: 1rem;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(192,57,43,0.5);
}

/* ---- 进入动画 ---- */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---- 响应式 ---- */
@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    :root {
        --navbar-height: 60px;
    }
    
    .nav-menu {
        position: fixed;
        top: var(--navbar-height);
        left: 0;
        right: 0;
        background: var(--paper);
        flex-direction: column;
        padding: 16px 24px;
        border-bottom: 1px solid var(--light-gray);
        box-shadow: var(--shadow);
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: all var(--transition);
    }

    .nav-menu.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    /* 移动端：下划线跟随文字左对齐，不再用50%居中 */
    .nav-menu a::after {
        left: 14px;
        transform: none;
        width: 0;
    }
    .nav-menu a:hover::after,
    .nav-menu a.active::after {
        width: 2em;
    }

    .mobile-toggle {
        display: flex;
    }

    .banner-taiji {
        width: 128px;
        height: 128px;
    }

    section {
        padding: 56px 0;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}
