:root {
  --bg: #212121;
  --panel: #323232;
  --panel-2: #141414;
  --text: #ffffff;
  --muted: #cfcfcf;
  --btn: #2b2b2b;
  --shadow-1: 0 4px 10px rgba(0,0,0,0.25);
  --shadow-2: 0 4px 20px rgba(0,0,0,0.25);
  --radius-lg: 40px;
  --radius-md: 30px;
  --radius-sm: 15px;
  --grad-1: linear-gradient(91deg, #f4ff58 0%, #47ffd4 51%, #ff9951 100%);
  --grad-ui: linear-gradient(90deg, #ff4242 2%, #b682ff 28%, #6de9ff 53%);
  --grad-ux: linear-gradient(90deg, #4245ff 2%, #ffc082 29%, #ff6d70 55%);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Montserrat", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color .3s ease;
}

.container { width: min(1200px, 100% - 32px); margin: 0 auto; }

/* --- Header --- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(33,33,33,0.8); backdrop-filter: saturate(120%) blur(8px); border-bottom: 1px solid rgba(255,255,255,0.08); transition: background-color .3s ease; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 16px 0; }
.brand-logo { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; transition: transform .3s ease; }
.brand:hover .brand-logo { transform: scale(1.1); }
.site-nav ul { display: flex; gap: 28px; list-style: none; padding: 0; margin: 0; }
.site-nav a { color: var(--text); text-decoration: none; font-weight: 500; position: relative; padding: 4px 0; }
.site-nav a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 100%; height: 2px; background: var(--grad-1); transform: scaleX(0); transform-origin: right; transition: transform .3s ease-out; }
.site-nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-toggle { display: none; background: transparent; border: 0; padding: 4px; z-index: 100; }
.nav-toggle img { width: 28px; height: 28px; }

/* --- General & Typography --- */
.section { padding: 80px 0; }
.section-title { font-family: "Quantico", ui-serif, serif; text-align: center; font-size: clamp(28px, 3.8vw, 48px); margin: 0 0 48px; }
.grad { background: var(--grad-1); -webkit-background-clip: text; background-clip: text; color: transparent; }
.grad-ui { background: var(--grad-ui); -webkit-background-clip: text; background-clip: text; color: transparent; }
.grad-ux { background: var(--grad-ux); -webkit-background-clip: text; background-clip: text; color: transparent; }

.btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 28px; background: var(--btn); color: var(--text); border-radius: var(--radius-sm); text-decoration: none; box-shadow: var(--shadow-1); border: 2px solid #fff1; font-weight: 500; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.btn.btn-secondary { background: transparent; border-color: var(--text); }
.btn.btn-secondary:hover { background: var(--text); color: var(--bg); }

/* --- Scroll Animations --- */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* --- Hero Section --- */
.hero-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: center; }
.hero-title { font-family: "Quantico"; font-size: clamp(32px, 5vw, 60px); margin: 0 0 12px; }
.hero-subtitle { font-size: clamp(18px, 2.2vw, 22px); line-height: 1.6; color: var(--muted); margin: 0 0 28px; max-width: 50ch; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }
.hero-art { position: relative; }
.hero-blob { position: absolute; inset: 10% auto auto 0; width: 400px; height: 320px; background: rgba(109, 233, 255, 0.2); filter: blur(80px); border-radius: 999px; z-index: -1; animation: pulse 8s infinite ease-in-out; }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.15); } }
.hero-image-wrapper { position: relative; }
.hero-image-wrapper:hover .hero-image {
  transform: scale(1.05) translateY(-10px);
  box-shadow: 0 0 45px rgba(71, 255, 212, 0.8);
  animation-play-state: paused;
}
@keyframes breathing-glow {
  0% { box-shadow: 0 0 25px rgba(71, 255, 212, 0.5); }
  50% { box-shadow: 0 0 40px rgba(244, 255, 88, 0.7); }
  100% { box-shadow: 0 0 25px rgba(71, 255, 212, 0.5); }
}
.hero-image {
  position: relative;
  width: min(420px, 90%);
  height: auto;
  border-radius: 50%;
  display: block;
  margin: 0 auto;
  z-index: 2;
  box-shadow: 0 0 25px rgba(71, 255, 212, 0.5);
  animation: breathing-glow 5s infinite ease-in-out;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* --- Cards --- */
.cards { display: grid; gap: 24px; }
.two-col { grid-template-columns: repeat(2, 1fr); }
.four-col { grid-template-columns: repeat(4, 1fr); }
.card { background: var(--panel); border-radius: var(--radius-lg); box-shadow: var(--shadow-1); padding: 18px; transition: transform .3s ease, box-shadow .3s ease; text-decoration: none; color: var(--text); }
/* --- 3D TILT EFFECT --- */
.tilt-card { transform-style: preserve-3d; transition: transform 0.1s linear; }
.card-media img, .card-media video { width: 100%; height: 280px; border-radius: 20px; object-fit: cover; }
.card-title { font-family: "Quantico"; font-size: clamp(22px, 2.5vw, 28px); margin: 14px 0 6px; }
.card-text { font-family: "Montserrat"; font-size: 16px; line-height: 1.6; color: var(--muted); }

/* --- Projects Section --- */
.project-card { padding: 0; overflow: hidden; position: relative; }
.project-card-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.7); padding: 24px; display: flex; flex-direction: column; justify-content: flex-end; opacity: 0; transform: translateY(20px); transition: opacity .4s ease, transform .4s ease; }
.project-card:hover .project-card-overlay { opacity: 1; transform: translateY(0); }
.project-card-title { font-family: "Quantico"; font-size: 28px; margin: 0 0 4px; }
.project-card-category { color: var(--muted); margin: 0; }
.card-media-img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.project-card:hover .card-media-img { transform: scale(1.05); }
.dark-panel { background: #1a1a1a; }

/* --- Tech Stack Section --- */
.tech-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 32px; }
.tech-item { text-align: center; transition: transform .2s ease; }
.tech-item:hover { transform: scale(1.1); }
.tech-item img { height: 64px; margin-bottom: 8px; }
.tech-item span { display: block; font-weight: 500; }

