:root {
  --primary-color: #2563eb;
  --primary-dark: #1e40af;
  --primary-light: #3b82f6;
  --secondary-color: #1f2937;
  --text-primary: #1f2937;
  --text-secondary: #4b5563;
  --text-light: #6b7280;
  --bg-primary: #ffffff;
  --bg-secondary: #f3f4f6;
  --bg-dark: #111827;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --border-color: #e5e7eb;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  line-height: 1.6;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.2;
}

h1 {
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
}

h2 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

h3 {
  font-size: 1.75rem;
  margin-bottom: 1.25rem;
}

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.lead {
  font-size: 1.25rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.highlight {
  color: var(--primary-color);
}

/* Enhanced Navigation */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
  z-index: 1000;
  padding: 1rem 0;
  transition: all 0.3s ease;
}

nav.scrolled {
  padding: 0.75rem 0;
  background-color: rgba(255, 255, 255, 0.95);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  position: relative;
  z-index: 2;
}

.nav-logo a {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-logo a::after {
  content: '';
  position: absolute;
  width: 8px;
  height: 8px;
  background-color: var(--primary-color);
  border-radius: 50%;
  bottom: 0;
  right: -12px;
}

.nav-links {
  display: flex;
  gap: 2.5rem;
  align-items: center;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
  padding: 0.5rem 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after {
  width: 100%;
}

.nav-links a:hover {
  color: var(--primary-color);
}

.nav-cta {
  padding: 0.75rem 1.5rem !important;
  background-color: var(--primary-color);
  color: white !important;
  border-radius: 0.5rem;
  transition: all 0.3s ease !important;
  box-shadow: 0 2px 4px rgba(37, 99, 235, 0.1);
}

.nav-cta:hover {
  background-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(37, 99, 235, 0.2);
}

.nav-cta::after {
  display: none !important;
}

/* Enhanced Hero Section */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem 0 6rem;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(30, 64, 175, 0.1) 100%);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 50%, rgba(37, 99, 235, 0.1) 0%, transparent 50%);
  animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.5); opacity: 0.2; }
}

.hero-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-text {
  max-width: 600px;
}

.subtitle {
  font-size: 1.25rem;
  color: var(--primary-color);
  font-weight: 600;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.subtitle::before {
  content: '';
  display: block;
  width: 2rem;
  height: 2px;
  background-color: var(--primary-color);
}

.hero-description {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

.hero-cta {
  display: flex;
  gap: 1.5rem;
}

.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-image::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, rgba(37, 99, 235, 0.2) 0%, transparent 70%);
  animation: rotate 20s linear infinite;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.profile-image {
  width: 400px;
  height: 400px;
  border-radius: 2rem;
  box-shadow: var(--shadow-lg);
  position: relative;
  z-index: 1;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile-image:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Layout */
.section {
  padding: 6rem 0;
}

.section:nth-child(even) {
  background-color: var(--bg-secondary);
}

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

.section-subtitle {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary-color);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

/* About Section */
.about-content {
  max-width: 800px;
  margin: 0 auto;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
  text-align: center;
}

.stat {
  padding: 2rem;
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.stat-number {
  display: block;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Skills Section */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.skill-category {
  background-color: white;
  padding: 2rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.skill-items {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.skill-item {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.skill-item i {
  font-size: 1.5rem;
  color: var(--primary-color);
  width: 2rem;
  text-align: center;
}

.skill-info {
  flex: 1;
}

.skill-info h4 {
  margin-bottom: 0.25rem;
  font-size: 1rem;
}

.skill-level {
  height: 0.5rem;
  background-color: var(--bg-secondary);
  border-radius: 0.25rem;
  overflow: hidden;
}

.skill-level::after {
  content: '';
  display: block;
  height: 100%;
  width: var(--width, 0%);
  background-color: var(--primary-color);
  border-radius: 0.25rem;
  transition: width 1s ease;
}

/* Projects Section */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
}

.project-card {
  background-color: white;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.project-content {
  padding: 2rem;
}

.project-tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.project-tags span {
  padding: 0.25rem 0.75rem;
  background-color: var(--bg-secondary);
  border-radius: 1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.project-features {
  list-style: none;
  margin: 1rem 0;
}

.project-features li {
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
}

.project-features li::before {
  content: '•';
  color: var(--primary-color);
  font-weight: bold;
  margin-right: 0.5rem;
}

/* Contact Section */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 4rem;
}

.contact-card {
  background-color: white;
  padding: 2rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.contact-details {
  margin: 2rem 0;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.contact-item i {
  color: var(--primary-color);
  font-size: 1.25rem;
}

.contact-item a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-item a:hover {
  color: var(--primary-color);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.social-links a {
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
  border-radius: 50%;
  transition: all 0.3s ease;
}

.social-links a:hover {
  background-color: var(--primary-color);
  color: white;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-weight: 500;
  color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 0.375rem;
  font-family: inherit;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

/* Buttons */
.button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 0.375rem;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
}

.button.primary {
  background-color: var(--primary-color);
  color: white;
}

.button.primary:hover {
  background-color: var(--primary-dark);
}

.button.secondary {
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
}

.button.secondary:hover {
  background-color: var(--border-color);
}

/* Footer */
footer {
  background-color: var(--bg-dark);
  color: white;
  padding: 4rem 0;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  text-align: center;
}

.footer-logo {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-color);
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: white;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--primary-light);
}

.footer-social {
  display: flex;
  gap: 1rem;
}

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

.footer-social a:hover {
  color: var(--primary-light);
}

.footer-copyright {
  color: var(--text-light);
}

/* Responsive Design */
@media (max-width: 1024px) {
  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2rem;
  }

  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }

  .hero-text {
    margin: 0 auto;
  }

  .hero-cta {
    justify-content: center;
  }

  .profile-image {
    width: 300px;
    height: 300px;
  }

  .subtitle::before {
    display: none;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .contact-container {
    grid-template-columns: 1fr;
  }

  .about-stats {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 4rem 0;
  }

  .footer-links {
    flex-direction: column;
    gap: 1rem;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 2.5rem;
  }

  .profile-image {
    width: 250px;
    height: 250px;
  }

  .hero-cta {
    flex-direction: column;
  }

  .project-card {
    margin: 0 1rem;
  }
}