/* ═══════════════════════════════════════════════════════════════
   Zyobits PORTFOLIO — style.css
   Design System, Layout, Components, Animations
   ═══════════════════════════════════════════════════════════════ */

/* ── 1. Custom Properties (Design Tokens) ─────────────────────── */
:root {
  /* Brand palette */
  --accent-primary:   hsl(207, 90%, 54%);   /* Electric blue */
  --accent-secondary: hsl(265, 85%, 62%);   /* Violet */
  --accent-tertiary:  hsl(175, 80%, 45%);   /* Cyan */
  --accent-glow:      hsla(207, 90%, 54%, 0.18);

  /* Dark theme (default) */
  --bg-base:          hsl(220, 16%, 8%);
  --bg-surface:       hsl(220, 14%, 11%);
  --bg-elevated:      hsl(220, 12%, 15%);
  --bg-card:          hsl(220, 14%, 12%);
  --border-color:     hsla(220, 20%, 50%, 0.14);
  --border-hover:     hsla(207, 90%, 54%, 0.35);
  --text-primary:     hsl(220, 15%, 95%);
  --text-secondary:   hsl(220, 12%, 65%);
  --text-muted:       hsl(220, 10%, 42%);
  --shadow-sm:        0 1px 3px hsla(220, 30%, 5%, 0.4);
  --shadow-md:        0 4px 16px hsla(220, 30%, 5%, 0.5);
  --shadow-lg:        0 12px 40px hsla(220, 30%, 5%, 0.6);
  --shadow-glow:      0 0 30px hsla(207, 90%, 54%, 0.15);

  /* Typography */
  --font-sans: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Spacing */
  --section-pad: 6rem 0;
  --container-width: 1200px;
  --nav-height: 68px;

  /* Radii */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  28px;

  /* Transition */
  --ease-out:   cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in:    cubic-bezier(0.64, 0, 0.78, 0);
  --ease-inout: cubic-bezier(0.65, 0, 0.35, 1);
  --duration:   280ms;
}

/* Light theme overrides */
[data-theme="light"] {
  --bg-base:       hsl(215, 25%, 97%);
  --bg-surface:    hsl(215, 20%, 93%);
  --bg-elevated:   hsl(215, 15%, 89%);
  --bg-card:       hsl(0, 0%, 100%);
  --border-color:  hsla(220, 20%, 40%, 0.12);
  --border-hover:  hsla(207, 90%, 44%, 0.40);
  --text-primary:  hsl(220, 20%, 12%);
  --text-secondary:hsl(220, 15%, 38%);
  --text-muted:    hsl(220, 10%, 58%);
  --shadow-sm:     0 1px 3px hsla(220, 20%, 30%, 0.12);
  --shadow-md:     0 4px 16px hsla(220, 20%, 30%, 0.16);
  --shadow-lg:     0 12px 40px hsla(220, 20%, 30%, 0.2);
  --shadow-glow:   0 0 30px hsla(207, 90%, 54%, 0.12);
  --accent-glow:   hsla(207, 90%, 54%, 0.12);
}

/* ── 2. Reset & Base ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.65;
  overflow-x: hidden;
  transition: background-color 0.35s var(--ease-out), color 0.35s var(--ease-out);
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.desktop-only { display: inline; }

/* ── 3. Gradient utilities ────────────────────────────────────── */
.gradient-text {
  background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── 4. Section shared styles ─────────────────────────────────── */
.section { padding: var(--section-pad); position: relative; }

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent-primary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 620px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ── 5. Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 100px;
  font-size: 0.95rem;
  font-weight: 600;
  transition: all var(--duration) var(--ease-out);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.08);
  opacity: 0;
  transition: opacity var(--duration);
}
.btn:hover::after { opacity: 1; }

