/* =====================================================
   ECU flashing guides: hub (/ecu-flashing/) and brand pages.
   Built on the features-page look (.mfx-fp): same hero, section
   rhythm, card surfaces, mono labels and display type.
   ===================================================== */

.mfx-ecu .mfx-ecu-crumbs {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 22px;
    font: 600 13px/1 var(--mf-font-mono);
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--mf-text-secondary);
}
.mfx-ecu .mfx-ecu-crumbs::before { content: ''; width: 40px; height: 1px; background: var(--mf-gradient-primary); }
.mfx-ecu .mfx-ecu-crumbs a { color: var(--mf-text-secondary); text-decoration: none; }
.mfx-ecu .mfx-ecu-crumbs a:hover { color: #7badff; }
.mfx-ecu .mfx-ecu-crumbs span[aria-hidden] { color: var(--mf-text-muted); }

.mfx-ecu .mfx-ecu-hero-hub .mfx-fhero-inner { grid-template-columns: minmax(0, 1fr); }
.mfx-ecu .mfx-ecu-hero-hub .mfx-fhero-copy { max-width: 760px; }

/* Section rhythm */
.mfx-ecu .mfx-ecu-section { padding: 120px 0; }
.mfx-ecu .mfx-ecu-section-alt { background: #0c1222; border-top: 1px solid var(--mfx-line); border-bottom: 1px solid var(--mfx-line); }
.mfx-ecu .mf-section-header-modern { margin-bottom: 48px; }

/* Shared surfaces */
.mfx-ecu .mfx-ecu-table,
.mfx-ecu .mfx-ecu-family,
.mfx-ecu .mfx-ecu-steps li,
.mfx-ecu .mfx-ecu-brand,
.mfx-ecu .mfx-ecu-cta-box {
    border: 1px solid rgba(123, 173, 255, 0.16);
    background:
        radial-gradient(ellipse at 50% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 60%),
        linear-gradient(180deg, #121a2c 0%, #0b1120 100%);
}

/* Model search */
.mfx-ecu .mfx-ecu-search {
    position: relative;
    max-width: 420px;
    margin-bottom: 18px;
}
.mfx-ecu .mfx-ecu-search svg { position: absolute; left: 16px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--mf-text-muted); }
.mfx-ecu .mfx-ecu-search input {
    width: 100%;
    padding: 14px 16px 14px 46px;
    border: 1px solid rgba(123, 173, 255, 0.22);
    border-radius: 12px;
    background: rgba(17, 24, 39, 0.7);
    color: var(--mf-text-primary);
    font: 500 15px/1.2 var(--mf-font);
    outline: none;
    transition: var(--mf-transition);
}
.mfx-ecu .mfx-ecu-search input:focus { border-color: var(--mf-accent); box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2); }

/* Models table */
.mfx-ecu .mfx-ecu-table { border-radius: 22px; overflow: hidden; box-shadow: 0 50px 100px -60px rgba(59, 130, 246, 0.6); }
.mfx-ecu .mfx-ecu-row {
    display: grid;
    grid-template-columns: minmax(160px, 1.3fr) minmax(120px, 0.9fr) minmax(220px, 1.6fr) minmax(200px, 1.4fr);
    gap: 18px;
    align-items: center;
    padding: 16px 24px;
    border-top: 1px solid var(--mfx-line);
    transition: background 0.2s ease;
}
.mfx-ecu .mfx-ecu-row[hidden] { display: none; }
.mfx-ecu .mfx-ecu-row:not(.mfx-ecu-row-head):hover { background: rgba(59, 130, 246, 0.06); }
.mfx-ecu .mfx-ecu-row-head {
    border-top: 0;
    padding-top: 18px;
    padding-bottom: 14px;
    background: rgba(10, 15, 28, 0.6);
    font: 600 11px/1 var(--mf-font-mono);
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--mf-text-muted);
}
.mfx-ecu .mfx-ecu-model { font: 600 1rem/1.3 var(--mf-font-display); color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-years { font: 500 13.5px/1.3 var(--mf-font-mono); color: #7badff; }
.mfx-ecu .mfx-ecu-chip { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.mfx-ecu .mfx-ecu-chip strong { font-weight: 600; color: var(--mf-text-primary); font-size: 14.5px; }
.mfx-ecu .mfx-ecu-chip small { font-size: 12.5px; color: var(--mf-text-muted); }
.mfx-ecu .mfx-ecu-devices { display: flex; flex-wrap: wrap; gap: 6px; }
.mfx-ecu .mfx-ecu-devices i,
.mfx-ecu .mfx-ecu-family footer i {
    font: 500 11.5px/1 var(--mf-font);
    font-style: normal;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(123, 173, 255, 0.2);
    color: #c7dbff;
    white-space: nowrap;
}
.mfx-ecu .mfx-ecu-addon,
.mfx-ecu .mfx-ecu-included {
    font: 600 10.5px/1 var(--mf-font-mono);
    font-style: normal;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 5px 8px;
    border-radius: 6px;
}
.mfx-ecu .mfx-ecu-addon { color: #fcd34d; background: rgba(245, 158, 11, 0.12); border: 1px solid rgba(245, 158, 11, 0.3); }
.mfx-ecu .mfx-ecu-included { color: #6ee7b7; background: rgba(16, 185, 129, 0.1); border: 1px solid rgba(16, 185, 129, 0.28); }
.mfx-ecu .mfx-ecu-dim { color: var(--mf-text-muted); }
.mfx-ecu .mfx-ecu-empty { margin: 0; padding: 26px 24px; border-top: 1px solid var(--mfx-line); color: var(--mf-text-secondary); }
.mfx-ecu .mfx-ecu-empty a { color: #7badff; }

/* ECU family cards */
.mfx-ecu .mfx-ecu-families { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.mfx-ecu .mfx-ecu-family { display: flex; flex-direction: column; padding: 26px 24px 22px; border-radius: 22px; transition: border-color 0.25s ease, transform 0.25s ease; }
.mfx-ecu .mfx-ecu-family:hover { border-color: rgba(123, 173, 255, 0.4); transform: translateY(-3px); }
.mfx-ecu .mfx-ecu-family header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.mfx-ecu .mfx-ecu-family-maker { font: 600 12px/1 var(--mf-font-mono); letter-spacing: 2.5px; text-transform: uppercase; color: var(--mf-text-secondary); }
.mfx-ecu .mfx-ecu-family h3 { margin: 0; font: 700 1.6rem/1.1 var(--mf-font-display); letter-spacing: -0.02em; color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-family-meta { margin: 8px 0 0; font: 500 13px/1.4 var(--mf-font-mono); color: #7badff; }
.mfx-ecu .mfx-ecu-family-models { flex: 1; margin: 14px 0 18px; font-size: 14px; line-height: 1.6; color: var(--mf-text-secondary); }
.mfx-ecu .mfx-ecu-family footer { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 16px; border-top: 1px solid var(--mfx-line); }

/* Steps */
.mfx-ecu .mfx-ecu-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; counter-reset: none; }
.mfx-ecu .mfx-ecu-steps li { position: relative; padding: 28px 24px; border-radius: 22px; }
.mfx-ecu .mfx-ecu-steps li > span {
    display: block;
    margin-bottom: 22px;
    font: 700 2.4rem/1 var(--mf-font-display);
    background: linear-gradient(180deg, #ffffff 20%, #3b82f6 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.mfx-ecu .mfx-ecu-steps h3 { margin: 0 0 10px; font: 700 1.2rem/1.3 var(--mf-font-display); color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-steps p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--mf-text-secondary); }

/* Written guide (page content) */
.mfx-ecu .mfx-ecu-guide { max-width: 820px; color: var(--mf-text-secondary); font-size: 1.05rem; line-height: 1.8; }
.mfx-ecu .mfx-ecu-guide > :first-child { margin-top: 0; }
.mfx-ecu .mfx-ecu-guide h2 {
    margin: 64px 0 18px;
    font: 700 clamp(1.7rem, 3vw, 2.4rem)/1.12 var(--mf-font-display);
    letter-spacing: -0.03em;
    color: var(--mf-text-primary);
}
.mfx-ecu .mfx-ecu-guide h2:first-child { margin-top: 0; }
.mfx-ecu .mfx-ecu-guide h3 { margin: 36px 0 12px; font: 700 1.3rem/1.3 var(--mf-font-display); color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-guide p { margin: 0 0 18px; }
.mfx-ecu .mfx-ecu-guide strong { color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-guide a { color: #7badff; text-underline-offset: 3px; }
.mfx-ecu .mfx-ecu-guide ul { margin: 0 0 22px; padding: 0; list-style: none; }
.mfx-ecu .mfx-ecu-guide ul li { position: relative; padding: 6px 0 6px 28px; }
.mfx-ecu .mfx-ecu-guide ul li::before {
    content: '';
    position: absolute;
    left: 4px;
    top: 17px;
    width: 10px;
    height: 2px;
    background: var(--mf-gradient-primary);
}
.mfx-ecu .mfx-ecu-guide ol { margin: 0 0 22px; padding-left: 22px; }
.mfx-ecu .mfx-ecu-guide ol li { padding: 4px 0 4px 6px; }
.mfx-ecu .mfx-ecu-guide ol li::marker { font: 700 0.95rem var(--mf-font-mono); color: #7badff; }

/* Callout: <div class="mfx-ecu-note"> or a quote block */
.mfx-ecu .mfx-ecu-guide .mfx-ecu-note,
.mfx-ecu .mfx-ecu-guide blockquote {
    margin: 28px 0;
    padding: 20px 24px;
    border: 1px solid rgba(123, 173, 255, 0.22);
    border-left: 3px solid var(--mf-accent);
    border-radius: 14px;
    background: rgba(59, 130, 246, 0.07);
    color: var(--mf-text-secondary);
}
.mfx-ecu .mfx-ecu-guide blockquote p:last-child,
.mfx-ecu .mfx-ecu-guide .mfx-ecu-note p:last-child { margin-bottom: 0; }

/* FAQ: details/summary blocks in the content */
.mfx-ecu .mfx-ecu-guide details {
    margin: 0 0 12px;
    border: 1px solid rgba(123, 173, 255, 0.16);
    border-radius: 16px;
    background: linear-gradient(180deg, #121a2c 0%, #0b1120 100%);
    overflow: hidden;
}
.mfx-ecu .mfx-ecu-guide summary {
    position: relative;
    padding: 20px 56px 20px 24px;
    list-style: none;
    cursor: pointer;
    font: 600 1.05rem/1.4 var(--mf-font-display);
    color: var(--mf-text-primary);
}
.mfx-ecu .mfx-ecu-guide summary::-webkit-details-marker { display: none; }
.mfx-ecu .mfx-ecu-guide summary::after {
    content: '+';
    position: absolute;
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
    font: 400 1.6rem/1 var(--mf-font);
    color: #7badff;
    transition: transform 0.2s ease;
}
.mfx-ecu .mfx-ecu-guide details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.mfx-ecu .mfx-ecu-guide details > :not(summary) { margin: 0; padding: 0 24px 20px; }

/* Brand grid (hub and "more brands") */
.mfx-ecu .mfx-ecu-brands { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.mfx-ecu .mfx-ecu-brand {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 24px 22px;
    border-radius: 20px;
    text-decoration: none;
    transition: border-color 0.25s ease, transform 0.25s ease;
}
.mfx-ecu .mfx-ecu-brand:hover { border-color: rgba(123, 173, 255, 0.45); transform: translateY(-3px); }
.mfx-ecu .mfx-ecu-brand strong { font: 700 1.4rem/1.15 var(--mf-font-display); color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-brand span { font: 500 12.5px/1.4 var(--mf-font-mono); color: #7badff; }
.mfx-ecu .mfx-ecu-brand small { font-size: 13.5px; line-height: 1.5; color: var(--mf-text-muted); }
.mfx-ecu .mfx-ecu-brand em { margin-top: 8px; font: 600 13px/1 var(--mf-font); font-style: normal; color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-brand.has-guide { border-color: rgba(123, 173, 255, 0.3); }
.mfx-ecu .mfx-ecu-brands-compact { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.mfx-ecu .mfx-ecu-brands-compact .mfx-ecu-brand { padding: 18px 20px; }
.mfx-ecu .mfx-ecu-brands-compact .mfx-ecu-brand strong { font-size: 1.15rem; }

/* CTA */
.mfx-ecu .mfx-ecu-cta { padding: 0 0 130px; }
.mfx-ecu .mfx-ecu-cta-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding: 48px 52px;
    border-radius: 28px;
    border-color: rgba(123, 173, 255, 0.28);
    background:
        radial-gradient(ellipse at 100% 0%, rgba(59, 130, 246, 0.22) 0%, transparent 55%),
        linear-gradient(180deg, #121a2c 0%, #0b1120 100%);
    box-shadow: 0 60px 120px -60px rgba(59, 130, 246, 0.7);
}
.mfx-ecu .mfx-ecu-cta-box h2 { margin: 0 0 10px; font: 700 clamp(1.7rem, 3vw, 2.5rem)/1.1 var(--mf-font-display); letter-spacing: -0.03em; color: var(--mf-text-primary); }
.mfx-ecu .mfx-ecu-cta-box p { margin: 0; max-width: 560px; color: var(--mf-text-secondary); }
.mfx-ecu .mfx-ecu-cta-box .mfx-hero-actions { flex: none; margin: 0; }

/* Responsive */
@media (max-width: 1100px) {
    .mfx-ecu .mfx-ecu-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mfx-ecu .mfx-ecu-row { grid-template-columns: minmax(130px, 1.2fr) minmax(100px, 0.9fr) minmax(170px, 1.5fr); }
    .mfx-ecu .mfx-ecu-row > :nth-child(4) { display: none; }
}
@media (max-width: 760px) {
    .mfx-ecu .mfx-ecu-section { padding: 80px 0; }
    .mfx-ecu .mfx-ecu-row { grid-template-columns: 1fr auto; gap: 6px 14px; padding: 14px 18px; }
    .mfx-ecu .mfx-ecu-row > :nth-child(4) { display: none; }
    .mfx-ecu .mfx-ecu-row-head { display: none; }
    .mfx-ecu .mfx-ecu-model { grid-column: 1; }
    .mfx-ecu .mfx-ecu-years { grid-column: 2; grid-row: 1; text-align: right; }
    .mfx-ecu .mfx-ecu-chip { grid-column: 1 / -1; grid-row: 2; }
    .mfx-ecu .mfx-ecu-steps { grid-template-columns: 1fr; }
    .mfx-ecu .mfx-ecu-cta-box { flex-direction: column; align-items: flex-start; padding: 32px 26px; }
    .mfx-ecu .mfx-ecu-cta { padding-bottom: 80px; }
}

/* Blog guides about the brand */
.mfx-ecu .mfx-ecu-guides-list { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.mfx-ecu .mfx-ecu-guides-list .mfx-ecu-brand strong { font-size: 1.05rem; line-height: 1.35; }
.mfx-ecu .mfx-ecu-guides-list .mfx-ecu-brand small {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.55;
}
