/* ============================================
   RASI – Service Reparaturen Kaffeemaschinen
   Landing Page
   ============================================ */

:root {
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
  --color-text: #1a1a1a;
  --color-text-muted: #6b6b6b;
  --color-border: #e8e8e8;
  --color-bg: #ffffff;
  --color-accent: #c41e3a;
  --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.2s ease;
  --header-height: 100px;
  /* Hero BG: focal point (cover keeps aspect ratio — only position/zoom change) */
  --hero-bg-position: center center;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ========== PRELOADER – Lottie ========== */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.preloader.loaded {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-inner {
  display: flex;
  align-items: center;
  justify-content: center;
}

.preloader-lottie {
  width: 300px;
  height: 300px;
}

@media (max-width: 480px) {
  .preloader-lottie {
    width: 220px;
    height: 220px;
  }
}

/* ========== HEADER – Landing Page ========== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-height);
  background: #000;
  color: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: box-shadow var(--transition);
}

.header.scrolled {
  background: #000;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
  height: 100%;
}

.logo-wrap {
  display: flex;
  align-items: center;
  height: 100%;
}

.logo-img {
  height: 96px;
  width: auto;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.25));
  transition: transform var(--transition-fast), filter var(--transition-fast);
}


.logo-wrap:hover .logo-img {
  transform: scale(1.02);
}

/* Nav – Home, About Us, Gallery, Contact */
.nav-main {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-link {
  position: relative;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
  transition: color var(--transition-fast), text-shadow var(--transition-fast);
}


.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width var(--transition);
}

.nav-link:hover::after {
  width: 100%;
}

/* Language switcher – DE | FR | EN */
.nav-lang {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding-left: 20px;
  border-left: 1px solid rgba(255, 255, 255, 0.25);
}

.nav-lang-link {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: rgba(255, 255, 255, 0.75);
  transition: color var(--transition-fast);
}

.nav-lang-link:hover,
.nav-lang-link.is-active {
  color: #fff;
}

.nav-lang-sep {
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  user-select: none;
}

/* Mobile overlay – hidden on desktop */
.nav-overlay {
  display: none;
}

/* Hamburger – hidden on desktop */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  color: #fff;
  z-index: 1002;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ========== HERO – Premium Coffee Visual ========== */
/* Full viewport bleed (100vw) — breaks out of any horizontal inset so BG/slider touches edges */
.hero {
  position: relative;
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  height: 100vh;
  min-height: 720px;
  overflow: hidden;
  background: #000;
}

.hero-inner {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.hero-inner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, transparent 45%, rgba(0,0,0,0.25) 100%);
  z-index: 2;
  pointer-events: none;
}

/* Puzzle reveal overlay – pieces cover hero until animation */
.hero-puzzle-reveal {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  pointer-events: none;
}

.hero-puzzle-piece {
  background: linear-gradient(145deg, #0a0a0c 0%, #141418 50%, #0c0c0e 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  transform-origin: center center;
}

/* Puzzle-style clip-paths – irregular shapes like puzzle pieces */
.hero-puzzle-piece--1 { clip-path: polygon(0 0, 100% 0, 100% 85%, 90% 100%, 0 100%); }
.hero-puzzle-piece--2 { clip-path: polygon(10% 0, 100% 0, 100% 100%, 0 100%, 0 15%); }
.hero-puzzle-piece--3 { clip-path: polygon(0 0, 90% 0, 100% 15%, 100% 100%, 10% 100%); }
.hero-puzzle-piece--4 { clip-path: polygon(0 15%, 100% 0, 100% 100%, 0 85%); }
.hero-puzzle-piece--5 { clip-path: polygon(15% 0, 85% 0, 100% 15%, 100% 85%, 85% 100%, 15% 100%, 0 85%, 0 15%); }
.hero-puzzle-piece--6 { clip-path: polygon(0 0, 100% 15%, 100% 100%, 15% 100%); }
.hero-puzzle-piece--7 { clip-path: polygon(0 85%, 10% 100%, 100% 100%, 100% 0, 0 0); }
.hero-puzzle-piece--8 { clip-path: polygon(0 100%, 0 15%, 10% 0, 100% 0, 100% 100%); }
.hero-puzzle-piece--9 { clip-path: polygon(90% 0, 100% 10%, 100% 100%, 0 100%, 0 0); }
.hero-puzzle-piece--10 { clip-path: polygon(0 85%, 15% 100%, 100% 100%, 100% 0, 0 0); }
.hero-puzzle-piece--11 { clip-path: polygon(0 0, 100% 0, 100% 85%, 90% 100%, 0 100%); }
.hero-puzzle-piece--12 { clip-path: polygon(10% 0, 100% 0, 100% 100%, 0 100%, 0 15%); }

.hero-puzzle-reveal.is-complete {
  pointer-events: none;
  visibility: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  background-size: cover;
  background-position: var(--hero-bg-position);
  background-repeat: no-repeat;
  animation: heroKenBurns 22s ease-out forwards;
  transform-origin: var(--hero-bg-position);
}

@keyframes heroKenBurns {
  0% {
    transform: scale(1.02) translate(-0.35%, -0.2%);
  }
  100% {
    transform: scale(1) translate(0, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg {
    animation: none !important;
    transform: none !important;
  }
}

.hero-content {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 10;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  width: 100%;
  max-width: 86%;
  margin: 0 auto;
  padding: 0 40px;
}

.hero-copy,
.hero-visual-card {
  display: none !important;
}

.hero-copy {
  flex: 1;
  max-width: 420px;
  text-align: center;
  position: relative;
  isolation: isolate;
  padding: 22px 22px 24px;
  border-radius: 18px;
  background: rgba(10, 10, 10, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

.hero-copy::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    320px circle at 14% 12%,
    rgba(255, 255, 255, 0.18),
    rgba(196, 30, 58, 0.08) 45%,
    transparent 75%
  );
  pointer-events: none;
  z-index: 0;
}

.hero-copy > * {
  position: relative;
  z-index: 1;
}

.hero-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 12px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(30px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
  margin-bottom: 16px;
}

.hero-desc {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 auto 24px;
  max-width: 360px;
}

.hero-copy .btn--primary {
  margin: 0 auto;
}

.hero-visual {
  display: none;
  position: relative;
  flex: 1;
  max-width: 480px;
  min-height: 340px;
  align-items: flex-end;
  justify-content: flex-end;
  align-self: flex-end;
  margin-left: auto;
}

.hero-visual-glow {
  position: absolute;
  inset: -20%;
  background: radial-gradient(circle at 20% 0%, rgba(196, 30, 58, 0.8), transparent 55%),
              radial-gradient(circle at 80% 100%, rgba(0, 0, 0, 0.9), transparent 55%);
  filter: blur(32px);
  opacity: 0.8;
}

.hero-visual-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 430px;
  border-radius: 20px;
  padding: 18px 18px 20px;
  background: linear-gradient(135deg, rgba(10, 10, 10, 0.9), rgba(25, 25, 25, 0.96));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(255, 255, 255, 0.03);
  overflow: hidden;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  animation: heroFloat 9s ease-in-out infinite alternate;
}

.hero-visual-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(196, 30, 58, 0.35), transparent 50%);
  opacity: 0.9;
  pointer-events: none;
}

.hero-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 2;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.7);
}

