@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800;900&family=Open+Sans:wght@300;400;500;600;700&display=swap');

/* ── CSS Variables ────────────────────────────────────────────────────────── */
:root {
    --primary:        #6783f2;
    --accent:         #6458f0;
    --accent-light:   #9d95f5;
    --cyan:           #00aeef;
    --dark-indigo:    #1e1b4b;
    --dark-section:   #141230;
    --bg:             #f1f1f1;
    --white:          #ffffff;
    --text-dark:      #2d2d2d;
    --text-medium:    #6b6b6b;
    --text-light:     #e0ddff;
    --border-light:   rgba(103,131,242,0.15);
    --shadow-card:    0 4px 24px rgba(100,88,240,0.12);
    --radius-card:    12px;
    --radius-btn:     40px;
}

/* ── Base Typography ──────────────────────────────────────────────────────── */
body,
.et_pb_text,
.et_pb_blurb_description,
p {
    font-family: 'Open Sans', sans-serif;
    color: var(--text-dark);
    line-height: 1.7;
}

h1, h2, h3, h4, h5, h6,
.et_pb_blurb_title,
.et_pb_slide_title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
}

/* ── Shared Section Headings ──────────────────────────────────────────────── */
.thfc-eyebrow {
    display: inline-block;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--cyan);
    margin-bottom: 12px;
}

.thfc-section-h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.75rem, 3.5vw, 2.5rem);
    font-weight: 800;
    line-height: 1.15;
    color: #ffffff;
    margin-bottom: 16px;
}

.thfc-section-h2.dark-text {
    color: var(--text-dark);
}

.thfc-section-subtitle {
    font-family: 'Open Sans', sans-serif;
    font-size: 1.05rem;
    color: var(--text-light);
    line-height: 1.65;
    margin-bottom: 0;
}
.thfc-stat-label.dark-text,
.thfc-section-subtitle.dark-text {
    color: var(--text-medium);
}

/* ── Hero ─────────────────────────────────────────────────────────────────── */
.thfc-hero-h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 900;
    line-height: 1.1;
    color: #ffffff;
    margin-bottom: 20px;
}

.thfc-hero-h1 .thfc-accent {
    color: var(--cyan);
}

.thfc-hero-sub {
    font-family: 'Open Sans', sans-serif;
    font-size: 1.1rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.65;
    max-width: 560px;
    margin: 0 auto 32px;
}

/* ── Buttons ──────────────────────────────────────────────────────────────── */
.thfc-btn-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
    margin-top: 8px;
}

.thfc-btn {
    display: inline-block;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-decoration: none;
    border-radius: var(--radius-btn);
    padding: 14px 28px;
    transition: transform 0.18s, box-shadow 0.18s, background 0.18s;
    cursor: pointer;
}

.thfc-btn:hover { transform: translateY(-2px); }

.thfc-btn-primary {
    background: var(--cyan);
    color: var(--bg) !important;
    box-shadow: 0 3px 12px rgba(110,220,245,0.18);
}

.thfc-btn-primary:hover {
    background: var(--primary);
    box-shadow: 0 5px 18px rgba(110,220,245,0.26);
}

.thfc-btn-outline {
    background: transparent;
    color: #ffffff !important;
    border: 2px solid rgba(255,255,255,0.5);
}

.thfc-btn-outline:hover {
    border-color: var(--cyan);
    color: var(--cyan) !important;
}

.thfc-btn-accent {
    background: var(--cyan);
    color: #ffffff !important;
    box-shadow: var(--shadow-card);
}

.thfc-btn-accent:hover {
    background: var(--primary);
    box-shadow: 0 6px 28px rgba(100,88,240,0.4);
}

/* Secondary — solid accent-light purple, used for secondary CTAs */
.thfc-btn-secondary {
    background: var(--cyan);
    color: #ffffff !important;
    box-shadow: 0 3px 12px rgba(157,149,245,0.18);
}

.thfc-btn-secondary:hover {
    background: var(--primary);
    box-shadow: 0 5px 18px rgba(157,149,245,0.26);
}

/* ── Trust Bar ────────────────────────────────────────────────────────────── */
.thfc-trust-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--border-light);
}

.thfc-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 18px 28px;
    border-right: 1px solid var(--border-light);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.thfc-trust-item:last-child { border-right: none; }

