/* ─── RESET & TOKENS ─── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --bg:       #080a0f;
  --bg1:      #0d1017;
  --bg2:      #111520;
  --surface:  #161b28;
  --border:   rgba(255,255,255,0.07);
  --border2:  rgba(255,255,255,0.13);
  --text:     #e8eaf0;
  --muted:    #a1a8b4;
  --accent:   #00ffe0;
  --accent2:  #ff3c6e;
  --accent3:  #7b5ea7;
  --yellow:   #f5c842;
  --font-head: 'Syne', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-body: 'Fraunces', serif;
}
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* cursor elements hidden */
#cursor, #cursor-ring { display: none; }

/* ─── NOISE OVERLAY ─── */
body::before {
  content: '';
  position: fixed; inset: 0;
  z-index: 0; /* was 1 — kept below everything */
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  opacity: 0.025;
  pointer-events: none;
}

/* ─── NAV ─── */
nav#site-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 clamp(24px, 5vw, 80px);
  height: 64px;
  background: rgba(8,10,15,0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: border-color 0.3s ease;
}
.nav-logo {
  font-family: var(--font-head); font-weight: 800; font-size: 1.1rem;
  letter-spacing: -0.02em; color: #fff; text-decoration: none;
}
.nav-logo span { color: var(--accent); }
.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a {
  font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--muted); text-decoration: none;
  transition: color 0.2s; position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 1px; background: var(--accent); transition: width 0.3s ease;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }
.nav-cta {
  font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--bg); background: var(--accent);
  padding: 8px 20px; border: none; cursor: pointer;
  clip-path: polygon(8px 0%, 100% 0%, calc(100% - 8px) 100%, 0% 100%);
  transition: all 0.2s; text-decoration: none; display: inline-block;
}
.nav-cta:hover { background: #fff; transform: scale(1.03); color: var(--bg); }

/* ─── HAMBURGER ─── */
.nav-hamburger {
  display: none; flex-direction: column; justify-content: center;
  gap: 5px; width: 44px; height: 44px; /* larger tap target */
  background: none; border: 1px solid var(--border2);
  padding: 10px; cursor: pointer; z-index: 200;
  -webkit-tap-highlight-color: transparent;
}
.nav-hamburger span {
  display: block; width: 100%; height: 1px;
  background: var(--accent); transition: all 0.3s ease; transform-origin: center;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ─── MOBILE DRAWER ─── */
.mobile-menu {
  display: none; /* hidden by default — JS adds .open to show */
  position: fixed; top: 64px; left: 0; right: 0; bottom: 0;
  background: rgba(8,10,15,0.98);
  z-index: 99;
  flex-direction: column; justify-content: center; align-items: center;
  gap: 8px; padding: 40px 32px;
  border-top: 1px solid var(--border);
}
.mobile-menu.open {
  display: flex; /* only shown when open class is added by JS */
}
.mobile-menu a {
  font-family: var(--font-head); font-size: 2.2rem; font-weight: 800;
  letter-spacing: -0.03em; color: var(--muted); text-decoration: none;
  transition: color 0.2s; padding: 12px 0; width: 100%; text-align: center;
  border-bottom: 1px solid var(--border);
  display: block; /* ensures full-width tap area */
  -webkit-tap-highlight-color: transparent;
}
.mobile-menu a:last-of-type { border-bottom: none; }
.mobile-menu a:hover, .mobile-menu a:active { color: var(--accent); }
.mobile-menu .mobile-cta {
  margin-top: 24px; font-family: var(--font-mono); font-size: 0.8rem;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--bg);
  background: var(--accent); padding: 14px 40px;
  border: none; width: auto; font-weight: 400;
  clip-path: none; /* no clip-path on mobile */
}

/* ─── SECTION BASE ─── */
section { position: relative; z-index: 1; }
.section-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 120px clamp(24px, 5vw, 80px);
}
.section-label {
  font-family: var(--font-mono); font-size: 0.68rem;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px;
}
.section-label::before { content: '[ '; }
.section-label::after  { content: ' ]'; }
.section-title {
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(2rem, 4vw, 3.5rem); letter-spacing: -0.03em;
  color: #fff; line-height: 1.05; margin-bottom: 60px;
}
.section-title em { font-family: var(--font-body); font-style: italic; font-weight: 300; color: var(--muted); }

