/* Athlete Profile Page Styles */
.athlete-profile {
  padding: 2rem 0;
}

.athlete-header {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-bottom: 3rem;
  background: var(--surface);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.athlete-image-container {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.athlete-image-container img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.athlete-image-container img:hover {
  transform: scale(1.03);
}

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

.athlete-name-social {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.athlete-full-name {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0;
  color: var(--text-primary);
  line-height: 1.2;
  text-align: center;
}

.athlete-badges {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.athlete-category-badge,
.athlete-status-badge,
.athlete-dan-badge {
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(0,0,0,0.1);
}

.athlete-category-badge {
  background: linear-gradient(135deg, var(--primary-200), var(--primary-300));
  color: var(--primary-900);
}

.athlete-status-badge {
  background: linear-gradient(135deg, var(--secondary-200), var(--secondary-300));
  color: var(--secondary-900);
}

.athlete-dan-badge {
  background: linear-gradient(135deg, var(--accent-200), var(--accent-300));
  color: var(--accent-900);
}

.athlete-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.athlete-detail {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.2rem;
  background: var(--background-light);
  border-radius: 12px;
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.athlete-detail:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
}

.detail-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 0.25rem;
  font-weight: 600;
}

.detail-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  text-align: center;
}

.athlete-social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 0.8rem 0;
  margin-top: 0.5rem;
  flex-wrap: wrap;
}

.social-link {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 50px;
  background: var(--primary-500);
  color: white;
  transition: all 0.3s ease;
  border: 2px solid var(--primary-400);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
  text-decoration: none;
  min-height: 40px;
}

.social-icon {
  width: 18px;
  height: 18px;
}

.social-label {
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: white;
}

.social-link:hover {
  background: var(--primary-600);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* Specific social media colors */
.social-link.instagram {
  background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

.social-link.judoinside {
  background: linear-gradient(135deg, #1e3a8a, #3b82f6);
}

.social-link.ijf {
  background: linear-gradient(135deg, #1f2937, #6b7280);
}

.athlete-gallery-section,
.athlete-achievements-section {
  margin: 3rem 0;
}

.athlete-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.2rem;
}

.athlete-gallery img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  border: 1px solid var(--border);
}

.athlete-gallery img:hover {
  transform: scale(1.03) rotate(1deg);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.athlete-achievements {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  padding: 1rem 0;
}

.achievement-item {
  padding: 1.5rem;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  min-height: 180px;
  display: flex;
  flex-direction: column;
}

.achievement-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.achievement-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.achievement-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.achievement-type-badge {
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-width: 80px;
  text-align: center;
}

.gold-badge {
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: #8B4513;
}

.silver-badge {
  background: linear-gradient(135deg, #C0C0C0, #A9A9A9);
  color: #2F4F4F;
}

.bronze-badge {
  background: linear-gradient(135deg, #CD7F32, #A0522D);
  color: #FFFFFF;
}

.achievement-date {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.achievement-description {
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.achievement-location {
  font-size: 0.85rem;
  color: var(--text-tertiary);
  margin-top: 0.5rem;
  font-style: italic;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--border);
}

.section-title {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
  position: relative;
  padding-bottom: 0.8rem;
  text-align: center;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-500), var(--accent-500));
  border-radius: 2px;
}

@media (min-width: 768px) {
  .section-title {
    text-align: left;
  }
  
  .section-title::after {
    left: 0;
    transform: none;
  }
}

/* Loading State - Similar to team card placeholders */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg,
    rgba(255,255,255,0) 0%,
    rgba(255,255,255,0.8) 50%,
    rgba(255,255,255,0) 100%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  z-index: 1;
}

@keyframes loading-shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

/* Specific loading styles for athlete profile elements */
.athlete-header.loading {
  background: transparent;
}

.athlete-card-image.loading {
  width: 100%;
  height: 400px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 12px;
  margin: 0 auto;
  max-width: 300px;
}

.loading-placeholder-text,
.loading-text {
  color: transparent;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 4px;
  min-height: 1rem;
  overflow: hidden;
}

.loading-placeholder-text {
  width: 80%;
  height: 2rem;
  margin: 0 auto;
}

.athlete-full-name.loading-placeholder-text {
  width: 100%;
  height: 2.5rem;
}

.loading-badge {
  display: inline-block;
  height: 1.8rem;
  width: 100px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 50px;
  margin: 0 0.4rem;
}

.loading-detail {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 12px;
  min-height: 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1.2rem;
}

.loading-social {
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 0.8rem 0;
  margin-top: 0.5rem;
}

.loading-social-item {
  width: 120px;
  height: 40px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 50px;
}

.loading-title {
  color: transparent;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 8px;
  height: 2rem;
  width: 120px;
  margin: 0 auto 1.5rem;
}

.loading-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.2rem;
}

.loading-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 12px;
}

.loading-achievements {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  padding: 1rem 0;
}

.loading-achievement {
  padding: 1.5rem;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading-shimmer 1.5s infinite;
  border-radius: 12px;
  min-height: 180px;
  display: flex;
  flex-direction: column;
}

/* Fade-in animation for smooth loading */
.fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

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

/* Error State */
.error-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 0;
  text-align: center;
}

.error-container h2 {
  font-size: 2rem;
  color: var(--error);
  margin-bottom: 1rem;
}

.error-container p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  max-width: 600px;
}

/* Fade-in animation for smooth loading */
.fade-in {
  animation: fadeIn 0.6s ease-out forwards;
}

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

/* Hidden class */
.hidden {
  display: none !important;
}

/* Responsive styles */
@media (min-width: 768px) {
  .athlete-header {
    flex-direction: row;
    align-items: flex-start;
    gap: 2.5rem;
  }
  
  .athlete-image-container {
    width: 350px;
    margin: 0;
  }
  
  .athlete-info {
    text-align: left;
    flex: 1;
    margin-left: 2rem;
  }
  
  .athlete-name-social {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }
  
  .athlete-full-name {
    font-size: 2.8rem;
    flex: 1;
    margin: 0;
    text-align: left;
  }
  
  .athlete-badges {
    justify-content: flex-start;
  }
  
  .athlete-details-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .athlete-social-links {
    justify-content: flex-start;
    padding: 0;
  }
}

@media (min-width: 1024px) {
  .athlete-header {
    align-items: center;
    gap: 3rem;
  }

  .athlete-image-container {
    width: 400px;
  }

  .athlete-full-name {
    font-size: 3rem;
  }

  .athlete-details-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .athlete-achievements {
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  }
}

/* High Resolution Displays - Increase container width */
/* FHD (1920x1080) */
@media (min-width: 1920px) {
  .athlete-details-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* 2K (2560x1440) */
@media (min-width: 2560px) {
  .athlete-details-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* 4K (3840x2160) */
@media (min-width: 3840px) {
  .athlete-details-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}