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

:root {
  --bg: #0a0a0a;
  --bg2: #111111;
  --bg3: #161616;
  --surface: #1a1a1a;
  --border: rgba(255,255,255,0.07);
  --border-hover: rgba(255,255,255,0.15);
  --text: #f0ede8;
  --text2: #8a8680;
  --text3: #4a4744;
  --accent: #e8e0d0;
  --accent2: #c8bfaf;
  --grit: #2a2520;
  --network-bg: #1a1a1a;
  --network-dot: #aaaaaa;
  --network-dot-rgb: 170,170,170;
  --network-line-rgb: 180,180,180;
  --network-line-alpha: 0.3;
  --name-color: #f0ede8;
  --tag-bg: rgba(255,255,255,0.05);
  --tag-border: rgba(255,255,255,0.1);
  --card-bg: #111111;
  --card-border: rgba(255,255,255,0.06);
  --card-hover: rgba(255,255,255,0.04);
  --gallery-caption-bg: rgba(10,10,10,0.72);
  --gallery-caption-text: #f0ede8;
  --gallery-control-bg: rgba(245,242,237,0.88);
  --gallery-control-text: #1a1714;
  --noise: 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.04'/%3E%3C/svg%3E");
}

[data-theme="light"] {
  --bg: #f5f2ed;
  --bg2: #ede9e3;
  --bg3: #e5e0d8;
  --surface: #ddd8d0;
  --border: rgba(0,0,0,0.07);
  --border-hover: rgba(0,0,0,0.15);
  --text: #1a1714;
  --text2: #6b6560;
  --text3: #aaa59e;
  --accent: #1a1714;
  --accent2: #3a3530;
  --grit: #d5cfc5;
  --network-bg: #b8b8b8;
  --network-dot: #555555;
  --network-dot-rgb: 55,55,55;
  --network-line-rgb: 50,50,50;
  --network-line-alpha: 0.4;
  --name-color: #0a0806;
  --tag-bg: rgba(0,0,0,0.04);
  --tag-border: rgba(0,0,0,0.1);
  --card-bg: #ede9e3;
  --card-border: rgba(0,0,0,0.06);
  --card-hover: rgba(0,0,0,0.03);
  --gallery-caption-bg: rgba(245,242,237,0.78);
  --gallery-caption-text: var(--text);
  --gallery-control-bg: rgba(245,242,237,0.9);
  --gallery-control-text: #1a1714;
}

html { scroll-behavior: smooth; }

body {
  background: var(--network-bg);
  color: var(--text);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  transition: color 0.4s ease;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: var(--noise);
  pointer-events: none;
  z-index: 0;
  opacity: 0.6;
}

#particle-network-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  background: var(--network-bg);
}

/* ── NAV ─────────────────────────────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 48px;
  height: 60px;
  background: rgba(10,10,10,0.7);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: background 0.4s ease, border-color 0.4s ease;
}

[data-theme="light"] nav {
  background: rgba(245,242,237,0.8);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 400;
  color: var(--text2);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.theme-toggle {
  position: fixed;
  right: 32px;
  top: 16px;
  z-index: 200;
  display: block;
  background: var(--tag-bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: 58px;
  height: 30px;
  color: var(--text2);
  cursor: pointer;
  backdrop-filter: blur(16px);
  overflow: hidden;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
  flex-shrink: 0;
}

.theme-toggle:hover {
  border-color: var(--border-hover);
  color: var(--text);
  background: var(--card-hover);
}

.theme-toggle::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: var(--text);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  z-index: 2;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s ease;
}

[data-theme="light"] .theme-toggle::after {
  transform: translateX(28px);
}

.theme-toggle:focus { outline: none; }

.theme-toggle:focus-visible {
  outline: 2px solid var(--accent2);
  outline-offset: 3px;
}

.theme-toggle i {
  position: absolute;
  top: 50%;
  z-index: 1;
  width: 18px;
  height: 18px;
  color: currentColor;
  transform: translateY(-50%);
  transition: color 0.2s ease, opacity 0.2s ease;
}

.theme-icon-moon {
  left: 5px;
  opacity: 0;
}

.theme-icon-sun { right: 5px; }

[data-theme="light"] .theme-icon-moon { opacity: 1; }

[data-theme="light"] .theme-icon-sun { opacity: 0; }

/* ── HERO ─────────────────────────────────────────────────── */
#hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(calc(100% - 48px), 928px);
  display: grid;
  grid-template-columns: 176px minmax(0, 720px);
  align-items: center;
  gap: 32px;
  text-align: left;
  pointer-events: auto;
  user-select: text;
}

