/* 
  CheckMatrix Chess Academy - Main Stylesheet
  Theme: Premium, Elegant, Intelligent, Modern, Corporate
  Colors:
    --color-navy: #081B33
    --color-royal: #245DFF
    --color-gold: #D9A441
    --color-white: #FFFFFF
    --color-light-bg: #F8FAFC
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Poppins:wght@600;700;800&display=swap');

:root {
  --color-navy: #081B33;
  --color-royal: #245DFF;
  --color-gold: #D9A441;
  --color-white: #FFFFFF;
  --color-light-bg: #F8FAFC;
  
  --font-headings: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.2s ease-out;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-white);
  color: var(--color-navy);
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headings);
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* --- Premium Navigation Header --- */
.header-glass {
  background-color: rgba(8, 27, 51, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: var(--transition-smooth);
}

.header-scrolled {
  padding-top: 0.75rem !important;
  padding-bottom: 0.75rem !important;
  background-color: rgba(6, 20, 38, 0.95);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
}

/* --- Gold Button Styling --- */
.btn-gold {
  background: linear-gradient(135deg, #E8B958, #C49129);
  color: #081B33;
  font-weight: 600;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 15px rgba(217, 164, 65, 0.3);
  position: relative;
  overflow: hidden;
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(217, 164, 65, 0.45);
}

.btn-gold::after {
  content: '';
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 100%;
  background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 50%, rgba(255, 255, 255, 0) 100%);
  transform: skewX(-25deg);
  transition: 0.75s ease-in-out;
  opacity: 0;
}

.btn-gold:hover::after {
  left: 125%;
  opacity: 1;
}

/* --- Secondary Royal Button --- */
.btn-royal {
  background-color: transparent;
  color: var(--color-white);
  border: 1.5px solid var(--color-royal);
  font-weight: 500;
  transition: var(--transition-smooth);
}

.btn-royal:hover {
  background-color: var(--color-royal);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(36, 93, 255, 0.3);
}

/* --- Chess Grid Accent (Hero background / section dividers) --- */
.chess-pattern-grid {
  background-color: #081B33;
  background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
                    radial-gradient(circle at 70% 30%, #1a3a5f 0%, #081B33 70%);
  background-size: 40px 40px, 40px 40px, auto;
  background-blend-mode: normal;
}

.hero-gradient {
  background: radial-gradient(circle at 70% 30%, #1a3a5f 0%, #081B33 70%);
}

.glass {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.chess-pattern-light {
  background-image: linear-gradient(rgba(8, 27, 51, 0.02) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(8, 27, 51, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
}

/* --- Hero Image Glow --- */
.hero-image-container::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 1rem;
  box-shadow: inset 0 0 100px rgba(8, 27, 51, 0.8),
              0 0 50px rgba(36, 93, 255, 0.15);
  pointer-events: none;
}

/* --- Program Card MasterClass Premium Look --- */
.program-card {
  border: 1px solid rgba(8, 27, 51, 0.06);
  transition: var(--transition-smooth);
}

.program-card:hover {
  transform: translateY(-8px);
  border-color: rgba(219, 164, 65, 0.3);
  box-shadow: 0 20px 40px -15px rgba(8, 27, 51, 0.08);
}

.program-card-dark {
  background-color: rgba(8, 27, 51, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: var(--transition-smooth);
}

.program-card-dark:hover {
  transform: translateY(-8px);
  border-color: var(--color-gold);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
}

/* --- Interactive Timeline Connector --- */
.timeline-track {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom, rgba(36, 93, 255, 0.1) 0%, rgba(36, 93, 255, 0.8) 50%, rgba(217, 164, 65, 0.8) 90%, rgba(217, 164, 65, 0.1) 100%);
}

.timeline-step {
  transition: var(--transition-smooth);
}

.timeline-step:hover .step-number {
  background-color: var(--color-gold);
  color: var(--color-navy);
  transform: scale(1.1) rotate(360deg);
  box-shadow: 0 0 20px rgba(217, 164, 65, 0.6);
}

.step-number {
  transition: var(--transition-smooth);
}

/* --- Interactive FAQ Accordion --- */
.faq-header {
  cursor: pointer;
  transition: var(--transition-fast);
}

.faq-header:hover {
  color: var(--color-royal);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  opacity: 0;
}

.faq-item.active .faq-answer {
  max-height: 250px;
  opacity: 1;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
  color: var(--color-gold);
}

.faq-icon {
  transition: var(--transition-smooth);
}

/* --- Premium Testimonial Slider --- */
.slide-item {
  display: none;
  animation: fadeEffect 0.6s ease-in-out;
}

.slide-item.active {
  display: block;
}

@keyframes fadeEffect {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.2);
  transition: var(--transition-smooth);
  cursor: pointer;
}

.slider-dot.active {
  background-color: var(--color-gold);
  width: 24px;
  border-radius: 4px;
}

/* --- Animated Statistics Count-up Trigger --- */
.stat-card {
  border-left: 4px solid #D9A441 !important;
  padding-left: 1.5rem !important;
  transition: var(--transition-smooth);
}
.stat-card:hover {
  transform: translateY(-5px);
}

/* --- Subtle Board Theme Decorations --- */
.diagonal-stripe {
  position: absolute;
  width: 300px;
  height: 100%;
  background: linear-gradient(135deg, rgba(36, 93, 255, 0.05) 0%, transparent 100%);
  transform: skewX(-15deg);
  z-index: 0;
  pointer-events: none;
}

/* Custom chess decoration fonts */
.chess-king-silhouette {
  font-size: 15rem;
  font-weight: 900;
  text-align: center;
  color: rgba(255, 255, 255, 0.02);
  user-select: none;
}

/* --- Image Overlays & Filters --- */
.lux-gradient-overlay {
  background: linear-gradient(to top, rgba(8, 27, 51, 1) 0%, rgba(8, 27, 51, 0.8) 50%, rgba(8, 27, 51, 0.4) 100%);
}

.text-gold-gradient {
  background: linear-gradient(135deg, #F3D075 0%, #D9A441 50%, #B88523 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* General Layout helpers */
.section-padding {
  padding-top: 8rem;
  padding-bottom: 8rem;
}

/* Form Inputs styling */
.premium-input {
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(8, 27, 51, 0.1);
  color: var(--color-navy);
  transition: var(--transition-smooth);
}

.premium-input:focus {
  outline: none;
  border-color: var(--color-royal);
  box-shadow: 0 0 12px rgba(36, 93, 255, 0.15);
  background-color: #ffffff;
}

.contact-dark-input {
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--color-white);
  transition: var(--transition-smooth);
}

.contact-dark-input:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 12px rgba(217, 164, 65, 0.15);
  background-color: rgba(255, 255, 255, 0.07);
}

/* Success Modal */
.modal-overlay {
  opacity: 0;
  pointer-events: none;
  transition: var(--transition-smooth);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* --- Premium Loading Screen --- */
#academy-loader {
  display: flex !important;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
#academy-loader.loaded {
  opacity: 0;
  transform: translateY(-20px);
  pointer-events: none;
}

/* --- Chess Microinteraction Animations --- */
@keyframes knight-jump {
  0% { transform: translate(0, 0) scale(1); }
  30% { transform: translate(6px, -18px) rotate(15deg) scale(1.15); }
  70% { transform: translate(14px, -12px) rotate(30deg) scale(1.1); }
  100% { transform: translate(16px, 0) rotate(0deg) scale(1); }
}
.animate-knight-jump:hover i, .animate-knight-jump:hover svg {
  animation: knight-jump 0.8s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes pawn-push {
  0% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
  100% { transform: translateY(-4px); }
}
.animate-pawn-push:hover i, .animate-pawn-push:hover svg {
  animation: pawn-push 0.5s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes rook-slide {
  0% { transform: translateX(0); }
  40% { transform: translateX(12px); }
  70% { transform: translateX(-4px); }
  100% { transform: translateX(0); }
}
.animate-rook-slide:hover i, .animate-rook-slide:hover svg {
  animation: rook-slide 0.6s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes crown-pulse {
  0% { transform: scale(1) rotate(0); filter: drop-shadow(0 0 2px rgba(217,164,65,0.4)); }
  50% { transform: scale(1.12) rotate(8deg); filter: drop-shadow(0 0 12px rgba(217,164,65,0.8)); }
  100% { transform: scale(1) rotate(0); filter: drop-shadow(0 0 2px rgba(217,164,65,0.4)); }
}
.animate-crown-spin:hover i, .animate-crown-spin:hover svg {
  animation: crown-pulse 0.8s ease-in-out forwards;
}

/* --- Ambient Floating Particles --- */
.notation-particle {
  position: absolute;
  color: rgba(255, 255, 255, 0.12);
  font-family: monospace;
  font-size: 0.85rem;
  font-weight: 600;
  pointer-events: none;
  animation: floatNotation 12s linear infinite;
  z-index: 1;
}
@keyframes floatNotation {
  0% { transform: translateY(120%) rotate(0deg); opacity: 0; }
  15% { opacity: 0.8; }
  85% { opacity: 0.8; }
  100% { transform: translateY(-120%) rotate(360deg); opacity: 0; }
}

/* --- Premium Reveal-on-Scroll Effects --- */
.reveal-inactive {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-active {
  opacity: 1;
  transform: translateY(0);
}

/* --- Luxury Spotlight Mouse Shadow --- */
.spotlight-card {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.spotlight-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(400px circle at var(--mouse-x, 0) var(--mouse-y, 0), rgba(217, 164, 65, 0.1), transparent 40%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.spotlight-card:hover::before {
  opacity: 1;
}

/* --- Golden Premium Border Pulse on CTA --- */
.luxury-pulse-gold {
  position: relative;
}
.luxury-pulse-gold::after {
  content: '';
  position: absolute;
  inset: -1.5px;
  border-radius: inherit;
  border: 1.5px solid rgba(217, 164, 65, 0.5);
  animation: borderGlowPulse 4s infinite alternate;
  pointer-events: none;
}
@keyframes borderGlowPulse {
  0% { box-shadow: 0 0 4px rgba(217, 164, 65, 0.2); border-color: rgba(217, 164, 65, 0.3); }
  50% { box-shadow: 0 0 20px rgba(217, 164, 65, 0.6); border-color: rgba(217, 164, 65, 0.8); }
  100% { box-shadow: 0 0 4px rgba(217, 164, 65, 0.2); border-color: rgba(217, 164, 65, 0.3); }
}

/* --- Interactive Chessboard Battle Visual (Hero) --- */
.hero-battle-board {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  grid-template-rows: repeat(8, 1fr);
  width: 100%;
  aspect-ratio: 1;
  border: 4px solid rgba(8, 27, 51, 0.8);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  border-radius: 6px;
  background: #081B33;
}
.board-sq {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.5rem;
  transition: background-color 0.3s ease, transform 0.3s ease;
  position: relative;
  cursor: crosshair;
}
.board-sq:hover {
  background-color: rgba(217, 164, 65, 0.22) !important;
}
.board-sq:hover::after {
  content: attr(data-coord);
  position: absolute;
  top: 2px;
  right: 2px;
  font-size: 8px;
  color: var(--color-gold);
  font-family: monospace;
}
.light-sq {
  background-color: rgba(255, 255, 255, 0.04);
}
.dark-sq {
  background-color: rgba(8, 27, 51, 0.5);
}
.board-piece {
  transform: scale(1);
  transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}
.board-piece:hover {
  transform: translateY(-8px) scale(1.15);
  filter: drop-shadow(0 12px 16px rgba(217,164,65,0.6));
}

/* --- Bento Imagery Gallery --- */
.gallery-filter-btn {
  padding: 0.6rem 1.5rem;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
}
.gallery-filter-btn.active, .gallery-filter-btn:hover {
  background: linear-gradient(135deg, #E8B958, #C49129);
  border-color: #D9A441;
  color: #081B33;
  box-shadow: 0 4px 15px rgba(217, 164, 65, 0.3);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
}
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.gallery-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 27, 51, 0.95) 0%, rgba(8, 27, 51, 0.4) 60%, transparent 100%);
  opacity: 0.75;
  transition: opacity 0.3s ease;
}
.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}
.gallery-item:hover::after {
  opacity: 0.9;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-cover: cover;
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.gallery-item:hover img {
  transform: scale(1.08);
}
.gallery-label {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 1.5rem;
  z-index: 10;
  transform: translateY(10px);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.gallery-item:hover .gallery-label {
  transform: translateY(0);
  opacity: 1;
}

/* Lightbox overlay styling */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(8, 27, 51, 0.97);
  backdrop-filter: blur(15px);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

/* --- Immersive UI Brand Specifications --- */
.btn-hover {
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.btn-hover:hover {
  opacity: 0.9 !important;
  transform: translateY(-1px) !important;
}

.nav-link {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s;
}
.nav-link:hover {
  color: #FFFFFF;
}
