/* ═══════════════════════════════════════════════════════
   TOKENS
═══════════════════════════════════════════════════════ */
:root {
  --primary:        #0B4F6C;
  --primary-hover:  #083d55;
  --primary-hi:     #d0e8f2;
  --accent:         #00C2CB;
  --accent2:        #4e9fc4;

  --text:           #111827;
  --muted:          #4b5a6e;
  --faint:          #8fa0b3;
  --border:         rgba(11,79,108,0.13);

  --glass:          rgba(255,255,255,0.62);
  --glass-border:   rgba(255,255,255,0.82);
  --blur:           18px;
  --shadow:         0 4px 28px rgba(11,79,108,0.09), 0 1px 4px rgba(11,79,108,0.06);
  --shadow-hover:   0 10px 48px rgba(11,79,108,0.15), 0 2px 8px rgba(11,79,108,0.08);

  --font-display:   'Cabinet Grotesk', 'Helvetica Neue', sans-serif;
  --font-body:      'Satoshi', 'Inter', sans-serif;

  --ease:           cubic-bezier(0.16, 1, 0.3, 1);
  --tr:             180ms cubic-bezier(0.16, 1, 0.3, 1);

  --r-sm:  0.375rem;
  --r-md:  0.625rem;
  --r-lg:  1rem;
  --r-xl:  1.5rem;
  --r-2xl: 2rem;

  /* Seamless gradient — every section sits on this fixed background */
  --grad: linear-gradient(
    175deg,
    #eef4fa 0%,
    #e6eff7 12%,
    #dde9f5 24%,
    #d4e3f2 36%,
    #cadcef 48%,
    #c0d6ec 60%,
    #b8d0ea 72%,
    #b2cce8 84%,
    #adc8e6 100%
  );
}

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

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

body {
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  color: var(--text);
  line-height: 1.65;
  overflow-x: hidden;
  /* Single fixed gradient — no per-section backgrounds */
  background: var(--grad);
  background-attachment: fixed;
}

img, picture, video, canvas, svg { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
h1,h2,h3,h4,h5,h6 { font-family: var(--font-display); text-wrap: balance; line-height: 1.12; }
p, li { text-wrap: pretty; }
button { cursor: pointer; background: none; border: none; }
a { color: inherit; text-decoration: none; }

::selection { background: color-mix(in srgb, var(--primary) 18%, transparent); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: var(--r-sm); }

a, button, [role="button"], input, textarea, select {
  transition: color var(--tr), background var(--tr),
              border-color var(--tr), box-shadow var(--tr), opacity var(--tr);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ═══════════════════════════════════════════════════════
   CANVAS BACKGROUND
═══════════════════════════════════════════════════════ */
#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════
   LAYOUT
═══════════════════════════════════════════════════════ */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
  position: relative;
  z-index: 1;
}

.section {
  padding-block: clamp(4rem, 8vw, 7rem);
  position: relative;
  z-index: 1;
}

.section-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.6rem;
  font-family: var(--font-body);
}

.section-title {
  font-size: clamp(1.9rem, 1.2rem + 2.5vw, 3.25rem);
  font-weight: 800;
  color: var(--text);
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
  letter-spacing: -0.02em;
}

/* ═══════════════════════════════════════════════════════
   GLASS CARD
═══════════════════════════════════════════════════════ */
.glass-card {
  background: var(--glass);
  backdrop-filter: blur(var(--blur)) saturate(1.5);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(1.5);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
  transition: box-shadow 320ms var(--ease), transform 320ms var(--ease);
}