.hero-avatar-wrap {
  width: 176px;
  height: 176px;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid var(--border-hover);
  background: var(--bg3);
  box-shadow: 0 20px 60px rgba(0,0,0,0.28);
  opacity: 0;
  animation: fadeUp 0.8s ease 0.35s forwards;
}

[data-theme="light"] .hero-avatar-wrap {
  box-shadow: 0 20px 60px rgba(0,0,0,0.12);
}

.hero-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-copy {
  min-width: 0;
}

.hero-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(30px, 3.2vw, 38px);
  font-weight: 700;
  color: var(--text);
  letter-spacing: 0;
  line-height: 1.05;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.5s forwards;
}

.hero-typewriter {
  min-height: 1.25em;
  margin-top: 16px;
  color: var(--text);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(18px, 2.2vw, 26px);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.02em;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.7s forwards;
}

.hero-typewriter-cursor {
  display: inline-block;
  width: 4px;
  height: 1.08em;
  margin-left: 4px;
  background: var(--accent2);
  vertical-align: -0.16em;
  animation: cursorBlink 0.9s steps(2, start) infinite;
}

.hero-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
  opacity: 0;
  animation: fadeUp 0.8s ease 1s forwards;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 14px;
  border: 1px solid var(--border-hover);
  border-radius: 999px;
  background: rgba(255,255,255,0.075);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 14px 30px rgba(0,0,0,0.16);
  color: var(--text2);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  backdrop-filter: blur(12px);
}

[data-theme="light"] .hero-pill {
  background: rgba(0,0,0,0.045);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.38), 0 14px 30px rgba(0,0,0,0.08);
}

.hero-socials {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  opacity: 0;
  animation: fadeUp 0.8s ease 1.2s forwards;
}

.hero-social-link {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border-hover);
  border-radius: 50%;
  background: rgba(255,255,255,0.075);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 14px 30px rgba(0,0,0,0.16);
  backdrop-filter: blur(12px);
  transition: transform 0.2s ease, color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.hero-social-link:hover {
  color: var(--text);
  background: var(--card-hover);
  border-color: var(--accent2);
  transform: translateY(-3px);
}

[data-theme="light"] .hero-social-link {
  background: rgba(0,0,0,0.045);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.38), 0 14px 30px rgba(0,0,0,0.08);
}

.hero-social-link i,
.hero-social-link svg {
  width: 20px;
  height: 20px;
  color: currentColor;
  stroke-width: 1.8;
}

.hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid var(--border-hover);
  border-radius: 999px;
  background: var(--tag-bg);
  color: var(--text);
  text-decoration: none;
  backdrop-filter: blur(16px);
  opacity: 0;
  animation: fadeUp 0.8s ease 1.4s forwards, scrollFloat 2.4s ease-in-out 2.2s infinite;
  z-index: 2;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.hero-scroll:hover {
  border-color: var(--accent2);
  background: var(--card-hover);
}

.hero-scroll i {
  width: 16px;
  height: 16px;
  animation: chevronBounce 1.3s ease-in-out infinite;
}

.hero-scroll span {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: currentColor;
}

.scroll-line {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  width: 1px;
  height: 28px;
  background: linear-gradient(to bottom, var(--text3), transparent);
  transform: translateX(-50%);
  animation: scrollPulse 2s ease-in-out infinite;
}

/* ── READING PROGRESS BAR ─────────────────────────────────── */
.reading-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  z-index: 9999;
  background: linear-gradient(90deg, var(--accent2), var(--accent));
  width: 0%;
  transition: width 0.1s ease;
}

/* ── SECTIONS ─────────────────────────────────────────────── */
section {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 120px 48px;
}

#about {
  max-width: 1240px;
}

/* Wider than the default section so the three carousel cards get more
   horizontal room and the nav arrows can sit in the side gutters. */
#projects {
  max-width: 1240px;
}

.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text3);
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
  max-width: 80px;
}

/* ── ABOUT ─────────────────────────────────────────────────── */
#about .about-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.9fr) minmax(420px, 1fr);
  gap: 48px clamp(40px, 6vw, 72px);
  align-items: start;
}

.about-copy {
  min-width: 0;
  order: 1;
}

.about-headline {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text);
}

.about-headline em {
  font-style: normal;
  color: transparent;
  -webkit-text-stroke: 1px var(--text2);
}

