/* ==========================================================================
   CSS Variables & Tokens
   ========================================================================== */
:root {
  /* Colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f4f5f9;
  --bg-elevated: #ffffff;

  --text-primary: #13182a;
  --text-secondary: #4a5568;
  --text-muted: #718096;

  --accent-primary: #e43d4e;
  /* Energetic Red/Orange */
  --accent-hover: #cc3545;
  --accent-glow: rgba(228, 61, 78, 0.2);

  --border-color: rgba(0, 0, 0, 0.1);
  --border-light: rgba(0, 0, 0, 0.05);

  /* Typography */
  --font-primary: 'Outfit', sans-serif;
  --font-secondary: 'Inter', sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

  /* Layout */
  --container-max-width: 1200px;
  --header-height: 80px;

  /* Z-Index */
  --z-base: 1;
  --z-header: 100;
  --z-modal: 1000;
  --z-toast: 2000;
}

/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-secondary);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-primary);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-md);
  text-transform: uppercase;
  letter-spacing: -0.02em;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

ul {
  list-style: none;
}

/* ==========================================================================
   Layout & Container
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.section {
  padding: var(--space-4xl) 0;
}

/* ==========================================================================
   Typography Utilities
   ========================================================================== */
.text-accent {
  color: var(--accent-primary);
}

.text-secondary {
  color: var(--text-secondary);
}

.text-muted {
  color: var(--text-muted);
}

.text-center {
  text-align: center;
}

/* ==========================================================================
   Components
   ========================================================================== */

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 2rem;
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: none;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background-color: var(--accent-primary);
  color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 25px var(--accent-glow);
}

.btn-outline {
  background-color: transparent;
  color: #ffffff;
  /* White text */
  border: 1px solid #ffffff;
  /* White border */
}

.btn-outline:hover {
  background-color: rgba(255, 255, 255, 0.1);
  /* Subtle white fill on hover */
  color: #ffffff;
  border-color: #ffffff;
}

/* Glass Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-light);
  z-index: var(--z-header);
  display: flex;
  align-items: center;
  transition: background-color var(--transition-normal);
}

.header.scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

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

.header__logo {
  font-family: var(--font-primary);
  font-size: 1.5rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.05em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header__logo-icon {
  color: var(--accent-primary);
}

/* Navigation */
.nav__list {
  display: flex;
  gap: var(--space-xl);
  align-items: center;
}

.nav__link {
  font-family: var(--font-primary);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  position: relative;
  padding: 0.5rem 0;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent-primary);
  transition: width var(--transition-fast);
}

.nav__link:hover,
.nav__link.active {
  color: var(--text-primary);
}

.nav__link:hover::after,
.nav__link.active::after {
  width: 100%;
}

/* Mobile Menu Toggle */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  z-index: calc(var(--z-header) + 1);
}

/* Main Content Area */
#app-content {
  min-height: 100vh;
  padding-top: var(--header-height);
  opacity: 1;
  transition: opacity var(--transition-normal);
}

#app-content.fade-out {
  opacity: 0;
}

/* Footer */
.footer {
  background-color: var(--bg-secondary);
  padding: var(--space-4xl) 0 var(--space-xl);
  border-top: 1px solid var(--border-light);
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-3xl);
  margin-bottom: var(--space-4xl);
}

.footer__col h4 {
  font-size: 1.125rem;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer__links a {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.footer__links a:hover {
  color: var(--accent-primary);
}

.footer__bottom {
  text-align: center;
  padding-top: var(--space-xl);
  border-top: 1px solid var(--border-light);
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */
.glass-panel {
  background: var(--bg-primary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: var(--space-xl);
  transition: opacity var(--transition-normal), transform var(--transition-normal);
}

.glass-panel[hidden] {
  display: none !important;
}

/* ==========================================================================
   Scrolling Reviews Component
   ========================================================================== */
.scrolling-reviews-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 1rem 0;
}

.scrolling-reviews-wrapper::before,
.scrolling-reviews-wrapper::after {
  content: '';
  position: absolute;
  top: 0;
  width: 100px;
  height: 100%;
  z-index: 2;
}

.scrolling-reviews-wrapper::before {
  left: 0;
  background: linear-gradient(to right, var(--bg-primary) 0%, transparent 100%);
}

.scrolling-reviews-wrapper::after {
  right: 0;
  background: linear-gradient(to left, var(--bg-primary) 0%, transparent 100%);
}

.scrolling-reviews-track {
  display: flex;
  gap: 2rem;
  width: max-content;
  animation: scrollLeft 40s linear infinite;
}

.scrolling-reviews-track:hover {
  animation-play-state: paused;
}

.review-card {
  width: 350px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 1.5rem;
  flex-shrink: 0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  transition: transform var(--transition-fast);
}

.review-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-primary);
}

.review-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.review-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.25rem;
}