/* ═══════════════════════════════════════════════════════
   BUTTONS
═══════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.65em 1.4em;
  border-radius: 9999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--tr), color var(--tr), border-color var(--tr),
              box-shadow var(--tr), transform var(--tr);
}
.btn-primary { background: var(--primary); color: white; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(11,79,108,0.22); }
.btn-primary:active { transform: translateY(0); }
.btn-ghost  { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-hi); }
.btn-sm  { font-size: 0.78rem; padding: 0.5em 1.1em; }
.btn-lg  { font-size: 1rem; padding: 0.75em 1.75em; }
.btn-full { width: 100%; justify-content: center; border-radius: var(--r-lg); }

/* ═══════════════════════════════════════════════════════
   PILLS / TAGS
═══════════════════════════════════════════════════════ */
.pill {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.28em 0.75em;
  border-radius: 9999px;
  background: rgba(255,255,255,0.6);
  border: 1px solid var(--border);
  color: var(--muted);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  white-space: nowrap;
  line-height: 1;
}
.pill-primary {
  background: var(--primary-hi);
  border-color: rgba(11,79,108,0.22);
  color: var(--primary);
}
.pill-row { display: flex; flex-wrap: wrap; gap: 0.4rem; }

/* ═══════════════════════════════════════════════════════
   SCROLL REVEAL CLASSES
   JS adds `js-ready` to <html> to opt into animations.
   Without JS, all content is visible by default.
   JS then adds `.visible` when element enters viewport.
═══════════════════════════════════════════════════════ */
/* Scroll reveal handled by AOS library — see js/script.js */
/* Project visual (SVG diagrams replacing placeholders) */
.proj-visual {
  width: 100%;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 1rem;
  border: 1px solid rgba(11,79,108,0.08);
}
/* ═══════════════════════════════════════════════════════
   NAV
═══════════════════════════════════════════════════════ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(238,244,250,0.82);
  backdrop-filter: blur(22px) saturate(1.6);
  -webkit-backdrop-filter: blur(22px) saturate(1.6);
  border-bottom: 1px solid rgba(11,79,108,0.08);
  transition: box-shadow 300ms var(--ease);
}
.nav.scrolled { box-shadow: 0 1px 12px rgba(11,79,108,0.08); }

.nav-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
  height: 64px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  flex-shrink: 0;
  transition: color var(--tr);
}
.nav-logo:hover { color: var(--primary); }
.nav-dot { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin-left: auto;
}
.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  transition: color var(--tr);
  white-space: nowrap;
}
.nav-links a:hover,
.nav-links a.active { color: var(--primary); font-weight: 600; }

.nav-actions { display: flex; align-items: center; gap: 0.5rem; margin-left: 1rem; }

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 38px; height: 38px;
  padding: 6px;
  border-radius: var(--r-md);
  cursor: pointer;
  transition: background var(--tr);
}
.hamburger:hover { background: var(--primary-hi); }
.hamburger span {
  display: block;
  height: 2px;
  background: var(--muted);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.2s;
}

.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s var(--ease);
  border-top: 1px solid transparent;
}
.mobile-menu.open {
  max-height: 420px;
  border-top-color: rgba(11,79,108,0.08);
}
.mobile-menu { display: flex; flex-direction: column; gap: 0; padding: 0 clamp(1.25rem, 5vw, 4rem); }
.mobile-menu.open { padding-block: 0.75rem; }
.mobile-link {
  display: block;
  padding: 0.75rem 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--muted);
  border-bottom: 1px solid rgba(11,79,108,0.06);
  transition: color var(--tr);
}
.mobile-link:hover { color: var(--primary); }
.mobile-menu .btn { margin-top: 0.75rem; width: fit-content; }

/* ═══════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════ */
.hero {
  position: relative;
  z-index: 1;
  min-height: 92vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 3rem;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 4rem);
  padding-block: clamp(3rem, 6vw, 5rem);
}

.hero-content { display: flex; flex-direction: column; gap: 1.1rem; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  background: var(--primary-hi);
  border: 1px solid rgba(11,79,108,0.2);
  padding: 0.4em 1em;
  border-radius: 9999px;
  width: fit-content;
}
.badge-dot {
  width: 6px; height: 6px;
  background: #0b6c28;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(34, 197, 143, 0.2);
  animation: badge-pulse 2s ease-in-out infinite;
}
@keyframes badge-pulse {
  0%,100% { box-shadow: 0 0 0 3px rgba(34, 37, 197, 0.2); }
  50%      { box-shadow: 0 0 0 6px rgba(45, 34, 197, 0.08); }
}

