/* AUTOMAT.AM landing page — page-level styles (full-page redesign).
   Tokens come from ../styles.css; components style themselves inline.
   Layout: every section is one screen (src/FullPage.jsx); the header is fixed. */

:root {
  --header-h: 76px;
  --gutter: clamp(20px, 5vw, 80px);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --panel-glass: rgba(30, 28, 28, 0.66);
}
@media (max-width: 820px) { :root { --header-h: 64px; } }

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none; }
body { background: #000; font-family: var(--font-sans); color: var(--white); }
button { font-family: inherit; }

/* ===== Full-page track ===== */
.fp-root { position: fixed; inset: 0; overflow: hidden; }
.fp-track { position: absolute; inset: 0; will-change: transform; }
.fp-track > * { position: relative; height: 100%; overflow: hidden; isolation: isolate; }
.fp-track { --fs-h1: clamp(28px, 1.6vw + 18px, 40px); }   /* section headings, smaller on phones */
.fp-bg {
  position: absolute; inset: 0; z-index: -1;
  background-position: center; background-size: cover; background-repeat: no-repeat;
  will-change: transform;
}
.fp-inner {
  height: 100%; width: 100%; max-width: 1480px; margin: 0 auto;
  display: flex; flex-direction: column;
  padding: calc(var(--header-h) + clamp(14px, 4vh, 48px)) var(--gutter) clamp(20px, 4.5vh, 52px);
}
.fp-head { flex: none; margin-bottom: clamp(16px, 3.6vh, 40px); }
/* content taller than a short screen scrolls inside its section; the page moves on at the edge */
.fp-scrollable { overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
.fp-scrollable::-webkit-scrollbar { display: none; }

/* ===== Entrance animations: [data-reveal] stays hidden until its section is first shown;
   fpReveal() in src/FullPage.jsx then plays it with GSAP (or, inside a scrollable box,
   when it is scrolled into view). Gallery tiles use the keyframes below instead, so the
   tiles of every new page animate as they are created. `animation-fill-mode: backwards`
   holds the start pose during the stagger delay and then hands back to the element's
   own styles, so hover transforms keep working afterwards. ===== */
.fp-track > :not(.is-seen) [data-reveal] { opacity: 0; }
.is-seen .gallery-grid [data-reveal] {
  animation: rv-scale 0.85s var(--ease-out) backwards;
  animation-delay: calc(var(--rd, 0) * 45ms + 300ms);
}
@keyframes rv-scale { from { opacity: 0; transform: translateY(18px) scale(0.93); } }
@keyframes rv-up    { from { opacity: 0; transform: translateY(34px); } }   /* mobile menu items */
@media (prefers-reduced-motion: reduce) {
  .fp-track > :not(.is-seen) [data-reveal] { opacity: 1; }
}

/* ===== Header: fixed and always visible; clear over the hero video, glass elsewhere ===== */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50; height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 0 var(--gutter);
}
.site-header::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: rgba(14, 13, 13, 0.66);
  backdrop-filter: blur(14px) saturate(1.2); -webkit-backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.07);
  transition: opacity 0.5s var(--ease-standard);
}
.site-header.is-over-hero::before { opacity: 0; }
.site-header::after {
  content: ""; position: absolute; inset: 0 0 -40px; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0));
  opacity: 0; transition: opacity 0.5s var(--ease-standard);
}
.site-header.is-over-hero::after { opacity: 1; }
.site-header__brand {
  flex: none; display: flex; padding: 4px; margin-left: -4px; border: 0; background: none; cursor: pointer;
  border-radius: var(--radius-button);
}
.site-header__brand img { height: 44px !important; }
.site-nav { display: flex; align-items: center; gap: clamp(14px, 1.7vw, 26px); }
.site-nav__item { transition: color var(--dur-base) var(--ease-standard), background var(--dur-base) var(--ease-standard) !important; }
.site-nav__item:not(.is-current):hover { color: var(--white) !important; }
.site-nav__item.is-current { padding: 10px 16px !important; background: var(--white) !important; color: var(--black) !important; }
.menu-toggle {
  display: none; width: 44px; height: 44px; flex: none; border: 0; border-radius: 50%; cursor: pointer;
  align-items: center; justify-content: center; color: var(--white);
  background: rgba(255, 255, 255, 0.08); box-shadow: var(--inset-subtle);
}
.site-header__brand:focus-visible, .site-nav__item:focus-visible, .menu-toggle:focus-visible,
.site-menu__item:focus-visible, .fp-dot:focus-visible, .round-btn:focus-visible, .dot:focus-visible,
.page-num:focus-visible, .wf-step:focus-visible, .findus-phone:focus-visible {
  outline: 3px solid var(--coral); outline-offset: 3px;
}
/* full-screen menu for narrow screens */
.site-menu {
  position: fixed; inset: 0; z-index: -2;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 16px) var(--gutter) 32px;
  background: rgba(8, 8, 8, 0.97);
}
.site-menu[hidden] { display: none; }
.site-menu__list { list-style: none; margin: 0; padding: 0; width: 100%; display: flex; flex-direction: column; gap: 4px; }
.site-menu__list li { animation: rv-up 0.55s var(--ease-out) backwards; animation-delay: calc(var(--rd, 0) * 45ms + 40ms); }
.site-menu__item {
  display: flex; align-items: baseline; gap: 18px; width: 100%; min-height: 56px; padding: 6px 0;
  border: 0; background: none; cursor: pointer; text-align: left;
  color: var(--ink-200); font-weight: 800; font-size: clamp(26px, 7vw, 40px); line-height: 1.15; letter-spacing: -0.01em;
}
.site-menu__item:hover { color: var(--white); }
.site-menu__item.is-current { color: var(--coral); }
.site-menu__num { min-width: 28px; font-weight: 500; font-size: 14px; color: var(--steel-400); }
@media (max-width: 820px) {
  .site-header__brand img { height: 38px !important; }
}
/* The inline menu needs room for the logo + every nav label. Measured fit (logo 253px wide):
   en ~1045px, ru ~966px, hy ~1294px with 7 items (Armenian labels run ~40% wider). Below these, the menu
   button takes over; each breakpoint keeps ~30-40px of slack. Re-measure if nav.* or the logo changes. */
