/* ---------- Base ---------- */
:root{
  --bg: #0b0f14;
  --panel: rgba(16, 22, 30, 0.78);
  --panel2: rgba(16, 22, 30, 0.55);
  --border: rgba(174, 210, 225, 0.18);
  --text: rgba(240, 248, 255, 0.92);
  --muted: rgba(240, 248, 255, 0.65);
  --accent: #8fe7ff;
  --accent2: #b7a6ff;
  --shadow: 0 14px 45px rgba(0,0,0,.45);
  --radius: 18px;
  --max: 1080px;
}

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}
a{ color: inherit; text-decoration: none; }
.container{ width: min(var(--max), 92vw); margin: 0 auto; }
.section{ padding: 70px 0; }
.section__head{ margin-bottom: 18px; }
.section__head h2{ margin: 0 0 6px; font-size: 30px; letter-spacing: .3px; }
.muted{ color: var(--muted); }
.small{ font-size: 12.5px; }

/* ---------- Background: stars + nebula ---------- */
.bg{ position: fixed; inset: 0; z-index: -5; }
.stars{
  position: absolute; inset: 0;
  background-image:
    radial-gradient(2px 2px at 20% 30%, rgba(255,255,255,.85) 50%, transparent 51%),
    radial-gradient(1px 1px at 70% 40%, rgba(255,255,255,.6) 50%, transparent 51%),
    radial-gradient(1px 1px at 40% 80%, rgba(255,255,255,.45) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 85% 75%, rgba(255,255,255,.75) 50%, transparent 51%),
    radial-gradient(1px 1px at 10% 70%, rgba(255,255,255,.5) 50%, transparent 51%);
  opacity: .7;
  filter: drop-shadow(0 0 6px rgba(255,255,255,.12));
  animation: drift 26s linear infinite;
}
.stars2{ opacity: .5; animation-duration: 40s; transform: scale(1.2); }
.stars3{ opacity: .35; animation-duration: 55s; transform: scale(1.35); }

.nebula{
  position: absolute; inset: -20%;
  background:
    radial-gradient(closest-side at 25% 30%, rgba(143,231,255,.16), transparent 55%),
    radial-gradient(closest-side at 70% 55%, rgba(183,166,255,.12), transparent 60%),
    radial-gradient(closest-side at 55% 80%, rgba(143,231,255,.10), transparent 60%);
  filter: blur(18px);
  animation: neb 18s ease-in-out infinite alternate;
}
.vignette{
  position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 30%, transparent 0 55%, rgba(0,0,0,.55) 80%);
}

@keyframes drift{
  from{ transform: translateY(0px); }
  to{ transform: translateY(-120px); }
}
@keyframes neb{
  from{ transform: translate3d(-10px, 0, 0) scale(1); opacity: .9; }
  to{ transform: translate3d(18px, -10px, 0) scale(1.05); opacity: 1; }
}

/* ---------- Topbar ---------- */
.topbar{
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(10px);
  background: linear-gradient(to bottom, rgba(11,15,20,.85), rgba(11,15,20,.55));
  border-bottom: 1px solid var(--border);
}
.topbar__inner{
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0;
}
.brand{
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 650;
}
.brand__dot{
  width: 10px; height: 10px; border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, var(--accent), var(--accent2));
  box-shadow: 0 0 20px rgba(143,231,255,.25);
}
.brand__text{ letter-spacing: .6px; }

.nav{
  display: flex; gap: 12px;
  padding: 6px;
  border: 1px solid var(--border);
  background: var(--panel2);
  border-radius: 999px;
}
.nav__link{
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--muted);
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}
.nav__link:hover{
  transform: translateY(-1px);
  background: rgba(143,231,255,.08);
  color: var(--text);
}
.nav__link.active{
  background: rgba(143,231,255,.14);
  color: var(--text);
  border: 1px solid rgba(143,231,255,.18);
}

/* Mobile menu button */
.navbtn{
  display: none;
  width: 44px; height: 40px;
  border-radius: 12px;
  background: var(--panel2);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  cursor: pointer;
}
.navbtn span{
  display: block;
  width: 18px; height: 2px;
  margin: 4px auto;
  background: rgba(240,248,255,.9);
  border-radius: 999px;
}

