* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui,
    sans-serif;
  background: #0a0a0a;
  color: #e5e5e5;
  overflow-x: hidden;
  line-height: 1.6;
}

html {
  scroll-behavior: smooth;
}

.bg-layer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: radial-gradient(ellipse at top, #121212 0.2%, #0a0a0a 100%);
}

.bg-layer::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
}

nav {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 1.5rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(10, 10, 10, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
  font-size: 1.4rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.5px;
}

nav ul {
  display: flex;
  gap: 2.5rem;
  list-style: none;
}

nav a {
  color: #999;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.3s ease;
  position: relative;
}

nav a:hover {
  color: #fff;
}

nav a.active {
  color: #fff;
}

#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  perspective: 1000px;
}

.hero-content {
  text-align: center;
  z-index: 10;
  animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.profile-photo {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  margin: 0 auto 2rem;
  border: 2px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  position: relative;
  transition: transform 0.4s ease;
}

.profile-photo:hover {
  transform: scale(1.05);
}

.profile-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-title {
  font-size: 4rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #fff;
  letter-spacing: -2px;
}

.hero-subtitle {
  font-size: 1.3rem;
  color: #666;
  margin-bottom: 2.5rem;
  font-weight: 400;
}

.cta-btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: #fff;
  color: #000;
  text-decoration: none;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.cta-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s;
}

.cta-btn:hover::before {
  left: 100%;
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(255, 255, 255, 0.2);
}

.floating-3d {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
}

.cube-3d {
  position: absolute;
  width: 120px;
  height: 120px;
  top: 20%;
  right: 15%;
  transform-style: preserve-3d;
  animation: rotateCube 20s infinite linear;
}

@keyframes rotateCube {
  from {
    transform: rotateX(0deg) rotateY(0deg);
  }
  to {
    transform: rotateX(360deg) rotateY(360deg);
  }
}

.cube-face {
  position: absolute;
  width: 120px;
  height: 120px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(10px);
}

.cube-face:nth-child(1) {
  transform: translateZ(60px);
}
.cube-face:nth-child(2) {
  transform: rotateY(180deg) translateZ(60px);
}
.cube-face:nth-child(3) {
  transform: rotateY(90deg) translateZ(60px);
}
.cube-face:nth-child(4) {
  transform: rotateY(-90deg) translateZ(60px);
}
.cube-face:nth-child(5) {
  transform: rotateX(90deg) translateZ(60px);
}
.cube-face:nth-child(6) {
  transform: rotateX(-90deg) translateZ(60px);
}

.sphere-3d {
  position: absolute;
  width: 100px;
  height: 100px;
  bottom: 25%;
  left: 10%;
  border-radius: 50%;
  background: radial-gradient(
    circle at 30% 30%,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  border: 1px solid rgba(255, 255, 255, 0.05);
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

.ring-3d {
  position: absolute;
  width: 150px;
  height: 150px;
  top: 50%;
  left: 12%;
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  animation: rotateRing 15s linear infinite;
}

@keyframes rotateRing {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

section {
  min-height: 100vh;
  padding: 8rem 5%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.container {
  max-width: 1200px;
  width: 100%;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 3rem;
  color: #fff;
  letter-spacing: -1px;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about-text {
  font-size: 1.1rem;
  line-height: 1.8;
  color: #888;
  margin-bottom: 1.5rem;
}

.skills {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.skill-card {
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  text-align: center;
  transition: all 0.3s ease;
  transform-style: preserve-3d;
}

.skill-card:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-5px) rotateX(5deg);
  border-color: rgba(255, 255, 255, 0.15);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.project-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 0;
  transition: all 0.4s ease;
  cursor: pointer;
  overflow: hidden;
  transform-style: preserve-3d;
}

.project-card:hover {
  transform: translateY(-10px) rotateX(2deg);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.project-image {
  width: 100%;
  height: 220px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.05),
    rgba(255, 255, 255, 0.02)
  );
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.project-content {
  padding: 1.8rem;
}

.project-title {
  font-size: 1.5rem;
  margin-bottom: 0.8rem;
  color: #fff;
}

.project-desc {
  color: #666;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.project-link {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.project-link:hover {
  gap: 1rem;
}

#contact {
  background: rgba(255, 255, 255, 0.02);
}

.contact-container {
  max-width: 600px;
  margin: 0 auto;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-top: 2rem;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  margin-bottom: 0.5rem;
  color: #888;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
  padding: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: #e5e5e5;
  font-size: 1rem;
  transition: all 0.3s;
  font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

.form-group textarea {
  resize: vertical;
  min-height: 150px;
}

.submit-btn {
  padding: 1rem 2rem;
  background: #fff;
  color: #000;
  border: none;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(255, 255, 255, 0.2);
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  z-index: 10000;
  animation: fadeIn 0.3s ease;
}

.modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  background: rgba(20, 20, 20, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  max-width: 800px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 3rem;
  position: relative;
  animation: slideUp 0.4s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #fff;
  transition: all 0.3s;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: rotate(90deg);
}

.modal-title {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #fff;
}

.modal-section {
  margin-bottom: 2rem;
}

.modal-section-title {
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 1rem;
}

.modal-text {
  color: #888;
  line-height: 1.8;
}

.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin: 1rem 0;
}

.modal-tag {
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  font-size: 0.9rem;
}

.modal-features {
  list-style: none;
  padding: 0;
}

.modal-features li {
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: #888;
}

.modal-buttons {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.modal-btn {
  padding: 1rem 2rem;
  background: #fff;
  color: #000;
  text-decoration: none;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s;
}

.modal-btn:hover {
  transform: translateY(-2px);
}

.modal-btn.secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.cursor-glow {
  position: fixed;
  width: 400px;
  height: 400px;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.05) 0%,
    transparent 70%
  );
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s;
}
.footer {
  background: rgba(0, 0, 0, 0.6);
  padding: 2rem 0;
  text-align: center;
  color: #fff;
  font-size: 0.95rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.social-links a {
  margin: 0 10px;
  color: #00bcd4;
  text-decoration: none;
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: #fff;
}
/* Responsive */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .cube-3d,
  .sphere-3d,
  .ring-3d {
    display: none;
  }

  nav ul {
    gap: 1.5rem;
  }

  section {
    padding: 6rem 5%;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }
}
