/* ==========================================================================
   JieJie.Dev — Geek-themed blog homepage
   ========================================================================== */

/* ---------- Reset & Tokens ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg-0: #05060a;
  --bg-1: #0a0d14;
  --bg-2: #11151f;
  --bg-card: rgba(13, 17, 23, 0.6);
  --border: rgba(0, 255, 136, 0.18);
  --border-soft: rgba(255, 255, 255, 0.06);

  --neon-green: #00ff88;
  --neon-cyan: #00e5ff;
  --neon-pink: #ff2e88;
  --neon-purple: #b14bff;
  --neon-yellow: #f1ff5a;

  --text-0: #e6f1ff;
  --text-1: #aab8d1;
  --text-2: #6a7a92;
  --text-3: #3a4658;

  --mono: 'Fira Code', 'JetBrains Mono', ui-monospace, monospace;
  --display: 'Space Grotesk', 'JetBrains Mono', sans-serif;

  --gradient-neon: linear-gradient(135deg, #00ff88 0%, #00e5ff 50%, #b14bff 100%);
  --gradient-hot: linear-gradient(135deg, #ff2e88 0%, #b14bff 100%);
  --shadow-glow: 0 0 24px rgba(0, 255, 136, 0.35), 0 0 48px rgba(0, 229, 255, 0.15);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(0, 255, 136, 0.08);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--mono);
  background: var(--bg-0);
  color: var(--text-0);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  line-height: 1.6;
  cursor: none;
}

/* Hide custom cursor on touch devices */
@media (hover: none) {
  body { cursor: auto; }
  .cursor, .cursor-follower { display: none; }
}

/* ---------- Background layers ---------- */
#matrix-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: -3;
  opacity: 0.35;
  pointer-events: none;
}

.scanlines {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.02) 0px,
    rgba(255, 255, 255, 0.02) 1px,
    transparent 1px,
    transparent 3px
  );
  mix-blend-mode: overlay;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.85) 100%);
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 20% 30%, rgba(0, 255, 136, 0.08), transparent 40%),
    radial-gradient(circle at 80% 70%, rgba(177, 75, 255, 0.08), transparent 40%);
  pointer-events: none;
}

/* Floating particles */
.particles {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.particles span {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--neon-green);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--neon-green);
  animation: float-up linear infinite;
  opacity: 0;
}
.particles span:nth-child(1)  { left:  5%; animation-duration: 18s; animation-delay:  0s; }
.particles span:nth-child(2)  { left: 15%; animation-duration: 22s; animation-delay:  3s; background: var(--neon-cyan); box-shadow: 0 0 12px var(--neon-cyan); }
.particles span:nth-child(3)  { left: 25%; animation-duration: 16s; animation-delay:  6s; }
.particles span:nth-child(4)  { left: 35%; animation-duration: 24s; animation-delay:  2s; background: var(--neon-pink); box-shadow: 0 0 12px var(--neon-pink); }
.particles span:nth-child(5)  { left: 45%; animation-duration: 20s; animation-delay:  8s; }
.particles span:nth-child(6)  { left: 55%; animation-duration: 19s; animation-delay:  4s; background: var(--neon-cyan); box-shadow: 0 0 12px var(--neon-cyan); }
.particles span:nth-child(7)  { left: 65%; animation-duration: 23s; animation-delay:  1s; }
.particles span:nth-child(8)  { left: 75%; animation-duration: 17s; animation-delay:  7s; background: var(--neon-pink); box-shadow: 0 0 12px var(--neon-pink); }
.particles span:nth-child(9)  { left: 85%; animation-duration: 21s; animation-delay:  5s; }
.particles span:nth-child(10) { left: 95%; animation-duration: 25s; animation-delay:  9s; }

@keyframes float-up {
  0%   { transform: translateY(110vh) scale(0); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateY(-10vh) scale(1); opacity: 0; }
}

/* ---------- Custom cursor ---------- */
.cursor,
.cursor-follower {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate3d(-100px, -100px, 0);
  transition: transform 0.15s ease, width 0.2s, height 0.2s, background 0.2s;
  will-change: transform;
}

.cursor {
  width: 8px;
  height: 8px;
  background: var(--neon-green);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--neon-green);
  margin: -4px 0 0 -4px;
}