.hero-name {
  font-size: clamp(2.4rem, 1rem + 4.5vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.0;
  color: var(--text);
}
.hero-name-accent { color: var(--primary); }

.hero-title {
  font-size: clamp(1rem, 0.9rem + 0.5vw, 1.25rem);
  font-weight: 500;
  color: var(--muted);
  font-family: var(--font-body);
}

.hero-desc {
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.75;
  max-width: 50ch;
}
.hero-desc strong { color: var(--text); font-weight: 600; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.hero-pills { display: flex; flex-wrap: wrap; gap: 0.4rem; }

/* Hero diagram card */
.hero-diagram {
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-2xl);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  overflow: hidden;
}
.fiber-svg { width: 100%; height: auto; }

/* ── Animated terminal ───────────────────────── */
.hero-terminal {
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-2xl);
  box-shadow: var(--shadow);
  overflow: hidden;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.8rem;
  line-height: 1.7;
  display: flex;
  flex-direction: column;
}
.term-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1rem;
  background: rgba(240,244,248,0.9);
  border-bottom: 1px solid rgba(11,79,108,0.1);
  flex-shrink: 0;
}
.term-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.term-title {
  color: #5a7a8a;
  font-size: 0.72rem;
  margin-left: 0.5rem;
}
.term-body {
  padding: 1rem 1.2rem 1.2rem;
  flex: 1;
  overflow: hidden;
  min-height: 300px;
}
.term-line {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 0.1rem;
}
.term-prompt {
  color: #0B4F6C;
  font-weight: 700;
  margin-right: 0.4rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.term-cmd   { color: #1a2e3b; }
.term-out   { color: #4a6070; margin-left: 0; display: block; width: 100%; }
.term-ok    { color: #16803c; }
.term-warn  { color: #b45309; }
.term-key   { color: #0B4F6C; }
.term-val   { color: #0e7490; }
.term-cursor {
  display: inline-block;
  width: 4px;
  height: 1.2rem;
  background: #0B4F6C;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
  margin-left: 1px;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

/* Fiber path draw animation */
.draw-path {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  animation: draw 2s var(--ease) forwards;
}
.draw-path:nth-child(4) { animation-delay: 0.2s; }
.draw-path:nth-child(5) { animation-delay: 0.4s; }
.draw-path:nth-child(6) { animation-delay: 0.6s; }
.draw-path:nth-child(7) { animation-delay: 0.7s; }
.draw-path:nth-child(8) { animation-delay: 0.8s; }
.draw-path:nth-child(9) { animation-delay: 0.9s; }
.draw-path:nth-child(10) { animation-delay: 1.0s; }
.draw-path:nth-child(11) { animation-delay: 1.1s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.ont { opacity: 0; animation: fade-in 0.4s var(--ease) forwards; }
.ont:nth-child(1) { animation-delay: 1.6s; }
.ont:nth-child(2) { animation-delay: 1.8s; }
.ont:nth-child(3) { animation-delay: 2.0s; }
.ont:nth-child(4) { animation-delay: 2.2s; }
.ont:nth-child(5) { animation-delay: 2.4s; }
@keyframes fade-in { to { opacity: 1; } }

/* ═══════════════════════════════════════════════════════
   ABOUT
═══════════════════════════════════════════════════════ */
.about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.about-photo-col { display: flex; flex-direction: column; gap: 1rem; }

.about-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 20px;
}

.photo-placeholder {
  aspect-ratio: 3/4;
  background: rgba(255,255,255,0.45);
  border: 2px dashed rgba(11,79,108,0.18);
  border-radius: var(--r-xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 1.5rem;
  text-align: center;
}
.photo-placeholder p { font-size: 0.8rem; color: var(--faint); }

.stat-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 0.6rem; }
.stat-card { padding: 0.75rem 0.5rem; text-align: center; display: flex; flex-direction: column; gap: 0.2rem; }
.stat-num { font-family: var(--font-display); font-size: 1.5rem; font-weight: 800; color: var(--primary); line-height: 1; }
.stat-lbl { font-size: 0.68rem; color: var(--muted); line-height: 1.3; }

.about-text { display: flex; flex-direction: column; gap: 1.25rem; }
.about-text p { font-size: 0.95rem; color: var(--muted); line-height: 1.8; }
.about-text strong { color: var(--text); font-weight: 600; }

.skills-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; padding-top: 0.5rem; }
.skill-group { display: flex; flex-direction: column; gap: 0.5rem; }
.skill-heading { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase; color: var(--faint); font-family: var(--font-body); }

/* ═══════════════════════════════════════════════════════
   EXPERIENCE
═══════════════════════════════════════════════════════ */
.timeline { margin-bottom: 2.5rem; }
.tl-item { display: grid; grid-template-columns: 28px 1fr; gap: 1rem; }
.tl-marker { display: flex; flex-direction: column; align-items: center; padding-top: 1.1rem; }
.tl-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--border); background: white; flex-shrink: 0; }
.tl-dot.active { background: var(--primary); border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-hi); }
.tl-line { flex: 1; width: 2px; background: linear-gradient(to bottom, var(--primary), transparent); margin-top: 0.4rem; min-height: 30px; }
.tl-card { padding: 1.5rem; }
.tl-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; margin-bottom: 0.75rem; }
.tl-role { font-size: 1.1rem; font-weight: 700; color: var(--text); }
.tl-company { font-size: 0.85rem; color: var(--muted); margin-top: 0.2rem; }
.tl-period { font-size: 0.72rem; font-weight: 700; color: var(--primary); background: var(--primary-hi); padding: 0.3em 0.8em; border-radius: 9999px; white-space: nowrap; flex-shrink: 0; }
.tl-desc { font-size: 0.9rem; color: var(--muted); line-height: 1.75; }

.work-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 1.25rem; }
.work-card { padding: 1.5rem; display: flex; flex-direction: column; gap: 0.9rem; }
.work-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.work-icon { width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; background: var(--primary-hi); border-radius: var(--r-lg); color: var(--primary); }
.work-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.work-photo-placeholder {
  aspect-ratio: 16/9;
  background: rgba(11,79,108,0.05);
  border: 2px dashed rgba(11,79,108,0.12);
  border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
}
.work-photo {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 1rem;
}
.work-photo-placeholder span { font-size: 0.72rem; color: var(--faint); }
.work-list { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; flex: 1; }
.work-list li { font-size: 0.85rem; color: var(--muted); padding-left: 1rem; position: relative; line-height: 1.6; }
.work-list li::before { content: ''; position: absolute; left: 0; top: 0.55em; width: 5px; height: 5px; background: var(--accent); border-radius: 50%; }


/* Experience — CV Download CTA */

.experience-cv {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.75rem 2rem;
  margin-top: 2rem;
}

.experience-cv-content {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-width: 0;
}

.experience-cv-icon {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 194, 203, 0.08);
  border: 1px solid rgba(0, 194, 203, 0.18);
  border-radius: 14px;
  color: #0B4F6C;
}

.experience-cv-text h3 {
  font-family: 'Cabinet Grotesk', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 0.4rem;
}

.experience-cv-text p {
  font-family: 'Satoshi', sans-serif;
  font-size: 0.9rem;
  line-height: 1.65;
  opacity: 0.7;
  max-width: 520px;
  margin: 0;
}

.experience-cv-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  white-space: nowrap;
  flex-shrink: 0;
}

