/* =============================================================================
   Abraham Tadesse — Modern Portfolio Design System
   ============================================================================= */

/* 1. DESIGN TOKENS
   ============================================================================= */
:root {
  --bg-primary:    #08080f;
  --bg-secondary:  #0f0f1a;
  --bg-surface:    #141420;
  --bg-glass:      rgba(255, 255, 255, 0.04);
  --bg-glass-hov:  rgba(255, 255, 255, 0.08);

  --accent-indigo: #6366f1;
  --accent-cyan:   #22d3ee;
  --accent-purple: #a855f7;
  --grad-main:     linear-gradient(135deg, #6366f1, #22d3ee);
  --grad-text:     linear-gradient(135deg, #818cf8, #22d3ee);
  --grad-subtle:   linear-gradient(135deg, rgba(99,102,241,.15), rgba(34,211,238,.15));

  --text-primary:  #f1f5f9;
  --text-secondary:#cbd5e1;
  --text-muted:    #64748b;
  --text-accent:   #818cf8;

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-accent: rgba(99, 102, 241, 0.35);

  --shadow-card:   0 4px 24px rgba(0, 0, 0, 0.45);
  --shadow-glow:   0 0 40px rgba(99, 102, 241, 0.22);

  --radius-sm:  8px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-pill:999px;

  --ease: 0.25s ease;
  --ease-slow: 0.5s ease;

  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

  --nav-h: 70px;
}

/* Light mode */
[data-theme="light"] {
  --bg-primary:    #f8fafc;
  --bg-secondary:  #f1f5f9;
  --bg-surface:    #ffffff;
  --bg-glass:      rgba(0, 0, 0, 0.03);
  --bg-glass-hov:  rgba(0, 0, 0, 0.06);
  --text-primary:  #0f172a;
  --text-secondary:#334155;
  --text-muted:    #94a3b8;
  --border-subtle: rgba(0, 0, 0, 0.08);
  --shadow-card:   0 4px 24px rgba(0, 0, 0, 0.08);
  --shadow-glow:   0 0 40px rgba(99, 102, 241, 0.12);
}

/* 2. RESET
   ============================================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a  { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul  { list-style: none; }
button { font-family: inherit; }
:focus-visible {
  outline: 2px solid var(--accent-indigo);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* 3. LAYOUT UTILITIES
   ============================================================================= */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
.section { padding: 100px 0; }

/* Reveal-on-scroll */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.visible { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: .1s; }
.reveal-d2 { transition-delay: .2s; }
.reveal-d3 { transition-delay: .3s; }
.reveal-d4 { transition-delay: .4s; }

/* 4. TYPOGRAPHY HELPERS
   ============================================================================= */
.gradient-text {
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.section-label {
  display: inline-block;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--accent-indigo);
  margin-bottom: .75rem;
}
.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.18;
  margin-bottom: 1rem;
}
.section-desc {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  max-width: 540px;
  line-height: 1.7;
}
.section-header { margin-bottom: 56px; }

/* 5. BUTTONS
   ============================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: var(--radius-pill);
  font-size: .9375rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: var(--grad-main);
  color: #fff;
  box-shadow: 0 4px 20px rgba(99,102,241,.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(99,102,241,.5);
}
.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-subtle);
}
.btn-outline:hover {
  border-color: var(--accent-indigo);
  color: var(--accent-indigo);
  transform: translateY(-2px);
}

/* 6. NAVIGATION
   ============================================================================= */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background var(--ease), box-shadow var(--ease);
}
#navbar.scrolled {
  background: rgba(8, 8, 15, .88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 1px 0 var(--border-subtle);
}
[data-theme="light"] #navbar.scrolled {
  background: rgba(248, 250, 252, .92);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}
