/* 12th Main — design tokens + section layout (single source for brand colors) */

/* === Tailwind palette overrides (utilities use var(--color-primary-*)) === */
:root {
  /* Primary / gold: brighter (still slightly toned vs. very first iteration) */
  --color-primary: oklch(74% 0.122 84);
  --color-primary-50: oklch(98.5% 0.024 88);
  --color-primary-100: oklch(96.2% 0.042 87);
  --color-primary-200: oklch(92.5% 0.065 86);
  --color-primary-300: oklch(86.5% 0.088 85);
  --color-primary-400: oklch(79% 0.105 84);
  --color-primary-500: oklch(74% 0.122 84);
  --color-primary-600: oklch(65% 0.11 83);
  --color-primary-700: oklch(55% 0.098 82);
  --color-primary-800: oklch(45% 0.082 80);
  --color-primary-900: oklch(37% 0.068 78);
  --color-primary-950: oklch(28% 0.05 76);

  --color-indigo-50: var(--color-primary-50);
  --color-indigo-100: var(--color-primary-100);
  --color-indigo-200: var(--color-primary-200);
  --color-indigo-300: var(--color-primary-300);
  --color-indigo-400: var(--color-primary-400);
  --color-indigo-500: var(--color-primary-500);
  --color-indigo-600: var(--color-primary-600);
  --color-indigo-700: var(--color-primary-700);
  --color-indigo-800: var(--color-primary-800);
  --color-indigo-900: var(--color-primary-900);
  --color-indigo-950: var(--color-primary-950);

  /* === Semantic brand (use in custom CSS / inline var() only) === */
  --brand-surface-deep: #050505;
  --brand-surface-mid: #080808;
  --brand-text-on-dark: #ffffff;
  --brand-text-muted: #d4cfc4;
  --brand-text-hero-sub: #e7e9ee;
  --brand-text-hero-eyebrow: #f3e8bc;
  --brand-text-hero-secondary-cta: #faf3e0;
  --brand-gold: #d4af37;
  --brand-gold-kicker: #c9a227;
  --brand-cta-on-gold: #0a0a0a;
  /* Gold for borders / overlays — close to classic band gold */
  --brand-gold-rgb: 208 176 72;
  --brand-gold-border-eyebrow: rgb(var(--brand-gold-rgb) / 0.48);
  --brand-gold-border-cta: rgb(var(--brand-gold-rgb) / 0.62);
  --brand-gold-border-image: rgb(var(--brand-gold-rgb) / 0.3);
  --brand-gold-border-card: rgb(var(--brand-gold-rgb) / 0.24);
  --brand-gold-border-tile: rgb(var(--brand-gold-rgb) / 0.22);
  --brand-gold-scrollbar: rgb(var(--brand-gold-rgb) / 0.36);
  --brand-card-bg: rgb(255 255 255 / 0.04);
  --brand-tile-bg: rgb(255 255 255 / 0.03);
  --brand-hero-secondary-bg: rgb(0 0 0 / 0.35);
  --brand-shadow-deep: rgb(0 0 0 / 0.28);
  --brand-shadow-card: rgb(0 0 0 / 0.22);
  --brand-shadow-tile: rgb(0 0 0 / 0.24);
  --brand-hero-gradient: linear-gradient(
    105deg,
    rgb(0 0 0 / 0.88) 0%,
    rgb(8 6 2 / 0.78) 38%,
    rgb(0 0 0 / 0.35) 100%
  );
  --brand-section-pad-y: 88px;
  --brand-black: #000000;
  --brand-header-border: rgb(var(--brand-gold-rgb) / 0.34);
  --brand-footer-border: rgb(var(--brand-gold-rgb) / 0.3);
  --brand-text-legal: rgb(196 188 178 / 0.72);
  --brand-wordmark-gradient: linear-gradient(
    115deg,
    #fff9d6 0%,
    #edd472 18%,
    #d4af37 38%,
    #9a7418 58%,
    #2a1f0a 82%,
    #0a0a0a 100%
  );
  --brand-wordmark-gradient-hover: linear-gradient(
    115deg,
    #fffce8 0%,
    #f0d978 22%,
    #e4c34a 42%,
    #b8922a 62%,
    #3d2e08 85%,
    #050505 100%
  );
}

