/* ── Variables ───────────────────────────────────── */
:root {
  --bg: #000000;
  --surface: #ffffff00;
  --border: #e0ddd6;
  --text: #c0bebe;
  --muted: #8a877f;
  --accent: #2d5be3;
  --accent-lt: #e8edfc;
  --danger: #d94f3d;
  --radius: 0px;
  --mono: 'DM Mono', monospace;
  --sans: 'Camera', sans-serif;
  --shadow: 0 2px 12px rgba(0, 0, 0, .08);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, .14);
}

@font-face {
  font-family: Camera;
  src: url(ABCCameraPlainVariableEdu-Regular.woff);
}



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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  height: 100vh;
  display: grid;
  grid-template-columns: 160px 1fr;
  overflow: hidden;
}


/* ── Header ──────────────────────────────────────── */
.site-header {
  padding: 12px 12px 0px 12px;
  background: var(--bg);

  
  grid-column: 1 / 2;
  grid-row: 1;
  align-self: start;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
}

.site-title {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 500;
  color: var(--text);
  display: block;
  letter-spacing: -0.2px;
  text-decoration: none;
}

.site-subtitle {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
  display: block;
  letter-spacing: 0.02em;
}

/* ── App Layout ───────────────────────────────────── */
.app-layout {
  display: flex;
  grid-column: 1 / -1;
  grid-row: 1;
  height: 100vh;
  overflow: hidden;
}

/* ── Sidebar ──────────────────────────────────────── */
.sidebar {
  width: 160px;
  min-width: 160px;
  background: var(--surface);
  border-right: none solid var(--border);
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow-y: auto;
  padding: 140px 16px 24px;
  gap: 0;
  flex-shrink: 0;
}

.site-title {
  font-family: var(--sans);
  font-size: 25px;
  font-weight: 500;
  letter-spacing: -0.3px;
  color: var(--text);
  display: block;
}

.sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: none;
}

.sidebar-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.sidebar-label {
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

#file-input {
  display: none;
}

.upload-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--text);
  color: #fff;
  border: none;
  padding: 9px 14px;
  border-radius: 0px;
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
  width: 100%;
}

.upload-btn:hover {
  background: #333;
}

#status-message {
  font-family: var(--sans);
  font-size: 10.5px;
  color: var(--muted);
  min-height: 16px;
  line-height: 1.4;
}

/* ── Main Content ─────────────────────────────────── */
.main-content {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
}

/* ── Sidebar Filter Inputs ────────────────────────── */
.filter-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.filter-label {
  font-family: var(--sans);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.filter-input {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  padding: 4px 0;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--text);
  outline: none;
  transition: border-color 0.14s;
  width: 100%;
}

.filter-input::placeholder {
  color: var(--muted);
  opacity: 0.6;
}

.filter-input:focus {
  border-bottom-color: var(--text);
}

/* Dropdowns — Sidebar & Modal */
select.filter-input,
select.modal-input {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%238a877f' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 2px center;
  padding-right: 18px;
}

select.filter-input option,
select.modal-input option {
  background: #111;
  color: var(--text);
}



/* ── Gallery — Masonry ───────────────────────────── */
.gallery {
  columns: 6 10vw;
  column-gap: 6px;
  padding: 5px;
  max-width: 1400px;
  margin: 0;
}

/* ── Mobile Nav (Hamburger + Drawer) ───────────────── */
.menu-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}

.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 450;
}

.sidebar-backdrop.visible {
  display: block;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  transition: box-shadow 0.18s, transform 0.18s;
  background: transparent;
  border: none;
  break-inside: avoid;
  display: inline-block;
  width: 100%;
}

.gallery-item:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.gallery-item.hidden {
  display: none;
}

.img-item {
  display: block;
  width: 100%;
  height: auto;
  transition: filter 1s ease;
}

.img-item.is-thumb {
  filter: blur(6px);
  transform: scale(1.0);
}

/* Overlay — sichtbar nur beim Hover */
.gallery-item-meta {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.1) 55%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 6px;
  padding: 10px;
  opacity: 0;
  transition: opacity 0.18s;
}

.gallery-item:hover .gallery-item-meta {
  opacity: 1;
}

.item-tags,
.item-info {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.item-tag {
  font-family: var(--sans);
  font-size: 10px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border-radius: 0px;
  padding: 2px 8px;
  backdrop-filter: blur(4px);
}

.item-actions {
  display: flex;
  gap: 6px;
}

.btn-tag-edit {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  padding: 6px 10px;
  font-family: var(--sans);
  font-size: 12px;
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.12s;
}

.btn-tag-edit:hover {
  background: rgba(255, 255, 255, 0.28);
}

.img-delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  padding: 6px 10px;
  font-family: var(--sans);
  font-size: 12px;
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.12s;
}

