/* VARIABLES & SYSTEM */
:root {
  /* Dark Mode (Default) */
  --background: #030712;
  --bg-alt: #080c16;
  --bg-card: rgba(8, 12, 24, 0.65);
  
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-glow: rgba(99, 102, 241, 0.15);
  --accent: #10b981;
  --accent-rgb: 16, 185, 129;
  --accent-glow: rgba(16, 185, 129, 0.15);
  --accent-1: #10b981;
  
  --text: #f3f4f6;
  --text-muted: #9ca3af;
  
  --border: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(99, 102, 241, 0.15);
  
  --shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.7);
  --radius: 24px;
  --radius-sm: 12px;
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Sora', sans-serif;
  
  --speed: 0.3s;
  --speed-fast: 0.15s;
}

html[data-theme="light"] {
  /* Light Mode */
  --background: #f8fafc;
  --bg-alt: #f1f5f9;
  --bg-card: rgba(255, 255, 255, 0.75);
  
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-glow: rgba(79, 70, 229, 0.1);
  --accent: #059669;
  --accent-rgb: 5, 150, 105;
  --accent-glow: rgba(5, 150, 105, 0.1);
  --accent-1: #059669;
  
  --text: #0f172a;
  --text-muted: #64748b;
  
  --border: rgba(15, 23, 42, 0.08);
  --border-glow: rgba(79, 70, 229, 0.12);
  
  --shadow: 0 24px 48px -12px rgba(15, 23, 42, 0.08);
}

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

html {
  scroll-behavior: smooth;
  font-size: 100%;
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: var(--font-sans);
  background-color: var(--background);
  color: var(--text);
  line-height: 1.625;
  overflow-x: hidden;
  width: 100%;
  transition: background-color var(--speed) ease, color var(--speed) ease;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--speed-fast) ease;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  background: none;
  border: none;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

/* SCROLLBAR */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--background);
}
::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-hover);
}

/* TYPOGRAPHY */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.25;
}

/* LAYOUT & GRID (8px Grid) */
.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 96px 0;
}
@media (max-width: 768px) {
  .section {
    padding: 64px 0;
  }
}

.alt-bg {
  background-color: var(--bg-alt);
}

/* SECTION HEADER */
.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-tag {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 1000px;
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
  font-size: 0.8rem;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 16px;
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* GLASS CONTAINER UTILITY */
.glass-panel {
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: border-color var(--speed) ease, box-shadow var(--speed) ease, transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1), background-color var(--speed) ease;
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 28px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease, background-color var(--speed-fast) ease, border-color var(--speed-fast) ease, color var(--speed-fast) ease;
}
.btn svg {
  width: 18px;
  height: 18px;
  transition: transform var(--speed-fast) ease;
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
  border: 1px solid transparent;
}
.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -8px var(--primary-glow);
}
.btn-primary:hover svg {
  transform: translateY(2px);
}
.btn-primary:active {
  transform: translateY(0) scale(0.98);
}

.btn-outline {
  border: 1px solid var(--border);
  color: var(--text);
  background: rgba(255, 255, 255, 0.02);
}
.btn-outline:hover {
  background-color: #ffffff;
  border-color: #ffffff;
  color: #000000;
  transform: translateY(-2px);
}
.btn-outline:active {
  transform: translateY(0) scale(0.98);
}

.btn-full {
  width: 100%;
}

/* LOADER */
#page-loader {
  position: fixed;
  inset: 0;
  background-color: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  /* Clip-path exit animation (driven by JS class) */
  clip-path: inset(0 0 0% 0);
  transition: clip-path 0.45s cubic-bezier(0.76, 0, 0.24, 1);
  pointer-events: auto;
}
#page-loader.is-clipping {
  clip-path: inset(0 0 100% 0);
  pointer-events: none;
}
#page-loader.hidden {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0s, visibility 0s;
}

.loader-inner {
  text-align: center;
  width: 100%;
  max-width: 400px;
  padding: 0 24px;
}

.loader-logo {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text);
  margin-bottom: 20px;
  white-space: nowrap;
}


.loader-progress-container {
  width: 100%;
  height: 4px;
  background-color: var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 12px;
  position: relative;
}

.loader-progress-bar {
  width: 0%;
  height: 100%;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary-glow);
  border-radius: 10px;
}

.loader-status {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-sans);
}

.loader-label {
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.loader-percentage {
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
}

/* SCROLL PROGRESS BAR */
#scroll-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  box-shadow: 0 0 8px var(--primary);
  z-index: 9998;
  transition: width 0.05s linear;
}

