/* ============================================================
   Skyhub — personal website
   Sky / glassmorphism theme
   Performance notes:
   - background image is on a single fixed layer (no background-attachment:fixed,
     which is expensive on mobile) -> position:fixed + will-change:auto
   - animations only use transform / opacity (GPU friendly, no layout thrash)
   - blur values kept moderate; heavy blur is reduced on small screens
   ============================================================ */

:root{
  --sky-1:#eaf8ff;
  --sky-2:#bde9ff;
  --sky-3:#7fd6ff;
  /* accent used for small text on glass — pale so it reads on the new darker glass */
  --sky-4:#dff4ff;

  --ink:#ffffff;
  --ink-soft:rgba(255,255,255,.82);
  --white:#ffffff;

  /* frosted glass recipe */
  --glass:rgba(255,255,255,.14);
  --line:rgba(255,255,255,.42);
  --shadow:0 24px 70px rgba(2,32,71,.35);
  --blur:blur(18px) saturate(150%);

  /* aliases kept so every component picks up the same recipe */
  --glass-bg:var(--glass);
  --glass-bg-strong:rgba(255,255,255,.22);
  --glass-brd:var(--line);
  --glass-shadow:var(--shadow);

  /* soft pill fills (chips, ghost buttons, bars) */
  --fill:rgba(255,255,255,.16);
  --fill-hi:rgba(255,255,255,.3);

  /* navbar sits on the brightest part of the sky, so it gets a
     navy-tinted glass instead of the plain white one */
  --nav-glass:rgba(6,38,72,.38);
  --nav-line:rgba(255,255,255,.34);
  /* the collapsed menu panel cannot use backdrop-filter (see note below),
     so it needs an opaque-enough tint of its own */
  --nav-panel:rgba(6,34,66,.9);

  --squircle-lg:34px;
  --radius:var(--squircle-lg);
  --radius-sm:18px;
  --maxw:1120px;
  --ease:cubic-bezier(.22,.68,.32,1);
  --ease-out:cubic-bezier(.22,.68,.32,1);
}


*,*::before,*::after{box-sizing:border-box}

html{
  scroll-behavior:smooth;
  scroll-padding-top:92px;
  -webkit-text-size-adjust:100%;
}

body{
  margin:0;
  min-height:100%;
  font-family:"Quicksand",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  color:var(--ink);
  background:#bfe8ff; /* fallback while image loads */
  line-height:1.65;
  overflow-x:hidden;
}

img,svg{display:block;max-width:100%}
a{color:inherit;text-decoration:none}
ul{list-style:none;margin:0;padding:0}
h1,h2,h3{margin:0;line-height:1.25;font-weight:700}
p{margin:0 0 .8em}

/* ---------- Background layers ---------- */
.sky-bg{
  position:fixed;
  inset:0;
  z-index:-3;
  /* url() is resolved relative to THIS stylesheet (css/), so it needs
     to step one level up to reach /assets — "./assets" would look for
     /css/assets/bg.jpg and 404 */
  background-image:url("../assets/bg.webp");
  background-size:cover;
  background-position:center top;
  background-repeat:no-repeat;
  /* very slow breathing motion — cheap, transform only */
  animation:bgDrift 40s ease-in-out infinite alternate;
}
@keyframes bgDrift{
  from{transform:scale(1.04) translate3d(0,0,0)}
  to{transform:scale(1.1) translate3d(0,-14px,0)}
  
}

/* soft scrim so white text on frosted glass stays readable over bright sky */
.sky-veil{
  position:fixed;
  inset:0;
  z-index:-2;
  pointer-events:none;
  background:
    radial-gradient(1100px 640px at 50% 6%,rgba(255,255,255,.16),transparent 60%),
    linear-gradient(180deg,rgba(4,38,74,.16) 0%,rgba(4,38,74,.26) 48%,rgba(4,38,74,.34) 100%);
}