.img-delete:hover {
  background: rgba(220, 80, 60, 0.6);
  border-color: transparent;
}

/* ── Empty State ──────────────────────────────────── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 80px 24px;
  color: var(--muted);
  font-size: 14px;
  max-width: 1400px;
  margin: 0 auto;
}

.empty-state svg {
  opacity: 0.3;
}

.empty-state.hidden {
  display: none;
}

/* ── Modal ────────────────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(20, 18, 14, 0.45);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.15s ease;
}

.modal.hidden {
  display: none;
}

.modal-box {
  background: #111;
  border-radius: 4px;
  padding: 28px 32px;
  width: min(420px, 90vw);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-title {
  font-size: 15px;
  font-weight: 500;
  font-family: var(--sans);
  color: var(--text);
}

.modal-fields {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.modal-label {
  font-family: var(--sans);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.modal-input {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 0;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--text);
  outline: none;
  transition: border-color 0.14s;
  width: 100%;
}

.modal-input::placeholder {
  color: var(--muted);
  opacity: 0.5;
}

.modal-input:focus {
  border-bottom-color: var(--text);
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 4px;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 9px 20px;
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.12s;
}

.btn-primary:hover {
  background: #1e48cc;
}

.btn-secondary {
  background: var(--bg);
  color: var(--text);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 9px 20px;
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.12s;
}

.btn-secondary:hover {
  background: var(--border);
}

/* ── Lightbox ────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.377);
  z-index: 300;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.18s ease;
  backdrop-filter: blur(20px);
}

.lightbox.hidden {
  display: none;
}

.lb-panel {
  background: rgb(245, 245, 245);
  width: 100%;
  max-width: 100vw;
  height: 80vh;
  display: flex;
  flex-direction: column;
  position: relative;
  border-top: 1px solid rgba(255, 255, 255, 0.07);

}

/* Close button */
.lb-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  z-index: 10;
  padding: 4px;
  transition: color 0.12s;
}

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

/* ── Image strip ── */
.lb-images-wrap {
  flex: 1;
  min-height: 0;
  padding: 20px 20px 0;
  overflow: hidden;
}

.lb-images {
  display: flex;
  gap: 6px;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.1) transparent;
}

.lb-images::-webkit-scrollbar {
  height: 4px;
}

.lb-images::-webkit-scrollbar-track {
  background: transparent;
}

.lb-images::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
}

.lb-img-wrap {
  position: relative;
  flex: 0 0 calc(20% - 5px);
  min-width: 0;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
}

.lb-img {
  width: auto;
  height: 100%;
  display: block;
}

/* Delete button auf Zusatzbildern */
.lb-img-delete {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.14s;
}

.lb-img-wrap:hover .lb-img-delete {
  opacity: 1;
}

.lb-img-delete:hover {
  background: rgba(220, 80, 60, 0.8);
}

/* Hauptbild — kein Delete-Button */
.lb-main .lb-img-delete {
  display: none;
}

/* Ghost-Bild (+) */
.lb-ghost {
  flex: 0 0 calc(20% - 5px);
  height: 100%;
  max-height: 120px;
  border: 1px dashed rgb(0, 0, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgb(0, 0, 0);
  cursor: pointer;
  transition: border-color 0.14s, color 0.14s;
  flex-shrink: 0;
}

.lb-ghost:hover {
  border-color: rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.5);
}

/* ── Footer ── */
.lb-footer {
  display: flex;
  flex-direction: row;
  border-top: 1px solid rgb(190, 190, 190);
  min-height: 8vw;
  flex-shrink: 0;
  /* background-color: crimson; */
}

.lb-info {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  padding: 14px 20px;
  flex-wrap: wrap;
  /* background-color: chartreuse; */
}

.lb-info-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lb-info-label {
  font-family: var(--sans);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.lb-info-val {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--text);
}

/* Tie-Up */
.lb-tieup-wrap {
  padding: 14px 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.lb-tieup-label {
  font-family: var(--sans);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.lb-tieup-area {
  position: relative;
  width: 72px;
  height: 72px;
}

.lb-tieup-img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  display: block;
  border-radius: 2px;
}

.lb-tieup-ghost {
  width: 72px;
  height: 72px;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: border-color 0.15s, color 0.15s;
}

.lb-tieup-ghost:hover {
  border-color: rgba(255, 255, 255, 0.4);
  color: rgba(255, 255, 255, 0.6);
}

.lb-tieup-delete {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  padding: 0;
}

.lb-tieup-delete:hover {
  background: rgba(0, 0, 0, 0.85);
}

/* Tie-Up Sichtbarkeit */
body[data-admin="true"] .lb-tieup-wrap {
  display: flex;
}

body:not([data-admin="true"]) .lb-tieup-wrap {
  display: none;
}

body:not([data-admin="true"]) .lb-tieup-wrap.has-content {
  display: flex;
}

/* Notiz — unterhalb der Info */
.lb-notiz-wrap {
  padding: 14px 20px;
  display: flex;
  width: 50vw;
  flex-direction: column;
  min-height: fit-content;
  gap: 4px;
  /* background-color: blue; */
}

.lb-notiz-label {
  font-family: var(--sans);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  /* background-color: deeppink; */
}

.lb-notiz {
  width: 100%;
  max-width: 480px;
  background: transparent;
  border: none;
  outline: none;
  resize: none;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--text);
  line-height: 1.5;
  min-height: 28px;
  height: 5vw;
  /* background-color: deeppink; */
}