.about-body {
  grid-column: 1 / -1;
  order: 3;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  gap: 18px clamp(32px, 5vw, 64px);
  margin-top: 4px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
  font-size: 15px;
  color: var(--text2);
  line-height: 1.8;
  font-weight: 300;
}

.about-body p {
  margin: 0;
}

.about-body p + p { margin-top: 0; }

.about-lede {
  max-width: 560px;
  margin-top: 28px;
  color: var(--text2);
  font-size: 16px;
  line-height: 1.8;
  font-weight: 300;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 32px;
}

.about-stat {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  background: var(--card-bg);
}

.about-stat-value {
  display: block;
  color: var(--text);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
}

.about-stat-label {
  display: block;
  margin-top: 8px;
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  line-height: 1.5;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.education-panel {
  margin-top: 16px;
  padding: 22px;
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  background: var(--card-bg);
  box-shadow: 0 14px 36px rgba(0,0,0,0.14);
}

.education-heading {
  margin-bottom: 16px;
  color: var(--accent2);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.education-list {
  display: grid;
  gap: 16px;
}

.education-item {
  min-width: 0;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.education-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.education-degree,
.education-school,
.education-meta,
.education-detail {
  display: block;
}

.education-degree {
  color: var(--text);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.25;
}

.education-school {
  margin-top: 4px;
  color: var(--text2);
  font-size: 14px;
  line-height: 1.45;
}

.education-meta,
.education-detail,
.education-cert {
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  line-height: 1.7;
  letter-spacing: 0.04em;
}

.education-meta {
  margin-top: 8px;
  color: var(--accent2);
}

.education-detail {
  margin-top: 6px;
}

.education-cert {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.skills-panel {
  order: 2;
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.skill-card {
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  background: var(--card-bg);
  box-shadow: 0 14px 36px rgba(0,0,0,0.16);
}

.skill-card-label {
  margin-bottom: 14px;
  color: var(--accent2);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.stack-list {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  padding: 6px 12px;
  background: var(--tag-bg);
  border: 1px solid var(--tag-border);
  border-radius: 4px;
  color: var(--text2);
  letter-spacing: 0.05em;
  overflow-wrap: anywhere;
  transition: all 0.2s;
}
.tag:hover {
  background: var(--border);
  color: var(--text);
  border-color: var(--border-hover);
}

/* ── HOBBIES ─────────────────────────────────────────────── */
#hobbies .hobbies-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 1fr;
  align-items: stretch;
  gap: 24px;
}

.hobby-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 28px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  position: relative;
}

.hobby-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  box-shadow: 0 16px 42px rgba(232, 224, 208, 0.10), 0 0 0 1px var(--border-hover);
}

[data-theme="light"] .hobby-card {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .hobby-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 16px 42px rgba(26, 23, 20, 0.10), 0 0 0 1px var(--border-hover);
}

.hobby-card .hobby-emoji {
  font-size: 28px;
  line-height: 1;
  margin-bottom: 14px;
  display: block;
}

.hobby-card .hobby-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  line-height: 1.2;
}

.hobby-card .hobby-desc {
  font-size: 14px;
  color: var(--text2);
  line-height: 1.65;
  font-weight: 300;
}

.hobby-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  margin-top: auto;
  padding-top: 18px;
  color: var(--accent2);
  text-decoration: none;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s ease, transform 0.2s ease;
}

.hobby-link:hover {
  color: var(--text);
  transform: translateX(4px);
}

.hobby-link i {
  width: 14px;
  height: 14px;
}

i[data-lucide] {
  width: 24px;
  height: 24px;
  stroke-width: 1.5;
  color: var(--accent2);
  display: inline-block;
  vertical-align: middle;
}

/* ── PROJECTS ─────────────────────────────────────────────── */
.project-showcase {
  position: relative;
  z-index: 2;
}

.project-card {
  background: color-mix(in srgb, var(--card-bg) 88%, var(--bg3));
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 0;
  cursor: pointer;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, transform 0.3s ease;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  min-height: 640px;
}

.project-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--card-hover);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.project-card:hover::before { opacity: 1; }
.project-card:hover { border-color: var(--border-hover); }

.project-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 16px 42px rgba(232, 224, 208, 0.10), 0 0 0 1px var(--border-hover);
  transform: translateY(-3px);
}

[data-theme="light"] .project-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 16px 42px rgba(26, 23, 20, 0.10), 0 0 0 1px var(--border-hover);
}

