:root {
  --ink: #2a2420;
  --muted: #6f6258;
  --paper: #faf8f5;
  --surface: #f2eee8;
  --line: #d8cec3;
  --accent: #8b6f5c;
  --accent-dark: #6b5545;
  --blue: #2d5a6b;
  --white: #fffdf9;
  --shadow: 0 22px 50px rgba(42, 36, 32, 0.13);
  --exhibitions-bg-image: url("assets/kunstwerkeln-hero-gallery-alt.png");
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "DM Sans", "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  line-height: 1.65;
}

body.nav-open,
body.lightbox-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px clamp(18px, 4vw, 56px);
  color: var(--white);
  transition: background 180ms ease, color 180ms ease, box-shadow 180ms ease, padding 180ms ease;
}

.site-header.is-scrolled,
.site-header.nav-active {
  padding-top: 14px;
  padding-bottom: 14px;
  color: var(--ink);
  background: rgba(250, 248, 245, 0.94);
  box-shadow: 0 8px 28px rgba(42, 36, 32, 0.08);
  backdrop-filter: blur(14px);
}

.brand {
  position: relative;
  display: inline-flex;
  align-items: center;
  color: currentColor;
  font-family: "Great Vibes", "Segoe Script", "Brush Script MT", cursive;
  font-size: clamp(1.55rem, 2.6vw, 2.25rem);
  font-weight: 400;
  letter-spacing: 0;
  text-decoration: none;
  text-underline-offset: 0.24em;
  transition: opacity 180ms ease, text-decoration-color 180ms ease;
}

.brand:hover,
.brand:focus-visible {
  text-decoration: underline;
  text-decoration-thickness: 1px;
}

.brand:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 6px;
}

.logo-script {
  font-family: "Great Vibes", "Segoe Script", "Brush Script MT", cursive;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 34px);
  font-size: 0.8rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-nav a {
  position: relative;
  padding: 6px 0;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 6px;
  color: inherit;
  background: transparent;
  cursor: pointer;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  transition: transform 180ms ease;
}

.nav-toggle span:not(.sr-only) + span:not(.sr-only) {
  margin-top: 5px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.hero {
  position: relative;
  min-height: clamp(590px, 88svh, 820px);
  overflow: hidden;
  isolation: isolate;
}

.hero-media,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-media {
  z-index: -3;
  background-image: url("assets/kunstwerkeln-hero.png");
  background-position: center;
  background-size: cover;
}

.hero-shade {
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(20, 17, 15, 0.74), rgba(42, 36, 32, 0.32) 52%, rgba(42, 36, 32, 0.08)),
    linear-gradient(0deg, rgba(42, 36, 32, 0.38), transparent 36%);
}

.hero-content {
  display: flex;
  min-height: inherit;
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 96px 0 84px;
  color: var(--white);
}

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

.hero .eyebrow {
  color: #f4cfaa;
}

h1,
h2,
h3,
p,
dd,
dt {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
  letter-spacing: 0;
}

h1 {
  max-width: 760px;
  font-size: clamp(3.6rem, 9vw, 8.2rem);
  font-weight: 500;
}

h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.05rem, 4.7vw, 4.3rem);
  font-weight: 500;
}

h3 {
  font-size: 1.08rem;
}

.hero-line {
  width: 86px;
  height: 2px;
  margin: 20px 0 0;
  background: #f4cfaa;
}

.hero-content > p:not(.eyebrow) {
  max-width: 650px;
  margin: 24px 0 0;
  color: rgba(255, 253, 249, 0.9);
  font-size: clamp(1.05rem, 2.2vw, 1.32rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 0;
  padding: 11px 18px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button.primary {
  color: var(--white);
  background: var(--accent);
}

.button.primary:hover,
.button.primary:focus-visible {
  background: var(--accent-dark);
}

.button.secondary {
  color: var(--white);
  border-color: rgba(255, 253, 249, 0.72);
  background: rgba(255, 253, 249, 0.08);
}

.section-wrap {
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(66px, 9vw, 118px) 0;
}

.section-band {
  background: var(--white);
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.8fr);
  gap: clamp(34px, 7vw, 86px);
  align-items: start;
}

.intro > p,
.section-heading p,
.artist-copy p,
.contact p {
  color: var(--muted);
  font-size: 1.05rem;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(280px, 0.76fr);
  gap: clamp(24px, 6vw, 78px);
  align-items: end;
  margin-bottom: 40px;
}

.section-heading .eyebrow {
  grid-column: 1 / -1;
  margin-bottom: -14px;
}

.section-heading p {
  margin: 0;
}

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

.gallery-item {
  min-width: 0;
}

.gallery-item button {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: var(--surface);
  cursor: pointer;
}

.art-canvas {
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--surface);
  transition: transform 650ms ease;
}