#lb-notiz {
  color: #424141;
}

.lb-notiz::placeholder {
  color: var(--muted);
  opacity: 0.5;
}

/* ── Notiz Sichtbarkeit ───────────────────────────── */
/* Admin-Modus: immer sichtbar */
body[data-admin="true"] .lb-notiz-wrap {
  display: flex;
}

/* Read-only: nur wenn Notiz vorhanden */
body:not([data-admin="true"]) .lb-notiz-wrap {
  display: none;
}

body:not([data-admin="true"]) .lb-notiz-wrap.has-content {
  display: flex;
}

/* Textarea im Read-only nicht editierbar */
body:not([data-admin="true"]) .lb-notiz {
  pointer-events: none;
  cursor: default;
}

/* ── Sidebar Page Links ───────────────────────────── */
.sidebar-pages {
  margin-top: auto;
}

.sidebar-page-link {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  display: block;
  letter-spacing: -0.2px;
  transition: color 0.14s;
}

.sidebar-page-link:hover {
  color: var(--text);
}

.sidebar-page-link.active {
  color: var(--text);
}

.sidebar-page-link.passive {
  color: var(--muted);
}

/* ── Lexikon ──────────────────────────────────────── */
.page-lexikon .main-content {
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.lexikon-container {
  display: flex;
  flex-direction: column;
  padding: 30px 16px;
  gap: 40px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.lexikon-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.lexikon-row-title {
  font-family: var(--sans);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  flex-shrink: 0;
}

.lexikon-row {
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  gap: 6px;
  flex: 1;
  min-height: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.08) transparent;
}

.lexikon-row::-webkit-scrollbar {
  height: 3px;
}

.lexikon-row::-webkit-scrollbar-track {
  background: transparent;
}

.lexikon-row::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
}

.lexikon-entry {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  width: 220px;
  position: relative;
  max-height: 100%;
  overflow: hidden;
}

.lexikon-entry img {
  width: 220px;
  height: auto;
  display: block;
  max-height: 100%;
}

.lexikon-entry-caption {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
  padding: 5px 0 2px;
}

.lexikon-entry-caption strong {
  color: var(--text);
  font-weight: 500;
}

/* Caption Textarea (Admin) */
.lexikon-caption-input {
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 4px 0;
  font-family: var(--sans);
  font-size: 11px;
  color: var(--text);
  outline: none;
  width: 100%;
  resize: none;
  line-height: 1.5;
}

.lexikon-caption-input::placeholder {
  color: var(--muted);
  opacity: 0.5;
}

body:not([data-admin="true"]) .lexikon-caption-input {
  display: none;
}

/* Caption sichtbar wenn Text vorhanden */
.lexikon-entry-caption.has-text {
  display: block;
}

body[data-admin="true"] .lexikon-entry-caption:not(.has-text) {
  display: none;
}

/* Delete Button */
.lexikon-entry-delete {
  align-self: flex-start;
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 10px;
  font-family: var(--sans);
  padding: 2px 0;
  opacity: 0;
  transition: opacity 0.12s, color 0.12s;
}

.lexikon-entry:hover .lexikon-entry-delete {
  opacity: 1;
}

.lexikon-entry-delete:hover {
  color: var(--danger);
}

body:not([data-admin="true"]) .lexikon-entry-delete {
  display: none;
}

/* Ghost: neuer Eintrag */
.lexikon-add {
  flex: 0 0 auto;
  width: 80px;
  height: 100px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: border-color 0.14s, color 0.14s;
}

.lexikon-add:hover {
  border-color: rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.45);
}

body:not([data-admin="true"]) .lexikon-add {
  display: none;
}

/* ── About Page ──────────────────────────────────── */
.main-content--about {
  overflow: hidden;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 40px;
  height: 100%;
  overflow: hidden;
  padding-bottom: 24px;
}

.about-col {
  padding: 24px 3px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
}

.bottom {
  justify-content: flex-end;
}

.about-col--scroll {
  overflow-y: auto;
  
}

.about-block {
  position: relative;
}

.about-img {
  width: 100%;
  height: auto;
  display: block;
}

