/* ==========================================================================
   Mereuta Sanierung – Stylesheet
   Aus dem HTML-Prototyp (index.html / impressum.html) übernommen.
   Abweichungen der Rechtsseiten sind unter .legal-page gebündelt.
   ========================================================================== */

/* Inter (Variable Font, latin) – lokal ausgeliefert, SIL OFL 1.1, siehe fonts/LICENSE-Inter.txt */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2-variations");
  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;
}

:root {
  --navy: #12304A;
  --teal: #20B8B0;
  --pale: #F3F6F8;
  --ink: #183247;
  --muted: #657987;
  --white: #fff;
  --line: #dce6eb;
  --shadow: 0 18px 50px #12304a14;
  --wrap-max: 1140px;
}

/* ---------- Basis ---------- */

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font: 16px/1.6 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: #fff;
}

a { color: inherit; }

/* Telefonnummern nie mitten in der Nummer umbrechen */
a[href^="tel:"] { white-space: nowrap; }

.wrap {
  width: min(var(--wrap-max), calc(100% - 40px));
  margin: auto;
}

.eyebrow {
  color: #098d88;
  font-size: .78rem;
  letter-spacing: .14em;
  font-weight: 800;
  text-transform: uppercase;
}

/* ---------- Header ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--navy);
  font-weight: 800;
  line-height: 1.15;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-top: 5px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  object-fit: contain;
  flex: none;
  border-radius: 10px;
}

.navlinks {
  display: flex;
  align-items: center;
  gap: 28px;
}

.navlinks a {
  text-decoration: none;
  font-weight: 650;
  font-size: .94rem;
}

/* ---------- Buttons ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--teal);
  color: var(--navy);
  font-weight: 800;
  text-decoration: none;
  padding: 13px 20px;
  border-radius: 8px;
  border: 0;
  transition: .2s;
}

.button:hover {
  background: #35cbc3;
  transform: translateY(-1px);
}

button.button {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  cursor: pointer;
}

.secondary {
  padding: 12px 20px;
  text-decoration: none;
  color: var(--navy);
  font-weight: 750;
  border: 1px solid #c9d8df;
  border-radius: 8px;
}

/* ---------- Hero ---------- */

.hero {
  background: var(--pale);
  overflow: hidden;
  position: relative;
}

.hero .wrap {
  display: grid;
  grid-template-columns: 1.12fr .88fr;
  gap: 50px;
  align-items: center;
  padding: 78px 0 84px;
}

.hero h1 {
  font-size: clamp(2.6rem, 5.4vw, 4.6rem);
  letter-spacing: -.055em;
  line-height: 1.03;
  color: var(--navy);
  margin: 15px 0 22px;
}

.hero p {
  font-size: 1.13rem;
  max-width: 590px;
  color: #526a79;
}

.hero-actions {
  display: flex;
  gap: 13px;
  align-items: center;
  margin-top: 28px;
  flex-wrap: wrap;
}

.hero-media { min-width: 0; }

.image-note {
  font-size: .78rem;
  line-height: 1.45;
  color: var(--muted);
  margin: 10px 0 18px;
}

.visual {
  height: auto;
  aspect-ratio: 3 / 2;
  position: relative;
  border-radius: 22px;
  background: #12304A;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.visual:after {
  content: "";
  position: absolute;
  inset: 48% 0 0;
  background: linear-gradient(transparent, rgba(18, 48, 74, .86));
}

.hero-photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.visual-label {
  position: absolute;
  z-index: 2;
  bottom: 24px;
  left: 24px;
  right: 18px;
  color: #fff;
  font-weight: 750;
  letter-spacing: .02em;
}

.visual-label span {
  display: block;
  font-size: .82rem;
  color: #e0edf1;
  font-weight: 500;
  margin-top: 4px;
}

/* ---------- Trust-Leiste ---------- */

.trust {
  position: relative;
  margin-top: -25px;
}

.trust .wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #fff;
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 23px 28px;
  gap: 20px;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 750;
  color: var(--navy);
}

