/* === Переменные === */
:root {
  --color-burgundy: #890F0F;
  --color-burgundy-light: rgba(226, 87, 87, 0.20);
  --color-purple: #C5B5EE;
  --color-purple-light: rgba(215, 204, 242, 0.60);
  --color-text-primary: #2C2C2C;
  --color-text-secondary: rgba(44.19, 44.19, 44.19, 0.60);
  --color-white: #FFFFFF;
  --color-bg-light: #FFFDFA;
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 39px;
  --radius-xl: 54px;
  --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.08);
  --transition: all 0.3s ease;
}

/* === Сброс и база === */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--color-bg-light);
  color: var(--color-text-primary);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* === Шрифты (замените src на реальные пути, если нужно) === */
@font-face {
  font-family: 'Segoe UI';
  src: local('Segoe UI'), url('font/SegoeUI.woff2') format('woff2');
  font-display: swap;
}

@font-face {
  font-family: 'Unbounded';
  src: local('Unbounded'), url('font/Unbounded-Black.woff2') format('woff2');
  font-display: swap;
}

@font-face {
  font-family: 'Unbounded';
  src: url('font/Unbounded-Medium.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}

.font-display {
  font-family: 'Unbounded', sans-serif;
  font-weight: 500;
}

.font-ui {
  font-family: 'Segoe UI', 'Segoe UI', sans-serif;
}

/* === Контейнер === */
.main-container {
  max-width: 100%;
  margin: 0 auto;
  background: var(--color-bg-light);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* === Хедер === */
.header {
  background: var(--color-burgundy);
  border-bottom-right-radius: var(--radius-xl);
  border-bottom-left-radius: var(--radius-xl);
  padding: 1rem;
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}

.header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-bottom: 1rem;
}

.header-date,
.header-year {
  font-family: 'Segoe UI', sans-serif;
  font-weight: 600;
  font-size: clamp(0.875rem, 2.5vw, 1rem);
  line-height: 1.2;
}

.header-badge {
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--color-purple);
  border-radius: var(--radius-lg);
  font-family: 'Segoe UI', sans-serif;
  font-weight: 600;
  font-size: clamp(0.875rem, 2.5vw, 1rem);
  background: transparent;
  color: var(--color-white);
}

.header-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1rem 2rem;
  text-align: center;
}

.header-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: bold;
  font-weight: 600;
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  line-height: 1.2;
  color: var(--color-white);
  max-width: 100%;
}

.header-photos {
  position: relative;
  width: 100%;
  max-width: 375px;
  height: auto;
  aspect-ratio: 375/160;
  margin: 0 auto;
}

.header-photos img {
  position: absolute;
  width: 45%;
  height: auto;
  top: 5px;
  object-fit: contain;
}

.header-photos img:first-child {
  left: 6%;
}

.header-photos img:last-child {
  right: 6%;
}

/* === Основной контент === */
.content {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  flex: 1;
}

.section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.section-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 400;
  font-size: clamp(1.125rem, 3vw, 1.25rem);
  color: var(--color-text-primary);
  text-align: center;
}

.section-subtitle {
  font-size: clamp(2rem, 2.5vw, 1.25rem);
  font-family: 'Unbounded', sans-serif;
  font-weight: 500;
  color: var(--color-burgundy);
  text-align: center;
}

.section-text {
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  color: var(--color-text-primary);
  text-align: center;
  max-width: 600px;
  z-index: 3;
}

/* === Карточки === */
.card {
  width: 100%;
  max-width: 420px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  outline: 1px solid var(--color-purple);
  outline-offset: -1px;
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: var(--shadow-soft);
}

.card-header {
  display: flex;
  justify-content: center;
  padding-bottom: 0.5rem;
}

.card-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--color-text-primary);
  text-align: center;
}

/* === Календарь === */
.calendar-wrapper {
  position: relative;
  width: 100%;
  overflow: visible;
  /* Чтобы указатель не обрезался */
  margin: 0 auto;
}

.calendar-days,
.calendar-dates {
  display: flex;
  justify-content: space-between;
  gap: 4px;
  width: 100%;
  margin-bottom: 6px;
}

.calendar-day {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(0.625rem, 1.5vw, 0.75rem);
  font-weight: 600;
  color: var(--color-text-primary);
  position: relative;
  padding: 6px 0;
}

/* Подчёркивание для ПТ */
.friday-underline {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 70%;
  height: auto;
  pointer-events: none;
  opacity: 0.9;
}

.calendar-date {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  border-radius: 50%;
  background: var(--color-purple-light);
  color: var(--color-burgundy);
  font-size: clamp(0.75rem, 2vw, 0.875rem);
  font-weight: 600;
}