.hero-machine {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: 16px;
  object-fit: cover;
  display: block;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.85);
}

.hero-pagination {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.hero-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  padding: 0;
  transition: background 0.25s ease, transform 0.25s ease, width 0.25s ease;
}

.hero-dot.is-active {
  width: 22px;
  background: var(--color-accent);
  transform: translateY(-1px);
}

.hero-visual-meta {
  position: relative;
  z-index: 2;
  margin-top: 18px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.hero-meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hero-meta-label {
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

.hero-meta-value {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.94);
}

.hero-bean {
  position: absolute;
  width: 110px;
  height: 110px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 20%, #3b2312, #120804 70%);
  box-shadow:
    0 16px 40px rgba(0, 0, 0, 0.8),
    inset 0 0 0 2px rgba(255, 255, 255, 0.05);
  opacity: 0.65;
  filter: blur(0.5px);
  animation: beanDrift 16s ease-in-out infinite alternate;
}

.hero-bean::before {
  content: '';
  position: absolute;
  inset: 18% 40%;
  border-radius: 999px;
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.12), rgba(0, 0, 0, 0.9));
}

.hero-bean--left {
  left: -10px;
  bottom: 4%;
}

.hero-bean--right {
  right: -26px;
  top: 10%;
  animation-delay: -5s;
}

@keyframes heroFloat {
  0% {
    transform: translateY(0px) translateX(0px) scale(1);
  }
  50% {
    transform: translateY(-10px) translateX(4px) scale(1.01);
  }
  100% {
    transform: translateY(-4px) translateX(-4px) scale(1.005);
  }
}

@keyframes beanDrift {
  0% {
    transform: translateY(0) translateX(0) rotate(0deg);
  }
  50% {
    transform: translateY(-18px) translateX(10px) rotate(12deg);
  }
  100% {
    transform: translateY(-10px) translateX(-6px) rotate(-8deg);
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 40px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: all var(--transition);
}

.btn--primary {
  color: #fff;
  background: var(--color-accent);
  border: 2px solid var(--color-accent);
}

.btn--primary:hover {
  background: transparent;
  color: #fff;
  border-color: #fff;
  transform: translateY(-2px);
}


/* ========== HOW IT WORKS ========== */
.how-it-works {
  position: relative;
  padding: 100px 40px;
  overflow: hidden;
}

.how-it-works-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.how-it-works-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(2px);
}