/* BACK TO TOP */
#back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background-color: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
  transform: translateY(80px);
  opacity: 0;
  transition: transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1), opacity var(--speed) ease, border-color var(--speed-fast) ease, color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
  z-index: 999;
}
#back-to-top svg {
  width: 20px;
  height: 20px;
}
#back-to-top.visible {
  transform: translateY(0);
  opacity: 1;
}
#back-to-top:hover {
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: 0 0 16px var(--primary-glow);
}

/* SITE HEADER & NAV */
#site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: background-color var(--speed) ease, border-color var(--speed) ease, padding var(--speed) ease, box-shadow var(--speed) ease;
  padding: 24px 0;
}

#site-header.scrolled {
  background-color: rgba(3, 7, 18, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
}
#site-header.scrolled:hover {
  background-color: rgba(3, 7, 18, 0.95);
  padding: 16px 0;
  box-shadow: 0 12px 40px -10px rgba(0, 0, 0, 0.4);
}

html[data-theme="light"] #site-header.scrolled {
  background-color: rgba(248, 250, 252, 0.85);
}
html[data-theme="light"] #site-header.scrolled:hover {
  background-color: rgba(248, 250, 252, 0.95);
}

.navbar {
  position: relative;
  padding: 0 48px;
  transition: padding var(--speed) ease;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text);
  display: flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}


.nav-right {
  display: flex;
  align-items: center;
  gap: 32px;
  transition: gap var(--speed) ease;
}
#site-header.scrolled .nav-right {
  gap: 24px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  transition: gap var(--speed) ease;
}
#site-header.scrolled .nav-links {
  gap: 16px;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 8px 16px;
  position: relative;
  white-space: nowrap;
  transition: color var(--speed-fast) ease, transform var(--speed-fast) ease, padding var(--speed) ease, font-size var(--speed) ease;
}
#site-header.scrolled .nav-link {
  font-size: 0.88rem;
  padding: 6px 12px;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 16px;
  right: 16px;
  height: 2px;
  background-color: var(--primary);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--speed-fast) cubic-bezier(0.16, 1, 0.3, 1);
}
#site-header.scrolled .nav-link::after {
  left: 12px;
  right: 12px;
}
.nav-link:hover, .nav-link.active {
  color: var(--text);
}
.nav-link:hover::after, .nav-link.active::after {
  transform: scaleX(1);
  transform-origin: left;
}
.nav-link:active {
  transform: scale(0.96);
}

.nav-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ctrl-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: var(--bg-card);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color var(--speed-fast) ease, color var(--speed-fast) ease, background-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease, padding var(--speed) ease;
}
#site-header.scrolled .ctrl-btn {
  padding: 6px 12px;
}
.ctrl-btn svg {
  width: 16px;
  height: 16px;
}
.ctrl-btn:hover {
  border-color: var(--primary);
  color: var(--text);
  background-color: rgba(99, 102, 241, 0.08);
  box-shadow: 0 0 12px var(--primary-glow);
}

/* Sun/Moon icons for Theme */
html[data-theme="light"] .icon-moon { display: none; }
html[data-theme="dark"]  .icon-sun  { display: none; }

/* Burger menu button */
.burger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  cursor: pointer;
  transition: border-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
.burger-btn:hover {
  border-color: var(--primary);
  box-shadow: 0 0 12px var(--primary-glow);
}
.burger-btn span {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--text);
  border-radius: 4px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}
.burger-btn.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger-btn.open span:nth-child(2) { opacity: 0; }
.burger-btn.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* MOBILE MENU (Glassmorphic Dropdown) */
.mobile-menu {
  position: fixed;
  top: 92px;
  right: 24px;
  margin-top: 8px;
  width: 240px;
  background-color: rgba(3, 7, 18, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  z-index: 999;
  padding: 12px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity var(--speed) ease, transform var(--speed) ease, visibility var(--speed) ease, top var(--speed) ease;
}
#site-header.scrolled .mobile-menu {
  top: 68px;
}
html[data-theme="light"] .mobile-menu {
  background-color: rgba(255, 255, 255, 0.85);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}
.mobile-menu.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.mobile-menu-inner {
  width: 100%;
}
.mobile-menu ul {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.mob-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 8px 12px;
  display: block;
  border-radius: var(--radius-sm);
  transition: color var(--speed-fast) ease, background-color var(--speed-fast) ease;
}
.mob-link:hover, .mob-link.active {
  color: var(--text);
  background-color: rgba(99, 102, 241, 0.08);
}

