/* ════════════════════════════════════════════════════════════
   SADIBYA KAFLE PORTFOLIO — style.css v2.0
   Theme: Dark Tech / IT Student Aesthetic
   Fonts: Space Grotesk (display) + JetBrains Mono (utility)
   ════════════════════════════════════════════════════════════ */

/* ── DESIGN TOKENS ──────────────────────────────────────── */
:root {
  --void:     #050510;
  --surface:  #0d0d1a;
  --card:     #111124;
  --border:   rgba(0, 255, 204, 0.1);
  --border-h: rgba(0, 255, 204, 0.35);
  --cyan:     #00ffcc;
  --violet:   #7000ff;
  --pink:     #ff2d78;
  --gold:     #fca61f;
  --text:     #8888aa;
  --white:    #e8e8ff;
  --radius:   16px;
  --font-d:   'Space Grotesk', sans-serif;
  --font-m:   'JetBrains Mono', monospace;
  --transition: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── RESET ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  background: var(--void);
  color: var(--text);
  font-family: var(--font-d);
  line-height: 1.7;
  overflow-x: hidden;
  cursor: none; /* custom cursor */
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { cursor: none; }

/* ── SCROLLBAR ──────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--void); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--cyan), var(--violet));
  border-radius: 4px;
}

/* ── SCANLINES OVERLAY ──────────────────────────────────── */
.scanlines {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.04) 2px,
    rgba(0, 0, 0, 0.04) 4px
  );
  animation: scanMove 8s linear infinite;
}
@keyframes scanMove {
  from { background-position: 0 0; }
  to   { background-position: 0 200px; }
}

/* ── CUSTOM CURSOR ──────────────────────────────────────── */
.cursor {
  position: fixed;
  width: 8px; height: 8px;
  background: var(--cyan);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.15s, height 0.15s, background 0.15s;
  mix-blend-mode: screen;
}
.cursor-follower {
  position: fixed;
  width: 32px; height: 32px;
  border: 1px solid rgba(0, 255, 204, 0.4);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.12s ease, width 0.2s, height 0.2s, border-color 0.2s;
  mix-blend-mode: screen;
}
body.cursor-hover .cursor {
  width: 14px; height: 14px;
  background: var(--pink);
}
body.cursor-hover .cursor-follower {
  width: 48px; height: 48px;
  border-color: rgba(255, 45, 120, 0.4);
}

/* ── SHADER CANVAS ──────────────────────────────────────── */
#shader-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.5s ease;
}

/* ── NAVBAR ─────────────────────────────────────────────── */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 3rem;
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  background: rgba(5, 5, 16, 0.75);
  border-bottom: 1px solid var(--border);
  transition: padding var(--transition), background var(--transition);
}
#navbar.scrolled {
  padding: 0.75rem 3rem;
  background: rgba(5, 5, 16, 0.95);
}

.nav-brand {
  font-family: var(--font-m);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 2px;
}
.brand-bracket { color: var(--cyan); }
.brand-name { color: var(--white); }

.nav-links {
  display: flex;
  list-style: none;
  gap: 0.25rem;
}
.nav-links a {
  font-family: var(--font-m);
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--text);
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  position: relative;
}
.nav-links a::before {
  content: attr(data-label) '_';
  position: absolute;
  top: -18px;
  left: 0.75rem;
  font-size: 0.6rem;
  color: var(--cyan);
  opacity: 0;
  transition: opacity 0.2s;
}
.nav-links a:hover { color: var(--white); background: rgba(0,255,204,0.06); }
.nav-links a:hover::before { opacity: 1; }

.nav-cta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--cyan);
  color: var(--void);
  border: none;
  padding: 0.55rem 1.25rem;
  border-radius: 8px;
  font-family: var(--font-m);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
}
.nav-cta:hover {
  background: var(--pink);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 45, 120, 0.3);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
}
.hamburger span {
  width: 22px; height: 1.5px;
  background: var(--cyan);
  border-radius: 2px;
  transition: all 0.3s;
  display: block;
}

@media (max-width: 900px) {
  #navbar { padding: 1rem 1.5rem; }
  #navbar.scrolled { padding: 0.75rem 1.5rem; }
  .hamburger { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(13, 13, 26, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem 0 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 0; }
  .nav-links a {
    display: block;
    padding: 0.75rem 2rem;
    border-radius: 0;
    font-size: 0.9rem;
  }
  .nav-links a::before { display: none; }
}

/* ── POPUP CONTACT ──────────────────────────────────────── */
.popup-contact {
  position: fixed;
  top: 68px; right: 16px;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-10px) scale(0.96);
  transition: opacity 0.3s ease, visibility 0s linear 0.3s, transform 0.3s ease;
}
.popup-contact.show {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  transition: opacity 0.3s ease, visibility 0s linear 0s, transform 0.3s ease;
}
.popup-inner {
  background: var(--card);
  border: 1px solid var(--border-h);
  border-radius: var(--radius);
  padding: 1.75rem;
  width: 350px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.7), 0 0 40px rgba(0,255,204,0.05);
}
.popup-tag {
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: var(--cyan);
  margin-bottom: 0.75rem;
  opacity: 0.7;
}
.popup-inner h3 {
  font-family: var(--font-d);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1rem;
}
.popup-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.83rem;
  margin-bottom: 0.5rem;
}
.popup-row i { color: var(--cyan); font-size: 0.9rem; }
.popup-row a { color: var(--text); transition: color 0.2s; }
.popup-row a:hover { color: var(--cyan); }
.popup-row .muted { color: rgba(136,136,170,0.5); font-size: 0.75rem; }
.popup-socials {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.25rem;
}
.popup-socials a {
  width: 34px; height: 34px;
  background: rgba(0,255,204,0.08);
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  font-size: 0.9rem;
  transition: all 0.2s;
}
.popup-socials a:hover {
  background: var(--cyan);
  color: var(--void);
}
.popup-close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1rem;
  transition: color 0.2s;
}
.popup-close:hover { color: var(--pink); }

