/* ==========================================================================
   DreamSpace Electronica Fest – static rebuild
   ========================================================================== */

/* Fonts (self-hosted) ----------------------------------------------------- */
@font-face {
  font-family: "Oxygen";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/oxygen-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Oxygen";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/oxygen-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Oxygen";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/oxygen-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Oxygen";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/oxygen-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "PT Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/ptserif-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "PT Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/ptserif-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Tokens ------------------------------------------------------------------ */
:root {
  --color-bg: #010066;
  --color-text: #fff;
  --color-link: #ff950a;
  --color-box: rgba(0, 0, 0, 0.25);
  --color-line: rgba(255, 255, 255, 0.18);
  --color-divider: rgb(214, 214, 214);
  --font-base: "Oxygen", "Helvetica Neue", Arial, sans-serif;
  --font-quote: "PT Serif", Georgia, serif;
  --radius: 0.3125rem;
  --page-width: 72.5rem;
  --gutter: 2rem;
}

/* Base -------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--color-bg) url("../img/background-1600.jpg") no-repeat center top;
  background-image: image-set(url("../img/background-1600.webp") type("image/webp"), url("../img/background-1600.jpg") type("image/jpeg"));
  color: var(--color-text);
  font: 400 1.15rem/1.7 var(--font-base);
  overflow-wrap: break-word;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
  border: 0;
}

iframe {
  max-width: 100%;
  border: 0;
}

a {
  color: var(--color-link);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
}

p {
  margin: 0 0 1.2em;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 0.4em;
  line-height: 1.25;
  font-weight: 700;
}

h2 {
  font-size: 2.25em;
  text-transform: uppercase;
}

h3 {
  font-size: 1.25em;
}

h4 {
  font-size: 1.15em;
}

blockquote {
  position: relative;
  margin: 0 0 1.2em;
  padding: 0.8em 2em 1em;
  font: 1em/1.25 var(--font-quote);
}

blockquote::before {
  content: "\201C";
  position: absolute;
  margin: -0.2em 0 0 -0.65em;
  font: 2.8em/1 Times, serif;
}

blockquote p:last-child {
  margin-bottom: 0;
}

.visually-hidden {
  position: absolute !important;
  width: 0.0625rem;
  height: 0.0625rem;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Layout ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  margin-bottom: 3.75rem;
}

.section--intro {
  margin-bottom: 3.5rem;
}

.cols {
  display: flex;
  gap: var(--gutter);
}

.cols > * {
  flex: 1 1 0;
  min-width: 0;
}

.cols--1-2 > :first-child {
  flex-grow: 1;
}

.cols--1-2 > :last-child {
  flex-grow: 2;
}

.cols--2-1 > :first-child {
  flex-grow: 2;
}

.cols--2-1 > :last-child {
  flex-grow: 1;
}

/* Header ------------------------------------------------------------------ */
.site-header {
  padding-top: 1.875rem;
  text-align: center;
}

.site-logo {
  margin: 0 0 0.8em;
}

.site-logo img {
  width: 37.875rem;
}

.site-header h2 {
  font-size: 1.5em;
}

.festival-date {
  margin-bottom: 0.4em;
  font-size: 1.5em;
  text-align: center;
}

.festival-date h2 {
  font-size: 1.75em;
}

/* Box heading --------------------------------------------------------------- */
.box {
  margin: 1.25rem 0 1.875rem;
  padding: 1.25rem;
  border-radius: var(--radius);
  background: var(--color-box);
  text-align: center;
}

.box h3 {
  margin: 0;
  font-size: 1.44em;
  line-height: 1.7;
  text-transform: uppercase;
}

.intro {
  margin: 0 1.875rem;
}

/* Artists ----------------------------------------------------------------- */
.artist + .artist {
  margin-top: 4.375rem;
  padding-top: 4.375rem;
  border-top: 0.0625rem solid var(--color-line);
}

.artist__head {
  text-align: center;
}

.artist__text {
  margin-top: 1.5625rem;
}

.artist__link {
  margin-top: 1.5625rem;
  font-size: 1.25em;
  text-align: center;
}

.artist__link a:hover {
  text-decoration: none;
}

.artist__image img {
  width: 100%;
}

.artist__image .artist__link {
  margin-top: 2.5rem;
}

/* Two-click embeds (Vimeo, OpenStreetMap) --------------------------------- */
.embed {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: #000;
}

.embed--video {
  margin-top: 1.875rem;
  aspect-ratio: 16 / 9;
}

.embed--map {
  height: 31.25rem;
  background: #1a1a5e;
}

.embed > picture img,
.embed > iframe,
.embed > .embed__map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.embed > picture img {
  object-fit: cover;
  filter: brightness(0.45) saturate(0.9);
}

.embed__consent {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.875rem;
  padding: 1.25rem;
  text-align: center;
}

.embed__play {
  width: 4.625rem;
  height: 4.625rem;
  border: 0.1875rem solid #fff;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
}

.embed__play::after {
  content: "";
  display: block;
  margin: 1.1875rem 0 0 1.6875rem;
  border-style: solid;
  border-width: 1rem 0 1rem 1.625rem;
  border-color: transparent transparent transparent #fff;
}

.embed__title {
  max-width: 46em;
  margin: 0;
  font-weight: 700;
  line-height: 1.35;
}

.embed__notice {
  max-width: 34em;
  margin: 0;
  font-size: 0.8em;
  line-height: 1.5;
  text-shadow: 0 0.0625rem 0.1875rem rgba(0, 0, 0, 0.8);
}

.embed__btn {
  padding: 0.625rem 1.625rem;
  border: 0;
  border-radius: 62.4375rem;
  background: var(--color-link);
  color: #000;
  font: 700 0.9em/1.4 var(--font-base);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.embed__btn:hover,
.embed__btn:focus-visible {
  background: #ffb04a;
  transform: translateY(-0.0625rem);
}

.embed__btn:focus-visible {
  outline: 0.125rem solid #fff;
  outline-offset: 0.1875rem;
}

.embed__credit {
  position: absolute;
  right: 0;
  bottom: 0;
  padding: 0.125rem 0.375rem;
  background: rgba(255, 255, 255, 0.75);
  color: #333;
  font-size: 0.6875rem;
  line-height: 1.4;
}

.embed.is-loaded .embed__consent,
.embed.is-loaded > picture,
.embed.is-loaded .embed__credit {
  display: none;
}

/* Gallery ----------------------------------------------------------------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.875rem;
  margin: 0;
  padding: 0 1.25rem;
  list-style: none;
}

.gallery a {
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
}

.gallery img {
  width: 100%;
  aspect-ratio: 300 / 212;
  object-fit: cover;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.gallery a:hover img,
.gallery a:focus-visible img {
  transform: scale(1.05);
  opacity: 0.85;
}

/* Lightbox ---------------------------------------------------------------- */
.lightbox {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--color-text);
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.9);
}

