/* Beautiful Pearls Equipping Academies — logo palette (gold, purple, black) */

:root {
  --black: #060607;
  --surface: #0c0c0e;
  --surface2: #131318;
  --gold: #c4a35a;
  --gold-light: #e8dcc0;
  --gold-muted: #8f7a47;
  --cream: #f2efe8;
  --text-body: #b8b3aa;
  --muted: #6f6b65;
  --violet: #a894c9;
  --navy: #121824;
  --hairline: rgba(196, 163, 90, 0.22);
  --hairline-faint: rgba(255, 248, 235, 0.06);
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "DM Sans", system-ui, sans-serif;
  --radius: 14px;
  --radius-sm: 10px;
  --max: 920px;
  --wide: 1080px;
  --header-h: 64px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.02rem;
  line-height: 1.68;
  color: var(--cream);
  background: var(--black);
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(196, 163, 90, 0.08), transparent 55%),
    linear-gradient(180deg, var(--navy) 0%, var(--black) 35%);
  -webkit-font-smoothing: antialiased;
  /* background: var(--black);
  background-image:
    radial-gradient(ellipse 70% 45% at 50% -5%, rgba(var(--purple-rgb), 0.35), transparent 50%),
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(var(--gold-rgb), 0.1), transparent 55%),
    linear-gradient(180deg, var(--purple-dark) 0%, var(--black) 40%);
  -webkit-font-smoothing: antialiased; */
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--gold-light);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--gold-light);
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0.75rem;
  background: var(--navy);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 1000;
  border-radius: 6px;
}

.skip-link:focus {
  left: 0.75rem;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(14px) saturate(1.15);
  border-bottom: 1px solid var(--hairline-faint);
  transition:
    background 0.35s ease,
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

.site-header.is-scrolled {
  background: rgba(6, 7, 10, 0.72);
  backdrop-filter: blur(14px) saturate(1.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  /* background: rgba(46, 8, 84, 0.97);
  border-bottom-color: var(--hairline); */
  /* box-shadow: 0 4px 24px rgba(0, 0, 0, 0.45); */
}

.header-inner {
  position: relative;
  max-width: var(--wide);
  margin: 0 auto;
  /*padding: 0 1.35rem;*/
  padding: 0 .5rem;
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--cream);
  min-width: 0;
  flex: 1 1 auto;
  max-width: min(100%, 22rem);
}

.logo__mark {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  object-fit: contain;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.4));
}

.logo__text {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: 0.03em;
  line-height: 1.2;
  min-width: 0;
}

.logo__text span {
  display: block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 0.2rem;
}

.logo:hover .logo__text {
  color: var(--gold-light);
}

.nav-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.08);
  color: var(--cream);
  border: 1px solid var(--hairline-faint);
  padding: 0.55rem 0.95rem;
  border-radius: 999px;
  font: inherit;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
}

.nav-primary ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.35rem;
  align-items: center;
}

.nav-primary a {
  color: var(--text-body);
  font-weight: 500;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav-primary a:hover,
.nav-primary a[aria-current="page"] {
  color: var(--gold-light);
}

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    flex-shrink: 0;
  }

  .nav-primary {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(8, 9, 12, 0.96);
    border-bottom: 1px solid var(--hairline-faint);
    padding: 1rem 1.35rem 1.25rem;
    display: none;
  }

  /* .nav-primary {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(46, 8, 84, 0.98);
    border-bottom: 1px solid var(--hairline);
    padding: 0.85rem 1.35rem 1.25rem;
    display: none;
    max-height: min(70vh, 400px);
    overflow-y: auto;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
  } */

  .nav-primary.is-open {
    display: block;
  }

  .nav-primary ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav-primary li {
    border-bottom: 1px solid var(--hairline-faint);
  }

  .nav-primary li:last-child {
    border-bottom: 0;
  }

  .nav-primary a {
    display: block;
    padding: 0.85rem 0.25rem;
  }

  /*.logo__text {*/
  /*  display: none;*/
  /*}*/

  .logo {
    /*max-width: calc(100% - 6rem);*/
  }
}

body.nav-open {
  overflow: hidden;
}

@media (min-width: 821px) {
  body.nav-open {
    overflow: auto;
  }
}

