/* ==========================================================================
   ADRIÀ SÁNCHEZ PANADERO - CV WEB PREMIUM
   Fusió: Estètica Visual Esportiva Completa + Paleta Beige & Verd Pastel
   ========================================================================== */

:root {
  --bg-beige: #FAF7F2;          /* Fons beige càlid d'alta gamma */
  --bg-beige-card: #FFFFFF;     /* Blanc càlid per a targetes */
  --bg-beige-subtle: #F3ECE2;   /* To sorra / lli clar */
  
  --pastel-green: #5E8366;       /* Verd pastel / sàlvia principal */
  --pastel-green-light: #EBF2EC; /* Verd molt suau / fons píndoles */
  --pastel-green-border: #CFDEC2;/* Vora suau */
  --pastel-green-dark: #3B5741;  /* Verd profund elegant */
  
  --warm-peach: #DB8365;         /* Taronja terracota suau / bàsquet */
  --soft-gold: #D4AF37;          /* Or pastel / medalles */
  --soft-sky: #7BA7BC;           /* Blau pastel cel */
  
  --text-dark: #243026;          /* Text fosc suau */
  --text-muted: #5C6E60;         /* Text secundari */
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  background-color: var(--bg-beige);
  color: var(--text-dark);
  overflow-x: hidden;
  scroll-behavior: smooth;
}

/* Textura subtil de pista esportiva en verd pastel molt suau */
.court-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: 
    linear-gradient(to right, rgba(94, 131, 102, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(94, 131, 102, 0.05) 1px, transparent 1px);
  background-size: 50px 50px;
  mask-image: radial-gradient(circle at center, black 50%, transparent 90%);
  -webkit-mask-image: radial-gradient(circle at center, black 50%, transparent 90%);
}

/* Glassmorphism Pastel */
.glass-card {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--pastel-green-border);
  box-shadow: 0 10px 30px -10px rgba(36, 48, 38, 0.06), 0 4px 6px -2px rgba(36, 48, 38, 0.02);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px -8px rgba(94, 131, 102, 0.16);
  border-color: var(--pastel-green);
}

.glass-card-dark {
  background: rgba(36, 48, 38, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(207, 222, 194, 0.2);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.25);
}

/* Aura Esportiva Suau de la Foto */
.profile-avatar-wrapper {
  position: relative;
  display: inline-block;
}

.profile-avatar-wrapper::before {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 9999px;
  background: conic-gradient(from 0deg, #7BA7BC, #5E8366, #DB8365, #D4AF37, #7BA7BC);
  animation: rotateGlow 10s linear infinite;
  filter: blur(6px);
  opacity: 0.65;
}

@keyframes rotateGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Pista de la Pelota que creua la pantalla */
.ball-transition-lane {
  position: relative;
  width: 100%;
  height: 80px;
  overflow: visible;
  pointer-events: none;
  z-index: 30;
}

.sports-ball-runner {
  position: absolute;
  top: 12px;
  left: -90px;
  width: 56px;
  height: 56px;
  filter: drop-shadow(0 8px 14px rgba(36, 48, 38, 0.2));
  will-change: transform, left;
  z-index: 40;
}

/* Rastre / Estela en verd pastel suau */
.ball-speed-trail {
  position: absolute;
  top: 38px;
  left: 0;
  height: 4px;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(94, 131, 102, 0.2), var(--pastel-green));
  box-shadow: 0 0 12px rgba(94, 131, 102, 0.4);
  pointer-events: none;
  z-index: 25;
}

/* Dock flotant de pilotes */
.ball-dock-item {
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.ball-dock-item:hover, .ball-dock-item.active {
  transform: scale(1.2) translateY(-3px);
}

/* Insígnia Esportiva animada suau */
.badge-pulse {
  animation: pulseBadge 2.4s infinite;
}

@keyframes pulseBadge {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}

/* Terreny de Joc en Verd Pastel Esportiu */
.pitch-container {
  background: radial-gradient(circle at 50% 120%, #5E8366, #415F47);
  border-radius: 1.5rem;
  border: 3px solid #8FAFA0;
  box-shadow: inset 0 2px 20px rgba(0,0,0,0.25), 0 16px 36px -10px rgba(65, 95, 71, 0.35);
  position: relative;
  overflow: hidden;
}

.goal-net {
  border: 2px dashed rgba(255, 255, 255, 0.85);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  background: repeating-linear-gradient(45deg, rgba(255,255,255,0.08) 0, rgba(255,255,255,0.08) 8px, transparent 8px, transparent 16px),
              repeating-linear-gradient(-45deg, rgba(255,255,255,0.08) 0, rgba(255,255,255,0.08) 8px, transparent 8px, transparent 16px);
}

/* Botons Esportius amb colors pastís & càlids */
.btn-sport-pastel {
  background: linear-gradient(135deg, #6C9375, #517559);
  color: #FFFFFF;
  box-shadow: 0 6px 18px -4px rgba(94, 131, 102, 0.4);
  transition: all 0.25s ease;
}

.btn-sport-pastel:hover {
  background: linear-gradient(135deg, #517559, #3B5741);
  box-shadow: 0 10px 22px -4px rgba(94, 131, 102, 0.5);
  transform: translateY(-2px);
}

.btn-sport-warm {
  background: linear-gradient(135deg, #E29377, #C77558);
  color: #FFFFFF;
  box-shadow: 0 6px 18px -4px rgba(219, 131, 101, 0.4);
  transition: all 0.25s ease;
}

.btn-sport-warm:hover {
  background: linear-gradient(135deg, #C77558, #A85A40);
  box-shadow: 0 10px 22px -4px rgba(219, 131, 101, 0.5);
  transform: translateY(-2px);
}

/* Barra de progrés de lectura a dalt */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3.5px;
  background: linear-gradient(90deg, #5E8366, #DB8365, #7BA7BC);
  width: 0%;
  z-index: 9999;
  transition: width 0.1s ease-out;
}

/* Estils de PDF / Impressió del CV */
@media print {
  #scroll-progress,
  .ball-transition-lane,
  #ball-dock,
  #zona-joc,
  header,
  footer,
  .no-print {
    display: none !important;
  }

  body {
    background: #FFFFFF !important;
    color: #111827 !important;
  }

  .glass-card {
    background: #FFFFFF !important;
    border: 1px solid #E5E7EB !important;
    box-shadow: none !important;
    break-inside: avoid;
  }

  .section-reveal-item {
    opacity: 1 !important;
    transform: none !important;
  }
}
