/* =====================================================
   TAHMID HOSSAIN ANKUR — Portfolio
   style.css
   ===================================================== */

/* ===== RESET & BASE ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Colors */
  --bg:           #080C14;
  --bg-card:      #0D1117;
  --bg-elevated:  #111827;
  --bg-hover:     #161D2E;
  --text-primary: #F0F4FF;
  --text-secondary: #8892A4;
  --text-muted:   #4A5568;
  --accent:       #7C3AED;
  --accent-light: #9F67FF;
  --accent-glow:  rgba(124, 58, 237, 0.18);
  --blue:         #38BDF8;
  --blue-glow:    rgba(56, 189, 248, 0.12);
  --teal:         #2DD4BF;
  --green:        #34D399;
  --border:       #1C2333;
  --border-subtle: #161C27;

  /* Typography */
  --font-heading: 'Sora', sans-serif;
  --font-body:    'DM Sans', sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  /* Spacing */
  --section-gap: 7rem;
  --container:   1100px;

  /* Transitions */
  --ease:        cubic-bezier(0.16, 1, 0.3, 1);
  --ease-fast:   cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  background-color: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* Focus visible */
:focus-visible {
  outline: 2px solid var(--accent-light);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Selection */
::selection {
  background: var(--accent);
  color: #fff;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

a {
  color: inherit;
  text-decoration: none;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
}

/* ===== LAYOUT ===== */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: var(--section-gap) 0;
}

/* ===== SECTION LABEL ===== */
.section-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  color: var(--accent-light);
}

.label-line {
  display: block;
  width: 2rem;
  height: 1px;
  background: var(--accent);
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--text-primary) 60%, var(--text-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-sub {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 3.5rem;
  max-width: 560px;
}

/* ===== SCROLL REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.75s var(--ease), transform 0.75s var(--ease);
}

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

.reveal-delay-1 { transition-delay: 0.12s; }
.reveal-delay-2 { transition-delay: 0.22s; }
.reveal-delay-3 { transition-delay: 0.32s; }

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 0 0 var(--accent-glow);
}

.btn-primary:hover {
  background: var(--accent-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--accent-glow);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.btn-secondary:hover {
  border-color: var(--text-muted);
  background: var(--bg-elevated);
  transform: translateY(-2px);
}

.btn-large {
  padding: 1rem 2rem;
  font-size: 1rem;
}

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
  border-bottom: 1px solid transparent;
}

.navbar.scrolled {
  background: rgba(8, 12, 20, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--border);
}

.nav-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 68px;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.05em;
  flex-shrink: 0;
  transition: color 0.2s;
}

.nav-logo:hover {
  color: var(--accent-light);
}

.logo-bracket {
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  margin-left: auto;
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-secondary);
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
  letter-spacing: 0.04em;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: var(--bg-elevated);
}

.nav-link.active {
  color: var(--accent-light);
}

.btn-resume {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1rem;
  background: transparent;
  color: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  transition: background 0.2s, color 0.2s;
  flex-shrink: 0;
}

.btn-resume:hover {
  background: var(--accent-glow);
  color: #fff;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
}

.bar {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.3s;
}

.hamburger.open .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open .bar:nth-child(2) { opacity: 0; }
.hamburger.open .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6rem 0 4rem;
  overflow: hidden;
}

/* Animated gradient background */
.hero-bg-gradient {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.gradient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.35;
  animation: orbFloat 12s ease-in-out infinite;
}

.orb-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, #7C3AED 0%, transparent 70%);
  top: -200px;
  left: -100px;
  animation-delay: 0s;
}

.orb-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #38BDF8 0%, transparent 70%);
  top: 50%;
  right: -100px;
  animation-delay: -4s;
}

.orb-3 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #2DD4BF 0%, transparent 70%);
  bottom: 0;
  left: 40%;
  animation-delay: -8s;
  opacity: 0.2;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%       { transform: translate(30px, -40px) scale(1.05); }
  66%       { transform: translate(-20px, 20px) scale(0.97); }
}

/* Grid overlay */
.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124, 58, 237, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 58, 237, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}

.hero-container {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  column-gap: 4rem;
  row-gap: 1.5rem;
  align-items: start;
}

.hero-content {
  grid-column: 1;
  grid-row: 1 / 3;
  align-self: center;
}

.hero-visual {
  grid-column: 2;
  grid-row: 1;
}

