@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --bg:         #161618;
  --bg-2:       #111113;
  --bg-3:       #1c1c1f;
  --bg-card:    #1a1a1d;
  --rule:       #272729;
  --rule-2:     #303034;
  --cream:      #f0ebe2;
  --cream-dim:  #a09890;
  --cream-pale: #2a2825;
  --off:        #e8e3da;
  --muted:      #9c9890;
  --body-text:  #d8d4ce;
  --serif:      'Cormorant Garamond', Georgia, serif;
  --ui:         'Outfit', sans-serif;
  --nav-w:      220px;
}

[data-theme="light"] {
  --bg:         #f5f3ef;
  --bg-2:       #eeebe5;
  --bg-3:       #e8e4dd;
  --bg-card:    #f0ece6;
  --rule:       #d8d2c8;
  --rule-2:     #c8c0b4;
  --cream:      #1a1816;
  --cream-dim:  #5a524a;
  --cream-pale: #d8d2c8;
  --off:        #2a2420;
  --muted:      #7a726a;
  --body-text:  #3a3430;
}

/* ─── THEME TOGGLE BUTTON ─── */
.theme-toggle {
  background: transparent;
  border: 1px solid var(--rule-2);
  color: var(--muted);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 2px;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  flex-shrink: 0;
}

.theme-toggle:hover {
  color: var(--cream);
  border-color: var(--cream-dim);
}

.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }

[data-theme="light"] .theme-toggle .icon-sun { display: block; }
[data-theme="light"] .theme-toggle .icon-moon { display: none; }

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

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

body {
  background: var(--bg-2);
  color: var(--body-text);
  font-family: var(--ui);
  font-weight: 300;
  min-height: 100vh;
  display: flex;
}

/* ─── SIDEBAR NAV ─── */
.nav {
  width: var(--nav-w);
  min-height: 100vh;
  background: var(--bg-2);
  border-right: 1px solid var(--rule);
  position: fixed;
  top: 0; left: 0; bottom: 0;
  display: flex;
  flex-direction: column;
  z-index: 100;
}

.nav-logo {
  padding: 28px 24px 24px;
  border-bottom: 1px solid var(--rule);
}

.nav-logo .name {
  font-family: var(--serif);
  font-size: 2.125rem;
  font-weight: 300;
  color: var(--cream);
  line-height: 1.05;
}

.nav-logo .name em { font-style: italic; color: var(--cream-dim); }

.nav-logo .title {
  margin-top: 8px;
  font-size: 0.5938rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

.nav-links {
  flex: 1;
  padding: 16px 0;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 24px;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.8438rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s, background 0.2s;
  border-left: 2px solid transparent;
  position: relative;
}

.nav-link:hover {
  color: var(--body-text);
  background: rgba(255,255,255,0.02);
}

.nav-link.active {
  color: var(--cream);
  border-left-color: var(--cream-dim);
  background: rgba(240,235,226,0.04);
}

.nav-link svg {
  width: 14px; height: 14px;
  flex-shrink: 0;
  opacity: 0.6;
}

.nav-link.active svg { opacity: 1; }

/* ─── LANG TOGGLE ─── */
.lang-toggle {
  background: transparent;
  border: 1px solid var(--rule-2);
  color: var(--muted);
  height: 36px;
  padding: 0 9px;
  font-family: var(--ui);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 2px;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  flex-shrink: 0;
}
.lang-toggle:hover {
  color: var(--cream);
  border-color: var(--cream-dim);
  background: rgba(255,255,255,0.04);
}

.nav-footer {
  padding: 20px 24px;
  border-top: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.nav-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.status-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #6dbe8d;
  flex-shrink: 0;
}

/* ─── MAIN CONTENT ─── */
.content {
  margin-left: var(--nav-w);
  flex: 1;
  min-height: 100vh;
}

/* pages */
.page {
  display: none;
  min-height: 100vh;
}

.page.active { display: block; }
#home.active { display: flex; flex-direction: column; }

/* ─── PAGE HEADER ─── */
.page-header {
  padding: 48px 52px 36px;
  border-bottom: 1px solid var(--rule);
}

.page-header .eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.page-header h1 {
  font-family: var(--serif);
  font-size: 3.625rem;
  font-weight: 300;
  color: var(--cream);
  line-height: 1;
  letter-spacing: -0.01em;
}

.page-header h1 em {
  font-style: italic;
  color: var(--cream-dim);
}

.page-header .sub {
  margin-top: 14px;
  font-size: 1.0rem;
  color: var(--muted);
  font-weight: 300;
  max-width: 560px;
  line-height: 1.7;
}

/* ─── SECTION TITLE ─── */
.sec-header {
  padding: 36px 52px 0;
  border-top: 1px solid var(--rule);
}

.sec-title {
  display: flex;
  align-items: baseline;
  margin-bottom: 0;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--rule);
}

