:root {
  --bg-gradient-start: #050608;
  --bg-gradient-end: #0b1517;
  --surface-dark: #10181d;
  --surface-soft: #151f26;
  --accent: #f4d74d;
  --accent-dark: #d5b73c;
  --accent-soft: #2fc3a2;
  --text-main: #f5f7f8;
  --text-muted: #9aa4aa;
  --card-bg: #151f26;
  --border-soft: #26333b;
  --shadow-soft: 0 18px 38px rgba(0, 0, 0, 0.55);
  --radius-pill: 999px;
  --transition-fast: 160ms ease-out;
}

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

body {
  font-family: 'Space Grotesk', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(circle at top right, var(--bg-gradient-end), var(--bg-gradient-start));
  padding: 1.5rem 4vw 3rem;
  color: var(--text-main);
  min-height: 100vh;
}

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

.nav {
  max-width: 1120px;
  margin: 0 auto 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: 'DM Mono', monospace;
  color: var(--text-main);
}

.nav-left {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
}

.nav-logo-tag {
  font-size: .8rem;
  padding: .15rem .6rem;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-pill);
  background: rgba(15, 26, 32, 0.9);
  color: var(--accent);
  backdrop-filter: blur(6px);
}

.nav-right {
  display: flex;
  gap: 1.5rem;
  font-size: .85rem;
  align-items: center;
}

.nav-link {
  position: relative;
  cursor: pointer;
  color: var(--text-muted);
}

