/**
 * Phone-only stacked cards for Sample Days / Mag schedule & money tables.
 * Desktop / print keep normal table layout (JS removes mm-as-cards above 720px).
 */
@media (max-width: 720px) {
  table.mm-as-cards,
  table.mm-table-cards {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0 !important;
    border-collapse: separate;
    border-spacing: 0;
    overflow: visible;
  }

  table.mm-as-cards thead,
  table.mm-table-cards thead {
    display: none;
  }

  table.mm-as-cards tbody,
  table.mm-table-cards tbody {
    display: block;
  }

  table.mm-as-cards tr,
  table.mm-table-cards tr {
    display: block;
    margin: 0 0 10px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid rgba(11, 61, 74, 0.12);
    border-radius: 10px;
  }

  table.mm-as-cards td,
  table.mm-table-cards td {
    display: block;
    padding: 4px 0 !important;
    border: none !important;
    width: auto !important;
    white-space: normal !important;
  }

  table.mm-as-cards td::before,
  table.mm-table-cards td::before {
    content: attr(data-label);
    display: block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #0b6e7a;
    margin-bottom: 2px;
  }

  /* Shop timing: never force 560px when cards are active */
  .dm-shop-timing.mm-as-cards,
  .dm-shop-timing.mm-table-cards {
    min-width: 0 !important;
  }

  .dm-shop-timing-wrap:has(table.mm-as-cards),
  .dm-shop-timing-wrap:has(table.mm-table-cards) {
    overflow-x: visible;
  }

  /* Prefer cards over legacy horizontal-scroll treatment */
  .dm-sched.mm-as-cards,
  .dm-money.mm-as-cards {
    display: block;
    overflow: visible;
    -webkit-overflow-scrolling: auto;
  }
}

/* Explicit skip: keep wide table + scroll wrap (rare) */
.dm-shop-timing.mm-skip-cards {
  min-width: 560px;
  display: table;
}
