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

:root {
  --primary-bg: #0a0f1c;
  --secondary-bg: #1a1f2e;
  --card-bg: #252a3a;
  --primary-blue: #2563eb;
  --accent-blue: #3b82f6;
  --light-blue: #60a5fa;
  --cyan: #06b6d4;
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --border: #334155;
  --gradient: linear-gradient(135deg, #2563eb 0%, #06b6d4 100%);
  --glow: 0 0 20px rgba(37, 99, 235, 0.3);
}

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

/* Animated background */
.bg-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: radial-gradient(
      circle at 20% 80%,
      rgba(37, 99, 235, 0.1) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(6, 182, 212, 0.1) 0%,
      transparent 50%
    );
}

.bg-animation::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(
      circle at 25% 25%,
      rgba(37, 99, 235, 0.05) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 75% 75%,
      rgba(6, 182, 212, 0.05) 0%,
      transparent 50%
    );
  animation: float 20s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-20px) rotate(180deg);
  }
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem 2rem;
  background: rgba(10, 15, 28, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--primary-blue);
  text-decoration: none;
  transition: all 0.3s ease;
}

.logo:hover {
  text-shadow: var(--glow);
  transform: scale(1.05);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
}

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

.nav-menu a:hover {
  color: var(--text-primary);
  background: rgba(37, 99, 235, 0.1);
  transform: translateY(-2px);
}

.nav-menu a.active {
  color: var(--primary-blue);
  background: rgba(37, 99, 235, 0.2);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 0.5rem;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  margin: 3px 0;
  transition: 0.3s;
  border-radius: 3px;
}

/* Main sections */
.section {
  min-height: 100vh;
  padding: 8rem 2rem 4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

/* Hero section */
.hero {
  text-align: center;
  position: relative;
}

.hero h1 {
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 800;
  margin-bottom: 1rem;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    filter: drop-shadow(0 0 10px rgba(37, 99, 235, 0.3));
  }
  to {
    filter: drop-shadow(0 0 20px rgba(37, 99, 235, 0.5));
  }
}

.hero .subtitle {
  font-size: clamp(1.2rem, 4vw, 2rem);
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-weight: 300;
}

.hero .description {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 3rem;
}

.social-links {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin: 2rem 0;
}

.social-links a {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--card-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 1.2rem;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid var(--border);
}

.social-links a:hover {
  background: var(--gradient);
  color: white;
  transform: translateY(-5px) scale(1.1);
  box-shadow: var(--glow);
}

.cta-button {
  display: inline-block;
  padding: 1rem 2rem;
  background: var(--gradient);
  color: white;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.3);
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(37, 99, 235, 0.4);
}

/* About section */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-text h2 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  color: var(--primary-blue);
}

.about-text p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

.stats {
  display: flex;
  gap: 2rem;
  margin-top: 2rem;
}

.stat-item {
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: bold;
  color: var(--accent-blue);
  display: block;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.about-image {
  position: relative;
  display: flex;
  justify-content: center;
}

.about-image img {
  width: 100%;
  max-width: 400px;
  height: 500px;
  object-fit: cover;
  border-radius: 20px;
  border: 3px solid var(--primary-blue);
  box-shadow: 0 20px 40px rgba(37, 99, 235, 0.3);
}

/* Portfolio section */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.portfolio-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--card-bg);
  border-radius: 15px;
  overflow: hidden;
  transition: all 0.3s ease;
  border: 1px solid var(--border);
  position: relative;
  group: hover;
}

.portfolio-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(37, 99, 235, 0.2);
  border-color: var(--primary-blue);
}

.portfolio-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.portfolio-card:hover img {
  transform: scale(1.05);
}

.portfolio-content {
  padding: 1.5rem;
}

.portfolio-content h3 {
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
}

.portfolio-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.portfolio-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  margin-bottom: 1rem;
}

.portfolio-link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--gradient);
  border-radius: 20px;
  color: white;
  text-decoration: none;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  transition: background 0.3s;
}

.portfolio-link:hover {
  background: var(--primary-blue);
  color: #fff;
}

/* Contact section */
.contact-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contact-info h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-blue);
}

.contact-info p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.contact-form {
  background: var(--card-bg);
  padding: 2rem;
  border-radius: 15px;
  border: 1px solid var(--border);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.8rem;
  background: var(--primary-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

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

.submit-btn {
  width: 100%;
  padding: 0.8rem;
  background: var(--gradient);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.3);
}

/* Section headers */
.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-blue);
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Responsive */
@media (max-width: 768px) {
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--secondary-bg);
    flex-direction: column;
    padding: 1rem;
    gap: 1rem;
  }

  .nav-menu.active {
    display: flex;
  }

  .menu-toggle {
    display: flex;
  }

  .about-content,
  .contact-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .stats {
    justify-content: center;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 6rem 1rem 2rem;
  }
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Loading animation */
.loading {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.loading.loaded {
  opacity: 1;
  transform: translateY(0);
}
