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

/* --- DESIGN SYSTEM & CSS VARIABLES (NEUTRAL LIGHT THEME) --- */
:root {
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Colors - Light Neutral */
  --bg-main: #f8fafc;
  --bg-card: rgba(255, 255, 255, 0.75);
  --bg-card-hover: rgba(255, 255, 255, 0.9);
  --border-color: rgba(15, 23, 42, 0.08);
  --border-color-glow: rgba(16, 185, 129, 0.4);
  
  --color-text-primary: #0f172a;
  --color-text-secondary: #475569;
  --color-text-muted: #64748b;
  
  /* Primary Accent - Pitch Green */
  --color-primary: #059669;
  --color-primary-hover: #10b981;
  --color-primary-glow: rgba(16, 185, 129, 0.1);
  
  /* Secondary Accent - Electric Cyan */
  --color-secondary: #0891b2;
  --color-secondary-glow: rgba(6, 182, 212, 0.1);
  
  /* Amber/Orange Accent - Drills & Progressions */
  --color-accent: #d97706;
  --color-accent-glow: rgba(245, 158, 11, 0.1);

  /* Red Team (Sandbox) */
  --color-red-team: #e11d48;
  
  /* Blue Team (Sandbox) */
  --color-blue-team: #2563eb;

  /* Pitch Lines color */
  --pitch-line: rgba(255, 255, 255, 0.55);
  --pitch-green: #15803d;
  
  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s ease;
  
  /* Shadows */
  --shadow-lg: 0 10px 30px -10px rgba(15, 23, 42, 0.08), 0 1px 3px rgba(15, 23, 42, 0.02);
  --shadow-glow: 0 0 20px rgba(16, 185, 129, 0.1);
}

/* --- RESET & LAYOUT --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--color-text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.03) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(6, 182, 212, 0.03) 0%, transparent 40%);
  background-attachment: fixed;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, 0.15);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}

/* --- APPFRAME & NAVIGATION --- */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
}

.nav-container {
  position: relative;
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.menu-btn {
  position: absolute;
  right: 2rem;
  background: none;
  border: none;
  color: var(--color-text-primary);
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--transition-fast);
}

.menu-btn:hover {
  color: var(--color-primary);
}

nav#main-nav {
  display: none;
  position: absolute;
  top: 100%;
  right: 2rem;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 0.5rem;
  z-index: 1000;
  min-width: 250px;
}

nav#main-nav.open {
  display: block;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  cursor: pointer;
}

.logo svg {
  fill: none;
  stroke: var(--color-primary);
  stroke-width: 2.5;
}

.nav-links {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  list-style: none;
}

.nav-tab {
  background: transparent;
  border: 1px solid transparent;
  color: var(--color-text-secondary);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  justify-content: flex-start;
}

.nav-tab:hover {
  color: var(--color-text-primary);
  background: rgba(15, 23, 42, 0.04);
}

.nav-tab.active {
  color: var(--color-primary);
  background: var(--color-primary-glow);
  border-color: rgba(16, 185, 129, 0.15);
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.05);
}

/* --- MAIN CONTAINER & SECTIONS --- */
main {
  max-width: 1400px;
  margin: 2rem auto;
  padding: 0 2rem;
}

.app-section {
  display: none;
  animation: fadeIn var(--transition-normal);
}

.app-section.active {
  display: block;
}

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

/* --- COMMON TYPOGRAPHY & COMPONENTS --- */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section-title {
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
  color: var(--color-text-primary);
}

.section-subtitle {
  color: var(--color-text-secondary);
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  max-width: none;
  width: 100%;
  text-align: justify;
}

/* Glassmorphism Card Style (Light) */
.glass-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 16px;
  padding: 1.75rem;
  box-shadow: var(--shadow-lg);
  transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.glass-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(15, 23, 42, 0.14);
  box-shadow: 0 12px 35px -10px rgba(15, 23, 42, 0.12);
}

/* Pill / Tag */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid transparent;
}

.badge-primary {
  background: var(--color-primary-glow);
  color: var(--color-primary);
  border-color: rgba(16, 185, 129, 0.25);
}

.badge-secondary {
  background: var(--color-secondary-glow);
  color: var(--color-secondary);
  border-color: rgba(6, 182, 212, 0.25);
}

.badge-accent {
  background: var(--color-accent-glow);
  color: var(--color-accent);
  border-color: rgba(245, 158, 11, 0.25);
}

/* --- SECTION 1: DASHBOARD --- */
.hero-banner {
  position: relative;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2.5rem;
}

.hero-banner::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--color-primary-glow) 0%, transparent 70%);
  pointer-events: none;
}

