:root {
  --brand-dark: #001f4d;
  --brand-yellow: #fecf07;
  --brand-blue: #2563eb;
  --brand-blue-dark: #1d4ed8;
  --brand-blue-light: #3b82f6;
}

.events-section {
  padding: 60px 0;
  background: #f8fafc;
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Events Header */
.events-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: white;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-bottom: 30px;
}

.events-controls {
  display: flex;
  gap: 20px;
  align-items: center;
}

.search-container {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input {
  padding: 12px 45px 12px 15px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-family: "Source Sans Pro", sans-serif;
  font-size: 1rem;
  width: 300px;
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-btn {
  position: absolute;
  right: 5px;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.3s ease;
}

.search-btn:hover {
  background: rgba(37, 99, 235, 0.1);
}

.filter-container {
  display: flex;
  gap: 15px;
}

.filter-select {
  padding: 12px 15px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-family: "Source Sans Pro", sans-serif;
  font-size: 1rem;
  background: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-select:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.events-stats {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

.stat-item {
  text-align: center;
  min-width: 80px;
}

.stat-number {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--brand-blue);
  font-family: "Merriweather", serif;
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: #64748b;
  font-family: "Source Sans Pro", sans-serif;
  margin-top: 5px;
  display: block;
}

/* Quick Navigation */
.quick-nav {
  display: flex;
  gap: 10px;
  margin-bottom: 40px;
  justify-content: center;
  flex-wrap: wrap;
}

.nav-btn {
  padding: 12px 24px;
  border: 2px solid #e2e8f0;
  background: white;
  border-radius: 25px;
  font-family: "Source Sans Pro", sans-serif;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  color: #64748b;
}

.nav-btn:hover,
.nav-btn.active {
  border-color: var(--brand-blue);
  background: var(--brand-blue);
  color: white;
}

/* Section Titles */
.section-title {
  font-family: "Merriweather", serif;
  font-size: 2rem;
  color: var(--brand-dark);
  margin-bottom: 30px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 15px;
}

.title-icon {
  font-size: 1.5rem;
}

/* Featured Events */
.featured-section {
  margin-bottom: 60px;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
  gap: 30px;
}

.featured-event {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  position: relative;
}

.featured-event:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.featured-event .event-image {
  position: relative;
  height: 250px;
  overflow: hidden;
}

.featured-event .event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.featured-event:hover .event-image img {
  transform: scale(1.05);
}

.event-status-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.status-upcoming {
  background: rgba(16, 185, 129, 0.9);
  color: white;
}

.status-past {
  background: rgba(156, 163, 175, 0.9);
  color: white;
}

.status-cancelled {
  background: rgba(239, 68, 68, 0.9);
  color: white;
}

.event-date-overlay {
  position: absolute;
  top: 15px;
  left: 15px;
  background: var(--brand-dark);
  padding: 10px;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.date-month {
  font-size: 0.8rem;
  color: white;
  font-weight: 600;
  text-transform: uppercase;
}

.date-day {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--brand-yellow);
  line-height: 1;
}

.featured-event .event-content {
  padding: 25px;
}

.event-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  font-size: 0.9rem;
  color: #64748b;
}

.event-name {
  background: rgba(37, 99, 235, 0.1);
  color: var(--brand-blue);
  padding: 4px 8px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.8rem;
}

.event-title {
  margin-bottom: 15px;
}

.event-title a {
  color: var(--brand-dark);
  text-decoration: none;
  font-family: "Merriweather", serif;
  font-size: 1.3rem;
  font-weight: 700;
  line-height: 1.4;
  transition: color 0.3s ease;
}

.event-title a:hover {
  color: var(--brand-blue);
}

.event-excerpt {
  color: #475569;
  line-height: 1.6;
  margin-bottom: 20px;
  font-family: "Source Sans Pro", sans-serif;
}

.event-actions {
  display: flex;
  gap: 15px;
  align-items: center;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-blue);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-family: "Source Sans Pro", sans-serif;
  transition: all 0.3s ease;
}

.btn-primary:hover {
  background: var(--brand-blue-dark);
  transform: translateX(5px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  color: var(--brand-blue);
  border: 2px solid var(--brand-blue);
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 600;
  font-family: "Source Sans Pro", sans-serif;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--brand-blue);
  color: white;
}

/* Events Grid */
.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
  margin-bottom: 40px;
}

.event-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.6s ease;
  opacity: 0;
  transform: translateY(30px);
  animation: slideInUp 0.6s ease forwards;
}

.event-card {
  transition: all 0.6s ease;
}

.event-card.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.event-card:nth-child(1) {
  animation-delay: 0.1s;
}
.event-card:nth-child(2) {
  animation-delay: 0.2s;
}
.event-card:nth-child(3) {
  animation-delay: 0.3s;
}
.event-card:nth-child(4) {
  animation-delay: 0.4s;
}
.event-card:nth-child(5) {
  animation-delay: 0.5s;
}
.event-card:nth-child(6) {
  animation-delay: 0.6s;
}

