.site-header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 18px;
}

.site-header .logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-header .logo a {
  display: inline-flex;
  align-items: center;
}

.site-header .logo img {
  height: clamp(76px, 7vw, 100px);
  width: auto;
  display: block;
}

.site-header .site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  row-gap: 8px;
  min-width: 0;
  margin-left: auto;
}

.site-header .site-nav a.nav-instagram {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-width: 44px;
  padding: 0;
}

.site-header .site-nav a.nav-instagram img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

@media (max-width: 1280px) and (min-width: 1101px) {
  header {
    padding: 16px 20px !important;
  }

  .site-header {
    gap: 14px;
  }

  .site-header .site-nav {
    gap: 8px;
  }
}

footer {
  text-align: center;
}

footer p + p {
  margin-top: 10px;
}

.socials {
  margin-top: 18px;
  display: flex;
  justify-content: center;
}

.instagram-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.instagram-link img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.footer-admin-link {
  margin-top: 16px;
}

.footer-admin-link a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted) !important;
  text-decoration: none !important;
  font-size: 0.88rem;
  font-weight: 700;
}

.footer-admin-link a:hover {
  color: var(--text) !important;
  background: rgba(255, 255, 255, 0.08);
}

.kunden-page {
  width: min(calc(100% - 32px), var(--container));
  margin: 28px auto 0;
}

.kunden-gallery-section {
  width: min(calc(100% - 32px), var(--container));
  margin: 24px auto 0;
}

.gallery-section {
  padding: 60px 0;
  min-height: calc(100vh - 180px);
}

.gallery-section h1 {
  text-align: center;
  font-size: 40px;
  margin-bottom: 15px;
}

.gallery-section > p {
  text-align: center;
  font-size: 18px;
  margin-bottom: 40px;
}

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

.kunden-gallery-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.kunden-login-section,
.kunden-dashboard-hero,
.kunden-empty-state,
.kunden-gallery-grid {
  width: 100%;
}

.kunden-login-section {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 440px);
  gap: 24px;
  align-items: stretch;
  min-height: calc(100vh - 250px);
}

.kunden-info-card,
.kunden-form-card,
.kunden-empty-state,
.kunden-stat-card,
.kunden-file-card {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(34, 39, 51, 0.96), rgba(19, 23, 31, 0.98));
  box-shadow: var(--shadow);
}

.kunden-info-card,
.kunden-form-card,
.kunden-empty-state {
  border-radius: 32px;
  padding: 38px;
  position: relative;
  overflow: hidden;
}

.kunden-info-card::before,
.kunden-form-card::before {
  content: "";
  position: absolute;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  pointer-events: none;
}

.kunden-info-card::before {
  right: -40px;
  bottom: -40px;
  background: radial-gradient(circle, rgba(224, 169, 109, 0.14), transparent 70%);
}

.kunden-form-card::before {
  top: -40px;
  right: -30px;
  background: radial-gradient(circle, rgba(140, 180, 255, 0.14), transparent 70%);
}

.eyebrow {
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.kunden-info-card h1,
.kunden-dashboard-hero h1 {
  margin-bottom: 16px;
  font-size: clamp(2.6rem, 5vw, 4.8rem);
  line-height: 0.98;
}

.kunden-info-card p,
.kunden-dashboard-hero p,
.kunden-empty-state p,
.kunden-form-card p,
.kunden-file-content p {
  color: var(--muted);
  line-height: 1.8;
}

.kunden-benefits {
  margin-top: 28px;
  padding-left: 18px;
  color: var(--text);
  position: relative;
  z-index: 1;
}

.kunden-benefits li + li {
  margin-top: 10px;
}

.kunden-form-card h2,
.kunden-empty-state h2 {
  margin-bottom: 10px;
  font-size: 2rem;
}

.kunden-form-card > * {
  position: relative;
  z-index: 1;
}

.form-intro {
  margin-bottom: 22px;
}

.form-message {
  margin-bottom: 18px;
  padding: 14px 16px;
  border-radius: 16px;
  font-weight: 600;
}

.form-message-error {
  border: 1px solid rgba(255, 112, 112, 0.3);
  background: rgba(255, 112, 112, 0.12);
  color: #ffd2d2;
}

.form-message-success {
  border: 1px solid rgba(123, 222, 168, 0.28);
  background: rgba(123, 222, 168, 0.12);
  color: #d7ffea;
}

.kunden-login-form {
  display: grid;
  gap: 12px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(8px);
}

.kunden-login-form.is-collapsed {
  display: none;
}

.kunden-admin-table.is-collapsed {
  display: none;
}

.kunden-customer-panel.is-collapsed {
  display: none;
}

.kunden-toggle-button {
  min-height: 48px;
  padding: 0 20px !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, var(--accent), #c9854f) !important;
  color: #101216 !important;
  font-weight: 800 !important;
  cursor: pointer;
}

.kunden-inline-toggle-button {
  margin-top: 14px;
}

.kunden-login-form label {
  font-weight: 700;
  color: var(--text);
  font-size: 0.96rem;
}

.kunden-login-form input {
  min-height: 54px;
}

.kunden-login-form select,
.kunden-login-form textarea {
  min-height: 54px;
}

.kunden-login-form select {
  width: 100%;
  max-width: 100%;
  padding: 14px 16px;
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(255, 255, 255, 0.7) 50%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.7) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) calc(50% - 3px),
    calc(100% - 14px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 42px;
}