/* HERO SECTION */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 120px;
  padding-bottom: 64px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
/* Blobs removed */

.hero-container {
  width: 100%;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 64px;
  position: relative;
  z-index: 1;
}

.hero-greeting {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  opacity: 0.8;
}

.hero-name {
  font-size: clamp(3rem, 7vw, 4.8rem);
  font-weight: 850;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
  line-height: 1;
  background: linear-gradient(135deg, #ffffff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
html[data-theme="light"] .hero-name {
  background: linear-gradient(135deg, #0f172a 30%, #475569 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.name-accent {
  background: linear-gradient(135deg, var(--primary) 0%, #a5b4fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-typing {
  font-size: clamp(1.3rem, 2.8vw, 2rem);
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 40px;
  min-height: 48px;
}
.typed-cursor {
  color: var(--primary);
  font-weight: 300;
  animation: cursorBlink 1s infinite;
}
@keyframes cursorBlink {
  50% { opacity: 0; }
}

.hero-socials {
  display: flex;
  gap: 16px;
  margin-bottom: 40px;
}
.social-link {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: border-color var(--speed-fast) ease, color var(--speed-fast) ease, background-color var(--speed-fast) ease, transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
.social-link svg {
  width: 20px;
  height: 20px;
}
.social-link:hover {
  border-color: var(--primary);
  color: var(--text);
  background-color: rgba(99, 102, 241, 0.05);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--primary-glow);
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-image {
  display: flex;
  justify-content: center;
}

/* Modern Circular Profile Image with Attached Outer Border */
.hero-profile-circle-wrapper {
  position: relative;
  width: 380px;
  height: 380px;
  max-width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}
.hero-profile-circle {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  z-index: 2;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}
.hero-profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--speed) ease;
}
.hero-profile-circle:hover .hero-profile-img {
  transform: scale(1.08);
}
.circle-border-decor {
  position: absolute;
  top: -6px;
  left: -6px;
  width: calc(100% + 12px);
  height: calc(100% + 12px);
  border-radius: 50%;
  border: 3px solid var(--primary);
  z-index: 1;
  pointer-events: none;
  filter: drop-shadow(0 0 8px var(--primary-glow));
}


/* ABOUT SECTION */
.about-grid {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 64px;
  align-items: center;
}

.about-img-wrap {
  position: relative;
}
.about-img-wrap::after {
  content: '';
  position: absolute;
  inset: -10px;
  border-radius: calc(var(--radius) + 10px);
  background: linear-gradient(135deg, var(--primary-glow), var(--accent-glow));
  filter: blur(20px);
  z-index: -1;
  opacity: 0.5;
}
.about-img-frame {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1), border-color var(--speed) ease;
}
.about-img-frame:hover {
  transform: scale(1.02) rotate(1deg);
  border-color: var(--primary);
}
.about-img-frame img {
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
}

.about-text p {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 1.05rem;
  line-height: 1.7;
}

/* About Lead Paragraph styling */
.about-text .about-lead {
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.6;
}

/* SERVICES SECTION */
.services-section .container {
  max-width: 1600px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

.service-card {
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: border-color var(--speed) ease, box-shadow var(--speed) ease, transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1), background-color var(--speed) ease;
}
.service-card:hover {
  border-color: var(--primary);
  box-shadow: 0 20px 40px -10px var(--primary-glow);
  transform: translateY(-8px);
}

.service-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background-color: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--primary);
  transition: background-color var(--speed-fast) ease, border-color var(--speed-fast) ease, color var(--speed-fast) ease, transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1), box-shadow var(--speed-fast) ease;
}
.service-icon svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  transition: transform var(--speed-fast) ease;
}
.service-card:hover .service-icon {
  background-color: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 8px 20px var(--primary-glow);
  transform: scale(1.05);
}
.service-card:hover .service-icon svg {
  transform: rotate(6deg);
}

.service-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
  transition: color var(--speed-fast) ease;
}
.service-card:hover h3 {
  color: var(--primary);
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 0;
}

/* SKILLS SECTION (Tabs & Grid) */
.skills-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.tab-btn {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 12px 28px;
  border-radius: 1000px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--speed-fast) ease;
}

