/* ==========================================================================
   MakeAVacation motion — v6 "Springy" (rebuilt from scratch 2026-11-28)

   Personality: playful and springy, scaled by how often you see it.
     frequent   — nav, menus, hovers, presses ...... snappy spring (90% in ~160ms)
     occasional — search, island, modals, toast ..... bouncy spring (~8% overshoot)
     rare       — like, save, add-to-trip, 1st visit  pop spring (~23%) + delight

   House rules (Emil Kowalski / Apple fluid-interface guidelines):
   - Springs are real physics: generated from response + damping ratio and
     written as CSS linear() curves. Opacity never springs (--fade).
   - Only transform-type properties and opacity move (the island's width is
     the one exception). Uses the individual translate / scale / rotate
     properties so motion never clobbers a component's own transform.
   - Interruptible: transitions (+ @starting-style) for anything you can
     toggle; keyframes only for one-shot entrances.
   - Press is asymmetric: squish in 90ms, spring back out.
   - Every movement is gated on html.mav-motion, which is never set under
     prefers-reduced-motion — those visitors get the static site.
   - Tab content never animates (core navigation); the nav glider carries it.
   Loaded LAST, after polish.css, so it is the single source of motion.
   ========================================================================== */

:root {
  /* press: button release: quick squish-back with a small boing (overshoot 12.6%) */
  --sp-press: linear(0, 0.0378, 0.1344, 0.2667, 0.4155, 0.5655, 0.7057, 0.8286, 0.9302, 1.0091, 1.0656, 1.102, 1.1211, 1.1263, 1.121, 1.1084, 1.0915, 1.0727, 1.0538, 1.0362, 1.0208, 1.0081, 0.9984, 0.9914, 0.9869, 0.9846, 0.9841, 0.9848, 0.9864, 0.9886, 0.991, 0.9933, 0.9956, 0.9975, 0.9991, 1.0003, 1.0011, 1.0017, 1.002, 1.002, 1.0019, 1.0017, 1.0014, 1.0011, 1);
  --sp-press-d: 570ms;
  /* snappy: frequent UI: menus, indicators, hover lifts, caret (overshoot 1.1%) */
  --sp-snappy: linear(0, 0.0173, 0.0621, 0.1254, 0.2001, 0.2804, 0.3623, 0.4426, 0.5191, 0.5903, 0.6554, 0.7139, 0.7657, 0.8109, 0.8499, 0.8831, 0.911, 0.9341, 0.953, 0.9683, 0.9804, 0.9898, 0.997, 1.0023, 1.006, 1.0085, 1.0101, 1.0109, 1.0111, 1.0109, 1.0104, 1.0097, 1.0088, 1.0079, 1.007, 1.0061, 1.0053, 1.0045, 1.0038, 1.0031, 1.0026, 1.0021, 1.0016, 1.0013, 1);
  --sp-snappy-d: 440ms;
  /* bouncy: occasional: island, modals, toast, results, mobile menu (overshoot 8.4%) */
  --sp-bouncy: linear(0, 0.0249, 0.0899, 0.1817, 0.2893, 0.4035, 0.5172, 0.6252, 0.7237, 0.8105, 0.8844, 0.9451, 0.9932, 1.0294, 1.0551, 1.0716, 1.0806, 1.0835, 1.0817, 1.0765, 1.0689, 1.06, 1.0505, 1.041, 1.0319, 1.0236, 1.0163, 1.01, 1.0049, 1.0008, 0.9977, 0.9955, 0.9941, 0.9933, 0.993, 0.9932, 0.9936, 0.9942, 0.9949, 0.9957, 0.9965, 0.9973, 0.998, 0.9986, 1);
  --sp-bouncy-d: 690ms;
  /* pop: rare feedback: heart, saved, check, trip badge (overshoot 23.4%) */
  --sp-pop: linear(0, 0.055, 0.1949, 0.3837, 0.589, 0.7851, 0.9538, 1.0845, 1.1731, 1.221, 1.2335, 1.2184, 1.1843, 1.1395, 1.0915, 1.0462, 1.0075, 0.9779, 0.9581, 0.9478, 0.9455, 0.9496, 0.9579, 0.9685, 0.9797, 0.9902, 0.999, 1.0057, 1.0101, 1.0123, 1.0127, 1.0116, 1.0096, 1.0071, 1.0045, 1.0021, 1.0001, 0.9985, 0.9976, 0.9971, 0.997, 0.9973, 0.9978, 0.9984, 1);
  --sp-pop-d: 930ms;
  /* smooth: no overshoot: hero text, skeletons (overshoot 0.0%) */
  --sp-smooth: linear(0, 0.0196, 0.0684, 0.1345, 0.2094, 0.2874, 0.3645, 0.4382, 0.507, 0.5701, 0.6271, 0.678, 0.7231, 0.7627, 0.7973, 0.8274, 0.8534, 0.8757, 0.8949, 0.9113, 0.9252, 0.9371, 0.9472, 0.9557, 0.9629, 0.969, 0.9741, 0.9783, 0.9819, 0.985, 0.9875, 0.9896, 0.9913, 0.9928, 0.994, 0.995, 0.9959, 0.9966, 0.9972, 0.9977, 0.9981, 0.9984, 0.9987, 0.9989, 1);
  --sp-smooth-d: 670ms;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --fade: 180ms;
  --island: #000;
  --dur-press: 90ms; /* legacy name used by older base rules */
}
@supports not (transition-timing-function: linear(0, 1)) {
  :root {
    --sp-press: cubic-bezier(.3, 1.6, .5, 1);   --sp-snappy: cubic-bezier(.25, 1.05, .4, 1);
    --sp-bouncy: cubic-bezier(.3, 1.4, .5, 1);  --sp-pop: cubic-bezier(.3, 1.9, .45, 1);
    --sp-smooth: cubic-bezier(.23, 1, .32, 1);
  }
}