.thfc-trust-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    flex-shrink: 0;
}

/* ── Stat Cards ───────────────────────────────────────────────────────────── */
.thfc-stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin-top: 48px;
}

.thfc-stat-card {
    text-align: center;
    flex: 1;
    min-width: 140px;
}

.thfc-stat-num {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-size: 2.8rem;
    font-weight: 900;
    color: var(--cyan);
    line-height: 1;
}

.thfc-stat-label {
    display: block;
    font-family: 'Open Sans', sans-serif;
    font-size: 18px;
    color: rgba(255,255,255,0.7);
    margin-top: 6px;
    letter-spacing: 0.03em;
}

/* ── Step Cards (How It Works) ────────────────────────────────────────────── */
.thfc-step {
    text-align: center;
    padding: 32px 24px;
    background: #ffffff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    position: relative;
}

.thfc-step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 16px;
}

.thfc-step-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.thfc-step-body {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-medium);
    line-height: 1.65;
}

/* ── Location Cards ───────────────────────────────────────────────────────── */
.thfc-location-card {
    background: #ffffff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    padding: 36px 32px;
    border-top: 4px solid var(--primary);
    
}

.thfc-location-name {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 14px;
}

.thfc-location-detail {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-medium);
    margin-bottom: 10px;
    line-height: 1.5;
}

.thfc-location-detail .icon { color: var(--primary); flex-shrink: 0; margin-top: 2px; }
.thfc-location-detail a { color: var(--accent); text-decoration: none; }
.thfc-location-detail a:hover { text-decoration: underline; }

.thfc-hours-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 16px;
    font-family: 'Open Sans', sans-serif;
    font-size: 0.85rem;
    color: var(--text-medium);
    margin: 16px 0;
}

.thfc-hours-day { font-weight: 600; color: var(--text-dark); }

/* ── Equal-height card rows ──────────────────────────────────────────────── */
/* Columns become flex containers so all cards in a row match the tallest one.
   Extra space accumulates at the bottom of each card — content stays top-aligned. */
.et_pb_column {
    display: flex;
    flex-direction: column;
}

.et_pb_column > .et_pb_blurb,
.et_pb_column > .et_pb_code {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.et_pb_blurb > .et_pb_module_inner,
.et_pb_code > .et_pb_module_inner {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Blurb content area fills remaining height so text stays top, space at bottom */
.et_pb_blurb .et_pb_blurb_content {
    flex: 1;
}

/* Code module cards (location, step, doctor) fill the module height */
.et_pb_code .thfc-location-card,
.et_pb_code .thfc-step {
    flex: 1;
}

/* ── Blurb Overrides ──────────────────────────────────────────────────────── */
.et_pb_blurb .et_pb_main_blurb_image .et-pb-icon {
    color: var(--cyan) !important;
}

.et_pb_blurb_title {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
}

.et_pb_blurb_description {
    font-size: 0.88rem !important;
    line-height: 1.65 !important;
}

/* ── Divi Button Overrides ────────────────────────────────────────────────── */
.et_pb_button {
    font-family: 'Montserrat', sans-serif !important;
    border-radius: var(--radius-btn) !important;
}

/* ── Scroll Reveal ────────────────────────────────────────────────────────── */
.thfc-reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s cubic-bezier(.16,1,.3,1), transform 0.6s cubic-bezier(.16,1,.3,1);
}

.thfc-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Mobile CTA Bar ───────────────────────────────────────────────────────── */
.thfc-mobile-cta {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--dark-indigo);
    border-top: 2px solid var(--primary);
    padding: 10px 16px;
    gap: 10px;
}

.thfc-mcta-call,
.thfc-mcta-btn {
    flex: 1;
    text-align: center;
    padding: 12px 10px;
    border-radius: var(--radius-btn);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    text-decoration: none;
}

.thfc-mcta-call {
    background: rgba(255,255,255,0.08);
    color: #ffffff !important;
    border: 1px solid rgba(255,255,255,0.2);
}

.thfc-mcta-btn {
    background: var(--cyan);
    color: var(--white) !important;
}

