:root{
  --bg:#0b0d12;
  --panel:#111522;
  --alt:#0f1320;
  --text:#e9eefc;
  --muted:#aab3cf;
  --border:rgba(255,255,255,.10);
  --accent:#7aa2ff;
  --shadow:0 10px 30px rgba(0,0,0,.35);
  --radius:18px;
  --max:1100px;
  --pad:22px;
  --font:"Inter",system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:var(--font);
  background:radial-gradient(1000px 500px at 20% 0%, rgba(122,162,255,.18), transparent 60%),
             radial-gradient(800px 500px at 90% 10%, rgba(255,255,255,.08), transparent 60%),
             var(--bg);
  color:var(--text);
  line-height:1.6;
}

a{color:inherit}
.container{max-width:var(--max); margin:0 auto; padding:0 18px}

.skip-link{
  position:absolute; left:-999px; top:10px;
  background:var(--text); color:#000; padding:10px 14px; border-radius:10px;
}
.skip-link:focus{left:10px; z-index:999}

.header{
  position:sticky; top:0; z-index:50;
  backdrop-filter:blur(10px);
  background:rgba(11,13,18,.65);
  border-bottom:1px solid var(--border);
}
.header__inner{
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 0;
}

.brand{display:flex; align-items:center; gap:12px}
.brand__mark{
  width:44px; height:44px; border-radius:14px;
  display:grid; place-items:center;
  background:linear-gradient(135deg, rgba(122,162,255,.25), rgba(255,255,255,.08));
  border:1px solid var(--border);
  font-weight:800;
}
.brand__name{font-weight:800}
.brand__tag{color:var(--muted); font-size:.92rem}

.nav{display:flex; align-items:center; gap:10px}
.nav__toggle{
  display:none;
  border:1px solid var(--border);
  background:transparent;
  color:var(--text);
  padding:10px 12px;
  border-radius:12px;
  cursor:pointer;
}
.nav__links{display:flex; gap:14px; align-items:center}
.nav__links a{
  text-decoration:none;
  color:var(--muted);
  padding:10px 10px;
  border-radius:12px;
}
.nav__links a:hover{color:var(--text); background:rgba(255,255,255,.06)}

.hero{padding:56px 0 22px}
.hero__inner{
  display:grid;
  grid-template-columns: 1.35fr .85fr;
  gap:20px;
  align-items:start;
}
.hero h1{font-size:2.6rem; line-height:1.15; margin:0 0 14px}
.accent{color:var(--accent)}
.lead{color:var(--muted); font-size:1.05rem; margin:0 0 18px}

.cta{display:flex; gap:12px; flex-wrap:wrap; margin:18px 0 14px}
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  text-decoration:none;
  padding:12px 16px;
  border-radius:14px;
  background:linear-gradient(135deg, rgba(122,162,255,.35), rgba(255,255,255,.08));
  border:1px solid var(--border);
  box-shadow:var(--shadow);
  font-weight:700;
}
.btn--ghost{
  background:transparent;
  box-shadow:none;
}
.links{color:var(--muted); display:flex; gap:10px; flex-wrap:wrap}
.links a{color:var(--muted); text-decoration:none}
.links a:hover{color:var(--text)}

.card{
  background:linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:var(--pad);
  box-shadow:var(--shadow);
}
.card__title{font-weight:800; margin-bottom:10px}
.card__list{margin:0; padding-left:18px; color:var(--muted)}
.card__note{margin-top:12px; color:var(--muted); font-size:.92rem}

.section{padding:54px 0}
.section--alt{background:rgba(255,255,255,.03); border-top:1px solid var(--border); border-bottom:1px solid var(--border)}
.section h2{font-size:1.8rem; margin:0 0 14px}
.muted{color:var(--muted)}
.small{font-size:.92rem}

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

.panel{
  background:rgba(255,255,255,.04);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:18px;
}
.panel h3{margin:0 0 10px}
.panel ul{margin:0; padding-left:18px; color:var(--muted)}

.section__head{display:flex; align-items:baseline; justify-content:space-between; gap:14px; flex-wrap:wrap}

.cards{
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:16px;
  margin-top:16px;
}
.project{
  background:linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:18px;
  box-shadow:var(--shadow);
}
.project h3{margin:0 0 8px}
.project p{margin:0 0 12px; color:var(--muted)}
.tags{list-style:none; padding:0; margin:0 0 10px; display:flex; flex-wrap:wrap; gap:8px}
.tags li{
  font-size:.85rem;
  color:var(--muted);
  border:1px solid var(--border);
  background:rgba(255,255,255,.03);
  padding:6px 10px;
  border-radius:999px;
}
.project__meta{color:var(--muted); font-size:.95rem}
.link{color:var(--accent); text-decoration:none}
.link:hover{text-decoration:underline}

.timeline{display:grid; gap:16px; margin-top:14px}
.role{
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:18px;
  background:rgba(255,255,255,.03);
}
.role__top{display:flex; align-items:baseline; justify-content:space-between; gap:12px; flex-wrap:wrap}
.role ul{margin:12px 0 0; padding-left:18px; color:var(--muted)}

.contact{display:flex; gap:12px; flex-wrap:wrap; margin-top:12px}

.footer{
  border-top:1px solid var(--border);
  padding:24px 0;
  color:var(--muted);
}
.footer__inner{display:flex; justify-content:space-between; gap:10px; flex-wrap:wrap}

@media (max-width: 900px){
  .hero__inner{grid-template-columns:1fr}
  .cards{grid-template-columns:1fr}
  .grid--2{grid-template-columns:1fr}
  .grid--3{grid-template-columns:1fr}
  .nav__toggle{display:inline-flex}
  .nav__links{
    display:none;
    position:absolute;
    right:18px;
    top:66px;
    background:rgba(11,13,18,.95);
    border:1px solid var(--border);
    border-radius:16px;
    padding:10px;
    flex-direction:column;
    min-width:180px;
  }
  .nav__links.is-open{display:flex}
}


/* === Hide ENTIRE Projects section when collapsed === */
#projects.is-collapsed .container {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-6px);
  padding-top: 0;
  padding-bottom: 0;
  transition: 
    max-height 450ms ease,
    opacity 250ms ease,
    transform 250ms ease,
    padding 300ms ease;
}

/* === Show everything when expanded === */
#projects .container {
  max-height: 2000px; /* big enough for your content */
  overflow: hidden;
  opacity: 1;
  transform: translateY(0);
  transition: 
    max-height 450ms ease,
    opacity 250ms ease,
    transform 250ms ease,
    padding 300ms ease;
}
