/* ═══════════════════════════════════════════════════
   法律指南 — 共享样式
   ═══════════════════════════════════════════════════ */

/* 阅读进度条 */
.reading-progress {
    position: fixed;
    top: 68px;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #1a5fb4, #667eea);
    z-index: 999;
    transition: width 0.1s ease;
    width: 0;
}

/* 指南页通用布局 */
.guide-container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 30px 20px;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
}

.guide-content { min-width: 0; }
.guide-sidebar { position: sticky; top: 90px; align-self: start; }

/* 指南头部 */
.guide-header {
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}
.guide-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.4;
    margin-bottom: 12px;
}
.guide-header .summary {
    font-size: 15px;
    color: #6b7280;
    line-height: 1.7;
    margin-bottom: 12px;
}
.guide-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
    color: #9ca3af;
}
.guide-meta span { display: inline-flex; align-items: center; gap: 4px; }
.guide-meta .badge {
    background: #eff6ff;
    color: #2563eb;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 500;
}

/* 结论先行框 */
.tl-dr {
    background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 100%);
    border-left: 4px solid #2563eb;
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 28px;
}
.tl-dr h3 {
    font-size: 15px;
    color: #1e40af;
    margin-bottom: 8px;
    font-weight: 600;
}
.tl-dr p { font-size: 14px; color: #475569; line-height: 1.7; }

/* 目录 */
.guide-toc {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 18px 22px;
    margin-bottom: 28px;
}
.guide-toc h3 { font-size: 15px; color: #1a1a2e; margin-bottom: 10px; }
.guide-toc ul { list-style: none; }
.guide-toc li { margin-bottom: 6px; }
.guide-toc a {
    font-size: 14px;
    color: #4a5a6a;
    text-decoration: none;
    transition: color 0.2s;
    line-height: 1.6;
    display: block;
    padding: 2px 0;
}
.guide-toc a:hover { color: #1a5fb4; }
.guide-toc .toc-h3 { padding-left: 20px; font-size: 13px; }

/* 正文 */
.guide-section {
    margin-bottom: 36px;
    scroll-margin-top: 80px;
}
.guide-section h2 {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f0f0f0;
}
.guide-section h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e40af;
    margin: 20px 0 10px;
}
.guide-section p {
    font-size: 15px;
    color: #333;
    line-height: 1.8;
    margin-bottom: 14px;
}
.guide-section ul, .guide-section ol {
    margin: 8px 0 16px 20px;
    font-size: 15px;
    color: #333;
    line-height: 1.8;
}
.guide-section li { margin-bottom: 6px; }

/* 提示框 */
.tip-box {
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 16px 0;
    font-size: 14px;
    color: #166534;
    line-height: 1.7;
}
.tip-box strong { color: #15803d; }
.warn-box {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 16px 0;
    font-size: 14px;
    color: #92400e;
    line-height: 1.7;
}
.warn-box strong { color: #b45309; }

/* 法条引用 */
.law-ref {
    background: #fafafa;
    border-left: 3px solid #9ca3af;
    padding: 8px 14px;
    margin: 12px 0;
    font-size: 14px;
    color: #475569;
    line-height: 1.7;
}
.law-ref a { color: #2563eb; text-decoration: none; }
.law-ref a:hover { text-decoration: underline; }

/* 表格 */
.guide-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 14px;
}
.guide-table th {
    background: #f1f5f9;
    color: #1e293b;
    font-weight: 600;
    text-align: left;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
}
.guide-table td {
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    color: #333;
    line-height: 1.6;
}
.guide-table tr:nth-child(even) td { background: #f8fafc; }

/* 自查清单 */
.checklist-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 20px 24px;
    margin: 20px 0;
}
.checklist-box h4 { font-size: 16px; color: #1a1a2e; margin-bottom: 12px; }
.checklist-box ul { list-style: none; }
.checklist-box li {
    font-size: 14px;
    color: #475569;
    padding: 4px 0;
    line-height: 1.6;
}
.checklist-box li::before { content: "☐ "; font-size: 18px; color: #94a3b8; }

/* FAQ */
.faq-item {
    border-bottom: 1px solid #e5e7eb;
    padding: 12px 0;
}
.faq-item h4 { font-size: 15px; color: #1a1a2e; margin-bottom: 6px; cursor: pointer; }
.faq-item p { font-size: 14px; color: #6b7280; line-height: 1.7; }

/* 服务衔接 */
.service-cta {
    background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    padding: 20px 24px;
    margin: 28px 0;
    text-align: center;
}
.service-cta h3 { font-size: 18px; color: #1e40af; margin-bottom: 8px; }
.service-cta p { font-size: 14px; color: #475569; line-height: 1.7; margin-bottom: 14px; }
.service-cta .cta-btn {
    display: inline-block;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: #fff;
    padding: 10px 32px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s;
}
.service-cta .cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37,99,235,0.3);
}

/* 信任要素 */
.trust-footer {
    border-top: 2px solid #f0f0f0;
    padding-top: 20px;
    margin-top: 32px;
}
.trust-footer .author-info {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}
.trust-footer .author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb, #667eea);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    font-weight: 700;
}
.trust-footer .author-text { font-size: 14px; }
.trust-footer .author-text .name { font-weight: 600; color: #1a1a2e; }
.trust-footer .author-text .title { color: #6b7280; }
.trust-footer .review-date { font-size: 13px; color: #9ca3af; margin-bottom: 8px; }
.trust-footer .disclaimer {
    font-size: 13px;
    color: #9ca3af;
    line-height: 1.7;
    padding: 12px;
    background: #f9fafb;
    border-radius: 8px;
    margin-bottom: 8px;
}
.trust-footer .error-link { font-size: 13px; }
.trust-footer .error-link a { color: #6b7280; text-decoration: underline; }

/* 侧边栏 */
.sidebar-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px 18px;
    margin-bottom: 16px;
}
.sidebar-card h4 { font-size: 14px; color: #1a1a2e; margin-bottom: 10px; font-weight: 600; }
.sidebar-card ul { list-style: none; }
.sidebar-card li { margin-bottom: 8px; }
.sidebar-card a {
    font-size: 13px;
    color: #4a5a6a;
    text-decoration: none;
    line-height: 1.5;
    transition: color 0.2s;
}
.sidebar-card a:hover { color: #1a5fb4; }
.sidebar-card .badge {
    display: inline-block;
    font-size: 11px;
    background: #eff6ff;
    color: #2563eb;
    padding: 1px 6px;
    border-radius: 3px;
    margin-left: 4px;
}

/* 浮动按钮 */
.float-cta {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: #fff;
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(37,99,235,0.4);
    z-index: 900;
    transition: all 0.25s;
    display: none;
}
.float-cta:hover { transform: scale(1.05); }

/* ═══════════════════════════════════════════════════
   法律指南首页样式
   ═══════════════════════════════════════════════════ */

.guide-hero {
    background: linear-gradient(135deg, #1a5fb4 0%, #667eea 100%);
    color: #fff;
    padding: 60px 0 70px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.guide-hero::before {
    content: "";
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 70%);
    animation: heroShine 8s ease-in-out infinite;
}
.guide-hero .container { position: relative; z-index: 1; }
.guide-hero h1 { font-size: 36px; font-weight: 700; margin-bottom: 14px; }
.guide-hero p { font-size: 16px; opacity: 0.95; margin: 0 auto 24px; max-width: 600px; line-height: 1.6; }

.cluster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 40px 0;
}
.cluster-card {
    background: #fff;
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid #f0f0f0;
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    text-decoration: none;
    color: inherit;
}
.cluster-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.10);
}
.cluster-card .cluster-icon {
    width: 52px; height: 52px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 26px;
    margin-bottom: 14px;
}
.cluster-card h3 { font-size: 18px; font-weight: 700; color: #1a1a2e; margin-bottom: 6px; }
.cluster-card .cluster-desc { font-size: 13.5px; color: #6b7280; line-height: 1.6; margin-bottom: 10px; }
.cluster-card .cluster-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.cluster-card .cluster-tag {
    font-size: 12px;
    background: #f1f5f9;
    color: #475569;
    padding: 3px 8px;
    border-radius: 4px;
}
.cluster-card.coming-soon { opacity: 0.55; }
.cluster-card.coming-soon .cluster-icon { filter: grayscale(0.5); }

/* ═══════════════════════════════════════════════════
   法律指南首页 — 三大板块分区样式
   文书怎么写(蓝) / 事情怎么办(紫) / 钱怎么算(橙)
   ═══════════════════════════════════════════════════ */

.guide-block {
    border-radius: 16px;
    padding: 26px 26px 6px;
    margin: 26px 0;
    border: 1px solid;
}
.guide-block .block-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    border-left: 4px solid;
    padding-left: 16px;
    margin-bottom: 4px;
}
.guide-block .block-num {
    flex-shrink: 0;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    border-radius: 6px;
    padding: 4px 10px;
    margin-top: 5px;
    letter-spacing: 1px;
}
.guide-block h2 {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 4px;
    line-height: 1.4;
}
.guide-block .block-sub {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    line-height: 1.6;
}
/* 板块内卡片网格收紧边距 */
.guide-block .cluster-grid { padding: 16px 0 24px; }

/* 01 文书怎么写 — 蓝色系 */
.block-write {
    background: #f5f9ff;
    border-color: #dbeafe;
}
.block-write .block-header { border-left-color: #2563eb; }
.block-write .block-num { background: #2563eb; }
.block-write .cluster-card { border-top: 3px solid #2563eb; }

/* 02 事情怎么办 — 紫色系 */
.block-do {
    background: #faf7ff;
    border-color: #ede9fe;
}
.block-do .block-header { border-left-color: #7c3aed; }
.block-do .block-num { background: #7c3aed; }
.block-do .cluster-card { border-top: 3px solid #7c3aed; }

/* 03 钱怎么算 — 橙色系 */
.block-money {
    background: #fffcf5;
    border-color: #fde8c8;
}
.block-money .block-header { border-left-color: #d97706; }
.block-money .block-num { background: #d97706; }
.block-money .cluster-card { border-top: 3px solid #d97706; }


/* 场景分类 */
.scene-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    padding: 30px 0;
}
.scene-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 18px;
    text-decoration: none;
    color: inherit;
    transition: all 0.25s;
    text-align: center;
}
.scene-card:hover { border-color: #93c5fd; background: #eff6ff; }
.scene-card .scene-icon { font-size: 28px; margin-bottom: 8px; }
.scene-card h4 { font-size: 15px; color: #1a1a2e; margin-bottom: 4px; }
.scene-card p { font-size: 12px; color: #9ca3af; }

/* 响应式 */
@media (max-width: 900px) {
    .guide-container { grid-template-columns: 1fr; }
    .guide-sidebar { display: none; }
    .float-cta { display: inline-block; }
}
@media (max-width: 768px) {
    .guide-header h1 { font-size: 22px; }
    .guide-section h2 { font-size: 19px; }
    .guide-section p { font-size: 14.5px; }
    .guide-hero h1 { font-size: 26px; }
    .guide-hero p { font-size: 15px; }
    .cluster-grid { grid-template-columns: 1fr; }
    .guide-block { padding: 18px 14px 4px; margin: 18px 0; border-radius: 12px; }
    .guide-block h2 { font-size: 19px; }
    .guide-block .block-header { padding-left: 12px; gap: 10px; }
    .guide-block .block-sub { font-size: 13px; }
    .guide-table { font-size: 13px; }
    .guide-table th, .guide-table td { padding: 8px 10px; }
}
