/* Critical Mobile CSS - Inline for Fastest Rendering
   Extracted for above-the-fold mobile optimization
   This file should be inlined in HTML head for critical path optimization */

/* Mobile-First Critical Styles - Above the Fold Only */
@media (max-width: 768px) {
  /* Critical Layout - Mobile Container */
  .container {
    padding: 0 1rem;
    max-width: 100vw;
    overflow-x: hidden;
  }

  /* Critical Header - Mobile Viewport */
  .header {
    padding: 1rem 0;
    position: sticky;
    top: 0;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    z-index: 1020;
  }

  /* Critical Profile Section - Mobile Layout */
  .profile-section {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
  }

  .profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
    margin-bottom: 1rem;
  }

  .profile-placeholder {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
  }

  /* Critical Typography - Mobile Optimized */
  .name {
    font-size: 1.75rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.2;
    margin-bottom: 0.25rem;
  }

  .title {
    font-size: 1rem;
    font-weight: 500;
    color: #60a5fa;
    margin-bottom: 0.5rem;
    line-height: 1.3;
  }

  .tagline {
    font-size: 0.875rem;
    color: #e2e8f0;
    margin-bottom: 1rem;
    line-height: 1.4;
    padding: 0 0.5rem;
  }

  /* Critical Navigation - Mobile Touch */
  .navigation {
    position: sticky;
    top: 0;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 0.75rem 0;
    margin-bottom: 1.5rem;
    z-index: 1020;
  }

  .nav-items {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    padding: 0 0.5rem;
  }

  .nav-items::-webkit-scrollbar {
    display: none;
  }

  .nav-item {
    flex-shrink: 0;
    padding: 0.75rem 1rem;
    min-height: 44px;
    min-width: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 500;
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    white-space: nowrap;
    margin: 0 0.25rem;
  }

  .nav-item.active {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.3);
  }

  .nav-item:active {
    transform: scale(0.96);
    background: rgba(59, 130, 246, 0.1);
  }

  /* Critical Stats Grid - Mobile Optimized */
  .live-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin: 1.5rem 0;
  }

  .stat-item {
    background: #1e1e1e;
    padding: 1rem 0.75rem;
    border-radius: 0.75rem;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .stat-item:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #3b82f6, #06b6d4);
    border-radius: 2px 2px 0 0;
  }

  .stat-value {
    font-size: 1.125rem;
    font-weight: 700;
    color: #60a5fa;
    margin-bottom: 0.25rem;
    line-height: 1.1;
  }

  .stat-label {
    font-size: 0.625rem;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1.2;
  }

  /* Critical Contact Links - Mobile Touch */
  .contact-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 1rem;
  }

  .contact-link {
    padding: 0.75rem 1rem;
    min-height: 44px;
    background: #1e1e1e;
    color: #ffffff;
    text-decoration: none;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-width: 80px;
    max-width: 120px;
  }

  .contact-link:active {
    transform: scale(0.96);
    background: rgba(59, 130, 246, 0.1);
    border-color: #60a5fa;
  }

  /* Loading Screen - Mobile Optimized */
  .loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile */
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
  }

  .loading-content {
    text-align: center;
    padding: 1rem;
    max-width: 280px;
  }

  .loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
  }

  .loading-text {
    font-size: 1rem;
    font-weight: 500;
    color: #ffffff;
    margin-bottom: 1rem;
  }
}

/* Critical Performance Optimizations */
@media (max-width: 480px) {
  .name {
    font-size: 1.5rem;
  }

  .title {
    font-size: 0.875rem;
  }

  .tagline {
    font-size: 0.75rem;
  }

  .container {
    padding: 0 0.75rem;
  }

  .live-stats {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }

  .stat-item {
    padding: 0.75rem 0.5rem;
    min-height: 70px;
  }

  .stat-value {
    font-size: 1rem;
  }

  .stat-label {
    font-size: 0.5rem;
  }

  .nav-item {
    padding: 0.75rem 0.75rem;
    font-size: 0.75rem;
    min-width: 70px;
  }

  .contact-link {
    padding: 0.75rem 0.75rem;
    font-size: 0.75rem;
    min-width: 70px;
    max-width: 100px;
  }
}

/* Critical Animations - Mobile Optimized */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Mobile-Safe Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
  .nav-item:hover {
    background: none;
  }
  
  .contact-link:hover {
    background: #1e1e1e;
    transform: none;
  }
  
  /* Enhanced touch targets */
  .nav-item,
  .contact-link {
    min-height: 48px;
  }
}