:root {
  --bg: #0b0e14;
  --panel: #111520;
  --muted: #94a3b8;
  --text: #e5e7eb;
  --brand: #60a5fa;
  --brand-2: #a78bfa;
  --ring: #7dd3fc;
  --ok: #34d399;
  --warn: #f59e0b;
  --shadow: 0 10px 30px rgba(0,0,0,.35);
  --radius: 16px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; 
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
  background: var(--bg);
  color: var(--text);
}
a { color: inherit; }
.container { max-width: 1000px; margin: 0 auto; padding: 24px; }

.card {
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(8px);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
header.card { padding: 24px; display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 16px; }
.avatar { width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); display: grid; place-items: center; font-weight: 800; color: white; letter-spacing: .5px; }
.title h1 { margin: 0; font-size: 1.5rem; }
.title p { margin: 2px 0 0; color: var(--muted); font-size: .95rem; }

.nav { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.nav button, .nav a.button {
  appearance: none; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.04); color: var(--text);
  padding: 10px 14px; border-radius: 12px; cursor: pointer; font-weight: 600; letter-spacing: .2px; text-decoration: none;
  transition: transform .08s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.nav button:hover, .nav a.button:hover { border-color: rgba(255,255,255,.28); transform: translateY(-1px); }
.nav button[aria-current="page"] { outline: 2px solid var(--ring); outline-offset: 2px; background: rgba(125, 211, 252, .08); }
.nav a.button.primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); border: none; }

main { margin-top: 18px; }
section.card { padding: 24px; display: none; }
section.card.active { display: block; }

.row { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 860px) { .row { grid-template-columns: 1.1fr .9fr; } }

.muted { color: var(--muted); }
.pill { font-size: .8rem; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); }
.icons { display: flex; gap: 10px; align-items: center; }
.icons a { display: inline-flex; padding: 8px; border-radius: 12px; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.04); }
.icons a:hover { border-color: rgba(255,255,255,.28); transform: translateY(-1px); }

.edulist { display: grid; grid-template-columns: 1fr; gap: 12px; }
.edu { display: grid; grid-template-columns: 60px 1fr; gap: 14px; align-items: center; padding: 10px; border-radius: 12px; border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.03); }
.edu img { width: 60px; height: 60px; object-fit: contain; border-radius: 10px; background: transparent; }
.edu h4 { margin: 0; }
.edu p { margin: 4px 0 0; color: var(--muted); }
.edugroup {
  margin-top: 18px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  background: rgba(255,255,255,.03);
  overflow: hidden;
}

.edugroup + .edugroup { margin-top: 14px; }

.edugroup summary {
  list-style: none; /* hides default marker in some browsers */
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: space-between;
  padding: 12px 14px;
  cursor: pointer;
  user-select: none;
  font-weight: 600;
}

/* Hide native marker consistently */
.edugroup summary::-webkit-details-marker { display: none; }

/* Left side of summary: caret + label */
.edugroup summary .label {
  flex: 1;
}

/* Count pill on the right */
.edugroup summary .count {
  font-size: .8rem;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  color: var(--muted);
}

/* Custom caret */
.edugroup summary .chev {
  transition: transform .15s ease;
  width: 18px;
  text-align: center;
  opacity: .9;
}

.edugroup[open] summary .chev {
  transform: rotate(90deg);
}

/* Inner list spacing */
.edugroup .edulist {
  padding: 12px;
}

.timeline { position: relative; margin: 8px 0 0; }
.timeline::before { content: ""; position: absolute; left: 14px; top: 0; bottom: 0; width: 2px; background: rgba(255,255,255,.12); }
.job { position: relative; margin-left: 38px; padding: 12px 12px 12px 14px; border-radius: 12px; border: 1px solid rgba(255,255,255,.08); background: rgba(255,255,255,.03); margin-bottom: 12px; }
.job::before { content: ""; position: absolute; left: -26px; top: 14px; width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); box-shadow: 0 0 0 3px rgba(99,102,241,.25); }
.job h4 { margin: 0; font-size: 1rem; }
.job .meta { margin-top: 4px; font-size: .9rem; color: var(--muted); }
.job p { margin: 8px 0 0; }

footer { text-align: center; color: var(--muted); margin: 24px 0 12px; font-size: .9rem; }
.visually-hidden { position: absolute !important; height: 1px; width: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

/* Project content area spacing */
.proj-body { padding: 12px; }
.proj-body p { margin: 0 0 8px; }
.proj-img {
  margin: 12px 0;
  text-align: center;
}
.proj-img img {
  width: auto;
  max-width: 100%;
  max-height: 280px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,.4);
  object-fit: contain;
}
.proj-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  padding: 8px 10px;
  border-radius: 10px;
}
.proj-link:hover { border-color: rgba(255,255,255,.28); transform: translateY(-1px); }

/* Load Aurebesh */
@font-face {
  font-family: 'Aurebesh';
  src:
    url('assets/fonts/Aurebesh.woff2') format('woff2'),
    url('assets/fonts/Aurebesh.woff') format('woff'),
    url('assets/fonts/Aurebesh.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* Name crossfade stack */
.name-stack {
  position: relative;
  display: inline-block;
  line-height: 1.1;
}

.name-stack .face {
  display: inline-block;
  transition: opacity .3s ease;
  white-space: nowrap;
}

.name-stack .face-normal {
  /* stays in normal flow to determine size */
  position: relative;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial;
}

.name-stack .face-aurebesh {
  position: absolute;
  inset: 0;              /* overlay the normal face */
  font-family: 'Aurebesh', Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial;
}

/* Animations (unchanged) */
@keyframes fontSwapOut {
  0%, 35% { opacity: 1; }
  45%, 85% { opacity: 0; }
  100% { opacity: 1; }
}
@keyframes fontSwapIn {
  0%, 35% { opacity: 0; }
  45%, 85% { opacity: 1; }
  100% { opacity: 0; }
}
.name-stack .face-normal   { animation: fontSwapOut 10s ease-in-out infinite; }
.name-stack .face-aurebesh { animation: fontSwapIn  10s ease-in-out infinite; }

.name-stack:hover .face-normal,
.name-stack:hover .face-aurebesh { animation-play-state: paused; }

@media (prefers-reduced-motion: reduce) {
  .name-stack .face-normal,
  .name-stack .face-aurebesh { animation: none; }
  .name-stack .face-aurebesh { opacity: 0; }
}

.profile-photo {
  margin: 0 0 12px 0;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* Keep a nice portrait shape; adjust ratio if you like */
.profile-photo img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 400px;
  aspect-ratio: 4 / 5;      /* common portrait ratio */
  object-fit: cover;        /* fills the frame, trims edges if needed */
  background: rgba(255,255,255,.02);
}

.hero {
  text-align: center;
  padding: 28px 8px 8px;
}

.home-title {
  margin: 0 0 8px;
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: .2px;
}

.home-subtitle {
  margin: 0 0 36px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
}

/* Make the icon row match the subtitle height */
.home-icons {
  justify-content: center;
  gap: 12px;
  margin-bottom: 36px;
  font-size: 1rem;   /* icon size ties to subtitle size */
}
.home-icons svg { width: 1em; height: 1em; }

/* Aurebesh line */
.home-aurebesh {
  margin: 6px 0 0;
  font-family: 'Aurebesh', Inter, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial;
  font-size: 1rem;
  opacity: .9;
}