.sec-title h2 {
  font-family: var(--serif);
  font-size: 2.6rem;
  font-weight: 300;
  font-style: italic;
  color: var(--cream);
  letter-spacing: -0.01em;
}

.sec-title .rule { display: none; }

/* ─── CARDS ─── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--rule);
  padding: 22px 24px;
  transition: border-color 0.2s;
}

.card:hover { border-color: var(--rule-2); }

/* ─── LANDING PAGE ─── */
#home .hero {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 0;
  min-height: calc(100vh - 80px);
}

#home .hero-left {
  padding: 48px 52px 44px;
  border-right: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  gap: 0;
  justify-content: space-between;
}

#home .hero-right {
  padding: 32px 34px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hero-name {
  font-family: var(--serif);
  font-size: 4.5rem;
  font-weight: 300;
  color: var(--cream);
  line-height: 0.9;
  letter-spacing: -0.02em;
}

.hero-name em { font-style: italic; color: var(--cream-dim); }

.hero-role {
  margin-top: 18px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-bio {
  margin-top: 24px;
  font-size: 0.9375rem;
  line-height: 1.85;
  color: var(--body-text);
  font-weight: 300;
  max-width: 620px;
}

.hero-bio strong { color: var(--cream); font-weight: 500; }

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 28px;
}

.chip {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 13px;
  border: 1px solid var(--rule-2);
  color: var(--cream-dim);
  background: transparent;
  transition: border-color 0.2s, color 0.2s;
}

.chip:hover { border-color: var(--cream-dim); color: var(--cream); }

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--ui);
  font-size: 0.7188rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 11px 22px;
  border: 1px solid var(--rule-2);
  color: var(--cream-dim);
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
}

.btn:hover { border-color: var(--cream); color: var(--cream); background: rgba(240,235,226,0.04); }

.btn-primary {
  background: var(--cream);
  color: var(--bg-2);
  border-color: var(--cream);
}

.btn-primary:hover { background: var(--off); color: var(--bg-2); }

/* hero right — info blocks */
.info-block {
  padding: 20px 0;
  border-bottom: 1px solid var(--rule);
}

.info-block:first-child { padding-top: 0; }
.info-block:last-child { border-bottom: none; }

.info-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 11px;
}

/* contact items in hero */
.contact-list { display: flex; flex-direction: column; gap: 8px; }

.contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8438rem;
  color: var(--body-text);
}

.contact-item svg { width: 14px; height: 14px; opacity: 0.5; flex-shrink: 0; }

/* skill tags in hero */
.skill-wrap { display: flex; flex-wrap: wrap; gap: 6px; }

.skill-pill {
  font-size: 0.7812rem;
  color: var(--body-text);
  border: 1px solid var(--rule);
  padding: 5px 12px;
  background: var(--bg-3);
}

/* stats row — fixed footer on home page */
.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--rule);
  background: var(--bg-2);
  position: sticky;
  bottom: 0;
  z-index: 10;
}

.stat-item {
  padding: 18px 52px;
  border-right: 1px solid var(--rule);
}

.stat-item:last-child { border-right: none; }

.stat-num {
  font-family: var(--serif);
  font-size: 2.75rem;
  font-weight: 300;
  color: var(--cream);
  line-height: 1;
}