.hero-cards {
  grid-column: 2;
  grid-row: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

/* Hero badge */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  background: rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.3);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent-light);
  margin-bottom: 1.5rem;
  width: fit-content;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulse 2.5s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--green); }
  50%       { opacity: 0.5; box-shadow: 0 0 14px var(--green); }
}

/* Hero headline */
.hero-headline {
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
}

.headline-gradient {
  background: linear-gradient(135deg, var(--accent-light), var(--blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subheadline {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 520px;
  margin-bottom: 2.5rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.hero-socials {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: color 0.2s, border-color 0.2s, background 0.2s, transform 0.2s;
}

.social-link svg {
  width: 18px;
  height: 18px;
}

.social-link:hover {
  color: var(--text-primary);
  border-color: var(--accent);
  background: var(--accent-glow);
  transform: translateY(-2px);
}

/* Hero visual */
.hero-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.photo-frame {
  position: relative;
  width: 260px;
  height: 260px;
  flex-shrink: 0;
}

.photo-placeholder {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  overflow: hidden;
}

.photo-placeholder img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
}

.placeholder-initials {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-light);
  letter-spacing: 0.05em;
}

.placeholder-hint {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
}

.photo-glow {
  position: absolute;
  inset: -2px;
  border-radius: 18px;
  background: transparent;
  border: 2px solid transparent;
  background-clip: padding-box;
  box-shadow: 0 0 40px rgba(124, 58, 237, 0.2), 0 0 80px rgba(56, 189, 248, 0.1);
  pointer-events: none;
}

/* Currently building card */
.building-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  width: 100%;
  max-width: 320px;
  animation: cardFloat 6s ease-in-out infinite;
}

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

.building-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pulse-dot {
  width: 6px;
  height: 6px;
  background: var(--accent-light);
  border-radius: 50%;
  animation: pulse 2.5s ease-in-out infinite;
  flex-shrink: 0;
}

.building-projects {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.project-pill {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  background: rgba(124, 58, 237, 0.12);
  color: var(--accent-light);
  border: 1px solid rgba(124, 58, 237, 0.2);
}

/* Code card */
.code-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0;
  width: 100%;
  max-width: 320px;
  overflow: hidden;
  animation: cardFloat 6s ease-in-out infinite;
  animation-delay: -3s;
}

.code-dots {
  display: flex;
  gap: 5px;
  padding: 0.6rem 0.9rem;
  background: rgba(0,0,0,0.2);
  border-bottom: 1px solid var(--border);
}

.code-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-muted);
  opacity: 0.5;
}

.code-dots span:nth-child(1) { background: #FF5F57; opacity: 0.7; }
.code-dots span:nth-child(2) { background: #FEBC2E; opacity: 0.7; }
.code-dots span:nth-child(3) { background: #28C840; opacity: 0.7; }

.code-snippet {
  padding: 0.85rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.7;
  white-space: pre;
  overflow: hidden;
  color: var(--text-secondary);
}

.code-kw  { color: var(--accent-light); }
.code-var { color: var(--blue); }
.code-str { color: var(--teal); }

/* Scroll hint */
.scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  animation: fadeInUp 1s 1.5s both;
}

.scroll-line {
  width: 1px;
  height: 36px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  animation: scrollDown 2s ease-in-out infinite;
}

@keyframes scrollDown {
  0%   { transform: scaleY(0); transform-origin: top; opacity: 0; }
  30%  { transform: scaleY(1); transform-origin: top; opacity: 1; }
  70%  { transform: scaleY(1); transform-origin: bottom; opacity: 1; }
  100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateX(-50%) translateY(12px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* ===== ABOUT ===== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
  margin-top: 2rem;
}

.about-text p {
  margin-bottom: 1.25rem;
}

.about-text p:last-child {
  margin-bottom: 0;
}

.about-cards {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.identity-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 1.1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: border-color 0.2s, transform 0.2s, background 0.2s;
}

.identity-card:hover {
  border-color: rgba(124, 58, 237, 0.4);
  background: var(--bg-hover);
  transform: translateX(4px);
}

.id-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--accent-glow);
  flex-shrink: 0;
  color: var(--accent-light);
}

.id-icon svg {
  width: 18px;
  height: 18px;
}

.identity-card div {
  display: flex;
  flex-direction: column;
}

.identity-card strong {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.3;
}

.identity-card span {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

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

.projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.project-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 80% 0%, rgba(124, 58, 237, 0.06), transparent 70%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}

.project-card:hover {
  border-color: rgba(124, 58, 237, 0.35);
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
}

.project-card:hover::before {
  opacity: 1;
}

.project-card.featured {
  border-color: rgba(124, 58, 237, 0.25);
}

.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.2rem;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.project-type {
  color: var(--accent-light);
  font-size: 0.7rem;
}

.card-links {
  display: flex;
  gap: 0.5rem;
}

.icon-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.icon-link svg {
  width: 14px;
  height: 14px;
}

.icon-link:hover {
  color: var(--text-primary);
  border-color: var(--accent);
  background: var(--accent-glow);
}

.project-accent {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
}

.project-accent svg {
  width: 100%;
  height: 100%;
}

.accent-purple { color: var(--accent-light); }
.accent-blue   { color: var(--blue); }
.accent-teal   { color: var(--teal); }
.accent-green  { color: var(--green); }

.project-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  font-family: var(--font-heading);
}