.hero-roadmap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.roadmap-step {
  cursor: pointer;
  background: rgba(15, 23, 42, 0.01);
  border: 1px solid var(--border-color);
  padding: 1.25rem;
  border-radius: 12px;
  transition: transform var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.roadmap-step:hover {
  transform: translateY(-3px);
  border-color: var(--color-primary);
  background: var(--bg-card-hover);
  box-shadow: 0 6px 15px rgba(16, 185, 129, 0.06);
}

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

@media (max-width: 640px) {
  .hero-roadmap {
    grid-template-columns: 1fr;
  }
}

/* Feature grid in dashboard */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
}

.info-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.info-icon {
  width: 48px;
  height: 48px;
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  font-size: 1.5rem;
  transition: color var(--transition-fast), border-color var(--transition-fast), background-color var(--transition-fast);
}

.info-card:hover .info-icon {
  color: var(--color-secondary);
  border-color: rgba(6, 182, 212, 0.3);
  background-color: var(--color-secondary-glow);
}

.info-card h3 {
  font-size: 1.25rem;
}

.info-card p {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--color-primary);
  color: #ffffff;
  border: none;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.8rem 1.6rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn:hover {
  background: var(--color-primary-hover);
  box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
  transform: translateY(-1px);
}

.btn-secondary {
  background: rgba(15, 23, 42, 0.05);
  color: var(--color-text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: rgba(15, 23, 42, 0.1);
  box-shadow: none;
  transform: none;
  border-color: rgba(15, 23, 42, 0.2);
}

.btn-outline {
  background: transparent;
  color: var(--color-text-primary);
  border: 1px solid var(--border-color);
  box-shadow: none;
}

.btn-outline:hover {
  background: rgba(16, 185, 129, 0.05);
  border-color: var(--color-primary);
  color: var(--color-primary);
  box-shadow: none;
  transform: translateY(-1px);
}

/* --- SECTION 2: INTERACTIVE MATRIX --- */
.matrix-layout {
  display: grid;
  grid-template-columns: 3fr 1.5fr;
  gap: 2rem;
  align-items: start;
}

.matrix-table-container {
  overflow-x: auto;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
}

.matrix-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  background: var(--bg-card);
}

.matrix-table th {
  background: rgba(241, 245, 249, 0.9);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  padding: 1.25rem;
  color: var(--color-text-primary);
  border-bottom: 1px solid var(--border-color);
}

.matrix-table th:first-child {
  width: 180px;
}

.matrix-table td {
  padding: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  vertical-align: top;
}

.matrix-table tr:last-child td {
  border-bottom: none;
}

/* Age Category column styles */
.age-row-header {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-text-primary);
}

.age-row-header .age-title {
  font-size: 1.15rem;
  display: block;
}

.age-row-header .age-desc {
  font-family: var(--font-body);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 500;
  margin-top: 0.25rem;
  display: block;
}

/* Interactive Cell Styles */
.matrix-cell {
  background: rgba(15, 23, 42, 0.01);
  border-radius: 8px;
  padding: 0.75rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.matrix-cell:hover {
  background: rgba(15, 23, 42, 0.03);
  border-color: rgba(15, 23, 42, 0.08);
  transform: translateY(-2px);
}

.matrix-cell.active-cell {
  background: var(--color-primary-glow);
  border-color: var(--color-primary);
  box-shadow: 0 0 15px rgba(5, 150, 105, 0.08);
}

.matrix-cell.active-cell-secondary {
  background: var(--color-secondary-glow);
  border-color: var(--color-secondary);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.08);
}

.cell-content-summary {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--color-text-secondary);
  margin-bottom: 0.5rem;
}

.matrix-cell:hover .cell-content-summary {
  color: var(--color-text-primary);
}

.matrix-cell.active-cell .cell-content-summary {
  color: var(--color-text-primary);
}

