/*************************************************/
/******           Shared Styles              *****/
/*************************************************/
.section {
  padding: 4rem;
}

@media (max-width: 1300px) {
  .section {
    padding: 2rem;
  }
}

@media (max-width: 580px) {
  .section {
    padding: 2rem 20px;
  }
}
/* Fade in effects  */
.fade-in-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1.2s ease-out, transform 1.2s ease-out;
}
.fade-in-visible {
  opacity: 1;
  transform: translateY(0);
}

/*************************************************/
/******            Title Section             *****/
/*************************************************/
.section.title-section {
  padding: 2rem;
  background: var(--salsa-gradient-1);
  box-shadow: inset 0px 0px 20px -8px black;
}
section.section.title-section h1 {
  text-align: center;
  margin: auto;
  color: var(--salsa-white);
}

/*************************************************/
/******             Main Menu                *****/
/*************************************************/
.first-sentence {
  /* color: #e01e45; */
  font-size: 30px;
  font-weight: 600;
}
.page-description {
  max-width: 1240px;
  margin: 0 auto 64px;
}

.event-section {
}
.events-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  max-width: 1240px;
  margin: 0 auto;
}

.event-card {
  box-sizing: border-box;
  position: relative;
  flex: 0 0 calc(50% - 0.8rem);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0px 0px 15px -6px grey;
}

.event-card:hover {
  opacity: 1;
}

.event-filter {
  width: 100%;
  height: 100%;
}

.event-filter img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-card:hover .event-filter img {
  transform: scale(1.05);
  transition: transform 0.3s ease;
  /* Smooth animation */
}

.event-name {
  font-size: 1.3rem;
  margin: auto;
  color: var(--salsa-white);
}

p.event-date {
  margin: auto;
  font-size: 1rem;
  color: var(--salsa-sky-blue);
}

.event-filter::after {
  position: absolute;
  bottom: 0;
  display: block;
  content: "";
  width: 100%;
  height: 70%;
  background: linear-gradient(0deg, #000000, transparent);
}

.info {
  position: absolute;
  bottom: 0;
  padding: 0 1.2rem 1rem;
  width: 100%;
}

.event-tag {
  font-size: 1rem;
  margin: 0 auto 10px;
}

.festival {
  color: var(--salsa-yellow);
}

p.tag {
  position: absolute;
  top: 20px;
  padding: 10px;
  border-radius: 0 10px 10px 0;
  font-weight: 600;
  color: var(--salsa-sky-blue);
  background: var(--salsa-white);
  box-shadow: 4px 3px 20px -5px black;
}

@media (max-width: 1300px) {
  .event-card {
    flex: 0 0 calc(50% - 0.5rem);
  }
}

@media (max-width: 768px) {
  .event-card {
    flex: 0 0 100%;
  }
}

/*************************************************/
/******           Gallery Preview            *****/
/*************************************************/
#galleryPreview {
  display: none;
}

.gallery-btn {
  background-color: white !important;
  border: solid;
  border-color: #e01e45;
  border-width: 3px;
  border-radius: 6px;
  color: #e01e45 !important;
  font-family: Lemonmilk !important;
  margin: 0 0 40px;
  padding: 16px 24px;
  transition: transform 0.3s;
}

.gallery-btn:hover {
  background-color: #e01e45 !important;
  border-color: white;
  color: white !important;
  transform: scale(1.1);
}

/*************************************************/
/******               Tabs                   *****/
/*************************************************/
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.tab {
  padding: 12px 16px;
  background: #eee;
  border: none;
  cursor: pointer;
  border-radius: 6px;
}

.tab:hover {
  background: #e01e45;
  color: white;
}

.tab.active {
  background: #e01e45;
  color: white;
}

/*************************************************/
/******               Cards                  *****/
/*************************************************/
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  justify-items: center; /* Optional: center cards in grid cells */
}

.gallery-card {
  aspect-ratio: 3 / 2; /* Keeps consistent width/height ratio */
  background: #eee;
  border: solid;
  border-color: #eee;
  border-radius: 12px;
  border-width: 3px;
  box-shadow: 0px 0px 10px -6px black;
  color: black !important;
  overflow: hidden;
  padding: 0;
  text-align: center;
  text-decoration: none;
  transition: transform 0.3s;
  width: 100%;
}

.gallery-card:hover {
  background-color: #e01e45;
  color: white !important;
  cursor: pointer;
  border: solid;
  border-color: #e01e45;
  border-width: 3px;
  transform: scale(1.03);
}

.card-image-wrapper {
  width: 100%;
  height: 85%;
  overflow: hidden;
  border-radius: 4px;
}
.card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-title-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 15%;
}
.card-title {
  font-size: 20px;
  margin: 0;
}

/* Tablet: 3 cards per row */
@media only screen and (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile: 2 cards per row */
@media only screen and (max-width: 580px) {
  .gallery-grid {
    grid-template-columns: repeat(1, 1fr);
  }
  .tabs {
    justify-content: center;
  }
}
