.footer {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

.dondorf-info {
  padding: 18px 20px;
  background: var(--background-color);
  color: var(--text-color);
  text-align: left;
}

.footer-inner {
  margin: 0 auto;
  padding: 40px 20px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  max-width: 100%;
  overflow-x: hidden;
}

.footer-left {
  flex: 1;
  min-width: 200px;
  align-self: flex-start;
}

.footer-center {
  flex: 1;
  align-self: flex-start;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  margin-top: 0;
  color: var(--text-color);
  text-align: center;
}

/* Newsletter form in footer */
.newsletter-form {
  width: 100%;
  max-width: 400px;
}

.newsletter-form label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: var(--text-sm);
  font-weight: normal;
}

.newsletter-input-group {
  display: flex;
  gap: 0.5rem;
}

.newsletter-form input[type="email"] {
  flex: 1;
  padding: 0.6rem;
  border: 1px solid var(--text-color);
  background: var(--background-color);
  color: var(--text-color);
  font-family: inherit;
  font-size: var(--text-sm);
}

.newsletter-form button {
  padding: 0.6rem 1.2rem;
  background: var(--text-color);
  color: var(--background-color);
  border: 1px solid var(--text-color);
  cursor: pointer;
  font-family: inherit;
  font-size: var(--text-sm);
  transition: background 200ms, color 200ms;
  white-space: nowrap;
}

.newsletter-form button:hover {
  background: var(--background-color);
  color: var(--text-color);
}

.newsletter-success,
.newsletter-errors {
  padding: 1rem;
  margin-bottom: 1rem;
  font-size: var(--text-sm);
  text-align: center;
}

.newsletter-success {
  background: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

.newsletter-errors {
  background: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}


.footer-right {
  flex: 1;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  align-self: flex-start;
  gap: 0;
  max-width: 100%;
  overflow: hidden;
}

.imprint-container {
  position: relative;
  text-align: right;
}

.imprint-toggle,
.imprint-toggle::-webkit-details-marker,
details summary::-webkit-details-marker {
  display: none;
}

details summary {
  background: none;
  border: none;
  color: var(--text-color);
  cursor: pointer;
  text-decoration: underline;
  padding: 5px;
  font-size: 1.1rem;
  letter-spacing: -0.03rem;
  margin-bottom: 8px;
  list-style: none;
  position: relative;
  outline: none;
  display: inline-block;
  transition: color 0.2s;
}

details summary::marker,
details summary::-webkit-details-marker {
  display: none !important;
}

details summary:hover {
  color: var(--color-red);
}


details.imprint-content {
  position: static;
  background-color: var(--background-color);
  min-width: 220px;
  max-width: 100%;
  text-align: left;
  z-index: 10;
  overflow-wrap: break-word;
  word-break: break-word;
}

details.imprint-content[open] {
  padding: 18px 20px;
  border: 1px solid var(--text-color);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.07);
  margin-top: 8px;
  max-width: calc(100vw - 40px);
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 18px;
}

.footer-link {
  color: var(--text-color);
  text-decoration: none;
  font-size: 1.2rem;
  letter-spacing: normal;
  transition: color 0.2s;
  display: inline-block;
}

.footer-link:hover {
  color: var(--color-red);
  text-decoration: underline;
}

.cookies-link {
  color: var(--text-color);
  text-decoration: underline;
}

.cookies-link:visited,
.cookies-link:active {
  color: var(--text-color);
}


@media (max-width: 900px) {
  .footer-inner {
    flex-direction: column;
    gap: 20px;
    align-items: stretch;
  }

  .footer-right {
    align-items: flex-end;
  }
}

@media (max-width: 768px) {
  .footer-inner {
    padding: 32px 12px;
    flex-direction: column;
  }

  .footer-left {
    align-self: flex-start;
  }

  .footer-center {
    align-self: flex-end;
    text-align: right;
    justify-content: flex-end;
  }

  .footer-right {
    align-self: flex-end;
    align-items: flex-end;
  }
}