/* Fullscreen hero */
.hero-full {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: calc(var(--header-h) + 2rem) 1.35rem 3.5rem;
  text-align: center;
  isolation: isolate;
  overflow: hidden;
}

.hero-full::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-color: #0a0b0f;
  background-image: url("images/bg.jpg");
  background-size: cover;
  background-position: center;
  filter:brightness(0.35);
  /* transform: scale(1.02); */
}

/* Hero veil — same navy/black DNA as body + soft handoff into content below */
.hero-full::after {
  /* content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 95% 55% at 50% -8%, rgba(196, 163, 90, 0.06), transparent 52%),
    linear-gradient(180deg, rgba(18, 22, 36, 0.42) 0%, transparent 48%),
    linear-gradient(0deg, rgba(6, 6, 8, 0.82) 0%, rgba(8, 9, 12, 0.45) 42%, transparent 72%); */


  /* background:
    radial-gradient(ellipse 95% 55% at 50% -8%, rgba(var(--purple-rgb), 0.25), transparent 52%),
    radial-gradient(ellipse 80% 40% at 50% 20%, rgba(var(--gold-rgb), 0.08), transparent 45%),
    linear-gradient(180deg, rgba(46, 8, 84, 0.5) 0%, transparent 48%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.88) 0%, rgba(46, 8, 84, 0.5) 42%, transparent 72%); */
}

/* Panel matches school/trainer cards: no blur — ink surface + gold/violet washes */
.hero-full-inner {
  position: relative;
  z-index: 2;
  max-width: 48rem;
  width: 100%;
  padding: clamp(1.35rem, 4vw, 2rem) clamp(1.25rem, 4vw, 2.25rem);
  border-radius: var(--radius);
  /* border: 1px solid var(--hairline-faint); */
  /* background:
    radial-gradient(ellipse 95% 75% at 0% 0%, rgba(196, 163, 90, 0.09), transparent 54%),
    radial-gradient(ellipse 75% 65% at 100% 90%, rgba(168, 148, 201, 0.07), transparent 50%),
    linear-gradient(165deg, rgba(22, 22, 28, 0.94) 0%, rgba(12, 12, 16, 0.9) 55%, rgba(10, 11, 14, 0.93) 100%);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35); */
  background:rgba(0,0,0,0.6);
  /* border: 1px solid var(--hairline-faint);
  background:
    radial-gradient(ellipse 95% 75% at 0% 0%, rgba(var(--gold-rgb), 0.12), transparent 54%),
    radial-gradient(ellipse 75% 65% at 100% 90%, rgba(var(--purple-rgb), 0.2), transparent 50%),
    linear-gradient(165deg, rgba(46, 8, 84, 0.92) 0%, rgba(10, 8, 14, 0.94) 55%, rgba(0, 0, 0, 0.93) 100%);
  border-color: var(--hairline);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35); */
}

@media (prefers-reduced-transparency: reduce) {
  .hero-full-inner {
    background:
      radial-gradient(ellipse 95% 75% at 0% 0%, rgba(196, 163, 90, 0.06), transparent 54%),
      linear-gradient(165deg, rgba(18, 18, 22, 0.96) 0%, rgba(12, 12, 16, 0.97) 100%);
    /* background:
      radial-gradient(ellipse 95% 75% at 0% 0%, rgba(var(--gold-rgb), 0.08), transparent 54%),
      linear-gradient(165deg, rgba(46, 8, 84, 0.96) 0%, rgba(0, 0, 0, 0.97) 100%); */
  }
}

.hero-kicker {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 1rem;
}

.hero-full h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 5.5vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--cream);
  margin: 0 0 1.1rem;
}

.hero-lead {
  font-size: clamp(1rem, 2vw, 1.12rem);
  color: var(--text-body);
  margin: 0 0 1.75rem;
  max-width: 42ch;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.68rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 0.15s ease,
    filter 0.2s ease,
    background 0.2s ease,
    border-color 0.2s ease;
  text-decoration: none;
  font-family: inherit;
}

.btn:active {
  transform: translateY(1px);
}

.hero-full .btn-ghost {
  border-color: var(--hairline-faint);
  background: rgba(255, 250, 235, 0.04);
}

