/* =============================================
   ASHIK ABRAR NAEEM — Personal Academic Website
   Aesthetic: Editorial Academic · Refined · Light
   ============================================= */

/* ---------- CSS Variables ---------- */
:root {
  --bg:          #F7F4EF;
  --bg-alt:      #EEEAE3;
  --surface:     #FFFFFF;
  --ink:         #1A1614;
  --ink-muted:   #5A534E;
  --ink-light:   #8A847E;
  --accent:      #1A3A6B; /* Deep Navy */
  --accent-warm: #B8914A; /* Sand/Gold */
  --accent-light:#D4B896;
  --rule:        #D5CFC8;
  --serif:       'Cormorant Garamond', Georgia, serif;
  --sans:        'DM Sans', system-ui, sans-serif;
  --mono:        'DM Mono', monospace;
  --nav-h:       68px;
  --max-w:       1180px;
  --trans:       cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

html { scroll-behavior: smooth; font-size: 16px; overflow-x: hidden; }

body {
  overflow-x: hidden;   /* ← add this */
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }

/* ---------- Utility ---------- */
.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}

/* ---------- Section Label ---------- */
.section-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-warm);
  padding-bottom: 1.5rem;
  margin-bottom: 0;
  display: block;
}

/* ---------- Section Row ---------- */
.section-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 4.5rem;
  align-items: start;
  padding: 3.5rem 0;
  border-top: 1px solid var(--rule);
}

.section-row:last-child {
  border-bottom: 1px solid var(--rule);
}

.row-left {
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
}

.row-title {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 400;
  font-style: italic;
  color: var(--ink);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

/* ---------- Scroll Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s var(--trans), transform 0.75s var(--trans);
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* =============================================
   NAVIGATION
   ============================================= */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(247, 244, 239, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, box-shadow 0.3s;
  height: var(--nav-h);
}

#navbar.scrolled {
  border-bottom-color: var(--rule);
  box-shadow: 0 2px 24px rgba(26,20,14,0.06);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 0.2rem;
}

.nav-links a {
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted);
  padding: 0.4rem 0.85rem;
  border-radius: 2px;
  transition: color 0.2s, background 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
  background: rgba(26, 58, 107, 0.06);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s, opacity 0.3s;
}

/* =============================================
   HERO
   ============================================= */
#hero {
  min-height: 100vh;
  padding-top: var(--nav-h);
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 4rem;
  align-items: center;
  max-width: var(--max-w);
  margin: 0 auto;
  padding-left: 2rem;
  padding-right: 2rem;
  position: relative;
}

/*
  Hero background: warm parchment that bridges into the
  cream-toned section palette below.
*/
#hero::before {
  content: "";
  position: absolute;
  top: 0; left: -50vw; right: -50vw; bottom: 0;
  background-color: #EDE9E1;
  z-index: -2;
}

/* Subtle vertical grid — same warm navy tint */
.hero-bg-lines {
  position: absolute;
  top: 0; left: -50vw; right: -50vw; bottom: 0;
  pointer-events: none;
  z-index: -1;
  background-image:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent calc(100% / 12 - 1px),
      rgba(26, 58, 107, 0.04) calc(100% / 12 - 1px),
      rgba(26, 58, 107, 0.04) calc(100% / 12)
    );
}

/* Gradient bridge from hero colour (#EDE9E1) to section bg (#F7F4EF) */
#hero::after {
  content: "";
  position: absolute;
  bottom: 0; left: -50vw; right: -50vw;
  height: 80px;
  background: linear-gradient(to bottom, transparent, var(--bg));
  z-index: -1;
  pointer-events: none;
}

.hero-content { position: relative; z-index: 1; }

.hero-label {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-warm);
  margin-bottom: 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.hero-label::before {
  content: '';
  display: inline-block;
  width: 32px;
  height: 1px;
  background: var(--accent-warm);
}

.hero-name {
  font-family: var(--serif);
  font-size: clamp(3.5rem, 8vw, 6.2rem);
  font-weight: 300;
  line-height: 1.0;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin-bottom: 1.6rem;
}

.hero-name em {
  font-style: italic;
  color: var(--accent);
  display: block;
}