.cell-tap-hint {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.matrix-cell:hover .cell-tap-hint {
  opacity: 1;
}

/* Matrix Detail Panel */
.matrix-detail-panel {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.detail-header {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
}

.detail-age {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.detail-pillar {
  font-size: 1.5rem;
  font-weight: 700;
}

.detail-body {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.detail-block h4 {
  font-size: 0.95rem;
  color: var(--color-text-primary);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.detail-block h4 svg {
  color: var(--color-primary);
}

.detail-block p {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

.detail-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.detail-list li {
  position: relative;
  padding-left: 1.25rem;
  font-size: 0.9rem;
  color: var(--color-text-secondary);
}

.detail-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: bold;
}

.detail-deep-dive-btn {
  margin-top: 1rem;
  width: 100%;
}

/* --- SECTION 3: PASSING/S&C DEEP DIVE --- */
.deep-dive-intro {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 3rem;
  margin-bottom: 3rem;
  align-items: center;
}

.intro-text h2 {
  font-size: 2.25rem;
  margin-bottom: 1rem;
}

.intro-text p {
  color: var(--color-text-secondary);
  font-size: 1.05rem;
  margin-bottom: 1.25rem;
  text-align: justify;
}

.intro-stats-box {
  background: rgba(15, 23, 42, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
}

.intro-stats-box h4 {
  margin-bottom: 0.75rem;
  color: var(--color-primary);
}

.intro-stats-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.intro-stats-list li {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 0.25rem;
}

.intro-stats-list li span:last-child {
  font-weight: 600;
  color: var(--color-text-primary);
}

/* Vertical Timeline (Light Mode) */
.timeline-container {
  position: relative;
  max-width: 1000px;
  margin: 3rem auto;
  padding: 1rem 0;
}

.timeline-container::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--color-primary), var(--color-secondary), var(--color-accent), var(--color-red-team));
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-bottom: 3rem;
  position: relative;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: 50%;
  top: 30px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-main);
  border: 4px solid var(--color-primary);
  transform: translate(-50%, -50%);
  z-index: 2;
  box-shadow: 0 0 10px rgba(5, 150, 105, 0.25);
  transition: all var(--transition-fast);
}

.timeline-item:nth-child(2) .timeline-dot {
  border-color: var(--color-secondary);
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.25);
}

.timeline-item:nth-child(3) .timeline-dot {
  border-color: var(--color-accent);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.25);
}

.timeline-item:nth-child(4) .timeline-dot {
  border-color: var(--color-red-team);
  box-shadow: 0 0 10px rgba(225, 29, 72, 0.25);
}

.timeline-item:hover .timeline-dot {
  transform: translate(-50%, -50%) scale(1.25);
  box-shadow: 0 0 15px var(--color-primary);
}

.timeline-content {
  width: 45%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 1.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-fast);
}

.timeline-item:nth-child(even) .timeline-content {
  margin-left: auto;
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-right: auto;
}

.timeline-item:hover .timeline-content {
  background: var(--bg-card-hover);
  border-color: rgba(15, 23, 42, 0.14);
}

.timeline-age {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.25rem;
}

.timeline-item:nth-child(2) .timeline-age { color: var(--color-secondary); }
.timeline-item:nth-child(3) .timeline-age { color: var(--color-accent); }
.timeline-item:nth-child(4) .timeline-age { color: var(--color-red-team); }

.timeline-phase {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-secondary);
  margin-bottom: 1rem;
}