.stat-label {
  margin-top: 5px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ─── PROJECTS PAGE ─── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--rule);
}

.project-card {
  background: var(--bg);
  padding: 28px 30px;
  transition: background 0.2s;
  text-decoration: none;
  display: block;
}

.project-card:hover { background: var(--bg-card); }

.project-card .p-type {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.project-card .p-title {
  font-family: var(--serif);
  font-size: 1.875rem;
  font-weight: 400;
  color: var(--cream);
  line-height: 1.2;
  margin-bottom: 10px;
}

.project-card .p-desc {
  font-size: 0.875rem;
  line-height: 1.75;
  color: var(--body-text);
  font-weight: 300;
  margin-bottom: 16px;
}

.project-card .p-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.p-tag {
  font-size: 0.75rem;
  color: var(--cream-dim);
  border: 1px solid var(--rule-2);
  padding: 4px 11px;
}

/* ─── HOME TRAIT CARDS ─── */
.home-traits {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--rule);
  margin-top: 28px;
  border: 1px solid var(--rule);
}

.home-trait {
  background: var(--bg);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-top: 2px solid transparent;
  transition: background 0.2s, border-top-color 0.2s;
}

.home-trait:hover {
  background: var(--bg-card);
  border-top-color: var(--cream-dim);
}

.home-trait-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
}

.home-trait-desc {
  font-size: 0.82rem;
  line-height: 1.6;
  color: var(--body-text);
  font-weight: 300;
}

@media (max-width: 900px) {
  .home-traits { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .home-traits { grid-template-columns: 1fr; }
}

/* ─── PROJECT BULLETS ─── */
.p-bullet {
  font-size: 13px;
  color: var(--body-text);
  padding-left: 12px;
  position: relative;
  font-weight: 300;
  line-height: 1.6;
}

.p-bullet-dash {
  position: absolute;
  left: 0;
  color: var(--muted);
}

/* ─── COMPETITIONS PAGE ─── */
.comp-list { display: flex; flex-direction: column; gap: 1px; }

.comp-item {
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 0 28px;
  padding: 24px 52px;
  border-bottom: 1px solid var(--rule);
  align-items: start;
  transition: background 0.2s;
}

.comp-item:hover { background: rgba(255,255,255,0.015); }

.comp-year {
  font-family: var(--serif);
  font-size: 2.25rem;
  font-weight: 300;
  color: var(--cream-dim);
  line-height: 1;
}

.comp-body {}

.comp-name {
  font-size: 1.1875rem;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 6px;
}

.comp-org {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

.comp-desc {
  font-size: 0.875rem;
  line-height: 1.75;
  color: var(--body-text);
  font-weight: 300;
  max-width: 580px;
}

.comp-badge {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cream-dim);
  border: 1px solid var(--rule-2);
  padding: 6px 14px;
  white-space: nowrap;
  margin-top: 2px;
}

/* ─── GITHUB PAGE ─── */
.github-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 52px;
  border-bottom: 1px solid var(--rule);
}

.github-user {
  display: flex;
  align-items: center;
  gap: 16px;
}

.gh-avatar {
  width: 56px; height: 56px;
  border-radius: 50%;
  border: 1px solid var(--rule-2);
  overflow: hidden;
  background: var(--bg-3);
  display: flex;
  align-items: center;
  justify-content: center;
}

.gh-avatar img { width: 100%; height: 100%; object-fit: cover; }
.gh-avatar svg { opacity: 0.3; }

.gh-name {
  font-size: 1.1875rem;
  font-weight: 600;
  color: var(--cream);
}

.gh-handle {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: 3px;
}

.gh-stats {
  display: flex;
  gap: 28px;
}

.gh-stat {
  text-align: center;
}

.gh-stat-num {
  font-family: var(--serif);
  font-size: 1.875rem;
  font-weight: 300;
  color: var(--cream);
  line-height: 1;
}

.gh-stat-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

.repos-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--rule);
}

.repo-card {
  background: var(--bg);
  padding: 26px 30px;
  transition: background 0.2s;
  cursor: pointer;
}

.repo-card:hover { background: var(--bg-card); }