@keyframes scrollLeft {
  0% {
    transform: translateX(0);
  }

  100% {
    /* 5 cards * 350px + 5 gaps * 2rem(32px) = 1750 + 160 = 1910px */
    transform: translateX(calc(-1 * (350px * 5 + 2rem * 5)));
  }
}

/* ==========================================================================
   GDPR Cookie Banner
   ========================================================================== */
.gdpr-banner {
  position: fixed;
  bottom: -100%;
  left: 0;
  width: 100%;
  background-color: var(--text-primary);
  color: white;
  z-index: var(--z-modal);
  padding: 1.5rem 0;
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.2);
  transition: bottom var(--transition-slow);
  border-top: 3px solid var(--accent-primary);
}

.gdpr-banner.show {
  bottom: 0;
}

.gdpr-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.gdpr-text {
  flex: 1;
  min-width: 250px;
}

.gdpr-text a {
  color: var(--accent-primary);
}

.gdpr-text a:hover {
  text-decoration: none;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */
@media (max-width: 992px) {
  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background-color: var(--bg-primary);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: right var(--transition-normal);
    z-index: var(--z-header);
  }

  .nav.is-open {
    right: 0;
  }

  .nav__list {
    flex-direction: column;
    gap: var(--space-2xl);
    text-align: center;
  }

  .nav__link {
    font-size: 1.5rem;
  }

  .mobile-toggle {
    display: block;
  }
}

@media (max-width: 768px) {
  :root {
    --space-4xl: 3rem;
    --space-xl: 1rem;
    --space-3xl: 2rem;
  }

  h1 {
    font-size: 2.5rem !important;
  }

  h2 {
    font-size: 2rem !important;
  }

  .container {
    padding: 0 var(--space-md);
  }

  .gdpr-container {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }

  .gdpr-actions {
    width: 100%;
    justify-content: center;
  }

  .discipline-row .discipline-text {
    order: 1;
  }

  .discipline-row .discipline-img {
    order: 2;
  }
}

/* ==========================================================================
   Schedule Grid Styles
   ========================================================================== */

.schedule-tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.schedule-tabs .btn-outline {
  color: var(--text-primary);
  border-color: var(--border-color);
}

.schedule-tabs .btn-outline:hover {
  background-color: var(--bg-secondary);
  color: var(--accent-primary);
  border-color: var(--accent-primary);
}

.schedule-scroll-hint {
  display: none;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.8rem;
  margin-bottom: 0.5rem;
  opacity: 0.7;
}