/* ── Section background themes ────────────────────────────────────────────── */
/*
 * Usage: add css_class="thfc-bg-dark" (or -darker / -light / -white) to any
 * section in build_homepage.py. To flip a section between dark and light, only
 * the class name needs to change — no other styles are affected.
 *
 * [style*] selectors below are kept as a fallback for sections where the Divi
 * CSS class field is not available.
 */

/* Dark indigo — hero, who-we-help, locations */
.thfc-bg-dark,
.et_pb_section[style*="background-color: #1e1b4b"],
.et_pb_section[style*="background-color:#1e1b4b"] {
    background-color: #1e1b4b !important;
    background-image:
        radial-gradient(ellipse 60% 70% at 100% 0%,   rgba(110,220,245,.25) 0%, transparent 55%),
        radial-gradient(ellipse 40% 35% at 0%  100%,  rgba(103,131,242,.14) 0%, transparent 50%)
        !important;
}

/* Darker navy — how-it-works, CTA banner */
.thfc-bg-darker,
.et_pb_section[style*="background-color: #141230"],
.et_pb_section[style*="background-color:#141230"] {
    background-color: #141230 !important;
    background-image:
        radial-gradient(ellipse 55% 60% at 100% 0%,   rgba(110,220,245,.20) 0%, transparent 52%),
        radial-gradient(ellipse 35% 30% at 0%  100%,  rgba(100,88,240,.12)  0%, transparent 50%)
        !important;
}

/* Light grey (alt) — converted from dark navy #141230, matches the "Conditions We
 * Treat" section's light color scheme. Divi 5 doesn't render the section's
 * css_class attribute onto the frontend element (verified sitewide — none of
 * thfc-bg-dark/-darker/-light/-white appear as literal classes either), so this
 * class only affects background via the [style*] fallback below. Headings/
 * subtitles and card/icon/button colors inside these sections must be hand-set
 * per block: add " dark-text" to thfc-section-h2 / thfc-section-subtitle, same
 * as the Conditions We Treat section does. */
.thfc-bg-light-alt,
.et_pb_section[style*="background-color: #f1f1f1"],
.et_pb_section[style*="background-color:#f1f1f1"] {
    background-color: #f1f1f1 !important;
}

/* Light grey — services, doctors, attorney */
.thfc-bg-light {
    background-color: #f1f1f1 !important;
}

/* White — trust bar */
.thfc-bg-white {
    background-color: #ffffff !important;
}

/* ── Image Placeholders ────────────────────────────────────────────────────── */
.thfc-img-placeholder {
    background: rgba(103,131,242,0.06);
    border: 2px dashed rgba(103,131,242,0.22);
    border-radius: var(--radius-card);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    color: var(--accent-light);
    font-family: 'Open Sans', sans-serif;
    font-size: 0.82rem;
    gap: 10px;
    text-align: center;
    width: 100%;
    box-sizing: border-box;
}

.thfc-img-placeholder .fa {
    font-size: 2.4rem;
    opacity: 0.35;
}

/* Doctor photo placeholder — square-ish, sits above doctor bio */
.thfc-doctor-img-placeholder {
    min-height: 200px;
    margin-bottom: 20px;
    border-radius: 10px;
}

/* Hero image placeholder — taller, fills right column */
.thfc-hero-img-placeholder {
    min-height: 400px;
    border-radius: 16px;
}

/* Dark-background variant — swap indigo tones for cyan/white tones */
.thfc-bg-dark  .thfc-img-placeholder,
.thfc-bg-darker .thfc-img-placeholder {
    background: rgba(110,220,245,0.05);
    border-color: rgba(110,220,245,0.20);
    color: rgba(255,255,255,0.35);
}

/* ── Hero Background Image ────────────────────────────────────────────────── */
/* This class marks a section as "ready for a background photo."
   Add the photo via Divi Visual Builder → Section → Background → Image.
   The dark gradient from .thfc-bg-darker serves as the placeholder until a photo is loaded. */
