/* ========================================
   Base Styles & Reset
   ======================================== */

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #0f0f11;
  color: #e0e0e0;
  overflow-x: hidden;
  position: relative;
  line-height: 1.6;
}

/* ========================================
   Matrix Rain Background Canvas
   ======================================== */

#matrix-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

/* ========================================
   Main Profile Card
   ======================================== */

.card {
  max-width: 600px;
  margin: 80px auto 40px;
  background: rgba(20, 20, 24, 0.85);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 10px 50px rgba(0, 240, 255, 0.15);
  border: 1px solid rgba(0, 240, 255, 0.2);
  position: relative;
  backdrop-filter: blur(10px);
  transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 60px rgba(0, 240, 255, 0.25);
}

/* ========================================
   Card Header Section
   ======================================== */

.card-header {
  text-align: center;
  position: relative;
}

/* Animated glow effect behind avatar */
.glow {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.4), transparent 70%);
  border-radius: 50%;
  animation: pulse 3s infinite;
  z-index: 0;
}

@keyframes pulse {
  0%, 100% {
    transform: translateX(-50%) scale(1);
    opacity: 0.6;
  }
  50% {
    transform: translateX(-50%) scale(1.1);
    opacity: 0.8;
  }
}

/* Avatar icon */
.avatar {
  width: 100px;
  height: 100px;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, #00d4ff, #0077ff);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: #fff;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 30px rgba(0, 240, 255, 0.5);
}

/* Profile title */
.title {
  font-size: 2rem;
  color: #00f0ff;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 15px rgba(0, 240, 255, 0.6);
}

/* Subtitle/job title */
.subtitle {
  font-size: 1rem;
  color: #a0a0a0;
  margin-bottom: 1rem;
}