.project-card:focus-visible {
  outline: 2px solid var(--accent2);
  outline-offset: -6px;
}

.project-card-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: var(--bg2);
}

.project-card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: saturate(0.9) contrast(0.96);
  transition: transform 0.45s ease, filter 0.45s ease;
}

.project-card-media--phone {
  background:
    radial-gradient(circle at 50% 10%, rgba(232,224,208,0.10), transparent 28%),
    var(--bg2);
}

.project-card-media--phone img {
  width: auto;
  max-width: 72%;
  margin: 0 auto;
  object-fit: contain;
  filter: saturate(0.92) contrast(0.98);
}

.project-card-media--nutribot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 18px 22px;
  align-items: center;
  background:
    radial-gradient(circle at 50% 18%, rgba(232,224,208,0.10), transparent 34%),
    var(--bg2);
}

.project-card-media--nutribot img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: top center;
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 16px 32px rgba(0,0,0,0.28);
  filter: saturate(0.92) contrast(0.98);
}

.project-card-media--nutribot img:nth-child(1),
.project-card-media--nutribot img:nth-child(3) {
  transform: scale(0.9);
  opacity: 0.82;
}

.project-card-media--nutribot img:nth-child(2) {
  transform: scale(1.02);
  z-index: 1;
}

.project-card:hover .project-card-media img {
  transform: scale(1.025);
  filter: saturate(1) contrast(1);
}

.project-card:hover .project-card-media--nutribot img:nth-child(1),
.project-card:hover .project-card-media--nutribot img:nth-child(3) {
  transform: scale(0.93);
}

.project-card:hover .project-card-media--nutribot img:nth-child(2) {
  transform: scale(1.055);
}

.project-card-content {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 28px;
}

.project-num {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--text3);
  letter-spacing: 0.1em;
  margin-bottom: 24px;
}

.project-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(22px, 2.4vw, 28px);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
  line-height: 1.2;
}

.project-desc {
  font-size: 14px;
  color: var(--text2);
  line-height: 1.62;
  font-weight: 300;
  max-width: 680px;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 18px;
  padding-top: 0;
}

.project-bullets {
  display: grid;
  gap: 10px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
  color: var(--text2);
  font-size: 13px;
  line-height: 1.58;
  font-weight: 300;
}

.project-bullets li {
  position: relative;
  padding-left: 24px;
}

.project-bullets li::before {
  content: '->';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent2);
  font-family: 'DM Mono', monospace;
  font-size: 13px;
}

.project-card-actions {
  position: absolute;
  top: 34px;
  right: 34px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
}

.project-arrow {
  color: var(--text3);
  transition: all 0.3s;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
}
.project-arrow svg { width: 20px; height: 20px; }

.project-card:hover .project-arrow { color: var(--text); }

.project-card:hover .project-arrow {
  transform: translate(3px, -3px);
}

.project-card-hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  margin-top: auto;
  padding: 10px 12px;
  border: 1px solid var(--accent2);
  border-radius: 8px;
  color: var(--bg);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  background: var(--accent2);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.project-card-hint svg {
  width: 14px;
  height: 14px;
  color: currentColor;
}

.project-card-hint--repo svg {
  fill: currentColor;
  stroke: none;
}

.about-target-role {
  grid-column: 1 / -1;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  line-height: 1.7;
  letter-spacing: 0.03em;
}

.project-card:hover .project-card-hint {
  color: var(--bg);
  border-color: var(--border-hover);
  background: var(--accent);
}

/* ── PROJECT GRID ─────────────────────────────────────────── */
.project-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 1fr;
  gap: 16px;
  align-items: stretch;
  position: relative;
  z-index: 3;
}

.project-grid .project-card {
  height: 100%;
}

.project-grid .project-desc {
  flex: 1 1 auto;
}

/* ── PROJECT CAROUSEL ─────────────────────────────────────── */
/* Five projects no longer divide evenly into the old 2x2 grid, so the
   showcase is a horizontal carousel: three cards visible on desktop,
   two on tablet, one on mobile, paged by arrows/dots and native swipe. */
.project-carousel {
  position: relative;
  z-index: 3;
}

.project-carousel-viewport {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  /* Vertical padding gives the card hover-lift and shadow room before the
     clip edge; matching negative margins keep the track flush with the
     section. Horizontal stays at 0 so the three cards sit perfectly centered. */
  padding: 14px 0 30px;
  margin: -14px 0 -10px;
}