.nav-logo {
  font-size: 1.2rem;
  font-weight: 800;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -.03em;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  padding: 7px 15px;
  border-radius: var(--radius-pill);
  font-size: .9rem;
  color: var(--text-secondary);
  transition: all var(--ease);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: var(--bg-glass);
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Theme toggle */
.theme-toggle {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--ease);
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}
.theme-toggle:hover { color: var(--text-primary); border-color: var(--accent-indigo); }
.theme-toggle svg { width: 16px; height: 16px; pointer-events: none; }
.icon-sun  { display: none; }
.icon-moon { display: block; }
[data-theme="light"] .icon-sun  { display: block; }
[data-theme="light"] .icon-moon { display: none; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px 4px;
  background: none;
  border: none;
  color: var(--text-primary);
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: all var(--ease);
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile menu */
.mobile-menu {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  padding: 12px 24px 20px;
  flex-direction: column;
  gap: 4px;
  z-index: 999;
  backdrop-filter: blur(18px);
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-weight: 500;
  transition: all var(--ease);
}
.mobile-menu a:hover { background: var(--bg-glass); color: var(--text-primary); }
.mobile-hire {
  margin-top: 8px;
  background: var(--grad-main);
  color: #fff !important;
  border-radius: var(--radius-pill);
  text-align: center;
}

/* 7. HERO SECTION
   ============================================================================= */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-h);
  position: relative;
  overflow: hidden;
}

/* Background blobs */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(110px);
  opacity: .2;
  will-change: transform;
}
.hero-blob-1 {
  width: 640px; height: 640px;
  background: #6366f1;
  top: -120px; left: -120px;
  animation: blobDrift 9s ease-in-out infinite;
}
.hero-blob-2 {
  width: 500px; height: 500px;
  background: #22d3ee;
  bottom: -80px; right: -80px;
  animation: blobDrift 11s ease-in-out infinite reverse;
}
@keyframes blobDrift {
  0%,100% { transform: translate(0,0) scale(1); }
  33%      { transform: translate(28px,-28px) scale(1.05); }
  66%      { transform: translate(-18px,22px) scale(.96); }
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  width: 100%;
}

/* Left column */
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-glass);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-pill);
  padding: 6px 16px;
  font-size: .8125rem;
  color: var(--text-accent);
  font-family: var(--font-mono);
  margin-bottom: 22px;
  animation: fadeUp .8s ease both;
}
.hero-tag::before { content: '▸'; color: var(--accent-cyan); }

.hero-name {
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -.03em;
  margin-bottom: 14px;
  animation: fadeUp .8s .08s ease both;
}