.timeline-text {
  color: var(--color-text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.timeline-details {
  border-top: 1px solid var(--border-color);
  padding-top: 0.75rem;
}

.timeline-details h5 {
  font-size: 0.85rem;
  color: var(--color-text-primary);
  margin-bottom: 0.5rem;
}

/* --- SECTION 4: INTERACTIVE DRILLS --- */
.drills-layout {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 2rem;
}

.drills-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.drill-tab {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.drill-tab:hover {
  background: var(--bg-card-hover);
  border-color: rgba(15, 23, 42, 0.12);
  transform: translateX(4px);
}

.drill-tab.active {
  background: var(--color-primary-glow);
  border-color: var(--color-primary);
  box-shadow: 0 4px 15px rgba(5, 150, 105, 0.05);
}

.drill-tab-age {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.drill-tab-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text-primary);
}

.drill-tab-desc {
  font-size: 0.8rem;
  color: var(--color-text-secondary);
}

.drill-display-area {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.pitch-visualizer-container {
  background: #15803d; /* pitch green */
  background-image: 
    linear-gradient(rgba(255,255,255,0.035) 2px, transparent 2px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 2px, transparent 2px);
  background-size: 20px 20px;
  border: 4px solid #166534;
  border-radius: 16px;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  box-shadow: var(--shadow-lg), inset 0 0 40px rgba(0, 0, 0, 0.3);
}

/* Interactive SVG Board inside the visualizer */
.pitch-svg {
  width: 100%;
  height: 100%;
}

.pitch-lines {
  fill: none;
  stroke: var(--pitch-line);
  stroke-width: 2px;
}

.pitch-goal {
  fill: none;
  stroke: #ffffff;
  stroke-width: 3px;
}

/* Animations for drills */
.player-node {
  transition: transform 1.5s ease-in-out;
}

.ball-node {
  transition: transform 1.5s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.cone-marker {
  fill: #f59e0b;
  stroke: #d97706;
  stroke-width: 1px;
}

.pass-path-line {
  stroke: #38bdf8;
  stroke-width: 2px;
  stroke-dasharray: 6, 4;
}

.run-path-line {
  stroke: #f472b6;
  stroke-width: 2px;
  stroke-dasharray: 3, 3;
}

/* Control bar for animated pitch */
.pitch-controls-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border-color);
  padding: 0.75rem 1.5rem;
  border-radius: 12px;
}

.play-pause-btn {
  background: var(--color-primary);
  color: #ffffff;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 10px rgba(5, 150, 105, 0.2);
}

.play-pause-btn:hover {
  transform: scale(1.1);
  background: var(--color-primary-hover);
}

.drill-meta-info {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.5rem;
}

.drill-info-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.drill-details-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  background: rgba(15, 23, 42, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
}

.drill-detail-cell {
  text-align: center;
}

.drill-detail-cell-label {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.drill-detail-cell-value {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-text-primary);
}

.drill-instructions-text {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
}

.coaching-points-card {
  border-left: 4px solid var(--color-primary);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.coaching-points-card h4 {
  color: var(--color-primary);
  font-size: 1.1rem;
}

.coaching-point-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.coaching-point-list li {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  position: relative;
  padding-left: 1.25rem;
}

.coaching-point-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: bold;
}

/* --- SECTION 5: TACTICS SANDBOX --- */
.sandbox-layout {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 2rem;
}

.sandbox-board-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.sandbox-pitch {
  background: #16a34a; /* bright grass */
  background-image: 
    radial-gradient(ellipse at center, rgba(255,255,255,0.06) 0%, transparent 80%),
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 100% 100%, 20px 20px;
  border: 4px solid #15803d;
  border-radius: 16px;
  position: relative;
  width: 100%;
  aspect-ratio: 1.5;
  overflow: hidden;
  box-shadow: var(--shadow-lg), inset 0 0 40px rgba(0, 0, 0, 0.2);
  touch-action: none;
}

/* HTML Canvas for drawing lines over the pitch */
.sandbox-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  pointer-events: none;
}

.sandbox-canvas.drawing-mode-active {
  pointer-events: auto;
  cursor: crosshair;
}

/* Draggable items on pitch */
.sandbox-element {
  position: absolute;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: #ffffff;
  cursor: grab;
  z-index: 10;
  box-shadow: 0 4px 8px rgba(15, 23, 42, 0.15);
  user-select: none;
  transition: box-shadow var(--transition-fast), transform var(--transition-fast);
}

.sandbox-element:active {
  cursor: grabbing;
  transform: scale(1.1);
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.25);
}

.element-red {
  background: var(--color-red-team);
  border: 2px solid #ffffff;
}

.element-blue {
  background: var(--color-blue-team);
  border: 2px solid #ffffff;
}

.element-ball {
  width: 24px;
  height: 24px;
  background: #ffffff;
  border: 2px solid #0f172a;
  border-radius: 50%;
  background-image: radial-gradient(circle, #f8fafc 40%, #e2e8f0 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.element-cone {
  width: 28px;
  height: 28px;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.element-cone svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0px 3px 2px rgba(15, 23, 42, 0.15));
}