/* ---------- Hero ---------- */
.hero{
  display: grid;
  grid-template-columns: 1.25fr .9fr;
  gap: 26px;
  padding-top: 40px;
}
.kicker{
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(143,231,255,.18);
  background: rgba(143,231,255,.08);
  color: var(--muted);
  font-size: 13px;
}
.title{
  margin: 12px 0 10px;
  font-size: clamp(34px, 4.2vw, 54px);
  line-height: 1.05;
  letter-spacing: .2px;
}
.accent{
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.subtitle{ margin: 0; font-size: 16.5px; line-height: 1.6; color: var(--muted); }

.hero__actions{ margin-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; }
.btn{
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid rgba(143,231,255,.22);
  background: rgba(143,231,255,.14);
  color: var(--text);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  transition: transform 180ms ease, background 180ms ease;
}
.btn:hover{ transform: translateY(-2px); background: rgba(143,231,255,.18); }
.btn--ghost{
  background: rgba(16,22,30,.35);
  border: 1px solid var(--border);
}
.btn--small{ padding: 9px 11px; border-radius: 12px; }

.chips{ margin-top: 18px; display: flex; gap: 8px; flex-wrap: wrap; }
.chip{
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(16,22,30,.35);
  color: var(--muted);
  font-size: 13px;
}

/* ---------- Cards / layout ---------- */
.card{
  border: 1px solid var(--border);
  background: var(--panel);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.card h3{ margin: 0 0 8px; }
.card p{ margin: 0 0 10px; line-height: 1.6; }
.card__header{
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 12px;
}
.card__title{ margin: 0 0 8px; font-weight: 700; }
.list{ margin: 0 0 10px; padding-left: 18px; color: var(--muted); line-height: 1.7; }

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

.pill{
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(183,166,255,.22);
  background: rgba(183,166,255,.10);
  color: var(--muted);
  font-size: 12.5px;
}

.tags{ display: flex; flex-wrap: wrap; gap: 8px; }
.tag{
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(16,22,30,.35);
  color: var(--muted);
  font-size: 13px;
}

.note{
  margin-top: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px dashed rgba(143,231,255,.28);
  background: rgba(143,231,255,.07);
  color: var(--muted);
}

/* Projects + posts */
.project__top, .post__meta{
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 10px;
}
.project__links{
  display: flex; gap: 10px; margin-top: 10px;
}
.link{
  color: var(--text);
  border-bottom: 1px solid rgba(143,231,255,.35);
  padding-bottom: 2px;
  transition: opacity 160ms ease, transform 160ms ease;
}
.link:hover{ opacity: .9; transform: translateY(-1px); }

.linklist{ display: grid; gap: 10px; margin-top: 10px; }
.linkrow{
  display: flex; justify-content: space-between; gap: 12px;
  padding: 11px 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(16,22,30,.35);
  transition: transform 180ms ease, background 180ms ease;
}
.linkrow:hover{ transform: translateY(-2px); background: rgba(143,231,255,.06); }

.footer{
  padding: 28px 0 40px;
  border-top: 1px solid rgba(174,210,225,.12);
}

/* ---------- Reveal animation ---------- */
.reveal{
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 600ms ease, transform 600ms ease;
  transition-delay: var(--delay, 0ms);
}
.reveal.visible{
  opacity: 1;
  transform: translateY(0px);
}

/* ---------- Modal ---------- */
.modal{
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  display: none;
  align-items: center; justify-content: center;
  padding: 18px;
  z-index: 60;
}
.modal.show{ display: flex; }
.modal__panel{
  width: min(760px, 96vw);
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(10,14,19,.88);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  padding: 14px;
}
.modal__top{
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(174,210,225,.12);
  padding-bottom: 10px;
  margin-bottom: 10px;
}
.modal__content{ color: var(--muted); line-height: 1.7; }
.iconbtn{
  width: 40px; height: 38px;
  border-radius: 12px;
  background: rgba(16,22,30,.35);
  border: 1px solid var(--border);
  color: var(--text);
  cursor: pointer;
}

/* ---------- Responsive ---------- */
@media (max-width: 920px){
  .hero{ grid-template-columns: 1fr; }
  .cards{ grid-template-columns: 1fr; }
  .grid-2{ grid-template-columns: 1fr; }
  .nav{ display: none; }
  .navbtn{ display: inline-block; }
  .nav.open{
    display: flex;
    position: absolute;
    right: 4vw;
    top: 62px;
    flex-direction: column;
    padding: 10px;
    border-radius: 16px;
    width: min(240px, 92vw);
  }
}

/* ---------- Section divider ---------- */
.divider {
  width: 100%;
  display: flex;
  justify-content: center;
  margin: 40px 0;
}

.divider span {
  width: 80%;
  height: 2px;
  background-image: repeating-linear-gradient(
    to right,
    rgba(143,231,255,0.4),
    rgba(143,231,255,0.4) 6px,
    transparent 6px,
    transparent 14px
  );
  opacity: 0.6;
}

.linkrow{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.linkleft{
  display: flex;
  align-items: center;
  gap: 10px;
}

.icon{
  font-size: 18px;
  color: var(--accent);
  min-width: 20px; /* keeps alignment consistent */
}

.logo{
  border: 2px solid #ffffff
 
  
}

body {
  font-family: 'Rubik', sans-serif;
}

h1, h2, h3 {
  font-family: 'Rubik', sans-serif;
}
