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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

img {
  display: block;
  max-width: 100%;
}

a {
  text-decoration: none;
}

ul {
  list-style: none;
}

:root {
  /* Base colors */
  --bg-primary: #080c18;
  --bg-secondary: #0e1426;
  --bg-tertiary: #161d34;
  --surface: rgba(255, 255, 255, .03);
  --surface-hover: rgba(255, 255, 255, .06);
  --border: rgba(255, 255, 255, .06);
  --border-glow: rgba(255, 193, 7, .12);

  /* Brand (silver/chrome) */
  --primary: #cfcfd8;
  --primary-dark: #ffffff;
  --primary-dim: #cfcfd816;
  --primary-dim-strong: #cfcfd824;
  --chrome: linear-gradient(135deg, #fff 0%, #dcdce2 30%, #9a9aa6 65%, #d4d4dc 100%);
  --on-chrome: #0a0a0c;

  /* Accent colors – unified */
  --gold: #fbbf24;
  --gold-dim: rgba(251, 191, 36, .12);
  --gold-glow: 0 0 30px rgba(251, 191, 36, .12);
  --amber: #f59e0b;
  /* was duplicate; kept this one */
  --amber-dim: rgba(245, 158, 11, .12);
  --rose: #f472b6;
  --emerald: #34d399;
  --sky: #38bdf8;

  /* Signal colors */
  --success: #34d399;
  --success-dim: #34d3991c;
  --violet: #a78bfa;
  --violet-dim: #a78bfa1c;

  /* Cyan / purple / pink – added for scroll-progress & others */
  --cyan: #00e5ff;
  --cyan-dim: rgba(0, 229, 255, .08);
  --cyan-dim-strong: rgba(0, 229, 255, .14);
  --cyan-glow: 0 0 40px rgba(0, 229, 255, .06);
  --purple: #a78bfa;
  --pink: #f472b6;

  /* Text */
  --text-primary: #d4dbe8;
  --text-secondary: #8892b0;
  --text-muted: #495670;
  --text-bright: #eef2f9;

  /* Fonts & sizing */
  --mono: 'JetBrains Mono', monospace;
  --sans: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --nav-h: 72px;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 20px 60px rgba(0, 0, 0, .6);
  --shadow-glow: 0 8px 40px rgba(251, 191, 36, .06);
  --radius-lg: 20px;
  --radius-md: 14px;
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, .35);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, .45);
  --shadow-lg: 0 26px 64px rgba(0, 0, 0, .55);
  --container: 1240px;
}

body.light {
  --bg-primary: #f3f6fc;
  --bg-secondary: #ffffff;
  --bg-tertiary: #e8edf6;
  --surface: rgba(255, 255, 255, .8);
  --surface-hover: rgba(255, 255, 255, .95);
  --border: rgba(0, 0, 0, .08);
  --border-glow: rgba(255, 193, 7, .15);
  --text-primary: #1a2332;
  --text-secondary: #4a5568;
  --text-muted: #8892a0;
  --text-bright: #0a0f1a;
  --shadow: 0 20px 60px rgba(0, 20, 40, .08);
  --shadow-glow: 0 8px 40px rgba(255, 193, 7, .08);
  --cyan-dim: rgba(0, 150, 255, .08);
  --cyan-dim-strong: rgba(0, 150, 255, .14);
  --cyan-glow: 0 0 40px rgba(0, 150, 255, .05);
}

/* ── SCROLL PROGRESS ── */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--cyan), var(--purple), var(--pink));
  z-index: 1001;
  width: 0%;
  transition: width .1s linear;
  border-radius: 0 99px 99px 0;
  box-shadow: 0 0 20px rgba(0, 229, 255, .15);
}

/* ── BASE ── */
body {
  font-family: var(--sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  transition: background .4s, color .4s;
  overflow-x: hidden;
}

::-webkit-scrollbar {
  width: 5px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--cyan);
  border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--purple);
}

::selection {
  background: var(--cyan);
  color: #06060f;
}

