/* Local layout fixes for the ticket shop
   ------------------------------------------------------------------ */

/* 1. Long product names (VriendenLoterij VIP-kaart, European Youth Card)
      pushed the quantity control past the card border between ~1200 and
      ~1400px. The text block could not shrink (flex items default to
      min-width:auto), so the fixed-width input group overflowed. */
/* The +/- control stays on the first line, top right, on every card — it must
   never drop to a second line on some cards and not others. */
.pre-choice-tickets .card-body {
    flex-wrap: nowrap;
}

.pre-choice-tickets .card-body-content {
    flex: 1 1 auto;
    /* no min-width:0 — the text block stays at least as wide as its longest
       word, so names never break mid-word ("Museumkaar/t") */
}

.pre-choice-tickets .amount-fieldset {
    flex: 0 0 auto;        /* control keeps its size, never gets squeezed out */
    width: auto;
    flex-wrap: nowrap;
    margin-left: auto;     /* pinned to the right edge on every card */
}

/* Between 1200 and 1400px the page container is 1140px, which leaves only
   ~260px inside a card. The longest name ("VriendenLoterij", 154px) plus the
   full-size 128px control did not fit, so the control slid past the border.
   Make the control compact in exactly that band — everywhere else it keeps
   its normal size. */
@media (min-width: 1200px) and (max-width: 1399.98px) {
    .pre-choice-tickets .amount-fieldset .btn {
        width: 1.875rem;
        padding-left: 0;
        padding-right: 0;
    }

    .pre-choice-tickets .amount-fieldset .input-amount {
        width: 2.125rem;
        flex: 0 0 2.125rem;
        padding-left: .125rem;
        padding-right: .125rem;
        text-align: center;
    }
}

/* 2. The cart column is aligned to the top of the left column, which starts
      with a heading ("Maak je keuze") or a back button. That left the cart
      box floating above the first box on the left. layout-fixes.js measures
      the offset and sets --cart-offset; this applies it on wide screens only,
      where the two columns actually sit side by side. */
@media (min-width: 1200px) {
    #offcanvasCart {
        margin-top: var(--cart-offset, 0px);
    }
}
