#paypal-button-container {
  width: 100% !important;
  text-align: center;
}

:root {
  --primary: #002D62;
  /* Baseball Blue */
  --secondary: #BA0021;
  /* Baseball Red */
  --accent: #FDB827;
  /* Generic Baseball Yellow/Gold accent */
  --dark: #212529;
  --light: #f8f9fa;
  --lightblue: #7ba5d6;
  --white: #ffffff;
  --gray: #6c757d;
  --border: #e9ecef;
  --header-height: 70px;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--dark);
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background-color: var(--light);
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  margin-top: 0;
  color: var(--primary);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s;
}

a:hover {
  color: var(--lightblue);
}

/* Utils */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
  font-size: 2.5rem;
  position: relative;
  padding-bottom: 1rem;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--secondary);
  margin: 0.5rem auto 0;
}

.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
}

.btn-primary {
  background-color: var(--secondary);
  /* Red button stands out more */
  color: var(--white);
}

.btn-primary:hover {
  background-color: #a0001c;
  color: var(--white);
}

.btn-outline {
  border: 2px solid var(--white);
  color: var(--white);
}

.btn-outline:hover {
  background-color: var(--white);
  color: var(--primary);
}

/* Navigation */
.navbar {
  background-color: var(--primary);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
  height: var(--header-height);
  display: flex;
  align-items: center;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.brand {
  color: var(--white);
  font-size: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--white);
  font-size: 1rem;
  font-weight: 500;
}

.nav-links a:hover {
  color: var(--lightblue);
}

.mobile-menu-btn {
  display: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
}

/* Hero Section */
.hero {
  height: 50vh;
  background: url('../images/backgrounds/bbslogo.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  background-color: #fff;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 8rem;
}

.hero-content {
  text-align: center;
  padding: 0 1rem;
}

.hero-content h1 {
  font-size: 3.5rem;
  color: var(--white);
  margin-bottom: 1.5rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-content p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  color: var(--white);
}

/* About & Instructors */
.bg-white {
  background-color: var(--white);
}

.instructor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.instructor-card {
  text-align: center;
  padding: 2rem;
  background: var(--light);
  border-radius: 8px;
  transition: transform 0.3s;
}

.instructor-card:hover {
  transform: translateY(-5px);
}

.instructor-img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1rem;
  border: 4px solid var(--primary);
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* Events Section */
.events-section {
  background-color: #f1f3f5;
}

.events-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

/* Event Card (Horizontal List Style) */
.event-card {
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  border-left: 5px solid var(--primary);
}

@media(min-width: 768px) {
  .event-card {
    flex-direction: row;
    align-items: center;
  }
}

.event-date {
  background-color: var(--primary);
  color: var(--white);
  padding: 1.5rem;
  text-align: center;
  min-width: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.event-date .month {
  text-transform: uppercase;
  font-size: 0.9rem;
  font-weight: 700;
}

.event-date .day {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
}

.event-details {
  padding: 1.5rem;
  flex-grow: 1;
}

.event-title {
  margin: 0 0 0.5rem 0;
  font-size: 1.5rem;
}

.event-meta {
  color: var(--gray);
  margin-bottom: 1rem;
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.event-meta i {
  width: 20px;
  text-align: center;
  color: var(--secondary);
}

.event-action {
  padding: 1.5rem;
  text-align: center;
  min-width: 175px;
  background-color: var(--light);
  border-top: 1px solid var(--border);
}

@media(min-width: 768px) {
  .event-action {
    border-top: none;
    border-left: 1px solid var(--border);
    background-color: transparent;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
}

.event-price {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 0.5rem;
}

/* Contact Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media(min-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.contact-info {
  font-size: 1.1rem;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 1.5rem;
}

.contact-item i {
  font-size: 1.5rem;
  color: var(--secondary);
  margin-right: 1rem;
  margin-top: 0.2rem;
  width: 25px;
}

/* Footer */
footer {
  background-color: var(--primary);
  color: var(--white);
  padding: 2rem 0;
  text-align: center;
}

/* Utilities */
.text-center {
  text-align: center;
}

.d-none {
  display: none;
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background-color: var(--primary);
    padding: 1rem 0;
    text-align: center;
  }

  .nav-links.active {
    display: flex;
  }

  .mobile-menu-btn {
    display: block;
  }

  .hero-content h1 {
    font-size: 2.5rem;
  }
}

/* Carousel */
.carousel {
  position: relative;
  height: auto;
  min-height: 300px;
  width: 90%;
  max-width: 800px;
  margin: 0 auto;
}

.carousel-track-container {
  overflow: hidden;
  height: 100%;
}

.carousel-track {
  padding: 0;
  margin: 0;
  list-style: none;
  display: flex;
  transition: transform 0.5s ease-in-out;
}

.carousel-slide {
  flex: 0 0 100%;
  width: 100%;
  box-sizing: border-box;
  padding: 20px;
}

.testimonial-card {
  background: var(--white);
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.testimonial-card p {
  font-size: 1.1rem;
  font-style: italic;
  margin-bottom: 1.5rem;
}

.testimonial-author {
  font-weight: 700;
  color: var(--primary);
  font-size: 1.2rem;
}

.testimonial-role {
  color: var(--gray);
  font-size: 0.9rem;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  font-size: 2rem;
  color: var(--primary);
  cursor: pointer;
  z-index: 10;
}

.prev-btn {
  left: -40px;
}

.next-btn {
  right: -40px;
}

.carousel-nav {
  display: flex;
  justify-content: center;
  padding: 10px 0;
  margin-top: 1rem;
}

.carousel-indicator {
  border: none;
  width: 12px;
  height: 12px;
  background: #ccc;
  border-radius: 50%;
  margin: 0 5px;
  cursor: pointer;
}

.carousel-indicator.current-slide {
  background: var(--primary);
}

/* Contact Center Layout */
.contact-box {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  background: var(--white);
  padding: 2rem;
}

.contact-items-row {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* Re-use contact-item styling but ensure flex works */
.contact-item {
  display: flex;
  align-items: center;
  text-align: left;
}

.contact-item i {
  font-size: 1.5rem;
  color: var(--secondary);
  margin-right: 15px;
}

/* Responsive */
@media screen and (max-width: 768px) {
  .prev-btn {
    left: -10px;
  }

  .next-btn {
    right: -10px;
  }

  .carousel {
    width: 100%;
  }
}

/* --- Modal & Form Styling --- */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: rgba(0, 0, 0, 0.6);
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
  /* Flex centering */
}

.modal-content {
  background-color: #fff;
  margin: auto;
  /* Fallback */
  width: 90%;
  max-width: 600px;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  /* Prevent checking out of screen */
  position: relative;
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  margin: 0;
  font-size: 1.5rem;
  color: var(--primary);
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  /* Scrollable internal area */
}

.close {
  font-size: 1.5rem;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
  transition: color 0.2s;
  background: none;
  border: none;
  padding: 0;
}

.close:hover {
  color: var(--dark);
}

/* Form Styles */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--dark);
}

.form-control,
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s;
  background-color: #fff;
  box-sizing: border-box;
}

.form-control:focus,
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
}

