/* ============================================================
   志睿源官网 · components.css
   按钮 / 卡片 / 标签 / 时间轴 / 表单 / 正文排版
   ============================================================ */

/* ── 按钮 ─────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: 10px;
    border: 1px solid transparent;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all .16s ease;
    white-space: nowrap;
    line-height: 1.4;
    text-align: center;
}

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

.btn--primary:hover {
    background: var(--brand-hover);
    border-color: var(--brand-hover);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 8px 20px -10px rgba(29, 78, 216, .7);
}

.btn--ghost {
    background: #fff;
    color: var(--ink);
    border-color: var(--line);
}

.btn--ghost:hover {
    border-color: var(--muted-2);
    color: var(--ink);
    transform: translateY(-1px);
}

.btn--link {
    background: none;
    border: 0;
    color: var(--brand);
    padding: 4px;
    font-weight: 600;
}

.btn--link:hover {
    color: var(--brand-hover);
    text-decoration: underline;
}

.btn--sm {
    padding: 7px 14px;
    font-size: 13.5px;
    border-radius: 8px;
}

.btn--lg {
    padding: 14px 30px;
    font-size: 16px;
}

.btn--block {
    width: 100%;
}

.btn[disabled] {
    opacity: .55;
    cursor: not-allowed;
    transform: none !important;
}

.btn-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ── 卡片 ─────────────────────────────────────────────── */
.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 26px;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

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

.card--flat {
    background: var(--surface);
    border-color: var(--line-2);
}

.card__title {
    font-size: 17px;
    font-weight: 650;
    color: var(--ink);
    margin-bottom: 8px;
}

.card__desc {
    font-size: 14.5px;
    line-height: 1.75;
    color: var(--ink-3);
    margin: 0;
}

.card__foot {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--line-2);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 13.5px;
    color: var(--muted);
}

/* ── 图标块 ───────────────────────────────────────────── */
.icon-box {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    background: var(--brand-soft);
    color: var(--brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    margin-bottom: 16px;
    font-weight: 600;
}

.icon-box--sm {
    width: 34px;
    height: 34px;
    font-size: 16px;
    border-radius: 9px;
    margin-bottom: 0;
}

/* ── 状态标签 ─────────────────────────────────────────── */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.6;
    white-space: nowrap;
}

.tag--ok {
    background: var(--ok-bg);
    color: var(--ok-fg);
}

.tag--doing {
    background: var(--doing-bg);
    color: var(--doing-fg);
}

.tag--plan {
    background: var(--plan-bg);
    color: var(--plan-fg);
}

.tag--brand {
    background: var(--brand-soft);
    color: var(--brand);
}

.tag--plain {
    background: var(--surface-2);
    color: var(--ink-3);
    font-weight: 500;
}

.tag__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

.tag-list {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}

/* ── 特性列表 ─────────────────────────────────────────── */
.checks {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checks li {
    position: relative;
    padding-left: 26px;
    font-size: 15px;
    color: var(--ink-3);
    line-height: 1.7;
}

.checks li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 9px;
    width: 14px;
    height: 8px;
    border-left: 2px solid var(--brand);
    border-bottom: 2px solid var(--brand);
    transform: rotate(-45deg);
}

.steps {
    list-style: none;
    counter-reset: st;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.steps li {
    position: relative;
    padding-left: 38px;
    counter-increment: st;
    font-size: 15px;
    color: var(--ink-3);
}

.steps li::before {
    content: counter(st);
    position: absolute;
    left: 0;
    top: 2px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 12.5px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── 产品卡 ───────────────────────────────────────────── */
.product-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.product-card__name {
    font-size: 18px;
    font-weight: 680;
    color: var(--ink);
    letter-spacing: -.01em;
}

.product-card__code {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--muted-2);
    margin-top: 2px;
}

.product-card__slogan {
    font-size: 15px;
    line-height: 1.72;
    color: var(--ink-3);
    margin: 0 0 16px;
    flex: 1;
}

.product-card__highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 18px;
}

.chip {
    font-size: 12.5px;
    padding: 3px 9px;
    background: var(--surface);
    border: 1px solid var(--line-2);
    border-radius: 6px;
    color: var(--ink-3);
}

.product-card__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 15px;
    border-top: 1px solid var(--line-2);
    font-size: 13px;
    color: var(--muted);
}