.hero-tagline {
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--ink-muted);
  letter-spacing: 0.02em;
  line-height: 1.8;
  margin-bottom: 2.5rem;
  max-width: 520px;
}

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

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  background: var(--accent);
  color: #fff;
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  transition: background 0.25s, transform 0.2s;
}
.btn-primary:hover {
  background: #0F2A52;
  transform: translateY(-1px);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  padding: 0.75rem 2rem;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  transition: background 0.25s, color 0.25s, transform 0.2s;
}
.btn-ghost:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

.hero-aside { position: relative; z-index: 1; }

.profile-panel {
  background: #DDD9D0;
  border: 1px solid rgba(213, 207, 200, 0.7);
  border-radius: 8px;
  box-shadow:
    0 2px 8px rgba(26,20,14,0.04),
    0 12px 48px rgba(26,20,14,0.09);
  overflow: hidden;
  max-width: 350px;
  margin: 0 auto;
  aspect-ratio: 1 / 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.profile-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
}

/* =============================================
   SECTIONS
   ============================================= */
.section { padding: 5rem 0; position: relative; }
.section-alt { background: var(--bg-alt); }

/* =============================================
   RESEARCH
   ============================================= */
.interest-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.interest-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.4rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}

.interest-card:hover {
  border-color: var(--accent-light);
  box-shadow: 0 4px 24px rgba(26,58,107,0.08);
  transform: translateY(-2px);
}

.interest-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(26,58,107,0.07);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 0.85rem;
}

.interest-title {
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--ink);
  line-height: 1.45;
}

.research-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-left: 4px solid var(--accent);
  border-radius: 0 4px 4px 0;
  padding: 2.5rem 2.5rem 2.5rem 2rem;
}

.research-tag {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-warm);
  margin-bottom: 0.75rem;
}

.research-title {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 1rem;
  line-height: 1.3;
}

.research-supervisor {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.875rem;
  color: var(--ink-muted);
  margin-bottom: 1.25rem;
}
.research-supervisor i {
  color: var(--accent-warm);
  margin-top: 0.1rem;
  flex-shrink: 0;
}

.research-desc {
  font-size: 0.93rem;
  color: var(--ink-muted);
  line-height: 1.8;
}

/* =============================================
   PUBLICATIONS
   ============================================= */
.pub-list {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.pub-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--rule);
}
.pub-item:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.pub-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.75rem 2rem;
}

.pub-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.25rem;
}

.pub-tag {
  font-family: var(--mono);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
}
.pub-tag.journal    { background: rgba(26,58,107,0.08); color: var(--accent); }
.pub-tag.conference { background: rgba(184,145,74,0.12); color: #9A7635; }
.pub-tag.preprint   { background: var(--surface); color: var(--ink-light); border: 1px solid var(--rule); }

.pub-year {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--ink-light);
}

.pub-title {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.3;
}

.pub-authors {
  font-size: 0.9rem;
  color: var(--ink-muted);
}
.pub-authors strong {
  color: var(--accent);
  font-weight: 600;
}

.pub-venue {
  font-style: italic;
  font-size: 0.85rem;
  color: var(--ink-light);
  margin-bottom: 0.5rem;
}

.pub-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.25rem;
}
.pub-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  transition: color 0.2s;
}
.pub-links a:hover { color: var(--accent-warm); }

/* =============================================
   EXPERIENCE TIMELINE
   ============================================= */
.timeline {
  position: relative;
  padding: 2rem 0 3rem;
}

/* Centre vertical rule — fades at top and bottom */
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1.5px;
  transform: translateX(-50%);
  background: linear-gradient(
    to bottom,
    transparent,
    var(--rule) 6%,
    var(--rule) 88%,
    transparent
  );
}

.tl-item {
  position: relative;
  width: calc(50% - 3rem);
  padding-bottom: 3rem;
}
.tl-item:last-child { padding-bottom: 0; }

.tl-right { margin-left: calc(50% + 3rem); }
.tl-left  { margin-left: 0; }

/* Concentric-ring dot sitting on the centre line */
.tl-dot {
  position: absolute;
  top: 1.15rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--accent-warm);
  box-shadow:
    0 0 0 4px rgba(184, 145, 74, 0.13),
    0 0 0 7px rgba(184, 145, 74, 0.05);
  z-index: 2;
}
.tl-right .tl-dot { left:  calc(-3rem - 6px); }
.tl-left  .tl-dot { right: calc(-3rem - 6px); }