/* ─── BUTTONS ─── */
.btn-primary {
  font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--bg); background: var(--accent);
  padding: 14px 32px; text-decoration: none;
  clip-path: polygon(10px 0%, 100% 0%, calc(100% - 10px) 100%, 0% 100%);
  transition: all 0.25s; display: inline-block;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary:hover { background: #fff; transform: translateY(-2px); color: var(--bg); }
.btn-ghost {
  font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--accent);
  border: 1px solid rgba(0,255,224,0.3); padding: 14px 32px;
  text-decoration: none; transition: all 0.25s; display: inline-block;
  -webkit-tap-highlight-color: transparent;
}
.btn-ghost:hover { border-color: var(--accent); background: rgba(0,255,224,0.05); color: var(--accent); }

/* ─── HERO ─── */
#hero {
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 64px clamp(24px, 5vw, 80px) 80px;
  min-height: 100vh;
  position: relative; overflow: hidden;
}
.hero-grid-bg {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(0,255,224,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,224,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: gridPan 20s linear infinite;
}
@keyframes gridPan { to { background-position: 60px 60px; } }
.hero-radial {
  position: absolute; top: -20%; left: -10%; width: 70vw; height: 70vw;
  background: radial-gradient(circle, rgba(0,255,224,0.06) 0%, transparent 65%);
  pointer-events: none;
}
.hero-radial2 {
  position: absolute; bottom: -10%; right: -5%; width: 50vw; height: 50vw;
  background: radial-gradient(circle, rgba(255,60,110,0.05) 0%, transparent 65%);
  pointer-events: none;
}
.hero-eyebrow {
  font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--accent); margin-bottom: 24px;
  opacity: 0; animation: fadeUp 0.8s 0.2s forwards; position: relative; z-index: 2;
}
.hero-eyebrow::before { content: '// '; opacity: 0.5; }
.hero-title {
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(2rem, 3.5vw, 4rem); line-height: 0.95;
  letter-spacing: -0.04em; color: #fff; max-width: 900px;
  opacity: 0; animation: fadeUp 0.8s 0.4s forwards; position: relative; z-index: 2;
}
.hero-title .line2 {
  display: block;
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.hero-title .line3 {
  display: block; font-family: var(--font-body); font-style: italic; font-weight: 300;
  font-size: 0.55em; color: var(--muted); -webkit-text-fill-color: var(--muted);
  margin-top: 16px; letter-spacing: -0.01em;
}
.hero-desc {
  font-family: var(--font-mono); font-size: 0.88rem; color: var(--muted);
  max-width: 520px; margin-top: 36px; line-height: 1.8;
  opacity: 0; animation: fadeUp 0.8s 0.6s forwards; position: relative; z-index: 2;
}
.hero-actions {
  display: flex; gap: 16px; align-items: center; margin-top: 48px;
  opacity: 0; animation: fadeUp 0.8s 0.8s forwards; position: relative; z-index: 2;
}
.hero-scroll {
  position: absolute; bottom: 32px; right: clamp(24px, 5vw, 80px);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  opacity: 0; animation: fadeIn 1s 1.5s forwards; pointer-events: none;
}
.hero-scroll span {
  font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--muted); writing-mode: vertical-rl;
}
.scroll-line {
  width: 1px; height: 60px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse { 0%,100%{opacity:0.3} 50%{opacity:1} }

/* ─── BLOG ─── */
#blog, #latest-post { background: var(--bg1); }
.blog-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 2px; }
.blog-featured {
  background: var(--surface); padding: 48px; border: 1px solid var(--border);
  position: relative; overflow: hidden; transition: border-color 0.3s; grid-row: span 2;
}
.blog-featured::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent3)); pointer-events: none;
}
.blog-featured:hover { border-color: rgba(0,255,224,0.3); }
.blog-card {
  background: var(--surface); padding: 32px; border: 1px solid var(--border);
  transition: all 0.3s; position: relative; overflow: hidden;
}
.blog-card:hover { border-color: rgba(0,255,224,0.25); background: var(--bg2); }
.post-tag {
  display: inline-block; font-size: 0.65rem; letter-spacing: 0.15em;
  text-transform: uppercase; padding: 4px 10px; margin-bottom: 16px;
}
.tag-red    { background: rgba(255,60,110,0.15);  color: var(--accent2); border: 1px solid rgba(255,60,110,0.3); }
.tag-teal   { background: rgba(0,255,224,0.1);    color: var(--accent);  border: 1px solid rgba(0,255,224,0.25); }
.tag-purple { background: rgba(123,94,167,0.15);  color: #a47fd6;        border: 1px solid rgba(123,94,167,0.3); }
.tag-yellow { background: rgba(245,200,66,0.1);   color: var(--yellow);  border: 1px solid rgba(245,200,66,0.3); }
.post-title {
  font-family: var(--font-head); font-weight: 700; color: #fff; line-height: 1.2;
  text-decoration: none; display: block; transition: color 0.2s;
  position: relative; z-index: 2; /* ensure above any overlapping elements */
}
.post-title:hover, .post-title:active { color: var(--accent); }
.blog-featured .post-title { font-size: 1.8rem; margin-bottom: 16px; letter-spacing: -0.02em; }
.blog-card    .post-title { font-size: 1.05rem; margin-bottom: 10px; }
.post-excerpt { font-family: var(--font-mono); font-size: 0.82rem; color: var(--muted); line-height: 1.7; margin-bottom: 24px; }
.post-meta { display: flex; align-items: center; gap: 16px; font-size: 0.68rem; letter-spacing: 0.08em; color: var(--muted); }
.post-meta .dot { color: var(--border2); }
.read-more {
  display: inline-flex; align-items: center; gap: 8px; font-size: 0.72rem;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent);
  text-decoration: none; margin-top: 24px; transition: gap 0.2s;
  position: relative; z-index: 2;
  padding: 8px 0; /* larger tap target */
}
.read-more:hover { gap: 14px; color: var(--accent); }
.read-more::after { content: '→'; }