@media (max-width: 1080px) {
  .site-nav { display: none; }
  .menu-toggle { display: flex; }
}
@media (max-width: 1330px) {
  html:lang(hy) .site-nav { display: none; }
  html:lang(hy) .menu-toggle { display: flex; }
}
@media (prefers-reduced-motion: reduce) { .site-menu__list li { animation: none; } }

/* ===== Side dots (desktop) ===== */
.fp-dots {
  position: fixed; z-index: 40; right: clamp(10px, 1.4vw, 26px); top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 2px;
}
.fp-dot {
  position: relative; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 8px;
  background: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.fp-dot::before {
  content: ""; width: 8px; height: 8px; border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.38); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  transition: height 0.35s var(--ease-out), background 0.35s;
}
.fp-dot:hover::before { background: rgba(255, 255, 255, 0.75); }
.fp-dot.is-current::before { height: 26px; background: var(--white); }
.fp-dot__label {
  position: absolute; right: 38px; white-space: nowrap; pointer-events: none;
  padding: 5px 10px; border-radius: 8px; background: rgba(0, 0, 0, 0.72);
  color: var(--white); font-size: 14px; font-weight: 500;
  opacity: 0; transform: translateX(6px); transition: opacity 0.2s, transform 0.2s;
}
.fp-dot:hover .fp-dot__label, .fp-dot:focus-visible .fp-dot__label { opacity: 1; transform: none; }
.fp-dots.is-on-light .fp-dot::before { background: rgba(0, 0, 0, 0.28); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5); }
.fp-dots.is-on-light .fp-dot:hover::before { background: rgba(0, 0, 0, 0.6); }
.fp-dots.is-on-light .fp-dot.is-current::before { background: var(--black); }
@media (max-width: 820px) { .fp-dots { display: none; } }

/* ===== Shared controls: round arrow buttons, carousel dots, page numbers ===== */
.round-btn {
  width: 48px; height: 48px; flex: none; border: 0; border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); background: rgba(255, 255, 255, 0.06); box-shadow: var(--inset-card);
  transition: background var(--dur-base) var(--ease-standard), color var(--dur-base) var(--ease-standard);
}
.round-btn:hover { background: var(--white); color: var(--black); }
.dots { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; }
.dot {
  width: 30px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.dot::before {
  content: ""; width: 8px; height: 8px; border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.35); transition: width 0.35s var(--ease-out), background 0.35s;
}
.dot:hover::before { background: rgba(255, 255, 255, 0.7); }
.dot.is-current::before { width: 26px; background: var(--white); }