html {
  scroll-behavior: smooth;
}

/* Site-wide repeating tile (see baseof.html). Single repeat — seamless pattern; overlays add depth without hiding seams. */
html.has-site-bg-pattern {
  background-color: #030303;
  background-image:
    radial-gradient(ellipse 130% 60% at 50% 0%, rgb(var(--brand-gold-rgb) / 0.085), transparent 60%),
    linear-gradient(
      180deg,
      rgb(0 0 0 / 0.2) 0%,
      transparent 32%,
      transparent 68%,
      rgb(0 0 0 / 0.38) 100%
    ),
    var(--site-bg-tile);
  background-repeat: no-repeat, no-repeat, repeat;
  background-size: 100% 100%, 100% 100%, auto;
  background-position: 0 0, 0 0, 0 0;
  background-attachment: scroll;
  min-height: 100%;
}

html.has-site-bg-pattern body.site-page {
  background-color: transparent;
}

/* Let the pattern show through slightly under solid chrome / sections */
html.has-site-bg-pattern .site-section {
  background: rgb(5 5 5 / 0.92);
}
html.has-site-bg-pattern .site-section--alt {
  background: rgb(8 8 8 / 0.92);
}
html.has-site-bg-pattern .site-header {
  background: rgb(5 5 5 / 0.94);
}
html.has-site-bg-pattern .site-footer {
  background: rgb(5 5 5 / 0.94);
}

/* --- Site header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--brand-surface-deep);
  color: var(--brand-text-muted);
  border-bottom: 1px solid var(--brand-header-border);
}
/* Header grid: wordmark | centered nav | social + mobile menu */
.site-header__shell {
  max-width: 100%;
}
.site-header__grid {
  display: grid;
  align-items: center;
  gap: 0.35rem 0.75rem;
  padding: 0.625rem 0;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "brand actions"
    "nav nav";
}
@media (min-width: 768px) {
  .site-header__grid {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    grid-template-areas: "brand nav social";
    padding: 0.75rem 0;
    gap: 0.75rem 1rem;
  }
}
.site-header__cell--brand {
  grid-area: brand;
  justify-self: start;
  min-width: 0;
}
.site-header__cell--nav {
  grid-area: nav;
  width: 100%;
}
@media (min-width: 768px) {
  .site-header__cell--nav {
    width: auto;
    justify-self: center;
    max-width: min(100%, 42rem);
  }
}
.site-header__cell--social {
  grid-area: actions;
  justify-self: end;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.15rem;
}
@media (min-width: 768px) {
  .site-header__cell--social {
    grid-area: social;
  }
}
.site-header__social {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.05rem;
}
.site-header__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem;
  border-radius: 0.5rem;
  color: var(--brand-gold-kicker);
  line-height: 0;
  text-decoration: none;
}
.site-header__social-link:hover,
.site-header__social-link:focus-visible {
  color: var(--brand-gold);
  background: rgb(var(--brand-gold-rgb) / 0.14);
  outline: none;
}
.site-header__social-icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
}
@media (min-width: 768px) {
  .site-header__social-icon {
    width: 1.35rem;
    height: 1.35rem;
  }
}
.site-header__dropdown-panel {
  right: 0;
}

.site-header__logo {
  display: inline-flex;
  align-items: center;
  align-self: center;
  flex-shrink: 0;
  padding: 0.25rem 0.375rem;
  line-height: 1.15;
}