.about-block.empty {}

.about-textarea {
  width: 100%;
  /* background: transparent; */
  /* background-color: #1e48cc; */
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  outline: none;
  resize: none;
  overflow: hidden;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--text);
  line-height: 1.6;
  padding: 6px 4px;
  display: block;
  box-sizing: border-box;
  width: 100%;
  border-bottom: none;
}

.web-credits {
  font-family: var(--sans);
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
  padding: 5px 0 2px;
}

.about-textarea::placeholder {
  color: var(--muted);
  opacity: 0.4;
}

body:not([data-admin="true"]) .about-textarea {
  pointer-events: none;
  border-bottom-color: transparent;
}

body:not([data-admin="true"]) .about-block.empty {
  display: none;
}

.about-block-delete {
  position: absolute;
  top: 6px;
  right: 0;
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  font-family: var(--sans);
  opacity: 0;
  transition: opacity 0.12s, color 0.12s;
  padding: 2px 4px;
}

.about-block:hover .about-block-delete {
  opacity: 1;
}

.about-block-delete:hover {
  color: var(--danger);
}

body:not([data-admin="true"]) .about-block-delete {
  display: none;
}

.about-ghost {
  width: 48px;
  height: 48px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  background: transparent;
  transition: border-color 0.14s, color 0.14s;
  flex-shrink: 0;
}

.about-ghost:hover {
  border-color: rgba(255, 255, 255, 0.4);
  color: rgba(255, 255, 255, 0.5);
}

body:not([data-admin="true"]) .about-ghost {
  display: none;
}

/* ── Lexikon Lightbox ────────────────────────────── */
.lx-lb {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(20px);
  background: rgba(0, 0, 0, 0.15);
}

.lx-lb.hidden {
  display: none;
}

.lx-lb-img {
  max-height: 90vh;
  max-width: 90vw;
  width: auto;
  height: auto;
  display: block;
}

.lx-lb-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 22px;
  cursor: pointer;
  padding: 16px;
  opacity: 0.5;
  transition: opacity 0.15s;
}

.lx-lb-arrow:hover { opacity: 1; }
.lx-lb-prev { left: 20px; }
.lx-lb-next { right: 20px; }

.lx-lb-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  opacity: 0.5;
  transition: opacity 0.15s;
}

/* ── Mobile Layout (≤768px) ─────────────────────────
   Steht bewusst am Dateiende: überschreibt gleich-
   spezifische Desktop-Regeln (z.B. .page-lexikon
   .main-content, .main-content--about, .lb-panel),
   die weiter oben ohne Media Query definiert sind. */
@media (max-width: 768px) {
  .gallery {
    columns: 3;
    padding: 12px;
  }

  .lb-img-wrap {
    flex: 0 0 100%;
    scroll-snap-align: center;
  }

  /* Auflösung der fixen Desktop-App-Shell */
  body {
    display: block;
    height: auto;
    overflow: visible;
  }

  .site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    grid-column: auto;
    grid-row: auto;

  }

  .menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    /* padding: 6px; */
  }

  .menu-toggle svg {
    width: 28px;
    height: 28px;
  }

  .app-layout {
    display: block;
    height: auto;
    overflow: visible;
  }

  /* Sidebar wird zum Drawer */
  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100dvh;
    width: min(280px, 80vw);
    padding: 32px 20px 24px;
    background: #0a0a0a;
    transform: translateX(-100%);
    transition: transform 0.2s ease;
    z-index: 500;
    overflow-y: auto;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  body.nav-open {
    overflow: hidden;
  }

  .main-content,
  .page-lexikon .main-content,
  .main-content--about {
    width: 100%;
    height: auto;
    overflow: visible;
  }

  /* Lightbox: Vollbild-Swipe statt Filmstreifen */
  .lightbox {
    align-items: stretch;
  }

  .lb-panel {
    height: 100dvh;
  }

  .lb-images {
    scroll-snap-type: x mandatory;
  }

  .lb-footer {
    flex-direction: column;
    overflow-y: auto;
  }

  .lb-notiz-wrap {
    width: 100%;
  }

  /* Lexikon: normaler Fluss statt viewport-gebundenem Flex */
  .lexikon-container {
    flex: none;
    height: auto;
    overflow: visible;
    padding: 24px 16px 30px;
  }

  .lexikon-section {
    flex: none;
    overflow: visible;
  }

  .lexikon-row {
    flex: none;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .lexikon-entry,
  .lexikon-entry img {
    width: 150px;
  }

  /* About: eine Spalte statt drei */
  .about-grid {
    display: block;
    height: auto;
    overflow: visible;
  }

  .about-col {
    height: auto;
    overflow: visible;
    padding: 16px 16px 24px;
  }
}

.lx-lb-close:hover { opacity: 1; }