.btn-primary {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: #fff;
  box-shadow: 0 4px 20px hsla(207, 90%, 54%, 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px hsla(207, 90%, 54%, 0.5);
}
.btn-primary:active { transform: translateY(0); }

.btn-outline {
  border: 1.5px solid var(--border-color);
  color: var(--text-primary);
  background: transparent;
}
.btn-outline:hover {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  background: var(--accent-glow);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.55rem 1.2rem;
  font-size: 0.85rem;
}

.btn-full { width: 100%; justify-content: center; }

/* ── 6. NAVBAR ────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  transition: background var(--duration) var(--ease-out),
              border-color var(--duration),
              box-shadow var(--duration);
}

.navbar.scrolled {
  background: hsla(220, 16%, 8%, 0.85);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

[data-theme="light"] .navbar.scrolled {
  background: hsla(215, 25%, 97%, 0.85);
}

.nav-container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.nav-logo {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 2px;
  transition: opacity var(--duration);
}
.nav-logo:hover { opacity: 0.8; }
.logo-bracket { color: var(--accent-primary); }
.logo-text { color: var(--text-primary); }

/* Nav menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link {
  padding: 0.5rem 0.9rem;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: color var(--duration), background var(--duration);
  position: relative;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px; left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 18px; height: 2px;
  background: var(--accent-primary);
  border-radius: 2px;
  transition: transform var(--duration) var(--ease-out);
}
.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}
.nav-link:hover::after,
.nav-link.active::after { transform: translateX(-50%) scaleX(1); }

/* Theme toggle */
.theme-toggle {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  transition: color var(--duration), background var(--duration), transform 0.4s;
  margin-left: 0.5rem;
}
.theme-toggle:hover {
  color: var(--accent-primary);
  background: var(--accent-glow);
  transform: rotate(20deg);
}

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

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px; height: 40px;
  padding: 8px;
}
.hamburger-line {
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.3s var(--ease-out), opacity 0.3s;
}
.nav-toggle.open .hamburger-line:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open .hamburger-line:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open .hamburger-line:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── 7. HERO ──────────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: calc(var(--nav-height) + 2rem) 1.5rem 4rem;
}

.hero-bg-image {
  position: absolute;
  inset: 0;
  background-image: url('assets/images/hero_bg.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.22;
  transition: opacity 0.4s;
}
[data-theme="light"] .hero-bg-image { opacity: 0.12; }

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 40%,
    hsla(207, 90%, 25%, 0.25) 0%,
    transparent 70%),
    linear-gradient(to bottom,
      var(--bg-base) 0%,
      transparent 30%,
      transparent 70%,
      var(--bg-base) 100%);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 860px;
  animation: fadeInUp 1s var(--ease-out) both;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: var(--accent-glow);
  border: 1px solid hsla(207, 90%, 54%, 0.3);
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--accent-primary);
  margin-bottom: 1.75rem;
}
.badge-dot {
  width: 7px; height: 7px;
  background: var(--accent-tertiary);
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

.hero-title {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.08;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 2.5rem;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta-group {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 3.5rem;
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}
.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
}
.stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
  font-family: var(--font-mono);
}
.stat-suffix { font-size: 1.4rem; font-weight: 800; color: var(--accent-primary); }
.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}
.stat-divider {
  width: 1px;
  height: 36px;
  background: var(--border-color);
}

.hero-scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  animation: fadeIn 1.5s 1s both;
}
.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--accent-primary), transparent);
  animation: scroll-line 2s ease-in-out infinite;
}

/* ── 8. PROJECTS ──────────────────────────────────────────────── */
.projects-section { background: var(--bg-base); }

/* Filter bar */
.filter-bar {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.filter-btn {
  padding: 0.5rem 1.25rem;
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface);
  transition: all var(--duration) var(--ease-out);
}
.filter-btn:hover {
  color: var(--accent-primary);
  border-color: var(--accent-primary);
  background: var(--accent-glow);
}
.filter-btn.active {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 16px hsla(207, 90%, 54%, 0.3);
}

/* Projects grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.75rem;
}

/* Project card */
.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--duration) var(--ease-out),
              border-color var(--duration),
              box-shadow var(--duration);
  animation: cardIn 0.5s var(--ease-out) both;
  display: flex;
  flex-direction: column;
}
.project-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.project-card.hidden {
  display: none;
}

.project-thumbnail {
  width: 100%;
  height: 210px;
  object-fit: cover;
  transition: transform 0.5s var(--ease-out);
}
.project-card:hover .project-thumbnail { transform: scale(1.04); }