.thfc-hero-bg-img {
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

/* ── Stat Blocks ──────────────────────────────────────────────────────────── */
.thfc-stat-row { display: flex; flex-wrap: wrap; gap: 0; justify-content: center; }
.thfc-stat-block {
    flex: 1 1 180px;
    text-align: center;
    padding: 28px 20px;
    border-right: 1px solid rgba(103,131,242,0.18);
}
.thfc-stat-block:last-child { border-right: none; }
.thfc-stat-value {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--cyan);
    line-height: 1;
    margin-bottom: 6px;
}
.thfc-stat-label {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.65);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.thfc-bg-light .thfc-stat-value,
.thfc-bg-white .thfc-stat-value { color: var(--accent); }
.thfc-bg-light .thfc-stat-label,
.thfc-bg-white .thfc-stat-label { color: var(--text-medium); }
.thfc-bg-light .thfc-stat-block,
.thfc-bg-white .thfc-stat-block { border-color: rgba(103,131,242,0.15); }

/* ── FAQ Items ────────────────────────────────────────────────────────────── */
.thfc-faq-list { max-width: 820px; margin: 0 auto; }
.thfc-faq-item { border-bottom: 1px solid rgba(103,131,242,0.88); padding: 22px 0; }
.thfc-faq-item:first-child { border-top: 1px solid rgba(103,131,242,0.88); }
.thfc-faq-q {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
    line-height: 1.4;
}
.thfc-faq-a {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.92rem;
    color: var(--text-dark);
    line-height: 1.75;
}
.thfc-bg-light .thfc-faq-item,
.thfc-bg-white .thfc-faq-item { border-color: rgba(103,131,242,0.15); }
.thfc-bg-light .thfc-faq-q,
.thfc-bg-white .thfc-faq-q { color: var(--text-dark); }
.thfc-bg-light .thfc-faq-a,
.thfc-bg-white .thfc-faq-a { color: var(--text-medium); }

/* ── Timeline Steps ───────────────────────────────────────────────────────── */
.thfc-timeline { display: flex; flex-direction: column; }
.thfc-timeline-step {
    display: flex;
    gap: 24px;
    padding: 28px 0;
    border-bottom: 1px solid rgba(110,220,245,0.12);
}
.thfc-timeline-step:last-child { border-bottom: none; }
.thfc-timeline-num {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(103,131,242,0.35);
}
.thfc-timeline-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: #2d2d2d;
    margin-bottom: 6px;
}
.thfc-timeline-title.light-text {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 6px;
}
.thfc-timeline-desc {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-medium);
    line-height: 1.7;
}
.thfc-timeline-desc.light-text {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.7;
}
.thfc-bg-light .thfc-timeline-step,
.thfc-bg-white .thfc-timeline-step { border-color: rgba(103,131,242,0.12); }
.thfc-bg-light .thfc-timeline-title,
.thfc-bg-white .thfc-timeline-title { color: var(--text-dark); }
.thfc-bg-light .thfc-timeline-desc,
.thfc-bg-white .thfc-timeline-desc  { color: var(--text-medium); }

/* ── Testimonial Cards ────────────────────────────────────────────────────── */
.thfc-testimonial {
    background: var(--accent);
    border: 1px solid rgba(110,220,245,0.14);
    border-radius: var(--radius-card);
    padding: 28px 24px;
    
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}
.thfc-testimonial-quote {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.95rem;
    color: rgba(255,255,255,0.80);
    line-height: 1.75;
    margin-bottom: 20px;
    font-style: italic;
    flex: 1 1 auto;
}
.thfc-testimonial-author {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--cyan);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.thfc-testimonial-stars {
    margin-bottom: 14px;
    color: #ffb400;
    font-size: 1.05rem;
    letter-spacing: 3px;
    line-height: 1;
}

.thfc-testimonial-carousel {
    overflow: hidden;
}
.thfc-testimonial-track {
    display: flex;
    align-items: stretch;
    gap: 24px;
    will-change: transform;
}
.thfc-testimonial-track .thfc-testimonial {
    flex: 0 0 calc((100% - 48px) / 3);
    box-sizing: border-box;
}

/* ── Photo Grid ───────────────────────────────────────────────────────────── */
.thfc-photo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}
.thfc-photo-grid .thfc-img-placeholder { min-height: 160px; }

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 980px) {
    .thfc-trust-bar { flex-direction: column; }
    .thfc-trust-item { border-right: none; border-bottom: 1px solid var(--border-light); justify-content: center; }
    .thfc-stats-row { gap: 12px; }

    .thfc-testimonial-track .thfc-testimonial { flex-basis: calc((100% - 24px) / 2); }
    .ddc-btn-wrapper.ddc-btn--loaded {margin-bottom: 12% !important;}
}

