/* ===== Self-hosted Google Fonts ===== */
@font-face {
  font-family: "Merienda";
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url(fonts/merienda-latin-ext.woff2) format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
    U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
    U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Merienda";
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url(fonts/merienda-latin.woff2) format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(fonts/inter-latin-ext.woff2) format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
    U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
    U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(fonts/inter-latin.woff2) format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}

/* ===== CSS Variables & Reset ===== */
:root {
  --color-primary: #2d6a1e;
  --color-primary-light: #3d8b2a;
  --color-primary-dark: #1e4a14;
  --color-accent: #c8a951;
  --color-accent-light: #e0c878;
  --color-bg: #fafaf5;
  --color-bg-alt: #f0efe8;
  --color-bg-dark: #1a2e14;
  --color-text: #2c2c2c;
  --color-text-light: #6b6b6b;
  --color-text-on-dark: #f0f0e8;
  --color-white: #ffffff;
  --color-border: #e0dfda;
  --color-whatsapp: #25d366;
  --font-heading: "Merienda", Georgia, cursive;
  --font-body:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.12);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --transition: 0.3s ease;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-primary-light);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Typography ===== */
h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  line-height: 1.2;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: var(--color-primary-dark);
  text-align: center;
  margin-bottom: 0.5rem;
}

.section-title.text-left {
  text-align: left;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--color-text-light);
  text-align: center;
  margin-bottom: 3rem;
}

/* ===== Navbar ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #ffffff;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: all var(--transition);
}

.navbar.scrolled {
  border-bottom-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-logo img {
  height: 52px;
  width: auto;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  padding: 4px 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width var(--transition);
}

.nav-links a:hover {
  color: var(--color-primary);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: all 0.35s ease;
  border-radius: 2px;
  transform-origin: center;
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(135deg, rgba(30, 74, 20, 0.85), rgba(45, 106, 30, 0.7)),
    url("images/hero-image.webp") center/cover no-repeat;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at 30% 80%,
    rgba(200, 169, 81, 0.15) 0%,
    transparent 60%
  );
}

.hero-content {
  position: relative;
  text-align: center;
  color: var(--color-white);
  padding: 120px 24px 80px;
}

.hero-logo-circle {
  width: 280px;
  height: 280px;
  margin: 0 auto 2rem;
  background: var(--color-white);
  border-radius: 50%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-logo {
  width: 210px;
  display: block;
}

.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  margin-bottom: 1rem;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  opacity: 0.9;
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition);
  border: 2px solid transparent;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-bg-dark);
  border-color: var(--color-accent);
}

.btn-primary:hover {
  background: var(--color-accent-light);
  border-color: var(--color-accent-light);
  color: var(--color-bg-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(200, 169, 81, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
}

/* ===== Sections ===== */
.section {
  padding: 100px 0;
}

/* ===== Services ===== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  padding: 2.5rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary-light);
}

.service-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1.5rem;
  color: var(--color-primary);
}

.service-card h3 {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--color-primary-dark);
}

.service-card p {
  color: var(--color-text-light);
  font-size: 0.95rem;
}

/* ===== Region Banner ===== */
.section-banner {
  background: var(--color-bg-dark);
  padding: 50px 0;
  text-align: center;
}

.banner-content h3 {
  color: var(--color-accent);
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
}

.region-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.region-tag {
  background: rgba(255, 255, 255, 0.1);
  color: var(--color-text-on-dark);
  padding: 8px 24px;
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

/* ===== Mithilfe ===== */
.mithilfe {
  background: var(--color-bg-alt);
}

.mithilfe-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.mithilfe-lead {
  font-size: 1.2rem;
  color: var(--color-primary-dark);
  margin-bottom: 1rem;
  font-weight: 500;
}

.mithilfe-content > p {
  margin-bottom: 2rem;
  color: var(--color-text-light);
}

.mithilfe-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(45, 106, 30, 0.08);
  border-left: 3px solid var(--color-primary);
  padding: 1rem 1.25rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.9rem;
  color: var(--color-text-light);
}

.mithilfe-note svg {
  flex-shrink: 0;
  color: var(--color-primary);
  margin-top: 2px;
}

.mithilfe-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.mithilfe-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-height: 400px;
}

/* ===== Maschinenpark ===== */
.maschinenpark {
  background: var(--color-white);
}

.machines-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.machine-card {
  background: var(--color-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}

.machine-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.machine-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.machine-card h4 {
  padding: 1.25rem 1.25rem 0.25rem;
  color: var(--color-primary-dark);
  font-size: 1.1rem;
}

.machine-card p {
  padding: 0 1.25rem 1.25rem;
  color: var(--color-text-light);
  font-size: 0.9rem;
}

/* ===== Instagram / Referenzen ===== */
.referenzen {
  background: var(--color-bg-alt);
}

.instagram-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: var(--color-primary);
}

.instagram-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.insta-card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}

.insta-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.insta-img-placeholder {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f0efe8 0%, #e8e5d8 100%);
  color: var(--color-text-light);
}

.insta-caption {
  padding: 1rem;
  font-size: 0.85rem;
  color: var(--color-text-light);
}

.instagram-fallback-grid {
  display: contents;
}