.tab-btn:hover, .tab-btn.active {
  border-color: var(--primary);
  color: var(--text);
  box-shadow: 0 0 16px var(--primary-glow);
  background: rgba(99, 102, 241, 0.08);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 24px;
}

@media (max-width: 1200px) {
  .skills-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 768px) {
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 480px) {
  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.skill-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  text-align: center;
  transition: border-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease, transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1);
  cursor: default;
}

.skill-card-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--speed) cubic-bezier(0.16, 1, 0.3, 1);
}

.skill-card-icon svg {
  width: 100%;
  height: 100%;
  transition: filter var(--speed-fast) ease;
}

.skill-card span {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  letter-spacing: -0.01em;
}

.skill-card:hover {
  transform: translateY(-8px);
  border-color: var(--tech-color);
  box-shadow: 0 12px 24px var(--tech-glow);
}

.skill-card:hover .skill-card-icon {
  transform: scale(1.1) rotate(4deg);
}

/* PROJECTS SECTION — Ultra-Modern Redesign */

/* Filter Pills */
/* PROJECTS SECTION */
.projects-filters {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.proj-filter-btn {
  background: transparent;
  border: 1px solid var(--border);
  padding: 8px 20px;
  border-radius: 8px;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background var(--speed-fast) ease, color var(--speed-fast) ease, border-color var(--speed-fast) ease;
}
.proj-filter-btn:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text);
  border-color: rgba(255,255,255,0.2);
}
.proj-filter-btn.active {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  border-color: transparent;
}

/* Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

/* PROJECT CARD — ProjectCard Component Style */
.project-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition:
    transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.3s ease;
}
.project-card:hover {
  transform: translateY(-8px);
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 24px 48px -12px rgba(99, 102, 241, 0.2), 0 0 0 1px rgba(99, 102, 241, 0.1);
}

/* Cover — Image (aspect-video ratio) */
.project-cover {
  aspect-ratio: 16 / 9;
  position: relative;
  overflow: hidden;
  background: #03040d;
  flex-shrink: 0;
}
.project-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.project-img.fit-contain {
  object-fit: contain;
  padding: 28px;
  background: #0a1128;
}
.project-card:hover .project-img {
  transform: scale(1.1);
}

/* Cover hover overlay */
.cover-hover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(5, 8, 17, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.project-cover:hover .cover-hover-overlay {
  opacity: 1;
  pointer-events: auto;
}
.visit-overlay-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 10px 20px;
  border-radius: 8px;
  transition: background 0.2s ease, transform 0.2s ease;
}
.visit-overlay-btn:hover {
  background: var(--primary-hover);
  color: #fff;
  transform: scale(1.04);
}

/* Cover — Confidential */
.project-cover.confidential {
  background: #020408;
}
.project-cover-bg {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: radial-gradient(ellipse at center, rgba(99, 102, 241, 0.08) 0%, transparent 70%);
}
.project-cover-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.012) 1px, transparent 1px);
  background-size: 24px 24px;
}
.project-svg {
  width: 78%;
  height: auto;
  max-height: 130px;
  position: relative;
  z-index: 1;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.project-card:hover .project-svg {
  transform: translateY(-6px);
}

/* Confidential overlay */
.confidential-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(5, 8, 17, 0.55);
  backdrop-filter: blur(2px);
  z-index: 2;
}
.lock-ring {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(99, 102, 241, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.1);
  animation: lockPulse 2.5s ease-in-out infinite;
}
.lock-icon {
  width: 18px;
  height: 18px;
  color: var(--primary);
}
.confidential-overlay > span {
  color: rgba(255, 255, 255, 0.7);
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.internal-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(10, 12, 25, 0.75);
  border: 1px solid rgba(99, 102, 241, 0.3);
  color: rgba(166, 170, 255, 0.9);
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  backdrop-filter: blur(6px);
  z-index: 3;
}
@keyframes lockPulse {
  0%, 100% { box-shadow: 0 0 10px rgba(99, 102, 241, 0.15); }
  50%       { box-shadow: 0 0 20px rgba(99, 102, 241, 0.35); }
}

/* Card Body */
.project-body {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Title */
.project-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
  margin-bottom: 12px;
  color: var(--text);
  transition: color 0.3s ease;
}
.project-card:hover .project-title {
  color: var(--primary);
}

.project-desc {
  color: var(--text-muted);
  font-size: 0.875rem;
  line-height: 1.65;
  margin-bottom: 16px;
  flex: 1;
}

/* Tags */
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}
.project-tag {
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: rgba(165, 180, 252, 0.9);
  font-size: 0.7rem;
  font-weight: 500;
  padding: 3px 9px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}

