/* ===========================
   CSS VARIABLES & RESET
=========================== */
:root {
  --bg: #030609;
  --bg-2: #060d15;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(99, 210, 255, 0.25);
  --text-primary: #f0f6ff;
  --text-secondary: rgba(240, 246, 255, 0.55);
  --text-muted: rgba(240, 246, 255, 0.3);
  --accent: #63d2ff;
  --accent-2: #a78bfa;
  --accent-3: #34d399;
  --neon-cyan: rgba(99, 210, 255, 0.6);
  --neon-purple: rgba(167, 139, 250, 0.4);
  --font-display: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'DM Mono', monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-display);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ===========================
   LOADER
=========================== */
#loader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 9999;
  display: flex;
  align-items: flex-end;
  transition: opacity 0.6s var(--ease-out), visibility 0.6s;
}

#loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-bar {
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  width: 0%;
  animation: loadBar 1.4s var(--ease-out) forwards;
  box-shadow: 0 0 12px var(--accent);
}

@keyframes loadBar {
  0% { width: 0%; }
  60% { width: 85%; }
  100% { width: 100%; }
}

/* ===========================
   ANIMATED BACKGROUND
=========================== */
.bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

#particleCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.5;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.12;
  animation: blobFloat 18s ease-in-out infinite;
}

.blob-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, #63d2ff, transparent 70%);
  top: -200px;
  left: -150px;
  animation-duration: 20s;
}

.blob-2 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #a78bfa, transparent 70%);
  bottom: -150px;
  right: -100px;
  animation-duration: 16s;
  animation-delay: -6s;
}

.blob-3 {
  width: 350px;
  height: 350px;
  background: radial-gradient(circle, #34d399, transparent 70%);
  top: 50%;
  left: 60%;
  animation-duration: 22s;
  animation-delay: -12s;
  opacity: 0.07;
}

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -40px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.97); }
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(99, 210, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99, 210, 255, 0.025) 1px, transparent 1px);
  background-size: 80px 80px;
}

/* ===========================
   NAVIGATION
=========================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 40px;
  background: rgba(3, 6, 9, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-3);
  box-shadow: 0 0 8px var(--accent-3);
  animation: statusPulse 2s ease-in-out infinite;
}

@keyframes statusPulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--accent-3); }
  50% { opacity: 0.5; box-shadow: 0 0 16px var(--accent-3); }
}

/* ===========================
   HERO SECTION
=========================== */
.hero {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 24px 60px;
}

.hero-inner {
  max-width: 760px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
}

/* Badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 18px 7px 12px;
  border: 1px solid rgba(99, 210, 255, 0.3);
  border-radius: 100px;
  background: rgba(99, 210, 255, 0.06);
  backdrop-filter: blur(12px);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.badge-pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
  animation: statusPulse 1.5s ease-in-out infinite;
  flex-shrink: 0;
}

/* Hero Name */
.hero-name {
  font-size: clamp(64px, 12vw, 110px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.03em;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.name-line {
  display: block;
}

.name-line.accent {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 40px rgba(99, 210, 255, 0.25));
}

/* Subtitle */
.hero-subtitle {
  font-family: var(--font-mono);
  font-size: clamp(14px, 2vw, 17px);
  color: var(--text-secondary);
  letter-spacing: 0.03em;
  min-height: 26px;
}

.cursor {
  display: inline-block;
  color: var(--accent);
  animation: blink 1s step-end infinite;
  font-weight: 300;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Glassmorphism Card */
.glass-card {
  max-width: 520px;
  padding: 24px 32px;
  background: var(--surface);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s, background 0.3s;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(99, 210, 255, 0.4), transparent);
}

.glass-card:hover {
  background: var(--surface-hover);
  border-color: var(--border-glow);
}

.card-text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Social Buttons */
.social-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 22px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text-primary);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  transition: all 0.25s var(--ease-out);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
}

.social-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform 0.25s var(--ease-spring);
}

.social-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(99, 210, 255, 0.1), rgba(167, 139, 250, 0.1));
  opacity: 0;
  transition: opacity 0.25s;
}

.social-btn:hover {
  border-color: rgba(99, 210, 255, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(99, 210, 255, 0.12), 0 0 0 1px rgba(99, 210, 255, 0.1);
  color: var(--accent);
}

.social-btn:hover::after { opacity: 1; }
.social-btn:hover svg { transform: scale(1.15) rotate(-5deg); }
.social-btn:active { transform: translateY(0px); }

.social-btn-email {
  border-color: rgba(52, 211, 153, 0.25);
}

.social-btn-email:hover {
  border-color: rgba(52, 211, 153, 0.5);
  color: var(--accent-3);
  box-shadow: 0 8px 30px rgba(52, 211, 153, 0.1);
}

/* ===========================
   PROJECTS SECTION
=========================== */
.projects-section {
  position: relative;
  z-index: 10;
  padding: 80px 24px 100px;
}

.projects-inner {
  max-width: 900px;
  margin: 0 auto;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 48px;
  color: var(--text-primary);
}

.project-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.project-placeholder {
  position: relative;
  padding: 32px 28px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  backdrop-filter: blur(12px);
  overflow: hidden;
  cursor: default;
  transition: all 0.3s var(--ease-out);
}

.project-glow {
  position: absolute;
  top: -60px;
  right: -60px;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(99, 210, 255, 0.08), transparent 70%);
  border-radius: 50%;
  transition: opacity 0.3s;
  opacity: 0;
}