.calendar-date.active {
  background: var(--color-burgundy);
  color: var(--color-bg-light);
}

/* Указатель от правого края к ПТ */
.friday-pointer {
  position: absolute;
  left: 64.3%;
  top: 2px;
  width: clamp(60px, 35vw, 200px);
  height: auto;
  transform: translateX(-50%) rotate(-110deg);
  transform-origin: center top;
  /* Ось вращения в верхней точке картинки */
  opacity: 0.6;
  pointer-events: none;
  z-index: 2;
}

.disco-pointer {
  position: absolute;
  left: 17%;
  top: 350px;
  width: 200px;
  height: auto;
  transform: translateX(-50%) rotate(100deg);
  transform-origin: center top;
  /* Ось вращения в верхней точке картинки */
  opacity: 0.6;
  pointer-events: none;
  z-index: 2;
}

.heart {
  width: 30px;
  height: auto;
  /* transform: translateX(-50%) rotate(100deg); */
  transform-origin: center top;
  z-index: 2;
}

.calendar-note {
  background: var(--color-burgundy-light);
  border-radius: var(--radius-md);
  padding: 1rem;
  text-align: center;
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  color: var(--color-text-primary);
  margin-top: 0.5rem;
}

/* === Таймлайн === */
.timeline {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 420px;
  padding-left: 0;
  /* Убираем старый отступ */
}

.timeline-item {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  /* Лево │ Центр │ Право */
  align-items: center;
  gap: clamp(0.5rem, 2vw, 1rem);
  padding: 0.25rem 0;
  position: relative;
}

.timeline-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 91%;
  width: 2px;
  height: 0.5rem;
  background: var(--color-purple);
}

.timeline-icons {
  justify-self: end;
  display: flex;
  gap: 0.25rem;
  padding: 0.375rem 0.5rem;
  border-radius: var(--radius-md);
  outline: 1px solid #E7DFF5;
  background: var(--color-white);
}

.timeline-icons img {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  object-fit: cover;
}

.timeline-text {
  justify-self: start;
  font-size: clamp(0.875rem, 2.5vw, 0.9375rem);
  font-weight: 600;
  color: var(--color-text-primary);
  text-align: left;
  min-width: 0;
  /* Предотвращает переполнение на узких экранах */
}

.timeline-time {
  justify-self: center;
  padding: 0.5rem 0.75rem;
  background: var(--color-purple-light);
  border-radius: var(--radius-md);
  text-align: center;
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  font-weight: 600;
  color: var(--color-burgundy);
  white-space: nowrap;
}

/* === Локации === */
.location-card {
  width: 100%;
  max-width: 420px;
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.25rem 1rem;
  background: var(--color-white);
  outline: 1px solid var(--color-purple);
  outline-offset: -1px;
  box-shadow: var(--shadow-soft);
}

.location-info {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  outline: 1px solid var(--color-purple);
  outline-offset: -1px;
  background: var(--color-white);
}

.location-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
}

.location-label {
  color: var(--color-text-secondary);
  font-weight: 400;
}

.location-value {
  color: var(--color-text-primary);
  font-weight: 600;
}

.location-image {
  width: 100%;
  height: auto;
  aspect-ratio: 343/212;
  border-radius: var(--radius-md);
  object-fit: cover;
  background: #f0f0f0;
}

.location-name {
  font-weight: 600;
  font-size: clamp(1rem, 2.5vw, 1.125rem);
  text-align: center;
  color: var(--color-text-primary);
}

.location-desc {
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  text-align: center;
  color: var(--color-text-primary);
  line-height: 1.4;
}

/* === Дресс-код === */
.dresscode-colors {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  max-width: 420px;
}

.dresscode-colors img {
  flex: 1 1 18%;
  min-width: 0;
  height: auto;
  aspect-ratio: 1/1;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #eee;
}

.dresscode-examples {
  display: grid;
  grid-template-columns: repeat(4, minmax(20px, 1fr));
  gap: 0.5rem;
  width: 100%;
  max-width: 420px;
}

.dresscode-examples img {
  width: 100%;
  height: auto;
  aspect-ratio: 128/188;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #eee;
}

.games-examples {
  display: grid;
  grid-template-columns: repeat(3, minmax(20px, 1fr));
  gap: 0.5rem;
  width: 100%;
  max-width: 420px;
}

.games-examples img {
  width: 100%;
  height: auto;
  aspect-ratio: 128/188;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #eee;
}

/* === Футер === */
.footer {
  background: var(--color-burgundy);
  border-top-left-radius: var(--radius-xl);
  border-top-right-radius: var(--radius-xl);
  padding: 1.5rem 1rem;
  color: var(--color-white);
  text-align: center;
  position: relative;
  margin-top: 1rem;
}

