/* Common fixes: extra styles on top of site.css (also used by the one example on the home page).
   Layout: short dark intro with a linked index, then one compact block per problem:
   the problem, why it matters and the fix on the left, before/after mock-ups on the right. */

:root {
  --bad: #B42318;      /* on --bad-bg: 6.0:1 */
  --bad-bg: #FEF3F2;
  --good: #067647;     /* on --good-bg: 5.6:1 */
  --good-bg: #ECFDF3;
}

/* ---------- Intro + index ---------- */
.fx-hero { background: linear-gradient(90deg, rgba(19, 35, 58, .95) 0%, rgba(19, 35, 58, .9) 55%, rgba(19, 35, 58, .72) 100%), var(--navy) url("/img/trades/heating-960.webp") center / cover no-repeat; color: var(--on-navy-muted); padding-block: clamp(36px, 6vw, 72px); }
@media (min-width: 900px) { .fx-hero { background-image: linear-gradient(90deg, rgba(19, 35, 58, .95) 0%, rgba(19, 35, 58, .9) 55%, rgba(19, 35, 58, .72) 100%), url("/img/trades/heating-1600.webp"); } }
.fx-hero .eyebrow { color: var(--on-navy-muted); }
.fx-hero h1 { color: var(--on-navy); max-width: 20ch; font-size: clamp(1.9rem, 4.6vw, 3rem); }
.fx-hero .lead { color: var(--on-navy-muted); max-width: 60ch; }
.fx-hero :focus-visible { outline-color: var(--on-navy); }
.fx-hero a:not(.btn) { color: var(--on-navy); }
.fx-honest { margin: 18px 0 0; padding-left: 14px; border-left: 3px solid var(--amber); max-width: 70ch; font-size: .98rem; }
.fx-honest strong { color: var(--on-navy); }
.fx-index-title { color: var(--on-navy); font-size: 1.15rem; margin: 32px 0 8px; }
.fx-guide { list-style: none; padding: 0; margin: 0; display: grid; column-gap: 32px; counter-reset: g; border-top: 1px solid rgba(250, 250, 247, .16); }
@media (min-width: 760px) { .fx-guide { grid-template-columns: 1fr 1fr; grid-auto-flow: column; grid-template-rows: repeat(4, auto); } }
.fx-guide li { counter-increment: g; border-bottom: 1px solid rgba(250, 250, 247, .16); }
.fx-guide a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 6px 0; font-weight: 600; color: var(--on-navy); text-decoration: none; line-height: 1.3; }
.fx-guide a::before { content: counter(g); flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--amber); color: var(--navy); font-size: .85rem; font-weight: 800; }
.fx-guide a:hover { text-decoration: underline; }

/* ---------- One problem ---------- */
.fx-list { padding-block: clamp(16px, 3vw, 32px) var(--section); }
.fx { padding-block: clamp(32px, 5vw, 56px); border-bottom: 1px solid var(--line); display: grid; gap: 24px; align-items: start; }
@media (min-width: 1000px) { .fx { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 48px; } }
.fx-head { display: flex; gap: 14px; align-items: flex-start; }
.fx-num { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--navy); color: var(--on-navy); font-weight: 800; font-size: 1.05rem; }
.fx-head h2 { font-size: clamp(1.35rem, 2.6vw, 1.75rem); margin-bottom: .25em; }
.fx-biz { margin: 0; font-size: .92rem; color: var(--muted); }
.fx-facts { display: grid; gap: 12px; margin: 20px 0 0; }
.fx-facts div { display: grid; gap: 2px; padding-left: 14px; border-left: 3px solid var(--line-strong); }
.fx-facts div:last-child { border-left-color: var(--amber); }
.fx-facts dt { font-weight: 800; color: var(--navy); }
.fx-facts dd { margin: 0; }
.fx-time { margin: 16px 0 0; font-size: .95rem; color: var(--text); background: var(--alt); border-radius: 8px; padding: 10px 14px; }
.fx-time strong { color: var(--navy); }
.fx-time span { display: block; }

/* ---------- Before / after ---------- */
.ba { display: grid; gap: 16px; }
@media (min-width: 560px) { .ba { grid-template-columns: 1fr 1fr; } }
.ba figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 16px 12px 14px; border-radius: 12px; }
.ba .before { background: var(--bad-bg); }
.ba .after { background: var(--good-bg); }
.ba-label { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: .9rem; padding: 3px 10px 3px 7px; border-radius: 999px; background: var(--white); }
.before .ba-label { color: var(--bad); }
.after .ba-label { color: var(--good); }
.ba-label .icon { width: 1.2em; height: 1.2em; stroke-width: 2.6; }
.ba figcaption { font-size: .9rem; color: var(--text); text-align: left; align-self: stretch; }

