/* ==========================================================================
   Vishnu Thaker — Portfolio · Clean Tech & Ocean
   ========================================================================== */

:root {
  /* Surfaces */
  --bg: #ffffff;
  --bg-alt: #f3f4f6;
  --bg-deep: #0f172a;
  --bg-deep-2: #1e3a8a;

  /* Text */
  --text: #1f2937;
  --text-muted: #4b5563;
  --text-soft: #6b7280;
  --text-on-deep: #f8fafc;
  --text-on-deep-muted: #cbd5e1;

  /* Accents */
  --primary: #2563eb;
  --primary-600: #1d4ed8;
  --primary-50: #eff6ff;
  --primary-100: #dbeafe;
  --secondary: #f59e0b;          /* warm amber — saves the design from monochrome */
  --secondary-soft: #fef3c7;
  --teal: #0d9488;
  --teal-soft: #ccfbf1;

  /* Lines & shadows */
  --border: #e5e7eb;
  --border-soft: #eef2f7;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 10px 30px -12px rgba(15, 23, 42, 0.12);
  --shadow-lg: 0 24px 50px -20px rgba(15, 23, 42, 0.18);
  --shadow-blue: 0 14px 30px -12px rgba(37, 99, 235, 0.45);

  /* Tokens */
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --container: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

/* Reset ------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; background: none; border: 0; color: inherit; cursor: pointer; }
::selection { background: var(--primary); color: #fff; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header / Glassmorphism Nav --------------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  background: rgba(255, 255, 255, 0.72);
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.header.is-scrolled {
  background: rgba(255, 255, 255, 0.88);
  border-bottom-color: var(--border-soft);
  box-shadow: var(--shadow-sm);
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 76px;
}
.logo {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  white-space: nowrap;
  transition: transform 0.25s var(--ease);
}
.logo:hover { transform: translateY(-1px); }
.logo:hover .logo__mark { transform: rotate(-6deg) scale(1.05); box-shadow: 0 16px 30px -10px rgba(37, 99, 235, 0.55); }
.logo__mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--bg-deep-2));
  display: grid;
  place-items: center;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: var(--shadow-blue);
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
}

.nav {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}
.nav__link {
  position: relative;
  padding: 10px 14px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-muted);
  border-radius: 8px;
  transition: color 0.25s ease, background 0.25s ease;
  white-space: nowrap;
}
.nav__link::before {
  content: '';
  position: absolute;
  inset: auto 14px 6px 14px;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}
.nav__link:hover { color: var(--primary); }
.nav__link:hover::before { transform: scaleX(1); }
.nav__link.is-active {
  color: var(--primary);
  background: var(--primary-50);
}
.nav__link.is-active::before {
  transform: scaleX(0.6);
  transform-origin: center;
}

.nav__cta {
  position: relative;
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--primary), var(--primary-600));
  color: #fff;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform 0.25s var(--ease), box-shadow 0.25s ease;
  box-shadow: var(--shadow-blue);
  overflow: hidden;
  isolation: isolate;
  white-space: nowrap;
  flex-shrink: 0;
}
.nav__cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.7s var(--ease);
  z-index: -1;
}
.nav__cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -10px rgba(37, 99, 235, 0.55);
}
.nav__cta:hover::before { transform: translateX(100%); }

/* Hamburger --------------------------------------------------------------- */
.hamburger {
  display: none;
  width: 42px;
  height: 42px;
  position: relative;
  border-radius: 10px;
  background: var(--bg-alt);
}
.hamburger span {
  position: absolute;
  left: 11px; right: 11px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.2s ease, top 0.3s var(--ease);
}
.hamburger span:nth-child(1) { top: 14px; }
.hamburger span:nth-child(2) { top: 20px; }
.hamburger span:nth-child(3) { top: 26px; }
.hamburger.is-open span:nth-child(1) { top: 20px; transform: rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; }
.hamburger.is-open span:nth-child(3) { top: 20px; transform: rotate(-45deg); }

.mobile-nav {
  position: fixed;
  inset: 76px 0 0 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 40px 24px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity 0.3s ease, transform 0.3s var(--ease);
}
.mobile-nav.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.mobile-nav__list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 360px;
  margin: 0 auto;
}
.mobile-nav__link {
  display: block;
  padding: 18px 20px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  background: var(--bg-alt);
  border-radius: 12px;
  text-align: center;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}
