/* ─── Reset ──────────────────────────────────────────────────────────────── */
* { margin: 0; padding: 0; box-sizing: border-box; }

/* ─── Base ───────────────────────────────────────────────────────────────── */
body {
  font-family: 'ff-typestar-black-web', sans-serif;
}

#header-desc {
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 400;
}

.card-title span {
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 400;
}

#header-impressum {
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 900;
}

/* ─── Header ─────────────────────────────────────────────────────────────── */
#header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: #fff;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 15px 8px 15px 24px;
  height: 76px;
  border-bottom: 1px solid #eee;
}

#header-left {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 24px;
  min-width: 0;
  height: 45px;
}

#logo-wrap {
  position: relative;
  width: 247px;
  height: 45px;
  flex-shrink: 0;
  cursor: pointer;
}

#logo-mask {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

#header-desc {
  flex: 1;
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 400;
  font-size: 16px;
  color: #000;
  line-height: normal;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 45px;
  min-width: 1px;
}

#header-insta {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #000;
}

#header-insta svg { width: 24px; height: 24px; }

#header-impressum {
  flex-shrink: 0;
  width: 14px;
  height: 57px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 900;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #000;
  text-decoration: none;
  transform: rotate(-90deg);
  white-space: nowrap;
}

/* ─── Intro ──────────────────────────────────────────────────────────────── */
#intro {
  position: sticky;
  top: 76px;
  z-index: 100;
  background: #f7f7f7;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 80px;
  padding: 8px 16px;
  overflow: hidden;
}

#intro-text {
  font-family: 'Gloock', serif;
  font-size: clamp(1rem, 2vw, 1.5rem);
  color: #424242;
  text-align: center;
}

.intro-line {
  display: block;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.intro-line.out-up {
  opacity: 0;
  transform: translateY(-20px);
}

.intro-line.out-down {
  opacity: 0;
  transform: translateY(20px);
}

/* ─── Gallery ────────────────────────────────────────────────────────────── */
#gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 8px;
}

.card {
  background: #d9d9d9;
  border-radius: 8px;
  box-shadow: 0 0 4px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 422 / 527.5;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.card-artwork {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.card-artwork img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.card-title {
  background: #fff;
  height: 32px;
  display: flex;
  align-items: center;
  padding: 0 8px;
  flex-shrink: 0;
}

.card-title span {
  font-family: 'ff-typestar-black-web', sans-serif;
  font-weight: 400;
  font-size: 14px;
  color: #000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ─── Overlay ────────────────────────────────────────────────────────────── */
#overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  background: rgba(60,60,60,0.7);
  align-items: center;
  justify-content: center;
}

#overlay.active { display: flex; }

#overlay-inner {
  position: absolute;
  inset: 16px;
  border-radius: 8px;
  overflow: hidden;
  background: #000;
}

#overlay-iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

#overlay-logo {
  position: absolute;
  top: 24px;
  left: 24px;
  width: 140px;
  height: 25px;
  z-index: 10;
  cursor: pointer;
  opacity: 0.5;
}

#overlay-logo svg { width: 100%; height: 100%; }

#overlay-close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 10;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  mix-blend-mode: difference;
}

#overlay-close svg { width: 24px; height: 24px; }

#overlay-prev,
#overlay-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: none;
  border: none;
  cursor: pointer;
  color: #fff;
  mix-blend-mode: difference;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#overlay-prev { left: 16px; }
#overlay-next { right: 16px; }
#overlay-prev svg,
#overlay-next svg { width: 24px; height: 24px; }

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  #gallery { grid-template-columns: repeat(2, 1fr); }
  #header-desc { display: none; }
  #logo-wrap { width: 140px; height: 25px; }
}