/* ── 时间轴（现在在做 · 核心） ────────────────────────── */
.timeline {
    position: relative;
}

.tl-month {
    position: sticky;
    top: calc(var(--header-h) + 8px);
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 30px 0 16px;
    font-size: 14px;
    font-weight: 650;
    color: var(--ink);
    background: linear-gradient(to bottom, #fff 62%, rgba(255, 255, 255, 0));
    padding: 8px 0;
}

.tl-month:first-child {
    margin-top: 0;
}

.tl-month__line {
    flex: 1;
    height: 1px;
    background: var(--line);
}

.tl-month__count {
    font-size: 12.5px;
    color: var(--muted);
    font-weight: 500;
}

.tl-item {
    position: relative;
    display: grid;
    grid-template-columns: 58px 24px 1fr;
    gap: 0;
    padding-bottom: 14px;
}

.tl-item__date {
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--muted);
    padding-top: 18px;
    text-align: right;
    padding-right: 10px;
    white-space: nowrap;
}

.tl-item__rail {
    position: relative;
}

.tl-item__rail::before {
    content: "";
    position: absolute;
    left: 11px;
    top: 0;
    bottom: 0;
    width: 1px;
    background: var(--line);
}

.tl-item:last-child .tl-item__rail::before {
    bottom: auto;
    height: 30px;
}

.tl-item__dot {
    position: absolute;
    left: 7px;
    top: 22px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--muted-2);
    z-index: 1;
}

.tl-item--done .tl-item__dot {
    border-color: var(--ok-fg);
    background: var(--ok-bg);
}

.tl-item--doing .tl-item__dot {
    border-color: var(--doing-fg);
    background: var(--doing-bg);
    box-shadow: 0 0 0 4px rgba(250, 238, 218, .55);
}

.tl-item--top .tl-item__dot {
    border-color: var(--brand);
    background: var(--brand-soft);
}

.tl-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin-left: 8px;
    transition: border-color .16s ease, box-shadow .16s ease;
}

.tl-card:hover {
    border-color: #CBD5E1;
    box-shadow: var(--shadow-sm);
}

.tl-card__head {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.tl-card__title {
    font-size: 16px;
    font-weight: 650;
    color: var(--ink);
    margin: 0;
    line-height: 1.5;
}

.tl-card__body {
    font-size: 14.5px;
    line-height: 1.78;
    color: var(--ink-3);
    margin: 0;
    white-space: pre-wrap;
}

.tl-card__bar {
    margin-top: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.progress {
    flex: 1;
    height: 5px;
    background: var(--surface-2);
    border-radius: 999px;
    overflow: hidden;
}

.progress__fill {
    height: 100%;
    background: var(--brand);
    border-radius: 999px;
    transition: width .4s ease;
}

.progress__num {
    font-size: 12.5px;
    font-weight: 650;
    color: var(--brand);
    font-family: var(--mono);
    min-width: 34px;
    text-align: right;
}

.tl-card__imgs {
    display: flex;
    gap: 8px;
    margin-top: 14px;
    flex-wrap: wrap;
}

.tl-card__imgs img {
    width: 132px;
    height: 88px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
}

.tl-card__link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 12px;
    font-size: 13.5px;
    font-weight: 600;
}

/* ── 进行中快照卡 ─────────────────────────────────────── */
.snap {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.snap__stage {
    font-size: 13.5px;
    color: var(--doing-fg);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.snap--done .snap__stage {
    color: var(--ok-fg);
}

.snap__title {
    font-size: 15.5px;
    font-weight: 650;
    color: var(--ink);
    line-height: 1.5;
    margin: 0;
}

/* ── 筛选栏 ───────────────────────────────────────────── */
.filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 26px;
}

.filters__label {
    font-size: 13.5px;
    color: var(--muted);
    margin-right: 2px;
}

.filter {
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: #fff;
    font-size: 13.5px;
    color: var(--ink-3);
    cursor: pointer;
    transition: all .15s ease;
}

.filter:hover {
    border-color: var(--muted-2);
    color: var(--ink);
}

.filter.is-active {
    background: var(--ink);
    border-color: var(--ink);
    color: #fff;
    font-weight: 600;
}

.filter__count {
    opacity: .6;
    font-size: 12px;
    margin-left: 3px;
}

/* ── 价格表 ───────────────────────────────────────────── */
.price-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.price-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    position: relative;
}

.price-card--hot {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft);
}

