/* ═══════════════════════════════════════════════════
   BLOG ARTICLE STYLES — Roof Repair Pasadena TX
   Mobile-first · AEO/GEO optimized layout
   ═══════════════════════════════════════════════════ */

/* ── Article Hero / Header ── */
.blog-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: clamp(2.75rem, 7vw, 5.25rem) 0 clamp(2.5rem, 5vw, 4rem);
    background:
        radial-gradient(circle at 88% 14%, rgba(249, 115, 22, 0.28), transparent 23rem),
        radial-gradient(circle at 76% 110%, rgba(37, 99, 235, 0.30), transparent 26rem),
        linear-gradient(125deg, #071a31 0%, #0c2340 52%, #102c51 100%);
    border-bottom: 3px solid #f97316;
}

.blog-hero::before {
    content: '';
    position: absolute;
    z-index: -1;
    width: 380px;
    height: 380px;
    top: -260px;
    right: 6%;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;
    box-shadow: 0 0 0 44px rgba(255, 255, 255, 0.035), 0 0 0 88px rgba(255, 255, 255, 0.02);
}

.blog-hero::after {
    content: '';
    position: absolute;
    z-index: -1;
    inset: 0;
    opacity: 0.16;
    background-image: linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px), linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to right, #000 0%, transparent 80%);
}

/* Evidence-backed cross-links and primary-source citations in long-form guides. */
.blog-editorial-references {
    margin-top: 2rem;
}

.blog-context-links {
    padding: 1rem 1.1rem;
    margin: 0 0 1.35rem;
    border-left: 3px solid var(--accent-orange, #ff6b14);
    background: #f5f8fc;
    color: #425a78;
    line-height: 1.65;
}

.blog-context-links a,
.blog-sources a {
    color: #1f5fe0;
    font-weight: 600;
}

.blog-hero .container {
    max-width: 1180px;
    position: relative;
}

.blog-hero-grid {
    max-width: 52rem;
    margin: 0 auto;
    text-align: center;
}

.blog-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.58);
    margin-bottom: 1.35rem;
    flex-wrap: wrap;
    justify-content: center;
}

.blog-breadcrumb a {
    color: rgba(255,255,255,0.76);
    text-decoration: none;
    transition: color 0.2s;
}

.blog-breadcrumb a:hover {
    color: var(--accent, #f59e0b);
}

.blog-breadcrumb .bc-sep {
    color: rgba(255,255,255,0.3);
    font-size: 0.7rem;
}

.blog-category-badge {
    display: inline-block;
    background: rgba(249, 115, 22, 0.16);
    border: 1px solid rgba(251, 146, 60, 0.42);
    color: #fed7aa;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    padding: 0.38rem 0.75rem;
    border-radius: 100px;
    margin-bottom: 1rem;
}

.blog-hero h1 {
    font-family: 'Outfit', sans-serif;
    max-width: 850px;
    font-size: clamp(2rem, 4.5vw, 3.35rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.1;
    color: #fff;
    margin: 0 auto 1.15rem;
}

.blog-hero h1 mark {
    background: linear-gradient(110deg, #bae6fd 0%, #38bdf8 54%, #7dd3fc 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.blog-hero-desc {
    max-width: 42rem;
    margin: 0 auto 1.6rem;
    color: #d5e2f1;
    font-size: clamp(1rem, 1.5vw, 1.075rem);
    line-height: 1.7;
}

.blog-hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 1.6rem;
}

.blog-hero-actions .btn {
    min-height: 48px;
    text-decoration: none;
}

.blog-hero-actions .btn-ghost {
    border-color: rgba(255,255,255,.42);
    color: #fff;
    background: rgba(255,255,255,.04);
}

.blog-hero-actions .btn-ghost:hover {
    border-color: #fff;
    background: rgba(255,255,255,.12);
    color: #fff;
}

.blog-meta {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.78);
    flex-wrap: wrap;
    justify-content: center;
}

.blog-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0.4rem 0.65rem;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
}

.blog-meta svg {
    width: 14px;
    height: 14px;
    vertical-align: -2px;
    margin-right: 3px;
    color: #fdba74;
    opacity: 1;
}

.blog-hero-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(191, 219, 254, .22);
}

.blog-hero-stats > div {
    min-height: 76px;
    display: grid;
    align-content: center;
    padding: 0.7rem 0.45rem;
    border: 1px solid rgba(191, 219, 254, .15);
    border-radius: 10px;
    background: rgba(255, 255, 255, .045);
}

