/* ==========================================================================
   aComRegBrkDwn_v0.css
   Regional Breakdown of Agentic Commerce
   --------------------------------------------------------------------------
   Scope: .acom-regbrk only. No selectors intentionally escape this component.
   Strategy: mobile-first cards, upgraded to the wide editorial table at 900px.
   Visual target: Alternative3.png.
   ========================================================================== */

.acom-regbrk {
  --arb-ink: #12181e;
  --arb-navy: #0a3540;
  --arb-navy-2: #0d4653;
  --arb-teal: #0e5966;
  --arb-teal-soft: #e8f1f1;
  --arb-gold: #d39a24;
  --arb-gold-deep: #a96f00;
  --arb-gold-soft: #fff4df;
  --arb-line: #ece5d7;
  --arb-paper: #fffefd;
  --arb-paper-alt: #fffdf9;
  --arb-note: #fbf8f1;
  --arb-muted: #647078;
  --arb-shadow: 0 10px 26px rgba(20, 37, 44, 0.055);
  --arb-radius: 16px;

  width: 100%;
  margin: 1.65rem 0 1.25rem;
  color: var(--arb-ink);
  font-family: "Roboto", Arial, sans-serif;
  font-size: 0.95rem;
  line-height: 1.46;
  background: transparent;
  isolation: isolate;
}

.acom-regbrk *,
.acom-regbrk *::before,
.acom-regbrk *::after {
  box-sizing: border-box;
}

.acom-regbrk__sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.acom-regbrk__icon {
  display: inline-block;
  width: 1em;
  height: 1em;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* --- title --------------------------------------------------------------- */
.acom-regbrk__header {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.72rem;
  padding: 0 0 0.75rem;
  margin: 0 0 0.45rem;
  position: relative;
}

.acom-regbrk__header::after {
  content: "";
  position: absolute;
  left: 3.95rem;
  bottom: 0;
  width: 3.15rem;
  height: 3px;
  border-radius: 999px;
  background: var(--arb-gold);
}

.acom-regbrk__header > .acom-regbrk__icon {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--arb-gold);
  stroke-width: 1.5;
}

.acom-regbrk__title {
  margin: 0;
  color: var(--arb-ink);
  font-size: clamp(1.12rem, 2.7vw, 1.55rem);
  line-height: 1.18;
  font-weight: 400;
  letter-spacing: -0.015em;
}

.acom-regbrk__title strong {
  font-weight: 700;
}

/* --- mobile: each row is a self-contained editorial card --------------- */
.acom-regbrk__scroll {
  overflow: visible;
}

.acom-regbrk__table,
.acom-regbrk__table tbody,
.acom-regbrk__table tr,
.acom-regbrk__table td {
  display: block;
  width: 100%;
}

.acom-regbrk__table {
  border: 0;
  border-collapse: separate;
  border-spacing: 0;
  background: transparent;
}