/* ===== 0. Resting values ===================================================
   translate / scale / rotate only interpolate number-to-number: going back to
   `none` snaps instead of springing. Everything we move gets an explicit rest. */
.mav-motion :is(.btn-primary, .btn-secondary, .btn-outline, .btn-remove, .btn-add-trip, .btn-book, .btn-go,
  .btn-back, .btn-danger, .budget-chip, .nl-tool, .shop-qtab, .shop-chip, .agent-act, .admin-nav-btn, .admin-btn,
  .acc-filter-btn, .acc-buy-btn, .trip-action-btn, .stay-add, .flt-addtrip, .donate-amt, .donate-submit, .df-opt,
  .trip-empty-btn, .suggestion, .save-search-btn, .disc-btn, .food-chip, .food-more-btn, .food-toggle, .flt-cancel,
  .flt-pill, .flt-book, .acct-quick-btn, .wx-save, .wx-chip-go, .wizard-chip, .tab-donate-btn, .auth-signin-btn,
  .auth-chip, .nl-signup-btn, .nl-send, .hw-search, .hw-tab, .hp-btn, .xgo, .xds-map, .xds-cat, .hint-chip,
  .ai-save-btn, .trn-book, .pc-heart, .hamburger, .lightbox-nav,
  .home-card, .photo-card, .xds-card, .cruise-card, .flt-gear-card, .home-ico, .cruise-card em, .flt-gear-btn,
  .mav-word, .home-widget, .hw-field, .stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card,
  .fish-card, .acc-card, .flt-modal, .auth-modal, .wizard-question, .nav-caret, .mi-check, .mi-warn, .mav-ls-pill) {
  translate: 0 0; scale: 1; rotate: 0deg;
}

/* ===== 1. Press: squish in fast, spring back out ========================== */
.mav-motion :is(.btn-primary, .btn-secondary, .btn-outline, .btn-remove, .btn-add-trip, .btn-book, .btn-go,
  .btn-back, .btn-danger, .budget-chip, .nl-tool, .shop-qtab, .shop-chip, .agent-act, .admin-nav-btn, .admin-btn,
  .acc-filter-btn, .acc-buy-btn, .trip-action-btn, .stay-add, .flt-addtrip, .donate-amt, .donate-submit, .df-opt,
  .trip-empty-btn, .suggestion, .save-search-btn, .disc-btn, .food-chip, .food-more-btn, .food-toggle, .flt-cancel,
  .flt-pill, .flt-book, .acct-quick-btn, .wx-save, .wx-chip-go, .wizard-chip, .tab-donate-btn, .auth-signin-btn,
  .auth-chip, .nl-signup-btn, .nl-send, .hw-search, .hw-tab, .hp-btn, .xgo, .xds-map, .xds-cat, .hint-chip,
  .ai-save-btn, .trn-book, .pc-heart, .hamburger, .lightbox-nav) {
  transition: scale var(--sp-press-d) var(--sp-press), background-color .15s ease, color .15s ease,
    border-color .15s ease, box-shadow .2s ease, opacity .15s ease, filter .15s ease;
}
.mav-motion :is(.btn-primary, .btn-secondary, .btn-outline, .btn-remove, .btn-add-trip, .btn-book, .btn-go,
  .btn-back, .btn-danger, .budget-chip, .nl-tool, .shop-qtab, .shop-chip, .agent-act, .admin-nav-btn, .admin-btn,
  .acc-filter-btn, .acc-buy-btn, .trip-action-btn, .stay-add, .flt-addtrip, .donate-amt, .donate-submit, .df-opt,
  .trip-empty-btn, .suggestion, .save-search-btn, .disc-btn, .food-chip, .food-more-btn, .food-toggle, .flt-cancel,
  .flt-pill, .flt-book, .acct-quick-btn, .wx-save, .wx-chip-go, .wizard-chip, .tab-donate-btn, .auth-signin-btn,
  .auth-chip, .nl-signup-btn, .nl-send, .hw-search, .hw-tab, .hp-btn, .xgo, .xds-map, .xds-cat, .hint-chip,
  .ai-save-btn, .trn-book, .pc-heart, .hamburger, .lightbox-nav):active:not(:disabled) {
  scale: .95;
  transition: scale 90ms var(--ease-out), background-color .15s ease, color .15s ease,
    border-color .15s ease, box-shadow .2s ease, opacity .15s ease, filter .15s ease;
}
/* wide buttons squish less, round icon buttons more */
.mav-motion :is(.btn-primary, .donate-submit, .hw-search, .flt-book, .nl-send):active:not(:disabled) { scale: .975; }
.mav-motion :is(.xgo, .pc-heart, .hamburger, .lightbox-nav):active:not(:disabled) { scale: .88; }
/* base CSS nudged a couple of these down 1px on press; the squish replaces it */
.mav-motion :is(.btn-primary, .donate-submit):active { transform: none; }