.cursor-follower {
  width: 32px;
  height: 32px;
  border: 1px solid var(--neon-cyan);
  border-radius: 50%;
  margin: -16px 0 0 -16px;
  transition: transform 0.3s ease, width 0.2s, height 0.2s, border-color 0.2s;
}

.cursor-follower.is-hover {
  width: 56px;
  height: 56px;
  margin: -28px 0 0 -28px;
  border-color: var(--neon-pink);
  box-shadow: 0 0 18px rgba(255, 46, 136, 0.5);
}

a, button, .btn { cursor: none; }

/* ---------- Selection ---------- */
::selection {
  background: var(--neon-green);
  color: var(--bg-0);
}

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(5, 6, 10, 0.6);
  border-bottom: 1px solid var(--border-soft);
  transition: padding 0.3s ease, background 0.3s ease;
}

.nav.is-scrolled {
  padding: 10px 32px;
  background: rgba(5, 6, 10, 0.85);
  border-bottom-color: var(--border);
}

.nav-logo {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 18px;
  display: flex;
  align-items: center;
  gap: 2px;
  color: var(--neon-green);
  text-shadow: 0 0 8px rgba(0, 255, 136, 0.5);
}

.logo-bracket { color: var(--text-2); }

.logo-cursor {
  animation: blink 1s steps(2) infinite;
  color: var(--neon-cyan);
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  color: var(--text-1);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  position: relative;
  transition: color 0.2s ease;
}

.nav-links a::before {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  color: var(--neon-green);
  overflow: hidden;
  white-space: nowrap;
  width: 0;
  transition: width 0.4s ease;
  text-shadow: 0 0 8px var(--neon-green);
}

.nav-links a:hover { color: transparent; }
.nav-links a:hover::before { width: 100%; }

.nav-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--text-1);
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--neon-green);
  box-shadow: 0 0 8px var(--neon-green);
  animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.5; transform: scale(1.3); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav { padding: 12px 20px; }
}

/* ---------- Section base ---------- */
.section {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 120px 32px 80px;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 60px;
}

.section-tag {
  font-family: var(--mono);
  color: var(--neon-pink);
  font-size: 14px;
  letter-spacing: 0.1em;
}

.section-title {
  font-family: var(--display);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-0);
}

.section-dot {
  color: var(--neon-green);
  text-shadow: 0 0 12px var(--neon-green);
}

.section-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, var(--border), transparent);
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 120px 32px 60px;
  max-width: 1200px;
  margin: 0 auto;
}

.terminal {
  width: 100%;
  max-width: 820px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-card), var(--shadow-glow);
  animation: terminal-in 1s ease 0.2s both;
}

