/* ============================================================
   AsTer Ingenieurbüro GbR – Hauptstylesheet
   ============================================================ */

/* === RESET & BASE ========================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: #333333;
  background: #e3e4b5;
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #6a98c9; }

/* === CSS-VARIABLEN ========================================= */
:root {
  --primary:      #6a98c9;
  --primary-dark: #1A3A6B;
  --bg:           #e3e4b5;
  --white:        #e3e4b5;
  --text:         #333333;
  --text-muted:   #555555;
  --footer-bg:    #e3e4b5;
  --shadow:       0 2px 12px rgba(111, 159, 210, 0.10);
  --radius:       8px;
  --max-width:    1100px;
}

/* === LAYOUT-HELPER ========================================= */
.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* === HEADER ================================================ */
header {
  background: var(--white);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.logo img { height: 52px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}
.nav-links a {
  color: var(--primary-dark);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--primary); }

.lang-switch {
  display: flex;
  gap: 0.2rem;
  margin-left: 0.5rem;
  align-items: center;
}
.lang-switch a {
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--text-muted);
  transition: background 0.2s, color 0.2s;
  letter-spacing: 0.03em;
}
.lang-switch a.active {
  background: var(--primary);
  color: white;
}
.lang-switch a:not(.active):hover {
  background: var(--bg);
  color: var(--primary-dark);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--primary-dark);
  border-radius: 2px;
  transition: 0.3s;
}

/* === HERO ================================================== */
.hero {
  position: relative;
  height: 520px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 60%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(26, 58, 107, 0.82) 0%,
    rgba(74, 144, 217, 0.55) 60%,
    rgba(74, 144, 217, 0.25) 100%
  );
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 2rem 1.5rem;
  color: white;
}
.hero-content h1 {
  font-size: clamp(1.6rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
  max-width: 680px;
  text-shadow: 0 1px 6px rgba(0,0,0,0.2);
}
.hero-content p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  max-width: 520px;
  opacity: 0.93;
  line-height: 1.55;
}
/* Slogan-Zeile (noch offen – Schritt 10.5) */
.hero-slogan {
  font-size: 1rem;
  font-style: italic;
  opacity: 0.80;
  margin-bottom: 2rem;
  margin-top: -0.75rem;
}

/* === BUTTONS =============================================== */
.btn-primary {
  display: inline-block;
  background: var(--primary);
  color: white;
  padding: 0.8rem 2rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover {
  background: #5a8fc2;
  transform: translateY(-2px);
  color: white;
}

/* === ALLGEMEINE SECTION ==================================== */
section { padding: 4rem 1.5rem; }
.section-title {
  font-size: 1.8rem;
  color: var(--primary-dark);
  margin-bottom: 0.5rem;
  font-weight: 700;
  line-height: 1.2;
}
.section-subtitle {
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  font-size: 1.05rem;
}

/* === SERVICE-KACHELN ======================================= */
.services-section { background: var(--bg); }
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(111, 159, 210, 0.18);
}
.service-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1rem;
  color: var(--primary);
}
.service-card h3 {
  font-size: 1.05rem;
  color: var(--primary-dark);
  margin-bottom: 0.7rem;
  font-weight: 600;
}
.service-card p {
  color: var(--text-muted);
  font-size: 0.93rem;
  line-height: 1.6;
}

/* === INTRO-SEKTION (Startseite) ============================ */
.intro-section { background: var(--white); }
.intro-section .section-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.intro-text h2 {
  font-size: 1.5rem;
  color: var(--primary-dark);
  margin-bottom: 1rem;
  font-weight: 700;
}
.intro-text p { color: var(--text-muted); margin-bottom: 1rem; }
.intro-text a.link { color: var(--primary); font-weight: 600; text-decoration: none; }
.intro-text a.link:hover { text-decoration: underline; }
.intro-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* === KONTAKT-LEISTE ======================================== */
.contact-strip { background: #6a98c9; color: white; padding: 3rem 1.5rem; }
.contact-strip .section-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
  justify-content: space-between;
}
.contact-text h2 { font-size: 1.4rem; margin-bottom: 0.25rem; }
.contact-text p { opacity: 0.82; font-size: 0.95rem; }
.contact-items { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.contact-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}
.contact-item svg { width: 20px; height: 20px; flex-shrink: 0; opacity: 0.85; }
.contact-item a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
}
.contact-item a:hover { text-decoration: underline; }