/* Sandbox Control Panel */
.sandbox-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.tool-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.tool-group h4 {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tool-buttons-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.tool-btn {
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid var(--border-color);
  color: var(--color-text-secondary);
  border-radius: 8px;
  padding: 0.6rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.tool-btn:hover {
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.15);
  color: var(--color-text-primary);
}

.tool-btn.active {
  background: var(--color-primary-glow);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.style-palette {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.color-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform var(--transition-fast);
}

.color-swatch:hover {
  transform: scale(1.15);
}

.color-swatch.active {
  border-color: #0f172a;
  transform: scale(1.15);
}

.swatch-yellow { background-color: #d97706; }
.swatch-white { background-color: #ffffff; border: 1px solid rgba(15, 23, 42, 0.2); }
.swatch-red { background-color: #e11d48; }
.swatch-blue { background-color: #2563eb; }

/* Drag and drop source container */
.sandbox-spawner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  background: rgba(15, 23, 42, 0.01);
  border: 1px dashed var(--border-color);
  padding: 1rem;
  border-radius: 12px;
}

.spawn-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  cursor: grab;
  padding: 0.5rem;
  background: rgba(15, 23, 42, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  flex: 1 1 60px;
  text-align: center;
  transition: all var(--transition-fast);
}

.spawn-item:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.12);
}

.spawn-item-label {
  font-size: 0.7rem;
  color: var(--color-text-secondary);
}

.spawn-token {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: #ffffff;
}

.spawn-token-red {
  background: var(--color-red-team);
  border: 1px solid #ffffff;
}

.spawn-token-blue {
  background: var(--color-blue-team);
  border: 1px solid #ffffff;
}

.spawn-token-ball {
  background: #ffffff;
  border: 1px solid #000000;
  color: #000000;
}

.spawn-token-cone {
  width: 24px;
}

/* --- INTERACTIVE PHYSICAL CAPACITY CARDS --- */
.capacity-click-card {
  cursor: pointer;
  transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  min-height: 180px;
}

.capacity-click-card:hover {
  transform: translateY(-4px);
}

.capacity-click-card.active {
  border-color: var(--color-primary);
  background: var(--bg-card-hover);
  box-shadow: 0 8px 25px rgba(5, 150, 105, 0.08);
}

.capacity-desc-text {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  margin-top: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--color-text-secondary);
  transition: max-height var(--transition-normal) ease, opacity var(--transition-normal) ease, margin-top var(--transition-normal) ease;
}

.capacity-click-card.active .capacity-desc-text {
  max-height: 200px;
  opacity: 1;
  margin-top: 0.75rem;
}

.click-prompt {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: auto;
  border-top: 1px dashed var(--border-color);
  width: 100%;
  padding-top: 0.5rem;
  transition: color var(--transition-fast);
}

.nav-shortcut-btn:hover {
  background: var(--bg-card-hover) !important;
  border-color: rgba(15, 23, 42, 0.15) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.05);
}

/* Responsive Overrides */
@media (max-width: 1024px) {
  .hero-grid, .matrix-layout, .deep-dive-intro, .drills-layout, .sandbox-layout {
    grid-template-columns: 1fr;
  }
  
  .timeline-container::before {
    left: 20px;
  }
  
  .timeline-dot {
    left: 20px;
  }
  
  .timeline-content {
    width: calc(100% - 50px);
    margin-left: 50px !important;
    margin-right: 0 !important;
  }
  
  .matrix-detail-panel {
    position: static;
  }
  
  .drills-sidebar {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 0.5rem;
  }
  
  .drill-tab {
    flex: 0 0 250px;
  }
  
  .sandbox-panel {
    order: -1;
  }
}

@media (max-width: 640px) {
  .nav-container {
    padding: 1rem;
  }
  
  .menu-btn {
    right: 1rem;
  }

  nav#main-nav {
    right: 1rem;
    left: 1rem;
    min-width: auto;
  }
  
  .welcome-card h1 {
    font-size: 2rem;
  }
  
  main {
    padding: 0 1rem;
    margin: 1rem auto;
  }
}

/* --- PLYOMETRICS CATALOGUE --- */
.catalogue-wrapper {
  max-width: 800px;
  margin: 2rem auto;
}

.catalogue-book {
  position: relative;
  min-height: 550px;
  perspective: 2500px;
  background: #ffffff;
  border-radius: 4px 20px 20px 4px;
  /* Book stack aesthetics */
  box-shadow: 
    inset 10px 0 20px rgba(0,0,0,0.05), /* Spine inner shadow */
    8px 8px 25px rgba(0,0,0,0.1),       /* Main drop shadow */
    3px 0px 0px #f8fafc,
    4px 0px 0px #e2e8f0,
    5px 0px 0px #f8fafc,
    6px 0px 0px #cbd5e1;                /* Stacked pages on the right */
  border-left: 18px solid var(--color-primary); /* Book spine */
  padding: 1rem 0;
}

.catalogue-book::before {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 2px;
  background: rgba(255,255,255,0.4);
  z-index: 10;
}

.catalogue-page {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  background: #ffffff;
  border-radius: 0 16px 16px 0;
  /* 3D flip setup */
  transform-origin: left center;
  transform: rotateY(90deg);
  transition: transform 0.6s cubic-bezier(0.645, 0.045, 0.355, 1), opacity 0.5s ease;
  pointer-events: none;
}

.catalogue-page.active {
  opacity: 1;
  visibility: visible;
  position: relative;
  transform: rotateY(0deg);
  pointer-events: auto;
  z-index: 5;
}

.catalogue-page.flipped {
  transform: rotateY(-90deg);
  opacity: 0;
}

.catalogue-page .page-content {
  padding: 2.5rem 3.5rem;
  height: 100%;
}

.book-cover {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.drill-meta {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0;
  flex-wrap: wrap;
}

.featured-timeline-item {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.featured-timeline-item:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.15);
}

button.filter-btn.selected {
  background-color: var(--color-primary) !important;
  color: white !important;
  border-color: var(--color-primary) !important;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3) !important;
}