.how-it-works-inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
}

.how-it-works .section-header {
  margin-bottom: 60px;
}

.how-it-works .section-title {
  color: #fff;
}

.how-it-works .section-subtitle {
  color: rgba(255, 255, 255, 0.8);
}

.how-it-works-steps {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.how-step {
  --mx: 50%;
  --my: 50%;
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  flex: 1;
  min-width: 280px;
  max-width: 360px;
  padding: 40px 32px;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  
   border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  transform: perspective(1000px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition:
    transform 0.2s ease-out,
    box-shadow 0.45s cubic-bezier(0.4, 0, 0.2, 1),
    border-color 0.35s ease,
    background 0.35s ease;
  will-change: transform;
  cursor: default;
}

/* Cursor-following highlight (filled via JS --mx / --my) */
.how-step::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    520px circle at var(--mx) var(--my),
    rgba(255, 255, 255, 0.22),
    rgba(196, 30, 58, 0.08) 38%,
    transparent 62%
  );
  opacity: 0;
  transition: opacity 0.45s ease;
  pointer-events: none;
  z-index: 0;
}

.how-step::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.45),
    rgba(196, 30, 58, 0.5) 45%,
    rgba(255, 255, 255, 0.15)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
  z-index: 0;
}

.how-step > * {
  position: relative;
  z-index: 1;
}

.how-step:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.35);
  transform: perspective(1000px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) translateY(-10px) scale(1.02);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 40px rgba(196, 30, 58, 0.25);
}

.how-step:hover::before {
  opacity: 1;
}

.how-step:hover::after {
  opacity: 1;
}

.how-step-icon {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--color-accent), #8f1428);
  border-radius: 50%;
  color: #fff;
  box-shadow: 0 8px 24px rgba(196, 30, 58, 0.45);
  transition:
    transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.35s ease;
}

.how-step:hover .how-step-icon {
  transform: scale(1.08) rotate(-6deg);
  box-shadow: 0 12px 32px rgba(196, 30, 58, 0.55);
}

.how-step:hover .how-step-icon svg {
  animation: howStepIconPulse 1.2s ease-in-out infinite;
}

@keyframes howStepIconPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.06);
  }
}

@media (prefers-reduced-motion: reduce) {
  .how-step {
    transform: none;
  }

  .how-step:hover {
    transform: translateY(-4px);
  }

  .how-step::before,
  .how-step::after {
    opacity: 0 !important;
    transition: none;
  }

  .how-step:hover .how-step-icon {
    transform: none;
  }

  .how-step:hover .how-step-icon svg {
    animation: none;
  }
}

.how-step-number {
  display: block;
  font-size: 48px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 12px;
  line-height: 1;
}

.how-step-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}

.how-step-desc {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
}

.how-step-arrow {
  display: flex;
  align-items: center;
  font-size: 28px;
  color: rgba(255, 255, 255, 0.6);
  flex-shrink: 0;
}

@media (max-width: 1024px) {
  .how-step-arrow {
    display: none;
  }

  .how-it-works-steps {
    flex-direction: column;
    align-items: center;
  }

  .how-step {
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .how-it-works {
    padding: 60px 24px;
  }

  .how-it-works-bg {
    background-attachment: scroll;
  }

  .how-step-number {
    font-size: 36px;
  }

  .how-step-title {
    font-size: 20px;
  }
}

/* ========== GALLERY – Editorial masonry (imgg 1–14 + img 1–9 at end) ========== */
.gallery {
  padding: clamp(56px, 8vw, 100px) clamp(16px, 3vw, 40px);
  max-width: 1320px;
  margin: 0 auto;
  width: 100%;
}

.gallery .section-header {
  margin-bottom: clamp(32px, 5vw, 52px);
}

.gallery .section-title::after {
  content: '';
  display: block;
  width: 48px;
  height: 3px;
  margin: 14px auto 0;
  background: var(--color-accent);
}

.gallery-grid {
  column-count: 1;
  column-gap: 6px;
  width: 100%;
  margin: 0 auto;
}

.gallery-item {
  position: relative;
  display: block;
  overflow: hidden;
  margin-bottom: 6px;
  break-inside: avoid;
  cursor: pointer;
  background: #0a0a0a;
  transition:
    opacity 0.4s ease,
    filter 0.4s ease,
    transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: middle;
  transition: transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-item-view {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--color-accent);
  opacity: 0;
  transform: translateY(-6px);
  transition:
    opacity 0.35s ease,
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.gallery-item::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0);
  transition: background 0.35s ease;
  pointer-events: none;
}

