/* Schriften lokal eingebunden (keine Verbindung zu Google, DSGVO) */
@font-face { font-family: "Inter"; src: url("../assets/fonts/Inter-Regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../assets/fonts/Inter-SemiBold.woff") format("woff"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../assets/fonts/InterDisplay-ExtraBoldItalic.woff") format("woff"); font-weight: 800; font-style: italic; font-display: swap; }

:root {
  --navy: #0F1B3D;
  --navy-2: #16254F;
  --navy-3: #1D2E5E;
  --line: #2B3C70;
  --text: #F3F5FA;
  --muted: #A6B1CF;
  --red: #E63B2E;
  --red-dark: #C42D21;
  --radius: 6px;
  --wrap: 1180px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--navy);
  color: var(--text);
  font: 400 17px/1.55 "Inter", system-ui, sans-serif;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }

.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }

/* Überschriften im Stil des Logos: schräg und kräftig */
h1, h2, h3, .display {
  font-family: "Inter Display", "Inter", sans-serif;
  font-weight: 800;
  font-style: italic;
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.3rem, 5.6vw, 4.4rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; max-width: 64ch; }
.muted { color: var(--muted); }

/* Kopfzeile */
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.site-header .logo img { height: 50px; width: auto; }
.site-nav { margin-left: auto; display: flex; gap: 4px; align-items: center; }
.site-nav a { text-decoration: none; padding: 8px 12px; border-radius: var(--radius); font-weight: 600; }
.site-nav a:hover { background: var(--navy-2); }
.site-nav a[aria-current="page"] { color: var(--red); }
.site-nav .tel { margin-left: 8px; }

/* Knöpfe: rot und schräg wie die Schrift im Logo */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 1rem/1 "Inter", sans-serif;
  padding: 14px 22px;
  border: 0; border-radius: var(--radius);
  background: var(--red); color: #fff; text-decoration: none; cursor: pointer; white-space: nowrap;
  transform: skewX(-8deg);
}
.btn > * , .btn span { transform: skewX(8deg); display: inline-block; }
.btn:hover { background: var(--red-dark); }
.btn.ghost { background: transparent; box-shadow: inset 0 0 0 2px var(--line); }
.btn.ghost:hover { box-shadow: inset 0 0 0 2px var(--text); }
.btn.small { padding: 10px 16px; font-size: .95rem; }

/* Startseite */
.hero { padding: clamp(48px, 9vw, 110px) 0 56px; }
.hero h1 { max-width: 15ch; }
.hero .lead { font-size: 1.2rem; color: var(--muted); max-width: 46ch; }

.finder {
  margin-top: 36px; padding: 22px;
  background: var(--navy-2); border: 1px solid var(--line); border-radius: 10px;
  display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 12px; align-items: end;
  max-width: 900px;
}
.finder label { display: block; font-size: .9rem; color: var(--muted); margin-bottom: 6px; }

input, select, textarea {
  width: 100%;
  font: inherit; color: var(--text);
  background: var(--navy); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 12px 14px;
}
input::placeholder, textarea::placeholder { color: #7482A8; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
input:focus, select:focus, textarea:focus { border-color: var(--muted); outline: none; }

.contact-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; align-items: center; }
.contact-row .or { color: var(--muted); }

.facts { border-top: 1px solid var(--line); padding: 44px 0 64px; }
.facts .wrap { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.facts h2 { font-size: 1.35rem; color: var(--red); margin-bottom: .6em; }
.facts dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 4px 18px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; font-variant-numeric: tabular-nums; }
.facts p { margin-bottom: .5em; }

.brands { padding: 0 0 80px; }
.brand-list { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; padding: 0; list-style: none; }
.brand-list a { display: block; padding: 10px 16px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 600; }
.brand-list a:hover { border-color: var(--text); }
.brand-list .count { color: var(--muted); font-weight: 400; margin-left: 6px; }