/* ── SECTION BASE ───────────────────────────────────────── */
section {
  position: relative;
  z-index: 1;
  padding: 7rem 5rem;
}
@media (max-width: 900px) { section { padding: 5rem 1.5rem; } }

.section-tag {
  font-family: var(--font-m);
  font-size: 0.75rem;
  color: var(--cyan);
  letter-spacing: 1px;
  margin-bottom: 0.75rem;
  opacity: 0.8;
}
.section-title {
  font-family: var(--font-d);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 700;
  color: var(--white);
  letter-spacing: -1px;
  line-height: 1.1;
  margin-bottom: 1rem;
}
.section-sub {
  font-size: 1rem;
  color: var(--text);
  max-width: 480px;
  line-height: 1.8;
}
.section-head { margin-bottom: 3.5rem; }
.accent { color: var(--cyan); }

/* ── BUTTONS ─────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--cyan);
  color: var(--void);
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 0.92rem;
  border: none;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  opacity: 0;
  transition: opacity 0.3s;
}
.btn-primary:hover::before { opacity: 1; }
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,255,204,0.25);
  color: var(--white);
}
.btn-primary span, .btn-primary svg { position: relative; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  color: var(--text);
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-family: var(--font-d);
  font-weight: 500;
  font-size: 0.92rem;
  border: 1px solid rgba(136,136,170,0.2);
  transition: all var(--transition);
}
.btn-ghost:hover {
  color: var(--white);
  border-color: var(--cyan);
  background: rgba(0,255,204,0.05);
  transform: translateY(-3px);
}

/* ── SCROLL REVEAL ──────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.8s var(--transition), transform 0.8s var(--transition);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── HOME SECTION ───────────────────────────────────────── */
#home {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 0 5rem;
  position: relative;
}
.hero-inner { max-width: 780px; padding-top: 80px; }

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-m);
  font-size: 0.75rem;
  color: var(--cyan);
  background: rgba(0,255,204,0.07);
  border: 1px solid var(--border);
  padding: 0.4rem 0.9rem;
  border-radius: 50px;
  margin-bottom: 2rem;
  letter-spacing: 1px;
}
.tag-dot {
  width: 6px; height: 6px;
  background: var(--cyan);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.7); }
}

.hero-title {
  font-family: var(--font-d);
  font-size: clamp(3.5rem, 9vw, 7.5rem);
  font-weight: 700;
  color: var(--white);
  letter-spacing: -3px;
  line-height: 1.0;
  margin-bottom: 1.5rem;
}
.line-label {
  display: block;
  font-family: var(--font-m);
  font-size: 0.75rem;
  letter-spacing: 2px;
  color: var(--cyan);
  opacity: 0.6;
  font-weight: 400;
  margin-bottom: 0.25rem;
}
.hero-name { display: block; }
.type-cursor {
  display: inline-block;
  color: var(--cyan);
  animation: blink 1s step-end infinite;
  font-weight: 300;
}
@keyframes blink { 50% { opacity: 0; } }

.hero-role {
  font-family: var(--font-m);
  font-size: clamp(0.85rem, 2vw, 1.1rem);
  color: var(--text);
  margin-bottom: 1.5rem;
  padding: 0.5rem 1rem;
  background: rgba(112,0,255,0.08);
  border: 1px solid rgba(112,0,255,0.2);
  border-radius: 8px;
  display: inline-block;
}
.role-prefix { color: var(--violet); }
.role-cycle { color: var(--cyan); font-weight: 700; }
.role-suffix { color: var(--pink); }

.hero-bio {
  font-size: 1.05rem;
  color: var(--text);
  max-width: 520px;
  line-height: 1.85;
  margin-bottom: 2.5rem;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3.5rem; }

.hero-stats {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
}
.stat {
  text-align: left;
  padding-right: 3rem;
}
.stat-val {
  font-family: var(--font-d);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--white);
}
.stat-suffix { font-size: 1.5rem; color: var(--cyan); font-weight: 700; }
.stat-key {
  display: block;
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: var(--text);
  letter-spacing: 1px;
  margin-top: -0.2rem;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: rgba(136,136,170,0.15);
  margin-right: 3rem;
}

