/* --- STYLE PODSTRONY ZAWODÓW (Vansjø 30) --- */

.event-hero {
  min-height: 50vh;
  padding-top: 100px;
  background: linear-gradient(rgba(26, 42, 64, 0.8), rgba(26, 42, 64, 0.6));
}

.event-subtitle {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--secondary-color);
  margin-bottom: 20px;
  font-style: italic;
}

.event-meta {
  display: flex;
  gap: 20px;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 600;
}

.event-meta span {
  background: rgba(255, 255, 255, 0.1);
  padding: 8px 15px;
  border-radius: 5px;
  backdrop-filter: blur(5px);
}

.event-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
}

.content-box {
  background: var(--white);
  padding: 40px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  margin-bottom: 30px;
}

.content-box h2 {
  margin-bottom: 10px;
}

.content-box h3 {
  margin-top: 30px;
  margin-bottom: 15px;
}

.feature-list li {
  margin-bottom: 15px;
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 10px;
  align-items: start;
}

.feature-list i {
  color: var(--secondary-color);
  font-size: 1.2rem;
  margin-top: 2px;
  text-align: center;
}

.alert-box {
  background-color: #fff3cd;
  border-left: 5px solid #ffc107;
  padding: 20px;
  margin-top: 20px;
  border-radius: 5px;
  color: #856404;
  line-height: 1.8;
}

.sidebar-widget {
  background: var(--primary-color);
  color: var(--white);
  padding: 30px;
  border-radius: 10px;
  margin-bottom: 30px;
}

.sidebar-widget h3 {
  color: var(--secondary-color);
  margin-bottom: 20px;
}

.day-schedule {
  margin-bottom: 25px;
}

.day-schedule:last-child {
  margin-bottom: 0;
}

.day-schedule h4 {
  color: var(--white);
  margin-bottom: 15px;
  font-size: 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2); /* Lekka linia oddzielająca dni */
  padding-bottom: 8px;
}

.day-schedule li {
  margin-bottom: 10px;
  display: flex;
  gap: 10px;
}

.day-schedule span {
  font-weight: 800;
  color: var(--secondary-color);
  min-width: 45px;
}

.full-width {
  display: block;
  width: 100%;
  text-align: center;
  margin-bottom: 15px;
}

.action-widget .btn-secondary {
  /* Zmieniamy kolor tekstu i ramki na granatowy, bo tło jest białe */
  color: var(--primary-color);
  border-color: var(--primary-color);
  background-color: transparent;
  display: block;
  width: 100%;
  text-align: center;
  margin-bottom: 15px;
  box-sizing: border-box;
}

.action-widget .btn-secondary:hover {
  /* Przy najechaniu przycisk wypełnia się granatem, a tekst staje się biały */
  background-color: var(--primary-color);
  color: var(--white);
}

/* Dodatkowo upewnijmy się, że przycisk "Zapisz się" też ma pełną szerokość */
.action-widget .btn-primary-large {
  display: block;
  width: 100%;
  text-align: center;
  box-sizing: border-box;
}

.action-widget {
  background: var(--white);
  border: 2px solid var(--primary-color);
  color: var(--text-color);
}

.action-widget h3 {
  color: var(--primary-color);
}

@media (max-width: 900px) {
  .event-layout {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .event-meta {
    flex-direction: column;
    gap: 10px;
  }
}

@media (max-width: 768px) {
  .content-box,
  .sidebar-widget {
    padding: 20px;
  }

  .event-subtitle {
    font-size: 1.2rem;
  }

  .content-box h2 {
    font-size: 1.6rem;
  }
}

@media (max-width: 480px) {
  .event-hero {
    min-height: 40vh;
    padding-top: 80px;
  }

  .event-meta span {
    font-size: 0.9rem;
    padding: 6px 12px;
  }

  .content-box,
  .sidebar-widget {
    padding: 16px;
  }
}

.season-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.season-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.9rem;
}

.season-list li:last-child {
  border-bottom: none;
}

.season-list .s-date {
  font-weight: 800;
  color: var(--secondary-color);
  min-width: 90px;
  flex-shrink: 0;
  font-size: 0.82rem;
}

.season-list li.done {
  opacity: 0.5;
}

.season-list .s-done {
  font-size: 0.75rem;
  font-style: italic;
  margin-left: auto;
  white-space: nowrap;
}

/* --- GALERIA TURNIEJOWA --- */

.t-gallery-masonry {
  columns: 4;
  column-gap: 10px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

.t-gallery-item {
  break-inside: avoid;
  display: block;
  margin: 0 0 10px;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
}

.t-gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.t-gallery-item:hover img {
  transform: scale(1.04);
  opacity: 0.82;
}

.t-gallery-item:focus-visible {
  outline: 3px solid var(--secondary-color);
  outline-offset: 2px;
}

/* --- LIGHTBOX --- */

dialog.t-lightbox {
  border: none;
  background: none;
  padding: 0;
  margin: 0;
  inset: 0;
  width: 100vw;
  height: 100vh;
  max-width: 100vw;
  max-height: 100vh;
  overflow: hidden;
}

dialog.t-lightbox[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}

dialog.t-lightbox::backdrop {
  background: rgba(0, 0, 0, 0.93);
}

.t-lightbox-img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  display: block;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
}

.t-lightbox-close,
.t-lightbox-prev,
.t-lightbox-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  color: #fff;
  cursor: pointer;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  transition: background 0.2s;
  backdrop-filter: blur(6px);
  flex-shrink: 0;
}

.t-lightbox-close:hover,
.t-lightbox-prev:hover,
.t-lightbox-next:hover {
  background: rgba(255, 255, 255, 0.28);
}

.t-lightbox-close {
  top: 18px;
  right: 18px;
}

.t-lightbox-prev {
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
}

.t-lightbox-next {
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
}

.t-lightbox-counter {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.85rem;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 0.06em;
  white-space: nowrap;
  pointer-events: none;
}

@media (max-width: 1200px) {
  .t-gallery-masonry { columns: 3; }
}

@media (max-width: 768px) {
  .t-gallery-masonry {
    columns: 2;
    column-gap: 8px;
    padding: 0 12px;
  }
  .t-gallery-item { margin-bottom: 8px; }
  .t-lightbox-prev,
  .t-lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .t-gallery-masonry { columns: 2; }
}
