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

:root {
  --primary-color: #0066FF;
  --secondary-color: #00D4FF;
  --dark-bg: #0A0E27;
  --light-bg: #F8FAFC;
  --text-dark: #1A1A1A;
  --text-light: #64748B;
  --white: #FFFFFF;
  --gradient: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  --gradient-warm: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-cool: linear-gradient(135deg, #00D4FF 0%, #0066FF 100%);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 16px 48px rgba(0, 102, 255, 0.2);
  --shadow-xl: 0 24px 64px rgba(0, 102, 255, 0.3);
}

[data-theme="dark"] {
  --dark-bg: #0F172A;
  --light-bg: #1E293B;
  --text-dark: #F1F5F9;
  --text-light: #94A3B8;
  --white: #0F172A;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 48px rgba(0, 102, 255, 0.3);
  --shadow-xl: 0 24px 64px rgba(0, 102, 255, 0.4);
}

[data-theme="dark"] body {
  background-color: #0F172A;
  color: #F1F5F9;
}

[data-theme="dark"] .pillar-card,
[data-theme="dark"] .project-card,
[data-theme="dark"] .step-card,
[data-theme="dark"] .tech-category {
  background: #1E293B;
  border-color: #334155;
}

[data-theme="dark"] header {
  background: #1E293B;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hero {
  background: #0A0E1F;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--white);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 0;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

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

.nav-links a {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: color 0.3s;
}

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

.hero {
  background: var(--dark-bg);
  color: var(--white);
  padding: 8rem 0 6rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(0, 212, 255, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(0, 102, 255, 0.15) 0%, transparent 50%);
  pointer-events: none;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero p {
  font-size: 1.25rem;
  color: #94A3B8;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.cta-button {
  display: inline-block;
  background: var(--gradient);
  color: var(--white);
  padding: 1rem 2.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.cta-button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.cta-button:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: var(--shadow-xl);
}

.cta-button:hover::before {
  width: 300px;
  height: 300px;
}

.cta-button:active {
  transform: translateY(-1px) scale(1.02);
}

.section {
  padding: 5rem 0;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 1rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-light);
  font-size: 1.1rem;
  margin-bottom: 3rem;
}

.pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.pillar-card {
  background: var(--white);
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 2rem;
  text-align: center;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.pillar-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient);
  transform: scaleX(0);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.pillar-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary-color);
}

.pillar-card:hover::before {
  transform: scaleX(1);
}

.pillar-card:hover .pillar-icon,
.pillar-card:hover .pillar-icon-inline {
  transform: scale(1.1) rotate(5deg);
  color: var(--secondary-color);
}

.pillar-icon,
.pillar-icon-inline {
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.pillar-icon {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1.5rem;
  color: var(--primary-color);
}

.pillar-icon svg {
  width: 100%;
  height: 100%;
}

.pillar-icon-inline {
  width: 2.5rem;
  height: 2.5rem;
  display: inline-block;
  color: var(--primary-color);
  vertical-align: middle;
  margin-right: 0.75rem;
}

.pillar-icon-inline svg {
  width: 100%;
  height: 100%;
}

.pillar-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

.pillar-card p {
  color: var(--text-light);
}

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

.project-card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.project-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 102, 255, 0.1), rgba(0, 212, 255, 0.1));
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.project-card:hover {
  transform: translateY(-12px) scale(1.03);
  box-shadow: var(--shadow-xl);
}

.project-card:hover::after {
  opacity: 1;
}

.project-card:hover .project-image {
  transform: scale(1.05);
}

.project-image {
  width: 100%;
  height: 250px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 3rem;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.project-image::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  transform: translate(-50%, -50%) scale(0);
  transition: transform 0.6s ease;
}

.project-card:hover .project-image::before {
  transform: translate(-50%, -50%) scale(1);
}

.project-content {
  padding: 1.5rem;
}

.project-content h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.project-content p {
  color: var(--text-light);
  margin-bottom: 1rem;
}

.tech-tag {
  display: inline-block;
  background: #E0F2FE;
  color: var(--primary-color);
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
}

.tech-stack {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.tech-category {
  background: var(--light-bg);
  padding: 2rem;
  border-radius: 12px;
  border-left: 4px solid var(--primary-color);
}

.tech-category h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tech-icon-inline {
  width: 1.75rem;
  height: 1.75rem;
  color: var(--primary-color);
}

.tech-list {
  list-style: none;
}

.tech-list li {
  padding: 0.5rem 0;
  color: var(--text-light);
  display: flex;
  align-items: center;
}

.tech-list li:before {
  content: "✓";
  color: var(--primary-color);
  font-weight: bold;
  margin-right: 0.5rem;
}

.methodology-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.step-card {
  background: var(--white);
  border: 2px solid #E2E8F0;
  border-radius: 12px;
  padding: 2rem;
  position: relative;
}

.step-number {
  position: absolute;
  top: -15px;
  left: 20px;
  background: var(--gradient);
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
}

.step-card h3 {
  margin-top: 1rem;
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.step-card p {
  color: var(--text-light);
}

footer {
  background: var(--dark-bg);
  color: var(--white);
  padding: 3rem 0;
  text-align: center;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  margin-bottom: 1rem;
}

.footer-section p,
.footer-section a {
  color: #94A3B8;
  text-decoration: none;
}

.footer-section a:hover {
  color: var(--secondary-color);
}

.footer-bottom {
  border-top: 1px solid #1E293B;
  padding-top: 2rem;
  color: #64748B;
}

.theme-toggle {
  background: none;
  border: 2px solid #E2E8F0;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.theme-toggle:hover {
  border-color: var(--primary-color);
  transform: rotate(15deg) scale(1.1);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  color: var(--text-dark);
  transition: all 0.3s ease;
}

.sun-icon {
  display: none;
}

.moon-icon {
  display: block;
}

[data-theme="dark"] .sun-icon {
  display: block;
}

[data-theme="dark"] .moon-icon {
  display: none;
}

[data-theme="dark"] .theme-toggle svg {
  color: #F1F5F9;
}

.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 30px;
  right: 30px;
  background-color: #25D366;
  color: #FFF;
  border-radius: 50%;
  text-align: center;
  font-size: 30px;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.whatsapp-float:hover {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 12px 32px rgba(37, 211, 102, 0.6);
  background-color: #128C7E;
}

.whatsapp-float svg {
  width: 32px;
  height: 32px;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  70% {
    box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

.whatsapp-float {
  animation: pulse 2s infinite;
}

@media (max-width: 768px) {
  .nav-links {
    gap: 1rem;
    font-size: 0.9rem;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .portfolio-grid,
  .tech-stack,
  .methodology-steps {
    grid-template-columns: 1fr;
  }
  
  .theme-toggle {
    width: 36px;
    height: 36px;
  }
  
  .theme-toggle svg {
    width: 18px;
    height: 18px;
  }
}