@keyframes terminal-in {
  from { opacity: 0; transform: translateY(30px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.terminal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-soft);
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.dot-red    { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green  { background: #28c840; }

.terminal-title {
  margin-left: auto;
  font-size: 12px;
  color: var(--text-2);
}

.terminal-body {
  padding: 28px 28px 32px;
  font-size: clamp(14px, 1.6vw, 17px);
  min-height: 280px;
}

.terminal-line {
  margin-bottom: 14px;
  opacity: 0;
  animation: line-in 0.5s ease forwards;
}
.terminal-line:nth-child(1) { animation-delay: 0.6s; }
.terminal-line:nth-child(2) { animation-delay: 2.8s; }
.terminal-line:nth-child(3) { animation-delay: 4.6s; }
.terminal-line:nth-child(4) { animation-delay: 5.2s; }
.terminal-line:nth-child(5) { animation-delay: 6.0s; }

@keyframes line-in {
  to { opacity: 1; }
}

.prompt { color: var(--neon-green); }
.path   { color: var(--neon-cyan); }
.output { color: var(--text-1); }
.output.success { color: var(--neon-green); }
.output.highlight {
  color: var(--neon-yellow);
  text-shadow: 0 0 8px rgba(241, 255, 90, 0.4);
}

.caret,
.cursor-blink {
  color: var(--neon-green);
  animation: blink 1s steps(2) infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.hero-cta {
  display: flex;
  gap: 16px;
  margin-top: 40px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--neon-green);
  color: var(--bg-0);
  box-shadow: 0 0 24px rgba(0, 255, 136, 0.4);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 36px rgba(0, 255, 136, 0.7), 0 0 60px rgba(0, 229, 255, 0.3);
}

.btn-ghost {
  background: transparent;
  color: var(--neon-cyan);
  border-color: var(--neon-cyan);
  box-shadow: inset 0 0 0 1px var(--neon-cyan), 0 0 12px rgba(0, 229, 255, 0.2);
}

.btn-ghost:hover {
  background: rgba(0, 229, 255, 0.1);
  color: #fff;
  box-shadow: inset 0 0 0 1px var(--neon-cyan), 0 0 24px rgba(0, 229, 255, 0.5);
  transform: translateY(-2px);
}

.btn-bracket {
  color: var(--text-2);
  font-weight: 300;
  transition: color 0.25s;
}
.btn-primary .btn-bracket { color: rgba(0, 0, 0, 0.5); }

.btn-arrow {
  transition: transform 0.25s;
}
.btn:hover .btn-arrow { transform: translateX(4px); }

/* ---------- Scroll hint ---------- */
.scroll-hint {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-2);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.6;
}

.scroll-arrow {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--neon-green), transparent);
  animation: scroll-down 2s ease-in-out infinite;
}

@keyframes scroll-down {
  0%   { transform: translateY(-10px); opacity: 0; }
  50%  { opacity: 1; }
  100% { transform: translateY(10px); opacity: 0; }
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
}

.about-text p {
  font-size: 16px;
  color: var(--text-1);
  margin-bottom: 16px;
}

.lead { font-size: 20px !important; color: var(--text-0) !important; }

.highlight {
  color: var(--neon-cyan);
  font-weight: 600;
}

.neon-text {
  background: var(--gradient-neon);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

.about-stats {
  display: flex;
  gap: 32px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-num {
  font-family: var(--display);
  font-size: 36px;
  font-weight: 700;
  color: var(--neon-green);
  text-shadow: 0 0 16px rgba(0, 255, 136, 0.4);
  line-height: 1;
}

.stat-suffix {
  font-family: var(--display);
  font-size: 20px;
  color: var(--neon-green);
  align-self: flex-start;
  margin-top: 8px;
}

.stat-label {
  font-size: 12px;
  color: var(--text-2);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* About Card */
.about-card {
  perspective: 1000px;
}

.card-inner {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transform-style: preserve-3d;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  box-shadow: var(--shadow-card);
}

.card-inner:hover {
  box-shadow: var(--shadow-card), 0 0 32px rgba(0, 255, 136, 0.25);
}

.card-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(0, 255, 136, 0.15), transparent 50%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.card-inner:hover .card-glow { opacity: 1; }

.card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border-soft);
  font-size: 13px;
  color: var(--text-1);
}

.card-icon { color: var(--neon-yellow); }

.card-body {
  padding: 20px;
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.8;
  overflow-x: auto;
}

.card-body .key    { color: var(--neon-cyan); }
.card-body .string { color: var(--neon-green); }

/* ---------- Skills ---------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.skill-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.skill-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 2px;
  background: var(--gradient-neon);
  transition: left 0.5s ease;
}

.skill-card:hover {
  transform: translateY(-4px);
  border-color: var(--border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 24px rgba(0, 255, 136, 0.15);
}

.skill-card:hover::before { left: 0; }

.skill-bar {
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 16px;
  position: relative;
}

.skill-fill {
  height: 100%;
  width: 0;
  background: var(--gradient-neon);
  border-radius: 999px;
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.5);
  transition: width 1.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.skill-name {
  display: block;
  font-family: var(--display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-0);
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.skill-cat {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--neon-cyan);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ---------- Blog ---------- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  position: relative;
  transform-style: preserve-3d;
  perspective: 800px;
}

.post-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(0, 229, 255, 0.12), transparent 50%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.post-card:hover {
  transform: translateY(-6px);
  border-color: var(--neon-cyan);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5), 0 0 32px rgba(0, 229, 255, 0.2);
}

.post-card:hover::after { opacity: 1; }

.post-thumb {
  height: 160px;
  background: var(--bg-1);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-soft);
}

.post-thumb::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 255, 136, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 255, 136, 0.06) 1px, transparent 1px);
  background-size: 24px 24px;
}

.post-thumb-glyph {
  font-family: var(--mono);
  font-size: 48px;
  color: var(--neon-green);
  text-shadow: 0 0 24px var(--neon-green);
  z-index: 1;
  position: relative;
  transition: transform 0.4s ease;
}

.post-card:hover .post-thumb-glyph {
  transform: rotate(-8deg) scale(1.1);
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px 0;
  font-size: 11px;
  color: var(--text-2);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.post-tag {
  background: rgba(0, 255, 136, 0.12);
  color: var(--neon-green);
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
}

.post-body {
  padding: 12px 20px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.post-title {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-0);
  margin-bottom: 8px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.post-card:hover .post-title { color: var(--neon-cyan); }

.post-excerpt {
  font-size: 14px;
  color: var(--text-1);
  margin-bottom: 16px;
  flex: 1;
}

.post-link {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--neon-green);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s;
}

.post-card:hover .post-link { gap: 12px; }

.blog-footer {
  display: flex;
  justify-content: center;
  margin-top: 48px;
}

/* ---------- Stats ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  min-height: 220px;
}

.stat-card.glow:hover {
  transform: translateY(-4px);
  border-color: var(--border);
  box-shadow: var(--shadow-card), 0 0 32px rgba(0, 255, 136, 0.2);
}

.stat-card img {
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 0 16px rgba(0, 255, 136, 0.15));
}

/* ---------- Contact ---------- */
.contact-wrap {
  text-align: center;
}

.contact-lead {
  font-family: var(--mono);
  font-size: clamp(14px, 1.6vw, 18px);
  color: var(--text-1);
  margin-bottom: 48px;
  display: inline-block;
  text-align: left;
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  padding: 16px 24px;
}

.contact-lead .prompt   { color: var(--neon-green); }
.contact-lead .string   { color: var(--neon-yellow); }
.contact-lead .comment  { color: var(--text-2); }

.contact-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
}

.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text-0);
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.contact-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(from 0deg, transparent 0deg, var(--neon-green) 90deg, transparent 180deg);
  opacity: 0;
  transition: opacity 0.4s;
  animation: rotate 4s linear infinite;
}

