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

body {
  background: #0a0a0a;
  color: white;
  font-family: Roboto, sans-serif;
  min-height: 100vh;
}

/* ---------- Page header (mono eyebrow + italic serif title) ----------
   Echoes the atlas-head pattern (atlas.css) and the year-rail active
   item so the global page chrome speaks the same language as the
   interior views. */

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

.page-header a {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 400;
  font-size: 0.66rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(255,184,107,0.62);
  text-decoration: none;
  padding: 4px 2px;
  transition: color 0.25s ease;
}

.page-header a::before,
.page-header a::after {
  color: rgba(255,184,107,0.3);
  letter-spacing: 0;
}
.page-header a::before { content: '—'; margin-right: 14px; }
.page-header a::after  { content: '—'; margin-left: 14px; }

.page-header a:hover { color: #ffb86b; }

.page-title {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 3.6rem;
  letter-spacing: 0.005em;
  line-height: 1;
  color: rgba(255,244,221,0.97);
  margin-top: 16px;
}

/* ---------- Sort controls (mono tabs with amber underline) ----------
   Replaces the sans pill buttons. Active tab gets a glowing amber rule
   that matches the year-rail progress indicator. Faint amber gradient
   rules flank the pair to echo the .selection-rule treatment. */

.sort-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 28px;
  padding: 26px 24px 18px;
}

.sort-controls::before,
.sort-controls::after {
  content: '';
  flex: 1 1 auto;
  max-width: 140px;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(255,184,107,0.28),
    transparent);
}

.sort-btn {
  position: relative;
  background: none;
  border: none;
  padding: 6px 2px 8px;
  color: rgba(255,255,255,0.38);
  font-family: 'JetBrains Mono', monospace;
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.3s ease;
}

.sort-btn::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 0;
  height: 1px;
  background: #ffb86b;
  box-shadow: 0 0 8px rgba(255,184,107,0.65);
  transform: translateX(-50%);
  transition: width 0.4s cubic-bezier(0.2, 0.8, 0.2, 1),
              background-color 0.3s ease,
              box-shadow 0.3s ease;
}

.sort-btn:hover { color: rgba(255,244,221,0.92); }
.sort-btn:hover::after {
  width: 28%;
  background: rgba(255,184,107,0.4);
  box-shadow: none;
}

.sort-btn.active { color: #fff4dd; }
.sort-btn.active::after {
  width: 100%;
  background: #ffb86b;
  box-shadow: 0 0 8px rgba(255,184,107,0.65);
}

.gallery-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 8px 24px 80px;
}

@media (max-width: 1024px) {
  .gallery-container { padding: 8px 16px 60px; }
}

@media (max-width: 600px) {
  .gallery-container { padding: 8px 12px 48px; }
  .page-header { padding: 36px 0 4px; }
  .page-header a { font-size: 0.56rem; letter-spacing: 0.22em; }
  .page-header a::before { margin-right: 8px; }
  .page-header a::after  { margin-left: 8px; }
  .page-title { font-size: 2.4rem; margin-top: 12px; }
  .sort-controls { gap: 18px; padding: 20px 16px 14px; }
  .sort-controls::before,
  .sort-controls::after { max-width: 60px; }
  .sort-btn { font-size: 0.62rem; letter-spacing: 0.2em; }
}