.project-desc {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.2rem;
}

.project-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.detail-block {
  background: var(--bg-elevated);
  border-radius: 8px;
  padding: 0.8rem;
  border: 1px solid var(--border-subtle);
}

.detail-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 0.35rem;
}

.detail-block p {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.project-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.feature-tag {
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  background: rgba(56, 189, 248, 0.08);
  color: var(--blue);
  border: 1px solid rgba(56, 189, 248, 0.15);
}

.tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.tech-pill {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.project-proves {
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.proves-label {
  color: var(--accent-light);
}

/* ===== SKILLS ===== */
.skills {
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-card) 100%);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}

.skill-group {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.4rem;
  transition: border-color 0.2s, transform 0.2s;
}

.skill-group:hover {
  border-color: rgba(124, 58, 237, 0.25);
  transform: translateY(-2px);
}

.skill-group-title {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--accent-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.9rem;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.skill-tag {
  font-size: 0.82rem;
  padding: 0.3rem 0.7rem;
  border-radius: 5px;
  background: var(--bg);
  color: var(--text-secondary);
  border: 1px solid var(--border);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.skill-tag:hover,
.skill-tag.primary {
  color: var(--text-primary);
  border-color: rgba(124, 58, 237, 0.35);
  background: var(--accent-glow);
}

/* ===== TIMELINE ===== */
.timeline {
  background: var(--bg-card);
}

.timeline-track {
  margin-top: 2.5rem;
  padding-left: 2rem;
  position: relative;
}

.timeline-track::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}

.timeline-item {
  position: relative;
  padding-bottom: 2.5rem;
  padding-left: 2rem;
}

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

.timeline-dot {
  position: absolute;
  left: -2.5rem;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--accent);
  transition: background 0.2s;
}

.timeline-item.active .timeline-dot {
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

.timeline-year {
  display: block;
  font-size: 0.75rem;
  color: var(--accent-light);
  letter-spacing: 0.07em;
  margin-bottom: 0.35rem;
  text-transform: uppercase;
}

.timeline-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
  font-family: var(--font-heading);
}

.timeline-body {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ===== GITHUB SECTION ===== */
.github-section {
  background: var(--bg);
}

.github-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-top: 2rem;
}

.github-text p {
  margin-bottom: 2rem;
  font-size: 1.05rem;
}

.github-visual {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem;
}

.gh-profile-card {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.gh-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-glow);
  border: 2px solid rgba(124, 58, 237, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-light);
  flex-shrink: 0;
}

.gh-info {
  display: flex;
  flex-direction: column;
}