.blog-hero-stats strong {
    color: #fb923c;
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.05rem, 2vw, 1.3rem);
}

.blog-hero-stats span {
    margin-top: 0.22rem;
    color: #a9bbcf;
    font-size: 0.67rem;
    line-height: 1.3;
    letter-spacing: .055em;
    text-transform: uppercase;
}

/* ── Article Body ── */
.blog-article {
    padding: 2rem 0 3rem;
}

.blog-article .container {
    max-width: 1180px;
}

.blog-article-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    grid-template-areas: 'content sidebar';
    gap: clamp(2rem, 5vw, 4.5rem);
    align-items: start;
}

.blog-content {
    grid-area: content;
    min-width: 0;
}

.blog-topic-table {
    grid-area: sidebar;
    position: sticky;
    top: 94px;
}

.blog-topic-table-inner {
    padding: 1.25rem;
    background: #f8fafc;
    border: 1px solid #dbe4ee;
    border-top: 3px solid #f97316;
    border-radius: 12px;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.blog-topic-eyebrow {
    display: block;
    margin-bottom: 0.35rem;
    color: #d97706;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.blog-topic-table h2 {
    margin: 0 0 0.85rem;
    padding: 0;
    border: 0;
    color: #0f172a;
    font-family: 'Outfit', sans-serif;
    font-size: 1.15rem;
}

.blog-topic-table nav {
    display: grid;
    gap: 0.15rem;
}

.blog-topic-table a {
    display: block;
    padding: 0.55rem 0.6rem;
    border-left: 2px solid transparent;
    color: #475569;
    font-size: 0.82rem;
    line-height: 1.35;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.blog-topic-table a:hover,
.blog-topic-table a:focus-visible {
    background: #fff7ed;
    border-left-color: #f97316;
    color: #9a3412;
    outline: none;
}

.blog-content h2[id] {
    scroll-margin-top: 100px;
}

.blog-content {
    font-size: 1.02rem;
    line-height: 1.75;
    color: var(--text, #e2e8f0);
}

.blog-content h2 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.2rem, 3vw, 1.55rem);
    font-weight: 700;
    color: #0f172a;
    margin: 2.5rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.blog-content h3 {
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 1.8rem 0 0.7rem;
}

.blog-content p {
    margin: 0 0 1.2rem;
    color: #475569;
}

.blog-content ul,
.blog-content ol {
    margin: 0 0 1.2rem;
    padding-left: 1.4rem;
}

.blog-content li {
    margin-bottom: 0.5rem;
    color: #475569;
}

.blog-content a {
    color: var(--accent, #f59e0b);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s;
}

.blog-content a:hover {
    color: #fbbf24;
}

/* ── Quick Answer Box (AEO/GEO Critical) ── */
.quick-answer {
    background: linear-gradient(135deg, rgba(245,158,11,0.08) 0%, rgba(245,158,11,0.03) 100%);
    border: 1px solid rgba(245,158,11,0.2);
    border-left: 4px solid var(--accent, #f59e0b);
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    margin: 0 0 2rem;
}

.quick-answer-label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent, #f59e0b);
    margin-bottom: 0.6rem;
}

.quick-answer-label svg {
    width: 15px;
    height: 15px;
}

.quick-answer p {
    font-size: 1rem;
    line-height: 1.65;
    color: #334155;
    margin: 0;
}

/* ── Key Takeaways Box ── */
.key-takeaways {
    background: rgba(16, 185, 129, 0.06);
    border: 1px solid rgba(16, 185, 129, 0.15);
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    margin: 0 0 2rem;
}

.key-takeaways-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: #10b981;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.8rem;
}

.key-takeaways-title svg {
    width: 16px;
    height: 16px;
}

.key-takeaways ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.key-takeaways li {
    position: relative;
    padding-left: 1.4rem;
    margin-bottom: 0.5rem;
    font-size: 0.92rem;
    line-height: 1.5;
    color: #334155;
}

.key-takeaways li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 0;
    color: #10b981;
    font-weight: 700;
    font-size: 0.85rem;
}

/* ── Comparison / Data Tables ── */
.blog-table-wrap {
    overflow-x: auto;
    margin: 1.5rem 0 2rem;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    -webkit-overflow-scrolling: touch;
}

.blog-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
    min-width: 480px;
}

.blog-table thead {
    background: #f8fafc;
}

