/* ==========================================================================
   Festive offer accordion — layout 3c (independent expand cards)
   Solaire North · festive outlet listing
   /festive/<category>/<outlet>-christmas

   Scope: the offer listing only. Page banner, title and write-up come from
   the existing outlet-offer template and are not restyled here.

   Contract
   - One offer = one card = one menu.
   - Any number of cards may be open at once.
   - Reserve now lives on the offer row ONLY — never inside the menu panel.
   - The expand control is labelled "Learn more" in both states; the chevron
     carries the open/closed meaning.
   - Menu courses render in rows across three columns, no imagery.

   Mobile first: base rules target small screens; section 7 layers on
   overrides at 550px (large phone), 768px (tablet) and 1024px (desktop).
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tokens
   Values mirror the live theme. If these already exist globally, delete this
   block and keep the global ones — nothing below hardcodes a colour.
   -------------------------------------------------------------------------- */
.fa-list {
  --fa-ink: var(--foreground);
  --fa-body: var(--foreground);
  --fa-muted: var(--accent-foreground);
  --fa-gold: var(--accent-foreground);


  --fa-surface: var(--background);
  --fa-surface-alt: var(--accent-200);
  /* expanded panel + tinted fills */
  --fa-rule: var(--accent);
  /* card border */
  --fa-rule-soft: var(--accent-300);
  /* hairline between courses */
  --fa-rule-strong: var(--primary);
  /* menu top rule */

  --fa-cta-bg: var(--primary);
  /* Reserve now */
  --fa-cta-ink: var(--primary-foreground);
  --fa-toggle-bg: var(--accent-200);
  --fa-toggle-bg-hover: var(--accent-300);

  --fa-font-display: var(--text-serif);
  --fa-font-body: var(--text-sans);

  --fa-gap: 16px;
  /* between cards */
  --fa-scroll-offset: calc(var(--header-eyebrow-height, 0px) + var(--header-height, 0px) + 16px);
  /* clears the sticky header when Learn more scrolls to a menu */
  --fa-pad-x: 18px;
  --fa-pad-y: 20px;
  --fa-focus: var(--primary);
}

/* --------------------------------------------------------------------------
   2. List
   -------------------------------------------------------------------------- */
.fa-list {
  display: flex;
  flex-direction: column;
  gap: var(--fa-gap);
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--fa-font-body);
  color: var(--fa-body);
}

.fa-list__head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 4px;
}

.fa-list__title {
  margin: 0;
  font-family: var(--fa-font-display);
  font-weight: 400;
  font-size: var(--text-4xl);
  line-height: 1.15;
  color: var(--fa-ink);
}

.fa-list__rule {
  flex: 1;
  height: 1px;
  background: var(--fa-rule);
}

.fa-list__count {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #8b8781;
  white-space: nowrap;
}

/* --------------------------------------------------------------------------
   3. Card
   -------------------------------------------------------------------------- */
.fa-offer {
  border: 1px solid var(--fa-rule);
  background: var(--fa-surface);
}

.fa-offer__row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: start;
  padding: var(--fa-pad-y) var(--fa-pad-x);
}

.fa-offer__when {
  margin: 0 0 7px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--fa-gold);
}

.fa-offer__title {
  margin: 0 0 8px;
  font-family: var(--fa-font-sans);
  font-weight: 600;
  font-size: var(--text-lg);
  line-height: 1.15;
  color: var(--fa-ink);
}

.fa-offer__copy {
  margin: 0;
  font-weight: 300;
  line-height: 1.7;
  text-wrap: pretty;
}

.fa-offer__price {
  margin: 20px 0 0 !important;
  font-weight: 400;
  color: var(--fa-ink);
  font-size: var(--text-sm);
}

/* --------------------------------------------------------------------------
   4. Actions — Reserve now + Learn more toggle
   -------------------------------------------------------------------------- */
.fa-offer__actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

.fa-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  min-height: 44px;
  /* touch target */
  padding: 16px 18px;
  border: 0;
  border-radius: 0;
  font-family: inherit;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  line-height: normal;
}