/* === FOOTER =============================================== */
footer {
  background: var(--footer-bg);
  padding: 1.25rem 1.5rem;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
}
footer p { color: #777; font-size: 0.875rem; }
.footer-links { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.footer-links a {
  color: #777;
  font-size: 0.875rem;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--primary); }

/* === PAGE-HERO (Unterseiten) =============================== */
.page-hero {
  background: #6a98c9;
  color: white;
  padding: 3.5rem 1.5rem;
}
.page-hero h1 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  max-width: var(--max-width);
  margin: 0 auto;
}
.page-hero p {
  max-width: var(--max-width);
  margin: 0.5rem auto 0;
  opacity: 0.85;
  font-size: 1.05rem;
}

/* === INHALTS-SEKTION (Unterseiten) ========================= */
.content-section { background: var(--white); }
.content-section .section-inner { max-width: 820px; }
.content-section h2 {
  font-size: 1.2rem;
  color: var(--primary-dark);
  margin: 2.5rem 0 0.75rem;
  font-weight: 700;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--bg);
}
.content-section h2:first-child { margin-top: 0; }
.content-section p,
.content-section li { color: var(--text-muted); margin-bottom: 0.65rem; line-height: 1.7; }
.content-section ul, .content-section ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.content-section address { font-style: normal; line-height: 2; }

/* === ÜBER UNS – ERFAHRUNGS-TIMELINE ======================= */
.timeline { list-style: none; padding: 0; margin: 1rem 0; }
.timeline li {
  position: relative;
  padding: 0.75rem 0 0.75rem 1.5rem;
  border-left: 3px solid var(--primary);
  margin-left: 0.5rem;
  margin-bottom: 0.5rem;
}
.timeline li::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 1.1rem;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--primary);
}
.timeline li strong { color: var(--primary-dark); display: block; margin-bottom: 0.2rem; }
.timeline li span { color: var(--text-muted); font-size: 0.93rem; }

/* === COMPETENCIES LIST ==================================== */
.competencies { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0.75rem; }
.competencies li {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text-muted);
  font-size: 0.93rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.competencies li::before { content: '✓'; color: var(--primary); font-weight: 700; flex-shrink: 0; }

/* === LEISTUNGS-DETAIL (Unterseite) ========================= */
.service-detail { background: var(--white); border-bottom: 1px solid var(--bg); }
.service-detail:nth-child(even) { background: var(--bg); }
.service-detail .section-inner {
  max-width: var(--max-width);
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1.5rem;
  align-items: start;
}
.service-detail-icon { color: var(--primary); margin-top: 0.2rem; }
.service-detail-icon svg { width: 44px; height: 44px; }
.service-detail h2 {
  font-size: 1.3rem;
  color: var(--primary-dark);
  margin-bottom: 0.75rem;
  font-weight: 700;
}
.service-detail p { color: var(--text-muted); line-height: 1.7; margin-bottom: 0.75rem; }

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

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.5rem 1.5rem;
    box-shadow: 0 6px 16px rgba(0,0,0,0.10);
    gap: 0.75rem;
    z-index: 99;
  }
  .nav-links.open { display: flex; }
  .header-inner { position: relative; flex-wrap: nowrap; }

  .hero { height: 400px; }
  .hero-content h1 { font-size: 1.5rem; }

  .intro-section .section-inner { grid-template-columns: 1fr; }
  .intro-img { height: 220px; }

  .contact-strip .section-inner { flex-direction: column; gap: 1.5rem; }

  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }

  .service-detail .section-inner { grid-template-columns: 1fr; }
  .service-detail-icon { display: none; }

  section { padding: 2.5rem 1.25rem; }
}

@media (max-width: 480px) {
  .hero { height: 360px; }
  .services-grid { grid-template-columns: 1fr; }
}