.scroll-cue {
  position: absolute;
  bottom: 2.5rem;
  left: 5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.scroll-line {
  width: 1px;
  height: 56px;
  background: linear-gradient(to bottom, var(--cyan), transparent);
  animation: scrollFade 2.5s ease-in-out infinite;
}
@keyframes scrollFade {
  0%, 100% { opacity: 0.3; transform: scaleY(0.8) translateY(0); }
  50% { opacity: 1; transform: scaleY(1.1) translateY(4px); }
}
.scroll-label {
  font-family: var(--font-m);
  font-size: 0.65rem;
  color: var(--text);
  letter-spacing: 2px;
  writing-mode: vertical-rl;
  opacity: 0.5;
}

@media (max-width: 768px) {
  #home { padding: 0 1.5rem; }
  .scroll-cue { left: 1.5rem; }
  .stat { padding-right: 1.5rem; }
  .stat-divider { margin-right: 1.5rem; }
}

/* ── SERVICES SECTION ───────────────────────────────────── */
#service { background: var(--surface); }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
@media (max-width: 1200px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .services-grid { grid-template-columns: 1fr; } }

.svc-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  position: relative;
  overflow: hidden;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.svc-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(0,255,204,0.07) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
  pointer-events: none;
}
.svc-card:hover {
  border-color: var(--border-h);
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.4), 0 0 0 1px rgba(0,255,204,0.08);
}
.svc-card:hover::after { opacity: 1; }

.svc-glow {
  position: absolute;
  width: 120px; height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,255,204,0.15) 0%, transparent 70%);
  top: -30px; right: -30px;
  pointer-events: none;
  transition: opacity var(--transition);
  opacity: 0;
}
.svc-glow--gold { background: radial-gradient(circle, rgba(252,166,31,0.15) 0%, transparent 70%); }
.svc-card:hover .svc-glow { opacity: 1; }

.svc-num {
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: var(--cyan);
  opacity: 0.4;
  margin-bottom: 1.25rem;
  letter-spacing: 2px;
}
.svc-icon {
  width: 46px; height: 46px;
  background: rgba(0,255,204,0.08);
  border: 1px solid rgba(0,255,204,0.12);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--cyan);
  margin-bottom: 1.25rem;
  transition: background var(--transition), border-color var(--transition);
}
.svc-card:hover .svc-icon {
  background: rgba(0,255,204,0.15);
  border-color: rgba(0,255,204,0.3);
}
.svc-card h3 {
  font-family: var(--font-d);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.75rem;
}
.svc-card > p {
  font-size: 0.88rem;
  color: var(--text);
  line-height: 1.75;
}
.svc-more {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  font-size: 0.85rem;
  color: var(--text);
  line-height: 1.75;
  transition: max-height 0.5s ease, opacity 0.4s ease, margin-top 0.3s ease;
}
.svc-more.open {
  max-height: 300px;
  opacity: 1;
  margin-top: 0.75rem;
}
.svc-toggle {
  background: none;
  border: none;
  color: var(--cyan);
  font-family: var(--font-m);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: gap 0.2s, color 0.2s;
  padding: 0;
}
.svc-toggle:hover { gap: 0.7rem; color: var(--white); }
.svc-cta { border-color: rgba(252,166,31,0.2); }

/* ── ABOUT SECTION ──────────────────────────────────────── */
#about { background: var(--void); }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: center;
}
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 3.5rem; }
}
.about-left p { font-size: 0.97rem; color: var(--text); line-height: 1.9; }

/* Terminal */
.about-terminal {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
.terminal-bar {
  background: #1a1a2e;
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.t-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
}
.t-dot.red    { background: #ff5f57; }
.t-dot.yellow { background: #ffbd2e; }
.t-dot.green  { background: #28c840; }
.t-title {
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: rgba(136,136,170,0.6);
  margin-left: 0.5rem;
}
.terminal-body {
  background: rgba(5,5,16,0.95);
  padding: 1.25rem 1.5rem;
  font-family: var(--font-m);
  font-size: 0.82rem;
  line-height: 1.9;
}
.t-line { display: flex; align-items: flex-start; gap: 0.5rem; }
.t-prompt { color: var(--cyan); }
.t-cmd { color: var(--white); }
.t-out { color: var(--text); padding-left: 1.2rem; }
.t-cursor-line {
  color: var(--cyan);
  animation: blink 1s step-end infinite;
}

/* Skills Panel */
.skills-panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: transform 0.1s ease;
  transform-style: preserve-3d;
  will-change: transform;
}
.skills-panel-tag {
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: var(--cyan);
  opacity: 0.6;
  margin-bottom: 1.75rem;
}
.skills-list { display: flex; flex-direction: column; gap: 1.5rem; }

.skill-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}
.skill-name {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--white);
}
.skill-pct {
  font-family: var(--font-m);
  font-size: 0.78rem;
  color: var(--cyan);
  font-weight: 700;
}
.skill-track {
  height: 4px;
  background: rgba(255,255,255,0.04);
  border-radius: 4px;
  overflow: hidden;
}
.skill-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  width: 0%;
  transition: width 1.4s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}
.skill-fill::after {
  content: '';
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 12px;
  background: rgba(255,255,255,0.6);
  filter: blur(4px);
  border-radius: 4px;
}

/* ── PORTFOLIO ──────────────────────────────────────────── */
#portfolio { background: var(--surface); }

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
}
.f-btn {
  font-family: var(--font-m);
  font-size: 0.75rem;
  font-weight: 500;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  color: var(--text);
  padding: 0.45rem 1.1rem;
  border-radius: 6px;
  letter-spacing: 0.5px;
  transition: all 0.25s ease;
}
.f-btn:hover, .f-btn.active {
  background: rgba(0,255,204,0.1);
  border-color: var(--cyan);
  color: var(--cyan);
}