.mobile-nav__link:hover,
.mobile-nav__link.is-active {
  color: var(--primary);
  background: var(--primary-50);
  transform: translateY(-1px);
}

/* Buttons ---------------------------------------------------------------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: transform 0.3s var(--ease), box-shadow 0.3s ease, background 0.25s, color 0.25s, border-color 0.25s;
  border: 1px solid transparent;
  white-space: nowrap;
  overflow: hidden;
  isolation: isolate;
  cursor: pointer;
}
.btn svg { transition: transform 0.3s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.8s var(--ease);
  z-index: -1;
  pointer-events: none;
}
.btn:hover::before { transform: translateX(100%); }

.btn--primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-600));
  color: #fff;
  box-shadow: var(--shadow-blue);
}
.btn--primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -10px rgba(37, 99, 235, 0.6);
}
.btn--ghost {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(6px);
}
.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-3px);
}
.btn--outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn--outline:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: var(--shadow-blue);
}

/* Generic section -------------------------------------------------------- */
.section { padding: 110px 0; }
.section--light { background: var(--bg); }
.section--alt { background: var(--bg-alt); }
.section--deep {
  background: linear-gradient(135deg, var(--bg-deep) 0%, var(--bg-deep-2) 100%);
  color: var(--text-on-deep);
  position: relative;
  overflow: hidden;
}
.section--deep::before {
  content: '';
  position: absolute;
  top: -200px; right: -200px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.35), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}