/* Card */
.tl-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.6rem 1.75rem;
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}
.tl-card:hover {
  border-color: var(--accent-light);
  box-shadow: 0 6px 28px rgba(26,58,107,0.08);
  transform: translateY(-2px);
}

.tl-date {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.55rem;
}

.tl-role {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.25;
  margin-bottom: 0.3rem;
}

.tl-company {
  font-size: 0.875rem;
  color: var(--ink-muted);
  margin-bottom: 0.85rem;
}

.tl-desc {
  font-size: 0.86rem;
  color: var(--ink-muted);
  line-height: 1.75;
}

/* =============================================
   PROJECTS
   ============================================= */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: box-shadow 0.3s, transform 0.3s, border-color 0.3s;
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-warm));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--trans);
}

.project-card:hover {
  box-shadow: 0 8px 40px rgba(26,20,14,0.1);
  transform: translateY(-4px);
  border-color: transparent;
}

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

.project-num {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--accent-warm);
  letter-spacing: 0.12em;
}

.project-title {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.3;
}

.project-desc {
  font-size: 0.855rem;
  color: var(--ink-muted);
  line-height: 1.75;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.project-tags span {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(26,58,107,0.07);
  padding: 0.25rem 0.6rem;
  border-radius: 2px;
}

/* =============================================
   BACKGROUND
   ============================================= */
.edu-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 2rem;
}

.edu-period {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  color: var(--accent-warm);
  margin-bottom: 0.5rem;
}

.edu-degree {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.edu-institution {
  font-size: 0.9rem;
  color: var(--ink-muted);
  margin-bottom: 1rem;
}

.edu-details {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.84rem;
  color: var(--ink-muted);
}
.edu-details strong { color: var(--accent); }

.coursework-block {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.5rem;
}

.cw-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cw-grid span {
  font-size: 0.82rem;
  color: var(--ink-muted);
  background: var(--bg);
  border: 1px solid var(--rule);
  border-radius: 2px;
  padding: 0.3rem 0.75rem;
  transition: border-color 0.2s, color 0.2s;
}
.cw-grid span:hover {
  border-color: var(--accent-light);
  color: var(--accent);
}

.skills-list {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  overflow: hidden;
}

.skill-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--rule);
}
.skill-row:last-child { border-bottom: none; }

.skill-cat {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-light);
  padding-top: 0.15rem;
}

.skill-vals {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.skill-vals span {
  font-size: 0.82rem;
  color: var(--ink);
  background: var(--bg-alt);
  border: 1px solid var(--rule);
  padding: 0.25rem 0.7rem;
  border-radius: 2px;
}

/* =============================================
   RECOGNITION
   ============================================= */
.achieve-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.achieve-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 1.25rem 1.5rem;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.achieve-item:hover {
  border-color: var(--accent-light);
  box-shadow: 0 3px 16px rgba(26,58,107,0.06);
}

.achieve-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(184, 145, 74, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-warm);
  font-size: 0.8rem;
  flex-shrink: 0;
}

.achieve-title {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink);
}
.achieve-sub {
  font-size: 0.8rem;
  color: var(--ink-light);
  margin-top: 0.2rem;
}

/* =============================================
   PEOPLE
   ============================================= */
.ref-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.ref-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 3px;
  padding: 2rem;
  transition: box-shadow 0.25s, border-color 0.25s;
}
.ref-card:hover {
  box-shadow: 0 6px 32px rgba(26,58,107,0.08);
  border-color: var(--accent-light);
}

.ref-role {
  font-family: var(--mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-warm);
  margin-bottom: 0.75rem;
}