/* Responsive */

@media (max-width: 768px) {
  .experience-cv {
    flex-direction: column;
    align-items: stretch;
    gap: 1.5rem;
    padding: 1.5rem;
  }

  .experience-cv-content {
    align-items: flex-start;
  }

  .experience-cv-btn {
    width: 100%;
  }
}


/* ═══════════════════════════════════════════════════════
   PROJECTS
═══════════════════════════════════════════════════════ */
.projects-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 1.25rem; }
.project-card { padding: 1.5rem; display: flex; flex-direction: column; gap: 0.9rem; }
.project-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.proj-top { display: flex; justify-content: space-between; align-items: flex-start; }
.proj-icon { width: 42px; height: 42px; display: flex; align-items: center; justify-content: center; background: rgba(11,79,108,0.07); border-radius: var(--r-md); color: var(--primary); }
.status-badge { font-size: 0.68rem; font-weight: 700; padding: 0.28em 0.75em; border-radius: 9999px; }
.status-badge.active { background: rgba(22,163,74,0.1); color: #16a34a; border: 1px solid rgba(22,163,74,0.25); }
.status-badge.wip    { background: rgba(217,119,6,0.1);  color: #d97706; border: 1px solid rgba(217,119,6,0.25); }
.proj-placeholder {
  aspect-ratio: 16/8;
  background: rgba(11,79,108,0.05);
  border: 2px dashed rgba(11,79,108,0.12);
  border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
}
.proj-placeholder span { font-size: 0.72rem; color: var(--faint); }
.proj-title { font-size: 1rem; font-weight: 700; color: var(--text); }
.proj-desc { font-size: 0.85rem; color: var(--muted); line-height: 1.7; flex: 1; }

/* ═══════════════════════════════════════════════════════
   EDUCATION
═══════════════════════════════════════════════════════ */

.certs-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
  width: 100%;
}

.cert-card { padding: 1.25rem; display: flex; gap: 1rem; align-items: flex-start; }
.cert-featured {
  grid-column: 1 / -1;
  background: linear-gradient(
    135deg,
    rgba(255,255,255,0.72),
    rgba(240,248,255,0.65)
  );
  border-color: rgba(4,159,217,0.2);
}
.cert-logo-wrap { flex-shrink: 0; }
.cert-info { flex: 1; min-width: 0; }
.cert-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem; margin-bottom: 0.35rem; }
.cert-name { font-size: 0.95rem; font-weight: 700; color: var(--text); line-height: 1.2; }
.cert-issuer { font-size: 0.72rem; color: var(--faint); margin-bottom: 0.6rem; }
.cert-detail { font-size: 0.8rem; color: var(--muted); line-height: 1.7; margin-bottom: 0.75rem; }

