:root {
  --black: #111111;
  --dark: #1b1b1b;
  --white: #ffffff;
  --cream: #f1eee8;
  --gray: #777777;
  --border: rgba(255, 255, 255, 0.2);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--black);
  font-family: Arial, Helvetica, sans-serif;
}

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

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

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 5%;
  background: rgba(17, 17, 17, 0.9);
  color: var(--white);
}

.logo img {
  width: 80px;
  max-height: 80px;
  object-fit: contain;
}

.main-nav {
  display: flex;
  gap: 24px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.main-nav a:hover,
.text-link:hover {
  opacity: 0.6;
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 28px;
  height: 2px;
  margin: 5px;
  background: white;
}

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 140px 8%;
  color: white;
  background: url("../images/main-bg.jpeg") center / cover no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.48);
}

.hero-content,
.hero-scroll {
  position: relative;
  z-index: 1;
}

.eyebrow,
.section-label,
.event-date {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 11px;
  font-weight: bold;
}

.hero h1,
.section h2,
.report h2 {
  margin: 20px 0;
  font-size: clamp(48px, 8vw, 110px);
  line-height: 0.9;
  font-weight: 400;
}

.hero-description {
  max-width: 420px;
  line-height: 1.6;
}

.hero-actions,
.contact-links {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-top: 35px;
}

.button {
  display: inline-block;
  padding: 15px 24px;
  border: 1px solid currentColor;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.1em;
  transition: 0.25s;
}

.button:hover {
  transform: translateY(-3px);
}

.button-light {
  color: var(--black);
  background: white;
}

.button-dark {
  color: white;
  background: var(--black);
}

.hero-scroll {
  position: absolute;
  right: 8%;
  bottom: 40px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 11px;
  writing-mode: vertical-rl;
}

.scroll-line {
  width: 1px;
  height: 60px;
  background: white;
}

.section {
  padding: 120px 8%;
}

.dark-section {
  background: var(--dark);
  color: white;
}

.section-grid,
.section-heading,
.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
}

.section-heading {
  align-items: end;
  margin-bottom: 60px;
}

.section-heading > p {
  max-width: 400px;
  line-height: 1.6;
}

.section-label {
  color: var(--gray);
}

.dark-section .section-label {
  color: #aaa;
}

.text-content,
.intro-text {
  max-width: 600px;
  line-height: 1.7;
}

.text-content p,
.intro-text p {
  margin-bottom: 25px;
}

.wide-image,
.feature-image img {
  width: 100%;
  max-height: 620px;
  object-fit: cover;
}

.history-text {
  margin: 60px 0 0 auto;
}

/* СОБЫТИЯ */

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

.event-card {
  display: flex;
  min-height: 300px;
  padding: 0;
  overflow: hidden;
  background: white;
  border: 1px solid #ddd;
}

.event-card img {
  width: 42%;
  min-height: 260px;
  object-fit: cover;
}

.event-info {
  flex: 1;
  padding: 28px;
}

.event-info h3 {
  margin: 0;
  font-size: 25px;
  font-weight: 400;
}

.event-card p:last-child {
  color: var(--gray);
  line-height: 1.5;
}

.event-list {
  display: grid;
  gap: 0;
  margin-top: 20px;
}

.event-list-item {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid #d7d3cc;
}

.event-list-item span {
  color: var(--gray);
}

/* ГАЛЕРЕЯ */

.gallery-toolbar {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 20px;
}

.gallery-button {
  width: 45px;
  height: 45px;
  border: 1px solid white;
  background: transparent;
  color: white;
  font-size: 20px;
  cursor: pointer;
}

.gallery-button:hover {
  background: white;
  color: var(--black);
}

.gallery-grid {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(260px, 28vw);
  gap: 15px;
  overflow-x: auto;
  padding-bottom: 15px;
  scroll-behavior: smooth;
}

.gallery-grid img {
  width: 100%;
  height: 370px;
  object-fit: cover;
  cursor: pointer;
  background: #333;
}

/* ДРУЗЬЯ */

.friends-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 40px;
}

.friends-grid img {
  display: block;
  width: 100%;
  height: 150px;
  padding: 25px;
  object-fit: contain;
  background: white;
  border: 1px solid #ddd;
}

/* ДНИ РОЖДЕНИЯ */

.birthdays-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.birthday-card {
  overflow: hidden;
  background: white;
  color: var(--black);
}

.birthday-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

.birthday-info {
  padding: 18px;
}

.birthday-info h3 {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 400;
}

.birthday-info p {
  margin: 0;
  color: var(--gray);
}

/* ОТЧЁТ И КОНТАКТЫ */

.report {
  background:
    linear-gradient(rgba(0, 0, 0, 0.48), rgba(0, 0, 0, 0.48)),
    url("../images/main-bg.jpeg") center / cover no-repeat;
  color: white;
}

.report p {
  max-width: 440px;
  line-height: 1.6;
}

.contacts {
  background: var(--cream);
}

.dark-link {
  color: var(--black);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  padding: 25px 8%;
  background: var(--black);
  color: white;
  font-size: 12px;
}