/* Primary — the only booking action on the card */
.fa-btn--reserve {
  background: var(--fa-cta-bg);
  color: var(--fa-cta-ink);
}

.fa-btn--reserve:hover,
.fa-btn--reserve:focus-visible {
  background: #1d1c1a;
  color: var(--fa-cta-ink);
}

/* Expand toggle */
.fa-btn--toggle {
  background: var(--fa-toggle-bg);
  color: var(--fa-ink);
}

.fa-btn--toggle:hover {
  background: var(--fa-toggle-bg-hover);
}

.fa-btn:focus-visible {
  outline: 2px solid var(--fa-focus);
  outline-offset: 2px;
}

.fa-btn__chevron {
  width: 9px;
  height: 9px;
  flex: none;
  transition: transform .18s ease;
}

.fa-offer[data-open="true"] .fa-btn__chevron {
  transform: rotate(180deg);
}

/* --------------------------------------------------------------------------
   5. Menu panel
   Collapsed with hidden until JS runs; height is animated by the script via
   --fa-panel-h so the transition works without magic numbers.
   -------------------------------------------------------------------------- */
.fa-offer__panel {
  border-top: 1px solid var(--fa-rule-soft);
  background: var(--fa-surface-alt);
  overflow: hidden;
  /* read by the script as the resolved px offset */
  scroll-margin-top: var(--fa-scroll-offset);
}

.fa-offer__panel[hidden] {
  display: none;
}

/* animating state set by JS */
.fa-offer__panel.is-animating {
  height: var(--fa-panel-h, auto);
  transition: height .26s ease;
}

.fa-offer__panel-inner {
  padding: var(--fa-pad-y) var(--fa-pad-x) 28px;

}

.fa-menu__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 16px;

  p {
    margin: 0;
  }
}

.fa-menu__name {
  margin: 0;
  font-family: var(--fa-font-body);
  font-weight: 400;
  font-size: 22px;
  line-height: 1.2;
  color: var(--fa-ink);
  margin-top: 0 !important;

}

.fa-menu__action {
  margin-left: auto;

  .btn-text {
    font-size: var(--text-xs);
  }
}

.fa-menu__note {
  font-size: var(--text-xs);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--fa-muted);
  white-space: nowrap;
}

.fa-menu__rule {
  display: none;
  flex: 1;
  height: 1px;
  background: #e2dacb;
}

/* Courses in rows, three columns, no imagery */
.fa-menu__courses {
  display: grid;
  grid-template-columns: 1fr;
  column-gap: 32px;
  margin: 0;
  padding: 1rem 0;
  list-style: none;
  border-top: 1px solid var(--fa-rule-strong);
  padding-left: 0 !important;
}

.fa-menu__course {
  padding: 11px 0;
  font-weight: 300;
  font-size: var(--text-sm);
  line-height: 1.5;
  color: var(--fa-body);
  margin: 5px 0 !important;
}

/* Detailed variant — each course has a title + description.
   Items sit side by side in the same 1/2/3 column grid; subgrid keeps every
   title and every description in a row on a shared baseline, however long
   the copy runs. */
.fa-menu__courses--detailed {
  display: block;
  padding-left: 0 !important;
}

.fa-menu__courses--detailed .fa-menu__course {
  display: grid;
  grid-row: span 2;
  grid-template-rows: subgrid;
  row-gap: 4px;
  align-content: start;
  /* padding: 16px 0; */
  border-bottom: 1px solid var(--fa-rule-soft);
  margin: 1rem 0;
  padding: 0;
}

.fa-menu__course-title {
  margin: 0 !important;
  font-weight: 600;
  font-size: var(--text-base);
  font-family: var(--text-sans);
  line-height: 1.4;
  color: var(--fa-ink);
}

.fa-menu__course-desc {
  margin: 0;
  font-weight: 300;
  font-size: var(--text-sm);
  line-height: 1.6;
  color: var(--fa-body);
  text-wrap: pretty;
}