.gallery-item:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.gallery-grid:has(.gallery-item:hover) .gallery-item:not(:hover),
.gallery-grid:has(.gallery-item:focus-visible) .gallery-item:not(:focus-visible) {
  opacity: 0.42;
  filter: saturate(0.65);
}

.gallery-item:hover,
.gallery-item:focus-visible {
  opacity: 1 !important;
  filter: none !important;
  transform: translateY(-2px);
  z-index: 2;
}

.gallery-item:hover::before,
.gallery-item:focus-visible::before {
  background: rgba(0, 0, 0, 0.12);
}

.gallery-item:hover img,
.gallery-item:focus-visible img {
  transform: scale(1.03);
}

.gallery-item:hover .gallery-item-view,
.gallery-item:focus-visible .gallery-item-view {
  opacity: 1;
  transform: translateY(0);
}

.gallery-item[data-animate] {
  opacity: 1;
}

@media (min-width: 520px) {
  .gallery-grid {
    column-count: 2;
    column-gap: 8px;
  }

  .gallery-item {
    margin-bottom: 8px;
  }
}

@media (min-width: 900px) {
  .gallery-grid {
    column-count: 3;
    column-gap: 10px;
  }

  .gallery-item {
    margin-bottom: 10px;
  }
}

@media (min-width: 1200px) {
  .gallery-grid {
    column-count: 4;
    column-gap: 12px;
  }
}

/* ========== GALLERY LIGHTBOX ========== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  z-index: 2010;
  width: 48px;
  height: 48px;
  font-size: 36px;
  line-height: 1;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2010;
  width: 56px;
  height: 56px;
  font-size: 48px;
  line-height: 1;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.lightbox-prev {
  left: 24px;
}

.lightbox-next {
  right: 24px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-prev:hover {
  transform: translateY(-50%) scale(1.05);
}

.lightbox-next:hover {
  transform: translateY(-50%) scale(1.05);
}

@media (max-width: 768px) {
  .lightbox-prev {
    left: 12px;
  }

  .lightbox-next {
    right: 12px;
  }

  .lightbox-prev,
  .lightbox-next {
    width: 44px;
    height: 44px;
    font-size: 36px;
  }

  .lightbox-close {
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    font-size: 32px;
  }
}

/* ========== CONTACT ========== */
.contact {
  padding: 80px 40px 100px;
  max-width: 1400px;
  margin: 0 auto;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 32px 28px;
  align-items: stretch;
}

.contact-info {
  grid-column: span 6;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.contact-map {
  grid-column: span 6;
  align-self: stretch;
}

.contact-form-col--full {
  grid-column: 1 / -1;
  margin-top: 24px;
}

.contact-item {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 16px 20px;
  background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
  border-radius: 14px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition-fast);
}

.contact-item:hover {
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.06);
  border-color: rgba(196, 30, 58, 0.15);
}

.contact-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  flex-shrink: 0;
}

.contact-icon svg {
  width: 22px;
  height: 22px;
}

.contact-item strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.contact-item p {
  color: var(--color-text);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
}

/* Contact form – full width (12 col) card */
.contact-form-card {
  padding: 44px 48px 48px;
  background: linear-gradient(165deg, #ffffff 0%, #fafafa 100%);
  border-radius: 20px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04), 0 0 0 1px rgba(0, 0, 0, 0.02);
  transition: box-shadow var(--transition);
}

.contact-form-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 28px;
}

.contact-form-fields .contact-field--textarea {
  grid-column: 1 / -1;
}

.contact-form-card:hover {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.07), 0 0 0 1px rgba(0, 0, 0, 0.03);
}