.nav-link::after {
  content: "";
  width: 0;
  height: 2px;
  position: absolute;
  left: 0;
  bottom: -4px;
  background: var(--accent);
  border-radius: 8px;
  transition: width var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-cta {
  padding: .45rem .95rem;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: #111;
  border: 1px solid rgba(0, 0, 0, .4);
  box-shadow: 0 6px 15px rgba(0, 0, 0, .45);
  cursor: pointer;
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.nav-cta:hover {
  transform: translateY(-1px);
  background: var(--accent-dark);
  box-shadow: 0 10px 22px rgba(0, 0, 0, .6);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle-bar {
  width: 20px;
  height: 2px;
  background: #f5f5f5;
  margin: 4px 0;
  border-radius: 20px;
}

.hero {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 3rem;
  align-items: center;
}

.hero-copy {
  max-width: 560px;
}

.hero-kicker {
  font-family: 'DM Mono', monospace;
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-soft);
  margin-bottom: .75rem;
}

.hero-title {
  font-size: clamp(2.4rem, 3.2vw + 1.5rem, 3.6rem);
  margin-bottom: 1rem;
  line-height: 1.05;
}

.accent {
  color: var(--accent);
}

.hero-subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 1.8rem;
  line-height: 1.5;
}

.hero-actions {
  display: flex;
  gap: .8rem;
  flex-wrap: wrap;
  margin-bottom: 1.6rem;
}

.btn {
  border-radius: var(--radius-pill);
  padding: .75rem 1.5rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .9rem;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: #111;
  box-shadow: 0 10px 26px rgba(0, 0, 0, .55);
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.btn-ghost {
  background: rgba(15, 26, 32, 0.9);
  border: 1px solid var(--border-soft);
  color: var(--text-main);
}

.btn-ghost:hover {
  border-color: var(--accent-soft);
  box-shadow: 0 10px 22px rgba(0, 0, 0, .5);
  transform: translateY(-1px);
}

.newsletter-label {
  font-size: .8rem;
  font-family: 'DM Mono', monospace;
  margin-bottom: .3rem;
  color: var(--text-muted);
}

.newsletter {
  display: flex;
  gap: .55rem;
  flex-wrap: wrap;
  align-items: stretch;
}

.newsletter input {
  flex: 1 1 220px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-soft);
  padding: .75rem 1.1rem;
  background: var(--surface-dark);
  color: var(--text-main);
  font-size: .9rem;
  outline: none;
}

.newsletter button {
  border-radius: var(--radius-pill);
  padding: .75rem 1.3rem;
  background: var(--accent);
  border: none;
  color: #111;
  cursor: pointer;
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.hero-gallery {
  max-width: 520px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.4rem;
  align-items: stretch;
}

.polaroid {
  position: relative;
  width: 100%;
  background: var(--card-bg);
  padding: .6rem .6rem 1.1rem;
  border-radius: 10px;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform .2s ease-out, box-shadow .2s ease-out;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.polaroid img {
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  filter: contrast(1.25) saturate(0.7) brightness(1.08) sepia(0.25) hue-rotate(-5deg);
}

.polaroid::after {
  content: "";
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  right: 0.6rem;
  bottom: 1.1rem;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.4'/%3E%3C/svg%3E");
  opacity: 0.15;
  mix-blend-mode: overlay;
  pointer-events: none;
  border-radius: 8px;
  z-index: 1;
}

.polaroid-caption {
  font-size: .7rem;
  font-family: 'DM Mono', monospace;
  margin-top: .5rem;
  color: var(--text-muted);
}

.polaroid:nth-child(1) { transform: rotate(-2deg); }
.polaroid:nth-child(2) { transform: rotate(1.5deg); }
.polaroid:nth-child(3) { transform: rotate(2deg); }
.polaroid:nth-child(4) { transform: rotate(-1.5deg); }

.polaroid:hover {
  transform: translateY(-8px) scale(1.02) rotate(0deg);
  box-shadow: 0 30px 60px rgba(0, 0, 0, .65);
  z-index: 20;
  border-color: var(--accent-soft);
}

.past-editions {
  max-width: 1120px;
  margin: 4rem auto 0;
  padding: 3rem 0;
}

.past-editions-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.past-editions-title {
  font-size: clamp(2rem, 2.5vw + 1rem, 2.8rem);
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.past-editions-subtitle {
  font-family: 'DM Mono', monospace;
  font-size: 0.9rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.table-wrapper {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid var(--border-soft);
  background: var(--surface-dark);
  box-shadow: var(--shadow-soft);
}

.editions-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'DM Mono', monospace;
  font-size: 0.9rem;
}

.editions-table thead {
  background: var(--surface-soft);
  border-bottom: 2px solid var(--accent-soft);
}

.editions-table th {
  padding: 1rem 1.5rem;
  text-align: left;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
}

.editions-table tbody tr {
  border-bottom: 1px solid var(--border-soft);
  transition: background-color var(--transition-fast);
}

.editions-table tbody tr:last-child {
  border-bottom: none;
}

.editions-table tbody tr:hover {
  background: rgba(47, 195, 162, 0.05);
}

.editions-table td {
  padding: 1.2rem 1.5rem;
  color: var(--text-main);
}

.editions-table td:first-child {
  color: var(--accent-soft);
  font-weight: 500;
}

footer {
  max-width: 1120px;
  margin: 3rem auto 0;
  border-top: 1px dashed var(--border-soft);
  padding-top: 1rem;
  font-family: 'DM Mono', monospace;
  font-size: .75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  color: var(--text-muted);
}

footer a {
  text-decoration: underline dotted;
}

.footer-right {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.footer-right a {
  opacity: .8;
  transition: opacity .15s ease-in-out, transform .15s ease-in-out;
  text-decoration: none;
  color: var(--text-main);
}

.footer-right a:hover {
  opacity: 1;
  transform: translateY(-2px);
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, .55);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  backdrop-filter: blur(4px);
  z-index: 1000;
}

.modal.open {
  display: flex;
}

.modal-content {
  width: min(800px, 90vw);
  height: min(90vh, 600px);
  background: var(--surface-dark);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, .75);
  position: relative;
  animation: modal-enter .25s ease-out;
  border: 1px solid var(--border-soft);
}

@keyframes modal-enter {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-content iframe {
  width: 100%;
  height: 100%;
}

.modal-close {
  position: absolute;
  top: 8px;
  right: 10px;
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  opacity: .7;
  padding: 4px;
  color: var(--text-main);
}

.modal-close:hover {
  opacity: 1;
}

@media (max-width: 960px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .hero-gallery {
    max-width: 420px;
  }

  .newsletter,
  .hero-actions {
    justify-content: flex-start;
  }

  .hero-copy {
    margin: 0 auto;
  }
}

@media (max-width: 720px) {
  .nav-right {
    position: absolute;
    top: 60px;
    right: 4vw;
    background: var(--surface-dark);
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    border-radius: 12px;
    display: none;
    z-index: 10;
    border: 1px solid var(--border-soft);
  }

  .nav-right.open {
    display: flex;
  }

  .nav-toggle {
    display: block;
  }

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

  .polaroid {
    width: 100%;
  }

  footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .past-editions {
    margin: 3rem auto 0;
    padding: 2rem 0;
  }

  .past-editions-header {
    margin-bottom: 2rem;
  }

  .table-wrapper {
    border: none;
    background: transparent;
    box-shadow: none;
  }

  .editions-table,
  .editions-table thead,
  .editions-table tbody,
  .editions-table tr,
  .editions-table td,
  .editions-table th {
    display: block;
  }

  .editions-table thead {
    display: none;
  }

  .editions-table tbody tr {
    margin-bottom: 1.5rem;
    background: var(--surface-dark);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    padding: 1rem;
    box-shadow: var(--shadow-soft);
  }

  .editions-table tbody tr:last-child {
    margin-bottom: 0;
  }

  .editions-table td {
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .editions-table td:last-child {
    border-bottom: none;
  }

  .editions-table td::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.08em;
  }

  .editions-table td:first-child {
    color: var(--text-main);
  }
}