.project-thumbnail-wrap {
  overflow: hidden;
  position: relative;
}
.project-category-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.25rem 0.65rem;
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}
.badge-cat-hardware { background: hsla(25, 90%, 55%, 0.85); color: #fff; }
.badge-cat-firmware  { background: hsla(207, 90%, 50%, 0.85); color: #fff; }
.badge-cat-gamedev   { background: hsla(265, 85%, 60%, 0.85); color: #fff; }
.badge-cat-pcb       { background: hsla(145, 70%, 40%, 0.85); color: #fff; }

.project-body {
  padding: 1.4rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.project-title {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.project-description {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.project-tag {
  padding: 0.22rem 0.65rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.project-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.4rem 1.4rem;
  margin-top: auto;
}

/* ── 9. ABOUT ─────────────────────────────────────────────────── */
.about-section {
  background: var(--bg-surface);
  position: relative;
  overflow: hidden;
}
.about-section::before {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, hsla(265, 85%, 60%, 0.07) 0%, transparent 70%);
  pointer-events: none;
}

.about-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}

.about-text-col .section-label { display: block; margin-bottom: 0.75rem; }
.about-text-col .section-title { text-align: left; margin-bottom: 1.5rem; }

.about-bio {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 1rem;
  font-size: 0.98rem;
}
.about-bio strong { color: var(--text-primary); }

.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}
.tag {
  padding: 0.35rem 0.9rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: 100px;
  font-size: 0.83rem;
  color: var(--text-secondary);
  transition: border-color var(--duration), color var(--duration);
}
.tag:hover { border-color: var(--accent-primary); color: var(--accent-primary); }

/* Skills */
.skills-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.skills-grid { display: flex; flex-direction: column; gap: 2rem; }

.skill-category { }
.skill-cat-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.skill-bars { display: flex; flex-direction: column; gap: 0.9rem; }

.skill-bar-item { }
.skill-bar-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}
.skill-pct { color: var(--accent-primary); font-family: var(--font-mono); font-size: 0.8rem; }

.skill-bar-track {
  height: 6px;
  background: var(--bg-elevated);
  border-radius: 100px;
  overflow: hidden;
}
.skill-bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 100px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  transition: width 1.2s var(--ease-out);
  box-shadow: 0 0 8px hsla(207, 90%, 54%, 0.4);
}
.skills-animated .skill-bar-fill {
  width: var(--target-width);
}

/* Skill badges */
.skill-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.skill-badge {
  padding: 0.3rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  font-family: var(--font-mono);
}
.badge-hw   { background: hsla(25, 90%, 55%, 0.12); color: hsl(25, 90%, 60%); border: 1px solid hsla(25, 90%, 55%, 0.25); }
.badge-pcb  { background: hsla(145, 70%, 40%, 0.12); color: hsl(145, 70%, 48%); border: 1px solid hsla(145, 70%, 40%, 0.25); }
.badge-game { background: hsla(265, 85%, 60%, 0.12); color: hsl(265, 85%, 68%); border: 1px solid hsla(265, 85%, 60%, 0.25); }
.badge-soft { background: hsla(207, 90%, 54%, 0.12); color: hsl(207, 90%, 62%); border: 1px solid hsla(207, 90%, 54%, 0.25); }

/* Expertise cards */
.expertise-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}
.expertise-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: border-color var(--duration), transform var(--duration), box-shadow var(--duration);
  text-align: center;
}
.expertise-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.exp-icon { font-size: 1.5rem; }
.exp-label { font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); }

/* ── 10. CONTACT ──────────────────────────────────────────────── */
.contact-section { background: var(--bg-base); }

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 3.5rem;
  align-items: start;
  max-width: 960px;
  margin: 0 auto;
}

.contact-info-col { display: flex; flex-direction: column; gap: 1rem; }

.contact-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.3rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: border-color var(--duration), box-shadow var(--duration);
}
.contact-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
}
.contact-card-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-glow);
  border: 1px solid hsla(207, 90%, 54%, 0.2);
  border-radius: var(--radius-sm);
  color: var(--accent-primary);
  flex-shrink: 0;
}
.contact-card-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.15rem;
}
.contact-card-value {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: color var(--duration);
}
.contact-card-value:hover { color: var(--accent-primary); }

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}
.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  transition: border-color var(--duration), box-shadow var(--duration), background var(--duration);
  outline: none;
}
.form-input::placeholder { color: var(--text-muted); }
.form-input:focus {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px hsla(207, 90%, 54%, 0.15);
  background: var(--bg-elevated);
}
.form-textarea {
  resize: vertical;
  min-height: 130px;
}
.form-notice {
  font-size: 0.85rem;
  text-align: center;
  min-height: 1.2em;
  font-weight: 500;
}
.form-notice.success { color: hsl(145, 70%, 48%); }
.form-notice.error   { color: hsl(0, 80%, 62%); }