.contact-form-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.contact-form-subtitle {
  font-size: 14px;
  color: var(--color-text-muted);
  margin-bottom: 28px;
  letter-spacing: 0.01em;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.contact-field {
  position: relative;
}

.contact-field input,
.contact-field textarea {
  width: 100%;
  padding: 22px 20px 14px;
  border: 2px solid var(--color-border);
  border-radius: 12px;
  font-family: inherit;
  font-size: 16px;
  color: var(--color-text);
  background: #fff;
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

.contact-field input::placeholder,
.contact-field textarea::placeholder {
  color: transparent;
}

.contact-field input:focus,
.contact-field textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 4px rgba(196, 30, 58, 0.12);
  background: #fff;
}

.contact-field label {
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  color: var(--color-text-muted);
  pointer-events: none;
  transition: transform 0.2s ease, font-size 0.2s ease, color 0.2s ease, top 0.2s ease;
}

.contact-field--textarea label {
  top: 28px;
  transform: translateY(0);
}

.contact-field input:focus + label,
.contact-field input:not(:placeholder-shown) + label,
.contact-field input:not([value=""]) + label {
  top: 12px;
  transform: translateY(0);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
}

.contact-field--textarea textarea:focus + label,
.contact-field--textarea textarea:not(:placeholder-shown) + label {
  top: 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
}

.contact-field textarea {
  min-height: 140px;
  resize: vertical;
  padding-top: 28px;
}

.contact-form-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 18px 28px;
  margin-top: 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, var(--color-accent) 0%, #a01830 100%);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(196, 30, 58, 0.35);
  transition: transform var(--transition-fast), box-shadow var(--transition), opacity 0.2s ease;
}

.contact-form-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(196, 30, 58, 0.4);
}

.contact-form-submit:active {
  transform: translateY(0);
}

.contact-form-submit svg {
  flex-shrink: 0;
  opacity: 0.95;
}

.contact-form-submit[disabled] {
  opacity: 0.7;
  cursor: progress;
}

.contact-form-status {
  margin-top: 14px;
  font-size: 13px;
  color: var(--color-text-muted);
}

.contact-form-status--success {
  color: #1b7f4a;
}

.contact-form-status--error {
  color: #c41e3a;
}

.contact-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: -4px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-text-muted);
}

.contact-consent input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--color-accent);
  cursor: pointer;
  flex-shrink: 0;
}

.contact-consent span {
  color: var(--color-text);
}

.contact-consent a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.contact-consent a:hover {
  color: #a01830;
}

.contact-popup {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(2, 6, 23, 0.45);
  z-index: 2147483647;
  opacity: 0;
  transition: opacity 0.22s ease;
}

.contact-popup.is-visible {
  opacity: 1;
}

.contact-popup__box {
  width: min(420px, 100%);
  border-radius: 14px;
  padding: 16px 16px 14px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 18px 36px rgba(2, 6, 23, 0.45);
  color: #ffffff;
  transform: translateY(10px) scale(0.98);
  transition: transform 0.22s ease;
}

.contact-popup.is-visible .contact-popup__box {
  transform: translateY(0) scale(1);
}

.contact-popup__icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  background: rgba(255, 255, 255, 0.18);
  margin-bottom: 8px;
}

.contact-popup__text {
  font-size: 14px;
  line-height: 1.55;
}

.contact-popup__close {
  margin-top: 12px;
  border: 0;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  color: #0f172a;
  background: #ffffff;
}

.contact-popup--success {
  background: transparent;
}