.footer-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 500;
  font-size: clamp(1.25rem, 4vw, 1.5rem);
  margin-bottom: 1rem;
}

.footer-text {
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  margin-bottom: 1.25rem;
  opacity: 0.95;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(197, 181, 238, 0.4);
}

.map-container {
  width: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  outline: 1px solid var(--color-purple);
  outline-offset: -1px;
  background: #f0f0f0;
}

.map-container iframe {
  display: block;
  width: 100%;
  height: 200px;
  border: none;
}

/* Ссылка на полную карту */
.map-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  margin: 0.5rem auto 0;
  background: var(--color-purple-light);
  color: var(--color-burgundy);
  border-radius: var(--radius-md);
  font-size: clamp(0.875rem, 2.5vw, 0.9375rem);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.map-link:hover {
  background: var(--color-purple);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(137, 15, 15, 0.15);
}

/* === Анимации === */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card,
.location-card,
.timeline-item {
  animation: fadeInUp 0.5s ease-out forwards;
  opacity: 0;
}

.card:nth-child(1) {
  animation-delay: 0.1s;
}

.card:nth-child(2) {
  animation-delay: 0.2s;
}

.location-card:nth-of-type(1) {
  animation-delay: 0.3s;
}

.location-card:nth-of-type(2) {
  animation-delay: 0.4s;
}

.dresscode-colors,
.dresscode-examples,
.games-examples,
.photo {
  animation: fadeInUp 0.5s 0.5s forwards;
  opacity: 0;
}


.countdown {
  display: flex;
  justify-content: center;
  gap: clamp(0.5rem, 2vw, 1rem);
  margin: 0.5rem 0 1.5rem;
  width: 100%;
}

.countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--color-purple-light);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  min-width: 70px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.countdown-item span {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(1.25rem, 4vw, 1.75rem);
  font-weight: 700;
  color: var(--color-burgundy);
  line-height: 1.2;
}

.countdown-item small {
  font-size: clamp(0.7rem, 2vw, 0.85rem);
  color: var(--color-text-secondary);
  margin-top: 4px;
  text-transform: lowercase;
}

.calendar-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: var(--color-white);
  color: var(--color-burgundy);
  border: 1px solid var(--color-purple);
  border-radius: var(--radius-lg);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  justify-content: center;
}

.calendar-btn:hover {
  background: var(--color-purple-light);
  transform: translateY(-1px);
}

/* === Утилиты === */
.text-center {
  text-align: center;
}

.color-purple {
  color: var(--color-purple);
}

.color-burgundy {
  color: var(--color-burgundy);
}

/* === Лайтбокс === */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(44, 44, 44, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 1000;
  padding: 1rem;
  box-sizing: border-box;
  backdrop-filter: blur(4px);
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: modalIn 0.3s ease-out forwards;
}

@keyframes modalIn {
  from {
    transform: scale(0.95);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

#modal-img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: var(--radius-md);
  object-fit: contain;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.modal-caption {
  color: #fff;
  font-size: 0.9rem;
  margin-top: 0.75rem;
  text-align: center;
  opacity: 0.9;
}

.modal-close {
  position: absolute;
  top: -18px;
  right: -18px;
  width: 38px;
  height: 38px;
  background: var(--color-white);
  border: 2px solid var(--color-purple);
  border-radius: 50%;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s, background 0.2s;
  color: var(--color-text-primary);
}

.modal-close:hover {
  transform: scale(1.1) rotate(90deg);
  background: var(--color-purple-light);
}

body.modal-open {
  overflow: hidden;
}

/* ✅ Подсветка плиток при наведении (покажет, что их можно кликнуть) */
.dresscode-examples img {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.dresscode-examples img:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.games-examples img {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.games-examples img:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.photo img {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.photo img:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* === Блок полезных ссылок === */
.useful-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: 100%;
  max-width: 380px;
  margin: 0.5rem auto 0;
}

.useful-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: var(--color-white);
  color: var(--color-burgundy);
  border: 1px solid var(--color-purple);
  border-radius: var(--radius-lg);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  justify-content: center;
}

.useful-link:hover,
.useful-link:focus {
  background: var(--color-purple-light);
  transform: translateY(-1px);
}

.link-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
}

.link-text {
  flex: 1;
}

.games-list {
  list-style: none;
  display: flex;
  flex-direction: column;
}

.games-list li {
  display: flex;
  align-items: center;
  font-size: 0.9375rem;
  transition: transform 0.2s ease;
  font-size: clamp(0.9375rem, 2.5vw, 1rem);
  color: var(--color-text-primary);
}