.blog-table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    color: #0f172a;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 1px solid #e2e8f0;
    white-space: nowrap;
}

.blog-table td {
    padding: 0.7rem 1rem;
    color: #334155;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
}

.blog-table tbody tr:hover {
    background: #fffbeb;
}

.blog-table tbody tr:last-child td {
    border-bottom: none;
}

/* ── FAQ Accordion (Homepage Style) ── */
.faq-list,
.blog-content .faq-list {
    margin: 1.5rem 0 2.5rem;
    border-top: 1px solid var(--card-border, #e2e8f0);
}

.faq-item,
.blog-content .faq-item {
    border-bottom: 1px solid var(--card-border, #e2e8f0);
}

.faq-q,
.blog-content .faq-q {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-body, 'Inter', sans-serif);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text, #1e293b);
    text-align: left;
    gap: 16px;
    transition: color 0.25s ease;
}

.faq-q:hover,
.blog-content .faq-q:hover {
    color: var(--accent-dark, #1d4ed8);
}

.faq-q-icon,
.blog-content .faq-q-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-alt, #f8fafc);
    border-radius: 9999px;
    flex-shrink: 0;
    transition: all 0.25s ease;
    color: var(--text-muted, #64748b);
}

.faq-q-icon svg,
.blog-content .faq-q-icon svg {
    width: 16px;
    height: 16px;
    transition: transform 0.25s ease;
}

.faq-item.active .faq-q-icon,
.blog-content .faq-item.active .faq-q-icon {
    background: var(--accent, #2563eb);
    color: #ffffff;
}

.faq-item.active .faq-q-icon svg,
.blog-content .faq-item.active .faq-q-icon svg {
    transform: rotate(45deg);
}

.faq-a,
.blog-content .faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.faq-item.active .faq-a,
.blog-content .faq-item.active .faq-a {
    max-height: 800px;
}

.faq-a-inner,
.blog-content .faq-a-inner {
    padding: 0 0 20px;
    font-size: 0.92rem;
    color: var(--text-muted, #64748b);
    line-height: 1.75;
}

.faq-a-inner p,
.blog-content .faq-a-inner p {
    font-size: 0.92rem;
    color: var(--text-muted, #64748b);
    line-height: 1.75;
    margin: 0;
}

/* ── Sources / References ── */
.blog-sources {
    background: #f8fafc;
    border: 1px solid #dbe4ee;
    border-left: 4px solid #f59e0b;
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    margin: 2rem 0;
}

.blog-sources-title {
    font-size: 0.78rem;
    font-weight: 700;
    color: #334155;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.7rem;
}

.blog-sources ol {
    list-style: decimal;
    padding-left: 1.2rem;
    margin: 0;
}

.blog-sources li {
    font-size: 0.82rem;
    line-height: 1.5;
    color: #64748b;
    margin-bottom: 0.3rem;
}

.blog-sources a {
    color: #2563eb;
    text-decoration: none;
    border-bottom: 1px dashed rgba(148,163,184,0.3);
}

.blog-sources a:hover {
    color: var(--accent, #f59e0b);
}

/* ── Related Services & Articles ── */
.blog-related {
    margin: 2.75rem 0;
}

.blog-related-title {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
    padding: 0 0 0.7rem 0.8rem;
    border-bottom: 1px solid #e2e8f0;
    border-left: 3px solid #f97316;
}

.blog-related-grid {
    display: grid;
    gap: 0.8rem;
}

.blog-content .blog-related-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    min-height: 84px;
    padding: 1rem 3.7rem 1rem 1rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    text-decoration: none;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.blog-content .blog-related-card::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: #f59e0b;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.blog-related-card:hover {
    border-color: #fbbf24;
    background: #fffbeb;
    transform: translateX(4px);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.blog-related-card:hover::before {
    opacity: 1;
}

.blog-related-card .rc-icon {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(245,158,11,0.1);
    border-radius: 10px;
    color: var(--accent, #f59e0b);
}

.blog-related-card .rc-icon svg {
    width: 18px;
    height: 18px;
}

.blog-related-card .rc-text {
    flex: 1;
}

.blog-related-card .rc-title {
    display: block;
    font-size: 0.94rem;
    font-weight: 700;
    color: #0f172a;
}

.blog-related-card .rc-desc {
    display: block;
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 2px;
}

.blog-related-card .rc-arrow {
    position: absolute;
    right: 1rem;
    display: grid;
    width: 28px;
    height: 28px;
    place-items: center;
    border: 1px solid #dbe4ee;
    border-radius: 50%;
    color: #2563eb;
    font-size: 1rem;
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.blog-related-card:hover .rc-arrow {
    color: #ffffff;
    border-color: #2563eb;
    background: #2563eb;
}

.blog-service-areas .blog-related-title {
    border-left-color: #2563eb;
}

.blog-service-areas .blog-related-card::before {
    background: #2563eb;
}

.blog-service-areas .blog-related-card .rc-icon {
    background: #eff6ff;
    color: #2563eb;
}

/* ── Blog CTA Section ── */
.blog-cta {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background: linear-gradient(135deg, #0c2340 0%, #0a1f38 100%);
    border: 0;
    border-radius: 14px;
    padding: 3.5rem 2rem;
    margin: 2.5rem 0 1rem;
    text-align: center;
}

.blog-cta::before {
    content: '';
    position: absolute;
    z-index: -1;
    width: 390px;
    height: 390px;
    top: -245px;
    right: -130px;
    border: 1px solid rgba(255, 255, 255, 0.11);
    border-radius: 50%;
    box-shadow: 0 0 0 42px rgba(255, 255, 255, 0.035), 0 0 0 84px rgba(255, 255, 255, 0.025);
}

.blog-cta::after {
    content: '';
    position: absolute;
    z-index: -1;
    width: 180px;
    height: 180px;
    bottom: -115px;
    left: -50px;
    background: rgba(249, 115, 22, 0.18);
    border-radius: 50%;
    filter: blur(2px);
}

.blog-cta h3 {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.35rem, 3vw, 1.8rem);
    font-weight: 800;
    line-height: 1.25;
    color: #ffffff;
    margin: 0 0 0.6rem;
}

.blog-cta p {
    font-size: 1rem;
    line-height: 1.7;
    color: #cbd5e1;
    margin: 0 0 1.2rem;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.blog-cta-buttons {
    display: flex;
    gap: 0.9rem;
    justify-content: center;
    flex-wrap: wrap;
}

.blog-cta .btn {
    min-height: 52px;
    min-width: 205px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.blog-cta .btn-outline-white {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.6);
    color: #ffffff;
    box-shadow: none;
}

.blog-cta .btn-outline-white:hover {
    background: #ffffff;
    border-color: #ffffff;
    color: #172554;
    transform: translateY(-2px);
}

/* ── E-E-A-T Trust Block ── */
.blog-trust {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem 1.25rem;
    margin: 2rem 0;
    font-size: 0.82rem;
    line-height: 1.55;
    color: #64748b;
}

.blog-trust strong {
    color: #334155;
}

/* ── Info/Regulation Callout Boxes ── */
.blog-callout {
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    margin: 1.5rem 0;
}

.blog-callout.callout-info {
    background: rgba(59, 130, 246, 0.06);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-left: 4px solid #3b82f6;
}

.blog-callout.callout-warning {
    background: rgba(245, 158, 11, 0.06);
    border: 1px solid rgba(245, 158, 11, 0.15);
    border-left: 4px solid #f59e0b;
}

.blog-callout.callout-regulation {
    background: rgba(139, 92, 246, 0.06);
    border: 1px solid rgba(139, 92, 246, 0.15);
    border-left: 4px solid #8b5cf6;
}

.blog-callout-label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.callout-info .blog-callout-label { color: #3b82f6; }
.callout-warning .blog-callout-label { color: #f59e0b; }
.callout-regulation .blog-callout-label { color: #8b5cf6; }

.blog-callout p {
    font-size: 0.92rem;
    line-height: 1.6;
    color: #334155;
    margin: 0;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .blog-hero {
        padding: 2.4rem 0 2.15rem;
    }

    .blog-hero h1 {
        font-size: clamp(1.85rem, 9vw, 2.5rem);
    }

    .blog-meta {
        gap: 0.5rem;
    }

    .blog-meta span {
        min-height: 32px;
        padding: 0.35rem 0.55rem;
    }

    .blog-hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .blog-hero-actions .btn {
        justify-content: center;
        width: 100%;
    }

    .blog-hero-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .blog-article-layout {
        grid-template-columns: 1fr;
        grid-template-areas: 'sidebar' 'content';
        gap: 1.75rem;
    }

    .blog-topic-table {
        position: static;
    }

    .blog-topic-table-inner {
        padding: 1rem;
    }

    .blog-topic-table nav {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 0.6rem;
    }

    .blog-content h2 {
        margin-top: 2rem;
    }

    .quick-answer,
    .key-takeaways,
    .blog-sources,
    .blog-callout {
        padding: 1rem 1.1rem;
    }

    .blog-cta {
        padding: 2.5rem 1.25rem;
    }

    .blog-cta-buttons {
        flex-direction: column;
    }

    .blog-cta-buttons .btn {
        width: 100%;
        text-align: center;
    }

    .blog-table {
        font-size: 0.82rem;
    }

    .blog-table th,
    .blog-table td {
        padding: 0.6rem 0.7rem;
    }

    .blog-related-card {
        padding: 0.7rem 0.8rem;
    }
}

@media (min-width: 1024px) {
    .blog-hero {
        padding: 5.25rem 0 4rem;
    }

    .blog-article {
        padding: 2.5rem 0 4rem;
    }

    .blog-related-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* ── Site Design-System Alignment ── */
.blog-hero {
    background-color: #061324;
    background-image:
        radial-gradient(circle at 15% 5%, rgba(56, 189, 248, .15), transparent 32rem),
        radial-gradient(circle at 88% 88%, rgba(234, 88, 12, .13), transparent 25rem),
        linear-gradient(135deg, var(--primary), #061324 68%);
    border-bottom-color: var(--cta);
}

.blog-hero::after {
    opacity: 0.16;
    background-image:
        linear-gradient(30deg, rgba(255,255,255,.12) 1px, transparent 1px),
        linear-gradient(150deg, rgba(255,255,255,.12) 1px, transparent 1px);
    background-size: 48px 28px;
    background-position: 0 0, 24px 14px;
}

.blog-category-badge {
    background: rgba(37, 99, 235, .15);
    border-color: rgba(37, 99, 235, .35);
    color: #93c5fd;
    border-radius: var(--radius-full);
}

.blog-hero h1 mark {
    background: linear-gradient(135deg, #60a5fa 0%, #38bdf8 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

.blog-article {
    background: var(--bg);
}

.blog-content h2 {
    color: var(--primary);
    border-bottom-color: var(--card-border);
}

.blog-content h3 {
    color: var(--text);
}

.blog-content p,
.blog-content li {
    color: var(--text-muted);
}

.blog-topic-table-inner,
.blog-sources,
.blog-trust {
    background: var(--bg-alt);
    border-color: var(--card-border);
    border-radius: var(--radius);
}

.blog-topic-table-inner {
    border-top-color: var(--cta);
    box-shadow: var(--shadow-sm);
}

.blog-topic-table h2,
.blog-related-card .rc-title,
.blog-cta h3 {
    color: var(--primary);
}

.blog-topic-table a,
.blog-related-card .rc-desc,
.blog-sources li,
.blog-trust {
    color: var(--text-muted);
}

.blog-topic-table a:hover,
.blog-topic-table a:focus-visible {
    background: var(--accent-soft);
    border-left-color: var(--accent);
    color: var(--accent-dark);
}

.blog-content .blog-related-card {
    border-color: var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.blog-related-card:hover {
    border-color: var(--accent);
    background: var(--bg);
    box-shadow: var(--shadow-md);
}

.blog-related-card .rc-icon {
    background: var(--accent-soft);
    color: var(--accent);
}

.blog-related-title {
    border-left-color: var(--cta);
    color: var(--primary);
}

.blog-content .blog-related-card::before {
    background: var(--accent);
}

.blog-cta {
    background: linear-gradient(135deg, var(--primary) 0%, #0a1f38 100%);
    border-radius: var(--radius-lg);
}

/* Cluster 4 template bridge
   Posts 19–21 were drafted before the current Blog 1 component system. Keep
   their long-form diagnostic copy intact while rendering them with the same
   hero, article rail, and responsive rules as the current blog template. */
.cluster-4-legacy-template .blog-hero-inner {
    max-width: 52rem;
    margin: 0 auto;
    text-align: center;
}

.cluster-4-legacy-template .svc-breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    flex-wrap: wrap;
    margin-bottom: 1.35rem;
    color: rgba(255, 255, 255, .58);
    font-size: .78rem;
}

.cluster-4-legacy-template .svc-breadcrumb a {
    color: rgba(255, 255, 255, .76);
    text-decoration: none;
}

.cluster-4-legacy-template .svc-breadcrumb svg {
    width: .8rem;
    height: .8rem;
    color: rgba(255, 255, 255, .3);
}

.cluster-4-legacy-template .blog-pill-badge {
    display: inline-block;
    margin-bottom: 1rem;
    padding: .38rem .75rem;
    border: 1px solid rgba(37, 99, 235, .35);
    border-radius: var(--radius-full);
    background: rgba(37, 99, 235, .15);
    color: #93c5fd;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.cluster-4-legacy-template .blog-meta-bar {
    display: flex;
    justify-content: center;
    gap: .65rem;
    flex-wrap: wrap;
    color: rgba(255, 255, 255, .78);
    font-size: .78rem;
}

.cluster-4-legacy-template .blog-meta-bar span {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    padding: .4rem .65rem;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 6px;
    background: rgba(255, 255, 255, .07);
}

.cluster-4-legacy-template .hero-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .7rem;
    margin-top: 1.5rem !important;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(191, 219, 254, .22);
}

.cluster-4-legacy-template .hero-stat-card {
    min-height: 76px;
    display: grid;
    align-content: center;
    padding: .7rem .45rem;
    border: 1px solid rgba(191, 219, 254, .15);
    border-radius: 10px;
    background: rgba(255, 255, 255, .045);
}

.cluster-4-legacy-template .hero-stat-num {
    color: #fb923c;
    font-family: 'Outfit', sans-serif;
    font-size: clamp(1.05rem, 2vw, 1.3rem);
    font-weight: 700;
}

.cluster-4-legacy-template .hero-stat-lbl {
    margin-top: .22rem;
    color: #a9bbcf;
    font-size: .67rem;
    line-height: 1.3;
    letter-spacing: .055em;
    text-transform: uppercase;
}

.cluster-4-legacy-template .blog-article-section {
    padding: 2.5rem 0 4rem;
    background: var(--bg);
}

.cluster-4-legacy-template .blog-article-section .container {
    max-width: 1180px;
}

.cluster-4-legacy-template .blog-topic-table .topic-box {
    padding: 1.25rem;
    border: 1px solid var(--card-border);
    border-top: 3px solid var(--cta);
    border-radius: var(--radius);
    background: var(--bg-alt);
    box-shadow: var(--shadow-sm);
}

.cluster-4-legacy-template .topic-box h3 {
    margin: 0 0 .85rem;
    color: var(--primary);
    font-family: 'Outfit', sans-serif;
    font-size: 1.15rem;
}

.cluster-4-legacy-template .topic-list {
    display: grid;
    gap: .15rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.cluster-4-legacy-template .topic-list a {
    display: block;
    padding: .55rem .6rem;
    border-left: 2px solid transparent;
    color: var(--text-muted);
    font-size: .82rem;
    line-height: 1.35;
    text-decoration: none;
}

.cluster-4-legacy-template .topic-list a:hover,
.cluster-4-legacy-template .topic-list a:focus-visible {
    border-left-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent-dark);
    outline: none;
}

.cluster-4-legacy-template .blog-quick-contact {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--card-border);
}

.cluster-4-legacy-template .blog-quick-contact h4 {
    margin: 0 0 .4rem;
    color: var(--primary);
}

.cluster-4-legacy-template .blog-quick-contact p {
    margin-bottom: .8rem;
    color: var(--text-muted);
    font-size: .82rem;
    line-height: 1.5;
}

.cluster-4-legacy-template .blog-quick-contact .btn-block {
    display: block;
    margin-top: .55rem;
    text-align: center;
}

/* Heavy-rain article topic rail: match the site's orange action / navy secondary pair. */
.heavy-rain-diagnostic .blog-quick-contact .btn-phone {
    border: 1px solid var(--cta);
    background: var(--cta);
    color: #fff;
    box-shadow: 0 5px 12px rgba(234, 88, 12, .22);
}

.heavy-rain-diagnostic .blog-quick-contact .btn-phone:hover {
    border-color: var(--cta-dark);
    background: var(--cta-dark);
    color: #fff;
}

.heavy-rain-diagnostic .blog-quick-contact .btn-ghost {
    border: 1px solid var(--primary);
    background: #fff;
    color: var(--primary);
}

.heavy-rain-diagnostic .blog-quick-contact .btn-ghost:hover {
    background: var(--primary);
    color: #fff;
}

@media (max-width: 760px) {
    .cluster-4-legacy-template .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .cluster-4-legacy-template .blog-meta-bar { justify-content: flex-start; }
}

/* Use the same compact phone icon treatment as the homepage header. */
.cluster-4-post .header .btn-phone > svg,
.cluster-4-post .header .header-phone-link > svg {
    display: block !important;
    width: 16px !important;
    height: 16px !important;
    min-width: 16px !important;
    max-width: 16px !important;
    min-height: 16px !important;
    max-height: 16px !important;
    flex: 0 0 16px !important;
}

/* Remove the pre-header emergency strip on Cluster 4 posts only. */
.cluster-4-post > .top-bar,
.cluster-4-post > .emergency-bar {
    display: none !important;
}

/* Shared topic-rail pattern across every blog guide. */
.blog-topic-table-inner,
.cluster-4-legacy-template .blog-topic-table .topic-box {
    border-top: 3px solid var(--cta);
    border-radius: 10px;
    background: #f8fafc;
}

.blog-topic-table-inner nav a,
.cluster-4-legacy-template .topic-list a {
    border-left: 2px solid transparent;
}

.blog-topic-table-inner nav a:first-child,
.cluster-4-legacy-template .topic-list a:first-child {
    border-left-color: #dbeafe;
}

.blog-topic-cta,
.cluster-4-legacy-template .blog-quick-contact {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #dbe4ee;
}

.blog-topic-cta h4,
.cluster-4-legacy-template .blog-quick-contact h4 {
    color: var(--primary);
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 800;
}

.blog-topic-cta .btn-block,
.cluster-4-legacy-template .blog-quick-contact .btn-block {
    display: block;
    width: 100%;
    margin-top: .55rem;
    padding: .68rem .8rem;
    border-radius: 9px;
    text-align: center;
    font-size: .8rem;
    font-weight: 800;
    text-decoration: none;
}

.blog-topic-cta .btn-phone,
.cluster-4-legacy-template .blog-quick-contact .btn-phone {
    border: 1px solid var(--cta);
    background: var(--cta);
    color: #fff;
    box-shadow: 0 5px 12px rgba(234, 88, 12, .2);
}

.blog-topic-cta .btn-ghost,
.cluster-4-legacy-template .blog-quick-contact .btn-ghost {
    border: 1px solid var(--primary);
    background: #fff;
    color: var(--primary);
}

/* Match every blog's final conversion panel to the site-wide CTA design. */
.blog-cta {
    width: 100vw;
    max-width: none;
    margin-right: calc(50% - 50vw) !important;
    margin-left: calc(50% - 50vw) !important;
    min-height: 0;
    padding: clamp(2.75rem, 6vw, 4.5rem) 1.5rem !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: linear-gradient(135deg, #0d2949 0%, #071a31 100%) !important;
}

.blog-cta::before {
    top: -13rem;
    right: -8rem;
    width: 23rem;
    height: 23rem;
    border-radius: 50%;
    background: rgba(37, 99, 235, .09);
    box-shadow: none;
}

/* Do not constrain the final CTA to the article column. */
.blog-article .blog-cta {
    grid-column: 1 / -1;
}

.blog-cta h3 {
    font-size: clamp(1.7rem, 3vw, 2.25rem) !important;
    letter-spacing: -.03em;
}

.blog-cta .btn-ghost,
.blog-cta .btn-outline-white {
    border: 1px solid rgba(255,255,255,.48) !important;
    background: transparent !important;
    color: #fff !important;
}

.blog-cta .btn-ghost:hover,
.blog-cta .btn-outline-white:hover {
    border-color: #fff !important;
    background: rgba(255,255,255,.1) !important;
    color: #fff !important;
}

/* Keep the final full-width CTA flush with the footer. */
.blog-article {
    padding-bottom: 0;
}

/* Add the homepage-style orange call line to blog conversion panels. */

.blog-cta h3 {
    color: #ffffff;
}

/* Match the homepage hero surface: clean glow and fine dot texture, no rings. */
.blog-hero::before {
    display: none;
}

.blog-hero::after {
    opacity: .18;
    background-image: radial-gradient(rgba(255,255,255,.12) .75px, transparent .75px);
    background-size: 24px 24px;
    background-position: 0 0;
    mask-image: none;
}

/* Pipe-boot guide: no emergency/top strip before the site header. */
.pipe-boot-page > .emergency-bar,
.pipe-boot-page > .top-bar {
    display: none !important;
}