.repo-card a { text-decoration: none; }

.repo-name {
  font-size: 1.0rem;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 8px;
}

.repo-desc {
  font-size: 0.8125rem;
  line-height: 1.65;
  color: var(--body-text);
  font-weight: 300;
  margin-bottom: 16px;
  min-height: 36px;
}

.repo-meta {
  display: flex;
  align-items: center;
  gap: 14px;
}

.repo-lang {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--muted);
}

.lang-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
}

.repo-stars {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--muted);
}

.repo-updated {
  font-size: 0.75rem;
  color: var(--muted);
  margin-left: auto;
}

.gh-loading, .gh-error {
  padding: 60px 52px;
  font-size: 0.75rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 12px;
}

.gh-input-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 52px;
  border-bottom: 1px solid var(--rule);
}

.gh-input {
  background: var(--bg-3);
  border: 1px solid var(--rule-2);
  color: var(--cream);
  font-family: var(--ui);
  font-size: 0.6875rem;
  padding: 8px 14px;
  outline: none;
  width: 260px;
  transition: border-color 0.2s;
}

.gh-input::placeholder { color: var(--muted); }
.gh-input:focus { border-color: var(--cream-dim); }

/* ─── ABOUT / EXPERIENCE ─── */
.exp-timeline {
  padding: 0 52px;
}

.exp-item {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 0 32px;
  padding: 28px 0;
  border-bottom: 1px solid var(--rule);
}

.exp-item:last-child { border-bottom: none; }

.exp-period {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.7;
  padding-top: 3px;
  white-space: nowrap;
}

.ep-date {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--cream-dim);
  white-space: nowrap;
}

.ep-loc {
  font-size: 0.7188rem;
  font-weight: 400;
  color: var(--muted);
  margin-bottom: 8px;
  white-space: nowrap;
}

.exp-period .type-badge {
  display: inline-block;
  margin-top: 5px;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0;
  border: none;
}

.exp-content .exp-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 3px;
}

.exp-content .exp-company {
  font-size: 0.8125rem;
  color: var(--cream-dim);
  font-weight: 500;
  margin-bottom: 12px;
}

.exp-content ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.exp-content ul li {
  font-size: 0.875rem;
  line-height: 1.65;
  color: var(--body-text);
  font-weight: 300;
  padding-left: 18px;
  position: relative;
}

.exp-content ul li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--muted);
  font-size: 0.75rem;
}




