/* ==========================================================================
   1. VARIABLES & GLOBAL STYLES
   ========================================================================== */
:root {
  --primary-color: #2563eb; /* Blue */
  --primary-dark: #1d4ed8;
  --secondary-color: #10b981; /* Teal/Green */
  --secondary-dark: #059669;
  --text-dark: #1f2937;
  --text-light: #4b5563;
  --text-white: #ffffff;
  --background-light: #f9fafb;
  --background-white: #ffffff;
  --background-dark: #111827;
  --border-color: #e5e7eb;
  --header-overlay-gradient: linear-gradient(135deg, rgba(17, 24, 39, 0.8) 0%, rgba(55, 65, 81, 0.8) 100%);
  --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --card-shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  --border-radius: 0.75rem;
  --transition-speed: 0.3s;
  --font-primary: 'Montserrat', sans-serif;
}

/* ==========================================================================
   2. BASE STYLES & RESETS
   ========================================================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
 scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  color: var(--text-light);
  background-color: var(--background-light);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

p {
  margin-bottom: 1rem;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--text-dark);
  font-weight: 700;
  line-height: 1.3;
}

h1 { font-size: 2.5rem; margin-bottom: 0.25rem; }
h2 { font-size: 2.25rem; margin-bottom: 2rem; }
h3 { font-size: 1.5rem; margin-bottom: 1rem; }
h4 { font-size: 1.25rem; margin-bottom: 0.75rem; }

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--transition-speed) ease;
}

a:hover {
  color: var(--primary-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

strong {
  color: var(--text-dark);
  font-weight: 600;
}

/* ==========================================================================
   3. LAYOUT (Container, Header, Footer, Sections)
   ========================================================================== */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

header {
  color: var(--text-white);
  padding: 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 4px solid var(--primary-color);
  background-color: var(--background-dark);
}

header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--header-overlay-gradient), url('https://smashpadelindonesia.com/PXL_20250216_111147448-smaller.webp');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  z-index: 0;
}

.header-content {
  position: relative;
  padding: 2.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3rem;
  z-index: 1;
  min-height: 180px;
}

.logo {
  width: 260px;
  height: auto;
  flex-shrink: 0;
  filter: drop-shadow(0px 4px 5px rgba(0, 0, 0, 0.4));
  transition: transform var(--transition-speed) ease;
}

.logo:hover {
  transform: scale(1.05);
}

.header-text {
  text-align: left;
}

header h1 {
  color: var(--text-white);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

header .subtitle {
  font-size: 1.1rem;
  color: #e5e7eb;
  margin-bottom: 0.5rem;
}

.tagline {
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--secondary-color);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  display: inline-block;
  position: relative;
  margin-top: 0.25rem;
  border-bottom: 2px solid var(--secondary-color);
  padding-bottom: 2px;
}

main {
  /* Wrapper for content switching animation */
  animation: fadeIn 0.5s ease-in-out;
}

.section {
  padding: 4rem 0;
  min-height: 200px;
}

.section-alt {
  background-color: var(--background-white);
  padding: 4rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.section h2 {
  text-align: center;
  position: relative;
  padding-bottom: 0.75rem;
}

.section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.subsection-title {
    font-size: 1.75rem;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    text-align: center;
    font-weight: 600;
}

footer {
  background: var(--background-dark);
  color: #9ca3af;
  text-align: center;
  padding: 3rem 1rem 2rem 1rem;
  margin-top: 4rem;
  border-top: 4px solid var(--primary-color);
}

.footer-logo {
    width: 120px;
    height: auto;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1.5rem;
    opacity: 0.8;
}

footer p {
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}
footer p strong {
    color: #e5e7eb;
}

.footer-links {
    margin: 1.5rem 0;
}

.footer-links a {
  color: var(--secondary-color);
  margin: 0 0.75rem;
  font-weight: 600;
}

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

.copyright {
    margin-top: 2rem;
    font-size: 0.85rem;
    color: #6b7280;
}

/* ==========================================================================
   4. COMPONENTS (Cards, Buttons, Modals, etc.)
   ========================================================================== */

/* --- Cards --- */
.card {
  background: var(--background-white);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-color);
  transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--card-shadow-hover);
}

.card h3 {
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card .icon {
  font-size: 1.5rem;
  color: var(--primary-color);
  line-height: 1;
  flex-shrink: 0;
}

/* Layout Grids for Cards */
.courts, .facilities, .promotions, .locations-grid, .features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}
.locations-grid {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  margin: 2rem 0;
}
.features-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}


/* Card Variants */
.feature-card {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: var(--text-white);
}
.feature-card h3, .feature-card .icon {
  color: var(--text-white);
}
.feature-card p, .feature-card li {
  color: #e0e7ff;
}
.feature-card .info-list li::before,
.feature-card .info-list li .icon {
  color: var(--secondary-color);
}

.founder-card {
  /* Inherits .card styles */
}