.event-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 20px 0;
}

.event-date-card {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand-blue));
  color: white;
  padding: 12px;
  border-radius: 8px;
  text-align: center;
  min-width: 60px;
}

.event-date-card .date-month {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  opacity: 0.9;
}

.event-date-card .date-day {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1;
}

.event-date-card .date-year {
  font-size: 0.7rem;
  opacity: 0.8;
}

.date-year {
  color: white;
}

.event-status {
  margin-top: 5px;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
}

.event-card .event-image {
  height: 180px;
  overflow: hidden;
  margin: 15px 20px 0;
  border-radius: 8px;
}

.event-card .event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.event-card:hover .event-image img {
  transform: scale(1.03);
}

.placeholder-image {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-icon {
  font-size: 3rem;
  opacity: 0.5;
}

.event-card .event-content {
  padding: 20px;
}

.event-card .event-meta {
  margin-bottom: 12px;
  font-size: 0.85rem;
}

.event-card .event-title {
  margin-bottom: 12px;
}

.event-card .event-title a {
  font-size: 1.1rem;
  line-height: 1.3;
}

.event-card .event-excerpt {
  margin-bottom: 15px;
  font-size: 0.9rem;
}

.event-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 15px;
  border-top: 1px solid #e2e8f0;
}

.read-more-link {
  color: var(--brand-blue);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: all 0.3s ease;
}

.read-more-link:hover {
  color: var(--brand-blue-dark);
  transform: translateX(3px);
}

.event-actions-mini {
  display: flex;
  gap: 10px;
}

.action-btn {
  background: none;
  border: 2px solid #e2e8f0;
  padding: 8px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  color: #64748b;
}

.action-btn:hover {
  border-color: var(--brand-blue);
  color: var(--brand-blue);
  background: rgba(37, 99, 235, 0.05);
}

/* Calendar Widget */
.calendar-widget {
  background: white;
  padding: 25px;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-top: 40px;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.calendar-widget h3 {
  font-family: "Merriweather", serif;
  color: var(--brand-dark);
  margin-bottom: 20px;
  text-align: center;
}

.mini-calendar {
  /* Calendar styles will be added by JavaScript */
  margin-bottom: 15px;
}

.calendar-legend {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #64748b;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.legend-dot.upcoming {
  background: var(--brand-blue);
}

.legend-dot.past {
  background: #94a3b8;
}

/* No Events State */
.no-events {
  text-align: center;
  padding: 60px 20px;
  color: #64748b;
}

.no-events-icon {
  font-size: 4rem;
  margin-bottom: 20px;
  opacity: 0.5;
}

.no-events h3 {
  font-family: "Merriweather", serif;
  color: var(--brand-dark);
  margin-bottom: 10px;
}

.no-events p {
  margin-bottom: 20px;
}

/* Load More */
.load-more-section {
  text-align: center;
  margin-top: 40px;
}

.load-more-btn {
  background: var(--brand-blue);
  color: white;
  border: none;
  padding: 15px 30px;
  border-radius: 8px;
  font-family: "Source Sans Pro", sans-serif;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.load-more-btn:hover {
  background: var(--brand-blue-dark);
  transform: translateY(-2px);
}

/* Share Modal */
.share-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
}

.modal-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border-radius: 15px;
  padding: 30px;
  max-width: 500px;
  width: 90%;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 1px solid #e2e8f0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #64748b;
}

.share-options {
  display: grid;
  gap: 15px;
  margin-bottom: 25px;
}

.share-option {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  text-decoration: none;
  color: #374151;
  transition: all 0.3s ease;
}

.share-option:hover {
  border-color: var(--brand-blue);
  background: rgba(37, 99, 235, 0.05);
}

.copy-link-section {
  display: flex;
  gap: 10px;
}

.copy-link-section input {
  flex: 1;
  padding: 12px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
}

.copy-link-section button {
  background: var(--brand-blue);
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
}

@keyframes slideInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .events-header {
    flex-direction: column;
    gap: 20px;
    align-items: stretch;
  }

  .events-controls {
    flex-direction: column;
    gap: 15px;
  }

  .filter-container {
    flex-direction: column;
  }

  .search-input {
    width: 100%;
  }

  .events-stats {
    gap: 15px;
  }

  .stat-item {
    min-width: 70px;
  }

  .stat-number {
    font-size: 1.5rem;
  }

  .stat-label {
    font-size: 0.8rem;
  }

  .events-stats {
    justify-content: center;
  }

  .featured-grid {
    grid-template-columns: 1fr;
  }

  .events-grid {
    grid-template-columns: 1fr;
  }

  .event-actions {
    flex-direction: column;
    gap: 10px;
  }

  .event-footer {
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  .events-section {
    padding: 40px 0;
  }

  .quick-nav {
    gap: 5px;
  }

  .nav-btn {
    padding: 8px 16px;
    font-size: 0.9rem;
  }
}