/* BG mesh */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(0, 229, 255, .06) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(167, 139, 250, .04) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(244, 114, 182, .03) 0%, transparent 50%);
  pointer-events: none;
}

body.light::before {
  background:
    radial-gradient(ellipse at 20% 50%, rgba(0, 150, 255, .05) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(167, 139, 250, .04) 0%, transparent 50%);
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  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)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: .5;
}

/* ── CURSOR GLOW ── */
#cursor-glow {
  position: fixed;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(circle, rgba(0, 229, 255, .06) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  transition: left .15s, top .15s;
}

body.light #cursor-glow {
  background: radial-gradient(circle, rgba(0, 150, 255, .04) 0%, transparent 70%);
}

@media (max-width: 768px) {
  #cursor-glow {
    display: none;
  }
}

/* ── NAVBAR ── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  z-index: 1000;
  background: rgba(6, 6, 15, .75);
  backdrop-filter: blur(20px) saturate(1.4);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
}

body.light .navbar {
  background: rgba(240, 242, 250, .8);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 1.8rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.nav-logo a {
  font-family: var(--mono);
  font-weight: 800;
  font-size: 1rem;
  color: var(--text-bright);
  letter-spacing: -.5px;
  position: relative;
}

.nav-logo a span {
  color: var(--text-secondary);
  font-weight: 400;
}

.nav-logo a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60%;
  height: 2px;
  background: linear-gradient(90deg, var(--text-bright), transparent);
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color .3s;
  position: relative;
  padding: .3rem 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--cyan);
  transition: width .3s;
  border-radius: 99px;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-bright);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: .6rem;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .95rem;
  transition: all .3s;
}

.icon-btn:hover {
  background: var(--cyan-dim-strong);
  border-color: var(--cyan);
  color: var(--chrome);
  transform: scale(1.05);
}

.hamburger {
  display: none;
}

.mobile-nav {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0;
  right: 0;
  background: rgba(6, 6, 15, .95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  z-index: 999;
  padding: 1.8rem;
  flex-direction: column;
  gap: 1rem;
  transform: translateY(-120%);
  transition: transform .4s cubic-bezier(.4, 0, .2, 1);
}

body.light .mobile-nav {
  background: rgba(240, 242, 250, .95);
}

.mobile-nav.open {
  transform: translateY(0);
}

.mobile-nav a {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: .6rem 0;
  border-bottom: 1px solid var(--border);
  transition: color .3s;
}

.mobile-nav a:hover {
  color: var(--cyan);
}

/* ── WRAPPER ── */
.wrapper {
  position: relative;
  z-index: 1;
  padding-top: var(--nav-h);
}

/* ── SECTION COMMON ── */
.section {
  padding: 6rem 1.8rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), var(--border), transparent);
  max-width: 1200px;
  margin: 0 auto;
}

.sec-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: .6rem;
  background: var(--surface);
  padding: .25rem 1rem;
  border-radius: 99px;
  border: 1px solid var(--border);
}

.sec-eyebrow::before {
  content: '✦';
  font-size: .5rem;
  color: var(--cyan);
}

.sec-title {
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  font-weight: 800;
  color: var(--text-bright);
  line-height: 1.1;
  letter-spacing: -.02em;
  margin-bottom: 2.5rem;
  position: relative;
}

.sec-title::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--cyan), var(--gold));
  border-radius: 99px;
}

/* ── HERO ── */
#home {
  padding: 1rem 1.8rem;
  max-width: 1200px;
  margin: 0 auto;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 3rem;
  align-items: center;
  width: 100%;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  background: var(--primary-dim);
  color: var(--primary);
  font-family: var(--sans);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: .5rem 1.05rem;
  border-radius: 999px;
  margin-bottom: 1.6rem;
}

.hero-eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
}