.mission-card {
  background: var(--background-white);
  padding: 2rem;
  border-radius: var(--border-radius);
  margin: 2rem 0;
  box-shadow: var(--card-shadow);
  border-left: 5px solid var(--secondary-color);
}
.mission-card h3 {
  color: var(--secondary-color);
  font-size: 1.5rem;
}
.mission-card p {
  color: var(--text-light);
}

/* Location Cards */
.location-card {
  background: var(--background-white);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
  cursor: pointer;
  position: relative;
}
.location-card::after {
  content: "Click to view details →";
  position: absolute;
  bottom: 1rem;
  right: 1.5rem;
  background: var(--primary-color);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--transition-speed) ease, transform var(--transition-speed) ease;
  pointer-events: none;
}
.location-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  border-color: var(--primary-color);
}
.location-card:hover::after {
  opacity: 1;
  transform: translateY(0);
}
.location-card.coming-soon {
  opacity: 0.8;
}
.location-card.coming-soon::after {
  content: "Click for updates →";
  background: var(--secondary-color);
}
.location-card-header {
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  position: relative;
}
.location-card-header h3 {
  color: white;
  margin: 0;
  font-size: 1.25rem;
}
.location-card-header .status {
  font-size: 0.9rem;
  opacity: 0.9;
  margin-top: 0.25rem;
}
.location-card-content {
  padding: 1.5rem;
}
.location-card-content p {
  margin-bottom: 0.75rem;
  color: var(--text-light);
}
.location-card-content .btn {
  margin-top: 1rem;
}
.location-card.coming-soon .location-card-header {
  background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

/* --- Lists (Info, Vision) --- */
.info-list, .vision-list {
  list-style: none;
  padding-left: 0;
  margin: 1.5rem 0;
}
.info-list li, .vision-list li {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}
.info-list li .icon, .vision-list li .icon {
  color: var(--primary-color);
  font-weight: bold;
  margin-top: 2px;
  flex-shrink: 0;
  width: 20px;
  text-align: center;
  line-height: 1.2;
}
.info-list li:not(:has(.icon))::before { /* Fallback bullet */
  content: "•";
  color: var(--primary-color);
  font-weight: bold;
  display: inline-block;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
  margin-top: 2px;
}
.vision-list li .icon {
  color: var(--secondary-color);
}
.info-list.compact li {
  margin-bottom: 0.5rem;
}

/* --- Section-specific Boxes & Elements --- */
.opening-countdown {
  background-color: #fffbeb;
  border-radius: var(--border-radius);
  padding: 1.5rem 2rem;
  text-align: center;
  margin: 2.5rem auto;
  border: 1px solid #fcd34d;
  max-width: 700px;
  box-shadow: var(--card-shadow);
  width: 100%;
  height: auto;
  min-height: 200px;
}
.countdown-title {
  color: #b45309;
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.founder-section {
  margin: 2rem 0;
}
.quote {
  font-style: italic;
  padding: 1.5rem 2rem;
  border-left: 4px solid var(--secondary-color);
  margin: 2rem auto;
  background-color: var(--background-white);
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  max-width: 800px;
  box-shadow: var(--card-shadow);
}
.quote p {
  margin-bottom: 0;
  font-size: 1.1rem;
  color: var(--text-dark);
}
.highlight-box {
  background-color: #eef2ff;
  border-left: 5px solid var(--primary-color);
  padding: 2rem;
  margin: 2rem 0;
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  box-shadow: var(--card-shadow);
}
.highlight-box h3 {
  color: var(--primary-dark);
  font-size: 1.5rem;
}
.hidden {
  display: none !important;
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 0.9rem 2rem;
  font-family: var(--font-primary);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow);
  transition: background-color var(--transition-speed) ease, transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
  cursor: pointer;
  text-align: center;
  border: none;
  font-size: 1rem;
  letter-spacing: 0.5px;
  line-height: 1.5;
}
.btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.1rem;
}
.btn-primary {
  background-color: var(--primary-color);
  color: var(--text-white);
}
.btn-primary:hover {
  background-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--card-shadow-hover);
}
.btn-secondary {
  background-color: var(--secondary-color);
  color: var(--text-white);
}
.btn-secondary:hover {
  background-color: var(--secondary-dark);
  transform: translateY(-2px);
  box-shadow: var(--card-shadow-hover);
}
#welcome .btn-primary {
  display: block;
  width: fit-content;
  margin: 2.5rem auto 0 auto;
}

/* --- Location Selector & Floating Button --- */
.location-selector {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 100;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  border-radius: var(--border-radius);
  box-shadow: var(--card-shadow-hover);
  border: 2px solid var(--primary-dark);
  overflow: hidden;
}
.location-selector::before {
  content: "📍";
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  color: var(--text-white);
  pointer-events: none;
  z-index: 1;
}
.location-selector select {
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  border: none;
  background: transparent;
  color: var(--text-white);
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  outline: none;
  min-width: 220px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}