/* Remove ugly spin buttons on number inputs (Cross-browser solution) */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type=number] {
  -moz-appearance: textfield;
}

/* Footer Section */
footer {
  background-color: var(--dark);
  color: var(--white);
  text-align: center;
  padding: 2rem 0;
}

footer a:hover {
  color: var(--white) !important;
  text-decoration: underline;
}

/* Dynamic Event Image Stylings */
.event-card.has-image {
  flex-direction: column;
}

.event-content-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
}

@media(min-width: 768px) {
  .event-content-wrapper {
    flex-direction: row;
    align-items: stretch;
  }
}

.event-image {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: cover;
  order: -1;
  /* Forces image to top */
  display: block;
  border-bottom: 1px solid var(--border);
}

/* Event Card Portrait Layout: Image Side-by-Side */
@media(min-width: 768px) {
  .event-card.portrait-mode {
    flex-wrap: nowrap;
    align-items: stretch;
    flex-direction: row;
  }

  .event-card.portrait-mode .event-image {
    width: 250px;
    min-width: 250px;
    max-width: 35%;
    height: auto;
    max-height: none;
    order: -1;
    object-fit: contain;
    border-bottom: none;
    border-right: 1px solid var(--border);
  }
}

/* Modal Updates */
.modal-content.has-modal-image {
  max-width: 900px;
  /* Wider modal for image side-by-side */
  display: flex;
  flex-direction: column;
}

.modal-body-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.modal-image-container {
  flex: 1 1 300px;
  display: flex;
  flex-direction: column; /* Stack image and dates vertically */
  justify-content: flex-start;
  align-items: center; /* Center them horizontally */
}

.modal-image {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.modal-form-container {
  flex: 1 1 400px;
}