.hero-name {
  font-family: var(--sans);
  font-size: clamp(2.3rem, 4.6vw, 3.7rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -.02em;
  color: var(--text-bright);
  margin-bottom: 1.2rem;
}

.hero-sub {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  color: var(--text-secondary);
  max-width: 48ch;
  margin-bottom: 2.2rem;
  min-height: 3.4em;
}

.hero-sub .role {
  color: var(--text-bright);
  font-weight: 700;
}

.hero-sub .cur {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--primary);
  margin-left: 2px;
  vertical-align: -.15em;
  animation: blink .85s step-end infinite;
}

.hero-cta {
  display: flex;
  gap: .85rem;
  flex-wrap: wrap;
  margin-bottom: 2.8rem;
}

.hero-stats {
  display: flex;
  gap: 2.2rem;
  flex-wrap: wrap;
  padding-top: 1.8rem;
  border-top: 1px solid var(--border);
}

.stat-chip {
  display: flex;
  flex-direction: column;
  cursor: default;
}

.stat-chip-num {
  font-family: var(--sans);
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--text-bright);
  line-height: 1;
}

.stat-chip-lbl {
  font-size: .75rem;
  color: var(--text-muted);
  margin-top: .35rem;
  font-weight: 500;
}

/* Hero photo panel */
.hero-photo-col {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.photo-panel {
  position: relative;
  width: 100%;
  max-width: 400px;
  aspect-ratio: 4 / 4.6;
}

.photo-panel-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, var(--bg-tertiary), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.photo-panel-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: .5;
}

.photo-panel-bg::after {
  content: '';
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(207, 207, 216, .35), transparent 70%);
  top: -60px;
  right: -60px;
  filter: blur(10px);
}

.photo-panel-photo {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 1;
}

.photo-panel-photo img {
  width: 100%;
  height: 100%;
  object-fit: fill;
  border-radius: 20px;
  filter: drop-shadow(0 20px 30px rgba(0, 0, 0, .35));
}

.avatar-fallback {
  width: 100%;
  height: 100%;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 4.5rem;
  color: var(--text-muted);
}

.photo-badge {
  position: absolute;
  bottom: 18px;
  left: 18px;
  background: rgba(255, 255, 255, .96);
  padding: .6rem 1.05rem;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 700;
  color: var(--success);
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  box-shadow: var(--shadow-md);
  z-index: 2;
}

.photo-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 3px var(--success-dim);
}

/* Buttons, tags */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .7rem 1.4rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .88rem;
  transition: .25s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-outline {
  background: var(--surface);
  color: var(--text-secondary);
  border: 1.5px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--cyan);
  color: var(--text-bright);
  transform: translateY(-2px);
}

.tag {
  font-size: .68rem;
  font-weight: 700;
  padding: .28rem .68rem;
  border-radius: 6px;
  letter-spacing: .01em;
}

.tag-cyan {
  color: var(--cyan);
  border-color: rgba(0, 229, 255, .2);
  background: rgba(0, 229, 255, .06);
}

.tag-purple {
  color: var(--purple);
  border-color: rgba(167, 139, 250, .2);
  background: rgba(167, 139, 250, .06);
}

.tag-green {
  color: var(--emerald);
  border-color: rgba(52, 211, 153, .2);
  background: rgba(52, 211, 153, .06);
}

.tag-orange {
  color: var(--amber);
  border-color: rgba(245, 158, 11, .2);
  background: rgba(245, 158, 11, .06);
}

/* ── ABOUT ── */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3.5rem;
  align-items: start;
}

.about-text p {
  color: var(--text-secondary);
  font-size: .95rem;
  line-height: 1.85;
  margin-bottom: 1.2rem;
}

.about-text b {
  color: var(--text-bright);
  font-weight: 600;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .8rem;
  margin-top: 2rem;
}

.a-stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.2rem;
  text-align: center;
  transition: all .3s;
}

.a-stat:hover {
  border-color: var(--cyan);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.a-stat-n {
  font-family: var(--mono);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-bright);
  line-height: 1;
  margin-bottom: .2rem;
}