/* Text wordmark: “12” + note SVG + “ MAIN” — gradient on text only (SVG note stays solid gold) */
.site-header__wordmark {
  display: inline-flex;
  align-items: baseline;
  font-weight: 800;
  font-size: clamp(1.45rem, 5.2vw, 2.45rem);
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.site-header__wordmark-grad {
  background: var(--brand-wordmark-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.site-header__logo:hover .site-header__wordmark-grad,
.site-header__logo:focus .site-header__wordmark-grad {
  background: var(--brand-wordmark-gradient-hover);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.site-header__wordmark-12 {
  letter-spacing: 0.02em;
}
.site-header__wordmark-note {
  display: inline-flex;
  align-self: center;
  margin-inline: 0.08em 0.06em;
  flex-shrink: 0;
  line-height: 0;
  color: var(--brand-gold);
}
.site-header__logo:hover .site-header__wordmark-note,
.site-header__logo:focus .site-header__wordmark-note {
  color: #fff4c8;
}
.site-header__wordmark-note-svg {
  display: block;
  width: 0.5em;
  height: auto;
  max-height: 0.62em;
  transform: translateY(-0.1em);
}
.site-header__wordmark-note-svg .site-header__wordmark-slash {
  opacity: 0.38;
}
.site-header__logo:hover .site-header__wordmark-note-svg .site-header__wordmark-slash,
.site-header__logo:focus .site-header__wordmark-note-svg .site-header__wordmark-slash {
  opacity: 0.58;
}
.site-header__wordmark-main {
  letter-spacing: 0.18em;
}
.site-header__menu-toggle {
  color: var(--brand-gold-kicker);
}
.site-header__menu-toggle:hover,
.site-header__menu-toggle:focus {
  color: var(--brand-gold);
}
.site-header .site-header__link {
  color: var(--brand-text-muted);
}
.site-header .site-header__link:hover,
.site-header .site-header__link:focus {
  color: var(--brand-text-on-dark);
}

.site-header__flyout {
  border: 1px solid var(--brand-gold-border-image);
  box-shadow:
    0 12px 40px var(--brand-shadow-card),
    0 0 0 1px rgb(var(--brand-gold-rgb) / 0.08);
}

/* --- Site footer --- */
.site-footer {
  background: var(--brand-surface-deep);
  color: var(--brand-text-muted);
  border-top: 1px solid var(--brand-footer-border);
}
.site-footer a {
  color: var(--brand-text-muted);
  text-decoration: none;
}
.site-footer a:hover,
.site-footer a:focus {
  color: var(--color-primary-300);
  text-decoration: underline;
}
.site-footer .site-footer__copyright {
  margin-top: 2.5rem;
  text-align: center;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--brand-text-legal);
}

/* --- Hero (#top) --- */
#top.site-hero {
  min-height: 92vh;
}
#top .hero-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Keep ground / lower subject visible when viewport crops (cover + tall hero) */
  object-position: center bottom;
}
#top .hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--brand-hero-gradient);
}
#top .hero-inner {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 110px 24px 84px;
}
#top .hero-content {
  max-width: 700px;
}
#top .hero-eyebrow {
  display: inline-block;
  margin: 0 0 18px;
  padding: 6px 12px;
  border: 1px solid var(--brand-gold-border-eyebrow);
  border-radius: 999px;
  color: var(--brand-text-hero-eyebrow);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
#top .hero-title {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(2.1rem, 5vw, 4.4rem);
  font-weight: 900;
  line-height: 1.04;
}
#top .hero-sub {
  margin: 22px 0 0;
  color: var(--brand-text-hero-sub);
  font-size: clamp(1rem, 1.8vw, 1.28rem);
  line-height: 1.7;
  max-width: 640px;
}
#top .hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}
#top .hero-cta-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 7px;
  background: var(--brand-gold);
  color: var(--brand-cta-on-gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}
#top .hero-cta-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 7px;
  border: 1px solid var(--brand-gold-border-cta);
  background: var(--brand-hero-secondary-bg);
  color: var(--brand-text-hero-secondary-cta);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}

/* --- Section shells --- */
.site-section {
  padding: var(--brand-section-pad-y) 0;
  background: var(--brand-surface-deep);
}
.site-section--alt {
  background: var(--brand-surface-mid);
}

/* --- About --- */
#about-section .about-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
#about-section .about-grid {
  display: grid;
  align-items: center;
  gap: 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 980px) {
  #about-section .about-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 38px;
  }
}
#about-section .about-panel {
  opacity: 0;
  transition: opacity 640ms ease, transform 640ms ease;
  will-change: transform, opacity;
}
#about-section .about-panel[data-dir="left"] {
  transform: translateX(-36px);
}
#about-section .about-panel[data-dir="right"] {
  transform: translateX(36px);
}
#about-section .about-panel.is-visible {
  opacity: 1;
  transform: translateX(0);
}
#about-section .about-title {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  font-weight: 900;
  line-height: 1.15;
}
#about-section .about-copy {
  margin-top: 16px;
  color: var(--brand-text-muted);
  font-size: 1.02rem;
  line-height: 1.78;
  white-space: pre-line;
}
#about-section .about-image-box {
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--brand-gold-border-image);
  box-shadow: 0 12px 30px var(--brand-shadow-deep);
}
#about-section .about-image {
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
  display: block;
}
@media (max-width: 979px) {
  #about-section .about-image {
    min-height: 240px;
  }
}