.schedule-container {
  margin-top: 2rem;
  margin-bottom: 2rem;
  opacity: 1;
  transition: opacity var(--transition-normal);
  animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

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

.schedule-container[hidden] {
  display: none !important;
}

.schedule-wrapper {
  overflow-x: auto;
  border-radius: 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  /* Same as .glass-panel */
  padding: 1px;
}

.schedule-grid {
  display: grid;
  grid-template-columns: 80px repeat(7, minmax(130px, 1fr));
  gap: 1px;
  background-color: var(--border-light);
  /* Forms the grid lines */
  min-width: 1050px;
  border-radius: 11px;
  overflow: hidden;
}

.grid-header {
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-family: var(--font-primary);
  font-weight: 700;
  padding: 0.25rem 0.5rem;
  min-height: 30px !important;
  /* Force override .grid-cell min-height */
  height: 30px !important;
  /* Force override .grid-cell height */
  text-align: center;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.grid-cell {
  background: var(--bg-primary);
  min-height: 100px;
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  justify-content: stretch;
  align-items: stretch;
  transition: background var(--transition-normal);
  position: relative;
}

.grid-cell:hover:not(.grid-header):not(.time-cell) {
  background: var(--bg-secondary);
}

.time-cell {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.875rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  /* Align to top */
  align-items: center;
  padding-top: 0.75rem;
  position: relative;
}

.time-cell::after {
  content: '';
  position: absolute;
  top: 0;
  right: -1px;
  /* Overlap grid line */
  width: 100%;
  height: 1px;
  background-color: var(--accent-primary);
  opacity: 0.2;
}

/* Add a subtle visual cue for the half-hour mark if needed, or just keep it clean */


.class-block {
  font-size: 0.8rem;
  font-weight: 700;
  text-align: center;
  padding: 0.5rem;
  border-radius: 4px;
  width: 100%;
  height: 100%;
  min-height: 80px;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  line-height: 1.3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  border: 1px solid var(--border-color);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  transition: background-color 0.2s ease;
  border-left-width: 4px;
  border-left-style: solid;
}

.class-block:hover {
  background-color: var(--bg-secondary);
}

/* Minimal Gym Colors */
.class-tehnica {
  border-left-color: #34495e;
  /* Dark Gray-Blue */
  background-color: rgba(52, 73, 94, 0.05);
  /* Very light tint */
}

.class-tehnica:hover {
  background-color: rgba(52, 73, 94, 0.1);
}

.class-sparring {
  border-left-color: #e43d4e;
  /* Primary Red */
  background-color: rgba(228, 61, 78, 0.05);
}

.class-sparring:hover {
  background-color: rgba(228, 61, 78, 0.1);
}

.class-sac {
  border-left-color: #f39c12;
  /* Warning Orange */
  background-color: rgba(243, 156, 18, 0.05);
}

.class-sac:hover {
  background-color: rgba(243, 156, 18, 0.1);
}

.class-copii {
  border-left-color: #27ae60;
  /* Athletic Green */
  background-color: rgba(39, 174, 96, 0.05);
}

.class-copii:hover {
  background-color: rgba(39, 174, 96, 0.1);
}

.class-mma {
  border-left-color: #8e44ad;
  /* Deep Purple */
  background-color: rgba(142, 68, 173, 0.05);
}

.class-mma:hover {
  background-color: rgba(142, 68, 173, 0.1);
}

.class-bjj {
  border-left-color: #16a085;
  /* Teal */
  background-color: rgba(22, 160, 133, 0.05);
}

.class-bjj:hover {
  background-color: rgba(22, 160, 133, 0.1);
}

.class-autoaparare {
  border-left-color: #d35400;
  /* Rust/Orange */
  background-color: rgba(211, 84, 0, 0.05);
}

.class-autoaparare:hover {
  background-color: rgba(211, 84, 0, 0.1);
}

/* Add specific styling to the text inside to make it look tougher */
.class-block br {
  margin-bottom: 2px;
}

@media (max-width: 991px) {
  .schedule-wrapper {
    margin: 0;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
}

@media (max-width: 768px) {
  .schedule-section {
    padding-top: 8vh !important;
  }

  .schedule-tabs {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    margin-bottom: 2rem;
  }

  .schedule-tabs .btn {
    width: 100%;
    text-align: center;
    padding: 0.875rem 1rem;
    font-size: 1rem;
  }

  .schedule-scroll-hint {
    display: block;
  }

  .schedule-wrapper {
    -webkit-overflow-scrolling: touch;
    overflow-x: auto;
    margin-left: calc(-1 * var(--space-md));
    margin-right: calc(-1 * var(--space-md));
  }
}

/* ==========================================================================
   Mobile Fixed Action Buttons
   ========================================================================== */
.mobile-actions {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  pointer-events: none;
  z-index: var(--z-modal);
  padding: 1.5rem;
  justify-content: space-between;
  align-items: flex-end;
}

.mobile-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  color: white;
  font-size: 1.75rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  pointer-events: auto;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  text-decoration: none;
}

.mobile-action-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  color: white;
}

.whatsapp-btn {
  background-color: #25d366;
  /* Vibrant WhatsApp Green */
}

.call-btn {
  background-color: var(--accent-primary);
}

@media (max-width: 768px) {
  .mobile-actions {
    display: flex;
  }
}

/* ==========================================================================
   Facilities Grid
   ========================================================================== */
.facilities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

@media (max-width: 768px) {
  .facilities-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}