.cert-badge { font-size: 0.65rem; font-weight: 700; padding: 0.28em 0.75em; border-radius: 9999px; white-space: nowrap; flex-shrink: 0; }
.cert-badge.upcoming  { background: rgba(4,159,217,0.12); color: #0489bf; border: 1px solid rgba(4,159,217,0.25); }
.cert-badge.completing { background: rgba(22,163,74,0.1); color: #16a34a; border: 1px solid rgba(22,163,74,0.25); }
.cert-badge.planned   { background: rgba(11,79,108,0.08); color: var(--primary); border: 1px solid var(--border); }

.prog-bar { height: 5px; background: rgba(11,79,108,0.1); border-radius: 9999px; overflow: hidden; margin-bottom: 0.35rem; }
.prog-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 9999px;
  transition: width 1.2s var(--ease);
}
.prog-label { font-size: 0.68rem; color: var(--faint); }

.cert-cv {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  background: linear-gradient(135deg, var(--primary-hi), rgba(255,255,255,0.7));
  border-color: rgba(11,79,108,0.18);
}


.education-period {
  display: block;
  margin-top: 1rem;
}


/* ═══════════════════════════════════════════════════════
   CONTACT
═══════════════════════════════════════════════════════ */
.contact-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  padding: clamp(2rem, 5vw, 3.5rem);
}
.contact-title { font-size: clamp(1.6rem, 1rem + 2vw, 2.5rem); font-weight: 800; color: var(--text); margin-block: 0.75rem; }
.contact-sub { font-size: 0.9rem; color: var(--muted); line-height: 1.75; margin-bottom: 1.5rem; }
.contact-links { display: flex; flex-direction: column; gap: 0.75rem; }
.contact-link, .contact-loc {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  transition: color var(--tr);
}
.contact-link:hover { color: var(--primary); }
.contact-loc { color: var(--faint); }