.a-stat-l {
  font-size: .7rem;
  color: var(--text-muted);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.info-panel {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.info-panel-head {
  padding: .8rem 1.25rem;
  background: rgba(255, 255, 255, .03);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--mono);
  font-size: .68rem;
  color: var(--cyan);
  letter-spacing: .12em;
  text-transform: uppercase;
}

.info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: .65rem 1.25rem;
  border-bottom: 1px solid var(--border);
  font-size: .82rem;
}

.info-row:last-child {
  border-bottom: none;
}

.info-k {
  color: var(--text-muted);
  flex-shrink: 0;
  font-size: .75rem;
}

.info-v {
  color: var(--text-bright);
  text-align: right;
  font-weight: 500;
}

.info-v.avail {
  color: var(--success);
}

.clock-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: .65rem 1.25rem;
  background: var(--surface);
  border-top: 1px solid var(--border);
}

.clock-label {
  font-size: .68rem;
  color: var(--text-muted);
  letter-spacing: .1em;
  text-transform: uppercase;
  font-family: var(--mono);
}

#bd-clock {
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: .05em;
}

/* ── PROJECTS ── */
.filter-tabs {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.filter-tab {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: .4rem 1.2rem;
  font-size: .72rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all .3s;
  letter-spacing: .06em;
}

.filter-tab:hover {
  border-color: var(--cyan);
  color: var(--text-bright);
}

.filter-tab.active {
  background: var(--cyan);
  border-color: var(--cyan);
  color: #06060f;
}

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

.proj-card {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all .4s;
  position: relative;
}

.proj-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--purple), var(--pink));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s;
}

.proj-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-6px);
  box-shadow: var(--shadow-glow);
}

.proj-card:hover::before {
  transform: scaleX(1);
}

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

.proj-thumb {
  width: 100%;
  height: 170px;
  object-fit: cover;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
}

.proj-thumb-placeholder {
  height: 170px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 2.8rem;
}

.proj-body {
  padding: 1.4rem 1.6rem 1.6rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.proj-type {
  font-family: var(--mono);
  font-size: .6rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: .4rem;
}

.proj-type.research {
  color: var(--purple);
}

.proj-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: .5rem;
  line-height: 1.3;
}

.proj-desc {
  font-size: .82rem;
  color: var(--text-secondary);
  line-height: 1.7;
  flex: 1;
  margin-bottom: 1rem;
}

.proj-accuracy {
  font-family: var(--mono);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--emerald);
  line-height: 1;
  margin: .3rem 0 .8rem;
}

.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-bottom: 1rem;
}

.proj-links {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  margin-top: .2rem;
}

.proj-link {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  font-size: .72rem;
  font-weight: 600;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  padding: .35rem .8rem;
  border-radius: 6px;
  transition: all .3s;
}

.proj-link:hover {
  color: var(--cyan);
  border-color: var(--cyan);
  background: var(--surface);
}

.res-badge {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  background: rgba(167, 139, 250, .1);
  border: 1px solid rgba(167, 139, 250, .2);
  color: var(--purple);
  font-size: .6rem;
  font-weight: 700;
  padding: .2rem .7rem;
  border-radius: 4px;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .5rem;
  align-self: flex-start;
}

.show-more-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 3rem;
}

.show-more-hint {
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--text-muted);
  margin-bottom: .8rem;
}

.show-more-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: .7rem 2.2rem;
  border-radius: 50px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: .82rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all .3s;
  display: inline-flex;
  align-items: center;
  gap: .6rem;
}