.kunden-login-form button {
  width: 100%;
  margin-top: 8px;
  cursor: pointer;
}

.kunden-login-note {
  margin-top: 18px;
  font-size: 0.95rem;
}

.kunden-dashboard-hero {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
  padding: 34px 36px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background: linear-gradient(180deg, rgba(29, 33, 43, 0.98), rgba(16, 19, 25, 0.98));
  box-shadow: var(--shadow);
}

.kunden-stats {
  min-width: 250px;
  display: grid;
  gap: 14px;
  align-content: start;
}

.kunden-stat-card {
  border-radius: 24px;
  padding: 18px 20px;
}

.kunden-stat-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.92rem;
}

.kunden-stat-card strong {
  font-size: 2rem;
}

.kunden-logout-link,
.kunden-file-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.kunden-logout-link {
  min-height: 54px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #c9854f);
  color: #101216;
  font-weight: 800;
  box-shadow: 0 18px 34px rgba(201, 133, 79, 0.22);
}

.kunden-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 22px;
  padding-bottom: 12px;
}

.kunden-album-grid {
  margin-top: 34px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  align-items: start;
}

.kunden-album-item {
  display: inline-flex;
  align-self: start;
  flex: 0 0 auto;
  width: auto;
  max-width: min(100%, 360px);
  padding: 5px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(34, 39, 51, 0.96), rgba(19, 23, 31, 0.98));
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  transform-origin: center center;
}

.kunden-album-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 42px rgba(0, 0, 0, 0.28);
}

.kunden-album-item img {
  width: auto;
  max-width: min(100%, 350px);
  height: auto;
  display: block;
  border-radius: 17px;
  box-shadow: none;
  object-fit: contain;
  cursor: pointer;
  background: transparent;
  transition: none;
  padding: 0;
}

.kunden-album-item img:hover {
  transform: none;
  box-shadow: none;
}

.album-download-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, var(--accent), #c9854f);
  color: #101216;
  text-decoration: none !important;
  font-weight: 800;
}

.kunden-file-card {
  overflow: hidden;
  border-radius: 28px;
}

.kunden-preview-link,
.kunden-file-placeholder {
  display: flex;
  min-height: 260px;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)), #181c25;
}

.kunden-preview-link img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.kunden-file-placeholder span {
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.kunden-file-content {
  padding: 20px 22px 22px;
}

.kunden-file-content h2 {
  margin-bottom: 8px;
  font-size: 1.25rem;
  line-height: 1.35;
}

.kunden-file-actions {
  display: flex;
  gap: 12px;
  margin-top: 18px;
}

.kunden-file-actions a {
  flex: 1;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font-weight: 700;
}

.kunden-file-actions a:last-child {
  background: linear-gradient(135deg, var(--accent), #c9854f);
  color: #101216;
}

.kunden-admin-grid,
.kunden-admin-list {
  width: 100%;
}

.kunden-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.kunden-admin-card,
.kunden-admin-list {
  border: 1px solid var(--line);
  border-radius: 32px;
  padding: 32px;
  background: linear-gradient(180deg, rgba(34, 39, 51, 0.96), rgba(19, 23, 31, 0.98));
  box-shadow: var(--shadow);
}

.kunden-admin-list {
  margin-top: 24px;
}

.kunden-admin-list-head h2,
.kunden-admin-card h2 {
  margin-bottom: 10px;
  font-size: 2rem;
}

.kunden-admin-table {
  display: grid;
  gap: 16px;
  margin-top: 22px;
}

.kunden-admin-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.03);
}