/* A phone drawn in CSS. The mock content inside is plain text marked role="img" with a full description. */
.mphone { width: min(100%, 250px); background: var(--navy-deep); border-radius: 30px; padding: 9px; box-shadow: 0 16px 30px -20px rgba(19, 35, 58, .6); }
.mscreen { background: #fff; border-radius: 22px; overflow: hidden; min-height: 340px; display: flex; flex-direction: column; font-size: .8rem; line-height: 1.4; color: #1f2937; }
.mbar { display: flex; align-items: center; gap: 6px; padding: 9px 11px; background: #f1f3f5; border-bottom: 1px solid #e3e6ea; font-size: .7rem; color: #374151; }
.mbar .url { flex: 1; min-width: 0; background: #fff; border: 1px solid #d6dbe1; border-radius: 999px; padding: 3px 9px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mbar .lock { width: 12px; height: 12px; flex: none; }
.mbody { padding: 12px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.m-center { align-items: center; justify-content: center; text-align: center; }

/* mock: map listing */
.mlist-photo { height: 80px; border-radius: 10px; background: linear-gradient(135deg, #8aa1b8, #c9d4de); }
.mlist-photo.roof { background: linear-gradient(160deg, #5b6b7d 0 45%, #8c5a43 45% 70%, #b9c4cf 70%); }
.mlist-photo.garden { background: linear-gradient(160deg, #6f9a6a 0 55%, #c2b59b 55%); }
.mlist-name { font-weight: 800; font-size: .98rem; color: #111827; line-height: 1.25; }
.mlist-meta { color: #4b5563; }
.stars { color: #9a6700; letter-spacing: 1px; }
.mlist-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.mlist-btns span { flex: 1; min-width: 60px; text-align: center; border: 1px solid #c7ced6; border-radius: 999px; padding: 5px 4px; font-weight: 700; color: #1f3a5f; background: #fff; }
.mlist-row { display: flex; gap: 8px; align-items: flex-start; padding-top: 8px; border-top: 1px solid #eceff2; }
.mlist-row b { min-width: 58px; color: #374151; }
.m-missing { color: #1d4ed8; font-weight: 700; }

/* mock: error and message pages */
.m-err-icon { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-size: 1.5rem; font-weight: 800; }
.m-err-icon.bad { background: #fde2df; color: var(--bad); }
.m-err-icon.good { background: #d7f5e3; color: var(--good); }
.m-err-title { font-weight: 800; font-size: 1.02rem; color: #111827; }
.m-small { font-size: .72rem; color: #4b5563; }
.m-suspended { background: #2f6aa8; color: #fff; }
.m-suspended .m-err-title, .m-suspended .m-small { color: #fff; }

/* mock: a small tradesperson website */
.msite-hero { border-radius: 10px; padding: 12px; color: #fff; background: linear-gradient(160deg, rgba(19,35,58,.92), rgba(30,53,86,.82)), linear-gradient(160deg, #5b6b7d, #8c5a43); }
.msite-hero.green { background: linear-gradient(160deg, rgba(18,52,38,.92), rgba(28,74,54,.85)), linear-gradient(160deg, #6f9a6a, #c2b59b); }
.msite-hero strong { display: block; font-size: .95rem; line-height: 1.25; margin-bottom: 4px; }
.msite-btns { display: flex; gap: 6px; }
.msite-btns span { flex: 1; text-align: center; padding: 7px 4px; border-radius: 8px; font-weight: 800; background: var(--amber); color: var(--navy); }
.msite-btns span.ghost { background: #fff; color: var(--navy); border: 1px solid #c7ced6; }
.msite-list { margin: 0; padding-left: 1.1em; }
.msite-gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.msite-gallery span { aspect-ratio: 4 / 3; border-radius: 6px; display: grid; place-items: center; text-align: center; font-size: .68rem; color: #4b5563; background: #eef1f5; border: 1px dashed #b8c1cc; padding: 4px; }
.msite-gallery.done span { border: 0; background: linear-gradient(150deg, #8c5a43, #c69a7f); }
.msite-gallery.done span:nth-child(2) { background: linear-gradient(150deg, #dfe7ee, #9fb2c4); }
.msite-gallery.done span:nth-child(3) { background: linear-gradient(150deg, #e9e1d3, #b9a98c); }
.msite-gallery.done span:nth-child(4) { background: linear-gradient(150deg, #cfd8e1, #7d8fa3); }
.msite-foot { margin-top: auto; background: #13233a; color: #d6dde7; border-radius: 8px; padding: 10px; font-size: .7rem; }
.mark-bad { background: #fde2df; color: #8a1c12; border-radius: 4px; padding: 0 3px; font-weight: 700; }
.mark-good { background: #d7f5e3; color: #05603a; border-radius: 4px; padding: 0 3px; font-weight: 700; }

/* mock: phone dialler */
.mdial { background: #111827; color: #f9fafb; align-items: center; justify-content: center; text-align: center; }
.mdial .m-small { color: #d1d5db; }
.mdial .num { font-size: 1.3rem; font-weight: 700; letter-spacing: .02em; }
.mdial .state { font-weight: 800; padding: 4px 12px; border-radius: 999px; }
.mdial .state.bad { background: #fde2df; color: #8a1c12; }
.mdial .state.good { background: #d7f5e3; color: #05603a; }
.mdial .endcall { width: 48px; height: 48px; border-radius: 50%; background: #dc2626; margin-top: 14px; }

/* mock: email */
.mmail-head { border-bottom: 1px solid #eceff2; padding-bottom: 8px; }
.mmail-from { font-weight: 800; color: #111827; overflow-wrap: anywhere; }

/* mock: reviews */
.mrev { border-top: 1px solid #eceff2; padding-top: 8px; }
.mrev b { color: #111827; }
.mreply { margin-top: 6px; padding: 7px; border-left: 3px solid var(--good); background: #f3faf6; border-radius: 0 6px 6px 0; }
.mreply b { display: block; font-size: .7rem; color: #05603a; }

/* two-address comparison */
.m-addr { padding: 9px; border-radius: 8px; background: #f8fafc; border: 1px solid #e3e6ea; }
.m-addr b { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #4b5563; }

/* ---------- Bottom bits ---------- */
.fx-legend { margin: 32px 0 0; font-size: .95rem; color: var(--muted); max-width: 70ch; }