.section--deep::after {
  content: '';
  position: absolute;
  bottom: -150px; left: -150px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.18), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.section__head {
  max-width: 720px;
  margin: 0 auto 72px;
  text-align: center;
}
.section__eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--primary);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
  padding: 6px 14px;
  background: var(--primary-50);
  border-radius: 999px;
}
.section--deep .section__eyebrow {
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.12);
}
.section__title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 16px;
}
.section--deep .section__title { color: #fff; }
.section__lead {
  color: var(--text-muted);
  font-size: 1.08rem;
  max-width: 580px;
  margin: 0 auto;
}
.section--deep .section__lead { color: var(--text-on-deep-muted); }

/* Hero (Home) ----------------------------------------------------------- */
.hero {
  position: relative;
  background: linear-gradient(135deg, var(--bg-deep) 0%, var(--bg-deep-2) 100%);
  color: var(--text-on-deep);
  padding: 120px 0 140px;
  overflow: hidden;
  isolation: isolate;
  max-width: 100vw;
}
.hero__title { overflow-wrap: break-word; word-wrap: break-word; }
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.7), transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.7), transparent 70%);
  z-index: -1;
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  top: -240px; right: -180px;
  width: 640px; height: 640px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.55), transparent 65%);
  filter: blur(40px);
  z-index: -1;
  pointer-events: none;
  animation: floatGlow 14s ease-in-out infinite;
}
@keyframes floatGlow {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-40px, 30px) scale(1.08); }
}
.hero__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: center;
}
.hero__copy { max-width: 620px; min-width: 0; }
.hero__subtitle { overflow-wrap: break-word; word-wrap: break-word; }
.hero__chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  background: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.3);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 28px;
}
.hero__chip .dot {
  width: 8px; height: 8px;
  background: #fbbf24;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.18);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.18); }
  50% { box-shadow: 0 0 0 7px rgba(251, 191, 36, 0.05); }
}
.hero__title {
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 22px;
}
.hero__title .tint {
  background: linear-gradient(120deg, #60a5fa 0%, #818cf8 35%, #fbbf24 70%, #60a5fa 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientShift 9s ease-in-out infinite;
}
@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
.hero__subtitle {
  font-size: 1.1rem;
  color: var(--text-on-deep-muted);
  margin-bottom: 38px;
}
.hero__subtitle strong { color: #fff; font-weight: 600; }
.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 48px;
}
.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.hero__meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hero__meta-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-on-deep-muted);
  font-family: var(--font-mono);
}
.hero__meta-value { font-size: 0.95rem; font-weight: 500; color: #fff; }

/* Hero card panel */
.hero__panel {
  position: relative;
  padding: 28px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.5);
  min-width: 0;
  overflow: hidden;
  max-width: 100%;
}
.hero__panel-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 18px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-on-deep-muted);
  min-width: 0;
}
.hero__panel-head > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.hero__panel-dots { display: inline-flex; gap: 6px; margin-right: auto; }
.hero__panel-dots span {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}
.hero__panel-dots span:nth-child(1) { background: #ef4444; }
.hero__panel-dots span:nth-child(2) { background: #f59e0b; }
.hero__panel-dots span:nth-child(3) { background: #22c55e; }
.hero__code {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.85;
  color: #cbd5e1;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: anywhere;
  margin: 0;
  max-width: 100%;
}
.hero__code .k { color: #60a5fa; }
.hero__code .s { color: #fbbf24; }
.hero__code .c { color: #94a3b8; font-style: italic; }
.hero__code .v { color: #a5f3fc; }
.hero__code .p { color: #f9a8d4; }

/* About / quick summary -------------------------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
}
.about__title {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 22px;
}
.about__title .accent { color: var(--primary); }
.about__text {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 18px;
}
.about__cta { display: inline-flex; gap: 12px; margin-top: 12px; flex-wrap: wrap; }

.about-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.about-card {
  padding: 24px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
  border-top: 3px solid var(--primary);
}
.about-card:nth-child(2) { border-top-color: var(--secondary); }
.about-card:nth-child(3) { border-top-color: var(--teal); }
.about-card:nth-child(4) { border-top-color: var(--bg-deep-2); }
.about-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.about-card:hover .about-card__icon { transform: scale(1.1) rotate(-6deg); }
.about-card__icon { transition: transform 0.4s var(--ease); }
.about-card__icon {
  width: 40px; height: 40px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--primary-50);
  color: var(--primary);
  margin-bottom: 14px;
}
.about-card:nth-child(2) .about-card__icon { background: var(--secondary-soft); color: #d97706; }
.about-card:nth-child(3) .about-card__icon { background: var(--teal-soft); color: var(--teal); }
.about-card:nth-child(4) .about-card__icon { background: #e0e7ff; color: var(--bg-deep-2); }
.about-card__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}
.about-card__desc {
  font-size: 0.88rem;
  color: var(--text-soft);
}

/* Highlights strip on home ----------------------------------------------- */
.strip {
  background: #fff;
  padding: 48px 0;
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}
.strip__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  text-align: center;
}
.strip__item .num {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-mono);
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.strip__item:nth-child(2) .num { color: var(--secondary); }
.strip__item:nth-child(3) .num { color: var(--teal); }
.strip__item:nth-child(4) .num { color: var(--bg-deep-2); }
.strip__item .lbl {
  font-size: 0.82rem;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Page header (sub pages) ----------------------------------------------- */
.page-header {
  background: linear-gradient(135deg, var(--bg-deep) 0%, var(--bg-deep-2) 100%);
  color: var(--text-on-deep);
  padding: 90px 0 80px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.6), transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.6), transparent 70%);
  z-index: -1;
  pointer-events: none;
}
.page-header__inner { max-width: 760px; }
.page-header__crumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fbbf24;
  margin-bottom: 18px;
}
.page-header__crumb a { color: var(--text-on-deep-muted); transition: color 0.2s; }
.page-header__crumb a:hover { color: #fff; }
.page-header__title {
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 16px;
  color: #fff;
}
.page-header__title .tint {
  background: linear-gradient(120deg, #60a5fa 0%, #818cf8 35%, #fbbf24 70%, #60a5fa 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientShift 9s ease-in-out infinite;
}
.page-header__lead {
  color: var(--text-on-deep-muted);
  font-size: 1.1rem;
  max-width: 600px;
}

/* Timeline (Journey) ----------------------------------------------------- */
.timeline {
  position: relative;
  max-width: 820px;
  margin: 0 auto;
}
.timeline::before {
  content: '';
  position: absolute;
  top: 12px; bottom: 12px;
  left: 22px;
  width: 2px;
  background: linear-gradient(180deg, var(--primary), var(--secondary) 60%, var(--teal));
  border-radius: 2px;
  opacity: 0.4;
}
.timeline__node {
  position: relative;
  padding-left: 70px;
  padding-bottom: 48px;
}
.timeline__node:last-child { padding-bottom: 0; }
.timeline__dot {
  position: absolute;
  left: 12px; top: 18px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--primary);
  box-shadow: 0 0 0 6px rgba(37, 99, 235, 0.1);
  z-index: 1;
}
.timeline__dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  opacity: 0;
  animation: dotPing 2.6s ease-out infinite;
}
@keyframes dotPing {
  0% { transform: scale(1); opacity: 0.6; }
  80%, 100% { transform: scale(2); opacity: 0; }
}
.timeline__node:nth-child(2) .timeline__dot { border-color: var(--secondary); box-shadow: 0 0 0 6px rgba(245, 158, 11, 0.12); }
.timeline__node:nth-child(2) .timeline__dot::after { border-color: var(--secondary); animation-delay: 0.6s; }
.timeline__node:nth-child(3) .timeline__dot { border-color: var(--teal); box-shadow: 0 0 0 6px rgba(13, 148, 136, 0.12); }
.timeline__node:nth-child(3) .timeline__dot::after { border-color: var(--teal); animation-delay: 1.2s; }

.timeline__card {
  position: relative;
  background: #fff;
  border-radius: var(--radius);
  padding: 30px 32px;
  box-shadow: var(--shadow-md);
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
  overflow: hidden;
  isolation: isolate;
}
.timeline__card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 4px; height: 100%;
  background: linear-gradient(180deg, var(--primary), transparent);
  opacity: 0;
  transition: opacity 0.35s ease;
}
.timeline__node:nth-child(2) .timeline__card::before { background: linear-gradient(180deg, var(--secondary), transparent); }
.timeline__node:nth-child(3) .timeline__card::before { background: linear-gradient(180deg, var(--teal), transparent); }
.timeline__card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
.timeline__card:hover::before { opacity: 1; }
.timeline__year {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-50);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.timeline__node:nth-child(2) .timeline__year { color: #b45309; background: var(--secondary-soft); }
.timeline__node:nth-child(3) .timeline__year { color: var(--teal); background: var(--teal-soft); }

.timeline__title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}
.timeline__institute {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 16px;
}
.timeline__metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--border-soft);
}
.metric {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--bg-alt);
  border-radius: 8px;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
}
.metric strong { color: var(--text); font-weight: 700; }