.project-carousel-viewport::-webkit-scrollbar { display: none; }

.project-carousel-track {
  display: flex;
  gap: 16px;
  align-items: stretch;
}

.project-carousel-track .project-card {
  flex: 0 0 calc((100% - 32px) / 3);
  scroll-snap-align: start;
}

.project-carousel-btn {
  position: absolute;
  top: calc(50% - 26px);
  transform: translateY(-50%);
  z-index: 4;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--border-hover);
  background: color-mix(in srgb, var(--bg2) 86%, transparent);
  backdrop-filter: blur(8px);
  color: var(--text);
  cursor: pointer;
  transition: background 0.25s ease, border-color 0.25s ease, opacity 0.25s ease, transform 0.25s ease;
}

.project-carousel-btn:hover {
  background: var(--surface);
  border-color: var(--accent2);
}

.project-carousel-btn i,
.project-carousel-btn svg { width: 20px; height: 20px; }

/* Sit in the section's side padding so they clear the cards entirely. */
.project-carousel-prev { left: -46px; }
.project-carousel-next { right: -46px; }

/* Keep both arrows present at the ends (dimmed) so the gutters stay
   symmetric and the row never looks lopsided. */
.project-carousel-btn[disabled] {
  opacity: 0.3;
  pointer-events: none;
}

.project-carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
}

.project-carousel-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--text3);
  opacity: 0.55;
  cursor: pointer;
  transition: opacity 0.25s ease, background 0.25s ease, width 0.25s ease, border-radius 0.25s ease;
}

.project-carousel-dot:hover { opacity: 0.85; }

.project-carousel-dot.is-active {
  opacity: 1;
  width: 22px;
  border-radius: 5px;
  background: var(--accent);
}

/* ── PROJECTS END ─────────────────────────────────────────── */

.project-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text3);
  margin-bottom: 16px;
}

.project-status--ghost {
  visibility: hidden;
  pointer-events: none;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  animation: pulse-dot 2s ease-in-out infinite;
}

/* ── CONTACT ─────────────────────────────────────────────── */
#contact {
  padding-bottom: 160px;
}

.contact-block {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 72px;
  align-items: center;
}

.contact-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  margin-bottom: 28px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg3);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text2);
}

.contact-headline {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(40px, 5.4vw, 66px);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: var(--text);
}

.contact-subtext {
  margin-top: 20px;
  max-width: 40ch;
  font-size: 15px;
  line-height: 1.65;
  font-weight: 300;
  color: var(--text2);
}

.contact-copy {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg2);
  color: var(--text2);
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}
.contact-copy:hover { border-color: var(--border-hover); color: var(--text); }
.contact-copy i { width: 16px; height: 16px; }
.contact-copy-action { display: inline-flex; color: var(--text3); transition: color 0.25s ease; }
.contact-copy.is-copied { color: var(--text); border-color: #4ade80; }
.contact-copy.is-copied .contact-copy-action { color: #4ade80; }

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.contact-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: color-mix(in srgb, var(--card-bg) 88%, var(--bg3));
  text-decoration: none;
  color: var(--text2);
  overflow: hidden;
  transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.contact-link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--card-hover);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.contact-link:hover {
  border-color: var(--border-hover);
  color: var(--text);
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

.contact-link:hover::before { opacity: 1; }

.contact-link-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg2);
  color: var(--text);
}
.contact-link-icon svg { width: 19px; height: 19px; }

.contact-link-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}
.contact-link-label {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 15px;
  color: var(--text);
}
.contact-link-handle {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--text3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-link-arrow {
  display: flex;
  color: var(--text3);
  transition: transform 0.25s ease, color 0.25s ease;
}
.contact-link-arrow svg { width: 18px; height: 18px; }
.contact-link:hover .contact-link-arrow {
  transform: translate(4px, -4px);
  color: var(--text);
}

/* ── FOOTER ─────────────────────────────────────────────── */
footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 32px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 100%;
}

.footer-text {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--text3);
  letter-spacing: 0.05em;
}

/* ── DIVIDER ─────────────────────────────────────────────── */
.section-divider {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 48px;
  height: 1px;
  background: var(--border);
}