.ext-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}
.ext-links.hidden { display: none; }
.ext-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all var(--transition);
  min-width: 220px;
}
.ext-card:hover {
  border-color: var(--border-h);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,255,204,0.08);
}
.ext-card > i:first-child { font-size: 1.5rem; color: var(--cyan); }
.ext-card div { flex: 1; }
.ext-card strong { display: block; color: var(--white); font-size: 0.9rem; font-weight: 600; }
.ext-card span { font-size: 0.78rem; color: var(--text); }
.ext-arrow { font-size: 0.85rem; color: var(--text); transition: transform 0.2s; }
.ext-card:hover .ext-arrow { transform: translate(3px,-3px); color: var(--cyan); }

.port-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.p-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  animation: fadeInUp 0.5s ease forwards;
}
.p-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 50px rgba(0,0,0,0.5), 0 0 0 1px rgba(0,255,204,0.1);
  border-color: rgba(0,255,204,0.2);
}
.p-card.hidden { display: none; }

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.p-img-wrap {
  position: relative;
  aspect-ratio: 4/3;
  background: var(--void);
  overflow: hidden;
}
.p-img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.p-card:hover .p-img-wrap img { transform: scale(1.06); }
.p-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: rgba(0,255,204,0.15);
  z-index: 0;
}
.p-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,255,204,0.12), rgba(112,0,255,0.18));
  display: flex;
  align-items: flex-end;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.35s ease;
  z-index: 2;
}
.p-card:hover .p-overlay { opacity: 1; }
.p-overlay-tag {
  font-family: var(--font-m);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--cyan);
  background: rgba(5,5,16,0.85);
  padding: 0.3rem 0.7rem;
  border-radius: 4px;
  letter-spacing: 1px;
}
.p-meta { padding: 1.1rem 1.25rem; }
.p-meta h4 {
  font-family: var(--font-d);
  font-size: 0.93rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.5rem;
}
.p-chips { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.p-chips span {
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: rgba(0,255,204,0.7);
  background: rgba(0,255,204,0.07);
  border: 1px solid rgba(0,255,204,0.12);
  padding: 0.15rem 0.6rem;
  border-radius: 4px;
}

/* ── TESTIMONIALS ───────────────────────────────────────── */
#testimonial { background: var(--void); }

.testi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 0;
}
@media (max-width: 900px) { .testi-grid { grid-template-columns: 1fr; } }

.t-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.t-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-h);
  box-shadow: 0 16px 40px rgba(0,0,0,0.3);
}
.t-quote {
  font-family: Georgia, serif;
  font-size: 4rem;
  line-height: 1;
  color: var(--cyan);
  opacity: 0.2;
  margin-bottom: 0.75rem;
}
.t-card p {
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.85;
  font-style: italic;
  margin-bottom: 1.5rem;
}
.t-author { display: flex; align-items: center; gap: 0.75rem; }
.t-avatar {
  width: 38px; height: 38px;
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--void);
  flex-shrink: 0;
}
.t-author strong { display: block; color: var(--white); font-size: 0.9rem; font-weight: 600; }
.t-author span { font-family: var(--font-m); font-size: 0.72rem; color: var(--cyan); opacity: 0.7; }

/* ── CONTACT ────────────────────────────────────────────── */
#contact { background: var(--surface); }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 5rem;
  align-items: start;
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; gap: 3rem; } }

.c-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.75rem;
}
.c-icon {
  width: 42px; height: 42px;
  background: rgba(0,255,204,0.08);
  border: 1px solid rgba(0,255,204,0.12);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--cyan);
  flex-shrink: 0;
}
.c-info-item strong { display: block; color: var(--white); font-weight: 600; font-size: 0.88rem; margin-bottom: 0.2rem; }
.c-info-item p { font-size: 0.88rem; color: var(--text); }
.accent-link { color: var(--cyan); transition: color 0.2s; }
.accent-link:hover { color: var(--white); }

.c-socials {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.5rem;
}
.c-socials a {
  width: 38px; height: 38px;
  background: rgba(0,255,204,0.06);
  border: 1px solid var(--border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  font-size: 1rem;
  transition: all 0.2s;
}
.c-socials a:hover { background: var(--cyan); color: var(--void); transform: translateY(-3px); }

/* Form */
.c-form { display: flex; flex-direction: column; gap: 1rem; }
.f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 600px) { .f-row { grid-template-columns: 1fr; } }
.f-group { display: flex; flex-direction: column; gap: 0.4rem; }
.f-group label {
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--text);
  letter-spacing: 1px;
}
.req { color: var(--pink); }
.opt { color: rgba(136,136,170,0.4); font-size: 0.68rem; }
.f-group input,
.f-group textarea {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  padding: 0.8rem 1rem;
  color: var(--white);
  font-family: var(--font-d);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.25s, background 0.25s;
  width: 100%;
}
.f-group input::placeholder,
.f-group textarea::placeholder { color: rgba(136,136,170,0.3); }
.f-group input:focus,
.f-group textarea:focus {
  border-color: var(--cyan);
  background: rgba(0,255,204,0.03);
}
.f-group input:valid:not(:placeholder-shown) { border-color: rgba(40,200,80,0.4); }
.f-group input:invalid:not(:placeholder-shown) { border-color: rgba(255,45,120,0.4); }
.f-group textarea { resize: vertical; min-height: 130px; }

