﻿/* ====== 全局 ====== */
.iching-nav-wrapper {
    max-width: 900px;
    margin: 20px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto;
}

/* ====== 导航容器 ====== */
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/* ====== 卡片基础 ====== */
.nav-item,
.current-display {
    border-radius: 14px;
    padding: 14px;
    background: #fff;
    transition: all 0.25s ease;
}

/* ====== 当前卦（主视觉） ====== */
.current-display {
    flex: 1.4;
    text-align: center;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    border: 2px solid #b1271b;
    z-index: 2;
}

/* ====== 前后卦 ====== */
.nav-item {
    flex: 1;
    text-align: center;
    background: #f8f8f8;
    opacity: 0.85;
}

    .nav-item:hover {
        transform: translateY(-3px);
        opacity: 1;
    }

    /* ====== 层级（next 在后） ====== */
    .nav-item.next {
        transform: scale(0.95);
        opacity: 0.7;
    }

/* ====== 文本 ====== */
.gua-name {
    margin: 6px 0;
    font-weight: 600;
}

    .gua-name.main {
        font-size: 2rem;
        color: #b1271b;
    }

.gua-eng {
    font-size: 0.9rem;
    color: #777;
}

.gua-index {
    font-size: 0.8rem;
    color: #b1271b;
    font-weight: bold;
}

/* ====== 按钮 ====== */
.nav-btn {
    display: inline-block;
    margin-top: 6px;
    padding: 6px 10px;
    border-radius: 6px;
    background: blue;
    color: #fff;
    text-decoration: none;
    font-size: 0.85rem;
}

    .nav-btn:hover {
        background: #8f1d14;
    }

/* ====== Jump Box ====== */
.jump-box {
    margin-top: 18px;
    text-align: center;
}

    .jump-box input {
        width: 70px;
        padding: 4px;
        margin: 0 6px;
    }

/* ====== Logic Section ====== */
.logic-section {
    margin-top: 20px;
}

.toggle-trigger {
    cursor: pointer;
    color: #b1271b;
    font-weight: bold;
}

.evolution-box {
    margin-top: 12px;
    padding: 16px;
    background: #fffdf8;
    border-left: 4px solid #b1271b;
    border-radius: 8px;
}

/* ====== 动画 ====== */
.yao-notes-hide {
    display: none;
}

.yao-notes-show {
    display: block;
}

/* ====== 📱 Mobile 优化 ====== */
@media (max-width: 768px) {

    .nav-container {
        flex-direction: column;
    }

    /* 上一卦在顶部 */
    .nav-item.prev {
        order: 1;
        width: 100%;
    }

    /* 当前卦 */
    .current-display {
        order: 2;
        width: 100%;
    }

    /* 下一卦在“后”（弱化） */
    .nav-item.next {
        order: 3;
        width: 100%;
        opacity: 0.6;
        transform: scale(0.92);
    }

    .gua-name.main {
        font-size: 1.6rem;
    }
}
.sequence-wrapper {
    max-width: 900px;
    margin: 20px auto;
    padding: 10px;
}

    /* 标题 */
    .sequence-wrapper h1 {
        text-align: center;
        font-size: 1.8rem;
        margin-bottom: 10px;
    }

/* 简介 */
.sequence-intro {
    text-align: left;
    color: #666;
    margin-bottom: 20px;
}

/* 🔥 序卦链 */
.sequence-chain {
    text-align: center;
    margin-bottom: 20px;
    font-size: 0.9rem;
    overflow-x: auto;
    white-space: nowrap;
}

    .sequence-chain a {
        text-decoration: none;
        color: #b1271b;
        margin: 0 2px;
    }

/* 列表 */
.sequence-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* 每一项 */
.sequence-item {
    display: flex;
    flex-wrap: wrap;
    padding: 12px;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
    align-items: center;
}

/* 编号 */
.seq-index {
    width: 40px;
    font-weight: bold;
    color: #b1271b;
}

/* 卦名 */
.seq-name {
    flex: 1;
    font-weight: 600;
}

    .seq-name .eng {
        display: block;
        font-size: 0.8rem;
        color: #888;
    }

/* 含义 */
.seq-meaning {
    flex: 2;
    font-size: 0.9rem;
    color: #444;
}

/* 链接 */
.seq-links {
    display: flex;
    gap: 8px;
}

    .seq-links a {
        font-size: 0.8rem;
        text-decoration: none;
        color: #fff;
        background: blue;
        padding: 4px 8px;
        border-radius: 5px;
    }

/* 📱 Mobile */
@media (max-width: 768px) {
    .sequence-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .seq-links {
        margin-top: 8px;
    }
}