/* ===== 2. Hover: clickable cards float on a spring ======================== */
.mav-motion :is(.home-card, .photo-card, .xds-card, .cruise-card, .flt-gear-card) {
  transition: translate var(--sp-snappy-d) var(--sp-snappy), scale var(--sp-press-d) var(--sp-press),
    box-shadow .25s ease, border-color .2s ease;
}
.mav-motion :is(.home-card, .photo-card, .xds-card, .cruise-card, .flt-gear-card):hover { transform: none; }
@media (hover: hover) and (pointer: fine) {
  .mav-motion :is(.home-card, .photo-card, .xds-card, .cruise-card):hover { translate: 0 -5px; }
  .mav-motion .flt-gear-card:hover { translate: 0 -3px; }
  /* the tool icon hops: the one playful flourish on the landing page */
  .mav-motion .home-card:hover .home-ico { translate: 0 -3px; scale: 1.12; rotate: -7deg; }
  .mav-motion :is(.cruise-card, .flt-gear-card):hover :is(em, .flt-gear-btn) { translate: 4px 0; }
}
.mav-motion :is(.home-card, .photo-card, .xds-card, .cruise-card):active {
  scale: .98;
  transition: translate var(--sp-snappy-d) var(--sp-snappy), scale 90ms var(--ease-out), box-shadow .25s ease, border-color .2s ease;
}
.mav-motion .home-ico {
  transition: translate var(--sp-pop-d) var(--sp-pop), scale var(--sp-pop-d) var(--sp-pop),
    rotate var(--sp-pop-d) var(--sp-pop), background-color .2s ease;
}
.mav-motion :is(.cruise-card em, .flt-gear-btn) { transition: translate var(--sp-snappy-d) var(--sp-snappy); }
/* result lists: you sweep across dozens of these — tint only, never lift */
.mav-motion :is(.stay-card, .flt-card, .forecast-fish-card):hover { transform: none; }
.mav-motion :is(.camp-card, .fish-card, .trail-card) { transition: border-color 150ms ease; }