@media (max-width: 767px) {
    .thfc-mobile-cta { display: flex; }
    body { padding-bottom: 70px; }

    .thfc-btn-wrap { flex-direction: column; align-items: center; }
    .thfc-btn { width: 100%; max-width: 320px; text-align: center; margin-bottom: 12px; margin-right: 0px !important;}

    .thfc-trust-bar { display: none; }

    .thfc-hours-grid { font-size: 0.82rem; }

    .thfc-stat-block { border-right: none; border-bottom: 1px solid rgba(103,131,242,0.15); }
    .thfc-stat-block:last-child { border-bottom: none; }

    .thfc-timeline-step { flex-direction: column; gap: 12px; }

    .thfc-photo-grid { grid-template-columns: repeat(2, 1fr); }

    .thfc-testimonial-track .thfc-testimonial { flex-basis: 100%; }
}

/* ── Accessibility ────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
    }
}

/* ── Divi Global Overrides ────────────────────────────────────────────────── */
.et_pb_section { padding: 80px 0; }
.et_pb_row { max-width: 1200px; }

@media (max-width: 767px) {
    .et_pb_section { padding: 40px 0; }
}

/* Remove default Divi sidebar */
.et_right_sidebar #main-content .container { padding-right: 0; }

.et-menu a:hover{
    opacity: 1 !important;
    color: #00aeef !important;
}

.et_flex_row .et_pb_code,
.et_flex_row .et_pb_code .et_pb_module_inner {
    height: 100%;
}
/* ── Ninja Forms ──────────────────────────────────────────────────────────── */

/* Form card wrapper */
.nf-form-cont {
    background: #ffffff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    padding: 40px 36px;
    border-top: 4px solid var(--primary);
}

/* Clear default NF background */
.nf-form-layout,
.nf-form-layout-div {
    background: transparent !important;
}

/* "* Required fields" note */
.nf-form-fields-required {
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.78rem !important;
    color: var(--text-medium) !important;
    margin-bottom: 22px !important;
}

/* Field spacing */
.nf-field-container {
    margin-bottom: 20px !important;
}

/* Labels */
.nf-field-label label,
.nf-label-span {
    display: block !important;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.1em !important;
    text-transform: uppercase !important;
    color: var(--text-dark) !important;
    margin-bottom: 7px !important;
}

/* Required asterisk */
.ninja-forms-req-symbol {
    color: var(--accent) !important;
    margin-left: 3px !important;
}

/* All text inputs, textarea, select */
.nf-field-element input[type="text"],
.nf-field-element input[type="email"],
.nf-field-element input[type="tel"],
.nf-field-element input[type="number"],
.nf-field-element input[type="date"],
.nf-field-element textarea.ninja-forms-field,
.nf-field-element select.ninja-forms-field {
    width: 100% !important;
    background: #ffffff !important;
    border: 1.5px solid rgba(103,131,242,0.25) !important;
    border-radius: 8px !important;
    padding: 13px 16px !important;
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.95rem !important;
    color: var(--text-dark) !important;
    line-height: 1.5 !important;
    box-sizing: border-box !important;
    box-shadow: none !important;
    outline: none !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}

/* Focus ring */
.nf-field-element input[type="text"]:focus,
.nf-field-element input[type="email"]:focus,
.nf-field-element input[type="tel"]:focus,
.nf-field-element input[type="number"]:focus,
.nf-field-element input[type="date"]:focus,
.nf-field-element textarea.ninja-forms-field:focus,
.nf-field-element select.ninja-forms-field:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px rgba(103,131,242,0.12) !important;
}

/* Textarea height */
.nf-field-element textarea.ninja-forms-field {
    min-height: 140px !important;
    resize: vertical !important;
}

/* Select — custom chevron arrow */
.nf-field-element select.ninja-forms-field {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236783f2' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    padding-right: 42px !important;
}

/* Submit button */
.nf-field-element input[type="button"].ninja-forms-field,
.nf-field-element input[type="submit"].ninja-forms-field,
.submit-container .nf-field-element input {
    width: 100% !important;
    background: var(--accent) !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: var(--radius-btn) !important;
    padding: 15px 28px !important;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.04em !important;
    cursor: pointer !important;
    box-shadow: 0 4px 18px rgba(100,88,240,0.22) !important;
    transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease !important;
    margin-top: 8px !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}