.contact-form { display: flex; flex-direction: column; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-label { font-size: 0.8rem; font-weight: 600; color: var(--muted); }
.form-input {
  width: 100%;
  padding: 0.65em 0.9em;
  background: rgba(255,255,255,0.7);
  border: 1.5px solid rgba(11,79,108,0.14);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  color: var(--text);
  backdrop-filter: blur(6px);
  transition: border-color var(--tr), box-shadow var(--tr);
  appearance: none;
}
.form-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-hi); }
.form-input::placeholder { color: var(--faint); }
.form-textarea { resize: vertical; min-height: 110px; }
.form-note { font-size: 0.7rem; color: var(--faint); text-align: center; line-height: 1.5; }


/* Contact — Privacy Notice */

.privacy-note {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-top: 0.15rem;

  font-family: var(--font-body);
  font-size: 0.7rem;
  line-height: 1.65;
  color: var(--faint);
}

.privacy-note svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: var(--primary);
  opacity: 0.65;
}

.privacy-note a {
  color: var(--primary);
  font-weight: 500;
  text-decoration: none;
}

.privacy-note a:hover {
  text-decoration: underline;
}


/* ═══════════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════════ */
.footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid rgba(11,79,108,0.1);
  padding-block: 2rem;
  background: rgba(238,244,250,0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 0.6rem; text-align: center; }
.footer-logo { display: flex; align-items: center; gap: 0.5rem; font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; color: var(--text); }
.footer-copy { font-size: 0.8rem; color: var(--muted); }
.footer-copy a { color: var(--primary); }
.footer-copy a:hover { text-decoration: underline; }
.footer-attr { font-size: 0.68rem; color: var(--faint); }
.footer-attr a { color: var(--faint); transition: color var(--tr); }
.footer-attr a:hover { color: var(--primary); }

/* ═══════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-diagram { display: none; }
  .hero-terminal { display: none; }
  .hero-content { max-width: 600px; }
  .about-grid { grid-template-columns: 1fr; }
  .about-photo-col { flex-direction: row; align-items: flex-start; }
  .photo-placeholder { width: 180px; aspect-ratio: 1; flex-shrink: 0; }
  .stat-row { flex: 1; }
  .work-grid { grid-template-columns: 1fr 1fr; }
  .contact-card { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .skills-grid { grid-template-columns: 1fr; }
  .work-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .tl-item { grid-template-columns: 1fr; }
  .tl-marker { display: none; }
  .tl-head { flex-direction: column; gap: 0.4rem; }
  .about-photo-col { flex-direction: column; }
  .photo-placeholder { width: 100%; aspect-ratio: 3/2; }
}

@media (max-width: 480px) {
  .hero-cta { flex-direction: column; }
  .hero-cta .btn { justify-content: center; }
  .nav-actions .btn { display: none; }
  .contact-card { padding: 1.5rem; }
}

/* Contact form response messages */
.form-note:empty { display: none; }
.form-note.form-feedback--success,
.form-note.form-feedback--error {
  display: block;
  padding: 0.65rem 0.85rem;
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  text-align: left;
}
.form-note.form-feedback--success {
  color: #166534;
  background: rgba(22,163,74,0.08);
  border: 1px solid rgba(22,163,74,0.2);
}
.form-note.form-feedback--error {
  color: #b91c1c;
  background: rgba(220,38,38,0.07);
  border: 1px solid rgba(220,38,38,0.18);
}