/* ===== Hero ===== */
.hero-stage { background: #000; }
.hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center; z-index: 0; pointer-events: none;
  background: #000;
}
.hero-wash {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0.62) 0%, rgba(0,0,0,0.32) 40%, rgba(0,0,0,0.22) 70%, rgba(0,0,0,0.55) 100%);
}
/* hero lockup: ~55% larger than the header's (44px mark, 36px wordmark token) */
.hero-brand { margin-bottom: clamp(18px, 3.2vh, 34px); --fs-wordmark: 56px; }
.hero-brand .logo__mark { height: 68px !important; }
.brand-flyer {
  position: fixed; left: 0; top: 0; z-index: 55; pointer-events: none;
  visibility: hidden; opacity: 0; will-change: transform;
}
@media (max-width: 820px) {
  .hero-brand { --fs-wordmark: 48px; margin-bottom: 14px; }
  .hero-brand .logo__mark { height: 60px !important; }
}
@media (max-width: 400px) {
  .hero-brand { --fs-wordmark: 41px; }
  .hero-brand .logo__mark { height: 53px !important; }
}
.hero-content {
  max-width: 1480px; margin: 0 auto;
  padding: calc(var(--header-h) + clamp(24px, 9vh, 110px)) var(--gutter) 0;
}
/* the lockup now marks the top of the hero, so on narrow screens it can start closer to the header */
@media (max-width: 820px) { .hero-content { padding-top: calc(var(--header-h) + clamp(8px, 2.5vh, 28px)); } }
.hero-scroll {
  position: absolute; z-index: 3; left: 50%; bottom: 22px; transform: translateX(-50%);
  min-height: 44px; padding: 6px 14px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: none; border: 0; border-radius: var(--radius-button); cursor: pointer;
  color: var(--ink-200); font-family: var(--font-sans); font-weight: 500; font-size: 14px;
  letter-spacing: 0.04em; text-transform: uppercase;
  transition: color var(--dur-base) var(--ease-standard);
}
.hero-scroll svg { animation: hero-bob 2.2s var(--ease-standard) infinite; }
.hero-scroll:hover { color: var(--white); }
.hero-toggle {
  position: absolute; z-index: 3; right: 24px; bottom: 26px;
  width: 44px; height: 44px; border-radius: 50%; border: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); background: rgba(0,0,0,0.45); box-shadow: var(--inset-subtle);
  backdrop-filter: blur(4px);
  transition: background var(--dur-base) var(--ease-standard);
}
.hero-toggle:hover { background: rgba(0,0,0,0.7); }
.hero-scroll:focus-visible, .hero-toggle:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; }
@keyframes hero-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }
@media (prefers-reduced-motion: reduce) { .hero-scroll svg { animation: none; } }
/* loader over the whole hero until the video can play (HeroLoader.jsx); the fixed header stays on top */
.hero-loader {
  position: absolute; inset: 0; z-index: 4;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at center, #5c5c5c 0%, #2c2c2c 22%, #0b0b0b 48%, #000 70%);
}
.hero-loader__mark { width: clamp(88px, 12vmin, 128px); aspect-ratio: 1; }
.hero-loader__mark svg { display: block; width: 100%; height: 100%; overflow: visible; }
@media (max-width: 820px) { .hero-shifter { display: none !important; } }
@media (max-width: 560px) {
  .hero-toggle { right: 16px; }
  .hero-ctas { flex-wrap: wrap; }
  .hero-content h1 { font-size: 30px !important; }
  .hero-content p { font-size: 16px !important; margin-top: 16px !important; }
}

/* ===== Our Services: tiles fill the screen ===== */
.services-bg {
  background-image:
    linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.15) 35%, rgba(0,0,0,0.55) 100%),
    url('../assets/backgrounds/services.webp');
}
.svc-grid {
  position: relative;                     /* offsetParent for the entrance (Services.jsx) */
  list-style: none; margin: 0; padding: 0; flex: 1; min-height: 0;
  display: grid; gap: clamp(12px, 1.5vw, 22px);
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(118px, 1fr));
  grid-auto-flow: column;                 /* one accent family per column */
}
.svc-tile {
  position: relative; overflow: hidden; min-width: 0;
  display: flex; flex-direction: column; justify-content: space-between; gap: 14px;
  padding: clamp(16px, 2.4vh, 28px) clamp(16px, 1.6vw, 28px);
  border-radius: var(--radius-card);
  background: var(--panel-glass);
  backdrop-filter: blur(12px) saturate(1.1); -webkit-backdrop-filter: blur(12px) saturate(1.1);
  box-shadow: var(--inset-subtle);
  transition: transform 0.3s var(--ease-out), background 0.3s var(--ease-standard);
}
.svc-tile::before {               /* family stripe: a short tab that runs the full width on hover */
  content: ""; position: absolute; left: 0; top: 0; right: 0; height: 3px;
  background: var(--fam); transform: scaleX(0.16); transform-origin: left;
  transition: transform 0.45s var(--ease-out);
}
.svc-tile:hover { transform: translateY(-4px); background: rgba(52, 49, 49, 0.78); }
.svc-tile:hover::before { transform: scaleX(1); }
.svc-tile:hover .svc-tile__icon { background: var(--fam) !important; }
/* height only; the 3:2 box fits the widest glyph (DSG, 1.47:1) so no icon is cut off */
.svc-tile__icon { height: clamp(34px, 6vh, 58px) !important; width: auto !important; aspect-ratio: 3 / 2; -webkit-mask-position: left center !important; mask-position: left center !important; }
.svc-tile__label {
  font-size: clamp(16px, 0.55vw + 0.9vh + 6px, 22px); line-height: 1.25; letter-spacing: var(--tracking-ui);
  color: var(--white); text-wrap: balance;
}
/* short desktop screens: icon beside the label, so long labels get the tile's full height */
@media (max-height: 800px) and (min-width: 1001px) {
  .svc-tile { flex-direction: row; align-items: center; justify-content: flex-start; gap: 18px; }
  .svc-tile__icon { flex: none !important; }
  .svc-tile__label { font-size: 16px; }
}
@media (max-width: 1000px) {
  .svc-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(4, minmax(96px, 1fr));
    grid-auto-flow: row;                  /* one family per row */
  }
}
@media (max-width: 600px) {
  .svc-grid { flex: 1 0 auto; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; grid-auto-rows: minmax(76px, auto); gap: 10px; }
  .svc-tile { padding: 12px 14px; gap: 8px; border-radius: 12px; }
  .svc-tile__icon { height: 28px !important; }
  .svc-tile__label { font-size: 14px; line-height: 1.2; }
}
/* icon zoom on hover: Services gives a tile .can-zoom and --icon-zoom only when it has room
   between icon and label (svcFitZoom); on top of that, only big hover screens (over 1000px) zoom */
@media (hover: hover) and (min-width: 1001px) and (prefers-reduced-motion: no-preference) {
  .svc-tile.can-zoom .svc-tile__icon {
    transform-origin: left top;
    transition: transform 0.45s var(--ease-out), background var(--dur-base) var(--ease-standard) !important;
  }
  .svc-tile.can-zoom:hover .svc-tile__icon { transform: scale(var(--icon-zoom)); }
}
@media (prefers-reduced-motion: reduce) { .svc-tile, .svc-tile::before { transition: none; } .svc-tile:hover { transform: none; } }

/* ===== Malfunctions: big split cards (photo | text) in a centred carousel ===== */
.malf-bg {
  background-image:
    linear-gradient(90deg, rgba(0,0,0,0.78) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.78) 100%),
    url('../assets/backgrounds/malfunctions.webp');
}
.malf-inner { max-width: none; padding-left: 0; padding-right: 0; }
.malf-inner > .fp-head { width: 100%; max-width: 1480px; margin-left: auto; margin-right: auto; padding: 0 var(--gutter); }
.malf-stage { flex: 1; min-height: 0; display: flex; }
.malf-slider { height: 100%; max-height: 620px; margin: auto 0; cursor: grab; }
.malf-slider:active { cursor: grabbing; }
.malf-card {
  display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1fr);
  height: 100%; border-radius: 20px; overflow: hidden;
  background: rgba(22, 21, 21, 0.86); box-shadow: var(--inset-subtle);
  opacity: 0.38; transition: opacity 0.6s var(--ease-standard);
}
.malf-card.is-current { opacity: 1; }
.malf-card__media { position: relative; min-height: 0; background: var(--graphite-700); }
.malf-card__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.06); transition: transform 1.2s var(--ease-out); user-select: none;
}
.malf-card.is-current .malf-card__media img { transform: scale(1); }
.malf-card__body {
  display: flex; flex-direction: column; justify-content: space-between; gap: 20px; min-width: 0;
  padding: clamp(22px, 4.5vh, 52px) clamp(22px, 3vw, 52px);
}
.malf-card__num {
  font-family: var(--font-display); font-weight: 700; line-height: 0.9;
  font-size: clamp(56px, 11vh, 120px); color: var(--coral);
}
.malf-card__num small { font-size: 0.32em; font-weight: 500; color: var(--steel-400); margin-left: 6px; }
.malf-card__text {
  margin: 0; color: var(--white); font-weight: 500;
  font-size: clamp(20px, 0.9vw + 1.2vh + 6px, 32px); line-height: 1.28; letter-spacing: -0.01em; text-wrap: pretty;
}
.malf-card__text::before {
  content: ""; display: block; width: 48px; height: 3px; margin-bottom: 20px;
  border-radius: var(--radius-pill); background: var(--white);
}
.malf-controls {
  flex: none; display: flex; align-items: center; justify-content: center; gap: 14px;
  margin-top: clamp(12px, 3vh, 32px); padding: 0 var(--gutter);
}
@media (max-width: 760px) {
  .malf-card { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; border-radius: 16px; }
  .malf-card__body { padding: 18px 20px 22px; gap: 10px; }
  .malf-card__num { font-size: 44px; }
  .malf-card__text { font-size: 18px; }
  .malf-card__text::before { margin-bottom: 12px; width: 36px; }
  .malf-controls .round-btn { display: none; }
  .dot { width: 24px; }
}
@media (prefers-reduced-motion: reduce) { .malf-card, .malf-card__media img { transition: none; } }

/* ===== Repair Workflow: step-by-step over the scrubbed video ===== */
.wf-section { background: #000; }
.wf-stage { position: relative; width: 100%; height: 100%; overflow: hidden; background: #000; }
.wf-video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 0; background: #000; pointer-events: none;
}
.wf-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(0,0,0,0.78) 0%, rgba(0,0,0,0.30) 45%, rgba(0,0,0,0.55) 100%),
    linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.05) 30%, rgba(0,0,0,0.55) 100%);
}
.wf-heading {
  position: absolute; top: calc(var(--header-h) + clamp(14px, 4vh, 48px));   /* = .fp-inner's top padding */ left: 0; right: 0; z-index: 3;
  display: flex; justify-content: center; pointer-events: none;
}
.wf-viewport {
  position: absolute; inset: 0; z-index: 2; overflow: hidden;
  /* steps fade out before they reach the heading */
  -webkit-mask-image: linear-gradient(180deg, transparent calc(var(--header-h) + 110px), #000 calc(var(--header-h) + 200px), #000 88%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent calc(var(--header-h) + 110px), #000 calc(var(--header-h) + 200px), #000 88%, transparent 100%);
}
.wf-col { position: absolute; top: 54%; left: 0; right: 0; will-change: transform; }
.wf-step {
  height: 150px; width: 100%; display: flex; align-items: center; gap: 26px;
  max-width: 720px; margin: 0 auto; padding: 0 32px; box-sizing: border-box;
  border: 0; background: none; color: inherit; font: inherit; text-align: left;
  opacity: 0.28; transform: scale(0.94); transform-origin: left center;
  transition: opacity .45s ease, transform .45s ease;
}
button.wf-step { cursor: pointer; }
button.wf-step:hover:not(.is-active) { opacity: 0.55; }
.wf-step.is-active { opacity: 1; transform: scale(1.04); }
.wf-copy, .wf-word, .wf-text { display: block; }
.wf-num {
  flex: 0 0 auto; width: 62px; height: 62px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-sans); font-weight: 800; font-size: 23px; line-height: 1;
  color: var(--graphite-800); background: var(--white);
  box-shadow: 0 0 0 0 rgba(255,255,255,0); transition: background .45s ease, box-shadow .45s ease, transform .45s ease;
}
.wf-step.is-active .wf-num { background: var(--accent); box-shadow: 0 0 0 8px rgba(255,255,255,0.08); }
.wf-word {
  font-family: var(--font-sans); font-weight: 800; font-size: 34px; line-height: 1.05;
  letter-spacing: -0.01em; color: var(--white);
}
.wf-step.is-active .wf-word { color: var(--accent); }
.wf-text {
  margin-top: 8px; font-family: var(--font-sans); font-weight: 400; font-size: 19px;
  line-height: 1.4; letter-spacing: -0.005em; color: var(--ink-200); max-width: 440px;
}
/* STATIC mode (reduced motion): plain list over the still video */
.wf-list {
  position: absolute; inset: 0; z-index: 2;
  padding: calc(var(--header-h) + 110px) 24px 40px;
}
.wf-list > .wf-step { max-width: 720px; height: auto; margin: 0 auto 18px; padding: 22px 24px; opacity: 1; transform: none;
  border-radius: 15px; background: rgba(0,0,0,0.34); backdrop-filter: blur(2px); }
.wf-flow .wf-num { background: var(--accent); }
.wf-flow .wf-word { color: var(--white); }
@media (max-width: 768px) {
  .wf-steps .wf-step { height: 116px; padding: 0 24px; }
}
@media (max-width: 560px) {
  .wf-word { font-size: 27px; }
  .wf-text { font-size: 17px; }
  .wf-num { width: 52px; height: 52px; font-size: 20px; }
  .wf-step { gap: 18px; }
}

/* ===== Gallery: paged grid that always fits ===== */
.gallery-bg {
  background:
    radial-gradient(90% 70% at 88% 0%, rgba(121, 157, 255, 0.10) 0%, transparent 60%),
    radial-gradient(120% 90% at 85% 10%, #3a3636 0%, #1c1a1a 48%, #0a0909 100%);
}
.gallery-head { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }
.gallery-intro {
  max-width: 560px; margin: clamp(10px, 1.6vh, 18px) 0 0;
  color: var(--ink-200); font-size: clamp(15px, 0.3vw + 13px, 18px); line-height: 1.5; text-wrap: balance;
}
.gallery-fit { flex: 1; min-height: 0; }
.gallery-grid {
  list-style: none; margin: 0; padding: 0; height: 100%;
  display: flex; flex-wrap: wrap; gap: var(--gap);
  align-content: center; justify-content: center;   /* a short last page sits centred */
}
.gallery-cell { flex: none; width: calc((100% - var(--gap) * (var(--cols) - 1)) / var(--cols)); aspect-ratio: 16 / 11; min-width: 0; }
.is-seen .gallery-grid.is-paged [data-reveal] { animation: gal-in 0.6s var(--ease-out) backwards; animation-delay: calc(var(--rd, 0) * 45ms); }
.is-seen .gallery-grid.is-paged.from-left [data-reveal] { animation-name: gal-in-left; }
@keyframes gal-in      { from { opacity: 0; transform: translateX(36px) scale(0.97); } }
@keyframes gal-in-left { from { opacity: 0; transform: translateX(-36px) scale(0.97); } }
.gallery-tile {
  position: relative; display: block; width: 100%; height: 100%;
  border-radius: 15px; overflow: hidden; background: var(--surface-card);
  box-shadow: var(--inset-subtle); text-decoration: none;
}
.gallery-tile::after {
  content: ""; position: absolute; inset: 0; background: rgba(0,0,0,0.18);
  opacity: 0; transition: opacity 180ms ease; pointer-events: none;
}
.gallery-tile:hover::after, .gallery-tile:focus-visible::after { opacity: 1; }
.gallery-tile:focus-visible { outline: 3px solid var(--coral); outline-offset: 4px; }
.gallery-poster {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transform: scale(1); transition: transform 240ms ease;
}
.gallery-tile:hover .gallery-poster, .gallery-tile:focus-visible .gallery-poster { transform: scale(1.04); }
.gallery-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.gallery-play > span {
  width: 60px; height: 60px; border-radius: 50%;
  background: rgba(0,0,0,0.55); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center;
}
.gallery-play > span::before {
  content: ""; width: 0; height: 0; margin-left: 4px;
  border-top: 11px solid transparent; border-bottom: 11px solid transparent;
  border-left: 18px solid var(--white);
}
.gallery-pager { flex: none; display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: clamp(12px, 3vh, 28px); }
.gallery-pages { display: flex; gap: 4px; }
.page-num {
  min-width: 44px; height: 44px; padding: 0 8px; border: 0; border-radius: var(--radius-button); cursor: pointer;
  background: none; color: var(--steel-300);
  font-family: var(--font-display); font-weight: 700; font-size: 22px;
  transition: color var(--dur-base), background var(--dur-base);
}
.page-num:hover { color: var(--white); background: rgba(255,255,255,0.06); }
.page-num.is-current { color: var(--black); background: var(--white); }
@media (max-width: 700px) {
  .gallery-play > span { width: 44px; height: 44px; }
  .gallery-play > span::before { border-top-width: 8px; border-bottom-width: 8px; border-left-width: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-tile::after, .gallery-poster { transition: none; }
  .gallery-grid [data-reveal] { animation: none !important; }
}

/* ===== Send Message: centred form over brushed steel. Gear at 70% of the form's width,
   centred on the form's edge and tucked behind it — left edge on desktop, bottom on mobile ===== */
.contact-bg {
  background-image:
    radial-gradient(55% 65% at 55% 50%, rgba(255,255,255,0.10) 0%, rgba(255,255,255,0) 70%),
    linear-gradient(180deg, rgba(0,0,0,0.35), rgba(0,0,0,0.1) 40%, rgba(0,0,0,0.5)),
    url('../assets/backgrounds/contact.webp');
}
.contact-inner { max-width: 1180px; }
.contact-head { display: flex; flex-direction: column; align-items: center; text-align: center; }
.contact-intro {
  max-width: 560px; margin: clamp(12px, 2vh, 20px) 0 0;
  color: var(--ink-200); font-size: clamp(15px, 0.3vw + 13px, 18px); line-height: 1.5; text-wrap: balance;
}
.contact-row { flex: 1 0 auto; display: flex; justify-content: center; align-items: center; }
.contact-card {
  position: relative; isolation: isolate;
  width: min(600px, 74%);
  margin-left: min(210px, 25.9%); /* room for the protruding half: 0.35 × card width */
}
.contact-gear {
  position: absolute; z-index: -1; left: 0; top: 50%;
  width: 70%; height: auto; transform: translate(-50%, -50%);
  pointer-events: none; user-select: none;
}
.contact-form {
  position: relative; display: flex; flex-direction: column; gap: 18px;
  padding: 30px 32px; border-radius: 15px; background: var(--white); box-shadow: var(--shadow-panel);
}
/* Send and the result toast share one box: the toast replaces the button, then the button returns */
.contact-send, .contact-toast { width: 100%; min-height: 58px; margin-top: 6px; animation: contact-swap-in 0.35s var(--ease-out) both; }
.ds-segment[aria-selected="false"]:hover { color: var(--black) !important; background: rgba(255,255,255,0.55) !important; }
.ds-segment:focus-visible, .contact-send:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; }
.contact-send svg { transition: transform var(--dur-base) var(--ease-standard); }
.contact-send:not(:disabled):hover svg { transform: translateX(4px); }
.contact-toast {
  display: flex; align-items: center; justify-content: center; text-align: center;
  padding: 8px 16px; border-radius: var(--radius-button);
  color: var(--white); font-family: var(--font-sans); font-size: 15px; line-height: 1.35;
}
.contact-toast--success { background: var(--success); }
.contact-toast--error   { background: var(--danger); }
@keyframes contact-swap-in { from { opacity: 0; transform: scale(0.97); } }
@media (max-width: 560px) {
  .contact-form { padding: 24px 20px; }
  .contact-toast { padding: 8px 12px; font-size: 13px; line-height: 1.3; }   /* longest (hy) message in 2 lines */
}
@media (prefers-reduced-motion: reduce) { .contact-toast, .contact-send { animation: none; } }
@media (max-width: 820px) {
  .contact-row { align-items: flex-start; }
  .contact-card { width: 100%; margin-left: 0; margin-bottom: 20.3%; /* half the gear's height (0.7 × 520/896 ÷ 2) */ }
  .contact-gear { left: 50%; top: 100%; }
}

/* ===== Testimonials: dark review cards on a dashed sine wave, over pale machined gears.
   The wave engine (src/vendor/orbit-slider) owns each .orbit's width/transform and the slider's
   height; the --orbit-* tokens below size it. Effects go on .tst-card, never on .orbit. ===== */
.tst-section { color: var(--black); }
.tst-bg {
  background-image:
    radial-gradient(75% 65% at 50% 52%, rgba(255,255,255,0.94) 0%, rgba(255,255,255,0.72) 60%, rgba(255,255,255,0.45) 100%),
    linear-gradient(180deg, rgba(255,255,255,0.7), rgba(255,255,255,0.2) 30%, rgba(255,255,255,0.2) 75%, rgba(236,234,234,0.75)),
    url('../assets/backgrounds/testimonials.webp');
  background-color: #f1f0f0;
}
.tst-inner { max-width: none; padding-left: 0; padding-right: 0; }
.tst-head { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 var(--gutter); margin-bottom: clamp(4px, 1.2vh, 16px); }
.tst-intro {
  max-width: 560px; margin: clamp(10px, 1.6vh, 18px) 0 0;
  color: var(--graphite-600); font-size: clamp(15px, 0.3vw + 13px, 18px); line-height: 1.5; text-wrap: balance;
}
.tst-stage { flex: 1 0 auto; display: flex; align-items: center; min-height: 0; }
.tst-slider {
  --orbit-min-height: 360px;
  --orbit-edge-padding: 20px;
  --orbit-vertical-padding: 40px;
  --orbit-amplitude-limit: 100;
  overflow: clip visible;   /* clip sideways only, so the cards' drop shadows aren't cut off at the bottom */
  outline: none;
}
.tst-slider:focus-visible { box-shadow: inset 0 0 0 3px var(--coral); }
@media (max-height: 820px) { .tst-slider { --orbit-amplitude-limit: 48; --orbit-min-height: 300px; --orbit-vertical-padding: 24px; } }
@media (max-height: 700px) { .tst-slider { --orbit-amplitude-limit: 28; } }
@media (max-width: 640px)  { .tst-slider { --orbit-amplitude-limit: 40; --orbit-min-height: 320px; } }

.tst-card {
  position: relative; isolation: isolate; overflow: hidden; margin: 0;
  display: flex; flex-direction: column; gap: 14px; min-height: 250px;   /* the current reviews all fit, so the cards line up */
  padding: 22px 24px 26px; border-radius: 22px; color: var(--white);
  border: 1.5px solid transparent;
  background:
    linear-gradient(160deg, #2e2b2b 0%, #161515 48%, #050505 100%) padding-box,
    linear-gradient(135deg, var(--fam) 0%, rgba(255,255,255,0.08) 38%, rgba(255,255,255,0.04) 62%, var(--fam-deep) 100%) border-box;
  box-shadow: 0 26px 50px -18px rgba(0,0,0,0.55), 0 8px 18px -10px rgba(0,0,0,0.4);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}
/* accent glow in the top corner + a big ghost quote mark */
.tst-card::before {
  content: ""; position: absolute; z-index: -1; top: -90px; right: -70px; width: 240px; height: 240px;
  border-radius: 50%; background: radial-gradient(circle, var(--fam) 0%, transparent 68%); opacity: 0.32;
}
.tst-card::after {
  content: "\201D"; position: absolute; z-index: -1; right: 14px; bottom: -58px;
  font: 900 190px/1 Georgia, 'Times New Roman', serif; color: var(--fam); opacity: 0.13; pointer-events: none;
}
.tst-card:hover { transform: translateY(-6px); box-shadow: 0 34px 60px -18px rgba(0,0,0,0.6), 0 10px 22px -10px rgba(0,0,0,0.45); }
.tst-card__top { display: flex; align-items: center; gap: 12px; }
.tst-avatar {
  flex: none; width: 48px; height: 48px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--fam), var(--fam-deep));
  box-shadow: 0 0 0 3px rgba(255,255,255,0.08), 0 6px 16px -4px var(--fam-deep);
  color: var(--white); font-family: var(--font-sans); font-weight: 800; font-size: 21px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}
.tst-who { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tst-name { font-family: var(--font-sans); font-weight: 800; font-size: 18px; line-height: 1.2; }
.tst-stars { display: flex; gap: 3px; color: #fbbc04; filter: drop-shadow(0 0 6px rgba(251, 188, 4, 0.45)); }
.tst-text {
  margin: 0; color: var(--ink-200);
  font-family: var(--font-sans); font-size: 16px; line-height: 1.55;
}
.tst-text::before { content: "\201C"; margin-right: 1px; color: var(--fam); font-weight: 900; }
.tst-text::after  { content: "\201D"; margin-left: 1px;  color: var(--fam); font-weight: 900; }
@media (max-width: 640px) {
  .tst-card { padding: 18px 18px 22px; min-height: 0; gap: 12px; }
  .tst-text { font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) { .tst-card { transition: none; } .tst-card:hover { transform: none; } }

/* ===== Find us + footer: map | address, phone, hours, socials, language, © ===== */
.findus-bg {
  background:
    radial-gradient(60% 70% at 0% 100%, rgba(79, 229, 234, 0.09) 0%, transparent 70%),
    radial-gradient(50% 60% at 100% 0%, rgba(255, 121, 121, 0.07) 0%, transparent 70%),
    linear-gradient(160deg, #262323 0%, #121111 55%, #050505 100%);
}
.findus-inner { gap: clamp(18px, 3.5vh, 36px); }
.findus-main {
  flex: 1; min-height: 0;
  display: grid; gap: clamp(24px, 4vw, 64px);
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 1fr);
}
.findus-map {
  position: relative; min-height: 220px; border-radius: 20px; overflow: hidden;
  box-shadow: var(--inset-subtle);
  background: repeating-linear-gradient(45deg, #3b3838 0 22px, #423f3f 22px 44px);
}
.findus-map iframe {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0;
  filter: invert(0.9) hue-rotate(180deg) saturate(0.55) contrast(0.95);   /* dark map to sit in the page */
  transition: filter 0.5s var(--ease-standard);
}
.findus-map:hover iframe { filter: none; }
.findus-info { display: flex; flex-direction: column; justify-content: center; gap: clamp(20px, 4vh, 36px); min-width: 0; }
.findus-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: clamp(12px, 2.4vh, 22px); }
.findus-phone { display: inline-block; color: inherit; text-decoration: none; border-radius: var(--radius-button); }
.findus-phone:hover span { text-decoration: underline; text-underline-offset: 4px; }
/* footer: Facebook, language, © — one centred row at the bottom, wrapping onto centred lines when narrow */
.findus-footer {
  flex: none; display: flex; align-items: center; justify-content: center; flex-wrap: wrap;
  gap: 12px 20px; text-align: center;
  padding-top: clamp(14px, 2.6vh, 24px); border-top: 1px solid rgba(255,255,255,0.12);
}
.findus-copy { margin: 0; color: var(--steel-300); font-size: 15px; line-height: 1.4; }
@media (max-width: 900px) {
  .findus-main { grid-template-columns: 1fr; grid-template-rows: minmax(170px, 1fr) auto; gap: 20px; }
  .findus-map { min-height: 170px; border-radius: 16px; }
  .findus-info { justify-content: flex-start; gap: 16px; }
  .findus-list span { font-size: 17px !important; }
  .findus-footer { flex-direction: column; gap: 10px; }
}
@media (prefers-reduced-motion: reduce) { .findus-map iframe { transition: none; } }

/* ===== Footer language switcher (components/forms/LanguageSwitcher.jsx) ===== */
.lang-switch {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px;
  max-width: 100%; flex-wrap: wrap; justify-content: center;
  border-radius: var(--radius-pill); background: rgba(0,0,0,0.35); box-shadow: var(--inset-subtle);
}
.lang-switch__icon { display: flex; padding: 0 6px 0 10px; color: var(--steel-400); }
.lang-switch__opt {
  min-height: 44px; padding: 0 18px; border: 0; border-radius: var(--radius-pill); cursor: pointer;
  background: transparent; color: var(--ink-200);
  font-family: var(--font-sans); font-weight: var(--fw-medium); font-size: var(--fs-ui); letter-spacing: var(--tracking-ui);
  transition: background var(--dur-base) var(--ease-standard), color var(--dur-base) var(--ease-standard);
}
.lang-switch__opt:hover { background: rgba(255,255,255,0.08); color: var(--white); }
.lang-switch__opt.is-active { background: var(--white); color: var(--black); cursor: default; }
.lang-switch__opt:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; }
@media (max-width: 400px) {
  .lang-switch__icon { display: none; }
  .lang-switch__opt { padding: 0 14px; }
}
@media (prefers-reduced-motion: reduce) { .lang-switch__opt { transition: none; } }