/* --- Team --- */
#our-team .team-wrap {
  max-width: min(1520px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 1280px) {
  #our-team .team-wrap {
    max-width: min(1600px, calc(100vw - 64px));
    padding: 0 32px;
  }
}
#our-team .team-kicker {
  margin: 0;
  color: var(--brand-gold-kicker);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
#our-team .team-title {
  margin: 12px 0 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  font-weight: 900;
  line-height: 1.1;
}
#our-team .team-subtitle {
  margin: 14px 0 0;
  color: var(--brand-text-muted);
  font-size: 1.02rem;
  line-height: 1.7;
  max-width: 720px;
}
#our-team .team-grid {
  display: grid;
  gap: 20px;
  margin-top: 36px;
  grid-template-columns: repeat(1, minmax(0, 1fr));
}
@media (min-width: 768px) {
  #our-team .team-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1024px) {
  #our-team .team-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
#our-team .team-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--brand-gold-border-card);
  background: var(--brand-card-bg);
  box-shadow: 0 10px 26px var(--brand-shadow-card);
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 620ms ease, transform 620ms ease;
}
#our-team .team-card.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) !important;
}
#our-team .team-card[data-dir="left"] {
  transform: translateX(-30px);
}
#our-team .team-card[data-dir="right"] {
  transform: translateX(30px);
}
#our-team .team-card[data-offset="down"] {
  margin-top: 16px;
}
#our-team .team-card[data-offset="up"] {
  margin-top: -10px;
}
#our-team .team-img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}
#our-team .team-copy {
  padding: 20px;
}
#our-team .team-name {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1.2;
}
#our-team .team-bio {
  margin: 10px 0 0;
  color: var(--brand-text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}
@media (max-width: 639px) {
  #our-team .team-grid {
    gap: 14px;
  }
  #our-team .team-img {
    height: 190px;
  }
  #our-team .team-copy {
    padding: 14px;
  }
}

/* --- Events --- */
#events-section .events-wrap {
  max-width: min(1200px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 0 20px;
}
#events-section .events-title {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  font-weight: 900;
  line-height: 1.1;
}
#events-section .events-subtitle {
  margin: 14px 0 0;
  color: var(--brand-text-muted);
  font-size: 1.02rem;
  line-height: 1.7;
  max-width: 720px;
}
#events-section .events-list {
  display: grid;
  gap: 20px;
  margin-top: 36px;
}
@media (min-width: 768px) {
  #events-section .events-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
#events-section .events-card {
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--brand-gold-border-card);
  background: var(--brand-card-bg);
  box-shadow: 0 10px 26px var(--brand-shadow-card);
}
#events-section .events-card-image {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
#events-section .events-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
#events-section .events-card-body {
  padding: 20px;
}
#events-section .events-date {
  display: block;
  color: var(--brand-gold-kicker);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
#events-section .events-name {
  margin: 10px 0 0;
  color: var(--brand-text-on-dark);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.2;
}
#events-section .events-venue {
  margin: 8px 0 0;
  color: var(--brand-text-muted);
  font-size: 0.95rem;
}
#events-section .events-description {
  margin: 12px 0 0;
  color: var(--brand-text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}
#events-section .events-description p {
  margin: 0;
}
#events-section .events-ticket-link {
  display: inline-block;
  margin-top: 16px;
  color: var(--brand-gold-kicker);
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
}
#events-section .events-ticket-link:hover {
  text-decoration: underline;
}