.acom-regbrk__table thead {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.acom-regbrk__row {
  position: relative;
  margin: 0 0 0.85rem;
  padding: 1rem;
  border: 1px solid var(--arb-line);
  border-radius: var(--arb-radius);
  background: var(--arb-paper);
  box-shadow: var(--arb-shadow);
  overflow: hidden;
}

.acom-regbrk__row:nth-child(even) {
  background: var(--arb-paper-alt);
}

.acom-regbrk__td {
  min-width: 0;
  padding: 0.78rem 0;
  border: 0;
  color: var(--arb-ink);
  font-size: 0.91rem;
  line-height: 1.48;
  overflow-wrap: anywhere;
}

.acom-regbrk__td + .acom-regbrk__td {
  border-top: 1px solid var(--arb-line);
}

.acom-regbrk__td[data-label]::before {
  content: attr(data-label);
  display: block;
  margin: 0 0 0.48rem;
  color: var(--arb-muted);
  font-size: 0.72rem;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0.065em;
  text-transform: uppercase;
}

/* Number becomes a compact timeline cue. */
.acom-regbrk__td--num {
  display: grid !important;
  place-items: center;
  width: 3.35rem !important;
  min-height: 3.35rem;
  padding: 0;
  margin: 0 0 0.7rem;
  border: 0 !important;
}

.acom-regbrk__td--num::before {
  display: none !important;
}

.acom-regbrk__num {
  display: inline-grid;
  place-items: center;
  width: 2.55rem;
  height: 2.55rem;
  border-radius: 50%;
  background: linear-gradient(180deg, #0e5f69 0%, #083e48 100%);
  color: #fff;
  font-size: 1.02rem;
  font-weight: 700;
  box-shadow: 0 3px 9px rgba(10, 53, 64, 0.18);
}

.acom-regbrk__row:nth-child(even) .acom-regbrk__num {
  background: linear-gradient(180deg, #e0ac3a 0%, #b57905 100%);
}


/* Status tile */
.acom-regbrk__status {
  display: grid;
  justify-items: center;
  gap: 0.45rem;
  width: min(100%, 12rem);
  margin: 0 auto;
  padding: 1rem 0.8rem;
  border-radius: 13px;
  text-align: center;
  font-weight: 700;
  line-height: 1.28;
}

.acom-regbrk__status > .acom-regbrk__icon {
  width: 2.25rem;
  height: 2.25rem;
  stroke-width: 1.55;
}

.acom-regbrk__status--live {
  color: var(--arb-teal);
  background: linear-gradient(180deg, #f0f6f5 0%, #e7efee 100%);
}

.acom-regbrk__status--active {
  color: var(--arb-gold-deep);
  background: linear-gradient(180deg, #fff7e9 0%, #fff0d6 100%);
}

.acom-regbrk__status--preparing {
  color: #5a6670;
  background: #f1f3f4;
}

/* Data / activity lists */
.acom-regbrk__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.acom-regbrk__list li {
  position: relative;
  margin: 0 0 0.58rem;
  padding-left: 1.4rem;
}

.acom-regbrk__list li:last-child {
  margin-bottom: 0;
}

.acom-regbrk__list li::before {
  content: "•";
  position: absolute;
  left: 0.15rem;
  top: -0.03rem;
  color: var(--arb-teal);
  font-size: 1.1em;
  font-weight: 800;
}

.acom-regbrk__row:nth-child(even) .acom-regbrk__list:not(.acom-regbrk__list--check) li::before {
  color: var(--arb-gold);
}

.acom-regbrk__list strong {
  color: var(--arb-ink);
  font-weight: 700;
}

.acom-regbrk__list--check li {
  padding-left: 1.78rem;
}

.acom-regbrk__list--check li::before {
  content: "✓";
  display: grid;
  place-items: center;
  left: 0;
  top: 0.16rem;
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--arb-teal);
  border-radius: 50%;
  color: var(--arb-teal);
  background: transparent;
  font-size: 0.62rem;
  line-height: 1;
}

.acom-regbrk__row:nth-child(even) .acom-regbrk__list--check li::before {
  border-color: var(--arb-gold);
  color: var(--arb-gold);
}

/* Sources are separated by subtle horizontal rules, like the mockup. */
.acom-regbrk__source-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.acom-regbrk__source-list li {
  position: relative;
  padding: 0.76rem 1.7rem 0.76rem 0;
  border-bottom: 1px dotted #d7c8ae;
}

.acom-regbrk__source-list li:first-child {
  padding-top: 0.1rem;
}

.acom-regbrk__source-list li:last-child {
  border-bottom: 0;
  padding-bottom: 0.1rem;
}

.acom-regbrk__source-link,
.acom-regbrk__source-text {
  color: var(--arb-ink);
  font-weight: 400;
  text-decoration: none;
}

.acom-regbrk__source-link::after,
.acom-regbrk__source-list li::after {
  content: "↗";
  position: absolute;
  right: 0.05rem;
  top: 0.7rem;
  color: var(--arb-teal);
  font-size: 1rem;
  font-weight: 700;
}

.acom-regbrk__source-link::after {
  display: none;
}

.acom-regbrk__row:nth-child(even) .acom-regbrk__source-list li::after {
  color: var(--arb-gold);
}

.acom-regbrk__source-list li:first-child::after {
  top: 0.05rem;
}

.acom-regbrk__source-link:hover,
.acom-regbrk__source-link:focus-visible {
  color: var(--arb-teal);
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

/* Note */
.acom-regbrk__note {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.72rem;
  margin: 0.95rem 0 0;
  padding: 0.75rem 0.95rem;
  border: 1px solid #eadfca;
  border-radius: 12px;
  background: var(--arb-note);
  color: #222b31;
  font-size: 0.82rem;
  line-height: 1.45;
  font-style: italic;
}

.acom-regbrk__note > .acom-regbrk__icon {
  width: 1.35rem;
  height: 1.35rem;
  padding: 0.2rem;
  border-radius: 50%;
  background: var(--arb-navy);
  color: #fff;
  stroke-width: 2;
}

.acom-regbrk__note strong {
  font-style: normal;
}

/* --- tablet -------------------------------------------------------------- */
@media (min-width: 640px) {
  .acom-regbrk__row {
    display: grid !important;
    grid-template-columns: 4.2rem minmax(0, 1fr) minmax(0, 1fr);
    gap: 0;
    padding: 0;
  }

  .acom-regbrk__td {
    padding: 1rem;
  }

  .acom-regbrk__td + .acom-regbrk__td {
    border-top: 0;
  }

  .acom-regbrk__td--num {
    grid-row: 1 / 4;
    align-self: stretch;
    width: auto !important;
    min-height: 100%;
    margin: 0;
    border-right: 1px solid var(--arb-line) !important;
  }

  .acom-regbrk__td--region,
  .acom-regbrk__td--status {
    border-bottom: 1px solid var(--arb-line);
  }

  .acom-regbrk__td--region {
    border-right: 1px solid var(--arb-line);
  }

  .acom-regbrk__td--data,
  .acom-regbrk__td--activity,
  .acom-regbrk__td--sources {
    grid-column: 2 / -1;
    border-top: 1px solid var(--arb-line) !important;
  }
}

/* --- desktop: editorial data table matching Alternative 3 ---------------- */
@media (min-width: 900px) {
  .acom-regbrk {
    font-size: 0.93rem;
  }

  .acom-regbrk__header {
    grid-template-columns: auto auto 1fr;
    gap: 0.8rem;
    padding-bottom: 0.8rem;
  }

  .acom-regbrk__header::after {
    left: 4rem;
  }

  .acom-regbrk__scroll {
    overflow-x: auto;
    overflow-y: visible;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #a9b4b7 transparent;
  }

  .acom-regbrk__table {
    display: table;
    width: 100%;
    min-width: 1180px;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    border: 1px solid var(--arb-line);
    border-radius: var(--arb-radius);
    background: var(--arb-paper);
    box-shadow: var(--arb-shadow);
  }

  .acom-regbrk__table thead {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    white-space: normal;
    display: table-header-group;
  }

  /* [FIX] The base (mobile) rule sets `.acom-regbrk__table tr { display: block }`
     using a bare element selector, which also matches the header row (it has
     no `.acom-regbrk__row` class). Without this, the header <tr> never
     switches to `table-row` at this breakpoint, so the browser wraps its
     table-cell children in an anonymous table of their own — rendering the
     header as a separate stacked column instead of a row across the top. */
  .acom-regbrk__table thead tr {
    display: table-row;
  }

  .acom-regbrk__table tbody {
    display: table-row-group;
  }

  .acom-regbrk__row {
    display: table-row !important;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: var(--arb-paper);
  }

  .acom-regbrk__row:nth-child(even) {
    background: var(--arb-paper-alt);
  }

  /* [FIX] `!important` is required here: the base (mobile) rule
     `.acom-regbrk__table td { display: block; width: 100%; }` combines a
     class with a type selector, giving it higher specificity than the
     unqualified `.acom-regbrk__td` selector below. Without `!important`,
     the base rule kept winning at desktop width, so every cell stayed
     `display: block` and stacked vertically instead of becoming a table
     column — which is the "content outside its column" bug in the
     screenshots. */
  .acom-regbrk__th,
  .acom-regbrk__td {
    display: table-cell !important;
    width: auto;
    min-width: 0;
    border: 0;
    border-right: 1px solid var(--arb-line);
    border-bottom: 1px solid var(--arb-line);
    vertical-align: top;
  }

  .acom-regbrk__th:last-child,
  .acom-regbrk__td:last-child {
    border-right: 0;
  }

  .acom-regbrk__row:last-child .acom-regbrk__td {
    border-bottom: 0;
  }

  .acom-regbrk__th {
    padding: 0.85rem 0.85rem;
    /*background: linear-gradient(180deg, #0b3541 0%, #0a303a 100%);*/
    background:#4d555b; 
    color: #fff;
    font-size: 0.83rem;
    line-height: 1.2;
    font-weight: 700;
    text-align: left;
    white-space: nowrap;
    vertical-align: middle;
    border-right-color: rgba(255,255,255,0.35);
    border-bottom: 0;
  }

  .acom-regbrk__th:first-child {
    border-top-left-radius: var(--arb-radius);
    text-align: center;
  }

  .acom-regbrk__th:last-child {
    border-top-right-radius: var(--arb-radius);
  }

  .acom-regbrk__th .acom-regbrk__icon {
    width: 1.38rem;
    height: 1.38rem;
    margin-right: 0.5rem;
    color: #f0be4f;
    vertical-align: -0.33rem;
  }

  .acom-regbrk__th--num {
    width: 4.4%;
    color: #f0be4f;
  }

  .acom-regbrk__th:nth-child(2) { width: 14.5%; }
  .acom-regbrk__th:nth-child(3) { width: 11.7%; }
  .acom-regbrk__th:nth-child(4) { width: 22.7%; }
  .acom-regbrk__th:nth-child(5) { width: 28.0%; }
  .acom-regbrk__th:nth-child(6) { width: 18.7%; }

  .acom-regbrk__td {
    padding: 1.35rem 1.05rem;
    font-size: 0.85rem;
    line-height: 1.48;
    background: inherit;
  }

  .acom-regbrk__td[data-label]::before {
    display: none;
  }

  .acom-regbrk__td--num {
    display: table-cell !important;
    width: auto !important;
    min-height: 0;
    margin: 0;
    padding: 0;
    text-align: center;
    vertical-align: middle;
    position: relative;
    border-right: 1px solid var(--arb-line) !important;
  }

  .acom-regbrk__td--num::after {
    content: "";
    position: absolute;
    top: calc(50% + 1.4rem);
    bottom: calc(-50% + 1.4rem);
    left: 50%;
    width: 2px;
    transform: translateX(-50%);
    background: repeating-linear-gradient(to bottom, var(--arb-teal) 0 3px, transparent 3px 6px);
    opacity: 0.95;
  }

  .acom-regbrk__row:nth-child(even) .acom-regbrk__td--num::after {
    background: repeating-linear-gradient(to bottom, var(--arb-gold) 0 3px, transparent 3px 6px);
  }

  .acom-regbrk__row:last-child .acom-regbrk__td--num::after {
    display: none;
  }

  .acom-regbrk__num {
    position: relative;
    z-index: 1;
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1rem;
  }

  .acom-regbrk__td--region {
    text-align: center;
    vertical-align: middle;
    padding-left: 0.8rem;
    padding-right: 0.8rem;
  }

  .acom-regbrk__td--region::after {
    width: 7.5rem;
    max-width: 100%;
    margin-bottom: 0.6rem;
  }

  .acom-regbrk__row:nth-child(2) .acom-regbrk__td--region::after { width: 7rem; }
  .acom-regbrk__row:nth-child(5) .acom-regbrk__td--region::after { width: 6rem; }

  .acom-regbrk__region-name {
    font-size: 1.1rem;
  }

  .acom-regbrk__td--status {
    vertical-align: middle;
    padding-left: 0.7rem;
    padding-right: 0.7rem;
  }

  .acom-regbrk__status {
    width: 100%;
    min-height: 10rem;
    align-content: center;
    padding: 0.9rem 0.55rem;
    font-size: 0.95rem;
  }

  .acom-regbrk__td--data,
  .acom-regbrk__td--activity,
  .acom-regbrk__td--sources {
    grid-column: auto;
    border-top: 0 !important;
  }

  .acom-regbrk__source-list li {
    min-height: 3rem;
    display: flex;
    align-items: center;
  }

  .acom-regbrk__source-list li::after {
    top: 50%;
    transform: translateY(-50%);
  }

  .acom-regbrk__source-list li:first-child::after {
    top: 50%;
  }

  .acom-regbrk__note {
    margin-top: 0.9rem;
    padding: 0.62rem 0.9rem;
    font-size: 0.82rem;
  }
}

/* At very wide article widths, allow breathing room without changing the
   table proportions. */
@media (min-width: 1280px) {
  .acom-regbrk__th {
    font-size: 0.88rem;
    padding: 0.9rem 1rem;
  }

  .acom-regbrk__td {
    font-size: 0.88rem;
    padding: 1.45rem 1.2rem;
  }
}

/* Print: preserve the editorial table rather than mobile cards. */
@media print {
  .acom-regbrk__scroll { overflow: visible; }
  .acom-regbrk__table { min-width: 0; box-shadow: none; }
}