/* ── ANIMATIONS ─────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.35; transform: translateX(-50%) scaleY(1); }
  50% { opacity: 1; transform: translateX(-50%) scaleY(1.25); }
}

@keyframes scrollFloat {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-6px); }
}

@keyframes cursorBlink {
  0%, 45% { opacity: 1; }
  46%, 100% { opacity: 0; }
}

@keyframes chevronBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

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

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 0 24px; }
  .nav-links { display: none; }
  .theme-toggle { right: 24px; }
  .hero-content {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 24px;
    text-align: center;
  }
  .hero-avatar-wrap {
    width: 152px;
    height: 152px;
  }
  .hero-copy { text-align: center; }
  .hero-name { font-size: 28px; }
  .hero-typewriter {
    min-height: 2.4em;
    margin-top: 14px;
    font-size: 17px;
  }
  .hero-sub {
    justify-content: center;
    gap: 8px;
    margin-top: 22px;
    line-height: 1.7;
  }
  .hero-pill {
    min-height: 28px;
    padding: 0 10px;
    font-size: 9px;
  }
  .hero-socials { justify-content: center; }
  .hero-social-link {
    width: 34px;
    height: 34px;
  }
  .hero-social-link i,
  .hero-social-link svg {
    width: 19px;
    height: 19px;
  }
  .project-card {
    min-height: auto;
    padding: 0;
  }
  .project-card-content { padding: 22px; }
  .project-grid { grid-template-columns: 1fr; }
  .project-carousel-track .project-card { flex-basis: 100%; }
  .project-carousel-prev { left: 0; }
  .project-carousel-next { right: 0; }
  .phone-screenshot-strip {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    overflow-x: auto;
    padding-bottom: 8px;
  }
  section { padding: 80px 24px; }
  #about .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-stats { grid-template-columns: 1fr; }
  .about-body {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .education-panel,
  .skill-card { padding: 18px; }
  .skills-panel { grid-template-columns: 1fr; }
  #hobbies .hobbies-grid { grid-template-columns: 1fr; }
  .contact-block { grid-template-columns: 1fr; gap: 48px; }
  footer { flex-direction: column; gap: 12px; text-align: center; }
}

@media (min-width: 769px) and (max-width: 1180px) {
  #about .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .about-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .skills-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-carousel-track .project-card { flex-basis: calc((100% - 16px) / 2); }
}

/* ── PROJECT DETAIL PAGES ────────────────────────────────── */
.project-detail-main {
  position: relative;
  z-index: 1;
  max-width: 1040px;
  margin: 0 auto;
  padding: 120px 48px 96px;
}

.project-detail-nav .nav-links a[aria-current="page"] {
  color: var(--text);
}

.project-back-link {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text2);
  text-decoration: none;
  transition: color 0.2s ease;
}

.project-back-link:hover { color: var(--text); }

.project-back-link + .project-detail-number {
  margin-top: 32px;
}

.project-detail-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: start;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--border);
}

.project-detail-number {
  font-family: 'DM Mono', monospace;
  color: var(--text3);
  font-size: 12px;
  letter-spacing: 0.14em;
  margin-bottom: 18px;
}

.project-detail-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(44px, 7vw, 88px);
  line-height: 0.96;
  letter-spacing: 0;
  color: var(--text);
  max-width: 820px;
}

.project-detail-tagline {
  max-width: 720px;
  margin-top: 24px;
  color: var(--text2);
  font-size: 18px;
  line-height: 1.7;
  font-weight: 300;
}

.project-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 28px;
}

.detail-section {
  padding: 56px 0;
  border-bottom: 1px solid var(--border);
}

.detail-section:last-of-type { border-bottom: none; }

.detail-section-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text3);
  margin-bottom: 22px;
}

.detail-copy {
  max-width: 780px;
  color: var(--text2);
  font-size: 16px;
  line-height: 1.85;
  font-weight: 300;
}

.pipeline {
  display: grid;
  grid-template-columns: repeat(var(--pipeline-steps, 4), minmax(150px, 1fr));
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg);
}

.pipe-step {
  min-width: 150px;
  padding: 20px;
  border-right: 1px solid var(--border);
}

.pipe-step:last-child { border-right: none; }

.pipe-num {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--text3);
  margin-bottom: 10px;
}

.pipe-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  color: var(--text);
  margin-bottom: 8px;
}

.pipe-desc {
  color: var(--text2);
  font-size: 13px;
  line-height: 1.6;
}

.project-shot,
.project-live-view,
.project-shot-placeholder {
  margin-top: 24px;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg);
  overflow: hidden;
}

.project-shot img {
  display: block;
  width: 100%;
  height: auto;
}

.project-shot figcaption {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.phone-screenshot-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.phone-screenshot {
  min-width: 0;
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg);
  overflow: hidden;
}