.show-more-btn:hover {
  border-color: var(--cyan);
  color: var(--text-bright);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.proj-count-pill {
  background: var(--cyan);
  color: #06060f;
  font-size: .65rem;
  font-weight: 700;
  padding: .15rem .5rem;
  border-radius: 40px;
  margin-left: .2rem;
}

.btn-icon {
  transition: transform .3s;
}

.show-more-btn.expanded .btn-icon {
  transform: rotate(180deg);
}

/* ── SKILLS ── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
}

.skill-card {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem;
  transition: all .35s;
}

.skill-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-5px);
  box-shadow: var(--shadow-glow);
}

.skill-header {
  display: flex;
  align-items: center;
  gap: .8rem;
  margin-bottom: 1.2rem;
  border-bottom: 1px dashed var(--border);
  padding-bottom: .8rem;
}

.skill-icon {
  width: 44px;
  height: 44px;
  background: var(--cyan-dim);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--cyan);
  transition: all .3s;
}

.skill-card:hover .skill-icon {
  background: var(--cyan);
  color: #06060f;
  transform: scale(1.05);
}

.skill-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-bright);
}

.skill-items {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.skill-tag {
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  padding: .3rem .9rem;
  border-radius: 40px;
  font-size: .72rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all .3s;
}

.skill-tag:hover {
  border-color: var(--cyan);
  color: var(--text-bright);
  background: var(--surface);
}

/* ── EDUCATION (merged – no duplicate .sec‑*) ── */
#education {
  padding: 2.5rem 2rem 3rem;
  transition: background .4s, border-color .4s;
}

#education:hover {
  border-color: var(--border-glow);
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 2.8rem;
  padding-left: .5rem;
}

.timeline-item {
  position: relative;
  padding: 1.2rem 1.8rem 1.2rem 3.8rem;
  border-left: 2px solid var(--border);
  transition: border-color .3s, background .3s;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-left: .5rem;
  cursor: default;
}

.timeline-item:hover {
  border-left-color: var(--cyan);
  background: var(--cyan-dim);
}

.timeline-item:last-child {
  border-left-color: transparent;
}

.timeline-item:last-child:hover {
  border-left-color: var(--cyan);
}

.timeline-dot {
  position: absolute;
  left: -7px;
  top: 1.6rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 2px solid var(--border);
  transition: all .4s;
  z-index: 1;
}

.timeline-item:hover .timeline-dot {
  background: var(--cyan);
  border-color: var(--cyan);
  box-shadow: 0 0 20px rgba(0, 229, 255, .25);
  transform: scale(1.15);
}

.timeline-item:last-child .timeline-dot {
  background: var(--gold);
  border-color: var(--gold);
}

.timeline-item:last-child:hover .timeline-dot {
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 20px rgba(251, 191, 36, .25);
}

.edu-degree {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-bright);
  letter-spacing: -.01em;
  margin-bottom: .05rem;
}

.edu-school {
  font-size: .85rem;
  color: var(--text-secondary);
  margin-bottom: .1rem;
}

.edu-year {
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--text-muted);
  letter-spacing: .02em;
}

.creds-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  margin-bottom: 2rem;
}

.cred-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.4rem 1.4rem 1.2rem;
  transition: all .35s;
  backdrop-filter: blur(8px);
}

.cred-card:hover {
  border-color: var(--border-glow);
  background: var(--cyan-dim);
  transform: translateY(-3px);
  box-shadow: var(--cyan-glow);
}

.cred-card h4 {
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  margin-bottom: .6rem;
}

.badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--cyan-dim);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: .7rem;
  font-weight: 500;
  padding: .25rem .85rem;
  border-radius: 40px;
  transition: all .3s;
  letter-spacing: .01em;
  white-space: nowrap;
  cursor: pointer;
}

.badge-list a:hover .badge {
  color: var(--text-bright);
  border-color: var(--cyan);
  transform: scale(1.04);
  background: var(--cyan-dim-strong);
}

.badge:hover {
  color: var(--text-bright);
  border-color: var(--cyan);
  transform: scale(1.04);
}

.badge-list a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: var(--cyan);
}

.extracard {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.8rem;
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  transition: all .35s;
}

.extracard:hover {
  border-color: var(--border-glow);
  background: var(--surface-hover);
  box-shadow: var(--shadow-glow);
}

.extracard i {
  color: var(--gold);
  font-size: 1.8rem;
  flex-shrink: 0;
  margin-top: .1rem;
  transition: transform .3s;
}