.art-canvas img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery-item button:hover .art-canvas,
.gallery-item button:focus-visible .art-canvas {
  transform: scale(1.05);
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 4px;
  padding: 18px;
  color: var(--white);
  background: linear-gradient(to top, rgba(10, 9, 8, 0.82), rgba(10, 9, 8, 0));
  opacity: 0;
  transition: opacity 220ms ease;
}

.gallery-item button:hover .gallery-overlay,
.gallery-item button:focus-visible .gallery-overlay {
  opacity: 1;
}

.gallery-overlay span {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.12rem;
}

.gallery-overlay small {
  color: rgba(255, 253, 249, 0.78);
  font-weight: 700;
}

.work-info {
  border-top: 1px solid var(--line);
  margin-top: 14px;
  padding-top: 13px;
}

.work-info > p {
  margin: 0 0 7px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.work-info h3 {
  min-height: 2.3em;
}

.work-info dl {
  display: grid;
  gap: 7px;
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.work-info dl div {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 10px;
  align-items: baseline;
}

.work-info dt,
.work-info dd {
  margin: 0;
}

.work-info dt {
  color: rgba(42, 36, 32, 0.58);
  font-weight: 750;
}

.work-info dd {
  color: var(--ink);
}

.artist {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(280px, 0.8fr);
  gap: clamp(30px, 7vw, 90px);
  align-items: center;
}

.artist-copy p {
  margin: 22px 0 0;
}

.artist-side {
  display: grid;
  gap: 22px;
}

.artist-photo {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.artist-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center;
}

.artist-panel {
  display: grid;
  gap: 0;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: var(--shadow);
}

.artist-panel > div {
  display: grid;
  gap: 6px;
  padding: 24px;
}

.artist-panel > div + div {
  border-top: 1px solid var(--line);
}

.artist-panel span {
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.artist-panel strong {
  font-size: 1.05rem;
  line-height: 1.35;
}

.exhibition-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.exhibitions {
  position: relative;
  isolation: isolate;
  background:
    linear-gradient(90deg, rgba(22, 18, 15, 0.78), rgba(42, 36, 32, 0.46)),
    var(--exhibitions-bg-image) center / cover no-repeat;
}

.exhibitions::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(18, 15, 12, 0.24);
  content: "";
}

.exhibitions .eyebrow {
  color: #f4cfaa;
}

.exhibitions h2 {
  color: var(--white);
}

.exhibition-card {
  border-left: 3px solid var(--accent);
  padding: 26px;
  background: rgba(255, 253, 249, 0.9);
  backdrop-filter: blur(8px);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.exhibition-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 28px rgba(42, 36, 32, 0.1);
}

.exhibition-card p {
  margin: 0 0 16px;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.exhibition-card h3 {
  margin-bottom: 14px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.32rem;
}

.exhibition-card span,
.exhibition-card time {
  display: block;
  color: var(--muted);
  font-size: 0.94rem;
}

.exhibition-card time {
  margin-top: 6px;
}

.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(290px, 0.8fr);
  gap: clamp(28px, 7vw, 84px);
  align-items: start;
}

.contact-links {
  display: grid;
  gap: 8px;
  margin-top: 26px;
  color: var(--accent);
  font-weight: 800;
}

.contact-form {
  display: grid;
  gap: 16px;
  border: 1px solid var(--line);
  padding: clamp(18px, 4vw, 30px);
  background: var(--white);
  box-shadow: var(--shadow);
}

.contact-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.spam-field {
  position: absolute;
  left: -100vw;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid rgba(42, 36, 32, 0.22);
  border-radius: 0;
  padding: 12px 13px;
  color: var(--ink);
  background: var(--paper);
}

.captcha-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--ink);
}

.captcha-refresh {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--accent);
  background: var(--paper);
  cursor: pointer;
}