/* ===== 3. Desktop nav: dropdowns pop out of their button ================== */
@media (min-width: 1201px) {
  .mav-motion .nav-group-menu {
    transform-origin: 2.4rem -6px;
    opacity: 0; scale: .94; translate: 0 -6px;
    transition: opacity 120ms var(--ease-out), scale 140ms var(--ease-out), translate 140ms var(--ease-out),
      display 140ms allow-discrete;
  }
  .mav-motion .nav-group.open .nav-group-menu {
    opacity: 1; scale: 1; translate: 0 0;
    transition: opacity 150ms var(--ease-out), scale var(--sp-snappy-d) var(--sp-snappy),
      translate var(--sp-snappy-d) var(--sp-snappy), display 0s allow-discrete;
  }
  @starting-style {
    .mav-motion .nav-group.open .nav-group-menu { opacity: 0; scale: .94; translate: 0 -6px; }
  }
  /* caret flips with a little wobble */
  .mav-motion .nav-caret { transition: rotate var(--sp-bouncy-d) var(--sp-bouncy); }
  .mav-motion .nav-group.open .nav-caret { transform: none; rotate: 180deg; }

  /* hover pill glides between top-bar items (positioned by motion.js) */
  .topnav-links.has-pill { position: relative; }
  .mav-navpill {
    position: absolute; top: 50%; left: 0; height: 42px; width: 0; margin-top: -21px;
    border-radius: 999px; background: var(--surface-3, #e9ecf4); pointer-events: none; opacity: 0; z-index: 0;
    transition: translate var(--sp-snappy-d) var(--sp-snappy), width var(--sp-snappy-d) var(--sp-snappy), opacity 150ms ease;
  }
  .mav-navpill.on { opacity: 1; }
  .mav-navpill.instant { transition: opacity 150ms ease; }
  .topnav-links.has-pill .nav-group-btn { position: relative; z-index: 1; }

  /* the glider replaces the static active underline */
  .topnav-links.has-line .nav-group.active-group > .nav-group-btn::after { opacity: 0; }
}
@media (min-width: 1201px) and (hover: hover) {
  .topnav-links.has-pill .nav-group-btn:hover { background: transparent; }
  /* menu rows: an arrow slides in */
  .mav-motion .nav-group-menu .tab { position: relative; padding-right: 2.2rem; }
  .mav-motion .nav-group-menu .tab::after {
    content: "→"; position: absolute; right: 1rem; top: 50%; transform: translateY(-50%);
    opacity: 0; translate: -6px 0;
    transition: opacity 120ms var(--ease-out), translate var(--sp-snappy-d) var(--sp-snappy);
  }
  .mav-motion .nav-group-menu .tab:hover::after { opacity: 1; translate: 0 0; }
}

/* ===== 4. Mobile / tablet menu: the panel drops on a spring =============== */
@media (max-width: 1200px) {
  .mav-motion .topnav-links {
    transform-origin: top center;
    opacity: 0; translate: 0 -12px; scale: .98;
    transition: opacity 140ms var(--ease-out), translate 160ms var(--ease-out), scale 160ms var(--ease-out),
      display 160ms allow-discrete;
  }
  .mav-motion .topnav-links.open {
    opacity: 1; translate: 0 0; scale: 1;
    transition: opacity 160ms var(--ease-out), translate var(--sp-bouncy-d) var(--sp-bouncy),
      scale var(--sp-bouncy-d) var(--sp-bouncy), display 0s allow-discrete;
  }
  @starting-style {
    .mav-motion .topnav-links.open { opacity: 0; translate: 0 -12px; scale: .98; }
  }
  .topnav-links .mav-glide, .mav-navpill { display: none; }
}
.mav-motion .hamburger span { transition: transform var(--sp-bouncy-d) var(--sp-bouncy), opacity 150ms ease; }

/* ===== 5. Account menu: pops out of the avatar (top-right origin) ========= */
.mav-motion .auth-dropdown {
  transform-origin: calc(100% - 22px) -6px; animation: none;
  transition: opacity 120ms var(--ease-out), scale 140ms var(--ease-out), translate 140ms var(--ease-out),
    display 140ms allow-discrete;
}
.mav-motion .auth-dropdown.hidden { opacity: 0; scale: .94; translate: 0 -6px; }
.mav-motion .auth-dropdown:not(.hidden) {
  opacity: 1; scale: 1; translate: 0 0;
  transition: opacity 150ms var(--ease-out), scale var(--sp-snappy-d) var(--sp-snappy),
    translate var(--sp-snappy-d) var(--sp-snappy), display 0s allow-discrete;
}
@starting-style {
  .mav-motion .auth-dropdown:not(.hidden) { opacity: 0; scale: .92; translate: 0 -6px; }
}

/* ===== 6. Gliders: indicators that stretch between tabs (motion.js) ======= */
.has-glide { position: relative; }
.mav-glide {
  position: absolute; left: 0; top: 0; pointer-events: none; z-index: 2;
  transform-origin: 0 0; opacity: 0; transition: opacity 150ms ease;
}
.mav-glide.on { opacity: 1; }
.mav-glide--line { width: 100px; height: 3px; border-radius: 3px 3px 0 0; background: var(--sun, var(--brand, #1668e3)); }
.mav-glide--pill { background: #fff; border-radius: 9px; box-shadow: 0 2px 8px rgba(0,0,0,.1); z-index: 0; }
#hw-tabs.has-glide .hw-tab.active,
.xds-cats.has-glide .xds-cat.active { border-bottom-color: transparent; }
.donate-freq.has-glide .df-opt { position: relative; z-index: 1; }
.donate-freq.has-glide .df-opt.active { background: transparent; box-shadow: none; }

/* ===== 7. Home: first impression ========================================= */
.mav-motion .mav-word { display: inline-block; }
.mav-motion .mav-word:not(.mav-done) {
  animation:
    mav-word-in 420ms var(--ease-out) var(--wd, 60ms) backwards,
    mav-word-rise var(--sp-bouncy-d) var(--sp-bouncy) var(--wd, 60ms) backwards;
}
@keyframes mav-word-in { from { opacity: 0; filter: blur(8px); } }
@keyframes mav-word-rise { from { translate: 0 20px; scale: .94; } }
.mav-motion .home-widget:not(.mav-done) {
  animation:
    mav-fade-in 320ms var(--ease-out) 160ms backwards,
    mav-rise var(--sp-bouncy-d) var(--sp-bouncy) 160ms backwards;
}
@keyframes mav-rise { from { translate: 0 26px; } }
@keyframes mav-fade-in { from { opacity: 0; } }
/* category switch in the search widget: the new fields settle in */
.mav-motion .hw-field:not(.mav-done) {
  animation: mav-fade-in 160ms var(--ease-out) backwards, mav-field-rise var(--sp-snappy-d) var(--sp-snappy) backwards;
}
@keyframes mav-field-rise { from { translate: 0 8px; } }
/* category bar: the chosen icon pops (spring), the others settle back */
.mav-motion .hw-tab .hw-ico { scale: 1; transition: scale var(--sp-pop-d) var(--sp-pop), filter .2s ease, opacity .2s ease; }
.mav-motion .hw-tab.active .hw-ico { scale: 1.12; }
/* photos fade in once they've actually loaded */
.mav-motion .pc-img { transition: opacity 320ms var(--ease-out); }
.mav-motion .pc-img:not(.loaded) { opacity: 0; }
.mav-motion .xds-img:not([style*="background-image"]):not(.xds-img--none) { animation: mav-shimmer 1.4s ease-in-out infinite; }
.mav-motion .xds-img[style*="background-image"] { animation: mav-fade-in 320ms var(--ease-out); }
@keyframes mav-shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }
/* header lifts off the page once you scroll */
.mav-motion .topnav { transition: box-shadow 300ms ease, background-color 300ms ease; }
.mav-motion .topnav.scrolled { box-shadow: 0 8px 28px rgba(var(--shade, 25,30,59),.09); background-color: var(--nav-scrolled, rgba(255,255,255,.94)); }

/* ===== 8. Search results pop in, with a short shrinking stagger =========== */
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):not(.mav-done) {
  animation:
    mav-fade-in 220ms var(--ease-out) var(--rd, 0ms) backwards,
    mav-res-rise var(--sp-bouncy-d) var(--sp-bouncy) var(--rd, 0ms) backwards;
}
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(2) { --rd: 40ms; }
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(3) { --rd: 75ms; }
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(4) { --rd: 105ms; }
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(5) { --rd: 130ms; }
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(n+6) { --rd: 150ms; }
/* long lists: only the first screenful performs */
.mav-motion :is(.stay-card, .flt-card, .trn-card, .food-card, .camp-card, .trail-card, .fish-card, .acc-card):nth-child(n+13) { animation: none; }
@keyframes mav-res-rise { from { translate: 0 18px; scale: .96; } }

/* ===== 9. The island: global loading status ============================== */
#mav-island {
  position: fixed; top: 82px; left: 50%; z-index: 9000;
  height: 40px; width: 40px; border-radius: 999px;
  background: var(--island); color: #fff;
  box-shadow: 0 12px 32px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.10);
  translate: -50% -16px; scale: .6;
  opacity: 0; pointer-events: none; overflow: hidden;
  font: 600 .86rem/1 var(--font, Inter), system-ui, sans-serif; letter-spacing: .01em;
  transition:
    width var(--sp-bouncy-d) var(--sp-bouncy), height var(--sp-bouncy-d) var(--sp-bouncy),
    translate var(--sp-bouncy-d) var(--sp-bouncy), scale var(--sp-bouncy-d) var(--sp-bouncy),
    opacity 200ms var(--ease-out);
}
#mav-island.show { opacity: 1; translate: -50% 0; scale: 1; }
#mav-island.show.tucked { opacity: 0; translate: -50% -10px; scale: .8; } /* the page's own loader is on screen */
#mav-island.done { height: 48px; }
#mav-island .mi-in {
  position: absolute; top: 0; bottom: 0; left: 0; width: max-content; display: flex; align-items: center; gap: .65rem;
  padding: 0 1.05rem 0 .7rem; white-space: nowrap;
}
#mav-island .mi-text { transition: opacity 150ms ease, filter 150ms ease; }
#mav-island .mi-text.swap { opacity: 0; filter: blur(4px); }
#mav-island.closing .mi-text { opacity: 0; filter: blur(4px); transition-duration: 110ms; }  /* content leaves before the pill shrinks */
#mav-island .mi-lead { position: relative; width: 26px; height: 26px; flex: none; display: grid; place-items: center; }
.mi-bars { display: flex; align-items: center; gap: 3px; height: 16px; }
.mi-bars i { display: block; width: 3px; height: 100%; border-radius: 3px; background: var(--bar-1, #5ac8fa); animation: mav-bar 900ms ease-in-out infinite; }
.mi-bars i:nth-child(2) { animation-delay: -200ms; background: var(--bar-2, #64d2ff); }
.mi-bars i:nth-child(3) { animation-delay: -450ms; background: var(--bar-3, #0a84ff); }
.mi-bars i:nth-child(4) { animation-delay: -650ms; background: var(--bar-4, #5e5ce6); }
@keyframes mav-bar { 0%, 100% { scale: 1 .3; } 50% { scale: 1 1; } }
.mi-check, .mi-warn {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  animation: mav-fade-in 150ms var(--ease-out), mav-pop var(--sp-pop-d) var(--sp-pop);
}
.mi-check { background: #30d158; }
.mi-warn { background: #ff9f0a; color: #000; font-weight: 800; }
.mi-check svg { width: 14px; height: 14px; }
.mi-check path { stroke-dasharray: 24; stroke-dashoffset: 24; animation: mav-draw 300ms var(--ease-out) 110ms forwards; }
@keyframes mav-pop { from { scale: .5; } }
@keyframes mav-draw { to { stroke-dashoffset: 0; } }

/* in-page loading screen (replaces "Searching…" text) */
.mav-ls { padding: 1.6rem 0 .6rem !important; text-align: center; }
.mav-ls-pill {
  display: inline-flex; align-items: center; gap: .7rem;
  background: var(--island); color: #fff; border-radius: 999px;
  padding: .7rem 1.3rem .7rem .9rem; font-weight: 600; font-size: .92rem;
  box-shadow: 0 14px 34px rgba(0,0,0,.2), inset 0 1px 0 rgba(255,255,255,.10);
  animation: mav-fade-in 200ms var(--ease-out) backwards, mav-ls-grow var(--sp-bouncy-d) var(--sp-bouncy) backwards;
}
@keyframes mav-ls-grow { from { scale: .7; } }
.mav-ls-pill .mav-ls-text { animation: mav-fade-in 220ms var(--ease-out) 120ms backwards; }
.mav-ls-sub { margin-top: .7rem; font-size: .8rem; color: var(--muted-2, #8a8fa3); font-weight: 500; animation: mav-fade-in 300ms var(--ease-out) 260ms backwards; }
.mav-skel { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; margin-top: 1.4rem; text-align: left; }
.mav-skel-card {
  position: relative; overflow: hidden; background: #fff; border: 1px solid var(--line, #ececf2); border-radius: 16px; padding-bottom: .9rem;
  animation: mav-fade-in 240ms var(--ease-out) 120ms backwards;
}
.mav-skel-card .sk-img { height: 120px; background: var(--surface-3, #eef0f5); }
.mav-skel-card .sk-line { height: 11px; border-radius: 6px; background: var(--surface-3, #eef0f5); margin: .85rem .9rem 0; width: 70%; }
.mav-skel-card .sk-line.short { width: 42%; margin-top: .55rem; }
.mav-skel-card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 20%, rgba(255,255,255,.75) 50%, transparent 80%);
  translate: -100% 0; animation: mav-glimmer 1.4s ease-in-out infinite;
}
@keyframes mav-glimmer { to { translate: 100% 0; } }
@media (max-width: 600px) { .mav-skel-card:nth-child(n+3) { display: none; } .mav-skel { grid-template-columns: 1fr 1fr; } }

/* ===== 10. Feedback: like, save, add-to-trip (driven by motion.js) ======== */
.mav-burst-dot {
  position: absolute; left: 50%; top: 50%; width: 7px; height: 7px; margin: -3.5px 0 0 -3.5px; z-index: 1;
  border-radius: 50%; pointer-events: none;
}
.mav-fly {
  position: fixed; z-index: 9500; width: 30px; height: 30px; border-radius: 50%;
  background: var(--sun, var(--brand, #1668e3)); box-shadow: 0 8px 20px rgba(var(--sun-rgb, 22,104,227),.45);
  display: grid; place-items: center; pointer-events: none;
}
.mav-fly svg { width: 15px; height: 15px; }

/* ===== 11. Modals and toast =============================================== */
.mav-motion :is(.flt-modal-overlay, .auth-modal-overlay) { animation: mav-fade-in 200ms var(--ease-out); }
.mav-motion :is(.flt-modal, .auth-modal) {
  transform-origin: center;
  animation: mav-fade-in 180ms var(--ease-out), mav-modal-rise var(--sp-bouncy-d) var(--sp-bouncy);
}
@keyframes mav-modal-rise { from { translate: 0 28px; scale: .93; } }
/* leaving (motion.js mavLeave): the way it came, faster */
.mav-motion .mav-leaving { animation: mav-fade-out 170ms var(--ease-out) forwards; pointer-events: none; }
.mav-motion .mav-leaving :is(.flt-modal, .auth-modal) { animation: mav-modal-out 170ms var(--ease-out) forwards; }
@keyframes mav-fade-out { to { opacity: 0; } }
@keyframes mav-modal-out { to { translate: 0 14px; scale: .97; } }

.mav-motion .agent-toast {
  transform: none; translate: -50% 160%;
  transition: translate 220ms var(--ease-out), opacity 180ms var(--ease-out);
}
.mav-motion .agent-toast.show {
  transform: none; translate: -50% 0;
  transition: translate var(--sp-bouncy-d) var(--sp-bouncy), opacity 180ms var(--ease-out);
}

/* wizard steps and admin panels */
.mav-motion .wizard-question { animation: mav-fade-in 200ms var(--ease-out), mav-field-rise var(--sp-snappy-d) var(--sp-snappy); }
.mav-motion .admin-panel.active { animation: mav-fade-in 160ms var(--ease-out); }

/* ===== 12. First visit of a session: the island splash (1.1s) ============= */
#mav-splash {
  position: fixed; inset: 0; z-index: 100000; display: grid; place-items: center;
  background: #fff; pointer-events: none;
  animation: mav-splash-out 260ms var(--ease-out) 840ms forwards;
}
#mav-splash .ms-island {
  display: flex; align-items: center; justify-content: center; gap: .8rem; overflow: hidden;
  background: var(--island); color: #fff; border-radius: 999px; white-space: nowrap;
  box-shadow: 0 20px 50px rgba(0,0,0,.28);
  animation: mav-splash-island 1100ms both;
}
#mav-splash .ms-logo { width: 40px; height: 40px; flex: none; animation: mav-splash-content 1100ms both; }
#mav-splash .ms-word { font: var(--splash-weight, 700) 1.35rem/1 var(--font, 'Source Serif 4'), Georgia, serif; letter-spacing: var(--splash-track, .01em); animation: mav-splash-content 1100ms both; }
#mav-splash .ms-bars { position: absolute; display: none; }
@keyframes mav-splash-island {
  0%   { width: 20px;  height: 20px; scale: .3; animation-timing-function: var(--sp-pop); }
  16%  { width: 20px;  height: 20px; scale: 1;  animation-timing-function: var(--sp-bouncy); }
  50%  { width: 290px; height: 74px; scale: 1;  translate: 0 0; animation-timing-function: linear; }
  72%  { width: 290px; height: 74px; scale: 1;  translate: 0 0; animation-timing-function: var(--ease-in-out); }
  100% { width: 120px; height: 36px; scale: .9; translate: 0 calc(-50vh + 100px); }
}
@keyframes mav-splash-content {
  0%, 30%  { opacity: 0; filter: blur(6px); scale: .8; }
  48%, 70% { opacity: 1; filter: none; scale: 1; }
  84%, 100% { opacity: 0; filter: blur(4px); scale: .9; }
}
@keyframes mav-splash-out { to { opacity: 0; visibility: hidden; } }
/* the hero waits for the splash */
.mav-splashing .mav-word:not(.mav-done) { animation-delay: calc(var(--wd, 60ms) + 860ms), calc(var(--wd, 60ms) + 860ms); }
.mav-splashing .home-widget:not(.mav-done) { animation-delay: 1000ms, 1000ms; }

/* ===== 13. Reduced motion: the static site, with gentle fades ============= */
@media (prefers-reduced-motion: reduce) {
  #mav-splash { display: none; }
  /* base CSS lifts and nudges a few things on hover/press — keep them still */
  :is(.home-card, .photo-card, .xds-card, .cruise-card, .flt-gear-card, .stay-card, .flt-card,
      .forecast-fish-card, .donate-amt, .wx-chip):hover,
  :is(.btn-primary, .donate-submit):active { transform: none; }
  .photo-cell img:hover { transform: none; }
  .nav-caret, .hamburger span { transition: none; }
  .wizard-question, .admin-panel.active, .auth-dropdown { animation: mav-fade-in 150ms ease; }
}

/* ===== 14. Glass motion (v8.1, 2026-11-29) ================================= */
/* a. Arriving in a section: the photo behind settles (a slow push-in that comes
      to rest) and the content sheet rises into place. One shot per visit;
      transform + opacity only. glass.js adds .settle only when the place changes. */
.mav-motion #scene .sc.on.settle { animation: mav-scene-settle 1.8s cubic-bezier(.16, .84, .3, 1) both; }
@keyframes mav-scene-settle { from { transform: scale(1.13); } to { transform: scale(1.04); } }
/* no resting translate on the sheet: any transform would trap position:fixed children */
.mav-motion .tab-content.active:not(#tab-home) {
  animation: mav-fade-in 220ms var(--ease-out), mav-sheet-rise var(--sp-smooth-d) var(--sp-smooth);
}
@keyframes mav-sheet-rise { from { translate: 0 34px; } to { translate: 0 0; } }

/* b. …and its header tile pops in on a spring */
.mav-motion :is(.flt-search-title, .wx-search-title, .pg-title, .shop-header h2, .budget-header h2, .acc-hero h2, .ai-header h2) > .ic:first-child { scale: 1; rotate: 0deg; }
.mav-motion .tab-content.active :is(.flt-search-title, .wx-search-title, .pg-title, .shop-header h2, .budget-header h2, .acc-hero h2, .ai-header h2) > .ic:first-child {
  animation: mav-tile-pop var(--sp-pop-d) var(--sp-pop) 90ms backwards;
}
@keyframes mav-tile-pop { from { scale: .4; rotate: -14deg; } }

/* c. Phone tab bar: the lens slides between tabs (motion.js glider), the chosen
      icon hops, and the bar tucks away while you scroll down (iOS 26). */
.mbar.mbar-glide button { position: relative; z-index: 1; }
.mbar.mbar-glide button.on { background: transparent; box-shadow: none; }
.mbar .mav-glide--pill {
  border-radius: 19px; background: rgba(255, 255, 255, .62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 1px 3px rgba(0, 0, 0, .08);
}
.mav-motion .mbar button .gl { translate: 0 0; scale: 1; transition: translate var(--sp-snappy-d) var(--sp-snappy); }
.mav-motion .mbar button.on .gl { animation: mav-mb-hop var(--sp-pop-d) var(--sp-pop); }
@keyframes mav-mb-hop { from { scale: .7; translate: 0 4px; } }
@media (max-width: 760px) {
  .mav-motion .mbar {
    scale: 1; translate: 0 0; transform-origin: 50% 100%;
    transition: scale var(--sp-snappy-d) var(--sp-snappy), translate var(--sp-snappy-d) var(--sp-snappy);
  }
  .mav-motion .mbar.min { scale: .82; translate: 0 8px; }
  .mav-motion .mbar .mbl { transition: opacity 160ms ease; }
  .mav-motion .mbar.min .mbl { opacity: 0; }
  .mav-motion .mbar.min button .gl { translate: 0 7px; }
}

/* d. Light on the glass follows the pointer (Liquid Glass's specular highlight).
      Mouse only, and never on glass-lite (no GPU). motion.js sets --mx/--my. */
@media (hover: hover) and (pointer: fine) {
  html.mav-motion:not(.glass-lite) :is(.topnav, .home-widget, .nl-signup) { isolation: isolate; }
  html.mav-motion:not(.glass-lite) :is(.topnav, .home-widget, .nl-signup)::after {
    content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
    background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 0px), rgba(255, 255, 255, .5), rgba(255, 255, 255, 0) 72%);
    opacity: 0; transition: opacity 400ms ease;
  }
  html.mav-motion:not(.glass-lite) :is(.topnav, .home-widget, .nl-signup).lit::after { opacity: 1; transition-duration: 150ms; }
}
@media (hover: hover) and (pointer: fine) and (min-width: 1201px) {
  html.mav-motion:not(.glass-lite) :is(.nav-group-menu, .auth-dropdown) { isolation: isolate; }
  html.mav-motion:not(.glass-lite) :is(.nav-group-menu, .auth-dropdown)::after {
    content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
    background: radial-gradient(200px circle at var(--mx, 50%) var(--my, 0px), rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 72%);
    opacity: 0; transition: opacity 400ms ease;
  }
  html.mav-motion:not(.glass-lite) :is(.nav-group-menu, .auth-dropdown).lit::after { opacity: 1; transition-duration: 150ms; }
}

/* e. Primary actions: a sweep of light crosses the button on hover */
@media (hover: hover) and (pointer: fine) {
  .mav-motion :is(.hw-search, .donate-submit, .nl-signup-btn) { position: relative; overflow: hidden; isolation: isolate; }
  .mav-motion :is(.hw-search, .donate-submit, .nl-signup-btn)::after {
    content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .4) 50%, transparent 70%);
    translate: -120% 0;
  }
  .mav-motion :is(.hw-search, .donate-submit, .nl-signup-btn):hover::after { translate: 120% 0; transition: translate 800ms cubic-bezier(.35, 0, .2, 1); }
  /* gear cards: the category illustration lifts toward you */
  .mav-motion .acc-card::after { translate: 0 0; scale: 1; transition: translate var(--sp-pop-d) var(--sp-pop), scale var(--sp-pop-d) var(--sp-pop); }
  .mav-motion .acc-card:hover::after { translate: 0 -5px; scale: 1.08; }
}

/* f. Home: sections and cards rise in as they scroll into view, a column at a
      time. Scroll-driven (runs off the main thread); browsers without it skip it. */
@supports (animation-timeline: view()) {
  .mav-motion .home-sheet > :is(.home-promo, .home-section-label),
  .mav-motion .home-sheet :is(.photo-card, .home-card) {
    animation: mav-reveal cubic-bezier(.2, .7, .3, 1) both;
    animation-timeline: view();
    animation-range: entry 5% entry 85%;
  }
  .mav-motion .home-sheet .photo-card:nth-child(4n+2), .mav-motion .home-sheet .home-card:nth-child(7n+2) { animation-range: entry 10% entry 90%; }
  .mav-motion .home-sheet .photo-card:nth-child(4n+3), .mav-motion .home-sheet .home-card:nth-child(7n+3) { animation-range: entry 15% entry 95%; }
  .mav-motion .home-sheet .photo-card:nth-child(4n+4), .mav-motion .home-sheet .home-card:nth-child(7n+4) { animation-range: entry 20% entry 100%; }
  .mav-motion .home-sheet .home-card:nth-child(7n+5) { animation-range: entry 25% cover 30%; }
  .mav-motion .home-sheet .home-card:nth-child(7n+6) { animation-range: entry 30% cover 33%; }
  .mav-motion .home-sheet .home-card:nth-child(7n+7) { animation-range: entry 35% cover 36%; }
  @keyframes mav-reveal { from { opacity: 0; transform: translateY(44px) scale(.96); } }
}
