/* ============================================
   Müller Elektrotechnik — Demo by Das Werk
   Clean, light, professional Handwerk website
   ============================================ */

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

:root {
  --accent: #2563EB;
  --accent-hover: #1D4ED8;
  --accent-light: rgba(37, 99, 235, 0.08);
  --white: #ffffff;
  --bg: #ffffff;
  --bg-muted: #FAFAFA;
  --text: #1a1a1a;
  --text-secondary: #555555;
  --text-muted: #888888;
  --border: #E5E5E5;
  --border-light: #F0F0F0;
  --red: #DC2626;
  --green: #16A34A;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.08);
  --radius: 6px;
  --radius-sm: 4px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.25;
  color: var(--text);
}

a {
  text-decoration: none;
  color: inherit;
}

img { max-width: 100%; display: block; }
ul { list-style: none; }

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

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 14px 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, padding 0.2s;
}

.nav.scrolled {
  border-bottom-color: var(--border);
  padding: 10px 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
}

.nav-logo-mark {
  width: 32px;
  height: 32px;
  background: var(--accent);
  color: white;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

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

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.15s;
}

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

.nav-cta {
  background: var(--accent) !important;
  color: white !important;
  padding: 8px 18px;
  border-radius: var(--radius);
  font-weight: 600 !important;
  transition: background 0.15s !important;
}

.nav-cta:hover {
  background: var(--accent-hover) !important;
}

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

.nav-mobile-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
  transition: all 0.2s;
}

/* --- Hero --- */
.hero {
  padding: 140px 0 80px;
  background: var(--bg);
}

.hero-content {
  max-width: 620px;
}

.hero-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 12px;
  letter-spacing: 0.01em;
}

.hero h1 {
  font-size: clamp(2.2rem, 4.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  color: var(--text);
}

.hero-tagline {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: white;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--text);
  padding: 12px 24px;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 500;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: border-color 0.15s;
  font-family: inherit;
}

.btn-secondary:hover {
  border-color: var(--text-muted);
}

.hero-trust {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.hero-trust-sep {
  color: var(--border);
}

/* --- Section Shared --- */
.section {
  padding: 80px 0;
}

.section-muted {
  background: var(--bg-muted);
}

.section-header {
  max-width: 560px;
  margin-bottom: 48px;
}

.section-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.section-header p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- Services --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border-light);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  overflow: hidden;
}

.service-card {
  background: var(--white);
  padding: 32px 28px;
  transition: background 0.15s;
}

.service-card:hover {
  background: var(--bg-muted);
}

.service-icon {
  width: 44px;
  height: 44px;
  background: var(--accent-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--accent);
}

.service-card h3 {
  font-size: 1rem;
  margin-bottom: 8px;
  font-weight: 600;
}

.service-card p {
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.6;
}

/* --- About --- */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 64px;
  align-items: start;
}

.about-content h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.about-intro {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 28px;
  line-height: 1.7;
}

.about-values {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.about-value {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.about-value-icon {
  flex-shrink: 0;
  color: var(--accent);
  margin-top: 2px;
}

.about-value strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 2px;
}

.about-value span {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border-light);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  overflow: hidden;
}

.about-stat {
  background: var(--white);
  padding: 28px 24px;
  text-align: center;
}

.about-stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 4px;
}

.about-stat-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* --- Booking --- */
.booking-wrapper {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 48px;
  align-items: start;
}

.booking-form-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  position: relative;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.form-group label .required {
  color: var(--red);
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-family: inherit;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.15s;
  outline: none;
}

.form-group input::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.form-group input.error,
.form-group select.error {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.08);
}

.form-group .error-message {
  display: none;
  color: var(--red);
  font-size: 0.75rem;
  margin-top: 4px;
  font-weight: 500;
}

.form-group input.error + .error-message,
.form-group select.error + .error-message {
  display: block;
}

.time-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.time-slot {
  padding: 10px 8px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  background: var(--white);
}

.time-slot:hover {
  border-color: var(--accent);
}

.time-slot.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.time-slot-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
}