.gh-info strong {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.gh-info span {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.commit-grid-label {
  color: var(--text-muted);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.6rem;
}

/* Contribution grid */
.commit-grid {
  display: grid;
  grid-template-columns: repeat(52, 1fr);
  gap: 2.5px;
  margin-bottom: 0.75rem;
}

.commit-cell {
  aspect-ratio: 1;
  border-radius: 2px;
  background: var(--border);
}

.commit-cell.l1 { background: rgba(124, 58, 237, 0.25); }
.commit-cell.l2 { background: rgba(124, 58, 237, 0.45); }
.commit-cell.l3 { background: rgba(124, 58, 237, 0.65); }
.commit-cell.l4 { background: var(--accent-light); }

.commit-grid-legend {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.legend-cells {
  display: flex;
  gap: 3px;
}

.legend-cell {
  width: 11px;
  height: 11px;
  border-radius: 2px;
}

.legend-cell.l0 { background: var(--border); }
.legend-cell.l1 { background: rgba(124, 58, 237, 0.25); }
.legend-cell.l2 { background: rgba(124, 58, 237, 0.45); }
.legend-cell.l3 { background: rgba(124, 58, 237, 0.65); }
.legend-cell.l4 { background: var(--accent-light); }

.project-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cat-pill {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 0.25rem 0.65rem;
  border-radius: 100px;
  border: 1px solid;
}

.cat-fullstack { color: var(--accent-light); border-color: rgba(124, 58, 237, 0.3); background: var(--accent-glow); }
.cat-api       { color: var(--blue);         border-color: rgba(56, 189, 248, 0.3); background: var(--blue-glow); }
.cat-ui        { color: var(--teal);         border-color: rgba(45, 212, 191, 0.3); background: rgba(45, 212, 191, 0.08); }
.cat-db        { color: var(--green);        border-color: rgba(52, 211, 153, 0.3); background: rgba(52, 211, 153, 0.08); }

/* ===== MORE THAN CODE ===== */
.more-section {
  background: var(--bg-card);
}

.more-quote {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 680px;
  border-left: 2px solid var(--accent);
  padding-left: 1.5rem;
  margin-bottom: 3rem;
  font-style: italic;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.value-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.4rem;
  transition: border-color 0.2s, transform 0.2s;
}

.value-card:hover {
  border-color: rgba(124, 58, 237, 0.3);
  transform: translateY(-3px);
}

.value-icon {
  width: 36px;
  height: 36px;
  color: var(--accent-light);
  margin-bottom: 0.85rem;
}

.value-icon svg {
  width: 100%;
  height: 100%;
}

.value-card h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  font-family: var(--font-heading);
}

.value-card p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* ===== CONTACT ===== */
.contact {
  background: var(--bg);
}

.contact-intro {
  font-size: 1.1rem;
  max-width: 580px;
  margin-bottom: 2.5rem;
  color: var(--text-secondary);
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 480px;
  margin-bottom: 2.5rem;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: border-color 0.2s, transform 0.2s, background 0.2s;
}

.contact-card:hover {
  border-color: rgba(124, 58, 237, 0.4);
  background: var(--bg-hover);
  transform: translateX(4px);
}

.contact-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--accent-glow);
  color: var(--accent-light);
  flex-shrink: 0;
}

.contact-icon svg {
  width: 18px;
  height: 18px;
}

.contact-card div {
  display: flex;
  flex-direction: column;
}

.contact-card strong {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.3;
}

.contact-card span {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* ===== FOOTER ===== */
.footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.footer-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: color 0.2s, border-color 0.2s, transform 0.2s;
}

.footer-back svg {
  width: 16px;
  height: 16px;
}

.footer-back:hover {
  color: var(--accent-light);
  border-color: var(--accent);
  transform: translateY(-2px);
}

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

/* Tablet */
@media (max-width: 900px) {
  :root {
    --section-gap: 5rem;
  }

  .hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
    text-align: center;
  }

  .hero-visual {
    order: 1;
    align-items: center;
  }

  .hero-content {
    order: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-cards {
    order: 3;
    width: 100%;
    align-items: center;
  }

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

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

  .hero-badge {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-subheadline {
    max-width: 100%;
  }

  .photo-frame {
    width: 200px;
    height: 200px;
  }

  .building-card,
  .code-card {
    max-width: 380px;
    width: 100%;
  }

  .scroll-hint {
    display: none;
  }

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

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

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

  .github-content {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

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

/* Mobile */
@media (max-width: 640px) {
  :root {
    --section-gap: 4rem;
  }

  .hamburger {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    background: rgba(8, 12, 20, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    gap: 0;
    padding: 1rem 0;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s var(--ease), opacity 0.3s;
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .nav-link {
    width: 100%;
    text-align: center;
    padding: 0.85rem 1.5rem;
    border-radius: 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.9rem;
  }

  .btn-resume {
    display: none;
  }

  .hero-container {
    gap: 2rem;
  }

  .hero-headline {
    font-size: clamp(1.7rem, 7vw, 2.5rem);
  }

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

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

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

  .timeline-track {
    padding-left: 1.5rem;
  }

  .commit-grid {
    grid-template-columns: repeat(26, 1fr);
  }

  .section-title {
    font-size: clamp(1.5rem, 6vw, 2.2rem);
  }
}

/* Very small screens */
@media (max-width: 400px) {
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .btn-primary,
  .btn-secondary {
    justify-content: center;
  }
}
