/* Custom CSS for Portfolio Website */

:root {
  --primary-color: #0d6efd;
  --secondary-color: #6c757d;
  --success-color: #198754;
  --info-color: #0dcaf0;
  --warning-color: #ffc107;
  --danger-color: #dc3545;
  --light-color: #f8f9fa;
  --dark-color: #212529;
}

/* Global Styles */
body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--dark-color);
  padding-top: 76px; /* Account for fixed navbar */
}

html {
  scroll-behavior: smooth;
}

/* Hero Section */
.hero-section {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding-top: 2rem;
}

.profile-img {
  width: 300px;
  height: 300px;
  object-fit: cover;
  border: 5px solid var(--primary-color);
}

/* Social Links */
.social-links a {
  text-decoration: none;
  transition: transform 0.3s ease;
}

.social-links a:hover {
  transform: translateY(-3px);
}

/* Cards */
.card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15) !important;
}

/* Navbar */
.navbar-brand {
  font-size: 1.5rem;
}

.navbar-nav .nav-link {
  font-weight: 500;
  margin: 0 0.5rem;
  transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover {
  color: rgba(255, 255, 255, 0.8) !important;
}

.navbar-nav .nav-link.active {
  color: #fff !important;
  font-weight: 600;
}

/* Added navbar scrolled state styling */
.navbar-scrolled {
  background-color: rgba(13, 110, 253, 0.95) !important;
  backdrop-filter: blur(10px);
}

/* Buttons */
.btn {
  font-weight: 500;
  padding: 0.75rem 2rem;
  border-radius: 50px;
  transition: all 0.3s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Sections */
section {
  padding: 5rem 0;
}

.section-title {
  position: relative;
  margin-bottom: 3rem;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 3px;
  background: var(--primary-color);
}

/* Added skills section styling */
.skill-item {
  margin-bottom: 1.5rem;
}

.progress {
  border-radius: 10px;
  overflow: hidden;
}

.progress-bar {
  border-radius: 10px;
  transition: width 0.6s ease;
}

/* Added project and blog card styling */
.project-card,
.blog-card {
  overflow: hidden;
  border-radius: 15px !important;
}

.project-card img,
.blog-card img {
  height: 200px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.project-card:hover img,
.blog-card:hover img {
  transform: scale(1.05);
}

.badge {
  font-size: 0.75rem;
  padding: 0.5em 0.75em;
}

/* Added contact section styling */
.contact-icon {
  width: 50px;
  height: 50px;
}

.contact-form .form-control {
  border-radius: 10px;
  border: 2px solid #e9ecef;
  padding: 0.75rem 1rem;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form .form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.contact-form .form-label {
  font-weight: 600;
  color: var(--dark-color);
  margin-bottom: 0.5rem;
}

/* Added form validation styling */
.was-validated .form-control:valid {
  border-color: var(--success-color);
}

.was-validated .form-control:invalid {
  border-color: var(--danger-color);
}

/* Added footer styling */
footer {
  background: linear-gradient(135deg, #212529 0%, #343a40 100%) !important;
}

footer .social-links a {
  font-size: 1.2rem;
  transition: color 0.3s ease;
}

footer .social-links a:hover {
  color: var(--primary-color) !important;
}

/* Added animation classes */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* Added scroll indicator */
.scroll-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--info-color));
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 0.3s ease;
  z-index: 9999;
}

/* Responsive Design */
@media (max-width: 768px) {
  .profile-img {
    width: 250px;
    height: 250px;
    margin-top: 2rem;
  }

  .display-4 {
    font-size: 2.5rem;
  }

  section {
    padding: 3rem 0;
  }

  .btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
  }

  /* Added mobile-specific contact styling */
  .contact-info {
    margin-bottom: 2rem;
  }

  .d-flex.gap-3 {
    flex-direction: column;
    gap: 1rem !important;
  }
}

@media (max-width: 576px) {
  .profile-img {
    width: 200px;
    height: 200px;
  }

  .btn-lg {
    padding: 0.5rem 1.5rem;
    font-size: 1rem;
  }

  .display-5 {
    font-size: 2rem;
  }

  /* Added mobile navbar adjustments */
  .navbar-nav .nav-link {
    margin: 0.25rem 0;
    text-align: center;
  }
}

/* Added print styles */
@media print {
  .navbar,
  .btn,
  footer {
    display: none !important;
  }

  body {
    padding-top: 0;
  }

  section {
    padding: 2rem 0;
    page-break-inside: avoid;
  }
}

/* Added accessibility improvements */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus styles for better accessibility */
.btn:focus,
.form-control:focus,
.nav-link:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .card {
    border: 2px solid var(--dark-color) !important;
  }

  .btn-outline-primary {
    border-width: 2px;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}