/* Live Instagram cards */
.insta-card-live {
  display: block;
  text-decoration: none;
  color: inherit;
}

.insta-img-live {
  aspect-ratio: 1;
  overflow: hidden;
}

.insta-img-live img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.insta-card-live:hover .insta-img-live img {
  transform: scale(1.05);
}

.insta-card-body {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.insta-date {
  font-size: 0.8rem;
  color: var(--color-text-light);
  opacity: 0.7;
}

.instagram-cta {
  text-align: center;
}

/* ===== Kontakt ===== */
.kontakt {
  background: var(--color-white);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 900px;
  margin: 0 auto;
}

.contact-card {
  text-align: center;
  padding: 2rem;
  border-radius: var(--radius-md);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
}

.contact-icon {
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.contact-card h4 {
  margin-bottom: 0.5rem;
  color: var(--color-primary-dark);
}

.contact-card p {
  color: var(--color-text-light);
}

.contact-card a {
  color: var(--color-text-light);
}

.contact-card a:hover {
  color: var(--color-primary);
}

/* ===== Footer ===== */
.footer {
  background: var(--color-bg-dark);
  color: var(--color-text-on-dark);
  padding: 60px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-logo-circle {
  width: 100px;
  height: 100px;
  background: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.footer-logo {
  height: 65px;
}

.footer-brand p {
  color: rgba(240, 240, 232, 0.7);
  font-size: 0.9rem;
  max-width: 300px;
}

.footer h4 {
  color: var(--color-accent);
  margin-bottom: 1rem;
  font-size: 1rem;
}

.footer ul {
  list-style: none;
}

.footer ul li {
  margin-bottom: 0.5rem;
}

.footer ul a {
  color: rgba(240, 240, 232, 0.7);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.footer ul a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  padding: 1.5rem 0;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(240, 240, 232, 0.5);
}

/* ===== WhatsApp Button ===== */
.whatsapp-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 64px;
  height: 64px;
  background: var(--color-whatsapp);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  z-index: 999;
  transition: all var(--transition);
  animation: whatsapp-pulse 2s infinite;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
}

@keyframes whatsapp-pulse {
  0%,
  100% {
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  }
  50% {
    box-shadow: 0 4px 30px rgba(37, 211, 102, 0.6);
  }
}

/* ===== Scroll Animations ===== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s ease forwards;
}

.delay-1 {
  animation-delay: 0.2s;
}
.delay-2 {
  animation-delay: 0.4s;
}
.delay-3 {
  animation-delay: 0.6s;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}

.scroll-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
  .mithilfe-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .mithilfe-image {
    order: -1;
  }

  .mithilfe-image img {
    min-height: 300px;
  }

  .section-title.text-left {
    text-align: center;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    display: flex;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--color-white);
    flex-direction: column;
    padding: 0 24px;
    gap: 0;
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition:
      max-height 0.4s ease,
      opacity 0.3s ease,
      padding 0.4s ease;
  }

  .nav-links.active {
    max-height: 400px;
    opacity: 1;
    padding: 1.5rem 24px;
  }

  .nav-links li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
    opacity: 0;
    transform: translateY(-10px);
    transition:
      opacity 0.3s ease,
      transform 0.3s ease;
  }

  .nav-links.active li {
    opacity: 1;
    transform: translateY(0);
  }

  .nav-links.active li:nth-child(1) {
    transition-delay: 0.05s;
  }
  .nav-links.active li:nth-child(2) {
    transition-delay: 0.1s;
  }
  .nav-links.active li:nth-child(3) {
    transition-delay: 0.15s;
  }
  .nav-links.active li:nth-child(4) {
    transition-delay: 0.2s;
  }
  .nav-links.active li:nth-child(5) {
    transition-delay: 0.25s;
  }

  .nav-links li:last-child {
    border-bottom: none;
  }

  .hero-logo-circle {
    width: 240px;
    height: 240px;
  }

  .hero-logo {
    width: 180px;
  }

  .section {
    padding: 70px 0;
  }

  .machines-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .instagram-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .whatsapp-btn {
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
  }
}

@media (max-width: 480px) {
  .hero-logo-circle {
    width: 210px;
    height: 210px;
  }

  .hero-logo {
    width: 160px;
  }

  .btn {
    padding: 12px 24px;
    font-size: 0.9rem;
  }

  .machines-grid {
    grid-template-columns: 1fr;
  }

  .instagram-grid {
    grid-template-columns: 1fr 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Legal Pages (Impressum / Datenschutz) ===== */
.legal-page {
  padding-top: 120px;
  padding-bottom: 80px;
}

.legal-page h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--color-primary-dark);
  margin-bottom: 2rem;
}

.legal-page h2 {
  font-size: 1.4rem;
  color: var(--color-primary-dark);
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}

.legal-page h3 {
  font-size: 1.15rem;
  color: var(--color-primary);
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

.legal-page h4 {
  font-size: 1rem;
  color: var(--color-text);
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

.legal-page p {
  margin-bottom: 1rem;
  color: var(--color-text-light);
  max-width: 800px;
}

.legal-page ul {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
  color: var(--color-text-light);
}

.legal-page ul li {
  margin-bottom: 0.35rem;
}

.back-link {
  margin-top: 3rem;
  display: inline-flex;
}
