/* =====================================================================
   Section — D - Content Breakout Module (Figma 10159:3694)
   Intro heading + body/list on the left, live-price stats panel on the
   right (Ounce / Gram / Kilo: label · price · change + up/down arrow).
   Desktop target: 1240 content area inside .container @ 1440 frame.
   Tokens only. BEM, all classes prefixed `breakout`.
   ===================================================================== */

/* Full-bleed dark band; the gradient spans the whole viewport width while the
   content stays locked to the 1240 .container inside. */
.breakout {
  padding-block: clamp(40px, 5.5vw, 80px);
  color: var(--gray-0);
  /* black → deep navy, left-leaning to match the node */
  background-image: linear-gradient(
    to left,
    var(--gray-8) 0%,
    var(--breakout-grad-dark) 100%
  );
}

/* Inner content row, locked to the 1240 content area. */
.breakout__band {
  display: flex;
  align-items: center;
  gap: clamp(24px, 3vw, 40px);
}

/* ---- Left: intro content ---- */
.breakout__content {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.breakout__heading {
  margin: 0;
  font-size: var(--fs-32);
  font-weight: var(--fw-medium);
  line-height: var(--lh-45);
}
.breakout__body { margin: 0; }
.breakout__para {
  margin: 0 0 20px;
  font-size: var(--fs-16);
  font-weight: var(--fw-regular);
  line-height: 1.25;
}
.breakout__list {
  list-style: disc;
  margin: 0;
  padding-left: 22px;
}
.breakout__list-item {
  font-size: var(--fs-14);
  font-weight: var(--fw-regular);
  line-height: 1.5;
}

/* ---- Right: live-price stats panel ---- */
.breakout__panel {
  flex: none;
  width: 500px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 15px;
  padding: 25px;
  border: 1px solid var(--og-blue);
  border-radius: var(--radius-8);
  /* angled black → dusty-blue, mirrors the band but tighter */
  background-image: linear-gradient(
    -73deg,
    var(--gray-8) 1%,
    var(--dusty-blue) 100%
  );
}

.breakout__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 10px;
}
.breakout__row--head {
  font-size: var(--fs-14);
  font-weight: var(--fw-semibold);
}

/* 3-column grid: label / price / change */
.breakout__label  { flex: 1 1 0; min-width: 0; }
.breakout__price  { flex: none; width: 119px; text-align: right; }
.breakout__change {
  flex: none;
  width: 95px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
}

/* head labels align with the data columns. The head cells carry localized
   column titles ("Gold Change" -> de "Goldveränderung", it "Variazione
   dell'oro") that are wider than the 95px data column, so let the head
   change/price size to content (95px floor) and wrap instead of clip. */
.breakout__row--head .breakout__price  { width: auto; white-space: nowrap; }
.breakout__row--head .breakout__change {
  width: auto;
  min-width: 95px;
  justify-content: flex-end;
  text-align: right;
}

/* data-row cells */
.breakout__row:not(.breakout__row--head) .breakout__label,
.breakout__row:not(.breakout__row--head) .breakout__price,
.breakout__row:not(.breakout__row--head) .breakout__delta {
  font-size: var(--fs-12);
  font-weight: var(--fw-regular);
}

.breakout__delta { white-space: nowrap; text-align: right; }
.breakout__delta--up   { color: var(--green); }
.breakout__delta--down { color: var(--red); }

/* Single triangle asset, tinted + rotated by direction
   (reuses the header price-arrow mask technique). */
.breakout__arrow {
  flex: none;
  width: 12px;
  height: 6px;
  -webkit-mask: url("../../img/price-arrow.svg") no-repeat center / contain;
          mask: url("../../img/price-arrow.svg") no-repeat center / contain;
}
.breakout__arrow--up   { background-color: var(--green); }
.breakout__arrow--down { background-color: var(--red); transform: rotate(180deg); }

/* =====================================================================
   Responsive — desktop priority, graceful down to 1100 / 768 / 390.
   ===================================================================== */
/* bespoke: the band stacks at <=1100 (NOT the canonical 1023.98) — the 2-col
   text|panel layout needs >=1100 width. This matches main; migrating to 1023.98
   would un-stack the band at 1024-1100 (a desktop-range regression). */
@media (max-width: 1100px) {
  .breakout__band {
    flex-direction: column;
    align-items: stretch;
    gap: 32px;
  }
  .breakout__panel { width: 100%; }
}

/* =====================================================================
   Mobile — M - Content Breakout Module (Figma 10159:4410) 390-wide.
   Single column: intro heading + body + bulleted list stacked, THEN the
   live-price panel full width below. Band padding 40px 15px, gap 20px.
   Heading 26/36. Panel padding 25px, gap 15px; head row 11px, data 10px.
   New tokens reported: --fs-26, --lh-36, --fs-11, --fs-10.
   ===================================================================== */
@media (max-width: 767.98px) {
  .breakout { padding-block: 40px; }
  .breakout__band {
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
  }
  .breakout__content { gap: 20px; }
  .breakout__heading { font-size: 26px; line-height: 36px; }
  .breakout__para { margin-bottom: 0; }
  .breakout__list { padding-left: 24px; }

  .breakout__panel {
    width: 100%;
    gap: 15px;
    padding: 25px;
  }

  /* head row → 11px, data cells → 10px (per M- panel) */
  .breakout__row--head { font-size: 11px; }
  .breakout__row:not(.breakout__row--head) .breakout__label,
  .breakout__row:not(.breakout__row--head) .breakout__price,
  .breakout__row:not(.breakout__row--head) .breakout__delta {
    font-size: 10px;
  }

  /* tighten the fixed data columns so all three fit at 360 */
  .breakout__label  { flex: 1 1 auto; }
  .breakout__price  { width: auto; }
  .breakout__change { width: auto; }
  .breakout__row--head .breakout__change { width: auto; }
}

/* bespoke: 480px is intentional — preserves the <=599 render. Do NOT migrate to
   599.98 (that changes panel padding at 481-599 from 25px to 20px = regression). */
@media (max-width: 480px) {
  .breakout__heading { font-size: 26px; line-height: 1.25; }
  .breakout__panel { padding: 20px; }
  .breakout__price { width: auto; }
}