/* Projects --------------------------------------------------------------- */
.projects {
  display: flex;
  flex-direction: column;
  gap: 32px;
  max-width: 1080px;
  margin: 0 auto;
}
.project-card {
  position: relative;
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 0;
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform 0.4s var(--ease), box-shadow 0.4s ease;
  isolation: isolate;
}
.project-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}
.project-card:hover .project-card__icon { transform: scale(1.08) rotate(-4deg); }
.project-card:hover .project-card__cover::after { opacity: 1; }
.project-card__cover::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.18), transparent 60%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}
.project-card__cover {
  position: relative;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--primary), var(--bg-deep-2));
  color: #fff;
  padding: 32px;
  min-height: 240px;
  overflow: hidden;
}
.project-card:nth-child(2) .project-card__cover {
  background: linear-gradient(135deg, var(--secondary), #b45309);
}
.project-card:nth-child(3) .project-card__cover {
  background: linear-gradient(135deg, var(--teal), #115e59);
}
.project-card__cover::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 28px 28px;
}
.project-card__num {
  position: absolute;
  top: 18px; left: 22px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  opacity: 0.85;
}
.project-card__icon {
  position: relative;
  width: 88px; height: 88px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 22px;
  backdrop-filter: blur(6px);
  transition: transform 0.5s var(--ease);
}
.project-card__icon svg { width: 44px; height: 44px; }
.project-card__body {
  padding: 36px 38px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.project-card__title {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
}
.project-card__role {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--font-mono);
}
.project-card:nth-child(2) .project-card__role { color: #b45309; }
.project-card:nth-child(3) .project-card__role { color: var(--teal); }
.project-card__desc {
  color: var(--text-muted);
  font-size: 1rem;
  flex-grow: 1;
}
.project-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 8px;
}
.tag {
  display: inline-block;
  padding: 6px 12px;
  background: var(--bg-alt);
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
  font-family: var(--font-mono);
  transition: background 0.2s, color 0.2s;
}
.tag:hover { background: var(--primary-50); color: var(--primary); }

.project-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 18px;
  margin-top: 6px;
  border-top: 1px solid var(--border-soft);
}
.gh-link {
  --gh-bg: #0d1117;
  --gh-accent: var(--primary);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px 10px 14px;
  background: var(--gh-bg);
  color: #fff;
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  border: 1px solid #30363d;
  box-shadow: 0 6px 16px -8px rgba(13, 17, 23, 0.4);
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.3s var(--ease), box-shadow 0.3s ease, border-color 0.25s ease, background 0.25s ease;
}
.gh-link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.18) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.7s var(--ease);
  pointer-events: none;
  z-index: 0;
}
.gh-link > * { position: relative; z-index: 1; }
.gh-link__mark {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.4s var(--ease);
}
.gh-link__arrow {
  opacity: 0.7;
  transition: transform 0.3s var(--ease), opacity 0.25s ease;
}
.gh-link:hover {
  transform: translateY(-3px);
  border-color: var(--gh-accent);
  box-shadow: 0 16px 30px -10px rgba(13, 17, 23, 0.45),
              0 0 0 3px color-mix(in srgb, var(--gh-accent) 15%, transparent);
}
.gh-link:hover::before { transform: translateX(100%); }
.gh-link:hover .gh-link__mark { transform: rotate(-8deg) scale(1.08); }
.gh-link:hover .gh-link__arrow { transform: translate(2px, -2px); opacity: 1; }
.gh-link:focus-visible {
  outline: none;
  border-color: var(--gh-accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--gh-accent) 30%, transparent);
}