.nf-field-element input[type="button"].ninja-forms-field:hover,
.nf-field-element input[type="submit"].ninja-forms-field:hover,
.submit-container .nf-field-element input:hover {
    background: var(--primary) !important;
    box-shadow: 0 6px 28px rgba(100,88,240,0.38) !important;
    transform: translateY(-1px) !important;
}

/* Error — field border + ring */
.nf-field-container.nf-error .nf-field-element input,
.nf-field-container.nf-error .nf-field-element textarea,
.nf-field-container.nf-error .nf-field-element select {
    border-color: #e53e3e !important;
    box-shadow: 0 0 0 3px rgba(229,62,62,0.10) !important;
}

/* Error message text */
.nf-error-msg,
.nf-errors li {
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.78rem !important;
    color: #e53e3e !important;
    margin-top: 5px !important;
    list-style: none !important;
    padding: 0 !important;
}

/* Success / response message */
.nf-response-msg {
    background: rgba(103,131,242,0.06) !important;
    border-left: 4px solid var(--primary) !important;
    border-radius: 0 8px 8px 0 !important;
    padding: 18px 20px !important;
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.95rem !important;
    color: var(--text-dark) !important;
    line-height: 1.6 !important;
    margin-top: 16px !important;
}

/* Responsive: collapse padding on mobile */
@media (max-width: 767px) {
    .nf-form-cont { padding: 28px 20px; }
}

/* ── Single Blog Post — Full-Width Sections ───────────────────────────────── */
/*
 * Pages get et_full_width_page on <body> which removes the .container
 * constraints automatically. Single posts don't — so we strip them here.
 * .et_pb_row { max-width: 1200px } (set above) keeps content contained.
 */
.single-post #main-content .container,
.single-post #content-area,
.single-post #left-area,
.single-post .et_pb_post,
.single-post .entry-content {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    float: none !important;
}

/* ── Blog Post Layout ─────────────────────────────────────────────────────── */

/* Hide duplicate WP post title on single posts only */
.single-post .et_pb_post .et_post_meta_wrapper { display: none !important; }

/* Hero — left-aligned 2-col layout */
.thfc-blog-hero--left {
    text-align: left;
    padding-right: 48px;
}

/* Hero image (right column in dark section) */
.thfc-blog-hero-img {
    width: 100%;
    display: block;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.45);
    object-fit: cover;
    max-height: 440px;
}

/* Category badge */
.thfc-blog-cat-badge {
    display: inline-block;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.68rem;
    font-weight: 700 !important;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--cyan) !important;
    background: rgba(110,220,245,0.12);
    border: 1px solid rgba(110,220,245,0.30);
    border-radius: 100px;
    padding: 5px 14px;
    margin-bottom: 20px;
}

/* Blog H1 */
.thfc-blog-h1 {
    font-family: 'Montserrat', sans-serif !important;
    font-size: clamp(1.9rem, 4.5vw, 3rem) !important;
    font-weight: 900 !important;
    line-height: 1.12 !important;
    color: #ffffff !important;
    margin-bottom: 18px !important;
}

/* Byline */
.thfc-blog-byline {
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.88rem !important;
    color: rgba(255,255,255,0.62) !important;
    margin: 0 0 8px !important;
}

/* Hero CTA buttons row */
.thfc-blog-hero-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

/* Article body */
.thfc-blog-body {
    max-width: 760px;
    margin: 0 auto;
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    color: var(--text-dark);
    line-height: 1.8;
}

.thfc-blog-body h2 {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 1.45rem !important;
    font-weight: 800 !important;
    color: var(--dark-indigo) !important;
    margin: 2.2em 0 0.6em !important;
    line-height: 1.25 !important;
}

.thfc-blog-body h3 {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    color: var(--accent) !important;
    margin: 1.8em 0 0.5em !important;
}

.thfc-blog-body p { margin-bottom: 1.2em; }

.thfc-blog-body ul,
.thfc-blog-body ol { padding-left: 1.5em; margin-bottom: 1.2em; }

.thfc-blog-body li { margin-bottom: 0.5em; line-height: 1.7; }

.thfc-blog-body strong { font-weight: 700; color: var(--text-dark); }