.check {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #e2f8f6;
  color: #087f7b;
  font-weight: 900;
  flex: none;
}

/* ---------- Sektionen ---------- */

.section { padding: 88px 0; }

.section-head {
  max-width: 680px;
  margin-bottom: 40px;
}

.section h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
  color: var(--navy);
  letter-spacing: -.04em;
  margin: 10px 0 16px;
}

.section-head p {
  color: var(--muted);
  margin: 0;
}

.scope {
  font-size: .87rem;
  color: #c4d5dc;
  border-top: 1px solid #ffffff25;
  padding-top: 20px;
  margin-top: 34px;
}

/* ---------- Leistungen ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  transition: .2s;
}

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

.service-photo {
  display: block;
  width: calc(100% + 56px);
  height: 190px;
  object-fit: cover;
  margin: -28px -28px 0;
  border-radius: 14px 14px 0 0;
}

.card .image-note { margin: 10px 0 22px; }

.card-top {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 16px;
}

.icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #e4f7f6;
  color: #087f7b;
  font-size: 1.35rem;
}

.card h3 {
  margin: 0;
  color: var(--navy);
  font-size: 1.28rem;
}

.card p {
  margin: 12px 0;
  color: var(--muted);
}

.card ul {
  list-style: none;
  margin: 15px 0 0;
  padding: 0;
}

.card li {
  position: relative;
  padding: 7px 0 7px 22px;
  color: #425b69;
}

.card li:before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
}

.notice {
  margin-top: 18px;
  padding: 15px 18px;
  background: #fff8e7;
  border-left: 4px solid #e8b649;
  border-radius: 5px;
  color: #674e1b;
  font-size: .93rem;
}

/* ---------- Über den Betrieb ---------- */

.about { background: var(--pale); }

.about-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 60px;
  align-items: center;
}

