/* Loonis Sites additions on top of the template stylesheet */

/* hide animated elements until the motion kit runs (removed instantly if it can't) */
html.lx-motion [animate="fade-up"],
html.lx-motion [animate="heading-reveal"],
html.lx-motion [animate="stagger"],
html.lx-motion [animate="image-reveal"],
html.lx-motion [animate="rule-draw"],
html.lx-motion [animate="bar-grow"],
html.lx-motion [animate="bar-segments"] { opacity: 0; }

/* card hover zoom (1.04, 0.6s) */
html:not(.lx-ix) [class*="_card"] img, html:not(.lx-ix) .card-media img { transition: transform var(--motion-slow) var(--ease-1); }
html:not(.lx-ix) [class*="_card"]:hover img:not([class*="icon"]), html:not(.lx-ix) .card-media:hover img { transform: scale(1.04); }
.card-media { overflow: hidden; }

/* lightbox */
.lx-lightbox { position: fixed; inset: 0; z-index: 9999; background: var(--tone-overlay-92); display: flex; align-items: center; justify-content: center; }
.lx-lightbox img { max-width: 86vw; max-height: 86vh; object-fit: contain; border-radius: var(--radius-8); }
.lx-lightbox button { position: absolute; background: none; border: 0; color: var(--role-card); font-size: calc(var(--size-2-5rem) * var(--scale-headings)); cursor: pointer; padding: var(--spacing-1rem); line-height: var(--leading-100); }
.lx-lb-close { top: 1rem; right: 1rem; }
.lx-lb-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lx-lb-next { right: 1rem; top: 50%; transform: translateY(-50%); }

/* tabs: Webflow hides inactive panes */
.w-tab-pane { display: none; }
.w-tab-pane.w--tab-active { display: block; }

/* single-page lists: Webflow hides pagination when there is nothing to page */
.w-pagination-wrapper { display: none; }


/* menu links the converter added to templates that only had a demo "Pages" dropdown */
.lx-nav-added { white-space: nowrap; }

/* ---- lx-icons: one-colour logo and icons follow the role colours (written by _tools/design-system/icons.mjs) ----
   The template's own one-colour SVG files are drawn as a mask filled with a role colour; the file
   itself is moved out of view. This runs in every theme except Original, and when the Style panel
   has changed a colour (<html data-colours="custom">). In Original the files show as drawn.
   The selectors match the template's own file names only: an owner logo or a replaced image has
   another src, so it shows exactly as uploaded and is never recoloured. */
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/icon-plus.svg"],
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lanewise-icon-chevron-down.svg"],
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lanewise-icon-menu.svg"],
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lw-video-pause.svg"],
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lw-video-play.svg"] {
  object-position: -99999px 0;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: center; mask-position: center;
  -webkit-mask-size: contain; mask-size: contain;
  -webkit-mask-origin: content-box; mask-origin: content-box;
  -webkit-mask-clip: content-box; mask-clip: content-box;
  background-color: var(--role-ink);
  background-clip: content-box;
}
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/icon-plus.svg"] { -webkit-mask-image: url(/_t/lanewise/images/icon-plus.svg); mask-image: url(/_t/lanewise/images/icon-plus.svg); }
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lanewise-icon-chevron-down.svg"] { -webkit-mask-image: url(/_t/lanewise/images/lanewise-icon-chevron-down.svg); mask-image: url(/_t/lanewise/images/lanewise-icon-chevron-down.svg); }
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lanewise-icon-menu.svg"] { -webkit-mask-image: url(/_t/lanewise/images/lanewise-icon-menu.svg); mask-image: url(/_t/lanewise/images/lanewise-icon-menu.svg); }
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lw-video-pause.svg"] { -webkit-mask-image: url(/_t/lanewise/images/lw-video-pause.svg); mask-image: url(/_t/lanewise/images/lw-video-pause.svg); background-color: var(--role-on-photo); }
:is(html[data-theme]:not([data-theme="original"]), html[data-colours="custom"]) img[src$="/_t/lanewise/images/lw-video-play.svg"] { -webkit-mask-image: url(/_t/lanewise/images/lw-video-play.svg); mask-image: url(/_t/lanewise/images/lw-video-play.svg); background-color: var(--role-on-photo); }
/* ---- end lx-icons ---- */

/* two-colour line icons (Tar and rust, icon-*-ink.svg) on light cards: the dark themes turn the cards dark, so the
   icons are inverted and turned back to their hue (light strokes, a rust that stays rust). Icons on the navy bands
   use their own cream files. An uploaded owner image has another file name and is never changed. */
html:is([data-theme="night-port"], [data-theme="inverted"]) img[src*="/_t/lanewise/images/icon-"][src$="-ink.svg"] { filter: invert(1) hue-rotate(180deg); }
