/* MiCA page 8109 — White Label layout parity, 2026-11-23.
 * Colour, type, hero, button and card visuals intentionally come from the
 * EXISTING white-label.css + white-label-pilot.css.
 * Original White Label selectors require ACF anchors #white-label-top and
 * #white-label-facts; see companion guarded ACF migration.
 * This file ONLY corrects MiCA content widths/spacing and the distinct RUE CTA.
 * TODO (future): consolidate these layout tokens when unifying landing templates.
 */

/* Same central width as the wide site contact section. Narrative remains readable. */
body.rue-mica-license.rue-white-label-components #primary.fx-main > .fx-builder > section.fx:not(#white-label-top):not(#white-label-facts) > .fx-inner {
  width: min(1360px, calc(100% - 48px)) !important;
  max-width: 1360px !important;
  min-width: 0;
}
body.rue-mica-license.rue-white-label-components #primary.fx-main .fx--rich_text:not(#white-label-facts) .fx-rich,
body.rue-mica-license.rue-white-label-components.rue-white-label-pilot #primary.fx-main .fx--rich_text:not(#white-label-facts) .fx-rich {
  width: 100% !important;
  max-width: 1280px !important;
}
body.rue-mica-license.rue-white-label-components #primary.fx-main .fx--rich_text:not(#white-label-facts) .fx-rich-body {
  max-width: 100% !important;
  min-width: 0;
}
body.rue-mica-license.rue-white-label-components #primary.fx-main .fx--rich_text:not(#white-label-facts) .fx-rich-body > :is(p,ul,ol,blockquote) {
  max-width: 98ch;
  margin-inline: auto;
}
/* Data tables span the wider content area, without breaking words into letters. */
body.rue-mica-license #primary .fx--rich_text .wl-table-scroll,
body.rue-mica-license #primary .fx--rich_text .wl-child-table-scroll {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
body.rue-mica-license #primary .fx--rich_text .wl-table-scroll table,
body.rue-mica-license #primary .fx--rich_text .wl-child-table-scroll table {
  width: 100% !important;
  table-layout: auto;
}
body.rue-mica-license #primary .fx--rich_text .wl-table-scroll :is(td,th),
body.rue-mica-license #primary .fx--rich_text .wl-child-table-scroll :is(td,th) {
  overflow-wrap: normal;
  word-break: normal;
  vertical-align: top;
}
/* MiCA has 24 smaller chapters. Avoid long blank bands between short sections. */
body.rue-mica-license.rue-white-label.rue-white-label-components.rue-white-label-pilot #primary.fx-main > .fx-builder > section.fx:not(#white-label-top):not(#white-label-facts) {
  padding-block: clamp(26px, 3vw, 44px) !important;
}
body.rue-mica-license.rue-white-label-components #primary.fx-main > .fx-builder > section.fx--rich_text:not(#white-label-facts) .fx-rich__heading {
  text-align: center !important;
  margin-bottom: clamp(16px, 2vw, 24px) !important;
}
body.rue-mica-license #primary .fx--link_cards .fx-link_cards__list,
body.rue-mica-license #primary .fx--step_by_step .fx-sbs { max-width: 1280px; margin-inline: auto; }
body.rue-mica-license #primary .fx--link_cards .fx-link_cards__item,
body.rue-mica-license #primary .fx--link_cards .fx-link_cards__card,
body.rue-mica-license #primary .fx--step_by_step .fx-sbs__item { min-width: 0; overflow-wrap: break-word; }

/* White Label Banking uses a gold-filled primary action; keep the same CTA hierarchy. */
body.rue-mica-license.rue-white-label-components #primary.fx-main #white-label-top .fx-hero__actions .fx-btn--primary {
  background: #f4d48a !important;
  border-color: #d3b775 !important;
  color: #12171d !important;
}
body.rue-mica-license.rue-white-label-components #primary.fx-main #white-label-top .fx-hero__actions .fx-btn--primary:hover {
  background: #ebc774 !important;
}

/* Facts have three real items; the shared banking grid defaults to four. */
body.rue-mica-license.rue-white-label-components #primary #white-label-facts .wl-facts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* Use the normal White Label CTA card geometry, with no MiCA v2 skin overrides.
 * Both actions stay contained within the frame. */
body.rue-mica-license #primary .fx--cta .fx-cta__panel {
  box-sizing: border-box;
  width: min(100%, 1120px);
  max-width: 100%;
  height: auto !important;
  min-height: 0 !important;
  overflow: visible;
}
body.rue-mica-license #primary .fx--cta .fx-cta__body,
body.rue-mica-license #primary .fx--cta .fx-cta__actions { min-width: 0; max-width: 100%; }
body.rue-mica-license #primary .fx--cta .fx-cta__text {
  max-width: 90ch;
  overflow-wrap: break-word;
}
body.rue-mica-license #primary .fx--cta .fx-cta__buttons {
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2px;
}
body.rue-mica-license #primary .fx--cta .fx-cta__btn { max-width: 100%; white-space: normal; text-align: center; }

/* The service introduction is a restrained charcoal band, within the same
 * White Label palette. CSS is page-ID-scoped and does NOT touch global CTA. */
body.rue-mica-license.rue-white-label-components.rue-white-label-pilot #primary.fx-main > .fx-builder > section#rue-support.fx--cta {
  background: #1d242c !important;
  padding-block: clamp(44px, 4.5vw, 68px) !important;
}
body.rue-mica-license.rue-white-label-components.rue-white-label-pilot #primary.fx-main #rue-support .fx-cta__panel {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  width: min(100%, 1120px);
  max-width: 1120px !important;
  padding: 20px 24px !important;
}
body.rue-mica-license.rue-white-label.rue-white-label-components.rue-white-label-pilot #primary.fx-main > .fx-builder > section#rue-support.fx--cta.fx:not(#white-label-top) h2.fx-cta__title {
  color: #f4d48a !important;
  text-shadow: none !important;
  margin-bottom: 14px !important;
}
body.rue-mica-license.rue-white-label-components.rue-white-label-pilot #primary.fx-main #rue-support .fx-cta__text {
  color: #e6e3de !important;
  font-size: 16px !important;
  line-height: 1.7 !important;
  max-width: 90ch !important;
  margin-inline: auto;
}
body.rue-mica-license.rue-white-label-components.rue-white-label-pilot #primary.fx-main #rue-support .fx-cta__btn {
  background: #f4d48a !important;
  border-color: #d3b775 !important;
  color: #12171d !important;
}

@media (max-width: 800px) {
  body.rue-mica-license.rue-white-label-components #primary.fx-main > .fx-builder > section.fx:not(#white-label-top):not(#white-label-facts) > .fx-inner {
    width: calc(100% - 32px) !important;
  }
  body.rue-mica-license.rue-white-label-components #primary #white-label-facts .wl-facts {
    grid-template-columns: 1fr;
  }
  body.rue-mica-license #primary .fx--rich_text .wl-table-scroll table,
  body.rue-mica-license #primary .fx--rich_text .wl-child-table-scroll table {
    min-width: 650px;
  }
  body.rue-mica-license #primary #rue-support .fx-cta__panel { padding: 12px !important; }
}