.hero-role-line {
  font-size: clamp(1.1rem, 2.4vw, 1.35rem);
  color: var(--text-secondary);
  margin-bottom: 22px;
  min-height: 2em;
  animation: fadeUp .8s .16s ease both;
}
#typed-role { color: var(--accent-cyan); font-weight: 600; }
.typed-cursor {
  color: var(--accent-indigo);
  font-weight: 300;
  animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.hero-desc {
  color: var(--text-muted);
  font-size: 1.0625rem;
  line-height: 1.72;
  max-width: 460px;
  margin-bottom: 34px;
  animation: fadeUp .8s .24s ease both;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  animation: fadeUp .8s .32s ease both;
}

/* Right column — code card */
.hero-visual {
  display: flex;
  justify-content: center;
  animation: fadeUp .8s .2s ease both;
}
.code-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  font-family: var(--font-mono);
  font-size: .875rem;
  line-height: 1.85;
  max-width: 400px;
  width: 100%;
  box-shadow: var(--shadow-card), var(--shadow-glow);
  position: relative;
  overflow: hidden;
  /* gentle float */
  animation: cardFloat 6s ease-in-out infinite;
}
@keyframes cardFloat {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}
.code-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--grad-main);
}
.code-dots { display: flex; gap: 6px; margin-bottom: 18px; }
.code-dot  { width: 10px; height: 10px; border-radius: 50%; }
.code-dot:nth-child(1) { background: #ff5f57; }
.code-dot:nth-child(2) { background: #febc2e; }
.code-dot:nth-child(3) { background: #28c840; }

/* Syntax colours */
.c-keyword  { color: #c792ea; }
.c-func     { color: #82aaff; }
.c-string   { color: #c3e88d; }
.c-comment  { color: #546e7a; font-style: italic; }
.c-prop     { color: #f78c6c; }
.c-value    { color: #22d3ee; }
.c-bool     { color: #ff9cac; }
.c-punct    { color: #89ddff; }
.c-line     { display: block; }

/* Scroll cue */
.scroll-cue {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: .7rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  z-index: 1;
  animation: fadeUp 1s .9s ease both;
}
.scroll-cue-line {
  width: 1px; height: 36px;
  background: linear-gradient(to bottom, var(--accent-indigo), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%,100% { opacity: 1; }
  50%      { opacity: .3; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: none; }
}

/* 8. ABOUT
   ============================================================================= */
#about { background: var(--bg-secondary); }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.65fr;
  gap: 72px;
  align-items: center;
}

.about-photo-wrap {
  position: relative;
  display: block;
  max-width: 340px;   /* constrains the gradient border to photo size */
}
.about-photo-wrap::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: calc(var(--radius-lg) + 3px);
  background: var(--grad-main);
  z-index: 0;
  opacity: .6;
}
.about-photo-wrap::after {
  content: '';
  position: absolute;
  top: 16px; left: 16px;
  width: 100%; height: 100%;
  border-radius: var(--radius-lg);
  background: var(--grad-subtle);
  z-index: -1;
}
.about-photo {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 420px;
  object-fit: cover;
  /* bg8.png: face sits upper-right of a landscape frame */
  object-position: 72% 8%;
  border-radius: var(--radius-lg);
  display: block;
}

.about-info { display: flex; flex-direction: column; gap: 22px; }

.about-bio {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  line-height: 1.78;
}

.about-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 24px;
  padding: 20px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}
.detail-item { display: flex; flex-direction: column; gap: 2px; }
.detail-label {
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-muted);
}
.detail-value {
  font-size: .9375rem;
  font-weight: 500;
  color: var(--text-primary);
}

.about-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* 9. PROJECTS
   ============================================================================= */
#projects { background: var(--bg-primary); }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--ease), border-color var(--ease), box-shadow var(--ease);
}
.project-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-accent);
  box-shadow: var(--shadow-glow);
}

.proj-img-wrap {
  position: relative;
  overflow: hidden;
  height: 240px;          /* taller so screenshots are clearly readable */
  background: var(--bg-surface);
}
.proj-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;  /* show the top of screenshots (most content) */
  transition: transform var(--ease-slow);
  display: block;
}
.project-card:hover .proj-img { transform: scale(1.04); }

/* CSS gradient placeholder for projects without a screenshot */
.proj-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(99,102,241,.18) 0%, rgba(34,211,238,.12) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  border-bottom: 1px solid var(--border-accent);
}
.proj-placeholder-icon { font-size: 3rem; line-height: 1; }
.proj-placeholder-label {
  font-size: .72rem;
  font-family: var(--font-mono);
  color: var(--text-accent);
  letter-spacing: .08em;
  text-transform: uppercase;
}

/* subtle gradient only at bottom edge — doesn't obscure the image */
.proj-img-wrap::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 40px;
  background: linear-gradient(to top, var(--bg-surface), transparent);
  pointer-events: none;
}

.proj-body {
  padding: 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.proj-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}
.proj-desc {
  font-size: .9375rem;
  color: var(--text-muted);
  line-height: 1.62;
  flex: 1;
}
.proj-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tag {
  padding: 3px 11px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  font-size: .72rem;
  font-weight: 500;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}
.proj-links {
  display: flex;
  gap: 16px;
  padding-top: 4px;
}
.proj-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .875rem;
  font-weight: 600;
  color: var(--accent-indigo);
  transition: color var(--ease), gap var(--ease);
}
.proj-link:hover { color: var(--accent-cyan); gap: 8px; }
.proj-link svg { width: 13px; height: 13px; }

/* 10. AI & TECH
   ============================================================================= */
#ai-tech {
  background: var(--bg-secondary);
  position: relative;
  overflow: hidden;
}
#ai-tech::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 900px; height: 400px;
  background: radial-gradient(ellipse, rgba(99,102,241,.09) 0%, transparent 70%);
  pointer-events: none;
}

.ai-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 72px;
  align-items: center;
}

.ai-features { display: flex; flex-direction: column; gap: 16px; }