/* ─── PROJECTS ─── */
#projects { background: var(--bg); }
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); }
.project-card {
  background: var(--bg); padding: 40px 32px; transition: background 0.3s;
  position: relative; overflow: hidden;
}
.project-card::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 1px;
  background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform 0.4s ease;
  pointer-events: none;
}
.project-card:hover { background: var(--surface); }
.project-card:hover::after { transform: scaleX(1); }
.project-num { font-family: var(--font-head); font-size: 4rem; font-weight: 800; color: var(--border2); line-height: 1; margin-bottom: 24px; transition: color 0.3s; }
.project-card:hover .project-num { color: rgba(0,255,224,0.15); }
.project-name { font-family: var(--font-head); font-weight: 700; font-size: 1.15rem; color: #fff; margin-bottom: 10px; letter-spacing: -0.01em; }
.project-desc { font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); line-height: 1.7; margin-bottom: 24px; }
.project-stack { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.stack-tag { font-size: 0.63rem; letter-spacing: 0.1em; text-transform: uppercase; padding: 3px 8px; border: 1px solid var(--border2); color: var(--muted); }
.project-link {
  font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); text-decoration: none; transition: gap 0.2s;
  display: inline-flex; align-items: center; gap: 6px;
  position: relative; z-index: 2; padding: 8px 0;
}
.project-link:hover { gap: 12px; color: var(--accent); }
.project-link::after { content: '↗'; }

