/* ============================================================
   Anhängerzentrale Dorfen – Stylesheet
   Fahrzeughandel Georg Glockshuber
   ============================================================ */

/* ── Reset & Box Model ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ── Variables ── */
:root {
  --red:          #c0392b;
  --red-dark:     #a93226;
  --humbaur:      #FFD100;
  --humbaur-dark: #E8BC00;
  --bg:           #f5f5f5;
  --bg-alt:       #ebebeb;
  --card-bg:      #ffffff;
  --border:       #d8d8d8;
  --text:         #1a1a1a;
  --muted:        #666666;
  --nav-dark:     #111111;
  --nav-h:        76px;
  --radius:       2px;
  --shadow:       0 2px 16px rgba(0,0,0,.08);
}

/* ── Base ── */
html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-h);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, Helvetica, sans-serif;
  font-size: 16px;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

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

a { color: var(--red); }

/* ── Navigation ── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  height: var(--nav-h);
  background: rgba(15, 15, 15, 0.97);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5%;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.nav-logo img {
  height: 50px;
  width: auto;
  display: block;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  color: #e8e8e8;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  transition: color 0.2s;
  white-space: nowrap;
}

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

.nav-links .nav-cta {
  background: var(--red);
  color: #fff;
  padding: 9px 20px;
  border-radius: var(--radius);
  transition: background 0.2s;
}

.nav-links .nav-cta:hover { background: var(--red-dark); color: #fff; }

.nav-links .nav-ext { color: var(--humbaur); }
.nav-links .nav-ext:hover { color: var(--humbaur-dark); }

.hamburger {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
  padding: 4px 8px;
  touch-action: manipulation;
}

/* ── Buttons ── */
.btn-primary, .btn-outline, .btn-white {
  display: inline-block;
  padding: 14px 32px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  text-decoration: none;
  border-radius: var(--radius);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  touch-action: manipulation;
  cursor: pointer;
  border: 2px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}