.extracard:hover i {
  transform: scale(1.1) rotate(-4deg);
}

.extracard div {
  flex: 1;
}

.extracard h4 {
  font-weight: 700;
  font-size: .95rem;
  color: var(--text-bright);
  margin-bottom: .3rem;
}

.extracard p {
  font-size: .82rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 0;
}

.extracard p br {
  display: block;
  content: '';
  margin-top: .15rem;
}

/* ── REVEAL (single definition) ── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.4, 0, .2, 1);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

.h-anim {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp .8s ease forwards;
}

.h-anim:nth-child(1) {
  animation-delay: .05s;
}

.h-anim:nth-child(2) {
  animation-delay: .1s;
}

.h-anim:nth-child(3) {
  animation-delay: .2s;
}

.h-anim:nth-child(4) {
  animation-delay: .3s;
}

.h-anim:nth-child(5) {
  animation-delay: .4s;
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

/* ── CONTACT ── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 3.5rem;
  align-items: start;
}

.clink {
  display: flex;
  align-items: center;
  gap: .9rem;
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .8rem 1.2rem;
  margin-bottom: .7rem;
  transition: all .3s;
}

.clink:hover {
  border-color: var(--gold-dim);
  transform: translateX(6px);
  box-shadow: var(--shadow-glow);
}

.clink-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--cyan-dim);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: .9rem;
  flex-shrink: 0;
  transition: all .3s;
}

.clink:hover .clink-icon {
  border: 2px solid var(--cyan-glow);
  color: var(--text-bright);
}

.clink-lbl {
  font-size: .6rem;
  color: var(--text-muted);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.clink-val {
  font-size: .8rem;
  color: var(--text-bright);
  font-weight: 500;
}

.clink-arr {
  color: var(--text-muted);
  margin-left: auto;
  font-size: .75rem;
  transition: all .3s;
}

.clink:hover .clink-arr {
  transform: translateX(4px);
  color: var(--cyan);
}

.socials {
  display: flex;
  gap: .6rem;
  margin-top: 1.5rem;
}

.soc {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 1rem;
  transition: all .3s;
}

.soc:hover {
  background: var(--cyan);
  border-color: var(--cyan);
  color: #06060f;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.form-box {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.form-box h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 1.5rem;
}

.form-box h3 i {
  color: var(--cyan);
  margin-right: .5rem;
}

.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: block;
  font-size: .68rem;
  color: var(--text-muted);
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .4rem;
  font-family: var(--mono);
}

.form-group input,
.form-group textarea {
  width: 100%;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: .7rem 1rem;
  color: var(--text-bright);
  font-family: var(--sans);
  font-size: .85rem;
  outline: none;
  transition: border-color .3s;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 20px var(--cyan-dim);
}

.form-group textarea {
  height: 110px;
  resize: vertical;
  min-height: 80px;
}

.form-group input[readonly],
.form-group textarea[readonly] {
  cursor: default;
  opacity: .7;
}

.form-alt-contact {
  margin-top: 1.5rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .8rem;
}

.form-alt-label {
  font-size: .68rem;
  color: var(--text-muted);
  letter-spacing: .08em;
  text-transform: uppercase;
  font-family: var(--mono);
}

/* ── BACK TO TOP ── */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--surface);
  backdrop-filter: blur(12px);
  color: var(--text-secondary);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 99;
  opacity: 0;
  visibility: hidden;
  border: 1px solid var(--border);
  transition: all .3s;
  box-shadow: var(--shadow);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--cyan-dim-strong);
  border-color: var(--cyan);
  color: var(--text-bright);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

/* ── FOOTER ── */
footer {
  background-color: #0b1424;
  border-top: 1px solid var(--border);
  padding: 2rem 6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  max-width: 100vw;
  margin: 0 auto;
}

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

.footer-copy span {
  color: #eef2f9;
}