.project-placeholder:hover {
  border-color: var(--border-glow);
  transform: translateY(-4px);
  background: var(--surface-hover);
  box-shadow: 0 12px 40px rgba(99, 210, 255, 0.06);
}

.project-placeholder:hover .project-glow {
  opacity: 1;
}

.project-placeholder::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(99, 210, 255, 0.3), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.project-placeholder:hover::before {
  opacity: 1;
}

.project-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  margin-bottom: 18px;
}

.project-desc {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 24px;
  transition: color 0.3s;
}

.project-placeholder:hover .project-desc {
  color: var(--text-primary);
}

.project-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 100px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: all 0.3s;
}

.project-placeholder:hover .project-tag {
  border-color: rgba(99, 210, 255, 0.25);
  color: var(--accent);
}

/* ===========================
   FOOTER
=========================== */
.footer {
  position: relative;
  z-index: 10;
  padding: 32px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  gap: 12px;
}

.footer-line {
  display: none;
}

.footer p {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

.footer-made {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  opacity: 0.6;
}

/* ===========================
   REAL PROJECT CARD
=========================== */
.project-card-real {
  position: relative;
  display: block;
  padding: 32px 30px 28px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: var(--surface);
  backdrop-filter: blur(12px);
  overflow: hidden;
  transition: all 0.35s var(--ease-out);
  max-width: 480px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;

.project-card-real::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(99, 210, 255, 0.5), rgba(167, 139, 250, 0.4), transparent);
  opacity: 0.6;
}

.project-card-real:hover {
  border-color: rgba(99, 210, 255, 0.35);
  transform: translateY(-5px);
  background: var(--surface-hover);
  box-shadow:
    0 16px 50px rgba(99, 210, 255, 0.08),
    0 0 0 1px rgba(99, 210, 255, 0.1);
}

.project-card-real:hover .project-glow {
  opacity: 1;
}

.project-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.project-icon {
  width: 52px;
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(99, 210, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  transition: all 0.3s;
}

.project-card-real:hover .project-icon {
  border-color: rgba(99, 210, 255, 0.3);
  background: rgba(99, 210, 255, 0.08);
  box-shadow: 0 0 20px rgba(99, 210, 255, 0.1);
}

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

.project-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.project-desc-real {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.project-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.project-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.project-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-muted);
  text-decoration: none;
  flex-shrink: 0;
  transition: all 0.25s var(--ease-spring);
}

.project-link svg {
  width: 14px;
  height: 14px;
}

.project-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(99, 210, 255, 0.08);
  transform: scale(1.1);
}


[data-aos] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

[data-aos].visible {
  opacity: 1;
  transform: translateY(0);
}

[data-aos][data-aos-delay="100"] { transition-delay: 100ms; }
[data-aos][data-aos-delay="200"] { transition-delay: 200ms; }
[data-aos][data-aos-delay="250"] { transition-delay: 250ms; }
[data-aos][data-aos-delay="300"] { transition-delay: 300ms; }
[data-aos][data-aos-delay="400"] { transition-delay: 400ms; }

/* ===========================
   SCROLLBAR
=========================== */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb {
  background: rgba(99, 210, 255, 0.2);
  border-radius: 2px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(99, 210, 255, 0.4);
}

/* ===========================
   RESPONSIVE
=========================== */
@media (max-width: 768px) {
  .nav { padding: 16px 20px; }

  .hero { padding: 90px 20px 50px; }
  .hero-inner { gap: 22px; }

  .hero-name { font-size: clamp(54px, 16vw, 80px); }

  .glass-card { padding: 20px 22px; }

  .social-links { gap: 10px; }
  .social-btn { padding: 10px 18px; font-size: 12px; }

  .projects-section { padding: 60px 20px 80px; }
  .project-cards { grid-template-columns: 1fr; }

  .footer {
    flex-direction: column;
    text-align: center;
    padding: 24px 20px;
    gap: 6px;
  }
}

@media (max-width: 420px) {
  .social-links { flex-direction: column; align-items: center; }
  .social-btn { width: 100%; max-width: 240px; justify-content: center; }
}

/* Selection */
::selection {
  background: rgba(99, 210, 255, 0.2);
  color: var(--accent);
}