.time-slot-range {
  display: block;
  font-size: 0.6875rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.time-slot.active .time-slot-range {
  color: rgba(255, 255, 255, 0.75);
}

.btn-submit {
  width: 100%;
  padding: 12px;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
  margin-top: 4px;
}

.btn-submit:hover {
  background: var(--accent-hover);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.booking-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-top: 8px;
}

.booking-benefit {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.booking-benefit svg {
  flex-shrink: 0;
  color: var(--accent);
  margin-top: 2px;
}

.booking-benefit strong {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 2px;
}

.booking-benefit span {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Booking success */
.booking-success {
  position: absolute;
  inset: 0;
  background: var(--white);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s, visibility 0.25s;
  z-index: 10;
}

.booking-success.show {
  opacity: 1;
  visibility: visible;
}

.success-checkmark {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
}

.success-circle {
  fill: none;
  stroke: var(--green);
  stroke-width: 3;
  transform-origin: center;
}

.success-check {
  fill: none;
  stroke: var(--green);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
}

.booking-success.show .success-check {
  animation: checkmark-draw 0.4s 0.2s ease forwards;
}

@keyframes checkmark-draw {
  to { stroke-dashoffset: 0; }
}

.booking-success h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.booking-success p {
  color: var(--text-secondary);
  font-size: 0.9375rem;
  max-width: 300px;
}

.booking-success .success-note {
  margin-top: 20px;
  padding: 10px 16px;
  background: var(--bg-muted);
  border-radius: var(--radius);
  color: var(--text-secondary);
  font-size: 0.8125rem;
}

/* --- Reviews --- */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

.review-card {
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 28px;
}

.review-stars {
  color: #F59E0B;
  font-size: 0.875rem;
  margin-bottom: 12px;
  letter-spacing: 2px;
}

.review-text {
  color: var(--text);
  font-size: 0.875rem;
  line-height: 1.65;
  margin-bottom: 16px;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.review-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.75rem;
}

.review-author-name {
  display: block;
  font-weight: 600;
  font-size: 0.8125rem;
}

.review-author-detail {
  display: block;
  color: var(--text-muted);
  font-size: 0.75rem;
}

.reviews-summary {
  text-align: center;
}

.reviews-summary-inner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.reviews-summary-inner strong {
  font-size: 1.25rem;
  color: var(--text);
}

.reviews-summary-stars {
  color: #F59E0B;
  letter-spacing: 1px;
}

.reviews-summary-count {
  color: var(--text-muted);
}

/* --- Contact --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact-items {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.contact-item-content h4 {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.contact-item-content p {
  color: var(--text);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.contact-item-content a {
  color: var(--accent);
  font-weight: 500;
  transition: color 0.15s;
}

.contact-item-content a:hover {
  color: var(--accent-hover);
}

.emergency-banner {
  background: var(--red);
  padding: 24px 28px;
  border-radius: var(--radius);
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.emergency-banner strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 2px;
}

.emergency-banner span {
  font-size: 0.875rem;
  opacity: 0.9;
}

.emergency-phone {
  color: white;
  font-size: 1.25rem;
  font-weight: 700;
  white-space: nowrap;
  transition: opacity 0.15s;
}

.emergency-phone:hover {
  opacity: 0.85;
}

/* --- Footer --- */
.footer {
  background: #111111;
  padding: 56px 0 0;
  color: rgba(255, 255, 255, 0.5);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand p {
  font-size: 0.8125rem;
  line-height: 1.6;
  margin-top: 12px;
  max-width: 260px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-weight: 600;
  font-size: 0.9375rem;
}

.footer h4 {
  color: white;
  font-size: 0.8125rem;
  margin-bottom: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.footer ul li {
  margin-bottom: 8px;
}

.footer ul li a {
  font-size: 0.8125rem;
  transition: color 0.15s;
}

.footer ul li a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.15s;
}

.footer-bottom a:hover {
  color: white;
}

/* --- Das Werk Badge --- */
.daswerk-badge {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 999;
  background: white;
  color: var(--text-secondary);
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: 0.6875rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-md);
  transition: box-shadow 0.15s;
  border: 1px solid var(--border-light);
  text-decoration: none;
}

.daswerk-badge:hover {
  box-shadow: var(--shadow-sm), 0 4px 12px rgba(0,0,0,0.1);
}

.daswerk-badge-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
}

.daswerk-badge span {
  opacity: 0.6;
}

.daswerk-badge strong {
  color: var(--text);
  font-weight: 600;
}

/* --- Mobile --- */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .booking-wrapper {
    grid-template-columns: 1fr;
  }

  .booking-sidebar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }

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

@media (max-width: 768px) {
  .section {
    padding: 56px 0;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    flex-direction: column;
    justify-content: center;
    gap: 20px;
    padding: 40px;
    transition: right 0.25s;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
    border-left: 1px solid var(--border);
  }

  .nav-links.open {
    right: 0;
  }

  .nav-links a {
    font-size: 1rem;
    color: var(--text);
  }

  .nav-mobile-toggle {
    display: flex;
    z-index: 1001;
  }

  .nav-mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

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

  .nav-mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .mobile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 998;
  }

  .mobile-overlay.show {
    display: block;
  }

  .hero {
    padding: 100px 0 56px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-trust {
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
  }

  .hero-trust-sep {
    display: none;
  }

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

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

  .form-row {
    grid-template-columns: 1fr;
  }

  .time-slots {
    grid-template-columns: 1fr;
  }

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

  .contact-items {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .emergency-banner {
    flex-direction: column;
    text-align: center;
  }

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

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .booking-sidebar {
    grid-template-columns: 1fr;
  }

  .booking-form-card {
    padding: 24px;
  }

  .daswerk-badge {
    bottom: 12px;
    right: 12px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero h1 {
    font-size: 1.875rem;
  }

  .section-header h2 {
    font-size: 1.375rem;
  }

  .about-stats {
    grid-template-columns: 1fr 1fr;
  }

  .about-stat {
    padding: 20px 16px;
  }

  .about-stat-number {
    font-size: 1.5rem;
  }
}