.footer-right {
  display: flex;
  gap: 1.5rem;
}

.footer-right a {
  font-size: .78rem;
  color: var(--text-muted);
  transition: color .3s;
}

.footer-right a:hover {
  color: var(--cyan);
}

/* ================ 
FLOATING MENU 
=================== */
#float-toggle-wrap {
  position: fixed;
  bottom: 90px;
  right: 30px;
  z-index: 100;
}

#float-toggle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--surface);
  backdrop-filter: blur(12px);
  color: var(--text-secondary);
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 24px var(--cyan-dim);
  transition: all .3s;
}

#float-toggle:hover {
  transform: scale(1.05);
  border: 1px solid var(--cyan);
  background-color: var(--cyan-dim-strong);
  box-shadow: 0 8px 40px var(--cyan-dim);
}

#float-menu {
  position: fixed;
  bottom: 155px;
  right: 30px;
  z-index: 98;
  display: flex;
  flex-direction: column;
  gap: .6rem;
  align-items: flex-end;
  opacity: 0;
  pointer-events: none;
  transition: all .3s cubic-bezier(.4, 0, .2, 1);
  transform: translateY(12px);
}

#float-menu.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.float-wrap {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: .6rem;
}

.float-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: blur(12px);
  color: var(--text-secondary);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .3s;
  box-shadow: var(--shadow-sm);
}

.float-btn:hover {
  transform: scale(1.08);
  border-color: var(--cyan);
}

.float-btn.email:hover {
  background: #D44638;
  color: #fff;
  border-color: #D44638;
}

.float-btn.facebook:hover {
  background: #1877f2;
  color: #fff;
  border-color: #1877f2;
}

.float-btn.linkedin:hover {
  background: #0a66c2;
  color: #fff;
  border-color: #0a66c2;
}

.float-btn.github:hover {
  background: #333;
  color: #fff;
  border-color: #333;
}

.float-label {
  background: var(--surface);
  backdrop-filter: blur(12px);
  padding: 4px 14px;
  border-radius: 30px;
  font-size: .7rem;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
  border: 1px solid var(--border);
}

.float-wrap:hover .float-label {
  opacity: 1;
}

/* ===========
RESPONSIVE 
============== */

@media (max-width:1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2.5rem;
  }

  .hero-grid>div:first-child {
    order: 2;
  }

  .hero-grid>div:last-child {
    order: 1;
  }

  .hero-cta {
    justify-content: center;
  }

  .hero-stats {
    justify-content: center;
  }
  .hero-sub{
    text-align: left;
  }

  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .nav-links {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .mobile-nav {
    display: flex;
  }
}

@media (max-width:768px) {
  .section {
    padding: 4rem 1.2rem;
  }

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

  .hero-name {
    font-size: 2.4rem;
  }

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

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

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

  .about-stats {
    grid-template-columns: 1fr;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

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

  .extracard {
    flex-direction: column;
    text-align: center;
    padding: 1.2rem;
  }

  .filter-tabs {
    justify-content: center;
  }

  .form-box {
    padding: 1.2rem;
  }

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

  #float-toggle-wrap,
  #float-menu {
    right: 16px;
  }

  #float-toggle {
    width: 42px;
    height: 42px;
    font-size: 1rem;
  }

  .float-btn {
    width: 38px;
    height: 38px;
    font-size: .85rem;
  }

  #float-menu {
    bottom: 130px;
  }

  .back-to-top {
    bottom: 20px;
    right: 16px;
    width: 40px;
    height: 40px;
  }
}

@media (max-width:480px) {
  .hero-name {
    font-size: 1.8rem;
  }

  .sec-title {
    font-size: 1.4rem;
  }

  .section {
    padding: 3rem .8rem;
  }

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

  .proj-card .proj-thumb,
  .proj-card .proj-thumb-placeholder {
    height: 140px;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }

  .h-anim {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }

  #cursor-glow,
  .hero3d-canvas,
  #particles-canvas {
    display: none !important;
  }
}