.location-selector select:focus {
  background: rgba(255, 255, 255, 0.1);
}
.location-selector select option {
  background: var(--background-white);
  color: var(--text-dark);
  padding: 0.75rem 1rem;
  font-weight: 600;
}
.location-selector select option:hover {
  background: var(--background-light);
  color: var(--primary-color);
}
.location-selector select option:checked {
  background: var(--primary-color);
  color: var(--text-white);
}
.location-selector::after {
  content: "▼";
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-white);
  pointer-events: none;
  font-size: 0.8rem;
}
.floating-book-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 99;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: var(--text-white);
  padding: 1rem 2rem;
  border-radius: 50px;
  font-family: var(--font-primary);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3);
  transition: all var(--transition-speed) ease;
  border: none;
  cursor: pointer;
  text-align: center;
  letter-spacing: 0.5px;
  display: none; /* Hidden by default */
}
.floating-book-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.4);
  background: linear-gradient(135deg, var(--primary-dark) 0%, #1e40af 100%);
}
.floating-book-btn.show {
  display: block;
  animation: fadeInUp 0.5s ease;
}

/* --- Badges & Animations --- */
.coming-soon-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-left: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* --- Gallery & Promotions --- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.gallery img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
  border: 1px solid var(--border-color);
}
.gallery img:hover {
  transform: scale(1.03);
  box-shadow: var(--card-shadow-hover);
}
.promo-card {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.promo-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-bottom: 1px solid var(--border-color);
}
.promo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0) 100%);
  color: var(--text-white);
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  opacity: 1;
  transition: opacity var(--transition-speed) ease;
  border-radius: 0 0 var(--border-radius) var(--border-radius);
}
.promo-overlay h4 {
  font-size: 1.2rem;
  color: var(--text-white);
  margin-bottom: 0.25rem;
}
.promo-overlay p {
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: #e5e5e5;
}
.promo-overlay span {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: inline-block;
  border-bottom: 1px solid var(--secondary-color);
  padding-bottom: 1px;
  color: var(--secondary-color);
}

/* --- Modals --- */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  justify-content: center;
  align-items: center;
  padding: 1rem;
  animation: fadeIn 0.3s ease;
}
.modal img {
  max-width: 90%;
  max-height: 85%;
  border-radius: 4px;
  display: block;
  margin: auto;
}
.modal-close {
  position: absolute;
  top: 15px;
  right: 25px;
  font-size: 2.5rem;
  font-weight: bold;
  color: #bbb;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
  padding: 5px;
  transition: color var(--transition-speed) ease;
}
.modal-close:hover {
  color: var(--text-white);
}
.modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(0, 0, 0, 0.4);
  color: white;
  border: none;
  padding: 1rem 0.8rem;
  font-size: 1.5rem;
  cursor: pointer;
  border-radius: 50%;
  transition: background-color var(--transition-speed) ease;
  line-height: 1;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-nav:hover {
  background-color: rgba(0, 0, 0, 0.7);
}
.modal-nav.prev {
  left: 15px;
}
.modal-nav.next {
  right: 15px;
}

/* ==========================================================================
   5. RESPONSIVE DESIGN
   ========================================================================== */

/* Tablet and smaller */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.8rem; }
  .subsection-title { font-size: 1.5rem; }

  .logo {
    width: 220px;
  }
  .header-content {
    gap: 2rem;
  }

  .courts, .facilities, .promotions, .locations-grid, .features-grid {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 1.5rem;
  }
  .location-card::after {
    bottom: 0.75rem;
    right: 1rem;
    font-size: 0.75rem;
    padding: 0.4rem 0.8rem;
  }

  .modal img {
    max-width: 95%;
    max-height: 80%;
  }
  .modal-nav {
    padding: 0.8rem 0.6rem;
    font-size: 1.2rem;
    width: 40px;
    height: 40px;
  }
  .modal-nav.prev { left: 5px; }
  .modal-nav.next { right: 5px; }

  .location-selector {
    position: relative;
    top: auto;
    right: auto;
    margin: 1rem auto;
    width: calc(100% - 2rem);
    max-width: 300px;
  }
  .location-selector select {
    width: 100%;
    text-align: center;
    min-width: auto;
  }
  .floating-book-btn {
    bottom: 20px;
    right: 15px;
    padding: 0.9rem 1.5rem;
    font-size: 0.9rem;
  }
}

/* Mobile */
@media (max-width: 640px) {
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.6rem; margin-bottom: 1.5rem; }
  .subsection-title { font-size: 1.3rem; }

  .header-content {
    flex-direction: column;
    padding: 2rem 1rem;
    gap: 1.5rem;
    min-height: auto;
  }
  .logo {
    width: 200px;
    margin-bottom: 0;
  }
  .header-text {
    text-align: center;
  }

  .section, .section-alt {
    padding: 2.5rem 0;
  }

  .btn {
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
  }
  .btn-lg {
    padding: 0.9rem 2rem;
    font-size: 1rem;
  }

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

  .footer-links a {
    margin: 0 0.5rem;
    display: inline-block;
    margin-bottom: 0.5rem;
  }
}