/* ============================================================
   COMPONENTS — pieces shared by several pages:
   meta row, buttons, credit, Motion note.
   ============================================================ */

/* Meta row (the small line above the title in the menu card) */
.meta {
  display: flex; align-items: center; gap: 20px; min-height: 44px;
  font-size: var(--fs-meta); letter-spacing: .05em; text-transform: uppercase;
}

/* Dark button (Get in touch…): the display face at full weight for its pull,
   kept small (14px, 48px tall) so it sits with the headings and text rather than shouting */
.btn {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 48px; padding: 0 20px 0 22px;
  background: var(--dark); color: var(--light); border-radius: 8px; text-decoration: none;
  font-family: var(--display); font-weight: var(--bold); font-stretch: 105%; font-size: 14px;
  letter-spacing: .04em; text-transform: uppercase;
  transition: color .2s;
}
.btn svg { width: 9px; height: 10px; flex-shrink: 0; }
/* Hover colours only where there is a real pointer: on phones a tapped button would otherwise
   stay orange (iOS keeps the hover state after a tap) */
@media (hover: hover) { .btn:hover { color: var(--accent); } }

/* ---- Credit: "Team Lobigs 2026", centred at the bottom of the main pages.
   Kept close to the content, so it reads as a sign-off rather than a footer. */
.credit {
  margin: 36px 0 0; text-align: center; font-size: var(--fs-meta); line-height: 1.6;
  letter-spacing: .05em; text-transform: uppercase; color: var(--grey-ink);
}
.credit span, .credit a { white-space: nowrap; }
.credit a { color: inherit; text-decoration: none; transition: color .2s; }
@media (hover: hover) { .credit a:hover { color: var(--accent-ink); } }
/* the links line under the credit (Terms · Privacy), close under it */
.credit.credit-links { margin-top: 6px; }
@media (min-width: 768px) and (min-height: 501px), (min-width: 768px) and (pointer: fine) {
  .credit { margin-top: 44px; }
  .page:has(.credit) { padding-bottom: 44px; }   /* the same space below as above */
}


/* ============================================================
   MOTION — the note (partials/motion.njk, motion.js), on every page.
   "Motion": a word after Terms and Privacy in the menu, and a word after them in the credit line.
   The note: a light card over a dimmed page — centred on desktop, rising from the bottom on phones —
   with one switch that pauses every animation.
   ============================================================ */
.mo-btn[hidden], .mo-sep[hidden] { display: none; }
.menu-social .mo-btn {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0; border: 0; cursor: pointer;
  background: none; color: var(--grey-on-dark); font: inherit; font-size: var(--fs-label); letter-spacing: var(--track); text-transform: uppercase;
  transition: color .2s;
}
.menu-social .mo-btn:hover { color: var(--light); }
.menu-social .mo-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }
.credit .mo-btn { padding: 0; border: 0; background: none; cursor: pointer; white-space: nowrap;
  font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit; transition: color .2s; }
@media (hover: hover) { .credit .mo-btn:hover { color: var(--accent-ink); } }
.credit .mo-btn:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 2px; border-radius: 2px; }

.mo-dlg { width: min(460px, calc(100% - 32px)); max-width: none; padding: 0; border: 0; border-radius: var(--card-r); color: var(--dark);
  background: var(--card-sheen), var(--card); box-shadow: 0 24px 60px -20px rgba(38,38,38,.45); }
.mo-dlg::backdrop { background: rgba(38,38,38,.4); }
.mo-dlg[open] { animation: mo-in .25s cubic-bezier(.2, .7, .2, 1); }
@keyframes mo-in { from { opacity: 0; transform: translateY(8px); } }
.mo-body { position: relative; display: grid; gap: 14px; padding: 28px; }
.mo-body:focus { outline: none; }
.mo-title { margin: 0; padding-right: 40px; font-family: var(--display); font-weight: var(--bold); font-stretch: var(--stretch-section); text-transform: uppercase; font-size: var(--fs-heading); }
.mo-text { margin: 0; font-size: var(--fs-body); line-height: 1.6; }
.mo-close { position: absolute; top: 20px; right: 20px; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 8px; cursor: pointer;
  background: var(--inset); color: var(--dark); box-shadow: var(--inner-shadow); transition: color .2s; }
.mo-close svg { width: 16px; height: 16px; display: block; }
@media (hover: hover) { .mo-close:hover { color: var(--accent-ink); } }
.mo-close:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 2px; }
.mo-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--card-rule); }
.mo-row label { font-size: var(--fs-body); font-weight: 600; cursor: pointer; }
.mo-switch { position: relative; flex: none; width: 46px; height: 28px; padding: 0; border: 0; border-radius: 14px; cursor: pointer;
  background: var(--inset); box-shadow: inset 0 0 0 1px rgba(38,38,38,.14); transition: background .2s, box-shadow .2s; }
.mo-switch::after { content: ""; position: absolute; top: 4px; left: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--dark); transition: transform .2s var(--ease), background .2s; }
.mo-switch[aria-checked="true"] { background: var(--dark); box-shadow: none; }
.mo-switch[aria-checked="true"]::after { transform: translateX(18px); background: var(--light); }
.mo-switch:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 2px; }
@media (max-width: 767px), (max-height: 500px) and (pointer: coarse) {
  .mo-dlg { width: 100%; margin: auto 0 0; border-radius: 14px 14px 0 0; }
  .mo-dlg[open] { animation-name: mo-up; }
  @keyframes mo-up { from { transform: translateY(100%); } }
  .mo-body { padding: 26px max(24px, env(safe-area-inset-right)) calc(28px + env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); }
}
@media (prefers-reduced-motion: reduce) { .mo-dlg[open] { animation: none; } .mo-switch, .mo-switch::after { transition: none; } }