.contact-popup--success .contact-popup__box {
  background: linear-gradient(135deg, #0f9f62, #0b7a4a);
}

.contact-popup--error {
  background: transparent;
}

.contact-popup--error .contact-popup__box {
  background: linear-gradient(135deg, #d13252, #a71d39);
}

@media (max-width: 600px) {
  .contact-popup__box {
    width: 100%;
  }
}

.contact-map {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  overflow: hidden;
  min-height: 100%;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.contact-map iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Contact links */
.contact-item a {
  color: var(--color-text);
  transition: color var(--transition-fast);
}

.contact-item a:hover {
  color: var(--color-accent);
}

/* Floating Buttons – WhatsApp left, Scroll to Top right, same row (bottom) */
.floating-buttons {
  position: fixed;
  bottom: 24px;
  left: 0;
  right: 0;
  z-index: 998;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
  padding: 0 24px;
}

.floating-buttons > * {
  pointer-events: auto;
}

/* WhatsApp – shake animation */
@keyframes whatsappShake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
  20%, 40%, 60%, 80% { transform: translateX(4px); }
}

.whatsapp-float {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: #25d366;
  color: #fff;
  border-radius: 50px;
  box-shadow: 0 4px 24px rgba(37, 211, 102, 0.4);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  animation: whatsappShake 3s ease-in-out infinite;
  transition: transform var(--transition), box-shadow var(--transition);
}

.whatsapp-float:hover {
  animation: none;
  transform: scale(1.05);
  box-shadow: 0 6px 28px rgba(37, 211, 102, 0.5);
  color: #fff;
}

.whatsapp-float svg {
  flex-shrink: 0;
}

/* Scroll to Top – white bg, black arrow */
.scroll-to-top {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  background: #fff;
  color: #000;
  border-radius: 50%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background 0.2s ease;
}

.scroll-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.scroll-to-top:hover {
  background: #f5f5f5;
  color: #000;
  transform: translateY(-4px);
}

@media (max-width: 768px) {
  .floating-buttons {
    bottom: 20px;
    padding: 0 20px;
  }

  .scroll-to-top {
    width: 46px;
    height: 46px;
  }

  .whatsapp-float span {
    display: none;
  }

  .whatsapp-float {
    padding: 16px;
  }

  .whatsapp-float svg {
    width: 28px;
    height: 28px;
  }
}

/* ========== FEATURES BAR – Trust / Schweiz ========== */
.features-bar {
  background: linear-gradient(180deg, #0d0d0d 0%, #141414 100%);
  padding: 32px 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.features-bar-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: center;
  justify-items: center;
  gap: 12px 20px;
}

.feature-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 0;
  width: 100%;
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.feature-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(196, 30, 58, 0.15);
  border-radius: 12px;
  color: var(--color-accent);
}

.feature-text {
  white-space: nowrap;
  line-height: 1.3;
}

@media (min-width: 1200px) {
  .features-bar-inner {
    gap: 16px 28px;
  }

  .feature-item {
    font-size: 14px;
    gap: 12px;
  }

  .feature-icon {
    width: 44px;
    height: 44px;
  }
}

@media (max-width: 1024px) {
  .features-bar-inner {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px 24px;
  }

  .feature-item {
    font-size: 13px;
  }

  .feature-text {
    white-space: normal;
    text-align: center;
  }
}

@media (max-width: 768px) {
  .features-bar {
    padding: 24px 24px;
  }

  .features-bar-inner {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .feature-item {
    justify-content: center;
  }
}

/* ========== SERVICES – Grid ========== */
.services {
  padding: 120px 40px 100px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4vw, 44px);
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}

.section-subtitle {
  font-size: 14px;
  color: var(--color-text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 32px;
}

@media (min-width: 1025px) {
  .service-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* Center the 4th card on its own row on desktop */
  .service-grid > .service-card:nth-child(4) {
    grid-column: 2 / 3;
  }
}

.service-card {
  perspective: 1000px;
  min-height: 660px;
}

.service-card-inner {
  position: relative;
  width: 100%;
  max-width: 391px;
  height: 100%;
  min-height: 660px;
  margin: 0 auto;
  transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

@media (min-width: 1025px) {
  .service-card-inner {
    width: 391px;
    height: 56%;
    min-height: 660px;
  }
}

.service-card:hover .service-card-inner,
.service-card.is-flipped .service-card-inner {
  transform: rotateY(180deg);
}

.service-card-front,
.service-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 28px;
}

.service-card-front {
  position: relative;
  background: #1a1a1a;
  border: 1px solid var(--color-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  border-radius: 12px;
}

.service-card-front::before {
  border-radius: 12px;
  content: '';
  position: absolute;
  inset: 0;
  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat;
  opacity: 0.72;
  z-index: 0;
}

.service-card--repairs .service-card-front::before {
  background-image: url('../imgg/11.jpeg');
}

.service-card--parts .service-card-front::before {
  background-image: url('../imgg/9.jpeg');
}

.service-card-front::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0.55) 100%);
  z-index: 1;
  border-radius: 12px;
}

.service-card-front .service-icon,
.service-card-front .service-title,
.service-card-front .service-hover-hint {
  position: relative;
  z-index: 2;
}

.service-card-front .service-icon {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.service-card-front .service-title {
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

.service-card-front .service-hover-hint {
  color: rgba(255, 255, 255, 0.9);
}

.service-card-back {
  background: linear-gradient(135deg, var(--color-accent) 0%, #a01830 100%);
  transform: rotateY(180deg);
  overflow-y: auto;
  padding: 32px 24px;
}

.service-card-back .service-desc {
  color: rgba(255, 255, 255, 0.95);
  font-size: 14px;
  line-height: 1.65;
  text-align: center;
}

.service-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(196, 30, 58, 0.1);
  border-radius: 50%;
  color: var(--color-accent);
  transition: transform var(--transition);
}

.service-card:hover .service-icon {
  transform: scale(1.1);
}

.service-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}

.service-hover-hint {
  font-size: 11px;
  color: var(--color-text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.8;
}

.service-desc {
  font-size: 15px;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* Service cards – GSAP scroll reveal */
.service-card[data-animate] {
  opacity: 1;
  transform: none;
}

.gallery .section-header, .contact .section-header {
  margin-bottom: 50px;
}

/* ========== FOOTER ========== */
.footer {
  background: #000;
  color: #fff;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.footer-main {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 48px;
  align-items: center;
  padding: 48px 0 32px;
}

.footer-logo-wrap {
  display: block;
}

.footer-logo {
  height: 88px;
  width: auto;
  object-fit: contain;
  display: block;
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: 32px;
}

.footer-link {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: var(--color-accent);
}

.footer-contact {
  text-align: right;
}

.footer-contact p {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.7;
}

.footer-contact a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-contact a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  padding: 20px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-copy {
  margin: 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: 0.05em;
  text-align: center;
}

.footer-legal {
  margin: 10px 0 0;
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
}

.footer-legal a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
}

.footer-legal a:hover {
  color: var(--color-accent);
}

.seo-split {
  max-width: 1400px;
  margin: 28px auto 72px;
  padding: 0 48px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  border-radius: 22px;
  overflow: hidden;
  background: #111827;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.seo-split-media {
  position: relative;
  min-height: 460px;
  height: 100%;
  overflow: hidden;
  background: #0d0d0d;
  opacity: 0;
}

.seo-split-media.is-inview {
  opacity: 1;
}

.seo-split-media.animate__lightSpeedInLeft {
  --animate-duration: 0.9s;
}

.seo-split-copy.animate__lightSpeedInRight {
  --animate-duration: 0.9s;
}

.seo-split-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 0;
  opacity: 1;
  transition: none;
  background: #0d0d0d;
}

.seo-split-slide.is-active {
  z-index: 1;
}

.seo-split-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
}

.seo-split-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.1) 25%, rgba(0, 0, 0, 0.5) 100%);
}