/* --- Process Section --- */
.process-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; position: relative; }
.process-step { background: var(--panel); padding: 24px; border-radius: var(--radius-md); text-align: center; border-top: 4px solid transparent; transition: transform .3s ease, background-color .3s ease; }
.process-step:hover { transform: translateY(-8px); background-color: #3c3c3c; }
.process-number { font-family: "Quantico"; font-size: 32px; font-weight: 700; color: var(--muted); margin-bottom: 12px; }
.process-title { font-family: "Quantico"; font-size: 20px; margin: 0 0 8px; }
.process-text { color: var(--muted); line-height: 1.6; font-size: 15px; }

/* --- Certifications Section --- */
.cert-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.cert img { width: 100%; height: auto; object-fit: cover; border-radius: 20px; }
.cert figcaption { text-align: center; font-weight: 500; margin-top: 12px; color: var(--muted); }

/* --- Footer --- */
.site-footer { background: var(--panel-2); color: var(--text); padding: 80px 0 0; text-align: center; }
.footer-title { font-family: "Quantico"; font-size: clamp(28px, 4vw, 48px); margin: 0 0 12px; }
.footer-subtitle { color: var(--muted); font-size: 18px; max-width: 50ch; margin: 0 auto 24px; }
.footer-btn { font-size: 18px; padding: 16px 32px; }
.footer-socials { display: flex; justify-content: center; gap: 24px; margin-top: 40px; }
.footer-socials a { color: var(--muted); text-decoration: none; font-weight: 500; transition: color .2s ease; }
.footer-socials a:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 20px 0; margin-top: 60px; }
.footer-bottom p { margin: 0; color: var(--muted); font-size: 14px; }

/* --- Responsive Media Queries --- */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-art { order: -1; margin-bottom: 2rem; }
  .hero-subtitle { margin: 0 auto 28px; }
  .hero-actions { justify-content: center; }
  .hero-blob { left: 50%; transform: translateX(-50%); }
  .four-col, .cert-grid { grid-template-columns: repeat(2, 1fr); }
  .process-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .site-nav { position: fixed; inset: 0 0 0 30%; background: #1e1e1e; flex-direction: column; padding: 100px 20px 20px; transform: translateX(100%); transition: transform .35s ease-out; }
  .site-nav.open { transform: translateX(0); }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav li { border-top: 1px solid #fff1; }
  .site-nav a { display: block; padding: 18px 16px; font-size: 18px; }
  .nav-toggle { display: inline-flex; }
  .two-col, .four-col, .cert-grid, .process-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .container { width: calc(100% - 24px); }
  .card-media img { height: 220px; }
}

/* --- FAQ Section --- */
.faq-grid {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.faq-item {
  background: var(--panel);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,0.1);
  transition: background-color .3s ease;
}
.faq-item[open] {
  background: #3c3c3c;
}
.faq-item summary {
  padding: 20px;
  font-weight: 500;
  font-size: 18px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary::after {
  content: '+';
  font-family: "Quantico", monospace;
  font-size: 24px;
  transition: transform .3s ease;
}
.faq-item[open] summary::after {
  transform: rotate(45deg);
}
.faq-item p {
  padding: 0 20px 20px;
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}