.btn-primary:hover { background: var(--red-dark); border-color: var(--red-dark); color: #fff; }

.btn-outline {
  background: transparent;
  color: #fff;
  border-color: rgba(255,255,255,.55);
}
.btn-outline:hover { border-color: #fff; color: #fff; }

.btn-white {
  background: #fff;
  color: var(--red);
  border-color: #fff;
}
.btn-white:hover { background: #f0f0f0; border-color: #f0f0f0; color: var(--red-dark); }

.btn-humbaur {
  background: var(--humbaur);
  color: #111;
  border-color: var(--humbaur);
}
.btn-humbaur:hover { background: var(--humbaur-dark); border-color: var(--humbaur-dark); color: #111; }

/* ── Hero ── */
#home {
  height: 100svh;
  min-height: 580px;
  background: url('img/tieflader.webp') center / cover no-repeat;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#home::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(0,0,0,.65) 0%,
    rgba(0,0,0,.35) 50%,
    rgba(0,0,0,.6) 100%
  );
}

.hero-inner {
  position: relative;
  padding: 0 20px;
  max-width: 860px;
}

.hero-badge {
  display: inline-block;
  background: var(--humbaur);
  color: #111;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 6px 16px;
  margin-bottom: 20px;
  border-radius: var(--radius);
}

.hero-inner h1 {
  font-size: clamp(38px, 6.5vw, 76px);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 3px;
  line-height: 1.08;
  color: #fff;
  text-shadow: 0 2px 16px rgba(0,0,0,.5);
}

.hero-inner h1 span { color: var(--red); }

.hero-inner .hero-sub {
  margin-top: 18px;
  font-size: clamp(15px, 2vw, 20px);
  color: rgba(255,255,255,.88);
  text-shadow: 0 1px 6px rgba(0,0,0,.5);
}

.hero-btns {
  margin-top: 36px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-trust {
  margin-top: 40px;
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-trust span {
  color: rgba(255,255,255,.8);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── Sections ── */
.section { padding: 90px 8%; }
.section-alt { background: var(--bg-alt); }
.section-dark {
  background: var(--nav-dark);
  color: #f0f0f0;
}

.section-title {
  font-size: clamp(22px, 3.5vw, 34px);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 12px;
}

.section-title::after {
  content: '';
  display: block;
  width: 52px;
  height: 3px;
  background: var(--red);
  margin-top: 10px;
}

.section-sub {
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 48px;
  max-width: 560px;
}

/* ── Cards ── */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 24px;
}

.card {
  background: var(--card-bg);
  border-top: 3px solid var(--red);
  padding: 30px 26px 36px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.card-icon {
  font-size: 38px;
  margin-bottom: 14px;
  line-height: 1;
}

.card h3 {
  font-size: 17px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 10px;
}

.card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
  flex: 1;
}

.card .card-link {
  margin-top: 20px;
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--red);
  text-decoration: none;
}
.card .card-link:hover { color: var(--red-dark); }

/* ── CTA Strip ── */
.cta-strip {
  background: var(--red);
  padding: 56px 8%;
  text-align: center;
  color: #fff;
}

.cta-strip h2 {
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 10px;
}

.cta-strip p {
  font-size: 16px;
  opacity: .88;
  margin-bottom: 28px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.cta-strip .cta-btns {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Humbaur Banner ── */
.humbaur-banner {
  margin-top: 56px;
  background: var(--nav-dark);
  padding: 36px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
  border-left: 4px solid var(--humbaur);
}

.humbaur-banner h3 {
  font-size: 20px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #fff;
  margin-bottom: 6px;
}

.humbaur-banner p {
  color: #aaa;
  font-size: 14px;
  max-width: 480px;
}

.humbaur-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* ── Anfahrt ── */
.anfahrt-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 56px;
  align-items: start;
}

.anfahrt-info { display: flex; flex-direction: column; gap: 26px; }

.info-block strong {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  color: var(--red);
  margin-bottom: 5px;
}

.info-block p { color: var(--text); font-size: 15px; line-height: 1.9; }

.info-block a {
  color: var(--text);
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s;
}
.info-block a:hover { color: var(--red); }

/* Google Maps DSGVO */
.map-area {
  width: 100%;
  height: 420px;
  position: relative;
  overflow: hidden;
  background: #ddd;
}

.map-consent {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e8e8e8;
  text-align: center;
  padding: 30px;
  flex-direction: column;
  gap: 14px;
}

.map-consent .consent-icon { font-size: 40px; }

.map-consent strong {
  font-size: 17px;
  display: block;
  margin-bottom: 4px;
}

.map-consent p {
  font-size: 13px;
  color: var(--muted);
  max-width: 340px;
  line-height: 1.6;
}

.map-consent .consent-hint {
  font-size: 12px;
  color: #999;
  margin-top: 4px;
}

.map-consent .consent-hint a { color: #999; font-size: 12px; }

.map-iframe-wrap {
  position: absolute;
  inset: 0;
  display: none;
}

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

/* ── Gallery ── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.gallery-item {
  height: 240px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.gallery-item:hover img { transform: scale(1.06); }

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.92);
  z-index: 999;
  align-items: center;
  justify-content: center;
}

.lightbox.open { display: flex; }

.lightbox img {
  max-width: 92vw;
  max-height: 92vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 22px;
  font-size: 44px;
  color: #fff;
  cursor: pointer;
  background: none;
  border: none;
  opacity: 0.75;
  line-height: 1;
  touch-action: manipulation;
}
.lightbox-close:hover { opacity: 1; }

/* ── Kontakt ── */
.kontakt-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 60px;
  align-items: start;
}

.kontakt-info { display: flex; flex-direction: column; gap: 22px; }

.kontakt-info .intro {
  font-size: 16px;
  line-height: 1.9;
  color: var(--muted);
}

.kontakt-links { display: flex; flex-direction: column; gap: 14px; }

.kontakt-link {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  transition: color 0.2s;
}
.kontakt-link:hover { color: var(--red); }

.kontakt-link .icon {
  width: 42px;
  height: 42px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

/* Form */
form {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

form input, form textarea {
  background: var(--card-bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 14px 16px;
  font-size: 16px; /* prevents iOS auto-zoom */
  font-family: inherit;
  width: 100%;
  outline: none;
  border-radius: var(--radius);
  transition: border-color 0.2s;
  appearance: none;
  -webkit-appearance: none;
}

form input:focus, form textarea:focus { border-color: var(--red); }

form textarea { height: 140px; resize: vertical; }

form button {
  padding: 15px;
  background: var(--red);
  color: #fff;
  border: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  cursor: pointer;
  border-radius: var(--radius);
  transition: background 0.2s;
  touch-action: manipulation;
}
form button:hover { background: var(--red-dark); }

/* ── Footer ── */
footer {
  background: #0d0d0d;
  border-top: 1px solid #222;
  padding: 32px 8%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 12px;
  color: #666;
}

footer a { color: #666; text-decoration: none; }
footer a:hover { color: #bbb; }

.footer-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-logo {
  height: 36px;
  width: auto;
  background: rgba(255,255,255,.9);
  padding: 3px 8px;
  border-radius: var(--radius);
}

.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }

.kontakt-logo {
  max-width: 200px;
  height: auto;
  margin-top: 16px;
}

.humbaur-banner-logo {
  height: 44px;
  width: auto;
  background: rgba(255,255,255,.12);
  padding: 5px 10px;
  border-radius: var(--radius);
  flex-shrink: 0;
}

/* ── Floating Call Button (mobile) ── */
.fab-call {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 150;
  background: var(--red);
  color: #fff;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  font-size: 24px;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(192,57,43,.45);
  touch-action: manipulation;
  border: 3px solid rgba(255,255,255,.2);
}

/* ── Media Queries ── */
@media (max-width: 1024px) {
  .nav-links { gap: 22px; }
  .anfahrt-grid { grid-template-columns: 1fr; }
  .map-area { height: 320px; }
  .kontakt-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  nav { padding: 0 5%; }

  .hamburger { display: block; }

  .nav-links {
    display: none;
    flex-direction: column;
    gap: 0;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: #111;
    border-top: 1px solid #222;
    border-bottom: 2px solid var(--red);
    align-items: stretch;
  }

  .nav-links.open { display: flex; }

  .nav-links li { border-bottom: 1px solid #222; }

  .nav-links a {
    display: block;
    padding: 17px 24px;
    font-size: 15px;
    letter-spacing: 0.8px;
  }

  .nav-links .nav-cta {
    background: var(--red);
    border-radius: 0;
    text-align: center;
    padding: 18px 24px;
  }

  .section { padding: 72px 5%; }

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

  .humbaur-banner { padding: 28px 24px; flex-direction: column; align-items: flex-start; }

  .cta-strip { padding: 48px 5%; }

  footer { flex-direction: column; align-items: flex-start; gap: 12px; }
  .footer-links { flex-direction: column; gap: 10px; }

  .fab-call { display: flex; }
}

@media (max-width: 480px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .hero-btns { flex-direction: column; align-items: stretch; }
  .hero-btns .btn-primary,
  .hero-btns .btn-outline { text-align: center; }
  .hero-trust { gap: 14px; }
  .hero-inner h1 {
    font-size: clamp(26px, 8vw, 38px);
    letter-spacing: 1px;
  }
}