.price-card__badge {
    position: absolute;
    top: -11px;
    left: 24px;
    background: var(--brand);
    color: #fff;
    font-size: 12px;
    font-weight: 650;
    padding: 3px 11px;
    border-radius: 999px;
}

.price-card__name {
    font-size: 15.5px;
    font-weight: 650;
    color: var(--ink);
    margin-bottom: 4px;
}

.price-card__unit {
    font-size: 12.5px;
    color: var(--muted);
    margin-bottom: 16px;
}

.price-card__num {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 6px;
}

.price-card__promo {
    font-size: 32px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -.02em;
    line-height: 1;
}

.price-card__promo small {
    font-size: 15px;
    font-weight: 600;
    color: var(--ink-3);
    margin-right: 1px;
}

.price-card__origin {
    font-size: 14px;
    color: var(--muted-2);
    text-decoration: line-through;
}

.price-card__save {
    display: inline-block;
    font-size: 12px;
    font-weight: 650;
    color: var(--hot);
    background: #FFF1E7;
    padding: 2px 8px;
    border-radius: 5px;
    margin-bottom: 16px;
}

.price-card__note {
    font-size: 14px;
    color: var(--ink-3);
    line-height: 1.7;
    margin: 0;
    flex: 1;
}

.price-note {
    margin-top: 26px;
    padding: 18px 20px;
    background: var(--surface);
    border: 1px solid var(--line-2);
    border-radius: var(--radius);
    font-size: 14px;
    color: var(--ink-3);
    line-height: 1.8;
}

.price-note strong {
    color: var(--ink);
}

/* ── 案例（能力实证） ─────────────────────────────────── */
.case-item {
    display: flex;
    gap: 20px;
    padding: 22px 0;
    border-bottom: 1px solid var(--line-2);
}

.case-item:last-child {
    border-bottom: 0;
}

.case-item__idx {
    font-family: var(--mono);
    font-size: 13px;
    color: var(--muted-2);
    width: 28px;
    flex-shrink: 0;
    padding-top: 3px;
}

.case-item__main {
    flex: 1;
}

.case-item__title {
    font-size: 16.5px;
    font-weight: 650;
    color: var(--ink);
    margin: 0 0 10px;
}

.case-item__metrics {
    font-size: 14px;
    color: var(--ink-3);
    margin-top: 10px;
}

.case-item__metrics strong {
    color: var(--ok-fg);
    font-weight: 600;
}

/* ── 表单 ─────────────────────────────────────────────── */
.form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.field label {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}

.field label .req {
    color: #DC2626;
    margin-left: 3px;
}

.field .hint {
    font-size: 12.5px;
    color: var(--muted);
}

.input,
.textarea,
.select {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    font-size: 15px;
    color: var(--ink);
    transition: border-color .15s ease, box-shadow .15s ease;
}

.input:focus,
.textarea:focus,
.select:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft);
}

.textarea {
    min-height: 130px;
    resize: vertical;
    line-height: 1.7;
}

.select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath fill='%2364748B' d='M6 8 0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: var(--ink-3);
    line-height: 1.7;
    cursor: pointer;
}

.checkbox input {
    margin-top: 4px;
    width: 16px;
    height: 16px;
    accent-color: var(--brand);
    flex-shrink: 0;
}

.field-error {
    font-size: 13px;
    color: #DC2626;
}

.form-note {
    font-size: 13px;
    color: var(--muted);
    line-height: 1.7;
}

.form-alert {
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 14px;
    display: none;
}

.form-alert.is-ok {
    display: block;
    background: var(--ok-bg);
    color: var(--ok-fg);
}

.form-alert.is-err {
    display: block;
    background: #FEF2F2;
    color: #B91C1C;
}

.hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* ── 正文排版（Markdown 渲染结果） ─────────────────────── */
.md-body {
    font-size: 16px;
    line-height: 1.85;
    color: var(--ink-2);
}

.md-body h1 {
    font-size: 27px;
    margin: 40px 0 16px;
}

.md-body h2 {
    font-size: 22px;
    margin: 38px 0 14px;
    padding-bottom: 9px;
    border-bottom: 1px solid var(--line-2);
}

