/* ============================================================
   COMPONENTS.CSS – Automatic Solutions
   Navigation, Buttons, Cards, Footer, Formulare
   ============================================================ */

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(15, 13, 8, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav__logo {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.nav__logo span {
  color: var(--color-accent);
}

.nav__logo:hover {
  color: var(--color-text);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav__links a {
  color: var(--color-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
  text-decoration: none;
}

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

/* Dropdown */
.nav__item--dropdown {
  position: relative;
}

.nav__dropdown-toggle {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav__dropdown-toggle svg {
  transition: transform 0.2s;
}

.nav__dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-xs);
  padding-top: calc(var(--space-xs) + 8px);
  min-width: 200px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* Unsichtbare Bruecke zwischen Link und Dropdown */
.nav__dropdown::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
}

.nav__item--dropdown:hover .nav__dropdown {
  display: block;
}

.nav__item--dropdown:hover .nav__dropdown-toggle svg {
  transform: rotate(180deg);
}

.nav__dropdown li a {
  display: block;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}

.nav__dropdown li a:hover {
  background: var(--color-surface);
  color: var(--color-accent);
}

.nav__cta {
  display: flex;
}

/* Hamburger */
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

.nav__burger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__burger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav__burger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu */
.nav__mobile {
  display: none;
  flex-direction: column;
  padding: var(--space-md) var(--space-lg) var(--space-lg);
  border-top: 1px solid var(--color-border);
  background: rgba(15, 13, 8, 0.95);
}

.nav__mobile.is-open {
  display: flex;
}

.nav__mobile a {
  padding: var(--space-sm) 0;
  color: var(--color-muted);
  font-size: 0.95rem;
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
}

.nav__mobile a:hover {
  color: var(--color-accent);
}

@media (max-width: 768px) {
  .nav__links,
  .nav__cta {
    display: none;
  }

  .nav__burger {
    display: flex;
  }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  border-radius: var(--radius-md);
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  line-height: 1.4;
  white-space: nowrap;
}

.btn--primary {
  background: var(--color-accent);
  color: #1a160a;
  border-color: var(--color-accent);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  color: #1a160a;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px var(--color-accent-glow);
}

.btn--ghost {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border);
}

.btn--ghost:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.btn--lg {
  padding: 0.85rem 2rem;
  font-size: 1rem;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  transition: border-color 0.2s, transform 0.2s;
}

.card:hover {
  border-color: rgba(245, 158, 11, 0.3);
  transform: translateY(-2px);
}

.card--featured {
  border-color: var(--color-accent);
}

.card__icon {
  margin-bottom: var(--space-md);
}

.card__title {
  font-size: 1.15rem;
  margin-bottom: var(--space-xs);
}

.card__text {
  font-size: 0.9rem;
  color: var(--color-muted);
}

/* ============================================================
   HERO (Startseite)
   ============================================================ */
.hero {
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero__content {
  position: relative;
  z-index: 1;
}

.hero__title {
  margin-bottom: var(--space-lg);
}

.hero__text {
  font-size: 1.1rem;
  max-width: 600px;
  margin-inline: auto;
  margin-bottom: var(--space-xl);
}

.hero__actions {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
}

.hero__trust {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
  font-size: 0.8rem;
  color: var(--color-muted);
  flex-wrap: wrap;
}

.hero__trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-muted);
  text-decoration: none;
}

.hero__trust-badge:hover {
  color: var(--color-accent);
}

.hero__trust-badge svg {
  color: var(--color-accent);
}

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

.hero__trust-item {
  color: var(--color-muted);
}

.hero__glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--color-accent-glow) 0%, transparent 70%);
  pointer-events: none;
  opacity: 0.5;
}

/* ============================================================
   LEISTUNGEN-GRID (Startseite)
   ============================================================ */
.leistungen__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}

@media (max-width: 768px) {
  .leistungen__grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   WARUM-GRID (Startseite – "Warum Praxen auf uns setzen")
   ============================================================ */
.warum__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl);
}

.warum__item {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.warum__number {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

.warum__title {
  font-size: 1.1rem;
  font-weight: 600;
}

@media (max-width: 768px) {
  .warum__grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
}

/* ============================================================
   CTA-BAND (Startseite)
   ============================================================ */
.cta-band__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
}

.cta-band__title {
  margin-bottom: var(--space-xs);
}

.cta-band__text {
  color: var(--color-muted);
  margin-bottom: 0;
}

@media (max-width: 768px) {
  .cta-band__inner {
    flex-direction: column;
    text-align: center;
  }
}

/* ============================================================
   FORMULARE
   ============================================================ */
.form__group {
  margin-bottom: var(--space-lg);
}

.form__label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-xs);
}

.form__input,
.form__select,
.form__textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form__input:focus,
.form__select:focus,
.form__textarea:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-glow);
}

.form__input::placeholder,
.form__textarea::placeholder {
  color: var(--color-muted);
  opacity: 0.6;
}

.form__select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%238a8070' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

.form__textarea {
  resize: vertical;
  min-height: 120px;
}

.form__group--checkbox {
  margin-bottom: var(--space-lg);
}

.form__checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--color-muted);
  line-height: 1.5;
}

.form__checkbox {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.form__checkbox-custom {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border: 2px solid var(--color-border);
  border-radius: 4px;
  background: var(--color-surface);
  transition: all 0.2s;
  position: relative;
  margin-top: 1px;
}

.form__checkbox:checked + .form__checkbox-custom {
  background: var(--color-accent);
  border-color: var(--color-accent);
}

.form__checkbox:checked + .form__checkbox-custom::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 6px;
  height: 10px;
  border: solid #1a160a;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.form__checkbox:focus + .form__checkbox-custom {
  box-shadow: 0 0 0 3px var(--color-accent-glow);
}

.form__submit {
  width: 100%;
}

.form__success {
  margin-top: var(--space-md);
  padding: var(--space-md);
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: var(--radius-md);
  color: #22c55e;
  font-size: 0.9rem;
}

.form__error {
  margin-top: var(--space-md);
  padding: var(--space-md);
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  color: #ef4444;
  font-size: 0.9rem;
}

/* ============================================================
   VERTRAUEN-LEISTE (Kontakt-Seite & Praxis-Check)
   ============================================================ */
.vertrauen__grid {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  flex-wrap: wrap;
}

.vertrauen__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  font-size: 0.9rem;
}

.vertrauen__item strong {
  font-size: 1.2rem;
}

.vertrauen__item span {
  color: var(--color-muted);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  padding: var(--space-2xl) 0 var(--space-lg);
  border-top: 1px solid var(--color-border);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer__brand p {
  font-size: 0.85rem;
  margin-top: var(--space-sm);
  max-width: 320px;
}

.footer__logo {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-text);
}

.footer__logo span {
  color: var(--color-accent);
}

.footer__col h4 {
  margin-bottom: var(--space-md);
  color: var(--color-text);
}

.footer__col ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.footer__col a {
  color: var(--color-muted);
  font-size: 0.85rem;
  text-decoration: none;
}

.footer__col a:hover {
  color: var(--color-accent);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
  font-size: 0.8rem;
  color: var(--color-muted);
}

.footer__bottom p {
  color: var(--color-muted);
  font-size: 0.8rem;
}

.footer__legal {
  display: flex;
  gap: var(--space-md);
}

.footer__legal a {
  color: var(--color-muted);
  font-size: 0.8rem;
  text-decoration: none;
}

.footer__legal a:hover {
  color: var(--color-accent);
}

@media (max-width: 768px) {
  .footer__grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .footer__bottom {
    flex-direction: column;
    gap: var(--space-sm);
    text-align: center;
  }
}
