/*
 * Basic styling for the BAC Pulse website.  
 * The design takes inspiration from neon club signage with a dark background  
 * and colored accents corresponding to musical genres.  
 */

/* Global resets */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background-color: #0a0a23;
  color: #f5f5f5;
  line-height: 1.4;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  background-color: #111138;
  border-bottom: 2px solid #222255;
}

header h1 {
  font-size: 1.8rem;
  font-weight: bold;
  letter-spacing: 1px;
  color: #39ff14; /* neon green title */
}

/* Brand area: displays the "BAC" text alongside the flame logo */
.brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* BAC text styling reused from the original header h1 */
.brand-text {
  font-size: 1.8rem;
  font-weight: bold;
  letter-spacing: 1px;
  color: #39ff14;
}

/* Flame logo: crop to show only the flames from pulseflame.png */
.brand-logo {
  height: 36px;
  width: auto;
  object-fit: cover;
  object-position: top;
  /* Slight glow to match neon aesthetics */
  filter: drop-shadow(0 0 4px rgba(255, 140, 0, 0.6));
}

/* Global flame counter next to the week selector */
.global-flame {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 1rem;
  color: #ff867c;
  margin-right: 0.6rem;
  user-select: none;
}

.global-flame .flame-icon {
  font-size: 1.3rem;
  line-height: 1;
}

/* Genre legend styling */
.genre-legend {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #222255;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.genre-legend .legend-title {
  font-size: 0.9rem;
  color: #8888c0;
}

.genre-legend .legend-items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  font-size: 0.8rem;
}

.genre-legend .legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.genre-legend .legend-color {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 3px;
  /* small box shadow for neon effect */
  box-shadow: 0 0 4px currentColor;
}

/* Week selector */
.week-selector {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1rem;
  color: #eee;
}

.week-selector button {
  background: transparent;
  border: none;
  color: #39ff14;
  font-size: 1.4rem;
  cursor: pointer;
  transition: color 0.2s ease;
}

.week-selector button:hover {
  color: #00ffff;
}

/* Today button styling */
.week-selector #today-btn {
  font-size: 0.9rem;
  padding: 0.25rem 0.5rem;
  margin-left: 0.5rem;
  background-color: transparent;
  border: 1px solid #39ff14;
  border-radius: 4px;
  color: #39ff14;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.week-selector #today-btn:hover {
  background-color: #39ff14;
  color: #0a0a23;
}

main {
  flex: 1;
  padding: 1rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

section.hot-section h2,
section.events-section h2 {
  margin-bottom: 0.5rem;
  font-size: 1.4rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #ff0080; /* neon pink for headings */
}

/* Day selector grid */
.day-selector {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.day-selector .day {
  background-color: #1a1a3d;
  border-radius: 6px;
  padding: 0.5rem 0.3rem;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
  border: 1px solid #33335a;
  user-select: none;
  position: relative; /* allow overlay elements like hot icons */
}

/* Flame icon for days containing hot events */
.day-selector .day .hot-icon {
  position: absolute;
  top: 2px;
  right: 2px;
  font-size: 0.9rem;
  pointer-events: none;
}

.day-selector .day.active {
  background-color: #33336b;
  border-color: #00ffff;
}

.day-selector .day .weekday {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: #aaaadc;
}

.day-selector .day .date {
  font-size: 1.2rem;
  font-weight: bold;
  color: #fff;
}

/* Event container holds event cards */
.event-container {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

/* Event card styling */
.event-card {
  position: relative;
  background-color: #11112a;
  border-left: 6px solid #39ff14;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}

.event-card .info {
  flex: 1;
  padding-right: 1rem;
}

.event-card h3 {
  margin-bottom: 0.3rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: #ffffff;
}

.event-card .meta {
  font-size: 0.85rem;
  color: #ccccff;
  margin-bottom: 0.3rem;
}

.event-card .location {
  font-size: 0.8rem;
  color: #8888c0;
}

.event-card .vote {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  cursor: pointer;
  min-width: 50px;
  color: #ff6f61;
  transition: transform 0.1s ease;
}

.event-card .vote:hover {
  transform: scale(1.1);
}

.event-card .vote svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.event-card .vote .count {
  font-size: 0.9rem;
  color: #ff867c;
  font-weight: bold;
}

/* Location list styling */
.location-list {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.location-list .location-item {
  background-color: #1a1a3d;
  border: 1px solid #33335a;
  border-radius: 12px;
  padding: 0.3rem 0.6rem;
  font-size: 0.8rem;
  color: #ccccff;
  white-space: nowrap;
}

/* Hot three cards emphasise ranking */
#hot-three-list .event-card {
  border-color: #ff007f;
  background-color: #1f1f3e;
}

/* Podium styling for Hot Three section */
.hot-section #hot-three-list {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 1rem;
}

.hot-section #hot-three-list .event-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem;
  text-align: center;
}

.hot-section #hot-three-list .rank-1 {
  flex: 1;
  transform: translateY(-12px);
}
.hot-section #hot-three-list .rank-2,
.hot-section #hot-three-list .rank-3 {
  flex: 0.8;
}
.hot-section #hot-three-list .rank-1::after {
  content: '';
  position: absolute;
  top: -6px;
  bottom: -6px;
  left: -6px;
  right: -6px;
  border-radius: 10px;
  box-shadow: 0 0 8px 2px #ff007f, 0 0 16px 4px #ff007f;
  pointer-events: none;
}

/* Links styling within event cards */
.event-card .links {
  margin-top: 0.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.event-card .links a {
  font-size: 0.75rem;
  color: #39ff14;
  text-decoration: underline;
  transition: color 0.2s ease;
}

.event-card .links a:hover {
  color: #00ffff;
}

/* Responsive adjustments */
@media (max-width: 700px) {
  .day-selector {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.4rem;
  }
  .event-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .event-card .vote {
    flex-direction: row;
    margin-top: 0.5rem;
  }
  .event-card .vote .count {
    margin-left: 0.3rem;
  }
}