.ref-name {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.ref-title {
  font-size: 0.875rem;
  color: var(--ink-muted);
}
.ref-inst {
  font-size: 0.84rem;
  color: var(--ink-light);
  margin-bottom: 1.25rem;
}

.ref-email {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
  transition: color 0.2s;
}
.ref-email:hover { color: var(--accent-warm); }
.ref-email i { font-size: 0.7rem; }

/* =============================================
   CONTACT
   ============================================= */
.contact-section { background: var(--accent); }
.contact-inner { text-align: center; }

.contact-section .section-label {
  color: rgba(255,255,255,0.45);
  padding-bottom: 1rem;
}

.contact-heading {
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 500;
  color: #fff;
  line-height: 1.2;
  margin-bottom: 1.25rem;
}

.contact-subtext {
  font-size: 1rem;
  color: rgba(255,255,255,0.7);
  max-width: 520px;
  margin: 0 auto 2.5rem;
  line-height: 1.8;
}

.contact-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem; /* Slightly increased gap so sliding tabs don't touch */
}

/* --- NEW SLIDING TAB LOGIC --- */

.contact-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* The visible tab (matches your old .contact-btn style) */
.contact-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 2rem;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.3);
  color: #fff;
  font-family: var(--sans);
  font-size: 0.84rem;
  font-weight: 400;
  border-radius: 2px;
  letter-spacing: 0.04em;
  min-width: 160px;
  position: relative;
  z-index: 2;
  cursor: pointer;
  transition: background 0.3s, border-color 0.3s, transform 0.2s;
}

.btn-label {
  white-space: nowrap;
}

/* Hover effect for the main tab */
.contact-wrapper:hover .contact-tab {
  background: rgba(255,255,255,0.22);
  border-color: rgba(255,255,255,0.6);
}

/* The hidden link that slides down (matches your old .btn-value style) */
.contact-slide {
  position: absolute;
  top: 100%;
  left: 50%;
  
  /* Start slightly higher up and invisible */
  transform: translate(-50%, -15px);
  opacity: 0;
  visibility: hidden;
  
  /* Styling to match your transparent theme */
  background: rgba(0, 0, 0, 0.25); 
  border: 1px solid rgba(255,255,255,0.2);
  border-top: none;
  backdrop-filter: blur(4px);
  color: #fff;
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  padding: 0.8rem 1.5rem;
  border-radius: 0 0 4px 4px;
  text-decoration: none;
  white-space: nowrap;
  z-index: 1;
  
  /* Smooth animation */
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Hover effect on the slide itself */
.contact-slide:hover {
  background: rgba(0, 0, 0, 0.4);
}

/* Trigger the slide down when hovering the wrapper */
.contact-wrapper:hover .contact-slide {
  transform: translate(-50%, 0);
  opacity: 1;
  visibility: visible;
}

/* =============================================
   FOOTER
   ============================================= */
footer {
  background: #0F2040;
  padding: 1.5rem 2rem;
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.4);
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  #hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: calc(var(--nav-h) + 4rem);
    padding-bottom: 4rem;
  }
  .hero-aside { order: -1; }
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-h);
    left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--rule);
    padding: 1rem 2rem;
    gap: 0;
  }
  .nav-links.open a { padding: 0.75rem 0; border-bottom: 1px solid var(--rule); }
  .hamburger { display: flex; }

  .section-row {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 2.5rem 0;
  }
  .row-left { position: static; }
  .row-title { font-size: 1.4rem; font-style: italic; }

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

  .hero-name { font-size: clamp(2.8rem, 12vw, 5rem); }
  .profile-panel { max-width: 280px; }

  .btn-label { display: none; }
  .btn-value {
    position: static;
    transform: none;
    opacity: 1;
    padding: 0;
    font-size: 0.72rem;
  }
  .contact-btn { min-width: auto; padding: 0.85rem 1.4rem; }

   /* Timeline collapses to a single left-aligned column */
  .timeline::before { left: 1rem; transform: none; }
  .tl-item  { width: calc(100% - 2.5rem); margin-left: 2.5rem !important; }
  .tl-right .tl-dot,
  .tl-left  .tl-dot { left: calc(-2.5rem - 6px); right: auto; }
}

@media (max-width: 480px) {
  .section { padding: 3.5rem 0; }
  .section-inner { padding: 0 1.5rem; }
  .footer-inner { flex-direction: column; text-align: center; }
}

/* =============================================
   HERO STAGGER REVEAL DELAYS
   ============================================= */
.hero-label   { transition-delay: 0.05s; }
.hero-name    { transition-delay: 0.15s; }
.hero-tagline { transition-delay: 0.25s; }
.hero-cta     { transition-delay: 0.45s; }
.hero-aside   { transition-delay: 0.55s; }