/* Autoteile-Seite */
.page-head { padding: 48px 0 24px; }
.page-head p { color: var(--muted); }
.filters {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr; gap: 10px;
  padding: 16px; background: var(--navy-2); border: 1px solid var(--line); border-radius: 10px;
}
.filters label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.result-bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin: 22px 0 14px; color: var(--muted); flex-wrap: wrap; }
.result-bar button { background: none; border: 0; color: var(--text); text-decoration: underline; font: inherit; cursor: pointer; padding: 0; }
.notice { border-left: 3px solid var(--red); padding: 10px 14px; background: var(--navy-2); margin: 16px 0 0; color: var(--muted); font-size: .95rem; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; padding: 0; margin: 0; list-style: none; }
.part {
  display: flex; flex-direction: column; width: 100%; height: 100%;
  background: var(--navy-2); border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
  text-align: left; color: inherit; font: inherit; padding: 0; cursor: pointer;
}
.part:hover { border-color: var(--muted); }
.part .img { aspect-ratio: 4 / 3; background: var(--navy-3); display: grid; place-items: center; }
.part .img img { width: 100%; height: 100%; object-fit: cover; }
.part .img .ph { width: 46%; opacity: .35; }
.part .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.part .title { font-weight: 600; line-height: 1.3; }
.part .meta { color: var(--muted); font-size: .9rem; }
.part .price { margin-top: auto; padding-top: 6px; font-family: "Inter Display", sans-serif; font-style: italic; font-weight: 800; font-size: 1.3rem; }
.price .vb { font-family: "Inter", sans-serif; font-style: normal; font-weight: 400; font-size: .9rem; color: var(--muted); margin-left: 6px; }

.more { display: flex; justify-content: center; margin: 32px 0 80px; }
.empty { padding: 40px 0 80px; }

/* Detailansicht */
dialog {
  width: min(920px, 100% - 24px); max-height: calc(100vh - 24px);
  padding: 0; border: 1px solid var(--line); border-radius: 10px;
  background: var(--navy); color: var(--text);
}
dialog::backdrop { background: rgba(5, 10, 25, .75); }
.detail { display: grid; grid-template-columns: 1.1fr 1fr; }
.detail .gallery { background: var(--navy-3); }
.detail .gallery .main { aspect-ratio: 4 / 3; display: grid; place-items: center; }
.detail .gallery .main img { width: 100%; height: 100%; object-fit: contain; }
.detail .gallery .main .ph { width: 40%; opacity: .35; }
.thumbs { display: flex; gap: 6px; padding: 8px; overflow-x: auto; }
.thumbs button { flex: 0 0 64px; height: 48px; padding: 0; border: 2px solid transparent; border-radius: 4px; overflow: hidden; cursor: pointer; background: none; }
.thumbs button[aria-current="true"] { border-color: var(--red); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
.detail .info { padding: 26px; display: flex; flex-direction: column; gap: 12px; }
.detail .info h2 { font-size: 1.6rem; margin: 0; padding-right: 36px; }
.detail .price { font-family: "Inter Display", sans-serif; font-style: italic; font-weight: 800; font-size: 1.8rem; }
.detail .desc { white-space: pre-line; color: var(--muted); }
.detail .actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; }
.detail .ref { font-size: .85rem; color: var(--muted); }
.close { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--navy-2); color: var(--text); font-size: 1.5rem; line-height: 1; cursor: pointer; }

/* Kontakt */
.contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: 56px; padding-bottom: 80px; }
.contact .block { margin-bottom: 30px; }
.contact .block h2 { font-size: 1.35rem; color: var(--red); }
.big-tel { font-family: "Inter Display", sans-serif; font-style: italic; font-weight: 800; font-size: clamp(1.8rem, 4vw, 2.4rem); text-decoration: none; display: inline-block; margin-bottom: 12px; }
form .field { margin-bottom: 16px; }
form label { display: block; margin-bottom: 6px; font-weight: 600; }
form .hint { font-size: .9rem; color: var(--muted); }
.hidden { display: none; }

/* Rechtstexte */
.legal { padding: 48px 0 80px; }
.legal h2 { font-size: 1.4rem; margin-top: 1.6em; }
.legal h3 { font-family: "Inter", sans-serif; font-style: normal; font-weight: 600; font-size: 1.05rem; margin-top: 1.4em; }
.legal address { font-style: normal; margin-bottom: 1em; }
.todo { background: var(--red); color: #fff; padding: 0 6px; border-radius: 3px; }

/* Fußzeile */
.site-footer { border-top: 1px solid var(--line); padding: 32px 0 40px; color: var(--muted); font-size: .95rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: space-between; }
.site-footer nav { display: flex; gap: 20px; }

/* Mobil */
@media (max-width: 860px) {
  .finder { grid-template-columns: 1fr; }
  .facts .wrap { grid-template-columns: 1fr; gap: 32px; }
  .filters { grid-template-columns: 1fr 1fr; }
  .filters .search { grid-column: 1 / -1; }
  .detail { grid-template-columns: 1fr; }
  .contact { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .site-header .wrap { flex-wrap: wrap; gap: 8px 16px; padding: 12px 0; }
  .site-header .logo img { height: 36px; }
  .site-nav { margin-left: 0; width: 100%; justify-content: space-between; }
  .site-nav .tel { margin-left: 0; }
  .site-nav a { padding: 8px 6px; }
  .site-nav .tel { padding: 10px 12px; font-size: .9rem; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