.hero-full .btn-ghost:hover {
  border-color: var(--hairline);
  background: rgba(196, 163, 90, 0.08);
  color: var(--gold-light);
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--black);
}

.btn-primary:hover {
  color: var(--black);
  filter: brightness(1.05);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.08);
  color: var(--cream);
  border-color: rgba(255, 255, 255, 0.22);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
}

/* .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.68rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 0.15s ease,
    filter 0.2s ease,
    background 0.2s ease,
    border-color 0.2s ease;
  text-decoration: none;
  font-family: inherit;
}

.btn:active {
  transform: translateY(1px);
}

.hero-full .btn-ghost {
  border-color: var(--hairline-faint);
  background: rgba(255, 250, 235, 0.04);
}

.hero-full .btn-ghost:hover {
  border-color: var(--hairline);
  background: rgba(var(--gold-rgb), 0.12);
  color: var(--gold-light);
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 55%, var(--gold-dark) 100%);
  color: var(--purple-dark);
  border-color: rgba(var(--gold-rgb), 0.4);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.btn-primary:hover {
  color: var(--purple-dark);
  filter: brightness(1.08);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.08);
  color: var(--cream);
  border-color: rgba(255, 255, 255, 0.22);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
} */

/* Sections */
main {
  display: block;
}

.section {
  padding: clamp(3.25rem, 7vw, 4.75rem) 1.35rem;
  border-top: 1px solid var(--hairline-faint);
}

.section--soft {
  background: linear-gradient(180deg, transparent, rgba(255, 250, 235, 0.02));
}

.section--emphasis {
  background:
    radial-gradient(ellipse 70% 60% at 100% 0%, rgba(var(--purple-rgb), 0.22), transparent 50%),
    radial-gradient(ellipse 50% 40% at 0% 100%, rgba(var(--gold-rgb), 0.06), transparent 45%),
    linear-gradient(180deg, var(--purple-dark) 0%, var(--black) 100%);
}

.container {
  max-width: var(--max);
  margin: 0 auto;
}

.container--wide {
  max-width: var(--wide);
}

.section-header {
  margin-bottom: 2rem;
}

.section-header--follow {
  margin-top: 2.5rem;
  margin-bottom: 0;
}

.hero-actions--cta {
  margin-top: 2rem;
  justify-content: flex-start;
}

.trainer-card p + p {
  margin-top: 1rem;
}

.section-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 0.5rem;
}

.section h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
  line-height: 1.15;
  color: var(--cream);
  margin: 0 0 0.75rem;
}

.section-intro {
  color: var(--text-body);
  margin: 0;
  max-width: 62ch;
}

.prose p {
  color: var(--text-body);
  margin: 0 0 1.1rem;
}

.prose p:last-child {
  margin-bottom: 0;
}

.split-simple {
  display: block;
  /* gap: 2rem; */
}

@media (min-width: 880px) {
  .split-simple {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
  }
}

.mv-grid {
  display: grid;
  gap: 1rem;
  margin-top:1rem;
}

@media (min-width: 560px) {
  .mv-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.mv-card {
  background: rgba(255, 250, 235, 0.03);
  border: 1px solid var(--hairline-faint);
  border-radius: var(--radius);
  padding: 1.35rem 1.45rem;
}

.mv-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--gold-light);
  margin: 0 0 0.65rem;
}

.mv-card p {
  margin: 0;
  color: var(--text-body);
  font-size: 0.97rem;
}

/* Values */
.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.65rem;
  margin-top: 1.75rem;
  list-style: none;
  padding: 0;
}

.values-grid li {
  text-align: center;
  padding: 0.65rem 0.8rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--hairline-faint);
  background: rgba(255, 250, 235, 0.025);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cream);
}

/* Schools */
.school-list {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.school-card {
  border-radius: var(--radius);
  border: 1px solid var(--hairline-faint);
  /* border-top: 2px solid var(--gold-dark); */
  background:
    radial-gradient(ellipse 100% 80% at 0% 0%, rgba(var(--purple-rgb), 0.12), transparent 50%),
    rgba(10, 8, 14, 0.75);
  padding: clamp(1.35rem, 3vw, 1.85rem);
}

.school-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.28rem, 2.5vw, 1.55rem);
  color: var(--cream);
  margin: 0 0 0.85rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
}