/* --- Gallery --- */
#gallery-section .gallery-wrap {
  max-width: min(1520px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 0 20px;
}
@media (min-width: 1280px) {
  #gallery-section .gallery-wrap {
    max-width: min(1600px, calc(100vw - 64px));
    padding: 0 32px;
  }
}
#gallery-section .gallery-title {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  font-weight: 900;
  line-height: 1.1;
}
#gallery-section .gallery-subtitle {
  margin: 12px 0 0;
  color: var(--brand-text-muted);
  font-size: 1rem;
  line-height: 1.7;
}
#gallery-section .gallery-empty-hint {
  margin-top: 18px;
  color: var(--brand-text-muted);
}

/* Home preview: stacked on small screens (5 imgs); masonry columns from md (up to 10) */
#gallery-section .gallery-home-grid {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 28px;
}
#gallery-section .gallery-home-tile--desktop-extra {
  display: none;
}
@media (min-width: 768px) {
  #gallery-section .gallery-home-grid {
    display: block;
    column-count: 2;
    column-gap: 16px;
  }
  #gallery-section .gallery-home-grid .gallery-tile {
    break-inside: avoid;
    page-break-inside: avoid;
    margin-bottom: 16px;
    display: inline-block;
    width: 100%;
  }
  #gallery-section .gallery-home-tile--desktop-extra {
    display: inline-block;
  }
}
@media (min-width: 1200px) {
  #gallery-section .gallery-home-grid {
    column-count: 3;
    column-gap: 18px;
  }
}

#gallery-section .gallery-tile,
.gallery-full-page .gallery-tile {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--brand-gold-border-tile);
  background: var(--brand-tile-bg);
  box-shadow: 0 12px 26px var(--brand-shadow-tile);
  opacity: 0;
  transition: opacity 640ms ease, transform 640ms ease;
  will-change: transform, opacity;
}
#gallery-section .gallery-tile[data-dir="left"],
.gallery-full-page .gallery-tile[data-dir="left"] {
  transform: translateX(-24px);
}
#gallery-section .gallery-tile[data-dir="right"],
.gallery-full-page .gallery-tile[data-dir="right"] {
  transform: translateX(24px);
}
#gallery-section .gallery-tile.is-visible,
.gallery-full-page .gallery-tile.is-visible {
  opacity: 1;
  transform: translateX(0);
}

.gallery-tile-hit {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  border: 0;
  cursor: zoom-in;
  background: transparent;
  border-radius: inherit;
  line-height: 0;
}
.gallery-tile-hit:focus-visible {
  outline: 2px solid var(--brand-gold);
  outline-offset: 3px;
}

#gallery-section .gallery-home-grid .gallery-img,
.gallery-full-page .gallery-page-grid .gallery-img {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: middle;
}
.gallery-full-page .gallery-page-grid .gallery-img {
  object-fit: cover;
}

#gallery-section .gallery-actions {
  margin-top: 1.75rem;
  display: flex;
  justify-content: center;
}
#gallery-section .gallery-view-all {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.35rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--brand-text-on-dark);
  border: 1px solid var(--brand-gold-border-cta);
  background: transparent;
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}
#gallery-section .gallery-view-all:hover,
#gallery-section .gallery-view-all:focus-visible {
  color: var(--brand-cta-on-gold);
  background: var(--brand-gold);
  border-color: var(--brand-gold);
  outline: none;
}

/* Full gallery page */
.gallery-full-page {
  padding-top: 1.5rem;
  padding-bottom: 3rem;
}
.gallery-wrap--page {
  padding-top: 0.5rem;
}
.gallery-page-header {
  text-align: center;
  margin-bottom: 2rem;
}
.gallery-page-title {
  margin: 0;
  color: var(--brand-text-on-dark);
  font-size: clamp(1.85rem, 3vw, 2.6rem);
  font-weight: 900;
  line-height: 1.12;
}
.gallery-page-lead {
  margin: 0.75rem auto 0;
  max-width: 40rem;
  color: var(--brand-text-muted);
  font-size: 1rem;
  line-height: 1.65;
}
/* Full gallery page: masonry columns (same spirit as original gallery-grid) */
.gallery-page-grid {
  display: block;
  margin-top: 8px;
  column-count: 1;
  column-gap: 16px;
}
@media (min-width: 640px) {
  .gallery-page-grid {
    column-count: 2;
  }
}
@media (min-width: 1200px) {
  .gallery-page-grid {
    column-count: 3;
    column-gap: 18px;
  }
}
.gallery-page-grid .gallery-tile {
  break-inside: avoid;
  page-break-inside: avoid;
  margin-bottom: 16px;
  display: inline-block;
  width: 100%;
}