.contact-card:hover::before { opacity: 0.15; }
.contact-card:hover {
  transform: translateY(-4px);
  border-color: var(--neon-green);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5), 0 0 32px rgba(0, 255, 136, 0.25);
}

.contact-card[data-platform="website"]:hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5), 0 0 32px rgba(0, 229, 255, 0.25);
}
.contact-card[data-platform="website"]::before {
  background: conic-gradient(from 0deg, transparent 0deg, var(--neon-cyan) 90deg, transparent 180deg);
}

.contact-card[data-platform="email"]:hover {
  border-color: var(--neon-pink);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.5), 0 0 32px rgba(255, 46, 136, 0.25);
}
.contact-card[data-platform="email"]::before {
  background: conic-gradient(from 0deg, transparent 0deg, var(--neon-pink) 90deg, transparent 180deg);
}

@keyframes rotate {
  to { transform: rotate(360deg); }
}

.contact-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 255, 136, 0.1);
  color: var(--neon-green);
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
  transition: transform 0.3s ease;
}
.contact-card[data-platform="website"] .contact-icon { background: rgba(0, 229, 255, 0.1); color: var(--neon-cyan); }
.contact-card[data-platform="email"] .contact-icon    { background: rgba(255, 46, 136, 0.1); color: var(--neon-pink); }

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

.contact-name {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 700;
  position: relative;
  z-index: 1;
}

.contact-handle {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-2);
  position: relative;
  z-index: 1;
}

.contact-arrow {
  position: absolute;
  top: 16px;
  right: 16px;
  color: var(--text-2);
  transition: transform 0.3s, color 0.3s;
}

.contact-card:hover .contact-arrow {
  color: var(--neon-green);
  transform: translate(4px, -4px);
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border-soft);
  padding: 32px;
  margin-top: 60px;
  background: rgba(5, 6, 10, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-text {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-1);
}

.footer-text .prompt { color: var(--neon-green); }
.footer-text .string { color: var(--neon-yellow); }

.footer-year {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-2);
}

/* ---------- Reveal animation on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Mobile tweaks ---------- */
@media (max-width: 600px) {
  .section { padding: 80px 20px 60px; }
  .terminal-body { padding: 18px; font-size: 14px; }
  .terminal-body .terminal-line { margin-bottom: 10px; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .btn { justify-content: center; }
  .card-body { font-size: 12px; }
}