/* ── FOOTER ─────────────────────────────────────────────── */
footer {
  position: relative;
  z-index: 1;
  background: var(--void);
  border-top: 1px solid var(--border);
  padding: 2.5rem 5rem;
}
@media (max-width: 768px) { footer { padding: 2rem 1.5rem; } }
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2rem;
}
.footer-brand {
  font-family: var(--font-m);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--white);
}
.footer-nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.footer-nav a {
  font-size: 0.83rem;
  color: var(--text);
  transition: color 0.2s;
}
.footer-nav a:hover { color: var(--cyan); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.04);
}
.footer-copy { font-size: 0.8rem; color: rgba(136,136,170,0.4); }
.footer-mono { font-family: var(--font-m); font-size: 0.72rem; color: rgba(0,255,204,0.3); }

/* ── BACK TO TOP ────────────────────────────────────────── */
#btn-top {
  position: fixed;
  bottom: 2rem; right: 2rem;
  z-index: 999;
  width: 44px; height: 44px;
  background: rgba(0,255,204,0.1);
  border: 1px solid var(--border-h);
  border-radius: 10px;
  color: var(--cyan);
  font-size: 1rem;
  display: none;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  backdrop-filter: blur(10px);
}
#btn-top.visible { display: flex; animation: fadeInUp 0.3s ease; }
#btn-top:hover {
  background: var(--cyan);
  color: var(--void);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,255,204,0.3);
}

/* ── REDUCED MOTION ─────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .cursor, .cursor-follower { display: none; }
  body { cursor: auto; }
}


/* ════════════════════════════════════════════════════════════
   ADDITIONS v3.0 — Service Apple Scroll, Skills, Portfolio,
   Testimonials, Toast, Character, Footer, Progress Bar
   ════════════════════════════════════════════════════════════ */

/* ── SERVICE CARDS — initial state handled by JS ────────── */
/* override the generic .reveal on .svc-card so JS controls it */
.svc-card.reveal {
  opacity: 0; /* JS will drive */
  transform: none; /* JS sets translateX */
}
.svc-card.reveal.visible {
  /* prevent generic reveal from fighting JS */
  opacity: unset;
  transform: unset;
}

/* ── SKILL BAR GLOW TIP ─────────────────────────────────── */
.skill-fill {
  position: relative;
  overflow: visible;
}

/* scanning shimmer after fill */
@keyframes shimmer {
  0%   { left: -40%; opacity: 0; }
  30%  { opacity: 0.7; }
  100% { left: 110%; opacity: 0; }
}
.skill-fill::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: -40%;
  width: 35%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.55), transparent);
  border-radius: 4px;
  animation: shimmer 1.8s ease-in-out infinite;
  animation-play-state: paused;
}
.skill-fill.animating::before {
  animation-play-state: running;
}

/* ── PORTFOLIO CARDS — perspective wrapper ──────────────── */
.port-grid {
  perspective: 1200px;
}

/* ── TESTIMONIAL SECTION — background grid accent ───────── */
#testimonial {
  position: relative;
  overflow: hidden;
}
#testimonial::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,255,204,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,204,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}
#testimonial .section-head,
#testimonial .testi-grid {
  position: relative;
  z-index: 1;
}

/* quote icon upgrade */
.t-quote {
  font-family: 'Space Grotesk', serif;
  font-size: 5rem;
  line-height: 0.8;
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0.35;
  margin-bottom: 1rem;
  display: block;
  user-select: none;
}

/* starring rating dots on t-card */
.t-card::after {
  content: '★ ★ ★ ★ ★';
  display: block;
  font-size: 0.65rem;
  letter-spacing: 3px;
  color: var(--gold);
  opacity: 0.6;
  margin-top: 1rem;
}

/* ── CONTACT FORM — field focus glow ────────────────────── */
.f-group input:focus,
.f-group textarea:focus {
  box-shadow: 0 0 0 3px rgba(0,255,204,0.08), 0 0 20px rgba(0,255,204,0.06);
}

/* send button full width + icon animation */
.c-form .btn-primary svg {
  transition: transform 0.3s ease;
}
.c-form .btn-primary:hover svg {
  transform: translateX(5px);
}

/* ── FOOTER — INFORMATIVE ───────────────────────────────── */
footer {
  position: relative;
  z-index: 1;
  background: var(--void);
  border-top: 1px solid var(--border);
  padding: 0;
  overflow: hidden;
}
footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(0,255,204,0.04) 0%, transparent 60%);
  pointer-events: none;
}