html.gallery-lightbox-open {
  overflow: hidden;
}

.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  background: rgb(0 0 0 / 0.88);
  backdrop-filter: blur(4px);
}
.gallery-lightbox-inner {
  position: relative;
  width: min(1100px, 100%);
  /* Reserved thumb band — keeps bottom strip from jumping when main image aspect ratio changes */
  --gallery-lightbox-thumb-slot: 5.75rem;
  /* Fixed shell: row 1 = stage, row 2 = thumbs (stable layout) */
  height: min(88vh, 860px);
  max-height: min(92vh, 880px);
  display: grid;
  grid-template-rows: 1fr var(--gallery-lightbox-thumb-slot);
  grid-template-columns: minmax(0, 1fr);
  gap: 0.75rem;
  align-content: stretch;
}
.gallery-lightbox-close {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 0;
  border-radius: 0.5rem;
  cursor: pointer;
  color: var(--brand-text-on-dark);
  background: rgb(0 0 0 / 0.45);
  transition: background 0.2s ease;
}
.gallery-lightbox-close:hover,
.gallery-lightbox-close:focus-visible {
  background: rgb(var(--brand-gold-rgb) / 0.38);
  outline: none;
}
.gallery-lightbox-nav {
  position: absolute;
  /* Center in main stage (row 1), not whole modal — stable with grid thumb row */
  top: calc((100% - var(--gallery-lightbox-thumb-slot, 5.25rem)) / 2);
  transform: translateY(-50%);
  z-index: 4;
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 0;
  border-radius: 0.5rem;
  cursor: pointer;
  color: var(--brand-text-on-dark);
  background: rgb(0 0 0 / 0.4);
}
@media (min-width: 768px) {
  .gallery-lightbox-nav {
    display: flex;
  }
}
.gallery-lightbox-nav--prev {
  left: 0.25rem;
}
.gallery-lightbox-nav--next {
  right: 0.25rem;
}
.gallery-lightbox-nav:hover,
.gallery-lightbox-nav:focus-visible {
  background: rgb(var(--brand-gold-rgb) / 0.34);
  outline: none;
}
.gallery-lightbox-main {
  grid-row: 1;
  grid-column: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 2.75rem 0.35rem;
  overflow: hidden;
}
.gallery-lightbox-main-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 20px 50px rgb(0 0 0 / 0.45);
}
.gallery-lightbox-thumbs-wrap {
  grid-row: 2;
  grid-column: 1;
  flex-shrink: 0;
  min-height: 0;
  height: 100%;
  max-height: var(--gallery-lightbox-thumb-slot);
  padding: 0 0.25rem 0.25rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-sizing: border-box;
  overflow: hidden;
}
.gallery-lightbox-thumbs {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 0.5rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0.35rem 0.25rem;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  flex: 1 1 auto;
  min-height: 0;
  /* Reserve space for horizontal scrollbar so its appearance doesn’t shift layout */
  scrollbar-gutter: stable;
}
.gallery-lightbox-thumbs::-webkit-scrollbar {
  height: 6px;
}
.gallery-lightbox-thumbs::-webkit-scrollbar-thumb {
  background: var(--brand-gold-scrollbar);
  border-radius: 10px;
}
.gallery-lightbox-thumb {
  flex: 0 0 auto;
  width: 4.75rem;
  height: 3.4rem;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  scroll-snap-align: start;
  opacity: 0.72;
  transition:
    opacity 0.2s ease,
    border-color 0.2s ease;
  background: rgb(0 0 0 / 0.35);
}
.gallery-lightbox-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gallery-lightbox-thumb:hover,
.gallery-lightbox-thumb:focus-visible {
  opacity: 1;
  outline: none;
}
.gallery-lightbox-thumb.is-active {
  opacity: 1;
  border-color: var(--brand-gold);
  box-shadow: 0 0 0 1px rgb(var(--brand-gold-rgb) / 0.38);
}