/* ---------- Floating leaves (8 elements only) ---------- */
.leaves{position:fixed;inset:0;z-index:-1;pointer-events:none;overflow:hidden}
.leaf{
  position:absolute;
  top:-8vh;
  width:14px;height:9px;
  border-radius:60% 10% 60% 10%;
  background:linear-gradient(135deg,#a6e88a,#5cc16b);
  opacity:.55;
  will-change:transform;
  animation:fall linear infinite;
}
.leaf:nth-child(1){left:6%;  animation-duration:17s; animation-delay:-1s;  transform:scale(.9)}
.leaf:nth-child(2){left:19%; animation-duration:22s; animation-delay:-6s;  transform:scale(1.1)}
.leaf:nth-child(3){left:33%; animation-duration:19s; animation-delay:-11s}
.leaf:nth-child(4){left:47%; animation-duration:25s; animation-delay:-3s;  transform:scale(.8)}
.leaf:nth-child(5){left:61%; animation-duration:20s; animation-delay:-14s}
.leaf:nth-child(6){left:74%; animation-duration:23s; animation-delay:-8s;  transform:scale(1.15)}
.leaf:nth-child(7){left:86%; animation-duration:18s; animation-delay:-17s; transform:scale(.85)}
.leaf:nth-child(8){left:94%; animation-duration:26s; animation-delay:-12s}

@keyframes fall{
  0%  {transform:translate3d(0,0,0) rotate(0deg);opacity:0}
  8%  {opacity:.6}
  50% {transform:translate3d(40px,55vh,0) rotate(180deg)}
  92% {opacity:.5}
  100%{transform:translate3d(-30px,118vh,0) rotate(360deg);opacity:0}
}

/* ---------- Glass helpers ---------- */
.glass{
  background:var(--glass);
  -webkit-backdrop-filter:var(--blur);
  backdrop-filter:var(--blur);
  border:1px solid var(--line);
  /* the inset hairline is what makes the edge read as glass */
  box-shadow:var(--shadow),inset 0 1px 0 rgba(255,255,255,.5);
}
.glass-soft{
  background:var(--fill);
  -webkit-backdrop-filter:blur(10px) saturate(140%);
  backdrop-filter:blur(10px) saturate(140%);
  border:1px solid rgba(255,255,255,.32);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.35);
}


/* ============================================================
   Navbar
   ============================================================ */
.nav-wrap{
  position:sticky;
  top:0;
  z-index:50;
  display:flex;
  justify-content:center;
  padding:14px clamp(12px,3vw,20px) 0;
  pointer-events:none; /* only the pill itself is clickable */
}
.nav{
  position:relative; /* anchor for the collapsed menu panel */
  display:inline-flex;
  align-items:center;
  gap:4px;
  max-width:100%;
  padding:6px;
  border-radius:999px;
  pointer-events:auto;
  animation:dropIn .7s var(--ease) both;
  /* darker than the generic .glass so links stay legible over bright sky */
  background:var(--nav-glass);
  border-color:var(--nav-line);
  box-shadow:0 14px 40px rgba(2,32,71,.4),inset 0 1px 0 rgba(255,255,255,.28);
}

@keyframes dropIn{from{opacity:0;transform:translate3d(0,-18px,0)}to{opacity:1;transform:none}}

/* avatar + menu button: desktop hides them, narrow screens show them */
.nav-avatar{
  display:none;
  width:34px;height:34px;flex:0 0 34px;
  border-radius:50%;overflow:hidden;
  border:2px solid rgba(255,255,255,.8);
  box-shadow:0 3px 10px rgba(2,32,71,.28);
  transition:transform .4s var(--ease);
}

.nav-avatar:hover{transform:rotate(-8deg) scale(1.08)}

.nav-toggle{
  display:none;
  width:38px;height:34px;
  flex:0 0 38px;
  border-radius:12px;
  cursor:pointer;
  background:var(--fill);
  border:1px solid rgba(255,255,255,.4);
  padding:8px 9px;
  /* the three bars are laid out by the flow, so keep the box predictable */
  line-height:0;
}
.nav-toggle span{
  display:block;height:2px;border-radius:2px;background:var(--ink);
  transition:transform .3s var(--ease),opacity .2s;
}
.nav-toggle span+span{margin-top:4px}
.nav-toggle.open span:nth-child(1){transform:translateY(6px) rotate(45deg)}
.nav-toggle.open span:nth-child(2){opacity:0}
.nav-toggle.open span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}

.nav-links{
  display:flex;
  align-items:center;
  gap:2px;
  min-width:0;
}

.nav-link{
  position:relative;
  display:block;
  padding:9px clamp(12px,2.2vw,18px);
  border-radius:999px;
  white-space:nowrap;
  font-weight:600;
  font-size:.92rem;
  color:var(--ink-soft);
  transition:color .25s,background-color .25s;
}
.nav-link:hover{color:var(--ink);background:rgba(255,255,255,.16)}
.nav-link.active{
  color:#fff;
  background:linear-gradient(135deg,rgba(120,214,255,.55),rgba(26,134,199,.7));
  box-shadow:0 4px 14px rgba(2,32,71,.28),inset 0 1px 0 rgba(255,255,255,.45);
}

/* thin divider between links and the language button */
.nav-sep{
  width:1px;
  height:20px;
  flex:0 0 1px;
  margin:0 4px;
  background:rgba(255,255,255,.34);
}