.school-num {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--gold);
}

.school-card > p {
  margin: 0 0 1rem;
  color: var(--text-body);
}

.gains-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-light) !important;
  margin: 1.25rem 0 0.65rem;
}

.gains-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.45rem;
}

@media (min-width: 640px) {
  .gains-list {
    grid-template-columns: 1fr 1fr;
  }
}

.gains-list li {
  position: relative;
  padding-left: 1.15rem;
  color: var(--text-body);
  font-size: 0.96rem;
}

.gains-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold-muted);
}

/* Lists */
.check-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.55rem;
}

@media (min-width: 560px) {
  .check-list.columns {
    grid-template-columns: 1fr 1fr;
  }
}

.check-list li {
  padding-left: 1.6rem;
  position: relative;
  color: var(--text-body);
}

.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--gold);
  font-weight: 700;
  font-size: 0.85rem;
}

.bullet-grid {
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 600px) {
  .bullet-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.bullet-grid article {
  padding: 1rem 1.1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--hairline-faint);
  background: rgba(255, 250, 235, 0.02);
  color: var(--text-body);
  font-size: 0.98rem;
}

.bullet-grid article strong {
  color: var(--cream);
  font-weight: 600;
}

.trainer-card {
  display: grid;
  gap: 1.25rem;
  align-items: start;
  padding: clamp(1.5rem, 3vw, 2rem);
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
  background:
    radial-gradient(ellipse 80% 80% at 0% 0%, rgba(var(--gold-rgb), 0.1), transparent 55%),
    radial-gradient(ellipse 60% 50% at 100% 100%, rgba(var(--purple-rgb), 0.15), transparent 50%),
    rgba(255, 250, 235, 0.03);
}

@media (min-width: 640px) {
  .trainer-card {
    grid-template-columns: auto 1fr;
    gap: 2rem;
  }
}

.trainer-photo {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background:
    linear-gradient(145deg, rgba(var(--gold-rgb), 0.4), rgba(var(--purple-rgb), 0.35)),
    var(--surface2);
  border: 2px solid var(--gold);
  margin: 0 auto;
}

@media (min-width: 640px) {
  .trainer-photo {
    margin: 0;
  }
}

.trainer-card h3 {
  font-family: var(--font-display);
  font-size: 1.65rem;
  margin: 0 0 0.35rem;
  color: var(--cream);
}

.trainer-role {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 1rem;
}

.trainer-card p {
  margin: 0;
  color: var(--text-body);
}

.contact-block {
  display: grid;
  gap: 1rem;
  margin-top: 1.75rem;
}

@media (min-width: 560px) {
  .contact-block {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
}

.contact-item {
  padding: 1rem 1.15rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--hairline-faint);
  background: rgba(255, 250, 235, 0.025);
  font-size: 0.96rem;
  color: var(--text-body);
  line-height: 1.55;
}

.contact-item strong {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 0.35rem;
}

.contact-item a {
  word-break: break-word;
}

.site-footer {
  padding: 2.75rem 1.35rem;
  border-top: 3px solid var(--gold);
  text-align: center;
  background: linear-gradient(180deg, var(--black) 0%, var(--purple-dark) 100%);
}

.footer-logo {
  width: 92px;
  height: 92px;
  margin: 0 auto 1rem;
  object-fit: contain;
  filter: drop-shadow(0 4px 16px rgba(0, 0, 0, 0.4));
}

.footer-motto {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold);
  margin: 0 0 0.65rem;
  letter-spacing: 0.04em;
}

.footer-inner {
  max-width: var(--wide);
  margin: 0 auto;
}

.footer-tagline {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--gold-light);
  margin: 0 0 0.5rem;
}

.footer-meta {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.footer-meta a {
  color: var(--text-body);
}

.footer-meta a:hover {
  color: var(--gold-light);
}

/* Gallery page */
.page-hero {
  padding: calc(var(--header-h) + 3rem) 1.35rem 2.5rem;
  text-align: center;
  border-bottom: 1px solid var(--hairline-faint);
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(196, 163, 90, 0.07), transparent 55%),
    linear-gradient(180deg, rgba(18, 22, 36, 0.45) 0%, transparent 100%);
}