.seo-split-badges {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  z-index: 2;
}

.seo-split-badges span {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(17, 24, 39, 0.55);
  color: #fff;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.seo-split-dots {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  gap: 6px;
  z-index: 2;
}

.seo-split-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
}

.seo-split-dot.is-active {
  background: #fff;
  transform: scale(1.2);
}

.seo-split-copy {
  padding: 48px 44px;
  background: linear-gradient(160deg, #111827 0%, #1f2937 100%);
  color: #f9fafb;
  opacity: 0;
}

.seo-split-copy.is-inview {
  opacity: 1;
}

.seo-split-title {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 38px;
  line-height: 1.2;
}

.seo-split-subtitle {
  margin: 0 0 22px;
  font-size: 16px;
  color: #d1d5db;
}

.seo-split-copy p {
  margin: 0 0 16px;
  line-height: 1.75;
  color: #e5e7eb;
}

.seo-split-copy strong {
  color: #fff;
}

#cookie-box {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.65);
  z-index: 9999;
}

.cookie-box-overlay {
  position: absolute;
  inset: 0;
}

.cookie-box-card {
  position: relative;
  max-width: 480px;
  width: 100%;
  background: #1a1a1a;
  color: #fff;
  padding: 32px 28px;
  border-radius: 16px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.cookie-box-title {
  margin: 0 0 12px;
  font-size: 22px;
}

.cookie-box-card p {
  margin: 0 0 20px;
  line-height: 1.6;
  font-size: 15px;
}

.cookie-box-card a {
  color: #fff;
  text-decoration: underline;
}

.cookie-box-card a:hover {
  color: var(--color-accent);
}

#cookie-box button {
  background: #fff;
  color: #000;
  border: none;
  padding: 12px 28px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border-radius: 10px;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .seo-split {
    grid-template-columns: 1fr;
    margin-bottom: 56px;
    padding: 0 24px;
  }

  .seo-split-media {
    min-height: min(72vw, 520px);
    aspect-ratio: 4 / 5;
  }

  .seo-split-badges {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .seo-split-copy {
    padding: 32px 28px;
  }

  .seo-split-title {
    font-size: 30px;
  }

  .header-inner {
    padding: 0 24px;
  }

  .nav-main {
    gap: 28px;
  }

  .hero-content {
    padding: 0 32px;
    gap: 40px;
  }

  /* Tablet: shorter hero vs full viewport — less aggressive vertical crop with cover */
  .hero {
    height: min(88vh, 820px);
    min-height: 560px;
  }

  .hero-inner {
    height: 100%;
    min-height: min(88vh, 820px);
  }

  .hero-copy {
    max-width: 380px;
    padding: 20px 18px 22px;
  }

  .service-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-card {
    min-height: 660px;
  }

  .service-card-inner {
    width: 100%;
    max-width: 391px;
    height: 100%;
    min-height: 660px;
  }

  .service-card-front::before {
    background-size: contain;
    opacity: 0.72;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-info,
  .contact-map {
    grid-column: 1 / -1;
  }

  .contact-form-fields {
    grid-template-columns: 1fr;
  }

  .footer-main {
    grid-template-columns: 1fr;
    gap: 32px;
    text-align: center;
  }

  .footer-logo-wrap {
    display: flex;
    justify-content: center;
  }

  .footer-nav {
    flex-wrap: wrap;
    justify-content: center;
  }

  .footer-contact {
    text-align: center;
  }

  .contact-map {
    height: 350px;
  }

  .contact-form-card {
    padding: 32px 28px 36px;
  }

  .contact-form-title {
    font-size: 22px;
  }
}

@media (max-width: 900px) {
  .nav-toggle {
    display: flex;
  }

  .nav-lang {
    display: none;
  }

  .nav-main {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    max-width: 85vw;
    height: 100vh;
    background: #000;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 100px 24px 40px;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.3);
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1001;
  }

  .header.is-menu-open .nav-main {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
  }

  .header.is-menu-open .nav-overlay {
    display: block;
  }

  .nav-link {
    font-size: 16px;
    padding: 12px 0;
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 768px) {
  :root {
    --header-height: 80px;
  }

  /* Mobile: compact hero (≈65vh cap) — cover scales gentler vs tall strip; no Ken Burns zoom */
  .hero {
    height: clamp(280px, 65vh, 70vh);
    min-height: 280px;
    max-height: 70vh;
    overflow: hidden;
  }

  .hero-inner {
    height: 100%;
    min-height: 100%;
    overflow: hidden;
  }

  .hero-bg {
    background-attachment: scroll;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    background-size: cover;
    background-position: var(--hero-bg-position);
    animation: none;
    transform: none;
    transform-origin: center center;
  }

  /* Phone: hero text/card hidden — hide wrapper too (avoids empty padded block) */
  .hero-content {
    display: none !important;
  }

  /* Phone: full-bleed hero image only */
  .hero-copy,
  .hero-visual-card {
    display: none !important;
  }

  .hero-visual {
    display: none !important;
    min-height: 0;
  }

  .hero-bean--left {
    left: -30px;
    bottom: -10px;
  }

  .hero-bean--right {
    right: -35px;
    top: auto;
    bottom: 45%;
  }

  .logo-img {
    height: 64px;
  }

  .hero-pagination {
    bottom: max(16px, env(safe-area-inset-bottom, 0px)) !important;
  }

  .services {
    padding: 80px 24px 60px;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

  .service-card {
    min-height: min(92vh, 660px);
  }

  .service-card-inner {
    width: 100%;
    max-width: 100%;
    height: 100%;
    min-height: min(92vh, 660px);
  }

  .service-card-front::before {
    background-size: cover;
    background-position: center center;
    opacity: 0.72;
  }

  .gallery {
    padding: 60px 24px 80px;
  }

  .contact {
    padding: 60px 24px 80px;
  }

  .contact-form-card {
    padding: 28px 22px 32px;
    border-radius: 16px;
  }

  .contact-form-title {
    font-size: 20px;
  }

  .contact-form-subtitle {
    margin-bottom: 22px;
  }

  .contact-form-fields {
    gap: 18px;
  }

  .contact-field input,
  .contact-field textarea {
    padding: 20px 18px 12px;
  }

  .contact-item {
    padding: 14px 16px;
  }

  .contact-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    min-height: 42px;
    font-size: 20px;
  }

  .contact-map {
    height: 280px;
    border-radius: 12px;
  }

  .footer-logo {
    height: 64px;
  }

  .footer-inner {
    padding: 0 24px;
  }
}

/* ========== LEGAL PAGES (Datenschutz, Impressum) ========== */
body.page-legal {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-legal .legal-wrap {
  flex: 1;
  width: 100%;
  min-width: 0;
}

.page-legal .legal-page {
  max-width: 980px;
  margin: 0 auto;
  padding: calc(var(--header-height) + 40px) clamp(16px, 4vw, 24px) 48px;
  width: 100%;
  box-sizing: border-box;
}

.page-legal .legal-card {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 16px;
  padding: clamp(20px, 4vw, 28px);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.05);
  overflow-wrap: anywhere;
  word-wrap: break-word;
}

.page-legal .legal-page h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin-bottom: 12px;
  line-height: 1.2;
}

.page-legal .legal-page h2 {
  margin: 28px 0 10px;
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  line-height: 1.3;
}

.page-legal .legal-page p,
.page-legal .legal-page li {
  line-height: 1.7;
  color: #1f2937;
}

.page-legal .legal-page ul {
  padding-left: 1.25rem;
}

.page-legal .legal-note {
  background: #fff8e1;
  border: 1px solid #f5d77a;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-size: 14px;
}

@media (max-width: 768px) {
  .page-legal .legal-page {
    padding-top: calc(var(--header-height) + 24px);
    padding-bottom: 32px;
  }

  .page-legal .legal-card {
    border-radius: 12px;
  }
}

@media (max-width: 380px) {
  .page-legal .legal-page {
    padding-left: 12px;
    padding-right: 12px;
  }
}
