/* Vidalux palette gallery — shared styles */

:root {
  --bg: #17150f;
  --bg-raised: #1f1c15;
  --text: #f3ede0;
  --text-dim: #b8afa0;
  --hairline: #322d21;
  --accent: #c9a86a;
  --accent-dim: #8a7550;
  --max-width: 1120px;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: Georgia, "Times New Roman", Times, serif;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--text);
}

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

a:hover {
  color: var(--text);
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(23, 21, 15, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--hairline);
}

.topbar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.topbar-label {
  font-family: Georgia, "Times New Roman", Times, serif;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.topbar-links {
  display: flex;
  gap: 20px;
  font-size: 0.92rem;
}

.topbar-links a {
  color: var(--text-dim);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}

.topbar-links a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ---------- Landing page ---------- */

.landing {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
}

.landing-inner {
  max-width: 640px;
  text-align: center;
}

.landing h1 {
  font-size: clamp(2rem, 4vw, 2.75rem);
  margin: 0 0 24px;
  line-height: 1.25;
}

.landing p {
  color: var(--text-dim);
  font-size: 1.05rem;
  margin: 0 0 40px;
}

.choice-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 18px 40px;
  border: 1px solid var(--accent-dim);
  border-radius: 2px;
  color: var(--text);
  font-family: Georgia, "Times New Roman", Times, serif;
  font-size: 1.05rem;
  letter-spacing: 0.03em;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.btn:hover {
  border-color: var(--accent);
  background: var(--bg-raised);
  color: var(--accent);
}

/* ---------- Collection pages ---------- */

.page-header {
  padding: 56px 0 24px;
  text-align: center;
}

.page-header h1 {
  font-size: clamp(1.7rem, 3.2vw, 2.2rem);
  margin: 0 0 12px;
}

.page-header p {
  color: var(--text-dim);
  max-width: 560px;
  margin: 0 auto;
}

section.group {
  padding: 32px 0 8px;
}

section.group h2 {
  font-size: 1.15rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 12px;
  margin: 0 0 24px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  padding-bottom: 16px;
}

.tile {
  cursor: pointer;
  border: none;
  background: none;
  padding: 0;
  text-align: left;
  color: inherit;
  font: inherit;
}

.tile img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--bg-raised);
  border-radius: 2px;
  transition: opacity 0.2s ease;
}

.tile:hover img {
  opacity: 0.85;
}

.tile figcaption {
  margin-top: 10px;
  font-size: 0.88rem;
  color: var(--text-dim);
  line-height: 1.4;
}

.tile:hover figcaption {
  color: var(--text);
}

footer.sitefoot {
  padding: 48px 24px 64px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* ---------- Lightbox ---------- */

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(10, 9, 6, 0.94);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}

.lightbox.open {
  display: flex;
}

.lightbox-figure {
  max-width: 92vw;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.lightbox-figure img {
  max-width: 92vw;
  max-height: 78vh;
  width: auto;
  height: auto;
  display: block;
  border-radius: 2px;
}

.lightbox-caption {
  color: var(--text-dim);
  font-size: 0.9rem;
  text-align: center;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: fixed;
  background: none;
  border: 1px solid var(--hairline);
  color: var(--text);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  padding: 12px 16px;
  border-radius: 2px;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.lightbox-close {
  top: 20px;
  right: 20px;
}

.lightbox-prev {
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}

/* ---------- Pairs (internal review) page ---------- */

.pairs-note {
  color: var(--text-dim);
  font-size: 0.9rem;
  padding: 8px 0 32px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 32px;
}

.pair-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding: 28px 0;
  border-bottom: 1px solid var(--hairline);
  align-items: start;
}

.pair-row h3 {
  grid-column: 1 / -1;
  font-size: 1.05rem;
  margin: 0 0 4px;
  color: var(--text);
}

.pair-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pair-col img {
  width: 100%;
  height: auto;
  border-radius: 2px;
  display: block;
}

.pair-col span {
  font-size: 0.8rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pair-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .grid {
    grid-template-columns: 1fr;
  }
  .choice-buttons {
    flex-direction: column;
    align-items: center;
  }
  .lightbox-prev,
  .lightbox-next {
    padding: 10px 14px;
    font-size: 1.2rem;
  }
}