.phone-screenshot img {
  display: block;
  width: 100%;
  height: auto;
}

.phone-screenshot figcaption {
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-live-view {
  position: relative;
  height: min(680px, 78vh);
  background: var(--bg);
}

.project-live-view--dark {
  background: #050506;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.04);
}

.project-live-view iframe {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #050506;
  color-scheme: dark;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.project-live-view.is-iframe-loaded iframe {
  opacity: 1;
}

.project-live-view.is-iframe-loaded .project-live-fallback {
  opacity: 0;
  pointer-events: none;
}

.project-live-fallback {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(280px, 0.44fr) minmax(320px, 1fr);
  min-height: 100%;
  background:
    linear-gradient(135deg, rgba(99,102,241,0.10), transparent 28%, transparent 68%, rgba(20,184,166,0.06)),
    #050508;
  color: #f8fafc;
  transition: opacity 0.4s ease;
}

.live-preview-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: clamp(24px, 4vw, 48px);
  border-right: 1px solid rgba(255,255,255,0.08);
}

.live-preview-kicker,
.live-preview-label,
.live-preview-card-top,
.live-lengths {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.live-preview-kicker,
.live-preview-label {
  color: rgba(226,232,240,0.42);
}

.live-preview-sidebar h2 {
  color: #fff;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1;
  letter-spacing: 0;
}

.live-preview-card {
  display: grid;
  gap: 18px;
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 10px;
  background:
    radial-gradient(circle at 18% 18%, rgba(99,102,241,0.18), transparent 46%),
    linear-gradient(165deg, rgba(255,255,255,0.07), transparent 34%, rgba(20,184,166,0.08)),
    #08080b;
  box-shadow: 0 22px 54px rgba(0,0,0,0.45);
}

.live-preview-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: rgba(226,232,240,0.62);
  letter-spacing: 0.08em;
}

.live-pill {
  display: inline-flex;
  padding: 5px 8px;
  border: 1px solid rgba(110,231,183,0.18);
  border-radius: 999px;
  background: rgba(110,231,183,0.10);
  color: #d1fae5;
}

.live-preview-card h3 {
  color: #fff;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(30px, 4.8vw, 58px);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: 0;
}

.live-wave {
  display: flex;
  align-items: end;
  gap: 7px;
  height: 46px;
}

.live-wave span {
  width: 7px;
  border-radius: 999px;
  background: rgba(129,140,248,0.78);
}

.live-wave span:nth-child(1) { height: 14px; }
.live-wave span:nth-child(2) { height: 28px; }
.live-wave span:nth-child(3) { height: 40px; }
.live-wave span:nth-child(4) { height: 18px; }
.live-wave span:nth-child(5) { height: 32px; }
.live-wave span:nth-child(6) { height: 24px; }

.live-lengths {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: rgba(226,232,240,0.68);
  letter-spacing: 0;
  text-transform: none;
}

.live-lengths span,
.live-generate {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
}

.live-lengths span {
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.04);
}

.live-generate {
  justify-content: center;
  padding: 12px 16px;
  border: 1px solid rgba(129,140,248,0.44);
  border-radius: 8px;
  background: #6366f1;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.live-preview-main {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.live-preview-main::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 54% 46%, rgba(99,102,241,0.18), transparent 22%),
    radial-gradient(circle at 74% 28%, rgba(20,184,166,0.10), transparent 18%);
}

.live-preview-orb {
  position: relative;
  width: min(54vw, 520px);
  aspect-ratio: 1;
  border: 1px solid rgba(174,199,255,0.22);
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle, transparent 0 34px, rgba(174,199,255,0.10) 35px 36px),
    radial-gradient(circle, rgba(129,140,248,0.12), transparent 62%);
  box-shadow: inset 0 0 60px rgba(129,140,248,0.08), 0 0 80px rgba(0,0,0,0.38);
}

.live-preview-orb::before,
.live-preview-orb::after {
  content: '';
  position: absolute;
  inset: 16%;
  border: 1px solid rgba(174,199,255,0.24);
  border-radius: 50%;
}

.live-preview-orb::after {
  inset: 32%;
}

.live-preview-label {
  position: absolute;
  bottom: 42px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
}

@media (max-width: 860px) {
  .project-live-view {
    height: auto;
    min-height: 720px;
  }

  .project-live-fallback {
    grid-template-columns: 1fr;
  }

  .live-preview-sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }

  .live-preview-main {
    min-height: 320px;
  }

  .live-preview-orb {
    width: min(76vw, 360px);
  }
}