.form-status {
  min-height: 1.4em;
  margin: -2px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.form-status.error {
  color: #a23d2d;
}

.form-status.success {
  color: #4f6f49;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  outline: 3px solid rgba(139, 111, 92, 0.18);
}

.contact-form .button {
  width: fit-content;
  cursor: pointer;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(18px, 4vw, 56px);
  color: var(--ink);
  background: var(--surface);
  border-top: 1px solid var(--line);
}

.site-footer div {
  display: grid;
  gap: 2px;
}

.site-footer strong {
  font-size: 1.55rem;
}

.site-footer span,
.site-footer a {
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: none;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 24px;
  background: rgba(7, 6, 5, 0.92);
  backdrop-filter: blur(12px);
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  display: grid;
  max-width: min(720px, calc(100vw - 96px));
  max-height: calc(100svh - 80px);
  gap: 18px;
}

.lightbox-art {
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: min(70svh, 720px);
  overflow: hidden;
  background: var(--surface);
}

.lightbox-art img {
  display: block;
  width: auto;
  max-width: min(76vw, 900px);
  height: auto;
  max-height: min(70svh, 720px);
  object-fit: contain;
}

.lightbox-caption {
  color: var(--white);
  text-align: center;
}

.lightbox-caption p {
  margin: 0 0 4px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.4rem;
}

.lightbox-caption span {
  color: rgba(255, 253, 249, 0.72);
  font-size: 0.94rem;
}

.lightbox-close,
.lightbox-nav {
  border: 1px solid rgba(255, 253, 249, 0.38);
  color: var(--white);
  background: rgba(255, 253, 249, 0.06);
  cursor: pointer;
}

.lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  min-height: 40px;
  padding: 8px 12px;
}

.lightbox-nav {
  width: 44px;
  height: 56px;
  font-size: 1.5rem;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 520ms ease, transform 520ms ease;
  transition-delay: var(--delay, 0ms);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.legal-main {
  padding-top: 90px;
}

.legal-hero {
  background: linear-gradient(180deg, var(--paper), var(--surface));
  border-bottom: 1px solid var(--line);
}

.legal-hero .section-wrap {
  padding-top: clamp(70px, 9vw, 120px);
  padding-bottom: clamp(44px, 7vw, 86px);
}

.legal-hero h1 {
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.6rem, 6vw, 5rem);
}

.legal-content {
  max-width: 900px;
}

.legal-content h2,
.legal-content h3 {
  margin-top: 38px;
  margin-bottom: 14px;
  font-family: Georgia, "Times New Roman", serif;
}

.legal-content h2:first-child,
.legal-content h3:first-child {
  margin-top: 0;
}

.legal-content p,
.legal-content li {
  color: var(--muted);
}

.legal-content a {
  color: var(--accent);
  font-weight: 750;
}

.legal-content ul {
  padding-left: 20px;
}

@media (max-width: 1100px) {
  .gallery-grid,
  .exhibition-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .nav-toggle {
    display: grid;
  }

  .site-nav {
    position: fixed;
    inset: 72px 14px auto;
    display: grid;
    gap: 2px;
    border: 1px solid var(--line);
    border-radius: 0;
    padding: 10px;
    color: var(--ink);
    background: var(--white);
    box-shadow: var(--shadow);
    transform: translateY(-16px);
    opacity: 0;
    pointer-events: none;
    transition: transform 180ms ease, opacity 180ms ease;
  }

  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav a {
    padding: 12px 10px;
  }

  .site-nav a:hover,
  .site-nav a:focus-visible {
    background: var(--paper);
  }

  .site-nav a::after {
    display: none;
  }

  .hero {
    min-height: 84svh;
  }

  .hero-media {
    background-position: 54% center;
  }

  .hero-shade {
    background:
      linear-gradient(90deg, rgba(20, 17, 15, 0.76), rgba(42, 36, 32, 0.38)),
      linear-gradient(0deg, rgba(42, 36, 32, 0.46), transparent 45%);
  }

  .intro,
  .section-heading,
  .artist,
  .contact {
    grid-template-columns: 1fr;
  }

  .section-heading .eyebrow {
    margin-bottom: -6px;
  }

  .gallery-grid,
  .exhibition-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lightbox {
    gap: 10px;
    padding: 18px;
  }
}

@media (max-width: 560px) {
  .site-header {
    padding: 14px 16px;
  }

  .brand {
    font-size: 1.05rem;
  }

  .hero-content {
    width: min(100% - 28px, 1120px);
    padding-top: 88px;
  }

  .hero-actions,
  .hero-actions .button {
    width: 100%;
  }

  .gallery-grid,
  .exhibition-grid {
    grid-template-columns: 1fr;
  }

  .gallery-item {
    display: grid;
    grid-template-columns: minmax(118px, 0.42fr) minmax(0, 1fr);
    gap: 0 16px;
  }

  .gallery-overlay {
    display: none;
  }

  .art-canvas {
    aspect-ratio: 1;
  }

  .work-info {
    margin-top: 0;
  }

  .work-info h3 {
    min-height: 0;
  }

  .work-info dl {
    margin-top: 12px;
  }

  .work-info dl div {
    grid-template-columns: 54px 1fr;
  }

  .contact-form .button {
    width: 100%;
  }

  .lightbox-content {
    max-width: calc(100vw - 68px);
  }

  .lightbox-art img {
    width: 100%;
    height: auto;
  }

  .lightbox-nav {
    width: 34px;
    height: 48px;
  }
}