.ai-feat {
  display: flex;
  gap: 16px;
  padding: 18px 20px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all var(--ease);
}
.ai-feat:hover {
  border-color: var(--border-accent);
  background: var(--bg-glass-hov);
  transform: translateX(4px);
}
.ai-feat-icon {
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--grad-subtle);
  border: 1px solid var(--border-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1rem;
}
.ai-feat h4 { font-size: .9375rem; font-weight: 600; margin-bottom: 4px; }
.ai-feat p  { font-size: .875rem; color: var(--text-muted); line-height: 1.5; }

/* Tech orbit grid */
.tech-panel { display: flex; flex-direction: column; gap: 14px; }
.tech-panel-title {
  font-size: .85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-muted);
}
.tech-orbit {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.tech-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  font-size: .73rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-align: center;
  transition: all var(--ease);
  cursor: default;
}
.tech-item:hover {
  border-color: var(--border-accent);
  color: var(--text-primary);
  transform: scale(1.05);
}
.tech-item-icon { font-size: 1.4rem; line-height: 1; }

/* 11. SKILLS
   ============================================================================= */
#skills { background: var(--bg-primary); }

.skills-groups {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.skill-group {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  transition: all var(--ease);
}
.skill-group:hover {
  border-color: var(--border-accent);
  box-shadow: 0 4px 20px rgba(99,102,241,.1);
}
.skill-group-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.skill-group-icon { font-size: 1.2rem; }
.skill-group-name {
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-accent);
}
.skill-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-tag {
  padding: 5px 13px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  font-size: .8rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--ease);
}
.skill-tag:hover {
  border-color: var(--accent-indigo);
  color: var(--accent-indigo);
  background: rgba(99,102,241,.1);
}

/* 12. EDUCATION TIMELINE
   ============================================================================= */
#education { background: var(--bg-secondary); }

.timeline {
  position: relative;
  max-width: 700px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 19px; top: 6px; bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent-indigo), var(--accent-cyan), transparent);
}

.tl-item {
  padding-left: 60px;
  position: relative;
  margin-bottom: 40px;
}
.tl-item:last-child { margin-bottom: 0; }

.tl-dot {
  position: absolute;
  left: 11px; top: 6px;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--grad-main);
  border: 3px solid var(--bg-secondary);
  box-shadow: 0 0 0 2px var(--accent-indigo);
}

.tl-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 22px 24px;
  transition: border-color var(--ease);
}
.tl-card:hover { border-color: var(--border-accent); }