.page-hero .container {
  max-width: 42rem;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 4.5vw, 2.85rem);
  line-height: 1.1;
  color: var(--cream);
  margin: 0 0 0.85rem;
}

.gallery-section {
  padding-top: clamp(2rem, 5vw, 3rem);
}

.gallery-status {
  text-align: center;
  color: var(--text-body);
  margin: 0 0 1.5rem;
  font-size: 0.95rem;
}

.gallery-masonry {
  margin: 0 auto;
}

.gallery-sizer,
.gallery-item {
  width: calc(50% - 8px);
}

@media (min-width: 640px) {
  .gallery-sizer,
  .gallery-item {
    width: calc(33.333% - 11px);
  }
}

@media (min-width: 960px) {
  .gallery-sizer,
  .gallery-item {
    width: calc(25% - 12px);
  }

  .gallery-item--wide {
    width: calc(50% - 12px);
  }
}

.gallery-item {
  margin-bottom: 16px;
  break-inside: avoid;
}

.gallery-popup {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-sm);
  border: 1px solid var(--hairline-faint);
  background: var(--surface2);
  color: inherit;
  text-decoration: none;
  transition:
    border-color 0.25s ease,
    box-shadow 0.25s ease,
    transform 0.25s ease;
}

.gallery-popup::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(6, 6, 7, 0.72) 0%, transparent 55%);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.gallery-popup:hover,
.gallery-popup:focus-visible {
  border-color: var(--hairline);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  transform: translateY(-2px);
  color: inherit;
}

.gallery-popup:hover::after,
.gallery-popup:focus-visible::after {
  opacity: 1;
}

.gallery-popup img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.4s ease;
}

.gallery-item--tall img {
  min-height: 280px;
  object-fit: cover;
}

.gallery-item--wide img {
  min-height: 220px;
  object-fit: cover;
  object-position: center 30%;
}

.gallery-popup:hover img,
.gallery-popup:focus-visible img {
  transform: scale(1.03);
}

.gallery-item__caption {
  position: absolute;
  left: 0.85rem;
  right: 0.85rem;
  bottom: 0.75rem;
  z-index: 1;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-light);
  opacity: 0;
  transform: translateY(6px);
  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
  pointer-events: none;
}

.gallery-popup:hover .gallery-item__caption,
.gallery-popup:focus-visible .gallery-item__caption {
  opacity: 1;
  transform: translateY(0);
}

body.gallery-lightbox-open {
  overflow: hidden;
}

.gallery-mfp .mfp-bg {
  background: rgba(6, 6, 7, 0.92);
  opacity: 1;
  backdrop-filter: blur(6px);
}

.gallery-mfp .mfp-figure::after {
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
}

.gallery-mfp .mfp-image-holder .mfp-close,
.gallery-mfp .mfp-iframe-holder .mfp-close {
  color: var(--gold-light);
  opacity: 0.85;
  font-size: 2.5rem;
  right: 0.5rem;
  top: 0.25rem;
}

.gallery-mfp .mfp-image-holder .mfp-close:hover,
.gallery-mfp .mfp-iframe-holder .mfp-close:hover {
  color: var(--gold);
  opacity: 1;
}

.gallery-mfp .mfp-arrow {
  opacity: 0.75;
  transition: opacity 0.2s ease;
}

.gallery-mfp .mfp-arrow:hover {
  opacity: 1;
}

.gallery-mfp .mfp-arrow::before,
.gallery-mfp .mfp-arrow::after {
  border-color: var(--gold-light);
}

.gallery-mfp .mfp-counter {
  color: var(--text-body);
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.gallery-mfp .mfp-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--cream);
  text-align: center;
  padding-right: 0;
  line-height: 1.4;
}

.gallery-mfp .mfp-bottom-bar {
  margin-top: 0.75rem;
  background: transparent;
}

.gallery-mfp.mfp-fade.mfp-bg {
  transition: opacity 0.28s ease;
}

.gallery-mfp.mfp-fade.mfp-wrap .mfp-content {
  transition: opacity 0.28s ease, transform 0.28s ease;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }

  .gallery-popup:hover img,
  .gallery-popup:focus-visible img {
    transform: none;
  }

  .gallery-popup:hover,
  .gallery-popup:focus-visible {
    transform: none;
  }
}