.thfc-blog-body a { color: var(--accent); text-decoration: none; }
.thfc-blog-body a:hover { text-decoration: underline; }

/* CTA box */
.thfc-blog-cta-box {
    text-align: center;
    max-width: 680px;
    margin: 0 auto;
}

.thfc-blog-cta-box h2 {
    font-family: 'Montserrat', sans-serif !important;
    font-size: clamp(1.5rem, 3vw, 2rem) !important;
    font-weight: 900 !important;
    color: #ffffff !important;
    margin-bottom: 14px !important;
    line-height: 1.2 !important;
}

.thfc-blog-cta-box p {
    font-family: 'Open Sans', sans-serif !important;
    font-size: 1rem !important;
    color: rgba(255,255,255,0.85) !important;
    line-height: 1.65 !important;
    margin-bottom: 28px !important;
}

.thfc-blog-cta-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
}

/* Blog CTA button variants */
.thfc-btn-white {
    background: #ffffff !important;
    color: var(--accent) !important;
    box-shadow: 0 3px 14px rgba(0,0,0,0.12);
}
.thfc-btn-white:hover {
    background: #f0eeff !important;
    box-shadow: 0 5px 20px rgba(0,0,0,0.16);
}

.thfc-btn-outline-white {
    background: transparent !important;
    color: #ffffff !important;
    border: 2px solid rgba(255,255,255,0.55) !important;
}
.thfc-btn-outline-white:hover {
    border-color: #ffffff !important;
    background: rgba(255,255,255,0.08) !important;
}

/* Blog post responsive */
@media (max-width: 980px) {
    .thfc-blog-hero--left { padding-right: 28px; }
}

@media (max-width: 767px) {
    .thfc-blog-hero, .thfc-blog-cta-box, .thfc-blog-body {padding-left: 5%; padding-right: 5%;}
    .thfc-blog-hero--left { padding-right: 0; }
    .thfc-blog-hero-img { max-height: 260px; margin-top: 28px; width:90%; margin:auto;}
    .thfc-blog-hero-btns { flex-direction: column; }
    .thfc-blog-hero-btns .thfc-btn { width: 100%; max-width: 280px; text-align: center; }
    .thfc-blog-cta-btns { flex-direction: column; align-items: center; }
    .thfc-blog-cta-btns .thfc-btn { width: 100%; max-width: 320px; text-align: center; }
    
}

/* ── Blog Listing Page Grid ────────────────────────────────────────────────── */
/* Applies to the /blog/ archive page (body.blog) */

.blog #left-area,
.archive #left-area {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    padding: 0 !important;
    width: 100% !important;
    max-width: 1200px !important;
    margin: 0 auto !important;
    box-sizing: border-box;
}

/* Card */
.blog .et_pb_post,
.archive .et_pb_post {
    background: #ffffff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    display: flex !important;
    flex-direction: column;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    margin: 0 !important;
}

.blog .et_pb_post:hover,
.archive .et_pb_post:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(100,88,240,0.18);
}

/* Featured image */
.blog .entry-featured-image-url,
.archive .entry-featured-image-url {
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    flex-shrink: 0;
}

.blog .entry-featured-image-url img,
.archive .entry-featured-image-url img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.blog .et_pb_post:hover .entry-featured-image-url img,
.archive .et_pb_post:hover .entry-featured-image-url img {
    transform: scale(1.04);
}

/* Card content area */
.blog .et_post_meta_wrapper,
.archive .et_post_meta_wrapper {
    padding: 20px 22px 22px !important;
    display: flex !important;
    flex-direction: column;
    flex: 1;
}

/* Category label (Divi outputs this) — this template variant never wraps
   the title/meta in .et_post_meta_wrapper (that rule above ends up unused),
   so title and meta sit directly in the card and need their own side
   padding, or they run edge-to-edge against the rounded card corners. */
.blog .et_pb_post .post-meta,
.archive .et_pb_post .post-meta {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.12em !important;
    text-transform: uppercase !important;
    color: var(--accent) !important;
    margin-bottom: 8px !important;
    padding: 0 22px 22px !important;
}

/* Post title */
.blog .entry-title,
.archive .entry-title {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    margin-bottom: 10px !important;
    padding: 20px 22px 0 !important;
}