.footer-main {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 3rem;
  padding: 4rem 5rem 3rem;
  position: relative;
  z-index: 1;
}
@media (max-width: 1100px) {
  .footer-main { grid-template-columns: 1fr 1fr; gap: 2.5rem; padding: 3rem 2rem 2rem; }
}
@media (max-width: 600px) {
  .footer-main { grid-template-columns: 1fr; padding: 2.5rem 1.5rem 2rem; }
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-brand-col .footer-logo {
  font-family: var(--font-m);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.75rem;
  display: block;
}
.footer-brand-col .footer-logo .brand-bracket { color: var(--cyan); }

.footer-tagline {
  font-size: 0.88rem;
  color: var(--text);
  line-height: 1.75;
  margin-bottom: 1.5rem;
  max-width: 260px;
}

.footer-social-row {
  display: flex;
  gap: 0.6rem;
}
.footer-social-row a {
  width: 36px; height: 36px;
  background: rgba(0,255,204,0.06);
  border: 1px solid var(--border);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-size: 0.9rem;
  transition: all 0.25s ease;
}
.footer-social-row a:hover {
  background: rgba(0,255,204,0.15);
  border-color: var(--border-h);
  color: var(--cyan);
  transform: translateY(-3px);
}

.footer-col-title {
  font-family: var(--font-m);
  font-size: 0.68rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--cyan);
  opacity: 0.7;
  margin-bottom: 1.25rem;
}

.footer-link-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.footer-link-list li a {
  font-size: 0.87rem;
  color: var(--text);
  transition: color 0.2s, padding-left 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.footer-link-list li a::before {
  content: '//';
  font-family: var(--font-m);
  font-size: 0.65rem;
  color: var(--cyan);
  opacity: 0;
  transition: opacity 0.2s;
}
.footer-link-list li a:hover {
  color: var(--white);
  padding-left: 4px;
}
.footer-link-list li a:hover::before { opacity: 0.6; }

.footer-contact-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.footer-contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.83rem;
  color: var(--text);
  line-height: 1.5;
}
.footer-contact-list li i {
  color: var(--cyan);
  font-size: 0.85rem;
  margin-top: 2px;
  flex-shrink: 0;
}
.footer-contact-list a {
  color: var(--text);
  transition: color 0.2s;
}
.footer-contact-list a:hover { color: var(--cyan); }

.footer-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: rgba(0,255,204,0.5);
  background: rgba(0,255,204,0.05);
  border: 1px solid rgba(0,255,204,0.12);
  padding: 0.3rem 0.7rem;
  border-radius: 50px;
  margin-top: 1rem;
  letter-spacing: 1px;
}
.footer-badge i { font-size: 0.7rem; }

.footer-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin: 0 5rem;
  position: relative;
  z-index: 1;
}
@media (max-width: 768px) { .footer-divider { margin: 0 1.5rem; } }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.5rem 5rem 2rem;
  position: relative;
  z-index: 1;
}
@media (max-width: 768px) {
  .footer-bottom {
    padding: 1.5rem 1.5rem 2rem;
    flex-direction: column;
    text-align: center;
  }
}

.footer-copy {
  font-size: 0.78rem;
  color: rgba(136,136,170,0.35);
}
.footer-mono {
  font-family: var(--font-m);
  font-size: 0.7rem;
  color: rgba(0,255,204,0.25);
}
.footer-made {
  font-family: var(--font-m);
  font-size: 0.68rem;
  color: rgba(136,136,170,0.3);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.footer-made i { color: var(--pink); font-size: 0.6rem; }

/* ── PROGRESS BAR (top) ─────────────────────────────────── */
#progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--violet), var(--pink));
  z-index: 10001;
  width: 0%;
  transition: width 0.08s linear;
  pointer-events: none;
  box-shadow: 0 0 8px rgba(0,255,204,0.6);
}

/* ── ACTIVE NAV LINK ────────────────────────────────────── */
.nav-links a.nav-active {
  color: var(--cyan) !important;
  background: rgba(0,255,204,0.06);
}

/* ── HERO GLITCH EFFECT ON NAME (subtle) ────────────────── */
@keyframes glitch {
  0%,95%,100% { text-shadow: none; clip-path: none; }
  96% {
    text-shadow: 2px 0 var(--pink), -2px 0 var(--cyan);
    clip-path: inset(20% 0 60% 0);
  }
  97% {
    text-shadow: -3px 0 var(--pink), 3px 0 var(--cyan);
    clip-path: inset(50% 0 20% 0);
  }
  98% {
    text-shadow: 1px 0 var(--violet);
    clip-path: inset(0 0 0 0);
  }
}
.hero-name {
  animation: glitch 7s ease-in-out infinite;
}

/* ── SECTION DIVIDER LINES ──────────────────────────────── */
section + section::before {
  content: '';
  display: block;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  position: absolute;
  top: 0; left: 10%; right: 10%;
}

/* ── CARD HOLOGRAPHIC BORDER ON HOVER ───────────────────── */
@keyframes holo {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.svc-card:hover,
.p-card:hover,
.t-card:hover {
  background-image: linear-gradient(var(--card), var(--card)),
    linear-gradient(135deg, var(--cyan), var(--violet), var(--pink), var(--cyan));
  background-origin: border-box;
  background-clip: padding-box, border-box;
  border-color: transparent;
  background-size: 200% 200%;
  animation: holo 3s ease infinite;
}

/* ── SELECTION STYLE ────────────────────────────────────── */
::selection {
  background: rgba(0,255,204,0.25);
  color: var(--white);
}

/* ── FOCUS VISIBLE ──────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}



/* ════════════════════════════════════════════════════════════
   CHARACTER IMAGE + HERO LAYOUT + FULL RESPONSIVENESS v3.1
   ════════════════════════════════════════════════════════════ */

/* ── HERO TWO-COLUMN LAYOUT ─────────────────────────────── */
#home {
  padding: 0 5rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}