.kunden-admin-row h3 {
  margin-bottom: 6px;
  font-size: 1.18rem;
}

.kunden-admin-row p {
  color: var(--muted);
  line-height: 1.7;
}

.kunden-admin-file-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.kunden-inline-edit-form {
  margin-top: 16px;
}

.kunden-customer-panel {
  width: 100%;
  margin-top: 16px;
}

.kunden-checkbox-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.kunden-checkbox-row input {
  min-height: auto;
  width: 18px;
  height: 18px;
}

.kunden-admin-file-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
}

.kunden-admin-file-row span {
  color: var(--muted);
  line-height: 1.6;
}

.kunden-admin-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.kunden-admin-actions form {
  margin: 0;
}

.kunden-admin-actions button {
  min-height: 46px;
  padding: 0 18px !important;
  white-space: nowrap;
}

.password-inline-wrap,
.kunden-inline-password-form {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.password-inline-input {
  min-height: 44px;
  min-width: 220px;
  padding: 10px 14px;
}

.password-inline-toggle {
  min-height: 44px;
  padding: 0 16px !important;
}

.kunden-lightbox-figure {
  display: grid;
  gap: 16px;
  justify-items: center;
}

.kunden-lightbox-figure img {
  max-width: 90vw;
  max-height: 80vh;
  object-fit: contain;
}

.kunden-lightbox-figure figcaption {
  max-width: 800px;
  text-align: center;
  color: var(--text);
}

.lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  justify-content: center;
  align-items: center;
  padding: 40px;
}

.lightbox.active {
  display: flex;
}

.lightbox .close,
.lightbox .prev,
.lightbox .next {
  position: absolute;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border: none;
  font-size: 30px;
  padding: 12px 18px;
  cursor: pointer;
  border-radius: 12px;
  transition: background 0.3s ease;
}

.lightbox .close:hover,
.lightbox .prev:hover,
.lightbox .next:hover {
  background: rgba(255, 255, 255, 0.28);
}

.lightbox .close {
  top: 20px;
  right: 20px;
}

.lightbox .prev {
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox .next {
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 900px) {
  .site-header {
    gap: 12px;
  }

  .mobile-menu-toggle {
    justify-self: end;
  }

  .site-header .site-nav {
    margin-left: 0;
  }

  .site-header .site-nav a.nav-instagram {
    width: 100%;
    min-width: 0;
    padding: 10px 16px;
    gap: 10px;
    justify-content: center;
  }

  .site-header .site-nav a.nav-instagram img {
    width: 22px;
    height: 22px;
  }

  .kunden-page {
    width: min(calc(100% - 20px), var(--container));
    margin-top: 20px;
  }

  .kunden-login-section,
  .kunden-dashboard-hero {
    grid-template-columns: 1fr;
    display: grid;
  }

  .kunden-info-card,
  .kunden-form-card,
  .kunden-empty-state,
  .kunden-dashboard-hero {
    border-radius: 24px;
    padding: 24px 20px;
  }

  .kunden-login-form {
    padding: 18px;
    border-radius: 20px;
  }

  .kunden-stats {
    min-width: 0;
  }

  .kunden-gallery-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .kunden-album-grid {
    justify-content: center;
    gap: 18px;
  }

  .kunden-album-item {
    max-width: min(100%, 320px);
  }

  .kunden-album-item img {
    max-width: min(100%, 310px);
    max-height: none;
  }

  .kunden-gallery-actions {
    width: 100%;
    flex-direction: column;
  }

  .gallery-section {
    padding: 40px 0 24px;
  }

  .lightbox {
    padding: 18px;
  }

  .lightbox .prev,
  .lightbox .next {
    font-size: 24px;
    padding: 10px 14px;
  }

  .kunden-admin-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .kunden-admin-card,
  .kunden-admin-list {
    border-radius: 24px;
    padding: 24px 20px;
  }

  .kunden-admin-row {
    flex-direction: column;
    align-items: stretch;
  }

  .kunden-admin-actions {
    flex-direction: column;
  }

  .kunden-admin-file-row {
    flex-direction: column;
    align-items: stretch;
  }

  .password-inline-wrap,
  .kunden-inline-password-form {
    width: 100%;
    align-items: stretch;
  }

  .password-inline-input,
  .password-inline-toggle {
    width: 100%;
  }

  .kunden-file-actions {
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .gallery-grid,
  .kunden-album-grid {
    justify-content: center;
  }

  .kunden-album-item,
  .kunden-album-item img {
    max-width: 100%;
  }
}