.blog .entry-title a,
.archive .entry-title a {
    color: var(--dark-indigo) !important;
    text-decoration: none !important;
}

.blog .entry-title a:hover,
.archive .entry-title a:hover {
    color: var(--accent) !important;
}

/* Excerpt */
.blog .post-content p,
.archive .post-content p {
    font-family: 'Open Sans', sans-serif !important;
    font-size: 0.875rem !important;
    color: var(--text-medium) !important;
    line-height: 1.65 !important;
    margin-bottom: 14px !important;
}

/* Read more link */
.blog .more-link,
.archive .more-link {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.78rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.06em !important;
    text-transform: uppercase !important;
    color: var(--accent) !important;
    text-decoration: none !important;
    margin-top: auto;
    display: inline-block;
}

.blog .more-link:hover,
.archive .more-link:hover {
    color: var(--primary) !important;
}

/* Pagination — DOM stays after the post loop (semantic/SEO order), but
   visually moved to the top of the grid via `order` since a page selector
   is more useful above the cards than buried below them */
.blog .pagination,
.archive .pagination {
    grid-column: 1 / -1;
    order: -1;
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 0 0 20px;
}

/* ── Blog sidebar (search / recent posts) ─────────────────────────────────
   Divi's default template floats #sidebar beside #left-area, but #left-area
   is forced to width:100% for the card grid above, leaving #sidebar no room
   to sit beside it. Reflowed as a horizontal utility bar below the grid
   instead, and Divi's leftover #main-content .container column-divider
   (meant to sit between the old content/sidebar columns) is dropped since
   it no longer maps to anything and was rendering as a stray line through
   the card grid. */
.blog #main-content .container::before,
.archive #main-content .container::before {
    display: none !important;
}

.blog #content-area,
.archive #content-area {
    display: flex;
    flex-direction: column;
}

.blog #sidebar,
.archive #sidebar {
    float: none !important;
    width: 100% !important;
    max-width: 1200px;
    margin: 32px auto 0 !important;
    padding: 24px 28px !important;
    box-sizing: border-box;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 40px;
    background: #ffffff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    border: none !important;
}

.blog #sidebar .et_pb_widget,
.archive #sidebar .et_pb_widget {
    float: none !important;
    width: auto !important;
    margin: 0 !important;
    flex: 1 1 260px;
}

/* Empty by default on this site (comments aren't used) — pure clutter */
.blog #sidebar #block-4,
.archive #sidebar #block-4 {
    display: none;
}

.blog #sidebar .wp-block-heading,
.archive #sidebar .wp-block-heading {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--dark-indigo);
    margin-bottom: 10px;
}

.blog #sidebar .wp-block-search__inside-wrapper,
.archive #sidebar .wp-block-search__inside-wrapper {
    display: flex;
}

.blog #sidebar .wp-block-search__input,
.archive #sidebar .wp-block-search__input {
    font-family: 'Open Sans', sans-serif;
    border: 1px solid #ddd;
    border-radius: 6px 0 0 6px;
    padding: 10px 14px;
    min-width: 180px;
}

.blog #sidebar .wp-block-search__button,
.archive #sidebar .wp-block-search__button {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 0 6px 6px 0;
    padding: 10px 18px;
    font-weight: 700;
    cursor: pointer;
}

.blog #sidebar .wp-block-latest-posts__list,
.archive #sidebar .wp-block-latest-posts__list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 24px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.blog #sidebar .wp-block-latest-posts__list a,
.archive #sidebar .wp-block-latest-posts__list a {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.85rem;
    color: var(--text-medium);
    text-decoration: none;
}

.blog #sidebar .wp-block-latest-posts__list a:hover,
.archive #sidebar .wp-block-latest-posts__list a:hover {
    color: var(--accent);
}

/* Blog listing page wrapper padding */
.blog #main-content,
.archive #main-content {
    padding: 60px 30px;
    max-width: 1260px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* Responsive grid */
@media (max-width: 980px) {
    .blog #left-area,
    .archive #left-area { grid-template-columns: repeat(2, 1fr); gap: 20px; }
}

@media (max-width: 600px) {
    .blog #left-area,
    .archive #left-area { grid-template-columns: 1fr; gap: 16px; }
    .blog #main-content,
    .archive #main-content { padding: 40px 16px; }
}