/* ─── MOBILE NAV TOGGLE ─── */
.nav-toggle {
  display: none;
  position: fixed;
  top: 14px; left: 14px;
  z-index: 200;
  background: var(--bg-2);
  border: 1px solid var(--rule-2);
  color: var(--cream);
  width: 42px; height: 42px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 2px;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 900px) {

  /* ── Nav overlay ── */
  .nav {
    width: 100%;
    max-width: 300px;
    transform: translateX(-100%);
    transition: transform 0.28s ease;
    z-index: 150;
  }

  .nav.open { transform: translateX(0); }

  /* dim overlay behind nav */
  .nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 140;
  }

  .nav-overlay.open { display: block; }

  .content { margin-left: 0; }
  .nav-toggle { display: flex; }

  /* ── HOME ── */
  #home .hero {
    grid-template-columns: 1fr;
    min-height: unset;
  }

  #home .hero-left {
    padding: 72px 24px 28px;
    justify-content: flex-start;
    gap: 0;
  }

  .hero-name {
    font-size: 2.6rem;
    line-height: 1;
  }

  .hero-role {
    font-size: 0.65rem;
    margin-top: 14px;
  }

  .hero-bio {
    font-size: 0.88rem;
    line-height: 1.8;
    margin-top: 18px;
    max-width: 100%;
  }

  .hero-chips {
    margin-top: 20px;
    gap: 6px;
  }

  .chip { font-size: 0.6rem; padding: 5px 10px; }

  .hero-actions {
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
    padding-top: 20px;
  }

  .btn { font-size: 0.6rem; padding: 10px 16px; }

  /* hero-right: show as stacked info sections below bio */
  #home .hero-right {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--rule);
    padding: 0 24px 24px;
  }

  .info-block { padding: 16px 0; }
  .info-block:first-child { padding-top: 20px; }

  .info-label { font-size: 0.58rem; }

  .contact-item { font-size: 0.8rem; }

  .skill-pill { font-size: 0.7rem; padding: 4px 10px; }

  /* stats row — 3 columns still but compact */
  .stats-row {
    position: static; /* remove sticky on mobile — causes iOS issues */
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--rule);
  }

  .stat-item {
    padding: 16px 16px;
    border-right: 1px solid var(--rule);
  }

  .stat-num { font-size: 1.8rem; }
  .stat-label { font-size: 0.55rem; letter-spacing: 0.1em; }

  /* ── PAGE HEADERS ── */
  .page-header {
    padding: 72px 24px 24px;
  }

  .page-header .eyebrow { font-size: 0.6rem; }
  .page-header h1 { font-size: 2.2rem; }
  .page-header .sub { font-size: 0.85rem; max-width: 100%; }

  /* ── SECTION TITLES ── */
  .sec-header { padding: 28px 24px 0; }
  .sec-title h2 { font-size: 1.4rem; }
  .exp-timeline { padding: 0 24px; }

  .exp-item {
    grid-template-columns: 1fr;
    gap: 8px 0;
    padding: 22px 0;
  }

  .ep-date { font-size: 0.75rem; }
  .ep-loc  { font-size: 0.65rem; }

  .exp-content .exp-title   { font-size: 1rem; }
  .exp-content .exp-company { font-size: 0.75rem; }
  .exp-content ul li        { font-size: 0.8rem; }

  /* ── PROJECTS ── */
  .projects-grid { grid-template-columns: 1fr; }

  .project-card { padding: 22px 24px; }
  .project-card .p-type  { font-size: 0.6rem; }
  .project-card .p-title { font-size: 1.3rem; }
  .project-card .p-desc  { font-size: 0.8rem; }
  .p-tag { font-size: 0.65rem; padding: 3px 9px; }

  /* ── COMPETITIONS ── */
  .comp-item {
    grid-template-columns: 1fr;
    gap: 10px 0;
    padding: 22px 24px;
  }

  .comp-year { font-size: 1.4rem; }
  .comp-name { font-size: 1rem; }
  .comp-org  { font-size: 0.62rem; }
  .comp-desc { font-size: 0.8rem; max-width: 100%; }
  .comp-badge { font-size: 0.6rem; align-self: flex-start; }

  /* ── GITHUB ── */
  .github-header {
    padding: 20px 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .gh-name   { font-size: 1rem; }
  .gh-handle { font-size: 0.75rem; }
  .gh-stats  { gap: 20px; }
  .gh-stat-num   { font-size: 1.4rem; }
  .gh-stat-label { font-size: 0.58rem; }

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

  .repo-card { padding: 18px 24px; }
  .repo-name { font-size: 0.9rem; }
  .repo-desc { font-size: 0.75rem; }
  .repo-lang, .repo-stars, .repo-updated { font-size: 0.68rem; }

  .gh-loading, .gh-error { padding: 40px 24px; font-size: 0.8rem; }
}

/* extra small phones */
@media (max-width: 400px) {
  .hero-name { font-size: 2.1rem; }
  .hero-actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
  .stats-row { grid-template-columns: 1fr; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--rule); }
}

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

.fade-up {
  opacity: 0;
  animation: fadeUp 0.5s ease forwards;
}

.fade-up:nth-child(1) { animation-delay: 0.05s; }
.fade-up:nth-child(2) { animation-delay: 0.12s; }
.fade-up:nth-child(3) { animation-delay: 0.19s; }
.fade-up:nth-child(4) { animation-delay: 0.26s; }
.fade-up:nth-child(5) { animation-delay: 0.33s; }
.fade-up:nth-child(6) { animation-delay: 0.40s; }

/* spinner */
.spinner {
  width: 16px; height: 16px;
  border: 1.5px solid var(--rule-2);
  border-top-color: var(--cream-dim);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }
