/* ============================================================
   ЧАС ДЛЯ СЕБЕ — Blue-black, Mobile-first, 480px centered column
   border-radius: 5px everywhere
   ============================================================ */

:root {
  --bg:          #0c0e1a;
  --bg-alt:      #0c0e1a;
  --bg-card:     #101422;

  --accent:      #4d8cff;
  --accent-d:    #3a70e0;
  --accent-glow: rgba(77,140,255,0.25);

  --text:        #ffffff;
  --text-muted:  #8891aa;
  --text-dim:    #4a5268;

  --border:        rgba(255,255,255,0.07);
  --border-accent: rgba(77,140,255,0.38);

  /* 5px everywhere */
  --r: 5px;

  --font: 'Inter', 'Manrope', system-ui, -apple-system, sans-serif;
  --font-title: 'TTNooks', 'Manrope', system-ui, sans-serif;
  --ease: 0.3s cubic-bezier(0.4,0,0.2,1);

  --col: 480px;
  --gap: 20px;
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior:smooth; overflow-x:clip; }
body {
  font-family:var(--font);
  background: #d8dae5;
  color:var(--text);
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.3s ease;
  overflow-x: hidden;
  max-width: 100vw;
}
img { display:block; max-width:100%; user-select:none; -webkit-user-select:none; }
a { color:inherit; text-decoration:none; -webkit-tap-highlight-color: transparent; }
ul { list-style:none; }
button { font:inherit; color:inherit; cursor:pointer; border:none; -webkit-tap-highlight-color: transparent; }
::selection { background:var(--accent); color:#fff; }

.noise {
  position:fixed; inset:0; z-index:999; pointer-events:none; opacity:0.025;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ══════════════════════════════════════════════
   CONFETTI EXPLOSION
══════════════════════════════════════════════ */
.confetti-stage {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1000;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.confetti-stage.is-playing {
  opacity: 1;
}
.confetti-svg {
  width: 100%;
  height: 100%;
  display: block;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.confetti-piece {
  transform-box: fill-box;
  transform-origin: center;
  opacity: 0;
  will-change: transform, opacity;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.is-playing .confetti-piece {
  animation-name: var(--anim-name);
  animation-duration: var(--dur, 3.4s);
  animation-timing-function: linear;
  animation-delay: 0s;
  animation-fill-mode: forwards;
}
.accent { color:var(--accent); }

/* ══════════════════════════════════════════════
   LOADER
══════════════════════════════════════════════ */
.loader {
  position: fixed;
  inset: 0;
  z-index: 998;
  background: #08090f;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.55s cubic-bezier(0.4,0,0.2,1),
              visibility 0.55s cubic-bezier(0.4,0,0.2,1);
}
.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.loader__hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex: 1;
  justify-content: center;
}
.loader__model-wrap {
  width: min(60vw, 240px);
  aspect-ratio: 1 / 1;
}
.loader__title { display: none; }
.loader__progress-wrap { display: none; }

/* ── Column ── */
.col {
  width:100%;
  max-width:var(--col);
  margin-inline:auto;
  padding-inline:var(--gap);
}

/* ══════════════════════════════════════════════
   HERO
══════════════════════════════════════════════ */
.hero {
  background: transparent !important;
  display:flex;
  flex-direction:column;
  align-items:center;
  overflow:visible;
  position:relative;
  padding-top: 40px;
  padding-bottom: 120px; /* Место для нижних карточек */
}
.hero::before {
  content:''; position:absolute;
  width:480px; height:480px;
  background:radial-gradient(circle, rgba(77,140,255,0.10) 0%, transparent 68%);
  top:30%; left:50%; transform:translate(-50%,-50%);
  pointer-events:none;
  opacity: 0;
  display: none; /* Свечение отключено */
  transition: opacity 1.4s ease-out 0.5s;
}
.hero-ready .hero::before {
  opacity: 0;
}
.hero::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(to bottom, #d8dae5 0%, transparent 100%);
  pointer-events: none;
  z-index: 5;
}

.hero__3d-wrap {
  width:100%; max-width:var(--col);
  aspect-ratio:4/3;
  overflow:visible; background:transparent; position:relative;
  margin-bottom: 16px;
  margin-top: 80px;
  margin-top: 80px;
  z-index: 1;
  opacity: 0;
  transition: opacity 1.2s ease-out;
}
.hero-ready .hero__3d-wrap {
  opacity: 1;
}
.hero__3d-wrap model-viewer {
  width:100%; height:100%; display:block;
  --progress-bar-height:0px; --progress-bar-color:transparent;
}

.hero__content {
  width:100%; max-width:var(--col);
  padding:0 var(--gap) 24px;
  text-align:center;
  position: relative;
  z-index: 3;
}

.hero__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 20px 20px 18px;
  background: rgba(77,140,255,0.06);
  border: 1px solid var(--border-accent);
  border-radius: var(--r);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  --card-bg: rgb(10, 11, 20);
  opacity: 0;
}
.hero-ready .hero__card {
  animation: heroCardIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.6s forwards;
}
@keyframes heroCardIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Model glow fade-in ── */
.hero__3d-wrap model-viewer {
  filter: drop-shadow(0 0 0px rgba(77,180,255,0)) drop-shadow(0 0 0px rgba(77,180,255,0));
}
.hero-ready .hero__3d-wrap model-viewer {
  animation: modelGlowIn 1.4s ease-out 1.0s forwards;
}
@keyframes modelGlowIn {
  from { filter: drop-shadow(0 0 0px rgba(77,180,255,0)) drop-shadow(0 0 0px rgba(77,180,255,0)); }
  to   { filter: drop-shadow(0 0 54px rgba(77,180,255,0.7)) drop-shadow(0 0 120px rgba(77,180,255,0.35)); }
}
.hero__ticker-fade--left  { left: 0;  background: linear-gradient(to right, var(--card-bg) 0%, var(--card-bg) 15%, transparent 100%); }
.hero__ticker-fade--right { right: 0; background: linear-gradient(to left,  var(--card-bg) 0%, var(--card-bg) 15%, transparent 100%); }

/* ── Hero review cards ── */
@keyframes reviewFlyLeft {
  from {
    opacity: 0;
    transform: translateX(180px) scale(0.85);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}
@keyframes reviewFlyRight {
  from {
    opacity: 0;
    transform: translateX(-180px) scale(0.85);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

.hero-reviews {
  position: absolute;
  top: -100px;
  bottom: -200px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  pointer-events: none;
  perspective: 600px;
}
.hero-reviews--left  {
  left: calc(50% - 240px - 8px);
  transform: translateX(-100%) perspective(500px) rotateY(30deg);
  transform-origin: right center;
  flex-direction: row-reverse;
}
.hero-reviews--right {
  right: calc(50% - 240px - 8px);
  transform: translateX(100%) perspective(500px) rotateY(-30deg);
  transform-origin: left center;
  flex-direction: row-reverse;
}

/* Шахматное смещение колонок */
.hero-reviews--left  .hero-reviews__col--a { margin-top: 160px; }
.hero-reviews--left  .hero-reviews__col--b { margin-top: 82px; }
.hero-reviews--left  .hero-reviews__col--c { margin-top: 170px; }
.hero-reviews--left  .hero-reviews__col--d { margin-top: 220px; }
.hero-reviews--right .hero-reviews__col--a { margin-top: 160px; }
.hero-reviews--right .hero-reviews__col--b { margin-top: 82px; }
.hero-reviews--right .hero-reviews__col--c { margin-top: 170px; }
.hero-reviews--right .hero-reviews__col--d { margin-top: 220px; }

.hero-reviews__col {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
/* Col with 2 cards — outer; col with 3 cards — inner (closer to logo) */
.hero-reviews--left  .hero-reviews__col--a { order: 1; }
.hero-reviews--left  .hero-reviews__col--b { order: 2; }
.hero-reviews--left  .hero-reviews__col--c { order: 3; }
.hero-reviews--left  .hero-reviews__col--d { order: 4; }
.hero-reviews--right .hero-reviews__col--a { order: 3; }
.hero-reviews--right .hero-reviews__col--b { order: 2; }
.hero-reviews--right .hero-reviews__col--c { order: 1; }
.hero-reviews--right .hero-reviews__col--d { order: 0; }

.hero-review-card {
  width: 75px;
  min-height: 100px;
  height: auto;
  border-radius: 18px;
  background: rgba(230, 230, 235, 0.95);
  border: none;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  flex-shrink: 0;
  opacity: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 
    0 0.5px 1px rgba(0, 0, 0, 0.08),
    0 1px 2px rgba(0, 0, 0, 0.12);
  position: relative;
  padding: 6px 8px;
  gap: 4px;
  will-change: transform, opacity;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.hero-review-card:hover {
  transform: scale(1.02);
  box-shadow: 
    0 1px 2px rgba(0, 0, 0, 0.12),
    0 2px 4px rgba(0, 0, 0, 0.16);
}
.hero-review-card__top {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border-bottom: none;
  flex-shrink: 0;
}
.hero-review-card__avatar {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: transparent;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}
.hero-review-card__avatar img {
  width: 18px !important;
  height: 18px !important;
  min-width: 0 !important;
  min-height: 0 !important;
  max-width: 18px !important;
  max-height: 18px !important;
  object-fit: contain !important;
  display: block !important;
}
.hero-review-card__name {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', var(--font);
  font-size: 9px;
  font-weight: 700;
  color: rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hero-review-card__text {
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', var(--font);
  font-size: 7px;
  font-weight: 400;
  color: rgba(0, 0, 0, 0.85);
  line-height: 1.4;
  flex: 1;
  overflow: hidden;
  margin: 0;
  position: relative;
  -webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
}

/* Запускаем только после скрытия лоадера — JS добавляет .hero-ready на body */
.hero-ready .hero-review-card {
  animation-duration: 0.125s;
  animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
  animation-fill-mode: forwards;
}
.hero-ready .hero-reviews--left .hero-review-card  { animation-name: reviewFlyLeft; }
.hero-ready .hero-reviews--right .hero-review-card { animation-name: reviewFlyRight; }

.hero-ready .hero-reviews--left  .hero-reviews__col--b .hero-review-card:nth-child(1) { animation-delay: 0.6s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--b .hero-review-card:nth-child(2) { animation-delay: 0.64s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--b .hero-review-card:nth-child(3) { animation-delay: 0.68s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--b .hero-review-card:nth-child(4) { animation-delay: 0.72s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--b .hero-review-card:nth-child(5) { animation-delay: 0.76s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--a .hero-review-card:nth-child(1) { animation-delay: 0.62s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--a .hero-review-card:nth-child(2) { animation-delay: 0.66s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--a .hero-review-card:nth-child(3) { animation-delay: 0.70s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--c .hero-review-card:nth-child(1) { animation-delay: 0.64s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--c .hero-review-card:nth-child(2) { animation-delay: 0.68s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--c .hero-review-card:nth-child(3) { animation-delay: 0.72s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--c .hero-review-card:nth-child(4) { animation-delay: 0.76s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--c .hero-review-card:nth-child(5) { animation-delay: 0.80s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--d .hero-review-card:nth-child(1) { animation-delay: 0.66s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--d .hero-review-card:nth-child(2) { animation-delay: 0.70s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--d .hero-review-card:nth-child(3) { animation-delay: 0.74s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--d .hero-review-card:nth-child(4) { animation-delay: 0.78s; }
.hero-ready .hero-reviews--left  .hero-reviews__col--d .hero-review-card:nth-child(5) { animation-delay: 0.82s; }

.hero-ready .hero-reviews--right .hero-reviews__col--b .hero-review-card:nth-child(1) { animation-delay: 0.6s; }
.hero-ready .hero-reviews--right .hero-reviews__col--b .hero-review-card:nth-child(2) { animation-delay: 0.64s; }
.hero-ready .hero-reviews--right .hero-reviews__col--b .hero-review-card:nth-child(3) { animation-delay: 0.68s; }
.hero-ready .hero-reviews--right .hero-reviews__col--b .hero-review-card:nth-child(4) { animation-delay: 0.72s; }
.hero-ready .hero-reviews--right .hero-reviews__col--b .hero-review-card:nth-child(5) { animation-delay: 0.76s; }
.hero-ready .hero-reviews--right .hero-reviews__col--a .hero-review-card:nth-child(1) { animation-delay: 0.62s; }
.hero-ready .hero-reviews--right .hero-reviews__col--a .hero-review-card:nth-child(2) { animation-delay: 0.66s; }
.hero-ready .hero-reviews--right .hero-reviews__col--a .hero-review-card:nth-child(3) { animation-delay: 0.70s; }
.hero-ready .hero-reviews--right .hero-reviews__col--c .hero-review-card:nth-child(1) { animation-delay: 0.64s; }
.hero-ready .hero-reviews--right .hero-reviews__col--c .hero-review-card:nth-child(2) { animation-delay: 0.68s; }
.hero-ready .hero-reviews--right .hero-reviews__col--c .hero-review-card:nth-child(3) { animation-delay: 0.72s; }
.hero-ready .hero-reviews--right .hero-reviews__col--c .hero-review-card:nth-child(4) { animation-delay: 0.76s; }
.hero-ready .hero-reviews--right .hero-reviews__col--c .hero-review-card:nth-child(5) { animation-delay: 0.80s; }
.hero-ready .hero-reviews--right .hero-reviews__col--d .hero-review-card:nth-child(1) { animation-delay: 0.66s; }
.hero-ready .hero-reviews--right .hero-reviews__col--d .hero-review-card:nth-child(2) { animation-delay: 0.70s; }
.hero-ready .hero-reviews--right .hero-reviews__col--d .hero-review-card:nth-child(3) { animation-delay: 0.74s; }
.hero-ready .hero-reviews--right .hero-reviews__col--d .hero-review-card:nth-child(4) { animation-delay: 0.78s; }
.hero-ready .hero-reviews--right .hero-reviews__col--d .hero-review-card:nth-child(5) { animation-delay: 0.82s; }



.hero__title {
  font-family: var(--font-title);
  font-size: clamp(22px, 7vw, 38px);
  font-weight: 900;
  line-height: 1.0;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0;
  white-space: nowrap;
  color: var(--accent);
}

.hero__slogan {
  font-family: var(--font);
  font-size: clamp(13px, 3.5vw, 16px);
  font-weight: 800;
  color: #ffffff;
  opacity: 1;
  margin-bottom: 2px;
  line-height: 1.4;
  width: 100%;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
  text-shadow:
    0 0 8px rgba(255,255,255,0.9),
    0 0 20px rgba(255,255,255,0.6),
    0 0 40px rgba(255,255,255,0.3);
  box-sizing: border-box;
}
.hero__slogan--glow {
  /* glow now on entire slogan */
}
.hero__ticker-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  overflow-x: hidden;
  overflow-y: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 15%, black 85%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, black 15%, black 85%, transparent 100%);
}
.hero__ticker {
  overflow: hidden;
  white-space: nowrap;
  display: block;
  width: 100%;
}
.hero__ticker-inner {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  animation: heroTicker 28s linear infinite;
  font-family: var(--font-title);
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  opacity: 0.6;
  letter-spacing: 0.05em;
  text-transform: lowercase;
  white-space: nowrap;
}
@keyframes heroTicker {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.hero__ticker-sep {
  color: var(--accent);
  opacity: 1;
  font-size: 13px;
  line-height: 1;
}
.hero__ticker-fade {
  position: absolute;
  top: 0; bottom: 0; width: 60px;
  z-index: 2; pointer-events: none;
}

.hero__location {
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:8px 16px;
  background:var(--accent);
  color:#fff;
  font-size:15px;
  font-weight:600;
  border-radius:var(--r);
  white-space:nowrap;
  transition:filter var(--ease);
}
.hero__location:hover { filter:brightness(1.12); }
.hero__location svg { flex-shrink:0; }
.hero__location--full {
  display:flex;
  width:100%;
  justify-content:center;
}

/* ── Hero map ── */
.hero__map {
  width: 100%;
  border-radius: var(--r);
  overflow: hidden;
  aspect-ratio: 16/7;
  border: 1px solid var(--border-accent);
}
.hero__map iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: none;
}

/* ── Hero CTA row ── */
.hero__cta-row {
  display: flex;
  gap: 6px;
  width: 100%;
  flex-wrap: wrap;
  overflow: visible; /* Не обрезаем тултипы */
}
.hero__cta-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 10px;
  border-radius: var(--r);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  white-space: nowrap;
  transition: filter 0.2s;
}
.hero__cta-btn:hover { filter: brightness(1.15); }
.hero__cta-btn img {
  flex-shrink: 0;
  filter: brightness(0) invert(1);
  opacity: 0.95;
}
.hero__cta-btn svg { flex-shrink: 0; }
.hero__cta-btn--tg {
  background: #29b6f6;
  color: #fff;
}
.hero__cta-btn--ig {
  background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af);
  color: #fff;
}
.hero__cta-btn--contacts {
  background: var(--accent);
  color: #fff;
  border: none;
}

/* ── Hero card overlay — між hero і bridge ── */
.hero-card-overlay {
  display: flex;
  justify-content: center;
  padding: 24px var(--gap) 0;
  position: relative;
  z-index: 3;
  overflow: visible; /* Не обрезаем тултипы */
}
.hero-card-overlay .hero__card {
  width: 100%;
  max-width: var(--col);
  overflow: visible; /* Не обрезаем тултипы */
}

/* ── Gradient bridge hero → next section ── */
.section-bridge {
  height: 96px;
  background: linear-gradient(to bottom, transparent 0%, #0c0e1a 100%);
  pointer-events: none;
  position: relative;
  z-index: 1;
}
/* alt(#0c0e1a) → bg(#08090f) */
.section-bridge--alt-to-bg {
  background: linear-gradient(to bottom, #0c0e1a 0%, #0c0e1a 100%);
  margin-top: 0;
  height: 48px;
}
/* bg(#08090f) → alt(#0c0e1a) */
.section-bridge--bg-to-alt {
  background: linear-gradient(to bottom, #0c0e1a 0%, #0c0e1a 100%);
  margin-top: 0;
  height: 48px;
}

/* ══════════════════════════════════════════════
   SECTIONS
══════════════════════════════════════════════ */
.section      { padding:48px 0; background: transparent; }
.section--alt { background: transparent; }
/* Services section — less top gap */
#services { padding-top: 16px; }

.section-title {
  font-size:clamp(24px,7vw,34px);
  font-weight:800;
  line-height:1.1;
  letter-spacing:-0.02em;
  margin-bottom:6px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.section-title__ico {
  flex-shrink: 0;
  opacity: 0.85;
  display: block;
  width: 36px;
  height: 36px;
  filter: brightness(0) saturate(100%) invert(53%) sepia(60%) saturate(800%) hue-rotate(195deg) brightness(1.1);
}
.section-sub {
  font-size:14px;
  color:var(--text-muted);
  margin-bottom:24px;
}

/* ══════════════════════════════════════════════
   CERT — single card with flip animation
══════════════════════════════════════════════ */

#certificates { overflow-x: hidden; padding-top: 4px; padding-bottom: 48px; }

.cert-carousel-wrap {
  width: 100%;
  max-width: var(--col);
  margin-inline: auto;
  padding: 40px 0 0;
  isolation: isolate;
}

.cert-flip-wrap {
  width: 100%;
  max-width: var(--col);
  margin-inline: auto;
  height: 460px;
  transform-origin: center center;
  will-change: transform;
}

.cert-flip-wrap.is-flipping-out {
  animation: certFlipOut 0.36s ease-in-out forwards;
}
.cert-flip-wrap.is-flipping-in {
  animation: certFlipIn 0.36s ease-in-out forwards;
}
@keyframes certFlipOut {
  0%   { transform: scaleX(1);   filter: none; }
  30%  { transform: scaleX(0.5); filter: url(#hblur-6); }
  50%  { transform: scaleX(0);   filter: url(#hblur-14); }
  70%  { transform: scaleX(0.5); filter: url(#hblur-6); }
  100% { transform: scaleX(1);   filter: none; }
}
/* Mobile — same single flip (media override kept for safety) */
@media (max-width: 639px) {
  @keyframes certFlipOut {
    0%   { transform: scaleX(1);   filter: none; }
    30%  { transform: scaleX(0.5); filter: url(#hblur-6); }
    50%  { transform: scaleX(0);   filter: url(#hblur-14); }
    70%  { transform: scaleX(0.5); filter: url(#hblur-6); }
    100% { transform: scaleX(1);   filter: none; }
  }
}
@keyframes certFlipIn {
  0%   { transform: scaleX(1); filter: none; }
  100% { transform: scaleX(1); filter: none; }
}

.cert-model-viewer {
  width: 100%;
  height: 460px;
  display: block;
  background: transparent;
  position: relative;
  z-index: 1;
  --progress-bar-height: 0px;
  --progress-bar-color: transparent;
}

/* ── Cert shimmer canvas ── */
.cert-particle-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}
#certificates {
  position: relative;
}
/* ── PNG cert card — pseudo-3D sway + shimmer ── */
.cert-img-card {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: certImgSway 3s ease-in-out infinite;
  will-change: transform;
  /* inner wrapper for shimmer alignment */
  pointer-events: none;
}

@keyframes certImgSway {
  0%   { transform: perspective(600px) rotateY(-4deg) rotateX(1.5deg); }
  50%  { transform: perspective(600px) rotateY( 4deg) rotateX(-1.5deg); }
  100% { transform: perspective(600px) rotateY(-4deg) rotateX(1.5deg); }
}

/* Inner wrapper — let PNG define its own proportions */
.cert-img-card__inner {
  position: relative;
  /* fit within the 460px slot, PNG scales naturally */
  max-height: 360px;
  width: auto;
  /* prevent overflow of parent */
  max-width: 90%;
  flex-shrink: 0;
}

.cert-img-card__img {
  width: auto;
  height: 360px;
  max-width: 100%;
  display: block;
  border-radius: 18px;
  box-shadow: 0 12px 48px rgba(0,0,0,0.6);
  object-fit: contain;
  position: relative;
  z-index: 1;
}

/* Surface sheen sweep — covers exactly the img */
.cert-img-card__sheen {
  position: absolute;
  inset: 0;
  border-radius: 18px;
  background: linear-gradient(
    115deg,
    transparent 20%,
    rgba(255,255,255,0.04) 35%,
    rgba(255,255,255,0.16) 45%,
    rgba(255,255,255,0.04) 55%,
    transparent 70%
  );
  background-size: 300% 100%;
  animation: certImgSheen 4s ease-in-out infinite;
  pointer-events: none;
  z-index: 2;
}

@keyframes certImgSheen {
  0%   { background-position: 200% center; }
  60%  { background-position: -100% center; }
  100% { background-position: -100% center; }
}

/* Shimmer border canvas — exactly over the inner wrapper */
.cert-img-card__shimmer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
  border-radius: 18px;
}

.cert-shimmer-canvas { display: none; }
.cert-particle-canvas {
  position: absolute;
  top: -60px;
  bottom: 0;
  left: -80px; right: -80px;
  width: calc(100% + 160px);
  height: calc(100% + 60px);
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

/* Old carousel styles — removed */
.cert-carousel, .cert-slide { display: none; }

/* ── Cert folder tabs ── */
.cert-tabs-wrap {
  padding: 0;
}
.cert-tabs {
  display: flex;
  gap: 4px;
  padding: 0;
}
.cert-tab {
  flex: 1;
  padding: 9px 6px 13px;
  border: none;
  border-radius: 8px 8px 0 0;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  background: rgba(255,255,255,0.07);
  color: var(--text-muted);
  position: relative;
  bottom: -1px;
  letter-spacing: 0.02em;
}
.cert-tab:hover {
  background: rgba(255,255,255,0.12);
  color: var(--text);
}
.cert-tab.is-active {
  bottom: 0;
  z-index: 2;
}
.cert-gift-block {
  margin-top: 0;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0 0 var(--r) var(--r);
}
.cert-gift-block__top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  justify-content: space-between;
}
.cert-gift-block__texts {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.cert-gift-block__title {
  font-size: 15px;
  font-weight: 700;
  color: inherit;
}
.cert-gift-block__sub {
  font-size: 13px;
  line-height: 1.55;
  opacity: 0.75;
}
.cert-gift-block__icon-img {
  width: 22px; height: 22px;
  flex-shrink: 0;
  margin-top: 2px;
  color: inherit;
}
.cert-buy-wrap {
  position: relative;
  border-radius: calc(var(--r) + 3px);
}
.cert-buy-shimmer { display: none; }
.cert-buy-btn {
  display: block;
  text-align: center;
  padding: 13px 16px;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  background: var(--accent);
  position: relative;
  z-index: 1;
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
  border: none;
  outline: 2px solid rgba(0,0,0,0.25);
  outline-offset: -2px;
}

/* Diagonal surface shimmer removed */
.cert-buy-btn::before { display: none; }

.cert-buy-btn:hover { filter: brightness(1.1); }
.cert-buy-btn strong { font-weight: 800; }

/* ── Cert program toggle ── */
.cert-program-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 9px 12px;
  border-radius: var(--r);
  border: 1.5px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.08);
  color: inherit;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.cert-program-toggle:hover { background: rgba(255,255,255,0.14); }
.cert-program-toggle__arrow {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}
.cert-program-toggle[aria-expanded="true"] .cert-program-toggle__arrow {
  transform: rotate(180deg);
}
.cert-program-table {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.cert-program-table.is-open { max-height: 500px; }
.cert-program-disclaimer {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 6px;
  padding: 9px 12px;
  font-size: 11px;
  font-weight: 600;
  opacity: 1;
  line-height: 1.5;
  color: inherit;
}
.cert-program-disclaimer svg {
  flex-shrink: 0;
  margin-top: 1px;
  opacity: 0.7;
}
.cert-program-table__inner {
  margin-top: 6px;
  border: 1.5px solid rgba(255,255,255,0.22);
  border-radius: var(--r);
  overflow: hidden;
}
.cert-program-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.cert-program-table th {
  text-align: left;
  padding: 7px 8px;
  opacity: 0.6;
  font-weight: 600;
  border-bottom: 1.5px solid rgba(255,255,255,0.22);
  border-right: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.15);
}
.cert-program-table th:last-child { border-right: none; }
.cert-program-table td {
  padding: 7px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  border-right: 1px solid rgba(255,255,255,0.08);
  line-height: 1.4;
  color: inherit;
}
.cert-program-table td:last-child { border-right: none; }
.cert-program-table tr:last-child td { border-bottom: none; }
.cert-program-table td:nth-child(1) { opacity: 0.6; width: 32px; text-align: center; }
.cert-program-table td:nth-child(3) { opacity: 0.7; white-space: nowrap; }
.cert-program-table td:nth-child(4) { font-weight: 700; white-space: nowrap; text-align: right; }

/* ══════════════════════════════════════════════
   SNAP DOTS
══════════════════════════════════════════════ */
.snap-dots {
  display:flex; gap:6px; justify-content:center;
  margin-top:16px;
}
.snap-dot {
  width:6px; height:6px;
  border-radius:50%;
  background:rgba(255,255,255,0.12);
  transition:all 0.3s ease;
  cursor:pointer;
}
.snap-dot.is-active {
  background:var(--accent);
  width:22px; border-radius:3px;
}

/* ══════════════════════════════════════════════
   SERVICES — horizontal snap scroll + fade sides
══════════════════════════════════════════════ */
.snap-wrap {
  width:100%; max-width:var(--col);
  margin-inline:auto;
  overflow:hidden;
}

.snap-track {
  width:100%;
  overflow-x:auto; overflow-y:hidden;
  scrollbar-width:none;
  -webkit-overflow-scrolling:touch;
  scroll-snap-type:x mandatory;
  scroll-behavior:smooth;
  scroll-padding-inline: 48px;
  /* allow horizontal swipe on touch without blocking vertical page scroll */
  touch-action: pan-x;
}
.snap-track::-webkit-scrollbar { display:none; }

.snap-inner {
  display:flex;
  padding-inline: 48px;
  gap:12px;
  width:max-content;
}

/* Hint sway — nudges left then right to show scrollability */
@keyframes snapHint {
  0%   { transform: translateX(0); }
  20%  { transform: translateX(-28px); }
  45%  { transform: translateX(14px); }
  65%  { transform: translateX(-10px); }
  80%  { transform: translateX(5px); }
  100% { transform: translateX(0); }
}
.snap-inner.snap-hint {
  animation: snapHint 1.6s cubic-bezier(0.4, 0, 0.2, 1) 1 forwards;
}

.services-scroll-wrap {
  position:relative;
  width:100%;
  max-width:var(--col);
  margin-inline:auto;
  /* clip horizontal fades without cutting card shadows vertically */
  overflow-x:hidden;
  overflow-y:visible;
}
.services-fade {
  position:absolute;
  top:0; bottom:0; width:48px;
  z-index:2; pointer-events:none;
}
.services-fade--left  { left:0;  background:linear-gradient(to right, var(--bg-alt) 0%, transparent 100%); }
.services-fade--right { right:0; background:linear-gradient(to left,  var(--bg-alt) 0%, transparent 100%); }
.services-scroll-wrap .snap-track { overflow-x:auto; overflow-y:hidden; }

/* ── Service card ── */
.service-card {
  width: min(calc(var(--col) * 0.72), calc(100vw - 96px));
  max-width: calc(var(--col) * 0.72);
  flex-shrink: 0;
  scroll-snap-align: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 20px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  height: auto;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.service-card:hover { border-color:var(--border-accent); box-shadow:0 0 36px var(--accent-glow); }

.service-card__ico {
  width:46px; height:46px;
  display:flex; align-items:center; justify-content:center;
  background:rgba(77,140,255,0.1);
  border:1px solid var(--border-accent);
  border-radius:var(--r);
}
.service-card__ico img {
  width:24px; height:24px;
  /* tint to --accent (#4d8cff) */
  filter: brightness(0) saturate(100%) invert(53%) sepia(60%) saturate(800%) hue-rotate(195deg) brightness(1.1);
}
.service-card__name { font-size:21px; font-weight:800; line-height:1.2; color: var(--accent); }
.service-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.service-card__desc { font-size:13px; color:var(--text-muted); line-height:1.6; flex:1; }
.service-card__tags { display:flex; flex-wrap:wrap; gap:6px; }
.service-card__tags span {
  font-size:11px; font-weight:600; color:var(--accent);
  border:1px solid var(--border-accent); border-radius:20px;
  padding:3px 10px; letter-spacing:.03em;
}
.service-card__btns {
  display: flex;
  flex-direction: row;
  gap: 8px;
  margin-top: auto;
}
.service-card__btns .btn {
  flex: 1;
}

/* ══════════════════════════════════════════════
   BUTTONS
══════════════════════════════════════════════ */
.btn {
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  padding:13px 22px; font-size:14px; font-weight:700;
  border-radius:var(--r); border:none;
  transition:transform var(--ease), filter var(--ease),
             background var(--ease), color var(--ease);
  white-space:nowrap;
}
.btn--accent  { background:var(--accent); color:#fff; }
.btn--accent:hover  { filter:brightness(1.15); }
.btn--accent:active { transform:scale(0.97); }
.btn--outline { background:transparent; color:var(--accent); border:1px solid var(--border-accent); }
.btn--outline:hover  { background:var(--accent); color:#fff; }
.btn--outline:active { transform:scale(0.97); }
.btn--full { width:100%; }

/* ══════════════════════════════════════════════
   PRICE ACCORDION
══════════════════════════════════════════════ */
.price-accordion {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.price-acc__group {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
}

.price-acc__head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(77,140,255,0.07);
  border: none;
  border-left: 3px solid var(--accent);
  cursor: pointer;
  font-family: var(--font);
  text-align: left;
  gap: 10px;
}
.price-acc__head:hover { background: rgba(77,140,255,0.12); }

/* Left side: icon + title */
.price-acc__head-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.price-acc__ico {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  filter: brightness(0) saturate(100%) invert(53%) sepia(60%) saturate(800%) hue-rotate(195deg) brightness(1.1);
}

.price-acc__title {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--accent);
}

.price-acc__arrow {
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 0.3s ease;
}
.price-acc__head[aria-expanded="true"] .price-acc__arrow {
  transform: rotate(180deg);
}

/* collapsed: show ~3 rows then fade */
.price-acc__body {
  position: relative;
  max-height: 132px; /* ~3 rows × 44px */
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.price-acc__body.is-open {
  max-height: 800px;
}
.price-acc__body.is-open .price-acc__fade {
  opacity: 0;
  pointer-events: none;
}

.price-acc__fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 56px;
  background: linear-gradient(to bottom, transparent 0%, var(--bg-card) 100%);
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 2;
}

.price-acc__more {
  display: block;
  width: 100%;
  padding: 9px 16px;
  background: none;
  border: none;
  border-top: 1px solid var(--border);
  color: var(--accent);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: background var(--ease);
}
.price-acc__more:hover { background: rgba(77,140,255,0.06); }

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.price-row:last-child { border-bottom: none; }
.price-row span:first-child { color: var(--text); font-weight: 500; }
.price-row span:last-child  { font-weight: 700; flex-shrink: 0; white-space: nowrap; color: var(--accent); }
.price-row em { font-style: normal; color: var(--accent); }

/* Legacy price-list — kept for compat */
.price-list { display:flex; flex-direction:column; gap:20px; }
.price-group {
  background:var(--bg-card);
  border:1px solid var(--border);
  border-radius:var(--r); overflow:hidden;
}
.price-group__title {
  padding:10px 16px;
  font-size:11px; font-weight:800; letter-spacing:.1em; text-transform:uppercase;
  color:var(--accent);
  background:rgba(77,140,255,0.07);
  border-bottom:1px solid var(--border);
  border-left:3px solid var(--accent);
}
.price-more-wrap {
  position: relative;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}
.price-more-wrap.is-open { max-height: 300px; }
.price-more-wrap.is-open .price-more-fade { display: none; }
.price-more-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--bg-alt));
  pointer-events: none;
  z-index: 2;
}
.price-more-btn {
  width: 100%;
  padding: 10px;
  background: none;
  border: none;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
}
.price-more-btn:hover { opacity: 0.8; }

/* ── Price item ── */
.price-item {
  display:flex; align-items:center; gap:8px;
  padding:12px 16px; border-bottom:1px solid var(--border);
}
.price-item:last-child { border-bottom:none; }
.price-item__name { font-size:14px; font-weight:500; }
.price-item__line { flex:1; }
.price-item__val  { font-size:14px; font-weight:700; flex-shrink:0; }

.price-note {
  display:flex; align-items:flex-start; gap:8px;
  padding:16px 20px;
  background:rgba(77,140,255,0.07);
  border:1px solid var(--border-accent);
  border-left:3px solid var(--accent);
  border-radius:var(--r);
  font-size:14px; font-weight:500; color:var(--text-muted); line-height:1.65;
}
/* info icons — match surrounding text color */

/* lot-card__rules-note: amber text #7a4e00 */
.lot-card__rules-note img {
  filter: brightness(0) saturate(100%) invert(28%) sepia(35%) saturate(700%) hue-rotate(15deg) brightness(0.75);
  flex-shrink: 0;
}

/* cert-program-disclaimer: color inherited from giftBlock JS — white tint matches fg */
.cert-program-disclaimer img {
  filter: brightness(0) invert(1);
  opacity: 0.65;
  flex-shrink: 0;
}

/* price-note: var(--text-muted) = #8891aa — grey-blue */
.price-note img {
  flex-shrink: 0;
  margin-top: 2px;
  filter: brightness(0) saturate(15%) invert(62%) sepia(8%) hue-rotate(195deg);
}

/* ══════════════════════════════════════════════
   LOT CARD — credit card style: 1/3 pink top, 2/3 yellow bottom
══════════════════════════════════════════════ */
.lot-card {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
  /* Credit card aspect ratio ~1.586:1 */
  aspect-ratio: 1.586 / 1;
  display: flex;
  flex-direction: column;
}

/* Icon pattern — SVG imgs, no canvas, stays crisp */
.lot-card__pattern-wrap {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}
.lot-card__pattern-wrap img {
  position: absolute;
  display: block;
}

/* Top 1/3 — pink */
.lot-card__top {
  flex: 0 0 auto;
  min-height: 56px;
  background: #c8860a;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
}
.lot-card__title {
  font-family: var(--font);
  font-size: clamp(18px, 6vw, 28px);
  font-weight: 900;
  color: #ffe033;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1;
}

/* Bottom 2/3 — yellow */
.lot-card__body {
  flex: 2;
  background: #f5e6ad;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 16px 14px;
  gap: 10px;
}
.lot-card__rules {
  display: flex;
  flex-direction: column;
  gap: 3px;
  background: rgba(200,134,10,0.12);
  border: 1px solid rgba(200,134,10,0.45);
  border-radius: 6px;
  padding: 8px 12px;
  width: 100%;
}
.lot-card__rules span {
  font-size: clamp(10px, 2.8vw, 12px);
  font-weight: 600;
  color: #7a4e00;
  line-height: 1.5;
}
.lot-card__rules-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: rgba(200,134,10,0.12);
  border: 1px solid rgba(200,134,10,0.45);
  border-radius: 6px;
  padding: 9px 12px;
  width: 80%;
  font-size: clamp(10px, 2.8vw, 12px);
  font-weight: 600;
  color: #7a4e00;
  line-height: 1.5;
}
.lot-card__rules-note svg {
  flex-shrink: 0;
  margin-top: 1px;
  color: #c8860a;
}
.lot-card__disclaimer {
  font-size: clamp(9px, 2.5vw, 11px);
  color: rgba(200,134,10,0.7);
  text-align: center;
  line-height: 1.4;
  font-family: var(--font);
  letter-spacing: 0.03em;
  width: 100%;
}

/* ── Lot card shimmer overlay (over the whole card) ── */
.lot-card {
  position: relative;
  overflow: hidden;
}
/* Diagonal metallic sheen — sweeps across the card */
.lot-card::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 9;
  pointer-events: none;
  background: linear-gradient(
    115deg,
    transparent 20%,
    rgba(255,255,220,0.18) 35%,
    rgba(255,255,255,0.38) 45%,
    rgba(255,250,200,0.18) 55%,
    transparent 70%
  );
  background-size: 300% 100%;
  animation: lotSheen 5s ease-in-out infinite;
  border-radius: inherit;
}
@keyframes lotSheen {
  0%   { background-position: 200% center; }
  60%  { background-position: -100% center; }
  100% { background-position: -100% center; }
}
/* Remove old CSS shimmer — replaced by canvas shimmer border */
.lot-card::after { display: none; }

/* ── Tilt wrapper ── */
.lot-scene {
  width: 100%;
  overflow: visible;
}

.lot-tilt-wrap {
  position: relative;
  width: 100%;
  will-change: transform;
  animation: lotSway 4s ease-in-out infinite;
  /* no overflow — door flap must not be clipped */
}

/* will-change on the wrapper, not the card */
.lot-tilt-wrap .lot-card {
  position: relative;
  z-index: 1;
  overflow: hidden;
}

/* ── Already played note — inside card, below scratch ── */
.lot-card__played-note {
  font-size: 13px;
  font-weight: 700;
  color: #6b7280;
  text-align: center;
  line-height: 1.4;
  padding: 0 4px 2px;
}

/* ── Bot link door flap ── */
.lot-door-wrap {
  width: 90%;
  margin: 6px auto 0;
  isolation: isolate;
}

.lot-door-flap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 9px;
  width: 90%;
  margin-inline: auto;
  padding: 11px 14px;
  background: var(--accent);
  color: #fff;
  font-size: clamp(11px, 3vw, 14px);
  font-weight: 700;
  text-decoration: none;
  border-radius: 3px;
  box-sizing: border-box;
}
.lot-door-flap span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
  min-width: 0;
  flex: 1;
}

  transform-origin: top center;
  transform: perspective(800px) rotateX(90deg);
  opacity: 0;
  transition: filter var(--ease);
  backface-visibility: visible;
  -webkit-backface-visibility: visible;
}
.lot-door-flap:hover { filter: brightness(1.15); }
.lot-door-flap svg { flex-shrink: 0; }

.lot-door-flap.is-open {
  animation: doorSwing 1.15s cubic-bezier(0.22, 1.4, 0.55, 1) forwards,
             doorWobble 2.7s ease-in-out 1.05s 1 forwards;
}

/* starts folded under card (rotateX 90deg = hidden below),
   swings down and bounces to flat (0deg) */
@keyframes doorSwing {
  0%   { transform: perspective(800px) rotateX(90deg);   opacity: 0; }
  15%  { opacity: 1; }
  60%  { transform: perspective(800px) rotateX(-12deg); }
  78%  { transform: perspective(800px) rotateX(6deg);  }
  90%  { transform: perspective(800px) rotateX(-3deg);  }
  100% { transform: perspective(800px) rotateX(0deg);   opacity: 1; }
}

@keyframes doorWobble {
  0%   { transform: perspective(800px) rotateX(0deg); }
  20%  { transform: perspective(800px) rotateX(-5deg); }
  45%  { transform: perspective(800px) rotateX(3deg); }
  65%  { transform: perspective(800px) rotateX(-2deg); }
  82%  { transform: perspective(800px) rotateX(1deg); }
  100% { transform: perspective(800px) rotateX(0deg); }
}

@keyframes lotSway {
  0%   { transform: perspective(600px) rotateY(-3deg); }
  50%  { transform: perspective(600px) rotateY( 3deg); }
  100% { transform: perspective(600px) rotateY(-3deg); }
}

/* ── Shimmer border canvas — sits INSIDE lot-card ── */
.lot-shimmer-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
  border-radius: 16px;
}

/* ── Axes overlay — hidden ── */
.lot-axes { display: none; }

/* Scratch zone — smaller (half previous) */
.lot-card__scratch-zone {
  position: relative;
  width: 80%;
  height: 52px;
  border-radius: 6px;
  overflow: hidden;
  z-index: 20; /* must beat rays canvas z-index:0 AND any card layers */
}
.lot-card__prize {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5e6ad;
  z-index: 1;
  visibility: hidden;
}
.lot-card__prize span {
  font-family: var(--font-title);
  font-size: clamp(22px, 7vw, 36px);
  font-weight: 900;
  color: #f13c77;
  line-height: 1;
  letter-spacing: -0.02em;
}
.lot-card__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  touch-action: none;
  border-radius: 6px;
  z-index: 21;
}

/* ══════════════════════════════════════════════
   CONTACTS
══════════════════════════════════════════════ */
.contacts-block { display:flex; flex-direction:column; gap:12px; }

.map-wrap {
  width:100%;
  border-radius:var(--r);
  overflow:hidden;
  aspect-ratio:16/9;
  border:1px solid var(--border);
}
.map-wrap iframe {
  width:100%; height:100%; display:block; border:none;
  filter:invert(90%) hue-rotate(180deg) saturate(0.7) brightness(0.85);
}

.map-chip {
  display:flex; align-items:center; gap:8px;
  padding:12px 16px;
  background:var(--accent); color:#fff;
  font-size:14px; font-weight:600;
  border-radius:var(--r); transition:filter var(--ease);
}
.map-chip:hover { filter:brightness(1.12); }
.map-chip__arrow {
  margin-left:auto;
  flex-shrink:0;
  opacity: 1;
  color: #fff;
  background: rgba(255,255,255,0.25);
  border-radius: 4px;
  padding: 2px;
  display: flex; align-items: center; justify-content: center;
}

.contact-btn {
  display:flex; align-items:center; justify-content:center; gap:10px;
  padding:15px; border-radius:var(--r);
  font-size:15px; font-weight:700;
  transition:filter var(--ease), transform var(--ease);
  text-decoration:none;
}
.contact-btn--tg { background:#229ED9; color:#fff; }
.contact-btn--tg:hover  { filter:brightness(1.1); }
.contact-btn--tg:active { transform:scale(0.98); }
.contact-btn--ig {
  background: linear-gradient(135deg, #f13c77 0%, #c4327c 40%, #7b4dbd 100%);
  color: #fff;
}
.contact-btn--ig:hover  { filter:brightness(1.12); }
.contact-btn--ig:active { transform:scale(0.98); }

/* Social buttons img — white tint since backgrounds are colored */
.contact-btn img {
  filter: brightness(0) invert(1);
  flex-shrink: 0;
}

/* Side-by-side social buttons */
.social-row {
  display: flex;
  gap: 10px;
}
.social-row .contact-btn {
  flex: 1;
  padding: 14px 10px;
  font-size: 14px;
}
.social-row .contact-btn img {
  flex-shrink: 0;
}

.perks-list { display:flex; flex-direction:column; gap:8px; }
.perk-item {
  display:flex; align-items:center; gap:14px;
  padding:12px 14px;
  background:rgba(255,255,255,0.04);
  border:1px solid var(--border); border-radius:var(--r);
  -webkit-backdrop-filter:blur(8px); backdrop-filter:blur(8px);
  transition:border-color var(--ease), background var(--ease);
}
.perk-item:hover { border-color:var(--border-accent); background:rgba(77,140,255,0.06); }
.perk-item__ico {
  width:40px; height:40px; flex-shrink:0;
  display:flex; align-items:center; justify-content:center;
  background:rgba(77,140,255,0.1); border-radius:var(--r);
}
.perk-item__ico img {
  width:22px; height:22px;
  filter:brightness(0) saturate(100%) invert(53%) sepia(80%) saturate(500%) hue-rotate(200deg);
}
.perk-item__text { display:flex; flex-direction:column; gap:2px; }
.perk-item__text strong { font-size:13px; font-weight:700; }
.perk-item__text span   { font-size:12px; color:var(--text-muted); line-height:1.4; }

/* FLOATING CTA — see rules at end of file */

/* ══════════════════════════════════════════════
   DESKTOP
══════════════════════════════════════════════ */
@media (min-width:640px) {
  .snap-inner { padding-inline:calc(var(--col)*0.06); }
}
@media (min-width:1024px) {
  .section { padding:64px 0; }
}
@media (prefers-reduced-motion:reduce) {
  /* Reduce motion for most elements */
  *,*::before,*::after { 
    animation-duration: 0.3s !important; 
    transition-duration: 0.3s !important;
    animation-iteration-count: 1 !important;
  }
  
  /* BUT: keep cert and lottery animations running normally */
  .cert-img-card,
  .cert-img-card__sheen,
  .lot-tilt-wrap,
  .lot-card::before {
    animation-duration: revert !important;
    animation-iteration-count: revert !important;
  }
}

/* Idle tilt — disabled, conflicts with swipe */

/* ══════════════════════════════════════════════
   FLOATING NAVBAR — two pill blocks
══════════════════════════════════════════════ */
.fnav {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 80;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s ease, transform .4s ease;

  display: flex;
  align-items: center;
  gap: 8px;
  width: min(calc(var(--col) - 32px), calc(100vw - 32px));
}
.fnav.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: all;
}

/* shared glass style — only for ads block */
.fnav__ads {
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(10, 11, 20, 0.72);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 8px 32px rgba(0,0,0,0.55), 0 1px 0 rgba(255,255,255,0.06) inset;
  height: 58px;
  overflow: hidden;
}

/* ── LEFT: ads (65%) ── */
.fnav__ads {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  min-width: 0;
  padding-left: 0; /* indicator removed — no extra padding */
}

/* vertical slide indicator (левый край) */
.fnav__indicator {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  justify-content: center;
  width: 14px;
  padding: 6px 0;
}
.fnav__indicator-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(255,255,255,0.22);
  transition: background 0.3s ease;
  flex-shrink: 0;
}
.fnav__indicator-dot.is-active {
  background: var(--accent);
  /* no transform — stays same size as inactive dots */
}

/* slides viewport */
.fnav__track-wrap {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  position: relative;
  height: 100%;
}
.fnav__track {
  display: flex;
  flex-direction: column;
  transition: transform 0.42s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
  /* touch */
  touch-action: pan-y;
}
.fnav__slide {
  flex: 0 0 58px;
  height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
  min-width: 0;
}
.fnav__slide:active { opacity: 0.75; }

.fnav__slide-ico {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
}
.fnav__slide-ico--cert   { background: rgba(124, 94, 93, 0.35); }
.fnav__slide-ico--fire   { background: rgba(200, 80, 30, 0.35); }
.fnav__slide-ico--lot    { background: rgba(200, 134, 10, 0.35); }
.fnav__slide-ico--needle { background: rgba(77, 140, 255, 0.22); }
.fnav__slide-ico--stone  { background: rgba(90, 110, 90, 0.35); }
/* animated emoji icons — no background box */
.fnav__slide-ico--bare {
  background: none;
  border-radius: 0;
  width: 40px;
  height: 40px;
}
.fnav__slide-ico--bare img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.fnav__slide-body {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  overflow: hidden;
}
.fnav__slide-body strong {
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fnav__slide-body span {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── RIGHT: book button block ── */
.fnav__book-wrap {
  flex: 0 0 auto;
  width: calc(35% - 4px);
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(10, 11, 20, 0.72);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 8px 32px rgba(0,0,0,0.55), 0 1px 0 rgba(255,255,255,0.06) inset;
}
.fnav__book {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: transparent;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  padding: 9px 12px;
  transition: background var(--ease), transform var(--ease);
  line-height: 1;
  white-space: nowrap;
  width: 100%;
}
.fnav__book:hover { background: rgba(255,255,255,0.08); }
.fnav__book:active { transform: scale(0.97); }
.fnav__book svg { flex-shrink: 0; }
.fnav__book span { display: inline; }

/* ── Lottery bot action — below card ── */
#lotBotAction {
  min-height: 0;
  width: 100%;
  overflow: hidden;
  transition: min-height 0.3s ease;
}

/* ── Lottery bot link ── */
.lot-bot-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 11px 18px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  border-radius: var(--r);
  text-decoration: none;
  width: 100%;
  box-sizing: border-box;
  justify-content: center;
  margin-top: 4px;
  transition: filter var(--ease);
}
.lot-bot-link:hover { filter: brightness(1.15); }
.lot-bot-link svg { flex-shrink: 0; stroke: #fff; }

/* ══════════════════════════════════════════════
   DESKTOP ICON PATTERN — per-section, absolute
══════════════════════════════════════════════ */
.bg-pattern { display: none; }

.noise, .hero, .section {
  position: relative;
  z-index: 1;
}
.fnav { z-index: 80; }

@media (min-width: 900px) {

  /* Three separate column divs injected by JS */
  .sec-pat-col {
    position: absolute;
    /* 5% indent top+bottom → 90% height, centered */
    top: 5%; bottom: 5%;
    pointer-events: none;
    z-index: 0;
    background-repeat: repeat-y;
    /* Soft top+bottom fade on every column */
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 12%, black 88%, transparent 100%);
    mask-image:         linear-gradient(to bottom, transparent 0%, black 12%, black 88%, transparent 100%);
  }

  /* col sizes */
  .sec-pat-col--1 { background-size: 86px 144px; opacity: 1.0;  }
  .sec-pat-col--2 { background-size: 65px 120px; opacity: 0.55; }
  .sec-pat-col--3 { background-size: 46px 96px;  opacity: 0.12; }

  /* Fade: only hides the hard crop at the very screen edge */
  .sec-pat-fade {
    position: absolute;
    top: 5%; bottom: 5%;
    width: 20px;
    pointer-events: none;
    z-index: 2;
  }
  .sec-pat-fade--left {
    left: 0;
    background: linear-gradient(to left, transparent 0%, #08090f 100%);
  }
  .sec-pat-fade--right {
    right: 0;
    background: linear-gradient(to right, transparent 0%, #08090f 100%);
  }
  .section--alt .sec-pat-fade--left  { background: linear-gradient(to left,  transparent 0%, #0c0e1a 100%); }
  .section--alt .sec-pat-fade--right { background: linear-gradient(to right, transparent 0%, #0c0e1a 100%); }

  /* Content above pattern */
  .section > *:not(.sec-pat-col):not(.sec-pat-fade) { position: relative; z-index: 3; }
}

/* ── Lot played note — одна строка ── */
.lot-card__played-note {
  font-size: 11px !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  padding: 4px 8px;
}

/* ── Отступ снизу последней секции чтобы fnav не перекрывал ── */
#contacts {
  padding-bottom: 96px;
}

/* ── Hot price rows ── */
.price-row--hot {
  background: rgba(255, 200, 50, 0.07);
  position: relative;
  overflow: hidden;
}
.price-row--hot::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    115deg,
    transparent 25%,
    rgba(255, 220, 80, 0.07) 40%,
    rgba(255, 245, 150, 0.13) 50%,
    rgba(255, 220, 80, 0.07) 60%,
    transparent 75%
  );
  background-size: 200% 100%;
  animation: priceRowShimmer 4s linear infinite;
  pointer-events: none;
}
@keyframes priceRowShimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}
.price-row--hot::before {
  content: '🔥';
  position: absolute;
  left: -20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  opacity: 0.8;
}
.price-row--hot > span:first-child {
  color: rgba(255, 220, 100, 0.95);
  font-weight: 500;
}
.price-row--hot > span:last-child {
  color: #fbbf24;
}
.price-row--hot > span:last-child em {
  color: #fbbf24;
}

/* ── Mobile: hide hero review cards and side patterns ── */
@media (max-width: 768px) {
  .hero-reviews { display: none; }
  .sec-pat-col, .sec-pat-fade { display: none; }
}

/* Нижние карточки col--a и col--c поверх bridge */
.hero-reviews__col--c .hero-review-card:last-child,
.hero-reviews__col--a .hero-review-card:last-child {
  position: relative;
  z-index: 2;
}

/* ══════════════════════════════════════
   SVC LIST — expand-from-row
══════════════════════════════════════ */
.svc-list {
  display: flex;
  flex-direction: column;
  border-radius: var(--r);
  overflow: hidden;
  border: 1px solid var(--border);
  position: relative;
}

/* ── Row ── */
.svc-item {
  border-bottom: 1px solid var(--border);
  position: relative;
}
.svc-item:last-child { border-bottom: none; }

.svc-item__row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: var(--bg-card);
  border: none;
  cursor: pointer;
  text-align: left;
  gap: 12px;
  transition: background var(--ease);
  position: relative;
  z-index: 1;
}
.svc-item__row:hover { background: rgba(77,140,255,0.07); }

.svc-item__row-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.svc-item__ico {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(77,140,255,0.1);
  border: 1px solid var(--border-accent);
  border-radius: var(--r);
  flex-shrink: 0;
}
.svc-item__ico img {
  width: 20px; height: 20px;
  filter: brightness(0) saturate(100%) invert(53%) sepia(60%) saturate(800%) hue-rotate(195deg) brightness(1.1);
}
.svc-item__name {
  font-size: 15px; font-weight: 600; color: var(--text);
}
.svc-item__arrow {
  flex-shrink: 0; color: var(--text-muted);
  transition: transform var(--ease);
}
.svc-item.is-open .svc-item__arrow { transform: rotate(180deg); }

/* ── Body: hidden by default ── */
.svc-item__body { display: none; }

/* ── Expanded card: absolute, covers full list ── */
.svc-expanded-card {
  position: absolute;
  inset: 0;
  z-index: 10;
  background: var(--bg-card);
  border-radius: var(--r);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: svcExpand 0.22s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes svcExpand {
  from { clip-path: inset(var(--svc-origin-y, 0px) 0 calc(100% - var(--svc-origin-bottom, 52px)) 0); }
  to   { clip-path: inset(0 0 0 0); }
}
.svc-expanded-card.is-closing {
  animation: svcCollapse 0.18s cubic-bezier(0.4, 0, 0.8, 1) forwards;
}
@keyframes svcCollapse {
  from { clip-path: inset(0 0 0 0); }
  to   { clip-path: inset(var(--svc-origin-y, 0px) 0 calc(100% - var(--svc-origin-bottom, 52px)) 0); }
}

/* hide icon in expanded card */
.svc-expanded-card .svc-item__card-header .service-card__ico { display: none; }

/* Top blue bar — "до інших видів масажу" */
.svc-expanded-card__back {
  display: block;
  width: 100%;
  padding: 11px 16px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
  transition: filter var(--ease);
}
.svc-expanded-card__back:hover { filter: brightness(1.12); }

/* Content area */
.svc-expanded-card__content {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}

/* Footer with action buttons */
.svc-expanded-card__footer {
  flex-shrink: 0;
  padding: 12px 16px 16px;
}
.svc-expanded-card__footer .service-card__btns {
  margin-top: 0;
}

/* desc color */
.svc-expanded-card .service-card__desc {
  color: var(--accent);
  opacity: 0.9;
  font-size: 14px;
  line-height: 1.65;
}

/* tags: 3px radius, lowercase, # prefix */
.svc-expanded-card .service-card__tags span {
  border-radius: 3px;
  font-size: 11px;
  font-weight: 500;
  text-transform: lowercase;
}
.svc-expanded-card .service-card__tags span::before {
  content: '#';
  opacity: 0.55;
}

.svc-item__close {
  display: flex; align-items: center; gap: 6px;
  background: none; border: none;
  color: var(--text-muted); font-family: var(--font);
  font-size: 13px; font-weight: 500;
  cursor: pointer; padding: 0; width: fit-content;
  transition: color var(--ease);
}
.svc-item__close:hover { color: var(--accent); }

.svc-item__card-header {
  display: flex; align-items: center;
  justify-content: space-between; gap: 8px;
}

/* ── Section pattern: no fade overlays, no vertical mask ── */
.sec-pat-fade { display: none; }
.sec-pat-col {
  -webkit-mask-image: none !important;
  mask-image: none !important;
}

/* ── Footer article links ── */
.footer-links {
  margin-top: 8px;
}
.footer-links__title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.footer-links__grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: var(--r);
  overflow: hidden;
  border: 1px solid var(--border);
}
.footer-link {
  display: block;
  padding: 11px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: background var(--ease), color var(--ease);
}
.footer-link:last-child { border-bottom: none; }
.footer-link:hover {
  background: rgba(77,140,255,0.06);
  color: var(--accent);
}

/* Lottery section — reduce top gap from price note */
#lottery { padding-top: 16px; }
/* Section titles blue */
.section-title { color: var(--accent); }
/* Price section title */
#price .section-title { color: var(--accent); }

/* Bridge after hero: transparent */
.section-bridge {
  background: transparent !important;
  margin-top: 0 !important;
  height: 120px !important;
  position: relative !important;
  z-index: 0 !important;
}

/* Animated emoji section icons — no color filter */
.section-title__ico[src*="Telegram-Animated"] {
  filter: none;
}

/* ── Rays canvas ── */
.lot-rays-canvas {
  position: absolute;
  top: -60px;
  left: -80px;
  right: -80px;
  bottom: -60px;
  width: calc(100% + 160px);
  height: calc(100% + 120px);
  pointer-events: none !important;
  touch-action: none;
  z-index: 0;
}

/* ── Service card read-more ── */
.svc-read-more {
  position: relative;
  margin-top: 0;
}
/* gradient fade above the link */
.svc-read-more::before {
  content: '';
  position: absolute;
  bottom: 100%;
  left: 0; right: 0;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--bg-card));
  pointer-events: none;
}
.svc-read-more__toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 100%;
  padding: 8px 0 2px;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  text-align: center;
  transition: opacity var(--ease);
}
.svc-read-more__toggle:hover { opacity: 0.75; }
.svc-read-more__toggle svg {
  flex-shrink: 0;
  /* chevron pointing right */
}


/* ══════════════════════════════════════════════
   MOBILE FIX: Prevent animation speed issues
══════════════════════════════════════════════ */

/* Force explicit animation timing on all devices */
.cert-img-card {
  animation-name: certImgSway !important;
  animation-duration: 3s !important;
  animation-timing-function: ease-in-out !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
  animation-fill-mode: none !important;
}

.cert-img-card__sheen {
  animation-name: certImgSheen !important;
  animation-duration: 4s !important;
  animation-timing-function: ease-in-out !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
  animation-fill-mode: none !important;
}

.lot-tilt-wrap {
  animation-name: lotSway !important;
  animation-duration: 4s !important;
  animation-timing-function: ease-in-out !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
  animation-fill-mode: none !important;
}

.lot-card::before {
  animation-name: lotSheen !important;
  animation-duration: 5s !important;
  animation-timing-function: ease-in-out !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
  animation-fill-mode: none !important;
}

@media (max-width: 768px) {
  /* Ensure cert animations run at correct speed on mobile */
  .cert-img-card {
    animation: certImgSway 3s ease-in-out infinite !important;
    animation-play-state: running !important;
  }
  
  .cert-img-card__sheen {
    animation: certImgSheen 4s ease-in-out infinite !important;
    animation-play-state: running !important;
  }
  
  .cert-flip-wrap.is-flipping-out {
    animation: certFlipOut 0.36s ease-in-out forwards !important;
    animation-play-state: running !important;
  }
  
  /* Ensure lottery animations run at correct speed on mobile */
  .lot-tilt-wrap {
    animation: lotSway 4s ease-in-out infinite !important;
    animation-play-state: running !important;
  }
  
  .lot-card::before {
    animation: lotSheen 5s ease-in-out infinite !important;
    animation-play-state: running !important;
  }
  
  .lot-door-flap.is-open {
    animation: doorSwing 1.15s cubic-bezier(0.22, 1.4, 0.55, 1) forwards,
               doorWobble 2.7s ease-in-out 1.05s 1 forwards !important;
    animation-play-state: running !important;
  }
}


/* ══════════════════════════════════════════════
   TELEGRAM-STYLE ANIMATED CONTACT BUTTONS
   Click-only mode with "Show All" button
══════════════════════════════════════════════ */
.telegram-contacts {
  --tg-ease: cubic-bezier(.22, 1, .36, 1);
  width: 100%;
  margin-top: 48px; /* Опущено ниже, чтобы совпасть с нижней границей карты */
}

.tg-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.tg-tooltip-container {
  position: relative;
  cursor: pointer;
  flex: 1;
  display: flex;
  justify-content: center;
}

.tg-btn { --color: #229ED9; --dark: #14658f; }
.ig-btn { --color: #E1306C; --dark: #9c1d4a; }
.ph-btn { --color: #25D366; --dark: #1da851; } /* Зелёный для телефона */

/* ── Tooltip (modal that appears on click) ── */
.tg-tooltip {
  position: absolute;
  bottom: calc(100% + 16px); /* Поднято выше: было +10px */
  left: 50%;
  width: max(110px, 100%);
  max-width: 140px;
  transform: translateX(-50%) scale(.96);
  padding: 6px;
  opacity: 0;
  pointer-events: none;
  background: var(--color);
  border: 1.5px solid var(--dark);
  border-radius: 12px;
  transition: bottom .6s var(--tg-ease), opacity .4s ease, transform .6s var(--tg-ease);
  z-index: 100;
}

/* Show tooltip only when active (clicked) */
.tg-tooltip-container.active .tg-tooltip {
  bottom: calc(100% + 32px); /* Поднято выше: было +26px */
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) scale(1);
}

/* Staggered appearance when "Show All" is clicked */
.telegram-contacts.open .tg-btn .tg-tooltip { transition-delay: 0s; }
.telegram-contacts.open .ig-btn .tg-tooltip { transition-delay: .1s; }
.telegram-contacts.open .ph-btn .tg-tooltip { transition-delay: .2s; }

.tg-profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  padding: 4px;
  color: inherit;
  text-decoration: none;
}

.tg-img {
  width: 36px;
  height: 36px;
  font-size: 14px;
  font-weight: 700;
  border: none; /* Убраны все рамки */
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent; /* Убран градиент */
  color: var(--color);
  position: relative;
  overflow: visible;
  padding: 0;
}

.tg-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  /* Без фильтров - показываем чистую webp */
}

.tg-details { 
  display: flex; 
  flex-direction: column; 
  align-items: center; 
  color: rgba(255, 255, 255, 0.85); 
  font-size: 11px;
  line-height: 1.3;
}
.tg-name { 
  font-size: 13px; 
  font-weight: 700; 
  color: #fff; 
}
.tg-username { 
  white-space: nowrap;
  font-size: 10px;
}
.tg-about { 
  font-size: 10px; 
  line-height: 1.3; 
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
}

/* ── Animated icon button (NO HOVER - click only) ── */
.tg-icon {
  display: block;
  position: relative;
}

.tg-layer {
  width: 58px;
  height: 58px;
  transition: transform .6s var(--tg-ease);
  margin: 0 auto;
}

/* Animation only on active state (clicked) */
.tg-tooltip-container.active .tg-layer { 
  transform: rotate(-35deg) skew(20deg); 
}

.tg-layer span {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  border: 2px solid transparent;
  border-radius: 14px;
  background: transparent;
  opacity: 0;
  transition:
    transform .6s var(--tg-ease),
    opacity .5s ease,
    background .5s ease,
    border-color .5s ease,
    border-radius .6s var(--tg-ease);
}

.tg-layer span.tg-svg {
  opacity: 1;
  padding: 13px;
  background: var(--color);
  border-color: var(--color);
}

/* Show layers only when active - БЕЗ ИНВЕРСИИ */
.tg-tooltip-container.active .tg-layer span {
  border-radius: 10px;
  border-color: var(--color);
  background: var(--color);
}

/* Верхний слой остаётся цветным (БЕЗ ИНВЕРСИИ) */
.tg-tooltip-container.active .tg-layer span.tg-svg { 
  background: var(--color); /* Было: #fff */
}

.tg-glyph { 
  fill: #fff; 
  transition: fill .5s ease; 
}
.tg-ring { 
  fill: none; 
  stroke: #fff; 
  stroke-width: 2; 
  transition: stroke .5s ease; 
}

/* Иконка остаётся белой (БЕЗ ИНВЕРСИИ) */
.tg-tooltip-container.active .tg-glyph { 
  fill: #fff; /* Было: var(--color) */
}
.tg-tooltip-container.active .tg-ring { 
  stroke: #fff; /* Было: var(--color) */
}

.tg-icon .tg-text {
  position: absolute;
  left: 50%;
  bottom: -5px;
  opacity: 0;
  font-weight: 700;
  font-size: 11px;
  color: var(--color);
  transform: translateX(-50%);
  transition: bottom .5s var(--tg-ease), opacity .4s ease;
  white-space: nowrap;
}

/* Show text only when active */
.tg-tooltip-container.active .tg-text { 
  bottom: -24px; 
  opacity: 1; 
}

/* Layered shadow effect on active state */
.tg-tooltip-container.active .tg-layer span:nth-child(1) { 
  opacity: .2; 
}
.tg-tooltip-container.active .tg-layer span:nth-child(2) { 
  opacity: .4; 
  transform: translate(4px, -4px); 
}
.tg-tooltip-container.active .tg-layer span:nth-child(3) { 
  opacity: .6; 
  transform: translate(8px, -8px); 
}
.tg-tooltip-container.active .tg-layer span:nth-child(4) { 
  opacity: .8; 
  transform: translate(12px, -12px); 
}
.tg-tooltip-container.active .tg-layer span:nth-child(5) { 
  opacity: 1; 
  transform: translate(16px, -16px); 
}

/* ── "Show All Contacts" button ── */
.tg-show-all {
  display: block;
  width: 100%;
  height: 48px;
  margin-top: 40px;
  border: none;
  border-radius: var(--r);
  background: rgba(77, 140, 255, 0.12);
  border: 1px solid var(--border-accent);
  color: var(--accent);
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background .3s ease, transform .3s var(--tg-ease), border-color .3s ease;
}
.tg-show-all:hover  { 
  background: rgba(77, 140, 255, 0.18); 
  border-color: var(--accent);
}
.tg-show-all:active { 
  transform: scale(.98); 
}

/* ── Mobile adjustments ── */
@media (max-width: 480px) {
  .tg-row {
    gap: 6px;
  }
  
  .tg-layer {
    width: 52px;
    height: 52px;
  }
  
  .tg-tooltip {
    max-width: 120px;
  }
  
  .tg-img {
    width: 32px;
    height: 32px;
    font-size: 12px;
    padding: 0;
  }
  
  .tg-name {
    font-size: 12px;
  }
  
  .tg-username,
  .tg-about {
    font-size: 9px;
  }
  
  .tg-show-all {
    margin-top: 32px;
    height: 44px;
    font-size: 13px;
  }
}


/* Скрыть блок контактов с картой */
.hero-card-overlay {
  display: none !important;
}


/* ══════════════════════════════════════════════
   FLIP CARD (замена 3D модели)
══════════════════════════════════════════════ */
.hero__flip-card {
  width: 100%;
  max-width: 280px;
  margin: 60px auto 16px;
  perspective: 1000px;
  z-index: 1;
  cursor: pointer;
  /* Анимация появления синхронно с review cards */
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform, opacity;
  transform: translateZ(0) scale(0.8);
  -webkit-transform: translateZ(0) scale(0.8);
}

.hero-ready .hero__flip-card {
  opacity: 1;
  transform: translateZ(0) scale(1);
  -webkit-transform: translateZ(0) scale(1);
  transition-delay: 0.6s; /* Синхронно с review cards */
  animation: flipCardSway 4s ease-in-out infinite 0.6s; /* Sway стартує після zoom */
}

@keyframes flipCardSway {
  0%, 100% { 
    transform: perspective(1000px) rotateY(-5deg) rotateX(1deg);
  }
  50% { 
    transform: perspective(1000px) rotateY(5deg) rotateX(-1deg);
  }
}

/* Scroll Down Button */
.hero-scroll-down {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 48px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.hero-ready .hero-scroll-down {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.2s; /* Після карточок і flip-карти */
}

.hero-scroll-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 24px;
  width: 280px;
  max-width: 280px;
  background: transparent;
  border: 2px solid rgba(0, 0, 0, 0.25);
  border-radius: 10px;
  color: rgba(40, 40, 40, 0.9);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
  text-transform: uppercase;
  margin: 0 auto;
}

.scroll-lottie {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  display: block;
  filter: brightness(0) opacity(0.7);
}

.hero-scroll-btn span {
  animation: scrollTextPulse 2s ease-in-out infinite;
}

.hero-scroll-btn:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.35);
  transform: translateY(-2px);
}

.hero-scroll-btn:active {
  transform: translateY(0);
}

.hero-scroll-down.hidden {
  animation: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

@keyframes scrollTextPulse {
  0%, 100% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

@media (max-width: 640px) {
  .hero-scroll-down {
    margin-top: 36px;
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 0;
  }
  
  .hero-scroll-btn {
    padding: 10px 16px;
    font-size: 11px;
    gap: 8px;
    width: 240px;
    max-width: 240px;
    white-space: nowrap;
  }
  
  .scroll-lottie {
    width: 24px !important;
    height: 24px !important;
  }
}

@media (max-width: 480px) {
  .hero__flip-card {
    max-width: 85%;
    width: 85%;
    margin: 40px auto 16px;
  }
  
  /* Повністю перевизначаємо ширину кнопки на mobile */
  .hero-scroll-btn {
    width: 85% !important;
    max-width: 85% !important;
    min-width: 0 !important;
    padding: 10px 16px !important;
    font-size: 11px !important;
    gap: 8px !important;
  }
  
  .scroll-lottie {
    width: 24px !important;
    height: 24px !important;
  }
}

.hero__flip-inner {
  position: relative;
  width: 100%;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
  transform: rotateY(0deg);
  /* Rotation controlled by JS inline style for continuous clockwise rotation */
  /* iOS 3D fix */
  -webkit-transform-style: preserve-3d;
  -webkit-perspective: 1000px;
  perspective: 1000px;
}

.hero__flip-front,
.hero__flip-back {
  width: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 18px;
  overflow: hidden;
  /* iOS 3D rendering fix - force GPU acceleration */
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  /* iOS visibility fix - smooth fade during flip */
  transition: opacity 0.4s ease, transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero__flip-front {
  background: transparent;
  position: relative;
  z-index: 2;
}

.hero__flip-back {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  z-index: 1;
  transform: rotateY(180deg); /* Statically rotated 180deg so it appears when inner rotates 180deg */
  background: rgba(245, 245, 250, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.hero__flip-video {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 18px;
}

.hero__flip-contacts {
  width: 100%;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Слоган на задней стороне в рамочке */
.flip-back-slogan {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  color: rgba(0, 0, 0, 0.85);
  text-align: center;
  padding: 10px 14px;
  border: 1.5px solid rgba(0, 0, 0, 0.12);
  border-radius: 10px;
  margin-bottom: 4px;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
}

.flip-back-slogan-accent {
  color: rgba(0, 0, 0, 0.85);
  font-weight: 600;
}

/* Карта на задней стороне */
.flip-back-map {
  width: 100%;
  height: 120px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.flip-back-map iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* Кнопка адреса */
.flip-back-address {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  color: rgba(0, 0, 0, 0.85);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.25s ease;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
}

.flip-back-address:hover {
  background: rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.flip-back-address svg {
  flex-shrink: 0;
  color: var(--accent);
}

/* Контакты */
.flip-back-contacts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.flip-back-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 8px;
  color: rgba(0, 0, 0, 0.8);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.25s ease;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
}

.flip-back-link:hover {
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.12);
  transform: translateX(2px);
}

.flip-back-link svg {
  flex-shrink: 0;
  color: rgba(0, 0, 0, 0.5);
}

@media (max-width: 639px) {
  .hero__flip-back {
    padding: 14px;
  }
  
  .flip-back-map {
    height: 100px;
  }
  
  .flip-back-address,
  .flip-back-link {
    font-size: 12px;
    padding: 8px 10px;
  }
}

/* Body background RGB variables for scroll effect */
:root {
  --body-bg-r: 12;
  --body-bg-g: 14;
  --body-bg-b: 26;
}