.about-box {
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 16px;
  padding: 34px;
  color: #fff;
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.about-logo {
  display: block;
  width: min(100%, 280px);
  height: auto;
  align-self: flex-start;
  border-radius: 8px;
}

.about-text p { color: var(--muted); }

/* ---------- Kontakt ---------- */

.contact {
  background: var(--navy);
  color: #fff;
}

.contact .section-head h2 { color: #fff; }

.contact .section-head p { color: #c4d5dc; }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.contact-card {
  border: 1px solid #ffffff2b;
  background: #ffffff0c;
  border-radius: 12px;
  padding: 24px;
}

.contact-card h3 { margin: 0 0 8px; }

.contact-card p {
  color: #c4d5dc;
  margin: 0 0 18px;
}

.contact-card a:not(.button) { color: #fff; }

.contact .button { margin-top: 5px; }

/* ---------- Kontaktformular (neu, im Stil der Kontaktkarten) ---------- */

.contact-form {
  margin-top: 24px;
  border: 1px solid #ffffff2b;
  background: #ffffff0c;
  border-radius: 12px;
  padding: 28px;
}

.contact-form h3 { margin: 0 0 8px; }

.contact-form > p {
  color: #c4d5dc;
  margin: 0 0 22px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 20px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.field-full { grid-column: 1 / -1; }

.field > label {
  font-weight: 700;
  font-size: .92rem;
}

.field input:not([type="checkbox"]),
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  color: #fff;
  background: #ffffff10;
  border: 1px solid #ffffff38;
  border-radius: 8px;
  padding: 12px 14px;
}

.field textarea {
  min-height: 150px;
  resize: vertical;
}

.field select option { color: var(--ink); }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}

.field input.invalid,
.field select.invalid,
.field textarea.invalid { border-color: #ffb4a8; }

.validation-message {
  color: #ffb4a8;
  font-size: .85rem;
}

.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: #c4d5dc;
  font-size: .92rem;
}

.consent input {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  flex: none;
  accent-color: var(--teal);
}

.consent a { color: #fff; }

.form-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 22px;
}

.form-hint {
  font-size: .82rem;
  color: #c4d5dc;
}

.form-status {
  padding: 14px 16px;
  border-radius: 8px;
  margin: 0 0 20px;
}

.form-status.success {
  background: #20b8b01f;
  border: 1px solid #20b8b066;
}

.form-status.error {
  background: #ff6b5a1f;
  border: 1px solid #ff6b5a66;
}

.form-status a { color: #fff; }

/* Honeypot: für Menschen unsichtbar, Bots füllen es aus */
.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- Footer ---------- */

.footer {
  background: #0b2437;
  color: #a8bdc8;
  padding: 22px 0;
  font-size: .84rem;
}

.footer .wrap {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer a {
  color: #d8e6eb;
  text-decoration: none;
}

.mobile-cta { display: none; }

/* ---------- Rechtsseiten (Impressum, Datenschutz, Fehlerseiten) ---------- */

body:has(.legal-page) { background: var(--pale); }

/* Footer bleibt auch bei kurzen Seiten (Impressum, 404) am unteren Rand */
.legal-page {
  --wrap-max: 1040px;
  line-height: 1.65;
  background: var(--pale);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.legal-main { flex: 1 0 auto; }

.legal-page .nav-link {
  font-weight: 700;
  text-decoration: none;
}

.legal-page .footer { font-size: .88rem; }

.legal-main { padding: 50px 0 90px; }

.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(26px, 5vw, 56px);
  box-shadow: var(--shadow);
  max-width: 760px;
}

.panel h1 {
  font-size: clamp(2.3rem, 5vw, 3.6rem);
  letter-spacing: -.05em;
  line-height: 1.05;
  color: var(--navy);
  margin: 10px 0 32px;
}

.panel h2 {
  font-size: 1.12rem;
  color: var(--navy);
  margin: 0 0 14px;
}

.details {
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.details p { margin: 0 0 18px; }

.details a { color: #087f7b; }

.privacy {
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.privacy section { margin: 26px 0; }

.privacy p { margin: 8px 0; }

.privacy a { color: #087f7b; }

.panel-actions { margin-top: 8px; }

/* ---------- Responsive ---------- */

@media (max-width: 800px) {
  .navlinks { gap: 15px; }
  .navlinks > a:not(.button) { display: none; }
  .hero .wrap { grid-template-columns: 1fr; gap: 35px; padding: 58px 0 70px; }
  .trust .wrap { grid-template-columns: 1fr; padding: 20px; }
  .about-grid { grid-template-columns: 1fr; gap: 28px; }
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .cards { gap: 12px; }
  .section { padding: 66px 0; }
}

@media (max-width: 560px) {
  .wrap { width: min(100% - 30px, var(--wrap-max)); }
  .nav { padding: 14px 0; }
  .navlinks .button { padding: 10px 13px; font-size: .83rem; }
  .hero h1 { font-size: 2.8rem; }
  .cards,
  .contact-grid,
  .form-grid { grid-template-columns: 1fr; }
  .card { padding: 22px; }
  .service-photo { width: calc(100% + 44px); margin: -22px -22px 20px; height: 165px; }
  .hero-actions > * { width: 100%; text-align: center; }
  .contact-form { padding: 22px; }
  .footer .wrap { display: block; }
  .footer .wrap > * { display: block; margin: 5px 0; }
  /* Footer-Links als ausreichend große Touch-Ziele (~44px hoch) */
  .footer a { display: inline-block; padding: 11px 0; }
  .mobile-cta { display: block; position: fixed; bottom: 12px; left: 15px; right: 15px; z-index: 5; box-shadow: 0 8px 28px #06172355; }
  .contact { padding-bottom: 100px; }
  /* Platz unter dem Footer, damit der fixierte Anruf-Button die Links nicht verdeckt (Button: 12px Abstand + 52px Höhe) */
  .footer:has(+ .mobile-cta) { padding-bottom: 86px; }

  .legal-page .brand small { font-size: .64rem; }
  .legal-main { padding: 34px 0 58px; }
}

/* Sehr schmale Handys: Anruf-Button bleibt einzeilig, damit er den Footer-Abstand nicht überschreitet */
@media (max-width: 360px) {
  .mobile-cta { font-size: .9rem; }
}