.md-body h3 {
    font-size: 18px;
    margin: 30px 0 12px;
}

.md-body h4 {
    font-size: 16px;
    margin: 24px 0 10px;
}

.md-body>*:first-child {
    margin-top: 0;
}

.md-body p {
    margin: 0 0 1.15em;
}

.md-body ul,
.md-body ol {
    margin: 0 0 1.15em;
    padding-left: 1.4em;
}

.md-body ul {
    list-style: disc;
}

.md-body ol {
    list-style: decimal;
}

.md-body li {
    margin-bottom: .45em;
}

.md-body blockquote {
    margin: 0 0 1.15em;
    padding: 4px 0 4px 18px;
    border-left: 3px solid var(--brand);
    color: var(--ink-3);
    background: var(--surface);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    padding-right: 16px;
}

.md-body blockquote p:last-child {
    margin-bottom: 0;
}

.md-body img {
    border-radius: var(--radius);
    border: 1px solid var(--line);
    margin: 1.2em 0;
}

.md-body a {
    font-weight: 500;
    border-bottom: 1px solid rgba(29, 78, 216, .3);
}

.md-body a:hover {
    border-bottom-color: var(--brand);
}

.md-table-wrap {
    overflow-x: auto;
    margin: 0 0 1.4em;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.md-body table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14.5px;
    min-width: 420px;
}

.md-body th,
.md-body td {
    padding: 11px 15px;
    text-align: left;
    border-bottom: 1px solid var(--line-2);
    vertical-align: top;
}

.md-body thead th {
    background: var(--surface);
    font-weight: 650;
    color: var(--ink);
    white-space: nowrap;
}

.md-body tbody tr:last-child td {
    border-bottom: 0;
}

.md-body tbody tr:hover {
    background: #FBFCFE;
}

/* ── CTA 区块 ─────────────────────────────────────────── */
.cta-box {
    background: #0F172A;
    border-radius: var(--radius-lg);
    padding: 44px 40px;
    color: #CBD5E1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.cta-box h2 {
    color: #fff;
    margin-bottom: 8px;
    font-size: 25px;
}

.cta-box p {
    margin: 0;
    max-width: 560px;
    line-height: 1.75;
    font-size: 15px;
}

.cta-box .btn--ghost {
    background: transparent;
    color: #E2E8F0;
    border-color: rgba(226, 232, 240, .28);
}

.cta-box .btn--ghost:hover {
    background: rgba(255, 255, 255, .08);
    color: #fff;
    border-color: rgba(226, 232, 240, .5);
}

/* ── 文章列表 ─────────────────────────────────────────── */
.post-item {
    display: block;
    padding: 24px 0;
    border-bottom: 1px solid var(--line-2);
    color: inherit;
}

.post-item:hover {
    color: inherit;
}

.post-item:hover .post-item__title {
    color: var(--brand);
}

.post-item__meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 8px;
}

.post-item__title {
    font-size: 18px;
    font-weight: 650;
    color: var(--ink);
    margin: 0 0 8px;
    line-height: 1.5;
    transition: color .15s ease;
}

.post-item__summary {
    font-size: 14.5px;
    color: var(--ink-3);
    line-height: 1.75;
    margin: 0;
}

/* ── 加载更多 ─────────────────────────────────────────── */
.load-more {
    text-align: center;
    padding: 34px 0 8px;
}

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

@media (max-width: 768px) {
    .card {
        padding: 20px;
    }

    .cta-box {
        flex-direction: column;
        align-items: flex-start;
        padding: 32px 24px;
        gap: 22px;
    }

    .tl-item {
        grid-template-columns: 44px 20px 1fr;
    }

    .tl-item__date {
        font-size: 11.5px;
        padding-right: 8px;
        padding-top: 19px;
    }

    .tl-item__rail::before {
        left: 9px;
    }

    .tl-item__dot {
        left: 5px;
    }

    .tl-card {
        padding: 15px 16px;
        margin-left: 6px;
    }

    .tl-card__imgs img {
        width: 104px;
        height: 72px;
    }

    .case-item {
        gap: 12px;
    }

    .md-body h1 {
        font-size: 23px;
    }

    .md-body h2 {
        font-size: 20px;
    }
}