/* CTA Link */
.project-cta-link {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  transition: gap 0.3s ease, opacity 0.2s ease;
  text-decoration: none;
  width: fit-content;
}
.project-cta-link.disabled {
  color: var(--text-muted);
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
  font-weight: 500;
}
.project-cta-link.playstore {
  color: #10b981;
  opacity: 0.75;
  cursor: default;
  pointer-events: none;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.825rem;
}
.project-cta-link:hover {
  opacity: 0.85;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.project-cta-arrow {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.project-cta-link:hover .project-cta-arrow {
  transform: translateX(4px);
}

/* Action buttons */
.project-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
}
.project-actions-row {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.project-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  white-space: nowrap;
  text-decoration: none;
}
.github-btn {
  background: transparent;
  border-color: var(--border);
  color: var(--text-muted);
  flex: 0 0 auto;
}
.github-btn:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.2);
  color: var(--text);
}
.project-btn.disabled {
  background: rgba(255,255,255,0.02);
  border-color: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.2);
  cursor: not-allowed;
  flex: 1;
  justify-content: center;
}

/* Responsive */
@media (max-width: 1100px) {
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .projects-grid { grid-template-columns: 1fr; gap: 16px; }
  .projects-filters { gap: 6px; }
  .proj-filter-btn { padding: 7px 14px; font-size: 0.82rem; }
}