/* ─── CV ─── */
#cv { background: var(--bg1); }
.cv-layout { display: grid; grid-template-columns: 1fr 2fr; gap: 80px; }
.cv-avatar {
  width: 120px; height: 120px; border-radius: 50%;
  border: 2px solid rgba(0,255,224,0.3); background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-weight: 800; font-size: 2.5rem;
  color: var(--accent); margin-bottom: 24px; position: relative;
}
.cv-avatar::after { content: ''; position: absolute; inset: -8px; border-radius: 50%; border: 1px solid rgba(0,255,224,0.1); }
.cv-name { font-family: var(--font-head); font-weight: 800; font-size: 1.3rem; color: #fff; letter-spacing: -0.02em; margin-bottom: 4px; }
.cv-role { font-family: var(--font-mono); font-size: 0.75rem; color: var(--accent); letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 24px; }
.cv-contact-list { list-style: none; }
.cv-contact-list li { font-size: 0.78rem; color: var(--muted); padding: 8px 0; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px; }
.cv-contact-list li:last-child { border-bottom: none; }
.cv-contact-list .icon { color: var(--accent); font-style: normal; }
.cv-skills-title { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--muted); margin: 32px 0 16px; }
.skill-bar { margin-bottom: 12px; }
.skill-bar-label { display: flex; justify-content: space-between; font-size: 0.72rem; color: var(--text); margin-bottom: 6px; }
.skill-bar-track { height: 2px; background: var(--border2); position: relative; }
.skill-bar-fill { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent3)); position: relative; }
.skill-bar-fill::after { content: ''; position: absolute; right: 0; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.cv-section { margin-bottom: 56px; }
.cv-section-title { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent); margin-bottom: 24px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.cv-item { margin-bottom: 32px; position: relative; padding-left: 24px; }
.cv-item::before { content: ''; position: absolute; left: 0; top: 8px; width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--accent); background: var(--bg1); }
.cv-item::after { content: ''; position: absolute; left: 3px; top: 20px; width: 1px; height: calc(100% - 12px); background: var(--border); }
.cv-item:last-child::after { display: none; }
.cv-item-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 4px; }
.cv-item-title { font-family: var(--font-head); font-weight: 700; font-size: 1rem; color: #fff; }
.cv-item-date { font-family: var(--font-mono); font-size: 0.68rem; color: var(--accent); white-space: nowrap; padding: 2px 8px; border: 1px solid rgba(0,255,224,0.2); }
.cv-item-org { font-family: var(--font-mono); font-size: 0.78rem; color: #9ca3af; margin-bottom: 10px; }
.cv-item-desc { font-family: var(--font-mono); font-size: 0.8rem; color: #9ca3af; line-height: 1.7; }
.cv-item-desc li { margin-bottom: 4px; padding-left: 12px; position: relative; list-style: none; }
.cv-item-desc li::before { content: '—'; position: absolute; left: 0; color: rgba(255,255,255,0.2); }
.cert-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.cert-card { background: var(--surface); border: 1px solid var(--border); padding: 16px; transition: border-color 0.3s; }
.cert-card:hover { border-color: rgba(0,255,224,0.3); }
.cert-name { font-family: var(--font-head); font-weight: 700; font-size: 0.88rem; color: #fff; margin-bottom: 4px; }
.cert-issuer { font-size: 0.7rem; color: var(--muted); }
.cv-download-row { display: flex; justify-content: flex-end; margin-bottom: 48px; }

/* ─── ABOUT ─── */
#about { background: var(--bg); }
.about-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.about-text { font-family: var(--font-body); font-size: 1.15rem; line-height: 1.9; color: #c8ccd6; margin-bottom: 20px; font-weight: 300; }
.about-text strong { font-weight: 600; color: #fff; }
.about-text em { color: var(--accent); font-style: italic; }
.about-terminal { background: #0a0c10; border: 1px solid var(--border); font-family: var(--font-mono); font-size: 0.8rem; }
.terminal-bar { background: var(--surface); padding: 10px 16px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--border); }
.t-dot { width: 10px; height: 10px; border-radius: 50%; }
.t-dot.r { background: #ff5f56; } .t-dot.y { background: #ffbd2e; } .t-dot.g { background: #27c93f; }
.terminal-title { font-size: 0.68rem; color: var(--muted); margin-left: 8px; letter-spacing: 0.08em; }
.terminal-body { padding: 24px; line-height: 2; }
.t-line { display: flex; gap: 8px; }
.t-prompt { color: var(--accent); }
.t-cmd { color: #fff; }
.t-output { color: var(--muted); }
.t-output.highlight { color: var(--accent); }
.t-output.red   { color: var(--accent2); }
.t-output.yellow{ color: var(--yellow); }
.t-cursor { display: inline-block; width: 8px; height: 14px; background: var(--accent); vertical-align: middle; animation: blink 1s step-end infinite; }
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

/* ─── CONTACT ─── */
#contact { background: var(--bg1); }
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; }
.contact-headline { font-family: var(--font-head); font-weight: 800; font-size: clamp(2.5rem, 5vw, 4.5rem); letter-spacing: -0.04em; line-height: 1; color: #fff; margin-bottom: 24px; }
.contact-headline .line2 { color: var(--accent); display: block; }
.contact-subtext { font-family: var(--font-mono); font-size: 0.85rem; color: var(--muted); line-height: 1.8; margin-bottom: 40px; }
.contact-links { display: flex; flex-direction: column; gap: 12px; }
.contact-link { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border: 1px solid var(--border); text-decoration: none; color: var(--text); transition: all 0.25s; }
.contact-link:hover, .contact-link:active { border-color: rgba(0,255,224,0.4); background: rgba(0,255,224,0.04); color: var(--text); }
.contact-link-icon { font-size: 1.1rem; width: 24px; text-align: center; }
.contact-link-text { font-family: var(--font-mono); font-size: 0.82rem; }
.contact-link-arrow { margin-left: auto; color: var(--muted); }
.contact-form { display: flex; flex-direction: column; gap: 16px; position: relative; z-index: 2; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-label { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--muted); }
.form-input, .form-textarea {
  background: var(--surface); border: 1px solid var(--border); color: var(--text);
  font-family: var(--font-mono); font-size: 0.85rem; padding: 12px 16px;
  outline: none; transition: border-color 0.2s; resize: none;
  -webkit-appearance: none; /* prevents iOS styling overrides */
  border-radius: 0;
  position: relative; z-index: 2;
}
.form-input:focus, .form-textarea:focus { border-color: rgba(0,255,224,0.4); }
.form-textarea { min-height: 120px; }
.form-submit {
  font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--bg); background: var(--accent); border: none; padding: 14px 32px; cursor: pointer;
  clip-path: polygon(10px 0%, 100% 0%, calc(100% - 10px) 100%, 0% 100%);
  align-self: flex-start; transition: all 0.2s; position: relative; z-index: 2;
}
.form-submit:hover { background: #fff; }

/* ─── SINGLE POST ─── */
.single-post-hero { padding: 140px clamp(24px, 5vw, 80px) 60px; max-width: 900px; margin: 0 auto; }
.single-post-content { max-width: 780px; margin: 0 auto; padding: 0 clamp(24px, 5vw, 80px) 120px; font-family: var(--font-body); font-size: 1.05rem; line-height: 1.9; color: #c8ccd6; }
.single-post-content h2, .single-post-content h3 { font-family: var(--font-head); color: #fff; margin: 48px 0 16px; letter-spacing: -0.02em; }
.single-post-content h2 { font-size: 1.8rem; }
.single-post-content h3 { font-size: 1.3rem; }
.single-post-content p { margin-bottom: 24px; }
.single-post-content a { color: var(--accent); }
.single-post-content pre, .single-post-content code { font-family: var(--font-mono); background: var(--surface); border: 1px solid var(--border); padding: 2px 6px; font-size: 0.85rem; color: var(--accent); }
.single-post-content pre { padding: 24px; display: block; overflow-x: auto; margin: 24px 0; }
.single-post-content ul, .single-post-content ol { padding-left: 24px; margin-bottom: 24px; }
.single-post-content li { margin-bottom: 8px; }

/* ─── FOOTER ─── */
footer#site-footer {
  background: var(--bg); border-top: 1px solid var(--border);
  padding: 40px clamp(24px, 5vw, 80px);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px;
  position: relative; z-index: 2;
}
.footer-logo { font-family: var(--font-head); font-weight: 800; color: #fff; text-decoration: none; font-size: 1rem; }
.footer-logo span { color: var(--accent); }
.footer-copy { font-size: 0.72rem; color: var(--muted); letter-spacing: 0.05em; }
.footer-links { display: flex; gap: 24px; }
.footer-links a { font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.footer-links a:hover { color: var(--accent); }

/* ─── WP ADMIN BAR OFFSET ─── */
.admin-bar nav#site-nav { top: 32px; }
@media screen and (max-width: 782px) { .admin-bar nav#site-nav { top: 46px; } }

/* ─── ANIMATIONS ─── */
@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ─── REVEAL ─── */
/* Disabled on mobile — opacity:0 blocks taps if IntersectionObserver doesn't fire */
.reveal { opacity: 0; transform: translateY(32px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* ─── TABLET ─── */
@media (max-width: 1024px) {
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-stats { gap: 32px; }
  .cv-layout { gap: 48px; }
}

/* ─── MOBILE ─── */
@media (max-width: 768px) {
  #cursor, #cursor-ring { display: none; }
  .nav-links { display: none; }
  .nav-cta   { display: none; }
  .nav-hamburger { display: flex; }
  /* mobile-menu stays display:none until .open is added — do NOT set display:flex here */

  /* CRITICAL: disable reveal animations on mobile entirely
     opacity:0 + transform makes elements untappable if observer doesn't fire */
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }

  .section-inner { padding: 90px 20px 60px; }

  /* Hero — fit content, no excess height that intercepts taps */
  #hero {
    min-height: unset !important;
    height: auto !important;
    justify-content: flex-start;
    padding: 74px 20px 50px; /* 74px = just enough to clear the fixed 64px nav */
    overflow: visible;
  }
  .hero-grid-bg, .hero-radial, .hero-radial2 {
    display: none; /* remove decorative overlays on mobile — they add invisible tap area */
  }
  .hero-title { font-size: clamp(1.8rem, 8vw, 2.8rem); }
  .hero-desc { font-size: 0.82rem; margin-top: 24px; }
  .hero-actions { flex-direction: column; gap: 12px; margin-top: 32px; }

  /* Remove clip-path on mobile — misaligns tap targets */
  .btn-primary, .btn-ghost, .form-submit, .nav-cta, .mobile-cta {
    clip-path: none !important;
  }
  .btn-primary, .btn-ghost {
    width: 100%; text-align: center; padding: 18px 16px; display: block;
    box-sizing: border-box;
  }
  .form-submit { align-self: stretch; width: 100%; text-align: center; padding: 18px; }

  /* Stats */
  .hero-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 48px; padding-top: 32px; }
  .stat-num { font-size: 1.8rem; }
  .hero-scroll { display: none; }

  /* Blog */
  .blog-grid { grid-template-columns: 1fr; gap: 2px; }
  .blog-featured { grid-row: span 1; padding: 24px; }
  .blog-featured .post-title { font-size: 1.3rem; }
  .blog-card { padding: 24px; }

  /* Projects */
  .projects-grid { grid-template-columns: 1fr; }
  .project-card { padding: 28px 24px; }
  .project-num { font-size: 2.8rem; margin-bottom: 16px; }

  /* CV */
  .cv-layout { grid-template-columns: 1fr; gap: 40px; }
  .cv-avatar { width: 88px; height: 88px; font-size: 2rem; }
  .cert-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cv-item-header { flex-direction: column; gap: 6px; }
  .cv-download-row { justify-content: flex-start; }

  /* About */
  .about-layout { grid-template-columns: 1fr; gap: 40px; }
  .about-text { font-size: 1rem; }
  .terminal-body { padding: 16px; font-size: 0.75rem; }

  /* Contact */
  .contact-layout { grid-template-columns: 1fr; gap: 32px; }
  .contact-headline { font-size: clamp(2rem, 9vw, 3rem); margin-bottom: 16px; }
  .contact-subtext { font-size: 0.78rem; margin-bottom: 24px; }
  .contact-links { gap: 8px; }
  .contact-link { padding: 12px 16px; }
  .form-textarea { min-height: 80px; }
  #contact .section-inner { padding: 50px 20px; }

  /* Section titles */
  .section-title { font-size: clamp(1.8rem, 7vw, 2.5rem); margin-bottom: 36px; }

  /* Footer */
  footer#site-footer { flex-direction: column; align-items: flex-start; gap: 12px; }
  .footer-links { flex-wrap: wrap; gap: 16px; }
}

@media (max-width: 400px) {
  .hero-title { font-size: 2.2rem; }
  .cert-grid { grid-template-columns: 1fr; }
  .mobile-menu a { font-size: 1.8rem; }
}

/* ─── PAGINATION ─── */
.pagination { display: flex; gap: 16px; justify-content: center; margin-top: 60px; }