/* LIGHTBOX */

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

.lightbox.is-visible {
  display: flex;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 25px;
  right: 35px;
  border: 0;
  background: transparent;
  color: white;
  font-size: 42px;
  cursor: pointer;
}

/* УСТАВ */

.club-charter {
  padding-top: 0;
  padding-bottom: 120px;
}

.charter-details {
  max-width: 1000px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid #ddd;
}

.charter-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 30px;
  cursor: pointer;
  list-style: none;
  font-size: clamp(24px, 3vw, 38px);
  font-weight: 400;
}

.charter-details summary::-webkit-details-marker {
  display: none;
}

.charter-details summary::after {
  content: "+";
  flex: 0 0 auto;
  color: var(--gray);
  font-size: 30px;
}

.charter-details[open] summary {
  border-bottom: 1px solid #ddd;
}

.charter-details[open] summary::after {
  content: "−";
}

.charter-details summary:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: -3px;
}

.charter-content {
  max-width: 760px;
  padding: 28px 30px 34px;
  color: #444;
  line-height: 1.7;
}

.charter-content h3 {
  margin: 0 0 30px;
  color: var(--black);
  font-size: clamp(22px, 2.5vw, 30px);
  font-weight: 400;
}

.charter-section + .charter-section {
  margin-top: 30px;
}

.charter-section h4 {
  margin: 0 0 12px;
  color: var(--black);
  font-size: 17px;
}

.charter-content p {
  margin: 0 0 12px;
}

.charter-content ol,
.charter-content ul {
  margin: 0 0 12px;
  padding-left: 24px;
}

.charter-content li + li {
  margin-top: 7px;
}

.header-instagram {
  display: inline-block;
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  color: white;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: 0.25s;
}

.header-instagram:hover {
  background: white;
  color: var(--black);
}
/* МОБИЛЬНАЯ ВЕРСИЯ */

@media (max-width: 800px) {
  .header-instagram {
  margin-left: auto;
  margin-right: 15px;
  padding: 8px 11px;
  font-size: 10px;
}
@media (max-width: 800px) {
  .language-switcher {
    margin-right: 10px;
  }
}
  .site-header {
    padding: 8px 5%;
  }

  .menu-toggle {
    display: block;
  }

  .main-nav {
    position: absolute;
    top: 90%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    gap: 0;
    background: var(--black);
  }

  .main-nav.is-open {
    display: flex;
  }

  .main-nav a {
    padding: 10px 5%;
    border-top: 1px solid #333;
  }

  .section-grid,
  .section-heading,
  .intro-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .section {
    padding: 80px 5%;
  }

  .hero {
    padding: 120px 5%;
  }

  .hero-scroll {
    display: none;
  }

  .events-grid,
  .friends-grid,
  .birthdays-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .event-card {
    display: block;
  }

  .event-card img {
    width: 100%;
    height: 220px;
    min-height: 0;
  }

  .event-list-item {
    flex-direction: column;
    gap: 6px;
  }

  .birthday-card img {
    height: 220px;
  }

  .site-footer {
    flex-direction: column;
    gap: 10px;
  }
}
.language-switcher {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  margin-right: 20px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 11px;
  letter-spacing: 0.1em;
}

.lang-button {
  padding: 4px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  font-size: 11px;
  letter-spacing: 0.1em;
}

.lang-button.active,
.lang-button:hover {
  color: white;
}
@media (max-width: 500px) {
  .events-grid,
  .friends-grid,
  .birthdays-grid {
    grid-template-columns: 1fr;
  }

  .hero h1,
  .section h2,
  .report h2 {
    font-size: 54px;
  }

  .hero-actions,
  .contact-links {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Видео занимают обычный экранный блок и не управляют прокруткой страницы. */
.intro-video,
.scroll-video {
  position: relative;
  height: 100vh;
  min-height: 480px;
  background: #111;
}

.intro-video { z-index: 0; }

.intro-video__sticky,
.scroll-video__sticky {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #111;
}

.intro-video__media,
.scroll-video__media {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  background: #111;
}

.intro-loader {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #fff;
  background: rgba(17, 17, 17, 0.96);
  opacity: 1;
  visibility: visible;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}

.intro-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.intro-loader[hidden] { display: none !important; }

.intro-loader__inner { width: min(420px, 100%); }
.intro-loader__label {
  margin-bottom: 16px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.intro-loader__row { display: flex; align-items: center; gap: 14px; }
.intro-loader__track {
  flex: 1; height: 2px; overflow: hidden; background: rgba(255, 255, 255, 0.3);
}
.intro-loader__bar {
  width: 0; height: 100%; background: #fff; transition: width 0.2s ease;
}
.intro-loader__percent { min-width: 3em; font-size: 12px; text-align: right; }
.intro-loader__hint { margin-top: 14px; color: rgba(255, 255, 255, 0.7); font-size: 12px; }


@media (prefers-reduced-motion: reduce) {
  .intro-loader, .intro-loader__bar { transition: none; }
}