.tl-period {
  font-size: .8rem;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
  margin-bottom: 6px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tl-badge {
  background: rgba(34,211,238,.1);
  border: 1px solid rgba(34,211,238,.25);
  border-radius: var(--radius-pill);
  padding: 1px 8px;
}

.tl-school {
  font-size: .875rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.tl-degree {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.tl-desc {
  font-size: .9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* 13. CONTACT
   ============================================================================= */
#contact {
  background: var(--bg-primary);
  text-align: center;
}
.contact-inner {
  max-width: 580px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}
.contact-inner .section-desc { text-align: center; margin-bottom: 36px; }
.contact-email {
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  font-weight: 700;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 32px;
  transition: opacity var(--ease);
}
.contact-email:hover { opacity: .8; }
.social-links {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.social-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--ease);
}
.social-link:hover {
  border-color: var(--border-accent);
  color: var(--text-primary);
  transform: translateY(-2px);
}
.social-link svg { width: 15px; height: 15px; flex-shrink: 0; }

/* 14. FOOTER
   ============================================================================= */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  padding: 26px 0;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-copy { font-size: .875rem; color: var(--text-muted); }
.footer-nav  { display: flex; gap: 20px; }
.footer-nav a {
  font-size: .875rem;
  color: var(--text-muted);
  transition: color var(--ease);
}
.footer-nav a:hover { color: var(--text-primary); }

/* Back to top */
#back-top {
  position: fixed;
  bottom: 28px; right: 28px;
  width: 42px; height: 42px;
  background: var(--grad-main);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 4px 16px rgba(99,102,241,.4);
  transition: all var(--ease);
  opacity: 0;
  pointer-events: none;
  z-index: 200;
}
#back-top.visible { opacity: 1; pointer-events: all; }
#back-top:hover { transform: translateY(-3px); }
#back-top svg { width: 18px; height: 18px; }

/* 15. RESPONSIVE
   ============================================================================= */
@media (max-width: 1024px) {
  .hero-inner        { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual       { justify-content: flex-start; }
  .code-card         { max-width: 100%; animation: none; }
  .about-grid        { grid-template-columns: 1fr; gap: 48px; }
  .about-photo-wrap  { max-width: 100%; }
  .about-photo       { height: 340px; object-position: 72% 10%; }
  .ai-grid           { grid-template-columns: 1fr; gap: 48px; }
  .proj-img-wrap     { height: 220px; }
}

@media (max-width: 768px) {
  .section { padding: 72px 0; }
  .nav-links,
  .nav-right .btn { display: none; }
  .hamburger { display: flex; }
  .projects-grid { grid-template-columns: 1fr; }
  .skills-groups { grid-template-columns: 1fr; }
  .about-details { grid-template-columns: 1fr 1fr; }
  .hero-blob-1 { width: 320px; height: 320px; }
  .hero-blob-2 { width: 260px; height: 260px; }
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-nav   { flex-wrap: wrap; justify-content: center; }
  /* project images stay tall enough on mobile single-column */
  .proj-img-wrap { height: 260px; }
}

@media (max-width: 520px) {
  .hero-actions      { flex-direction: column; }
  .about-details     { grid-template-columns: 1fr; }
  .about-photo       { height: 280px; }
  .tech-orbit        { grid-template-columns: repeat(2, 1fr); }
  .contact-email     { font-size: 1.1rem; }
  .scroll-cue        { display: none; }
  .proj-img-wrap     { height: 230px; }
}

/* 16. HERO STATS ROW
   ============================================================================= */
.hero-stats {
  display: flex;
  gap: 36px;
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--border-subtle);
  animation: fadeUp .8s .4s ease both;
}
.hero-stat { display: flex; flex-direction: column; gap: 3px; }
.hero-stat-num {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-stat-label {
  font-size: .7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .1em;
  font-weight: 500;
}
@media (max-width: 768px) { .hero-stats { gap: 20px; } .hero-stat-num { font-size: 1.5rem; } }
@media (max-width: 520px) { .hero-stats { gap: 14px; flex-wrap: wrap; } }

/* 17. FEATURED PROJECT BADGE
   ============================================================================= */
.proj-featured-badge {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 2;
  background: var(--grad-main);
  color: #fff;
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  box-shadow: 0 2px 12px rgba(99,102,241,.5);
  pointer-events: none;
}

/* 18. PROJECT CASE STUDY ACCORDION
   ============================================================================= */
.proj-case-study {
  margin-top: 6px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 10px;
}
.proj-case-study > summary {
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-accent);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 2px 0;
  user-select: none;
  transition: color var(--ease);
}
.proj-case-study > summary::-webkit-details-marker { display: none; }
.proj-case-study > summary::before {
  content: '▶';
  font-size: .55rem;
  line-height: 1;
  transition: transform var(--ease);
  color: var(--accent-cyan);
}
.proj-case-study[open] > summary::before { transform: rotate(90deg); }
.proj-case-study > summary:hover { color: var(--accent-cyan); }
.case-study-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 0 2px;
}
.case-item { display: flex; flex-direction: column; gap: 3px; }
.case-label {
  font-size: .65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--accent-indigo);
  font-family: var(--font-mono);
}
.case-item > p { font-size: .84rem; color: var(--text-muted); line-height: 1.55; margin: 0; }

/* 19. TECH LETTER-BADGE ICONS
   ============================================================================= */
.ti {
  position: relative;
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 7px;
  font-size: .7rem; font-weight: 800;
  font-family: var(--font-mono);
  color: var(--tc, #818cf8);
  border: 1px solid var(--tc, #818cf8);
  overflow: hidden;
  flex-shrink: 0;
}
.ti::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--tc, #818cf8);
  opacity: .13;
  border-radius: inherit;
}