/* TESTIMONIALS SECTION */
.carousel-wrapper {
  max-width: 800px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

.carousel {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.testi-slide {
  min-width: 100%;
  padding: 0 16px;
}

.testi-card {
  padding: 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.testi-quote {
  position: absolute;
  top: 16px;
  left: 32px;
  font-family: var(--font-display);
  font-size: 8rem;
  font-weight: 900;
  color: var(--primary);
  opacity: 0.06;
  line-height: 1;
  pointer-events: none;
}

.testi-stars {
  color: #f59e0b;
  font-size: 0.95rem;
  margin-bottom: 20px;
  display: flex;
  justify-content: center;
  gap: 4px;
}

.testi-text {
  font-size: 1.15rem;
  font-style: italic;
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 32px;
  position: relative;
  z-index: 1;
}

.testi-author {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  text-align: left;
}

.testi-avatar {
  width: 52px;
  height: 52px;
  border-radius: 1000px;
  background: var(--primary);
  color: #ffffff;
  font-weight: 800;
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px var(--primary-glow);
}

.testi-name {
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.01em;
}

.testi-role {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 40px;
}

.carousel-btn {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background-color: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: border-color var(--speed-fast) ease, color var(--speed-fast) ease, background-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
.carousel-btn svg {
  width: 20px;
  height: 20px;
}
.carousel-btn:hover {
  border-color: var(--primary);
  color: var(--text);
  background-color: rgba(99, 102, 241, 0.06);
  box-shadow: 0 0 12px var(--primary-glow);
}

.carousel-dots {
  display: flex;
  gap: 8px;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 1000px;
  background-color: var(--border);
  cursor: pointer;
  transition: width var(--speed-fast) ease, background-color var(--speed-fast) ease;
}
.dot.active {
  width: 24px;
  border-radius: 4px;
  background-color: var(--primary);
}

/* CONTACT SECTION */
#contact {
  padding-bottom: 48px;
}
.contact-grid {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 64px;
  align-items: start;
}

.contact-intro {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.7;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 40px;
}
.contact-details li {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: border-color var(--speed-fast) ease, background-color var(--speed-fast) ease;
}
.contact-details li:hover {
  border-color: var(--border);
  background-color: var(--bg-card);
}

.cd-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background-color: rgba(99, 102, 241, 0.06);
  border: 1px solid rgba(99, 102, 241, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background-color var(--speed-fast) ease, border-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
.cd-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--primary);
  transition: stroke var(--speed-fast) ease;
}
.contact-details li:hover .cd-icon {
  background-color: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 0 16px var(--primary-glow);
}
.contact-details li:hover .cd-icon svg {
  stroke: #ffffff;
}

.cd-text {
  display: flex;
  flex-direction: column;
}
.contact-details strong {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}
.contact-details a, .contact-details span {
  font-weight: 600;
  font-size: 1rem;
}
.contact-details a:hover {
  color: var(--primary);
}

.contact-socials {
  display: flex;
  gap: 16px;
  padding-left: 12px;
}

.social-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  font-size: 0.9rem;
  font-weight: 600;
  transition: border-color var(--speed-fast) ease, color var(--speed-fast) ease, background-color var(--speed-fast) ease, transform var(--speed-fast) ease;
}
.social-pill svg {
  width: 20px;
  height: 20px;
}
.social-pill:hover {
  border-color: var(--primary);
  color: var(--text);
  background-color: rgba(99, 102, 241, 0.05);
  transform: translateY(-2px);
}

/* Contact Form */
.contact-form-wrap {
  padding: 40px;
  padding-bottom: 24px;
}
@media (max-width: 576px) {
  .contact-form-wrap {
    padding: 24px;
    padding-bottom: 16px;
  }
}

#contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 576px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}
.form-group input, .form-group textarea {
  width: 100%;
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background-color: var(--bg-card);
  color: var(--text);
  transition: border-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
html[data-theme="light"] .form-group input,
html[data-theme="light"] .form-group textarea {
  background-color: #ffffff;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 12px var(--primary-glow);
}
.form-group input.error, .form-group textarea.error {
  border-color: #ef4444;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  opacity: 0.45;
  transition: opacity var(--speed-fast) ease;
}

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

.form-feedback {
  text-align: center;
  font-weight: 600;
  font-size: 0.95rem;
  min-height: 24px;
}
.form-feedback.success { color: var(--accent); }
.form-feedback.error { color: #ef4444; }

/* FOOTER */
.site-footer {
  padding: 24px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  background-color: rgba(3, 4, 13, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
html[data-theme="light"] .site-footer {
  background-color: rgba(241, 245, 249, 0.6);
  border-top: 1px solid rgba(0, 0, 0, 0.04);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}
.footer-left {
  display: flex;
  align-items: center;
}
.footer-copy {
  color: var(--text-muted);
  font-size: 0.8rem;
  opacity: 0.8;
  line-height: 1.5;
}
.footer-right {
  display: flex;
  align-items: center;
}
.footer-credit {
  color: var(--text-muted);
  font-size: 0.8rem;
  opacity: 0.8;
  line-height: 1.5;
}
.footer-credit a {
  color: var(--primary);
  font-weight: 500;
  transition: color var(--speed-fast) ease;
  position: relative;
  text-decoration: none;
}
.footer-credit a::after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1px;
  bottom: -2px;
  left: 0;
  background-color: var(--accent);
  transform-origin: bottom right;
  transition: transform 0.25s ease-out;
}
.footer-credit a:hover {
  color: var(--accent);
}
.footer-credit a:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

@media (max-width: 768px) {
  .footer-inner {
    flex-direction: column;
    gap: 16px;
    text-align: center;
    align-items: center;
  }
  .footer-left {
    flex-direction: column;
    gap: 8px;
    align-items: center;
  }
  .footer-right {
    display: flex;
    justify-content: center;
    align-items: center;
  }
}@media (max-width: 1250px) {
  .nav-links {
    gap: 12px;
  }
  .nav-right {
    gap: 16px;
  }
  .nav-link {
    padding: 8px 10px;
  }
  .nav-link::after {
    left: 10px;
    right: 10px;
  }
  #site-header.scrolled .nav-links {
    gap: 8px;
  }
  #site-header.scrolled .nav-link {
    padding: 6px 8px;
  }
  #site-header.scrolled .nav-link::after {
    left: 8px;
    right: 8px;
  }
}

/* MEDIA QUERIES & RESPONSIVENESS */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 48px;
  }
  .hero-image {
    grid-row: 1;
  }
  .hero-socials, .hero-cta {
    justify-content: center;
  }
  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  #desktop-nav {
    display: none;
  }
  .burger-btn {
    display: flex;
  }
  .nav-right {
    gap: 16px;
  }
  .navbar {
    padding: 0 32px;
  }
}

@media (max-width: 768px) {
  .services-grid, .projects-grid {
    grid-template-columns: 1fr;
  }
  .hero-profile-circle-wrapper {
    width: 280px;
    height: 280px;
  }
  .navbar {
    padding: 0 24px;
  }
}

@media (max-width: 480px) {
  #lang-label {
    display: none;
  }
  .ctrl-btn {
    padding: 8px;
  }
  #site-header.scrolled .ctrl-btn {
    padding: 6px;
  }
  .logo {
    font-size: 1.25rem;
  }
  .nav-right {
    gap: 8px;
  }
  .navbar {
    padding: 0 16px;
  }
}
