/* ==========================================================================
   Engage360 Connect — Frontend Consumer Pages
   Self-contained; served via our own page template (templates/page-e360c.php)
   so Divi/theme styles never interfere.
   Matches central advisor-preview.css design tokens exactly.
   Primary: #00466d  |  Mid: #006a91  |  Accent: #66bb6a
   ========================================================================== */

/* ── CSS Variables ───────────────────────────────────────────────────────── */
:root {
    --e-primary:    #00466d;
    --e-mid:        #006a91;
    --e-accent:     var(--e-secondary, #0ea5e9);
    --e-accent-h:   var(--e-mid, #0284c7);
    --e-border:     #e2e8f0;
    --e-bg:         #f4f7fa;
    --e-card:       #ffffff;
    --e-text:       #1a2332;
    --e-muted:      #64748b;
    --e-radius:     10px;
    --e-shadow:     0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
    --e-shadow-md:  0 4px 12px rgba(0,0,0,.08);
}

/* ── Content wrapper — isolates all shortcode output ─────────────────────── */
/* 'all: revert' is intentionally NOT used here since we want theme header/footer.
   Instead we reset only the properties that commonly bleed in from Divi/themes. */
.e360c-wrap,
.e360c-advisor-section {
    max-width: 760px;
    margin: 0 auto;
    padding: 40px 24px 60px;
    color: var(--e-text);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    /* Reset common theme bleeds */
    background: transparent;
    border: none;
    box-shadow: none;
}
.e360c-index-wrap {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 24px 60px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}
.e360c-hub-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 24px 60px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 28px;
}
.e360c-wrap *,
.e360c-advisor-section *,
.e360c-index-wrap *,
.e360c-hub-wrap * {
    box-sizing: border-box;
    font-family: inherit;
}

/* Neutralize Divi's opinionated paragraph/heading margins inside our content */
.e360c-wrap p,
.e360c-advisor-section p { margin: 0 0 14px; padding: 0; }
.e360c-wrap h1,
.e360c-wrap h2,
.e360c-wrap h3 { padding: 0; }

/* ── Type Badges ─────────────────────────────────────────────────────────── */
.e360c-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .6px;
    text-transform: uppercase;
    margin-bottom: 18px;
    line-height: 1;
}
.e360c-badge--guide       { background: var(--e-secondary-tint, #e0f2fe); color: var(--e-secondary, #0ea5e9); }
.e360c-badge--blog        { background: var(--e-secondary-tint, #e0f2fe); color: var(--e-secondary, #0ea5e9); }
.e360c-badge--video       { background: #fce7f3; color: #9d174d; }
.e360c-badge--quiz        { background: #fef9c3; color: #854d0e; }
.e360c-badge--newsletter  { background: #e0f2fe; color: #0369a1; }

/* ── Content Typography ──────────────────────────────────────────────────── */
.e360c-title {
    font-size: clamp(26px, 4vw, 38px);
    font-weight: 800;
    color: var(--e-text);
    line-height: 1.2;
    margin: 0 0 16px;
    letter-spacing: -.5px;
}
.e360c-excerpt {
    font-size: 17px;
    color: var(--e-muted);
    line-height: 1.65;
    margin: 0 0 28px;
}
.e360c-body {
    font-size: 16px;
    line-height: 1.75;
    color: var(--e-text);
    margin-bottom: 32px;
}
.e360c-body p  { margin: 0 0 16px; }
.e360c-body h2 { font-size: 22px; font-weight: 700; color: var(--e-text); margin: 28px 0 12px; }
.e360c-body h3 { font-size: 18px; font-weight: 700; color: var(--e-text); margin: 22px 0 10px; }
.e360c-body ul, .e360c-body ol { padding-left: 24px; margin-bottom: 16px; }
.e360c-body li { margin-bottom: 6px; }
.e360c-body a  { color: var(--e-mid); text-decoration: underline; }

/* ── Cover Image ─────────────────────────────────────────────────────────── */
.e360c-cover { text-align: center; margin: 0 0 32px; }
.e360c-cover img {
    max-width: 280px;
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 8px 28px rgba(0,70,109,.18);
    display: inline-block;
}

/* ── Blog Article ────────────────────────────────────────────────────────── */
.e360c-blog-article { max-width: 780px; }
.e360c-article-meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: var(--e-muted);
    margin: 0 0 28px;
    flex-wrap: wrap;
    align-items: center;
}
.e360c-article-hero {
    margin: 0 0 36px;
    border-radius: 12px;
    overflow: hidden;
    max-height: 420px;
}
.e360c-article-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/* Body within blog article — inherits e360c-body but with slightly looser spacing */
.e360c-blog-article .e360c-body { font-size: 17px; line-height: 1.85; }
.e360c-blog-article .e360c-body h2 { font-size: 24px; margin: 40px 0 16px; }
.e360c-blog-article .e360c-body h3 { font-size: 20px; margin: 32px 0 12px; }
.e360c-blog-article .e360c-body img { max-width: 100%; border-radius: 10px; margin: 24px 0; display: block; }
.e360c-blog-article .e360c-body blockquote {
    border-left: 4px solid var(--e-secondary, #0ea5e9);
    margin: 28px 0;
    padding: 12px 24px;
    color: var(--e-muted);
    font-style: italic;
    background: var(--e-secondary-tint, #f0f9ff);
    border-radius: 0 8px 8px 0;
}


.e360c-bullets-heading {
    font-size: 20px;
    font-weight: 700;
    color: var(--e-text);
    margin: 0 0 14px;
}
.e360c-bullets {
    list-style: none;
    padding: 0;
    margin: 0 0 32px;
}
.e360c-bullets li {
    position: relative;
    padding: 13px 16px 13px 48px;
    margin-bottom: 8px;
    background: var(--e-card);
    border: 1px solid var(--e-border);
    border-left: 4px solid var(--e-accent);
    border-radius: 8px;
    font-size: 15px;
    line-height: 1.5;
    color: var(--e-text);
}
.e360c-bullets li::before {
    content: '✓';
    position: absolute;
    left: 16px;
    top: 13px;
    color: var(--e-accent);
    font-weight: 800;
    font-size: 16px;
}

/* ── Guidebook Lead-gate Form Box ────────────────────────────────────────── */
.e360c-form-box {
    background: var(--e-card);
    border: 1px solid var(--e-border);
    border-radius: var(--e-radius);
    padding: 28px;
    box-shadow: var(--e-shadow-md);
    margin-bottom: 32px;
}
.e360c-form-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--e-text);
    margin: 0 0 18px;
    text-align: center;
}

/* ── Lead Form ───────────────────────────────────────────────────────────── */
.e360c-lead-form { width: 100%; }
.e360c-lead-form .e360c-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 16px;
}
.e360c-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 16px;
}
.e360c-lead-form .e360c-form-row .e360c-form-group { margin-bottom: 0; }
.e360c-form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--e-text);
    display: block;
    margin: 0;
}
.e360c-form-group .req { color: #e53e3e; }
.e360c-form-group input,
.e360c-form-group textarea,
.e360c-form-group select {
    padding: 11px 14px;
    border: 1.5px solid var(--e-border);
    border-radius: 8px;
    font-size: 15px;
    background: #fff;
    color: var(--e-text);
    width: 100%;
    font-family: inherit;
    box-shadow: none;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    transition: border-color .15s, box-shadow .15s;
}
.e360c-form-group input:focus,
.e360c-form-group textarea:focus {
    border-color: var(--e-mid);
    box-shadow: 0 0 0 3px rgba(0,106,145,.1);
}
.e360c-form-group textarea { min-height: 90px; resize: vertical; }
.e360c-form-submit-row {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin-top: 8px;
}
.e360c-submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--e-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s;
    letter-spacing: .3px;
    text-transform: uppercase;
    font-family: inherit;
}
.e360c-submit-btn:hover    { background: var(--e-mid); }
.e360c-submit-btn:disabled { opacity: .6; cursor: not-allowed; }
.e360c-privacy {
    font-size: 12px;
    color: var(--e-muted);
    margin: 0;
    text-align: center;
}
.e360c-form-success {
    padding: 12px 16px;
    background: #dcfce7;
    color: #166534;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    margin-top: 12px;
}
.e360c-form-error {
    padding: 12px 16px;
    background: #fee2e2;
    color: #991b1b;
    border-radius: 8px;
    font-size: 14px;
    margin-top: 12px;
}

/* ── Confirm / Download ──────────────────────────────────────────────────── */
.e360c-confirm { text-align: center; padding: 40px 20px; }
.e360c-confirm-icon  { font-size: 56px; margin-bottom: 14px; line-height: 1; display: block; }
.e360c-confirm-title { font-size: 30px; font-weight: 800; color: var(--e-primary); margin: 0 0 10px; }
.e360c-confirm-body  { font-size: 16px; color: var(--e-muted); margin: 0 0 22px; }
.e360c-confirm-cover { max-width: 200px; border-radius: 8px; box-shadow: var(--e-shadow-md); margin: 0 auto 22px; display: block; }
.e360c-dl-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 30px;
    background: var(--e-accent);
    color: #fff;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    margin-bottom: 12px;
    transition: background .15s;
}
.e360c-dl-btn:hover { background: var(--e-accent-h); color: #fff; }
.e360c-confirm-note { font-size: 13px; color: var(--e-muted); }

/* ── Video ───────────────────────────────────────────────────────────────── */
.e360c-video-wrap .e360c-title { margin-top: 12px; }
.e360c-video-container {
    margin: 0 0 28px;
    border-radius: var(--e-radius);
    overflow: hidden;
    box-shadow: var(--e-shadow-md);
}
.e360c-video-embed {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    background: #000;
}
.e360c-video-embed iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: none;
}

/* ── Quiz ────────────────────────────────────────────────────────────────── */
.e360c-quiz-intro { max-width: 600px; margin: 0 auto; text-align: center; }
.e360c-quiz-meta  { font-size: 14px; color: var(--e-muted); margin: 0 0 24px; }
.e360c-quiz-start-btn {
    display: inline-flex;
    padding: 14px 36px;
    background: var(--e-accent);
    color: #fff;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: background .15s;
}
.e360c-quiz-start-btn:hover { background: var(--e-accent-h); color: #fff; }
.e360c-progress { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; }
.e360c-progress-bar  { flex: 1; height: 6px; background: var(--e-border); border-radius: 4px; overflow: hidden; }
.e360c-progress-fill { height: 100%; background: var(--e-accent); border-radius: 4px; transition: width .3s; }
.e360c-progress-lbl  { font-size: 12px; font-weight: 600; color: var(--e-muted); white-space: nowrap; }
.e360c-q-text { font-size: 20px; font-weight: 700; color: var(--e-text); line-height: 1.4; margin-bottom: 20px; }
.e360c-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.e360c-opt {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: var(--e-card);
    border: 2px solid var(--e-border);
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    transition: all .15s;
    color: var(--e-text);
    text-align: left;
}
.e360c-opt:hover { border-color: var(--e-mid); background: #f0f9ff; }
.e360c-opt.sel   { border-color: var(--e-accent); background: var(--e-secondary-tint, #f0f9ff); font-weight: 600; }
.e360c-opt-letter {
    width: 30px; height: 30px;
    border-radius: 50%;
    background: var(--e-bg);
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 800;
    color: var(--e-primary);
    flex-shrink: 0;
}
.e360c-opt.sel .e360c-opt-letter { background: var(--e-accent); color: #fff; }
.e360c-quiz-nav { display: flex; justify-content: space-between; gap: 12px; }
.e360c-quiz-back-btn,
.e360c-quiz-next-btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all .15s;
    font-family: inherit;
}
.e360c-quiz-back-btn { background: var(--e-card); border-color: var(--e-border); color: var(--e-muted); }
.e360c-quiz-back-btn:hover { border-color: var(--e-mid); color: var(--e-primary); }
.e360c-quiz-next-btn { background: var(--e-accent); color: #fff; border-color: var(--e-accent); }
.e360c-quiz-next-btn:hover { background: var(--e-accent-h); }
.e360c-score-circle {
    width: 90px; height: 90px;
    border-radius: 50%;
    background: var(--e-primary);
    color: #fff;
    font-size: 30px; font-weight: 900;
    display: inline-flex; align-items: center; justify-content: center;
    margin-bottom: 18px;
}
.e360c-band-title { font-size: 28px; font-weight: 800; color: var(--e-primary); margin: 0 0 10px; }
.e360c-band-body  { font-size: 15px; color: var(--e-muted); line-height: 1.65; max-width: 520px; margin: 0 auto 28px; }

/* ── Advisor Section ─────────────────────────────────────────────────────── */
.e360c-advisor-section {
    border-top: 2px solid var(--e-border);
    padding-top: 36px;
    margin-top: 48px;
    padding-bottom: 0;
}

/* Advisor Card */
.e360c-advisor-card {
    background: var(--e-card);
    border: 1px solid var(--e-border);
    border-radius: var(--e-radius);
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: var(--e-shadow);
}
.e360c-advisor-header {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    padding: 22px 24px;
}
.e360c-advisor-headshot {
    width: 72px; height: 72px;
    min-width: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--e-border);
    flex-shrink: 0;
    display: block;
}
.e360c-advisor-info { flex: 1; min-width: 0; }
.e360c-advisor-logo {
    max-height: 36px;
    max-width: 150px;
    width: auto;
    object-fit: contain;
    margin-bottom: 8px;
    display: block;
}
.e360c-advisor-name  { display: block; font-size: 18px; font-weight: 700; color: var(--e-text); margin: 0 0 2px; }
.e360c-advisor-title { display: block; font-size: 13px; color: var(--e-text); margin-top: 2px; }
.e360c-advisor-firm  { display: block; font-size: 13px; color: var(--e-muted); margin-top: 2px; }
.e360c-advisor-contact { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 10px; }
.e360c-contact-link { font-size: 13px; color: var(--e-primary); text-decoration: none; font-weight: 500; }
.e360c-contact-link:hover { text-decoration: underline; }
.e360c-advisor-bio {
    padding: 16px 24px;
    font-size: 14px;
    color: var(--e-muted);
    line-height: 1.65;
    border-top: 1px solid var(--e-border);
}

/* Contact Form Box */
.e360c-contact-form-box {
    background: var(--e-card);
    border: 1px solid var(--e-border);
    border-radius: var(--e-radius);
    padding: 28px 26px;
    box-shadow: var(--e-shadow);
}
.e360c-contact-form-title {
    font-size: 22px;
    font-weight: 800;
    color: var(--e-text);
    margin: 0 0 6px;
}
.e360c-contact-form-sub { font-size: 14px; color: var(--e-muted); margin: 0 0 22px; }

/* ── Index page grid (matches card design in central) ────────────────────── */
.e360c-index-wrap { padding-top: 32px; padding-bottom: 48px; }
.e360c-index-empty { text-align: center; padding: 64px 24px; color: var(--e-muted); }
.e360c-index-empty-icon { font-size: 48px; display: block; margin-bottom: 16px; }
.e360c-index-empty p { font-size: 16px; margin: 0; }

.e360c-index-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}
.e360c-index-card {
    background: var(--e-card);
    border: 1px solid var(--e-border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--e-shadow);
    display: flex;
    flex-direction: column;
    transition: box-shadow .2s, transform .2s;
}
.e360c-index-card:hover {
    box-shadow: var(--e-shadow-md);
    transform: translateY(-2px);
}
.e360c-index-card-img-wrap { display: block; overflow: hidden; aspect-ratio: 16/9; }
.e360c-index-card-img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; display: block; }
.e360c-index-card:hover .e360c-index-card-img { transform: scale(1.03); }
.e360c-index-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.e360c-index-card-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.e360c-index-card-date,
.e360c-index-card-readtime { font-size: 12px; color: #94a3b8; font-weight: 500; }
.e360c-index-card-title { font-size: 18px; font-weight: 800; color: var(--e-text); line-height: 1.35; margin: 0 0 10px; }
.e360c-index-card-title a { color: inherit; text-decoration: none; }
.e360c-index-card-title a:hover { color: var(--e-primary); }
.e360c-index-card-excerpt {
    font-size: 14px;
    color: var(--e-muted);
    line-height: 1.6;
    margin: 0 0 20px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.e360c-index-card-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 10px 20px;
    background: var(--e-primary);
    color: #fff;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: background .15s;
    align-self: flex-start;
    margin-top: auto;
}
.e360c-index-card-btn:hover { background: var(--e-mid); color: #fff; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
/* ── Resource Hub Cards ──────────────────────────────────────────────────── */
.e360c-hub-empty { grid-column: 1/-1; text-align: center; padding: 64px 24px; color: var(--e-muted); font-size: 16px; }
.e360c-hub-card { display: flex; flex-direction: column; background: var(--e-card); border: 1px solid var(--e-border); border-radius: 14px; overflow: hidden; text-decoration: none; color: inherit; box-shadow: var(--e-shadow); transition: box-shadow .2s, transform .2s; }
.e360c-hub-card:hover { box-shadow: 0 10px 32px rgba(0,70,109,.15); transform: translateY(-3px); color: inherit; text-decoration: none; }
.e360c-hub-card-img { height: 160px; background-size: cover; background-position: center; }
.e360c-hub-card-img--placeholder { background: var(--e-secondary-tint, #f0f9ff); display: flex; align-items: center; justify-content: center; }
.e360c-hub-card-img--placeholder span { font-size: 52px; }
.e360c-hub-card-body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.e360c-hub-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.e360c-hub-card-count { font-size: 12px; color: var(--e-muted); font-weight: 600; }
.e360c-hub-card-title { font-size: 22px; font-weight: 800; color: var(--e-text); margin: 0 0 8px; line-height: 1.2; }
.e360c-hub-card-desc { font-size: 14px; color: var(--e-muted); line-height: 1.6; margin: 0 0 18px; flex: 1; }
.e360c-hub-card-cta { font-size: 14px; font-weight: 700; color: var(--e-primary); }
.e360c-hub-card:hover .e360c-hub-card-cta { color: var(--e-mid); }


@media (max-width: 600px) {
    .e360c-wrap,
    .e360c-advisor-section { padding: 24px 16px 48px; }
    .e360c-title { font-size: 26px; }
    .e360c-lead-form .e360c-form-row { grid-template-columns: 1fr; }
    .e360c-advisor-header { flex-direction: column; gap: 12px; }
    .e360c-site-header-inner { padding: 0 16px; }
    .e360c-index-grid { grid-template-columns: 1fr; }
}