/* Optional footnote (allergens, service charge, "menu subject to change") */
.fa-menu__note-foot {
  margin: 18px 0 0;
  font-weight: 300;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--fa-muted);
}

/* --------------------------------------------------------------------------
   6. PDF variant — same card, menu supplied as a file (layout 3e)
   Drop .fa-offer__panel-inner content for a .fa-menu--pdf block instead.
   -------------------------------------------------------------------------- */
.fa-menu--pdf {
  display: flex;
  flex-direction: column;
  gap: 26px;
  align-items: stretch;
  max-width: 720px;
  padding: 20px;
  border: 1px solid #e6dfd0;
  background: var(--fa-surface);
}

.fa-menu__thumb {
  flex: none;
  width: 100%;
  height: 120px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--fa-rule);
  background: var(--fa-surface-alt);
  font-size: 9.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #8b8781;
}

.fa-menu__file {
  margin: 0;
  font-weight: 300;
  font-size: 13.5px;
  line-height: 1.6;
}

.fa-menu__file-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
  padding-top: 18px;
}

.fa-btn--ghost {
  background: transparent;
  color: var(--fa-ink);
  box-shadow: inset 0 0 0 1px var(--fa-ink);
}

.fa-btn--quiet {
  background: transparent;
  color: var(--fa-muted);
  box-shadow: inset 0 0 0 1px var(--fa-rule);
}

.fa-offer__image {
  >* {
    height: 100%;
    width: 100%;
    object-fit: cover;
    display: block;
  }
}



/* --------------------------------------------------------------------------
   7. Responsive — mobile first
   -------------------------------------------------------------------------- */

/* Large phone — 550px and up */
@media (min-width: 550px) {
  .fa-offer__actions {
    /* flex-direction: row; */
    align-items: center;
  }

  .fa-btn {
    width: auto;
    padding: 13px 22px;
  }

  .fa-btn--toggle {
    padding: 13px 18px;
  }

  .fa-menu--pdf {
    flex-direction: row;
  }

  .fa-menu__thumb {
    flex: 0 0 116px;
    width: auto;
    height: 150px;
  }

  .fa-menu__file-actions {
    flex-direction: row;
  }

  /* image column only when the card has an image */
  .fa-offer__row:has(.fa-offer__image) {
    grid-template-columns: 10rem 1fr;
  }

  .fa-offer__image {
    align-self: flex-end;


  }
}

/* Tablet — 768px and up */
@media (min-width: 768px) {
  .fa-list {
    --fa-pad-x: 26px;
    --fa-pad-y: 24px;
  }

  .fa-offer__row {
    gap: 28px;
    align-items: end;
  }

  .fa-offer__title {
    font-size: var(--text-xl);
  }

  .fa-menu__courses {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fa-menu__head {
    flex-wrap: nowrap;
  }

  .fa-menu__rule {
    display: block;
  }
}

/* Desktop — 1024px and up */
@media (min-width: 1024px) {

  .fa-offer__row {
    grid-template-columns: 1fr auto;
  }

  .fa-offer__row:has(.fa-offer__image) {
    grid-template-columns: 15rem 1fr auto;
  }

  .fa-menu__courses {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* --------------------------------------------------------------------------
   8. Motion + print
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {

  .fa-offer__panel.is-animating,
  .fa-btn__chevron {
    transition: none;
  }
}

@media print {
  .fa-offer__panel[hidden] {
    display: block !important;
  }

  /* print all menus */
  .fa-offer__actions,
  .fa-btn {
    display: none !important;
  }

  .fa-offer {
    break-inside: avoid;
    border-color: #ccc;
  }
}

/* --------------------------------------------------------------------------
   9. No-JS fallback
   Add class="no-js" to <html> and remove it in an inline head script.
   Panels stay open so menus are always readable.
   -------------------------------------------------------------------------- */
.no-js .fa-offer__panel[hidden] {
  display: block;
}

.no-js .fa-btn--toggle {
  display: none;
}


div:has(.fa-list) div:has(> .cta.cta-reservenow) {
  display: none;
}