/* language switcher */
.lang-btn{
  display:inline-flex;align-items:center;gap:5px;
  flex:0 0 auto;
  padding:9px 14px;
  border-radius:999px;
  cursor:pointer;
  font-family:inherit;font-weight:700;font-size:.82rem;
  color:var(--ink);
  background:var(--fill);
  border:1px solid rgba(255,255,255,.4);
  transition:background-color .25s,box-shadow .25s,transform .2s var(--ease);
}
.lang-btn:hover{background:var(--fill-hi);box-shadow:0 6px 16px rgba(2,32,71,.26)}
.lang-btn:active{transform:scale(.95)}
.lang-code{min-width:20px;text-align:center;display:inline-block}
.lang-flip{animation:flip .45s var(--ease)}
@keyframes flip{from{transform:rotateX(-90deg);opacity:0}to{transform:none;opacity:1}}


/* ============================================================
   Layout
   ============================================================ */
.section{
  max-width:var(--maxw);
  margin:0 auto;
  padding:clamp(48px,8vh,86px) clamp(16px,4vw,28px);
}
.hero{
  min-height:calc(100vh - 80px);
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:24px;
}

.card{border-radius:var(--radius);padding:clamp(20px,3vw,32px)}

.section-head{text-align:center;margin-bottom:28px}
.section-title{
  font-size:clamp(1.6rem,4vw,2.3rem);
  letter-spacing:.5px;
  text-shadow:0 2px 14px rgba(2,32,71,.45);
}

.section-sub{color:var(--ink-soft);margin:6px 0 0;font-weight:500}

.card-title{
  font-size:1.15rem;
  margin-bottom:12px;
  display:flex;align-items:center;gap:8px;
}

/* ---------- Reveal on scroll ---------- */
.reveal{
  opacity:0;
  transform:translate3d(0,26px,0);
  transition:opacity .7s var(--ease),transform .7s var(--ease);
  will-change:opacity,transform;
}
.reveal.in{opacity:1;transform:none;will-change:auto}

/* ============================================================
   Profile / contact card
   ============================================================ */
.profile-card{
  position:relative;
  width:min(760px,100%);
  text-align:left;
  overflow:hidden;
  background:var(--glass-bg-strong);
}
/* avatar on the left, greeting block on the right */
.profile-top{
  display:flex;
  align-items:center;
  gap:clamp(16px,3vw,26px);
}
.profile-head{min-width:0;flex:1 1 auto}

.profile-glow{
  position:absolute;
  top:-140px;left:50%;
  width:420px;height:420px;
  margin-left:-210px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(255,255,255,.42),transparent 66%);
  pointer-events:none;
  animation:pulseGlow 7s ease-in-out infinite;
}
@keyframes pulseGlow{
  0%,100%{transform:scale(1);opacity:.6}
  50%{transform:scale(1.12);opacity:.85}
}