.lightbox__figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  margin: 0;
  padding: 3.125rem 4.375rem;
}

.lightbox__figure img {
  max-height: calc(100vh - 8.75rem);
  object-fit: contain;
  box-shadow: 0 0 1.875rem rgba(0, 0, 0, 0.6);
}

.lightbox__figure figcaption {
  margin-top: 0.75rem;
  font-size: 0.85em;
  opacity: 0.85;
}

.lightbox__btn {
  position: absolute;
  padding: 0.625rem 1rem;
  border: 0;
  background: none;
  color: #fff;
  font: 400 2.5rem/1 var(--font-base);
  cursor: pointer;
  opacity: 0.75;
}

.lightbox__btn:hover,
.lightbox__btn:focus-visible {
  opacity: 1;
}

.lightbox__close {
  top: 0.375rem;
  right: 0.375rem;
}

.lightbox__prev,
.lightbox__next {
  top: 50%;
  transform: translateY(-50%);
  font-size: 3.5rem;
}

.lightbox__prev {
  left: 0.375rem;
}

.lightbox__next {
  right: 0.375rem;
}

/* Map --------------------------------------------------------------------- */
.embed--map .leaflet-popup-content {
  color: #333;
  font: 400 0.875rem/1.5 var(--font-base);
}

.embed--map .leaflet-popup-content a {
  color: #0078a8;
}

.map-link {
  margin-top: 0.5em;
  font-size: 0.85em;
}

.contact {
  margin-top: 2.5rem;
  text-align: center;
}

/* Footer ------------------------------------------------------------------ */
.site-footer {
  padding-bottom: 1.25rem;
  font-size: 0.85em;
  text-align: center;
}

.site-footer hr {
  margin: 1.5em 0;
  border: 0;
  border-top: 0.0625rem solid var(--color-divider);
}

.site-footer p {
  margin: 0 0 0.5em;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4em 1.6em;
}

/* Legal pages ------------------------------------------------------------- */
.site-header--small {
  padding-bottom: 0.625rem;
}

.site-header--small .site-logo img {
  width: 23.75rem;
}

.legal {
  max-width: 51.25rem;
  margin: 0 auto 3.75rem;
  padding: 1.875rem 2.5rem 2.5rem;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.3);
  font-size: 0.92em;
}

.legal h1 {
  margin-bottom: 0.8em;
  font-size: 2em;
  text-transform: uppercase;
}

.legal h2 {
  margin-top: 1.8em;
  font-size: 1.35em;
  text-transform: none;
}

.legal h3 {
  margin-top: 1.4em;
  font-size: 1.1em;
}

.legal ul {
  margin: 0 0 1.2em;
  padding-left: 1.3em;
}

.legal li {
  margin-bottom: 0.4em;
}

.legal .back-link {
  margin-top: 2em;
}

/* Responsive -------------------------------------------------------------- */
@media (max-width: 56.25em) {
  .gallery {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 47.5em) {
  body {
    font-size: 1rem;
  }

  .container {
    padding: 0 1rem;
  }

  h2 {
    font-size: 1.9em;
  }

  .cols {
    flex-direction: column;
    gap: 1.875rem;
  }

  .intro {
    margin: 0;
  }

  .box h3 {
    font-size: 1.15em;
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.625rem;
    padding: 0;
  }

  .artist + .artist {
    margin-top: 3.125rem;
    padding-top: 3.125rem;
  }

  .embed--map {
    height: 23.75rem;
  }

  .embed__play,
  .embed__title {
    display: none;
  }

  .embed__notice {
    font-size: 0.75em;
  }

  .legal {
    padding: 1.25rem;
  }

  .lightbox__figure {
    padding: 3.125rem 0.625rem;
  }

  .lightbox__prev,
  .lightbox__next {
    top: auto;
    bottom: 0.625rem;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gallery img {
    transition: none;
  }
}