/* ── 11. FOOTER ───────────────────────────────────────────────── */
.footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 3rem 0 1.5rem;
}

.footer-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.footer-logo {
  font-family: var(--font-mono);
  font-size: 1.3rem;
  font-weight: 700;
  transition: opacity var(--duration);
}
.footer-logo:hover { opacity: 0.75; }

.footer-tagline {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.footer-socials {
  display: flex;
  gap: 0.75rem;
}
.social-link {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  color: var(--text-muted);
  transition: color var(--duration), border-color var(--duration), transform var(--duration), background var(--duration);
}
.social-link:hover {
  color: var(--accent-primary);
  border-color: var(--accent-primary);
  background: var(--accent-glow);
  transform: translateY(-3px);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.83rem;
  color: var(--text-muted);
}

/* ── 12. MODAL ────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: hsla(220, 16%, 5%, 0.75);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s var(--ease-out);
}
.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  max-width: 640px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  position: relative;
  transform: translateY(24px) scale(0.97);
  transition: transform 0.35s var(--ease-out);
  box-shadow: var(--shadow-lg);
}
.modal-overlay.open .modal-box { transform: translateY(0) scale(1); }

.modal-close {
  position: sticky;
  top: 1rem;
  left: 100%;
  float: right;
  margin: 1rem 1rem 0 0;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  font-size: 1.2rem;
  color: var(--text-secondary);
  display: flex; align-items: center; justify-content: center;
  transition: background var(--duration), color var(--duration);
  z-index: 10;
}
.modal-close:hover { background: var(--bg-surface); color: var(--text-primary); }

.modal-content { padding: 0 1.75rem 1.75rem; clear: both; }
.modal-content img {
  width: 100%;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  max-height: 280px;
  object-fit: cover;
}
.modal-content h3 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.75rem;
}
.modal-content p {
  color: var(--text-secondary);
  line-height: 1.75;
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}
.modal-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.25rem; }
.modal-links { display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* ── 13. Back to top ──────────────────────────────────────────── */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 900;
  width: 46px; height: 46px;
  background: var(--accent-primary);
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px hsla(207, 90%, 54%, 0.4);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity var(--duration), transform var(--duration);
}
.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}
.back-to-top:hover { background: var(--accent-secondary); }

/* ── 14. Keyframes ────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%       { transform: scale(1.5); opacity: 0.5; }
}
@keyframes scroll-line {
  0%   { transform: scaleY(0); transform-origin: top; opacity: 1; }
  50%  { transform: scaleY(1); transform-origin: top; opacity: 1; }
  51%  { transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

/* Intersection observer – reveal */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ── 15. Responsive ───────────────────────────────────────────── */
@media (max-width: 900px) {
  .about-layout { grid-template-columns: 1fr; gap: 3rem; }
  .contact-layout { grid-template-columns: 1fr; gap: 2.5rem; }
}

@media (max-width: 768px) {
  :root { --section-pad: 4.5rem 0; }

  .desktop-only { display: none; }

  .nav-toggle { display: flex; }

  .nav-menu {
    position: fixed;
    top: var(--nav-height);
    left: 0; right: 0;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.5rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    transform: translateY(-110%);
    transition: transform 0.35s var(--ease-out);
    box-shadow: var(--shadow-md);
  }
  .nav-menu.open { transform: translateY(0); }

  .nav-link { width: 100%; padding: 0.7rem 0.5rem; font-size: 1rem; }
  .theme-toggle { margin-left: 0; }

  .hero-title { font-size: 2.2rem; }
  .hero-subtitle { font-size: 0.97rem; }

  .projects-grid { grid-template-columns: 1fr; }

  .footer-bottom { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .hero-stats { gap: 1.2rem; }
  .stat-value  { font-size: 1.6rem; }
  .hero-cta-group { flex-direction: column; align-items: center; }
  .expertise-grid { grid-template-columns: 1fr 1fr; }
}