.hero-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 2rem;
  min-height: 100vh;
  padding-top: 80px;
  padding-bottom: 60px;
}

/* left column stays as-is */
.hero-inner {
  max-width: 100%;
  padding-top: 0;
}

/* ── CHARACTER IMAGE COLUMN ─────────────────────────────── */
.hero-character-wrap {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  height: 120%;
  min-height: 980px;
}

/* soft radial glow behind character */
.hero-char-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 420px;
  height: 420px;
  background: radial-gradient(ellipse at center,
    rgba(0,255,204,0.12) 0%,
    rgba(112,0,255,0.08) 45%,
    transparent 70%
  );
  border-radius: 50%;
  pointer-events: none;
  animation: glowPulse 4s ease-in-out infinite;
}
@keyframes glowPulse {
  0%,100% { opacity: 0.7; transform: translateX(-50%) scale(1);   }
  50%      { opacity: 1;   transform: translateX(-50%) scale(1.08); }
}

/* decorative rings */
.hero-char-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(0,255,204,0.1);
  pointer-events: none;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  animation: ringExpand 4s ease-in-out infinite;
}
.ring1 { width: 340px; height: 340px; animation-delay: 0s;    }
.ring2 { width: 460px; height: 460px; animation-delay: 0.8s;  border-color: rgba(112,0,255,0.07); }
@keyframes ringExpand {
  0%,100% { opacity: 0.4; transform: translateX(-50%) scale(1);    }
  50%      { opacity: 0.9; transform: translateX(-50%) scale(1.04); }
}

/* THE CHARACTER IMAGE */
.hero-char-img {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 480px;
  height: auto;
  object-fit: contain;
  filter:
    drop-shadow(0 0 40px rgba(0,255,204,0.18))
    drop-shadow(0 20px 60px rgba(0,0,0,0.5));
  /* entrance animation */
  animation: charEntrance 1s cubic-bezier(0.16,1,0.3,1) 0.4s both;
  transform-origin: bottom center;
  will-change: transform;
}
@keyframes charEntrance {
  from { opacity: 0; transform: translateY(60px) scale(0.92); }
  to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

/* idle floating animation */
.hero-char-img.idle {
  animation: charEntrance 1s cubic-bezier(0.16,1,0.3,1) 0.4s both,
             charFloat 5s ease-in-out 1.5s infinite;
}
@keyframes charFloat {
  0%,100% { transform: translateY(0px);   }
  50%      { transform: translateY(-14px); }
}

/* scroll-section pose transitions */
.hero-char-img.pose-home        { animation: charFloat   5s ease-in-out infinite; }
.hero-char-img.pose-service     { animation: charBounce  3s ease-in-out infinite; }
.hero-char-img.pose-about       { animation: charSway    4s ease-in-out infinite; }
.hero-char-img.pose-portfolio   { animation: charPop     2.5s ease-in-out infinite; }
.hero-char-img.pose-testimonial { animation: charNod     3s ease-in-out infinite; }
.hero-char-img.pose-contact     { animation: charWait    4s ease-in-out infinite; }
.hero-char-img.pose-sent        { animation: charSalute  1.8s ease-in-out 3; }

@keyframes charFloat   { 0%,100%{transform:translateY(0)}    50%{transform:translateY(-14px)} }
@keyframes charBounce  { 0%,100%{transform:translateY(0) scaleX(1)}  40%{transform:translateY(-18px) scaleX(1.04)} 70%{transform:translateY(-6px)} }
@keyframes charSway    { 0%,100%{transform:rotate(0deg)}  33%{transform:rotate(-3deg)} 66%{transform:rotate(3deg)} }
@keyframes charPop     { 0%,100%{transform:scale(1)}      50%{transform:scale(1.05) translateY(-8px)} }
@keyframes charNod     { 0%,100%{transform:translateY(0) rotate(0)}  50%{transform:translateY(-6px) rotate(-2deg)} }
@keyframes charWait    { 0%,100%{transform:translateY(0)}    50%{transform:translateY(-5px)} }
@keyframes charSalute  { 0%{transform:scale(1) rotate(0)}  30%{transform:scale(1.06) rotate(-4deg)}  60%{transform:scale(1.03) rotate(2deg)}  100%{transform:scale(1) rotate(0)} }

/* transition between poses */
.hero-char-img.switching-pose {
  transition: opacity 0.3s ease, transform 0.3s ease;
  opacity: 0.4;
  transform: scale(0.94);
}

/* "Open to work" badge */
.hero-char-badge {
  position: absolute;
  bottom: 280px;
  right: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-m);
  font-size: 0.72rem;
  color: var(--cyan);
  background: rgba(13,13,26,0.8);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(0,255,204,0.2);
  padding: 0.45rem 0.9rem;
  border-radius: 50px;
  letter-spacing: 1px;
  animation: badgePop 0.6s cubic-bezier(0.16,1,0.3,1) 1.2s both;
  white-space: nowrap;
}
@keyframes badgePop {
  from { opacity:0; transform:scale(0.8) translateY(10px); }
  to   { opacity:1; transform:scale(1)   translateY(0);    }
}