/* Badge container for skills */
.badge-container {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

/* Individual skill badge */
.badge {
  background: rgba(0, 240, 255, 0.1);
  color: #00f0ff;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 240, 255, 0.3);
  transition: all 0.3s;
}

.badge:hover {
  background: rgba(0, 240, 255, 0.2);
  transform: translateY(-2px);
}

/* ========================================
   Card Body Section
   ======================================== */

.card-body {
  margin-top: 2rem;
}

/* Bio/description text */
.bio {
  text-align: center;
  color: #c0c0c0;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

/* ========================================
   Statistics Cards
   ======================================== */

.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

/* Individual stat card */
.stat-card {
  background: rgba(0, 240, 255, 0.05);
  padding: 1rem;
  border-radius: 10px;
  text-align: center;
  border: 1px solid rgba(0, 240, 255, 0.15);
  transition: all 0.3s;
}

.stat-card:hover {
  background: rgba(0, 240, 255, 0.1);
  transform: translateY(-3px);
}

/* Stat number (large number display) */
.stat-number {
  font-size: 1.5rem;
  font-weight: bold;
  color: #00f0ff;
  margin-bottom: 0.3rem;
}

/* Stat label (description) */
.stat-label {
  font-size: 0.85rem;
  color: #909090;
}

/* ========================================
   Call-to-Action Buttons
   ======================================== */

.btn-container {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Base button styles */
.btn {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s;
  display: inline-block;
  border: none;
  cursor: pointer;
}

/* Primary button (main action) */
.btn-primary {
  background: linear-gradient(135deg, #00d4ff, #0077ff);
  color: #fff;
  box-shadow: 0 5px 20px rgba(0, 240, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0, 240, 255, 0.5);
}

/* Secondary button (alternative action) */
.btn-secondary {
  background: rgba(0, 240, 255, 0.1);
  color: #00f0ff;
  border: 1px solid rgba(0, 240, 255, 0.3);
}

.btn-secondary:hover {
  background: rgba(0, 240, 255, 0.2);
  transform: translateY(-3px);
}

/* ========================================
   System Status Monitor
   ======================================== */

.monitor {
  margin-top: 2rem;
  text-align: center;
  color: #00ff88;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Pulsing status indicator */
.pulse {
  width: 10px;
  height: 10px;
  background: #00ff88;
  border-radius: 50%;
  animation: pulse-dot 1.5s infinite;
}

@keyframes pulse-dot {
  0%, 100% {
    box-shadow: 0 0 5px #00ff88, 0 0 10px #00ff88;
  }
  50% {
    box-shadow: 0 0 10px #00ff88, 0 0 20px #00ff88;
  }
}

/* ========================================
   Projects & Certifications Section
   ======================================== */

.projects-section {
  max-width: 1200px;
  margin: 60px auto;
  padding: 0 2rem;
}

/* Section title */
.section-title {
  text-align: center;
  font-size: 2rem;
  color: #00f0ff;
  margin-bottom: 2rem;
  text-shadow: 0 0 15px rgba(0, 240, 255, 0.6);
}

/* Grid layout for project cards */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

/* Individual project card */
.project-card {
  background: rgba(20, 20, 24, 0.85);
  padding: 2rem;
  border-radius: 15px;
  border: 1px solid rgba(0, 240, 255, 0.2);
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 40px rgba(0, 240, 255, 0.2);
  border-color: rgba(0, 240, 255, 0.4);
}

/* Project icon */
.project-card i {
  font-size: 2.5rem;
  color: #00f0ff;
  margin-bottom: 1rem;
  display: block;
}

/* Project title */
.project-card h3 {
  color: #e0e0e0;
  margin-bottom: 0.75rem;
  font-size: 1.25rem;
}

/* Project description */
.project-card p {
  color: #a0a0a0;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ========================================
   PDF Viewer Security & Styling
   ======================================== */

/* PDF viewer container */
#pdf-viewer-container {
  margin-top: 1rem;
  max-width: 100%;
  position: relative;
}

/* PDF canvas element */
#pdf-canvas {
  border: 1px solid rgba(0, 240, 255, 0.3);
  border-radius: 8px;
  width: 100%;
  box-shadow: 0 4px 20px rgba(0, 240, 255, 0.2);

  /* Security: Prevent text selection and interaction */
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-touch-callout: none;

  /* Fade-in animation on load */
  animation: fadeIn 0.8s ease-in;
}

/* Fade-in animation for PDF */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Prevent selection of all elements within PDF container */
#pdf-viewer-container * {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
}

/* ========================================
   Footer Section
   ======================================== */

.footer {
  text-align: center;
  margin: 60px auto 40px;
  display: flex;
  gap: 1.5rem;
  justify-content: center;
}

/* Social media links */
.social-link {
  width: 50px;
  height: 50px;
  background: rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00f0ff;
  font-size: 1.5rem;
  transition: all 0.3s;
  text-decoration: none;
}

.social-link:hover {
  background: rgba(0, 240, 255, 0.2);
  transform: translateY(-5px);
  box-shadow: 0 5px 20px rgba(0, 240, 255, 0.3);
}

/* ========================================
   Responsive Design - Mobile
   ======================================== */

@media (max-width: 768px) {
  /* Adjust card padding on mobile */
  .card {
    margin: 40px 1rem;
    padding: 1.5rem;
  }

  /* Smaller title on mobile */
  .title {
    font-size: 1.5rem;
  }

  /* Single column stats layout */
  .stats {
    grid-template-columns: 1fr;
  }

  /* Stack buttons vertically */
  .btn-container {
    flex-direction: column;
  }

  /* Full width buttons on mobile */
  .btn {
    width: 100%;
  }

  /* Smaller section title */
  .section-title {
    font-size: 1.5rem;
  }

  /* Single column project grid */
  .projects-grid {
    grid-template-columns: 1fr;
  }

  /* Adjust projects section padding */
  .projects-section {
    padding: 0 1rem;
  }
}

/* ========================================
   Responsive Design - Tablet
   ======================================== */

@media (min-width: 769px) and (max-width: 1024px) {
  /* Two-column layout for projects on tablet */
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}