.screenshot-carousel {
  margin-top: 24px;
  position: relative;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card-bg);
  /* No clip here — the arrows escape into the gutter; the image is
     clipped by the viewport below instead. */
}

/* Positioning context for the arrows, sized to just the image. */
.screenshot-carousel-stage {
  position: relative;
}

.screenshot-carousel-viewport {
  position: relative;
  aspect-ratio: 16 / 9;
  min-height: 320px;
  background: var(--bg);
  overflow: hidden;
  border-radius: 12px 12px 0 0;
}

.screenshot-carousel-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.screenshot-carousel-btn {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 44px;
  height: 44px;
  transform: translateY(-50%);
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  background: var(--gallery-control-bg);
  color: var(--gallery-control-text);
  display: grid;
  place-items: center;
  cursor: pointer;
  backdrop-filter: blur(16px);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.screenshot-carousel-btn:hover {
  border-color: var(--accent2);
  transform: translateY(-50%) scale(1.04);
}

.screenshot-carousel-btn i {
  width: 18px;
  height: 18px;
  color: currentColor;
}

/* Desktop: arrows sit outside the image in the page gutter. */
.screenshot-carousel-prev { left: -46px; }

.screenshot-carousel-next { right: -46px; }

.screenshot-carousel-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.screenshot-carousel-description {
  padding: 16px;
  border-top: 1px solid var(--border);
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
  font-weight: 300;
}

.screenshot-carousel-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  padding: 14px 16px 16px;
  border-top: 1px solid var(--border);
}

.screenshot-carousel-dot {
  width: 6px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: var(--text3);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease, width 0.2s ease;
}

.screenshot-carousel-dot.is-active {
  width: 22px;
  background: var(--accent2);
}

.project-architecture {
  margin-top: 24px;
  background: transparent;
}

.project-architecture-header {
  margin-bottom: 16px;
}

.project-architecture-kicker {
  display: block;
  margin-bottom: 6px;
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-architecture-title {
  color: var(--text2);
  font-size: 15px;
  line-height: 1.6;
}

.architecture-flow {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  background: transparent;
}

.architecture-flow--mobile {
  display: none;
}

@media (max-width: 640px) {
  .architecture-flow--desktop {
    display: none;
  }

  .architecture-flow--mobile {
    display: block;
  }
}

.project-shot-placeholder {
  min-height: 280px;
  display: grid;
  place-items: center;
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-style: dashed;
}

.decisions-list {
  list-style: none;
  display: grid;
  gap: 12px;
  max-width: 840px;
}

.decision-item {
  border-left: 2px solid var(--accent2);
  background: var(--card-bg);
  border-radius: 0 8px 8px 0;
  padding: 18px 20px;
  color: var(--text2);
  line-height: 1.75;
  font-size: 15px;
}

.decision-item strong {
  display: block;
  color: var(--text);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  margin-bottom: 4px;
}

.metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.metric {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
}

.metric-val {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1;
  color: var(--text);
}

.metric-label {
  margin-top: 10px;
  color: var(--text3);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.project-cta,
.project-approval-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  border-radius: 8px;
  padding: 10px 16px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
}

.project-cta {
  color: var(--text);
  border: 1px solid var(--border-hover);
  background: var(--tag-bg);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.project-cta:hover {
  border-color: var(--accent2);
  background: var(--card-hover);
  transform: translateY(-2px);
}

.project-cta i { width: 14px; height: 14px; }

.project-approval-badge {
  color: #fcd34d;
  border: 1px solid rgba(245,158,11,0.28);
  background: rgba(245,158,11,0.10);
}

.project-note {
  width: 100%;
  max-width: 620px;
  color: var(--text3);
  font-size: 14px;
  line-height: 1.7;
}

.project-detail-footer {
  max-width: 1040px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .project-detail-main { padding: 96px 24px 72px; }
  /* The narrow mobile gutter can't hold the arrows outside, so inset them
     over the image (which the original design did everywhere). */
  .screenshot-carousel-prev { left: 8px; }
  .screenshot-carousel-next { right: 8px; }
  .project-detail-header { grid-template-columns: 1fr; gap: 24px; }
  .pipeline { grid-template-columns: repeat(var(--pipeline-steps, 4), minmax(180px, 1fr)); }
  .metrics-row { grid-template-columns: 1fr; }
}