/* ── REMOVE OLD FLOATING MASCOT ─────────────────────────── */
#mascot-wrap { display: none !important; }

/* ── FULL RESPONSIVENESS ────────────────────────────────── */

/* Large desktops */
@media (min-width: 1400px) {
  .hero-char-img { max-width: 520px; }
  .hero-layout { grid-template-columns: 1fr 1.1fr; }
}

/* Standard desktops / laptops */
@media (max-width: 1200px) {
  #home { padding: 0 3rem; }
  .hero-char-img { max-width: 400px; }
  .hero-character-wrap { min-height: 480px; }
}

/* Tablets landscape */
@media (max-width: 1024px) {
  #home { padding: 0 2.5rem; }
  .hero-layout {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
  .hero-title { font-size: clamp(2.5rem, 7vw, 5rem); }
  .hero-char-img { max-width: 340px; }
  .hero-character-wrap { min-height: 420px; }
  .hero-char-glow { width: 300px; height: 300px; }
  .ring1 { width: 260px; height: 260px; }
  .ring2 { width: 360px; height: 360px; }
}

/* Tablets portrait — stack vertically */
@media (max-width: 768px) {
  #home {
    padding: 0 1.5rem;
    min-height: auto;
  }
  .hero-layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    min-height: 100vh;
    padding-top: 90px;
    padding-bottom: 40px;
    gap: 0;
  }

  /* character goes ABOVE text on mobile */
  .hero-character-wrap {
    order: -1;
    min-height: 320px;
    margin-bottom: 1.5rem;
  }
  .hero-char-img {
    max-width: 260px;
    margin: 0 auto;
  }
  .hero-char-glow  { width: 220px; height: 220px; }
  .ring1 { width: 200px; height: 200px; }
  .ring2 { width: 280px; height: 280px; }
  .hero-char-badge { right: 50%; transform: translateX(50%); bottom: 10px; }

  .hero-inner { text-align: center; }
  .hero-tag   { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-actions { justify-content: center; }

  .line-label { text-align: left; }

  .scroll-cue { left: 50%; transform: translateX(-50%); }

  /* Services */
  .services-grid { grid-template-columns: 1fr; }

  /* About */
  .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }

  /* Portfolio */
  .port-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

  /* Testimonials */
  .testi-grid { grid-template-columns: 1fr; }

  /* Contact */
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }

  /* Popup */
  .popup-contact { right: 8px; left: 8px; }
  .popup-inner   { width: 100%; }
}

/* Mobile small */
@media (max-width: 480px) {
  #home { padding: 0 1.25rem; }
  section { padding: 3.5rem 1.25rem; }
  nav { padding: 0.85rem 1.25rem; }

  .hero-char-img { max-width: 210px; }
  .hero-character-wrap { min-height: 260px; }

  .hero-title { letter-spacing: -2px; }
  .hero-bio   { font-size: 0.9rem; }

  .hero-stats { gap: 0; flex-wrap: wrap; }
  .stat       { padding-right: 1.2rem; margin-bottom: 0.5rem; }
  .stat-divider { margin-right: 1.2rem; height: 30px; }

  .btn-primary,
  .btn-ghost  { padding: 0.7rem 1.3rem; font-size: 0.85rem; }

  .section-title { font-size: 1.8rem; }

  .f-row { grid-template-columns: 1fr; }

  .footer-main  { grid-template-columns: 1fr; padding: 2rem 1.25rem 1.5rem; }
  .footer-bottom { padding: 1.25rem 1.25rem 1.5rem; flex-direction: column; text-align:center; }

  #btn-top { bottom: 1.25rem; right: 1.25rem; }
}

/* Very small phones */
@media (max-width: 360px) {
  .hero-char-img { max-width: 180px; }
  .hero-title    { font-size: 2rem; letter-spacing: -1.5px; }
  .stat-val      { font-size: 1.8rem; }
}

/* ── SECTION RESPONSIVENESS EXTRAS ─────────────────────── */
@media (max-width: 900px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .testi-grid    { grid-template-columns: 1fr; }
  footer { padding: 0; }
}
@media (max-width: 640px) {
  .services-grid { grid-template-columns: 1fr; }
  .filter-bar    { gap: 0.4rem; }
  .f-btn         { font-size: 0.7rem; padding: 0.4rem 0.85rem; }
  .ext-links     { flex-direction: column; }
  .ext-card      { min-width: unset; width: 100%; }
}

/* ── TOUCH DEVICES — disable custom cursor ──────────────── */
@media (hover: none) {
  .cursor, .cursor-follower { display: none !important; }
  body { cursor: auto !important; }
  button { cursor: pointer !important; }
}

/* ── NAVBAR MOBILE FIXES ────────────────────────────────── */
@media (max-width: 900px) {
  .nav-cta .cta-text { display: none; }
  .nav-cta { padding: 0.5rem 0.75rem; }
  #navbar { padding: 0.85rem 1.5rem; }
  #navbar.scrolled { padding: 0.65rem 1.5rem; }
}
@media (max-width: 480px) {
  .nav-brand { font-size: 1.1rem; }
}