/* Per-card accent override (matches the colored cover) */
.project-card:nth-child(2) .gh-link { --gh-accent: var(--secondary); }
.project-card:nth-child(3) .gh-link { --gh-accent: var(--teal); }

/* Internships (alternating) --------------------------------------------- */
.intern-list {
  display: flex;
  flex-direction: column;
  gap: 80px;
  max-width: 1100px;
  margin: 0 auto;
}
.intern {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.intern--reverse .intern__media { order: 2; }
.intern__media {
  position: relative;
  padding: 36px;
  border-radius: var(--radius-lg);
  min-height: 420px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  color: #fff;
  overflow: hidden;
  background: linear-gradient(135deg, var(--bg-deep), var(--primary));
  box-shadow: var(--shadow-lg);
  transition: transform 0.4s var(--ease), box-shadow 0.4s ease;
}
.intern:hover .intern__media {
  transform: translateY(-4px);
  box-shadow: 0 30px 60px -20px rgba(15, 23, 42, 0.35);
}
.intern__big { margin-top: auto; }
.intern__media-stats { margin-top: 0; }
.intern:nth-child(2) .intern__media {
  background: linear-gradient(135deg, #b45309, var(--secondary));
}
.intern:nth-child(3) .intern__media {
  background: linear-gradient(135deg, #134e4a, var(--teal));
}
.intern__media::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
}
.intern__media-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.intern__badge {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
}
.intern__big {
  position: relative;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-top: 24px;
}
.intern__big small {
  display: block;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.85;
  margin-top: 8px;
  font-family: var(--font-mono);
}
.intern__copy {}
.intern__role {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 12px;
}
.intern:nth-child(2) .intern__role { color: #b45309; }
.intern:nth-child(3) .intern__role { color: var(--teal); }
.intern__company {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
  margin-bottom: 8px;
}
.intern__period {
  font-size: 0.92rem;
  color: var(--text-soft);
  margin-bottom: 18px;
}
.intern__desc {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 22px;
}
.intern__bullets {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.intern__bullets li {
  position: relative;
  padding-left: 22px;
  font-size: 0.92rem;
  color: var(--text-muted);
}
.intern__bullets li::before {
  content: '';
  position: absolute;
  left: 0; top: 9px;
  width: 8px; height: 8px;
  background: var(--primary);
  border-radius: 50%;
}
.intern:nth-child(2) .intern__bullets li::before { background: var(--secondary); }
.intern:nth-child(3) .intern__bullets li::before { background: var(--teal); }
.intern__bullets li strong { color: var(--text); font-weight: 600; }

.intern__sub {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  margin: 24px 0 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-soft);
}
.intern:nth-child(2) .intern__sub { color: #b45309; }
.intern:nth-child(3) .intern__sub { color: var(--teal); }

.intern__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.chip {
  display: inline-block;
  padding: 6px 13px;
  font-size: 0.8rem;
  font-weight: 500;
  font-family: var(--font-mono);
  background: var(--bg-alt);
  color: var(--text-muted);
  border-radius: 999px;
  border: 1px solid var(--border-soft);
  transition: transform 0.2s var(--ease), background 0.25s, color 0.25s, border-color 0.25s;
}
.chip:hover {
  background: var(--primary-50);
  color: var(--primary);
  border-color: var(--primary-100);
  transform: translateY(-2px);
}
.intern:nth-child(2) .chip:hover {
  background: var(--secondary-soft);
  color: #b45309;
  border-color: rgba(245, 158, 11, 0.25);
}
.intern:nth-child(3) .chip:hover {
  background: var(--teal-soft);
  color: var(--teal);
  border-color: rgba(13, 148, 136, 0.25);
}

.intern__media-stats {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding-top: 22px;
  margin-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}
.intern__media-stats div { display: flex; flex-direction: column; gap: 2px; }
.intern__media-stats strong {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-family: var(--font-mono);
  color: #fff;
}
.intern__media-stats span {
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.78;
  font-family: var(--font-mono);
}

/* CTA section (shared bottom) ------------------------------------------- */
.cta {
  background: linear-gradient(135deg, var(--bg-deep) 0%, var(--bg-deep-2) 100%);
  color: #fff;
  padding: 90px 0;
  position: relative;
  overflow: hidden;
}
.cta::after {
  content: '';
  position: absolute;
  bottom: -120px; left: 50%;
  transform: translateX(-50%);
  width: 600px; height: 300px;
  background: radial-gradient(ellipse, rgba(245, 158, 11, 0.18), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 0;
}
.cta__inner { z-index: 1; }
.cta__inner { text-align: center; max-width: 720px; margin: 0 auto; position: relative; }
.cta__title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 14px;
}
.cta__lead { color: var(--text-on-deep-muted); margin-bottom: 32px; font-size: 1.05rem; }
.cta__buttons { display: inline-flex; gap: 14px; flex-wrap: wrap; justify-content: center; }

/* Footer ---------------------------------------------------------------- */
.footer {
  background: #0b1120;
  color: var(--text-on-deep-muted);
  padding: 60px 0 28px;
}
.footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.footer__brand h3 {
  color: #fff;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.footer__brand p { font-size: 0.95rem; max-width: 360px; }
.footer__col h4 {
  color: #fff;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: var(--font-mono);
  margin-bottom: 16px;
}
.footer__list { display: flex; flex-direction: column; gap: 10px; }
.footer__list a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  color: var(--text-on-deep-muted);
  transition: color 0.2s ease;
  word-break: break-word;
}
.footer__list a:hover { color: #60a5fa; }
.footer__list svg { flex-shrink: 0; color: #60a5fa; }
.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  font-size: 0.82rem;
  color: #94a3b8;
}
.footer__bottom .heart { color: #f472b6; }

/* Toast ----------------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 24px);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  background: linear-gradient(135deg, var(--bg-deep), var(--primary-600));
  color: #fff;
  font-size: 0.92rem;
  font-weight: 500;
  border-radius: 999px;
  box-shadow: 0 18px 40px -10px rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  z-index: 200;
  transition: opacity 0.35s var(--ease), transform 0.45s var(--ease);
  max-width: calc(100vw - 32px);
}
.toast svg {
  flex-shrink: 0;
  background: rgba(34, 197, 94, 0.25);
  border-radius: 50%;
  padding: 3px;
  width: 22px;
  height: 22px;
  color: #4ade80;
}
.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Reveal ---------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* Responsive ------------------------------------------------------------ */

/* Wide desktops -- give a bit more breathing room */
@media (min-width: 1440px) {
  :root { --container: 1240px; }
  .section { padding: 130px 0; }
  .hero { padding: 140px 0 160px; }
}

/* Mid laptops -- pull nav + spacing in slightly */
@media (max-width: 1180px) {
  .container { padding: 0 28px; }
  .nav__link { padding: 10px 12px; font-size: 0.9rem; }
  .header__inner { gap: 16px; }
}

/* Small laptops / large tablets */
@media (max-width: 1024px) {
  .hero__inner { gap: 48px; }
  .hero__title { font-size: clamp(2.2rem, 5vw, 3.4rem); }
  .about-grid { gap: 48px; }
  .project-card { grid-template-columns: 240px 1fr; }
  .project-card__body { padding: 30px; }
  .intern { gap: 40px; }
}

/* Tablets */
@media (max-width: 900px) {
  .hero { padding: 90px 0 100px; }
  .hero__inner { grid-template-columns: 1fr; gap: 56px; }
  .hero__copy { max-width: 100%; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .strip__grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .project-card { grid-template-columns: 1fr; }
  .project-card__cover { min-height: 180px; }
  .project-card__body { padding: 28px; }
  .intern { grid-template-columns: 1fr; gap: 28px; }
  .intern--reverse .intern__media { order: 0; }
  .intern__media { min-height: 240px; }
  .page-header { padding: 80px 0 70px; }
}

/* Phones / hamburger threshold */
@media (max-width: 760px) {
  .nav, .nav__cta { display: none; }
  .hamburger { display: block; }

  .section { padding: 76px 0; }
  .section__head { margin-bottom: 44px; }

  .header__inner { height: 70px; }
  .mobile-nav { inset: 70px 0 0 0; }

  .footer__top { grid-template-columns: 1fr; gap: 32px; }
  .footer__bottom { justify-content: center; text-align: center; }

  .timeline__node { padding-left: 56px; padding-bottom: 36px; }
  .timeline::before { left: 18px; }
  .timeline__dot { left: 8px; }
  .timeline__card { padding: 24px; }

  .about-cards { grid-template-columns: 1fr 1fr; gap: 14px; }
  .about-card { padding: 20px; }
  .about-card__title { font-size: 0.95rem; }
  .about-card__desc { font-size: 0.82rem; }

  .hero__panel { padding: 22px; }
  .hero__code { font-size: 0.78rem; line-height: 1.75; }

  .intern__media { padding: 28px; min-height: 220px; }
  .intern__big { font-size: clamp(2rem, 8vw, 2.8rem); }

  .cta { padding: 70px 0; }
}

/* Small phones */
@media (max-width: 520px) {
  .container { padding: 0 20px; }
  .hero__cta, .cta__buttons, .about__cta { width: 100%; flex-direction: column; }
  .hero__cta .btn,
  .cta__buttons .btn,
  .about__cta .btn { width: 100%; justify-content: center; }
  .strip__grid { grid-template-columns: 1fr 1fr; gap: 18px; }
  .strip__item .num { font-size: 1.6rem; }
  .strip__item .lbl { font-size: 0.74rem; }
  .hero__meta { gap: 18px; }
  .about-cards { grid-template-columns: 1fr; }
  .timeline__metrics { gap: 8px; }
  .metric { font-size: 0.78rem; padding: 5px 10px; }
  .project-card__body { padding: 24px; }
  .project-card__title { font-size: 1.2rem; }
  .intern__media { padding: 22px; min-height: 200px; }
  .intern__copy { padding: 0; }
  .intern__company { font-size: 1.35rem; }
  .page-header__title { font-size: clamp(2rem, 8vw, 2.6rem); }
  .footer { padding: 50px 0 24px; }
}

/* Tiny screens */
@media (max-width: 360px) {
  .container { padding: 0 16px; }
  .logo { font-size: 0.95rem; }
  .logo__mark { width: 30px; height: 30px; font-size: 0.74rem; }
  .strip__grid { grid-template-columns: 1fr; }
  .hero__title { font-size: 2rem; }
  .hero__subtitle { font-size: 0.95rem; }
}
