/* Typography and motion polish only. The original layout and components remain authoritative. */

.hero-copy h1 {
  font-size: clamp(2.75rem, 5.15vw, 4.65rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

#sluzby .max-w-2xl h2,
#revizie h2,
#referencie .max-w-2xl h2,
#o-mne h2,
#kontakt h2 {
  font-size: clamp(2.6rem, 4.6vw, 4.25rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.lead {
  font-size: clamp(1.125rem, 1.45vw, 1.3rem);
  line-height: 1.65;
}

.service-card--featured h3 {
  font-size: clamp(1.7rem, 2.3vw, 2.15rem);
  line-height: 1.08;
  letter-spacing: -0.035em;
}

.service-card--compact h3 {
  font-size: 1.25rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.reference-card h3 {
  font-size: clamp(1.35rem, 2vw, 1.65rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.revision-card > span:last-of-type {
  font-size: 1rem;
  line-height: 1.25;
}

/* Hero: copy and a freestanding 3D object, not a card. */
.hero-stage {
  position: relative;
  isolation: isolate;
  overflow: clip;
  gap: 0;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero-media {
  position: relative;
  z-index: 1;
  order: -1;
  min-height: min(122vw, 475px);
  margin: 0 -1rem 2.75rem;
  overflow: visible;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.hero-media .hero-bulb,
.hero-media .hero-bulb-glow,
.hero-media .hero-bulb-shadow {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform-origin: 52% 58%;
}

.hero-media .hero-bulb {
  will-change: transform;
}

.hero-media .hero-bulb-glow {
  z-index: 2;
  opacity: 0;
  mix-blend-mode: screen;
  -webkit-mask-image: linear-gradient(to bottom, transparent 5%, black 12%, black 52%, transparent 61%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 5%, black 12%, black 52%, transparent 61%, transparent 100%);
  pointer-events: none;
}

.hero-media .hero-bulb-shadow {
  z-index: 3;
  overflow: visible;
  pointer-events: none;
}

.hero-media.hero-interactive {
  cursor: pointer;
}

.hero-media.hero-interactive:focus-visible {
  outline: 2px solid var(--brand, #e2001a);
  outline-offset: 4px;
}

.hero-motion .hero-copy > *,
.hero-motion .hero-bulb {
  opacity: 0;
}

.hero-motion .hero-bulb-shadow {
  opacity: 0;
}

.hero-motion.hero-enter .hero-bulb {
  animation: hero-bulb-arrive 1.9s cubic-bezier(0.22, 1, 0.36, 1) 80ms both;
}

.hero-motion.hero-enter .hero-bulb-glow {
  animation: hero-glass-switch-on 1s cubic-bezier(0.22, 1, 0.36, 1) 1.98s both;
}

.hero-motion.hero-enter .hero-bulb-shadow {
  animation: hero-shadow-in 1.9s cubic-bezier(0.22, 1, 0.36, 1) 120ms both;
}

.hero-motion.hero-enter .hero-media.hero-relight .hero-bulb-glow {
  animation: hero-glass-relight 900ms ease-in-out both;
}

.hero-motion.hero-enter .hero-copy > * {
  animation: hero-copy-in 1.05s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-motion.hero-enter .hero-copy > :nth-child(1) { animation-delay: 260ms; }
.hero-motion.hero-enter .hero-copy > :nth-child(2) { animation-delay: 360ms; }
.hero-motion.hero-enter .hero-copy > :nth-child(3) { animation-delay: 470ms; }
.hero-motion.hero-enter .hero-copy > :nth-child(4) { animation-delay: 580ms; }

@keyframes hero-bulb-arrive {
  from { opacity: 0; transform: translate3d(0, -48px, 0); }
  to { opacity: 1; transform: none; }
}

@keyframes hero-glass-switch-on {
  0% { opacity: 0; filter: brightness(1) saturate(1); }
  58% { opacity: 0.82; filter: brightness(1.28) saturate(1.3); }
  100% { opacity: 0.62; filter: brightness(1.16) saturate(1.22); }
}

@keyframes hero-shadow-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes hero-glass-relight {
  0%,
  100% { opacity: 0.62; filter: brightness(1.16) saturate(1.22); }
  35%,
  65% { opacity: 0.96; filter: brightness(1.52) saturate(1.4); }
}

@keyframes hero-copy-in {
  from { opacity: 0; transform: translate3d(0, 24px, 0); }
  to { opacity: 1; transform: none; }
}

.about-media {
  aspect-ratio: 1;
}

.about-media img {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  object-position: 32% 50%;
}

.polish-motion [data-polish-reveal] {
  opacity: 0;
  transform: translate3d(0, calc(20px + var(--scroll-shift, 0px)), 0);
  transition:
    opacity 680ms cubic-bezier(0.22, 1, 0.36, 1) var(--polish-delay, 0ms),
    transform 760ms cubic-bezier(0.22, 1, 0.36, 1) var(--polish-delay, 0ms),
    border-color 220ms ease,
    box-shadow 220ms ease;
}

.polish-motion [data-polish-reveal].polish-visible {
  opacity: 1;
  transform: translate3d(0, var(--scroll-shift, 0px), 0);
}

.polish-motion .revision-card .tick-chip {
  opacity: 0;
  transform: scale(0.55);
  transform-origin: center;
}

.polish-motion .revision-card .tick-chip path {
  stroke-dasharray: 24;
  stroke-dashoffset: 24;
}

.polish-motion .revision-card:nth-child(1) { --tick-delay: 380ms; }
.polish-motion .revision-card:nth-child(2) { --tick-delay: 570ms; }
.polish-motion .revision-card:nth-child(3) { --tick-delay: 760ms; }
.polish-motion .revision-card:nth-child(4) { --tick-delay: 950ms; }

.polish-motion .revision-card.polish-visible .tick-chip {
  animation: revision-tick-chip 360ms cubic-bezier(0.16, 1, 0.3, 1) var(--tick-delay) both;
}

.polish-motion .revision-card.polish-visible .tick-chip path {
  animation: revision-tick-stroke 420ms cubic-bezier(0.22, 1, 0.36, 1) calc(var(--tick-delay) + 90ms) both;
}

@keyframes revision-tick-chip {
  from { opacity: 0; transform: scale(0.55); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes revision-tick-stroke {
  to { stroke-dashoffset: 0; }
}

@media (min-width: 1024px) {
  .hero-stage {
    min-height: calc(100svh - 4rem);
    gap: clamp(5rem, 7vw, 7rem);
    padding-top: 4.5rem;
    padding-bottom: 5rem;
  }

  .hero-media {
    order: 0;
    align-self: stretch;
    min-height: 700px;
    margin: -2.5rem -5.5rem -6.5rem -2rem;
  }

}

@media (min-width: 640px) and (max-width: 1023px) {
  .hero-stage {
    padding-top: 5rem;
    padding-bottom: 7rem;
  }

  .hero-media {
    min-height: min(88vw, 800px);
    margin: 0 -1.5rem 4.5rem;
  }
}

@media (max-width: 639px) {
  .hero-stage {
    padding-top: 2.5rem;
    padding-bottom: 5rem;
  }

  .hero-copy h1 {
    font-size: clamp(2.3rem, 11.5vw, 2.85rem);
    line-height: 1;
  }

  #sluzby .max-w-2xl h2,
  #revizie h2,
  #referencie .max-w-2xl h2,
  #o-mne h2,
  #kontakt h2 {
    font-size: clamp(2.35rem, 10.5vw, 3.15rem);
    line-height: 1;
  }

  .lead {
    font-size: 1.125rem;
    line-height: 1.6;
  }

}

@media (orientation: landscape) and (min-width: 640px) and (max-width: 1023px) and (max-height: 500px) {
  .hero-stage {
    min-height: calc(100svh - 4rem);
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    align-items: center;
    gap: 2rem;
    padding-top: 1.25rem;
    padding-bottom: 6rem;
  }

  .hero-copy {
    grid-column: 1;
    grid-row: 1;
  }

  .hero-copy h1 {
    margin-top: 0.75rem;
    font-size: clamp(2.2rem, 4.8vw, 2.75rem);
  }

  .hero-copy .lead {
    margin-top: 1rem;
    font-size: 0.98rem;
    line-height: 1.45;
  }

  .hero-copy > div:last-child {
    margin-top: 1.25rem;
  }

  .hero-media {
    order: 0;
    grid-column: 2;
    grid-row: 1;
    min-height: min(92vh, 390px);
    margin: -1rem -1.5rem -1rem 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .polish-motion [data-polish-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-motion .hero-copy > *,
  .hero-motion .hero-bulb,
  .hero-motion .hero-bulb-shadow {
    opacity: 1;
    animation: none;
    transform: none;
    filter: none;
  }

  .hero-media .hero-bulb-glow {
    opacity: 0.62;
    filter: brightness(1.16) saturate(1.22);
    animation: none;
  }

  .polish-motion .revision-card .tick-chip,
  .polish-motion .revision-card .tick-chip path {
    opacity: 1;
    stroke-dashoffset: 0;
    animation: none;
    transform: none;
  }
}