.avatar-ring{
  position:relative;
  width:clamp(104px,13vw,132px);height:clamp(104px,13vw,132px);
  flex:0 0 auto;
  margin:0;
  border-radius:50%;
  padding:5px;
  background:conic-gradient(from 0deg,#ffffff,#9fe4ff,#4fb9ec,#c8f3d0,#ffffff);
  animation:spinRing 9s linear infinite;
}
@keyframes spinRing{to{transform:rotate(360deg)}}

.avatar{
  width:100%;height:100%;
  border-radius:50%;
  overflow:hidden;
  background:#eaf8ff;
  box-shadow:0 8px 22px rgba(2,32,71,.3);
  animation:spinRingRev 9s linear infinite, floaty 5s ease-in-out infinite;
}
@keyframes spinRingRev{to{transform:rotate(-360deg)}}
@keyframes floaty{0%,100%{translate:0 0}50%{translate:0 -5px}}

.status-dot{
  position:absolute;
  right:10px;bottom:10px;
  width:16px;height:16px;
  border-radius:50%;
  background:#43d17a;
  border:3px solid #fff;
  box-shadow:0 0 0 0 rgba(67,209,122,.6);
  animation:ping 2.4s ease-out infinite;
}
@keyframes ping{
  0%{box-shadow:0 0 0 0 rgba(67,209,122,.55)}
  70%{box-shadow:0 0 0 12px rgba(67,209,122,0)}
  100%{box-shadow:0 0 0 0 rgba(67,209,122,0)}
}

.name{
  display:flex;
  align-items:center;
  gap:.4em;
  flex-wrap:wrap;
  font-size:clamp(1.55rem,4.6vw,2.5rem);
  letter-spacing:.5px;
  background:linear-gradient(100deg,#ffffff,#a9e6ff,#ffffff);
  background-size:220% auto;
  -webkit-background-clip:text;background-clip:text;
  color:transparent;
  animation:shine 7s linear infinite;
}
@keyframes shine{to{background-position:220% center}}

/* the name is a gradient-clipped text, so the emoji needs its own colour back */
.name-text{
  background:inherit;
  -webkit-background-clip:text;background-clip:text;
  color:transparent;
}
.wave{
  /* the parent clips its gradient to the text and paints it transparent,
     which would swallow the emoji too — give it a solid fill back */
  -webkit-text-fill-color:#fff;
  color:#fff;
  background:none;
  transform-origin:70% 80%;
  animation:wave 2.6s var(--ease) infinite;
}
@keyframes wave{
  0%,60%,100%{transform:rotate(0deg)}
  10%,30%{transform:rotate(14deg)}
  20%,40%{transform:rotate(-8deg)}
}

.role{font-weight:600;color:var(--sky-4);margin:-14px 0 0;letter-spacing:.3px;font-size:.9rem}

/* typed line sits directly under the greeting */
.tagline{
  color:var(--ink);
  font-weight:600;
  font-size:clamp(.95rem,2.4vw,1.15rem);
  margin:6px 0 0;
  /* reserve two lines so the card does not resize while typing */
  min-height:2.6em;
}
.type-caret{
  display:inline-block;
  width:2px;height:1.05em;
  margin-left:2px;
  vertical-align:-.18em;
  background:var(--ink);
  animation:caret 1s steps(1) infinite;
}
@keyframes caret{0%,49%{opacity:1}50%,100%{opacity:0}}

/* visually hidden but still available to screen readers / the translator */
.sr-only{
  position:absolute;
  width:1px;height:1px;
  padding:0;margin:-1px;
  overflow:hidden;
  clip:rect(0 0 0 0);
  white-space:nowrap;
  border:0;
}

/* social tiles */
.social-row{display:flex;flex-wrap:wrap;gap:8px;margin-top:14px}
.social{
  display:grid;place-items:center;
  width:40px;height:40px;
  border-radius:12px;
  color:var(--ink);
  background:var(--fill);
  border:1px solid rgba(255,255,255,.34);
  transition:transform .28s var(--ease),background-color .28s,box-shadow .28s;
}
.social svg{width:20px;height:20px;fill:currentColor}
.social:hover{
  transform:translateY(-4px);
  background:var(--fill-hi);
  box-shadow:0 10px 22px rgba(2,32,71,.3);
}

/* ---------- Buttons ---------- */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  padding:12px 24px;
  border-radius:999px;
  font-weight:700;font-size:.95rem;
  cursor:pointer;
  border:1px solid transparent;
  transition:transform .28s var(--ease),box-shadow .28s,background-color .28s;
}
.btn:hover{transform:translateY(-3px)}
.btn:active{transform:translateY(-1px) scale(.98)}

.btn-primary{
  color:#fff;
  background:linear-gradient(135deg,#4fb9ec,#1a86c7);
  box-shadow:0 8px 22px rgba(2,32,71,.34),inset 0 1px 0 rgba(255,255,255,.4);
}
.btn-primary:hover{box-shadow:0 14px 30px rgba(2,32,71,.42),inset 0 1px 0 rgba(255,255,255,.4)}

.btn-ghost{
  color:var(--ink);
  background:var(--fill);
  border-color:rgba(255,255,255,.4);
  -webkit-backdrop-filter:blur(10px);
  backdrop-filter:blur(10px);
}
.btn-ghost:hover{background:var(--fill-hi);box-shadow:0 10px 24px rgba(2,32,71,.28)}

/* ---------- CV / resume button ----------
   Deliberately not glass: a solid white pill next to the blue primary
   button reads instantly as "document", and the icon + PDF badge say
   what happens on click before the label is even read. */
.btn-cv{
  gap:9px;
  padding-right:14px;
  color:#0d4f7a;
  background:#ffffff;
  border-color:#ffffff;
  box-shadow:0 8px 22px rgba(2,32,71,.3);
}
.btn-cv:hover{
  background:#f2fbff;
  box-shadow:0 14px 30px rgba(2,32,71,.4);
}

.cv-ico{
  display:grid;place-items:center;
  width:22px;height:22px;flex:0 0 22px;
  color:#1a86c7;
}
.cv-ico svg{width:100%;height:100%;fill:currentColor}
/* the arrow inside the sheet nudges down on hover = "download" */
.btn-cv:hover .cv-ico{animation:cvDip .6s var(--ease)}
@keyframes cvDip{
  0%,100%{transform:translateY(0)}
  45%{transform:translateY(3px)}
}

.cv-badge{
  padding:2px 7px;
  border-radius:6px;
  font-size:.62rem;font-weight:800;letter-spacing:.6px;
  color:#fff;
  background:linear-gradient(135deg,#ff7a6b,#e2453a);
  box-shadow:0 2px 6px rgba(226,69,58,.4);
}

.hero-actions{display:flex;flex-wrap:wrap;gap:12px;justify-content:flex-start;margin-top:22px}

/* ---------- Scroll hint ---------- */
.scroll-hint{
  display:inline-flex;flex-direction:column;align-items:center;gap:6px;
  font-size:.75rem;text-transform:uppercase;letter-spacing:2px;
  color:var(--ink-soft);font-weight:700;
  animation:floaty 2.6s ease-in-out infinite;
}
.chev{
  width:11px;height:11px;
  border-right:2px solid var(--sky-4);
  border-bottom:2px solid var(--sky-4);
  transform:rotate(45deg);
}

/* ============================================================
   About + skills
   ============================================================ */
.about-grid{
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:20px;
  align-items:start;
}
.about-text p{color:var(--ink-soft)}

.chips{display:flex;flex-wrap:wrap;gap:8px;margin-top:14px}
.chip{
  padding:6px 13px;
  border-radius:999px;
  font-size:.82rem;font-weight:600;
  color:var(--ink);
  background:var(--fill);
  border:1px solid rgba(255,255,255,.34);
  transition:transform .25s var(--ease),background-color .25s;
}
.chip:hover{transform:translateY(-2px);background:var(--fill-hi)}

.skill+.skill{margin-top:14px}
.skill-top{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:6px}
.skill-name{font-weight:600;font-size:.93rem}
.skill-pct{font-size:.82rem;font-weight:700;color:var(--sky-4);font-variant-numeric:tabular-nums}

.bar{
  height:11px;
  border-radius:999px;
  background:rgba(255,255,255,.18);
  border:1px solid rgba(255,255,255,.34);
  overflow:hidden;
}
.bar>i{
  display:block;
  height:100%;
  width:var(--w);
  border-radius:999px;
  background:linear-gradient(90deg,#8ee0b6,#4fb9ec,#1a86c7);
  background-size:200% 100%;
  /* animate with scaleX: no layout recalculation */
  transform:scaleX(0);
  transform-origin:left center;
  transition:transform 1.3s var(--ease);
}
.skills.in .bar>i{transform:scaleX(1);animation:barFlow 3.5s linear infinite}
@keyframes barFlow{to{background-position:-200% 0}}

/* ============================================================
   Experience timeline
   ============================================================ */
.timeline{
  position:relative;
  max-width:820px;
  margin:0 auto;
  padding-left:34px;
}
/* the vertical line */
.timeline::before{
  content:"";
  position:absolute;
  left:9px;top:6px;bottom:6px;
  width:2px;
  border-radius:2px;
  background:linear-gradient(180deg,rgba(255,255,255,.85),rgba(79,185,236,.55),rgba(255,255,255,.2));
}
.tl-item{position:relative}
.tl-item+.tl-item{margin-top:16px}

.tl-dot{
  position:absolute;
  left:-33px;top:26px;
  width:14px;height:14px;
  border-radius:50%;
  background:#fff;
  border:3px solid var(--sky-3);
  box-shadow:0 0 0 4px rgba(255,255,255,.22);
}
.tl-item.in .tl-dot{animation:dotPop .5s var(--ease) both}
@keyframes dotPop{from{transform:scale(0)}to{transform:scale(1)}}

/* The reveal animation must run on the glass element itself.
   A transformed / will-change ancestor becomes a "backdrop root", which means a
   descendant's backdrop-filter has nothing left to sample and the frost
   disappears. So .tl-item stays untransformed and the card animates instead. */
.tl-item.reveal{opacity:1;transform:none;will-change:auto;transition:none}
.tl-item.reveal .tl-card{
  opacity:0;
  transform:translate3d(0,26px,0);
  transition:opacity .7s var(--ease),transform .7s var(--ease);
}
.tl-item.in .tl-card{opacity:1;transform:none}

.tl-card{transition:transform .35s var(--ease),box-shadow .35s,background-color .35s}
.tl-item.in .tl-card:hover{
  transform:translateX(5px);
  background:var(--glass-bg-strong);
  box-shadow:0 20px 44px rgba(2,32,71,.35),inset 0 1px 0 rgba(255,255,255,.5);
}
.tl-date{
  display:inline-block;
  padding:3px 11px;
  margin-bottom:8px;
  border-radius:999px;
  font-size:.75rem;font-weight:700;letter-spacing:.4px;
  color:var(--ink);
  background:var(--fill);
  border:1px solid rgba(255,255,255,.34);
}
.tl-role{font-size:1.08rem}
.tl-org{margin:2px 0 6px;font-size:.85rem;font-weight:600;color:var(--sky-4);opacity:.9}
.tl-desc{color:var(--ink-soft);font-size:.92rem;margin-bottom:10px}
.tl-tags{display:flex;flex-wrap:wrap;gap:6px}
.tl-tags .chip{font-size:.75rem;padding:4px 10px}

/* ============================================================
   Projects
   ============================================================ */

.project-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
  gap:18px;
}
.project{
  position:relative;
  display:flex;flex-direction:column;
  overflow:hidden;
  transition:transform .35s var(--ease),box-shadow .35s,background-color .35s;
}
.project::before{
  content:"";
  position:absolute;inset:0;
  background:linear-gradient(140deg,rgba(255,255,255,.22),transparent 55%);
  opacity:0;
  transition:opacity .35s;
  pointer-events:none;
}
.project:hover{
  transform:translateY(-7px);
  background:var(--glass-bg-strong);
  box-shadow:0 26px 52px rgba(2,32,71,.4),inset 0 1px 0 rgba(255,255,255,.5);
}
.project:hover::before{opacity:1}

.p-ico{
  font-size:1.6rem;
  width:48px;height:48px;
  display:grid;place-items:center;
  border-radius:14px;
  background:var(--fill);
  border:1px solid rgba(255,255,255,.34);
  margin-bottom:12px;
  transition:transform .35s var(--ease);
}
.project:hover .p-ico{transform:rotate(-8deg) scale(1.08)}
.p-name{font-size:1.1rem;margin-bottom:6px}
.p-desc{color:var(--ink-soft);font-size:.92rem;flex:1}
.p-go{
  font-weight:700;font-size:.87rem;color:var(--sky-4);
  transition:transform .3s var(--ease);
  align-self:flex-start;
}
.project:hover .p-go{transform:translateX(5px)}

/* ============================================================
   Support
   ============================================================ */
.support-card{
  width:min(680px,100%);
  margin:0 auto;
  text-align:center;
  background:var(--glass-bg-strong);
}
.support-ico{
  display:inline-grid;place-items:center;
  width:60px;height:60px;
  font-size:1.7rem;
  border-radius:50%;
  background:var(--fill-hi);
  border:1px solid rgba(255,255,255,.42);
  margin-bottom:12px;
  animation:floaty 4s ease-in-out infinite;
}
.support-text{color:var(--ink-soft);max-width:52ch;margin:8px auto 20px}

.btn-support{
  position:relative;
  color:#fff;
  padding:14px 32px;
  font-size:1rem;
  background:linear-gradient(135deg,#37c2f0,#1a86c7 55%,#5ad1a8);
  background-size:180% auto;
  box-shadow:0 12px 30px rgba(2,32,71,.4),inset 0 1px 0 rgba(255,255,255,.4);
  overflow:hidden;
  animation:shine 6s linear infinite;
}
.btn-support::after{
  content:"";
  position:absolute;top:0;left:-60%;
  width:45%;height:100%;
  background:linear-gradient(100deg,transparent,rgba(255,255,255,.5),transparent);
  transform:skewX(-20deg);
  animation:sweep 3.4s ease-in-out infinite;
}
@keyframes sweep{0%{left:-60%}55%,100%{left:130%}}
.btn-support:hover{box-shadow:0 18px 40px rgba(2,32,71,.48),inset 0 1px 0 rgba(255,255,255,.4)}
.heart{animation:beat 1.8s ease-in-out infinite;display:inline-block}
@keyframes beat{0%,100%{transform:scale(1)}30%{transform:scale(1.22)}60%{transform:scale(1.05)}}

.support-note{font-size:.8rem;color:var(--ink-soft);margin:14px 0 0;opacity:.85}

/* ============================================================
   Footer — subtle, blends into background, thin separator line
   ============================================================ */
.footer{
  max-width:var(--maxw);
  margin:0 auto;
  padding:18px clamp(16px,4vw,28px) 26px;
  border-top:1px solid rgba(255,255,255,.28);
}
.footer-line{
  margin:0;
  text-align:center;
  font-size:.8rem;
  font-weight:500;
  color:rgba(255,255,255,.6);
  letter-spacing:.2px;
}
.footer-line .dot{margin:0 8px;opacity:.55}

/* ============================================================
   Floating music player
   ============================================================ */
.player{
  position:fixed;
  z-index:60;
  right:clamp(12px,3vw,26px);
  bottom:clamp(12px,3vw,24px);
  display:flex;align-items:center;gap:11px;
  padding:8px 14px 8px 8px;
  border-radius:999px;
  animation:playerIn .8s var(--ease) .3s both;
}
@keyframes playerIn{from{opacity:0;transform:translate3d(0,20px,0)}to{opacity:1;transform:none}}

.play-btn{
  position:relative;
  flex:0 0 40px;
  width:40px;height:40px;
  display:grid;place-items:center;
  border:none;border-radius:50%;
  cursor:pointer;
  color:#fff;
  background:linear-gradient(135deg,#4fb9ec,#1a86c7);
  box-shadow:0 6px 16px rgba(2,32,71,.36),inset 0 1px 0 rgba(255,255,255,.4);
  transition:transform .25s var(--ease),box-shadow .25s;
}
.play-btn:hover{transform:scale(1.08)}
.play-btn:active{transform:scale(.94)}

/* pure-CSS play triangle / pause bars, swapped by .playing */
.ico-play,.ico-pause{position:absolute;transition:opacity .2s,transform .25s var(--ease)}
.ico-play{
  width:0;height:0;
  margin-left:3px;
  border-left:12px solid currentColor;
  border-top:8px solid transparent;
  border-bottom:8px solid transparent;
}
.ico-pause{
  width:13px;height:14px;
  border-left:4px solid currentColor;
  border-right:4px solid currentColor;
  opacity:0;transform:scale(.6);
}
.player.playing .ico-play{opacity:0;transform:scale(.6)}
.player.playing .ico-pause{opacity:1;transform:none}
/* soft ring while playing */
.player.playing .play-btn{box-shadow:0 0 0 0 rgba(79,185,236,.55);animation:ping 2.2s ease-out infinite}

.player-body{width:176px;min-width:0}
.player-top{display:flex;align-items:center;gap:6px;margin-bottom:5px}

.track-name{
  flex:1 1 auto;min-width:0;
  font-size:.78rem;font-weight:700;color:var(--ink);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.track-time{font-size:.7rem;font-weight:600;color:var(--ink-soft);font-variant-numeric:tabular-nums}

/* "2/5" — position in the playlist */
.track-count{
  flex:0 0 auto;
  font-size:.66rem;font-weight:700;
  color:var(--ink-soft);
  font-variant-numeric:tabular-nums;
  padding:1px 6px;
  border-radius:999px;
  background:rgba(255,255,255,.16);
}

/* the playlist is data only — never rendered */
.playlist{display:none}

/* prev / next */
.player-nav{display:flex;align-items:center;gap:4px;flex:0 0 auto}
.skip-btn{
  display:grid;place-items:center;
  width:28px;height:28px;
  padding:0;
  border-radius:50%;
  cursor:pointer;
  color:var(--ink);
  background:rgba(255,255,255,.16);
  border:1px solid rgba(255,255,255,.34);
  transition:transform .25s var(--ease),background-color .25s;
}
.skip-btn:hover{background:var(--fill-hi);transform:scale(1.1)}
.skip-btn:active{transform:scale(.92)}

/* CSS triangles, mirrored for "previous" */
.ico-skip{
  width:0;height:0;
  border-top:5px solid transparent;
  border-bottom:5px solid transparent;
}
.ico-skip.next{border-left:8px solid currentColor;margin-left:2px}
.ico-skip.prev{border-right:8px solid currentColor;margin-right:2px}

/* mini equalizer, only animates while playing */
.eq{display:flex;align-items:flex-end;gap:2px;height:11px;flex:0 0 auto}
.eq i{width:2px;height:4px;border-radius:2px;background:var(--sky-3)}
.player.playing .eq i{animation:eqJump .9s ease-in-out infinite}
.player.playing .eq i:nth-child(2){animation-delay:.15s}
.player.playing .eq i:nth-child(3){animation-delay:.3s}
@keyframes eqJump{0%,100%{height:4px}50%{height:11px}}

.progress{
  height:6px;
  border-radius:999px;
  cursor:pointer;
  background:rgba(255,255,255,.2);
  border:1px solid rgba(255,255,255,.34);
  overflow:hidden;
}

.progress-fill{
  display:block;height:100%;width:100%;
  border-radius:999px;
  background:linear-gradient(90deg,#8ee0b6,#4fb9ec,#1a86c7);
  transform:scaleX(0);
  transform-origin:left center;
}

/* ============================================================
   Responsive
   ============================================================ */


/* laptops / macbook 13" */
@media (max-width:1180px){
  :root{--maxw:960px}
}

/* iPad landscape & small laptops */
@media (max-width:980px){
  .about-grid{grid-template-columns:1fr}
}

/* laptops: five links still fit, just tighter */
@media (max-width:900px){
  .nav-link{font-size:.86rem;padding:9px 11px}
}

/* iPad portrait & below — five links no longer fit a centered pill,
   so the nav becomes: avatar + language + menu button, links in a panel */
@media (max-width:820px){
  html{scroll-padding-top:80px}

  .nav-wrap{padding:10px 12px 0}
  .nav{
    width:100%;
    justify-content:space-between;
    border-radius:20px;
    padding:8px 10px;
  }
  .nav-avatar{display:block}
  .nav-toggle{display:block}
  /* avatar stays left; separator + language + burger group to the right */
  .nav-sep{margin-left:auto}

  /* collapsed menu panel.
     No backdrop-filter here on purpose: .nav is already a backdrop-filter
     element, which makes it a backdrop root, so a nested backdrop-filter has
     nothing to sample and the panel renders as a nearly invisible white film.
     A solid navy tint is used instead. */
  .nav-links{
    position:absolute;
    top:calc(100% + 8px);
    left:0;right:0;
    z-index:2;
    flex-direction:column;
    align-items:stretch;
    gap:4px;
    padding:8px;
    border-radius:18px;
    background:var(--nav-panel);
    border:1px solid var(--nav-line);
    box-shadow:0 20px 44px rgba(2,32,71,.45),inset 0 1px 0 rgba(255,255,255,.22);
    /* closed state — transform/opacity only, and not clickable */
    opacity:0;
    visibility:hidden;
    pointer-events:none;
    transform:translate3d(0,-10px,0) scale(.98);
    transform-origin:top center;
    transition:opacity .28s var(--ease),transform .28s var(--ease),visibility .28s;
  }
  .nav-links.open{opacity:1;visibility:visible;pointer-events:auto;transform:none}
  .nav-links li{display:block;width:100%}
  .nav-link{display:block;text-align:center;font-size:.95rem;padding:12px 14px;border-radius:14px}

  .hero{min-height:auto;padding-top:34px}
  .profile-glow{width:320px;height:320px;margin-left:-160px;top:-110px}

  .timeline{padding-left:28px}
  .tl-dot{left:-27px;top:22px}
}

/* phones */
@media (max-width:560px){
  :root{--radius:18px}

  .lang-btn{padding:9px 11px;font-size:.78rem;gap:4px}

  /* Player shrinks to a compact 3-button cluster: prev / play / next.
     The track name + progress bar are dropped, which is what made the
     widget wide enough to sit over the text while reading. */
  .player{padding:5px;gap:2px}
  .player-body{display:none}

  /* smaller controls so the cluster stays out of the way */
  .play-btn{flex:0 0 34px;width:34px;height:34px}
  .ico-play{border-left-width:10px;border-top-width:7px;border-bottom-width:7px}
  .ico-pause{width:11px;height:12px;border-left-width:3px;border-right-width:3px}
  .skip-btn{width:26px;height:26px}

  /* prev sits before the play button so the order reads ◀ ▶ ▶▶ */
  .player-nav{display:contents}
  #prevBtn{order:-1}

  /* the ping ring is a large box-shadow — it would visually crowd
     the neighbouring buttons at this size */
  .player.playing .play-btn{animation:none;box-shadow:0 6px 16px rgba(2,32,71,.36),inset 0 1px 0 rgba(255,255,255,.4)}

  /* stack the hero: avatar above a centered greeting block */
  .profile-card{text-align:center}
  .profile-top{flex-direction:column;align-items:center;text-align:center}
  .name{justify-content:center}
  .social-row{justify-content:center}
  .hero-actions{justify-content:center}
  .tagline{min-height:3.9em} /* the line wraps more at this width */

  .hero-actions .btn{flex:1 1 100%}
  .section{padding-top:40px;padding-bottom:40px}
  .footer-line{font-size:.75rem}
  .footer-line .dot{display:block;height:0;margin:2px 0;overflow:hidden;opacity:0}

  /* lighter blur = smoother scrolling on mobile GPUs */
  .glass{-webkit-backdrop-filter:blur(10px) saturate(140%);backdrop-filter:blur(10px) saturate(140%)}
  .leaf:nth-child(n+6){display:none}
  .sky-bg{animation:none;transform:scale(1.02)}
}

/* very small phones — hide the globe, keep the EN/VI code.
   Links live in the dropdown panel at this width, so they keep their
   full tap target instead of being squeezed. */
@media (max-width:380px){
  .lang-flag{display:none}
  .lang-btn{padding:9px 9px}
}


/* ---------- Accessibility / performance preferences ---------- */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{
    animation-duration:.01ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.01ms !important;
  }
  .reveal{opacity:1;transform:none}
  .tl-item.reveal .tl-card{opacity:1;transform:none}
  .bar>i{transform:scaleX(1)}
  .type-caret{display:none}
  html{scroll-behavior:auto}
}

:focus-visible{outline:3px solid #ffffff;outline-offset:3px;border-radius:8px}
