/* ===========================================================
   Portfolio — design system (Fly-inspired)
   Fonts: Newsreader (serif headings) + Hanken Grotesk (body)
   =========================================================== */

:root {
  --ink: #2a1a5e;
  --body: #4b4066;
  --muted: #5b5077;
  --faint: #9a8fb8;
  --accent: #7c3aed;
  --accent-2: #a78bfa;
  --accent-dark: #5b21b6;
  --border: #ece7fb;
  --bg: #fbfaff;
  --panel: #fff;
  --gold: #f5c542;
  --gold-dark: #fbbf24;
  --serif: 'Newsreader', Georgia, serif;
  --sans: 'Hanken Grotesk', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }
img { display: block; max-width: 100%; }
::selection { background: #ddd0ff; color: var(--ink); }

.container { max-width: 1180px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }

@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.float { animation: floaty 8s ease-in-out infinite; }
.pg { animation: fadeUp .5s ease both; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; justify-content: center;
  padding: 20px 24px;
  background: linear-gradient(180deg, rgba(251,250,255,.9), rgba(251,250,255,0));
  backdrop-filter: blur(8px);
}
.nav-inner {
  width: 100%; max-width: 1180px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.logo { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 50% 50% 50% 4px;
  background: linear-gradient(150deg, var(--grad-a, #a78bfa), var(--grad-b, #7c3aed));
  box-shadow: 0 6px 16px rgba(124,58,237,.35);
}
.logo-name { font-family: var(--serif); font-size: 22px; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.navlinks {
  display: flex; align-items: center; gap: 6px; padding: 7px;
  background: #fff; border: 1px solid var(--border); border-radius: 999px;
  box-shadow: 0 8px 30px rgba(80,50,160,.08);
}
.navlink {
  font-family: inherit; font-size: 14.5px; font-weight: 500;
  padding: 8px 16px; border: 0; border-radius: 999px; cursor: pointer;
  color: #3a2d63; background: transparent; text-decoration: none;
}
.navlink:hover { background: #f3effe; color: var(--ink); }
.navlink.active { background: #f3effe; color: var(--ink); }

.btn {
  font-family: inherit; font-size: 15px; font-weight: 600;
  padding: 14px 28px; border: 0; border-radius: 999px; cursor: pointer;
  display: inline-block; text-decoration: none; transition: background .15s ease;
}
.btn-sm { font-size: 14.5px; padding: 11px 22px; }
.btn-primary { color: #fff; background: linear-gradient(135deg, var(--grad-a, #8b5cf6), var(--grad-b, #7c3aed)); box-shadow: 0 8px 22px rgba(124,58,237,.35); }
.btn-primary:hover { background: linear-gradient(135deg, var(--grad-b, #7c3aed), var(--accent-dark, #6d28d9)); color: #fff; }
.btn-ghost { color: #3a2d63; background: #fff; border: 1px solid #d9cffb; }
.btn-ghost:hover { background: #f3effe; color: #3a2d63; }
.btn-gold { color: var(--ink); background: var(--gold); }
.btn-gold:hover { background: var(--gold-dark); color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(1100px 520px at 78% -8%, #ffe3f1 0%, transparent 55%),
              radial-gradient(900px 500px at 8% 4%, #dfeaff 0%, transparent 55%),
              linear-gradient(180deg, #f6f2ff, #fbfaff);
  padding: 70px 24px 96px;
}
.hero-collage { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero-collage img { position: absolute; }
.hero-collage svg { position: absolute; }
.hero-grid {
  position: relative; z-index: 1;
  max-width: 1180px; margin: 0 auto;
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center;
}
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px; background: #fff; border: 1px solid var(--border);
  border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--accent);
  margin-bottom: 26px;
}
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px #dcfce7; }
.h1 { font-family: var(--serif); font-weight: 500; font-size: 66px; line-height: 1.02; letter-spacing: -.02em; color: var(--ink); margin: 0 0 22px; }
.h1 .accent { font-style: italic; color: var(--accent); position: relative; }
.h1 .accent::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 6px; background: var(--accent-2, #c4b5fd); border-radius: 4px; opacity: .6; z-index: -1; }
.lead { font-size: 19px; line-height: 1.6; color: var(--muted); max-width: 520px; margin: 0 0 34px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-art { position: relative; animation: floaty 7s ease-in-out infinite; }
/* .hero-art .art-back { position: absolute; inset: -18px; background: linear-gradient(135deg, #ffd6e8, #d9c6ff); border-radius: 32px; transform: rotate(-3deg); opacity: .55; } */
.hero-art .art-frame { position: relative; width: 100%; aspect-ratio: 4/5; border-radius: 26px; overflow: hidden; border: 1px solid var(--border); box-shadow: 0 30px 60px rgba(80,50,160,.18); background: #f3eefe; }
.hero-art .art-frame img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Sections ---------- */
.section { max-width: 1180px; margin: 0 auto; padding: 82px 24px 20px; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-2); margin: 0 0 12px; }
.h2 { font-family: var(--serif); font-weight: 500; font-size: 40px; line-height: 1.1; color: var(--ink); margin: 0 0 46px; max-width: 640px; }
.page-title { font-family: var(--serif); font-weight: 500; font-size: 56px; line-height: 1.04; letter-spacing: -.02em; color: var(--ink); margin: 0 0 16px; }
.page-intro { font-size: 19px; line-height: 1.6; color: var(--muted); max-width: 560px; margin: 0 0 50px; }

/* What I do */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.card { padding: 30px; border: 1px solid var(--border); border-radius: 20px; background: #fff; box-shadow: 0 10px 30px rgba(80,50,160,.05); }
.card-ico { width: 46px; height: 46px; border-radius: 14px; margin-bottom: 20px; }
.card h3 { font-family: var(--serif); font-size: 23px; font-weight: 600; color: var(--ink); margin: 0 0 10px; }
.card p { font-size: 15px; line-height: 1.6; color: var(--muted); margin: 0; }

/* CTA band */
.cta-wrap { padding: 90px 24px 0; }
.cta-band {
  max-width: 1180px; margin: 0 auto; position: relative; overflow: hidden;
  border-radius: 28px;
  background: radial-gradient(700px 400px at 85% 10%, var(--dark-b, #6d28d9) 0%, transparent 60%),
              linear-gradient(140deg, var(--dark-a, #2d1b5e), var(--dark-b, #4a2b8f));
  padding: 66px 56px;
}
.cta-band h2 { font-family: var(--serif); font-weight: 500; font-size: 44px; line-height: 1.08; color: #fff; margin: 0 0 16px; max-width: 600px; }
.cta-band p { font-size: 18px; line-height: 1.6; color: #d8ccff; max-width: 520px; margin: 0 0 30px; }
.cta-doodle { position: absolute; right: 44px; bottom: -30px; width: 200px; height: 200px; animation: floaty 8s ease-in-out infinite; opacity: .9; }

/* Projects */
.proj-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.proj-card { border: 1px solid var(--border); border-radius: 22px; overflow: hidden; background: #fff; box-shadow: 0 12px 34px rgba(80,50,160,.06); transition: transform .18s ease, box-shadow .18s ease; }
.proj-card:hover { transform: translateY(-4px); box-shadow: 0 20px 44px rgba(80,50,160,.12); }
.proj-cover { height: 240px; background: #f3eefe; }
.proj-cover img { width: 100%; height: 100%; object-fit: cover; }
.proj-body { padding: 28px 30px 32px; }
.proj-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.tag { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); background: #f3effe; padding: 5px 11px; border-radius: 999px; }
.proj-year { font-size: 13px; color: var(--faint); }
.proj-card h3 { font-family: var(--serif); font-size: 27px; font-weight: 600; color: var(--ink); margin: 0 0 10px; }
.proj-card p { font-size: 15px; line-height: 1.6; color: var(--muted); margin: 0 0 18px; }
.linkarrow { font-size: 14.5px; font-weight: 600; color: var(--accent); }

/* Experience timeline */
.timeline { display: flex; flex-direction: column; }
.exp-row { display: grid; grid-template-columns: 150px 1fr; gap: 32px; padding: 30px 0; border-top: 1px solid var(--border); }
.exp-period { font-size: 14px; font-weight: 600; color: var(--faint); padding-top: 5px; }
.exp-row h3 { font-family: var(--serif); font-size: 25px; font-weight: 600; color: var(--ink); margin: 0 0 4px; }
.exp-company { font-size: 15px; font-weight: 600; color: var(--accent); margin: 0 0 12px; }
.exp-summary { font-size: 15.5px; line-height: 1.65; color: var(--muted); margin: 0; }

/* Blog */
.blog-hero {
  background: radial-gradient(800px 500px at 80% 0%, var(--dark-b, #6d28d9) 0%, transparent 60%),
              linear-gradient(150deg, var(--dark-a, #2d1b5e), var(--dark-b, #3b1f7a));
  padding: 66px 24px 72px;
}
.blog-hero-grid { max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; }
.blog-hero-meta { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.blog-hero-meta .lbl { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #c4b5fd; }
.blog-hero-meta .rule { flex: 1; height: 1px; background: rgba(196,181,253,.3); }
.blog-hero-meta .read { font-size: 13px; color: #c4b5fd; }
.blog-hero h1 { font-family: var(--serif); font-weight: 500; font-size: 46px; line-height: 1.08; color: #fff; margin: 0 0 18px; }
.blog-hero p { font-size: 17px; line-height: 1.65; color: #d8ccff; margin: 0 0 26px; }
.blog-hero .readmore { font-size: 15px; font-weight: 600; color: var(--gold); }
.blog-hero-cover { aspect-ratio: 16/10; border-radius: 20px; overflow: hidden; box-shadow: 0 24px 50px rgba(0,0,0,.3); background: #4a2b8f; }
.blog-hero-cover img { width: 100%; height: 100%; object-fit: cover; }

.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.post-card { border: 1px solid var(--border); border-radius: 20px; overflow: hidden; background: #fff; box-shadow: 0 12px 34px rgba(80,50,160,.06); transition: transform .18s ease, box-shadow .18s ease; display: block; }
.post-card:hover { transform: translateY(-4px); box-shadow: 0 20px 44px rgba(80,50,160,.12); }
.post-cover { height: 190px; background: #f3eefe; }
.post-cover img { width: 100%; height: 100%; object-fit: cover; }
.post-body { padding: 24px 26px 28px; }
.post-meta { display: flex; justify-content: space-between; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); margin-bottom: 14px; }
.post-card h3 { font-family: var(--serif); font-size: 23px; font-weight: 600; color: var(--ink); margin: 0 0 12px; line-height: 1.2; }
.post-card p { font-size: 14.5px; line-height: 1.6; color: var(--muted); margin: 0 0 16px; }

/* Blog detail article */
.article { max-width: 760px; margin: 0 auto; padding: 60px 24px 20px; }
.article .back { font-size: 14px; font-weight: 600; color: var(--accent); display: inline-block; margin-bottom: 26px; }
.article-meta { display: flex; gap: 14px; align-items: center; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); margin-bottom: 16px; }
.article h1 { font-family: var(--serif); font-weight: 500; font-size: 46px; line-height: 1.08; letter-spacing: -.01em; color: var(--ink); margin: 0 0 28px; }
.article-cover { border-radius: 20px; overflow: hidden; margin-bottom: 40px; box-shadow: 0 20px 44px rgba(80,50,160,.12); }
.article-cover img { width: 100%; display: block; }
.prose { font-size: 18px; line-height: 1.75; color: #423a5c; }
.prose h2 { font-family: var(--serif); font-size: 32px; font-weight: 600; color: var(--ink); margin: 44px 0 14px; }
.prose h3 { font-family: var(--serif); font-size: 24px; font-weight: 600; color: var(--ink); margin: 32px 0 10px; }
.prose p { margin: 0 0 22px; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose ul, .prose ol { margin: 0 0 22px; padding-left: 24px; }
.prose li { margin-bottom: 8px; }
.prose blockquote { margin: 26px 0; padding: 6px 22px; border-left: 3px solid var(--accent-2); color: var(--muted); font-style: italic; }
.prose code { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: .88em; background: #f3eefe; padding: 2px 6px; border-radius: 6px; color: var(--accent-dark); }
.prose pre { background: var(--dark-a, #2d1b5e); color: #ede7ff; padding: 20px 22px; border-radius: 14px; overflow-x: auto; margin: 0 0 24px; }
.prose pre code { background: transparent; color: inherit; padding: 0; }
.prose img { border-radius: 14px; margin: 8px 0 24px; }

/* About */
.about-grid { max-width: 1180px; margin: 0 auto; padding: 70px 24px 20px; display: grid; grid-template-columns: 1fr 380px; gap: 56px; align-items: start; }
.about-heading { font-family: var(--serif); font-weight: 500; font-size: 52px; line-height: 1.05; letter-spacing: -.02em; color: var(--ink); margin: 0 0 26px; }
.about-body p { font-size: 17px; line-height: 1.7; color: var(--muted); margin: 0 0 18px; }
.about-body p:first-of-type { font-size: 18px; }
.skills-heading { font-family: var(--serif); font-size: 30px; font-weight: 600; color: var(--ink); margin: 40px 0 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { font-size: 14px; font-weight: 500; color: #3a2d63; background: #fff; border: 1px solid var(--border); padding: 9px 16px; border-radius: 999px; box-shadow: 0 4px 12px rgba(80,50,160,.05); }
.about-aside { position: sticky; top: 100px; }
.about-photo { aspect-ratio: 1; border-radius: 22px; overflow: hidden; border: 1px solid var(--border); box-shadow: 0 20px 44px rgba(80,50,160,.14); margin-bottom: 22px; background: #f3eefe; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.contact-card { padding: 26px; border-radius: 22px; background: radial-gradient(400px 240px at 80% 0%, var(--dark-b, #6d28d9) 0%, transparent 60%), linear-gradient(140deg, var(--dark-a, #2d1b5e), var(--dark-b, #4a2b8f)); }
.contact-card h3 { font-family: var(--serif); font-size: 24px; font-weight: 600; color: #fff; margin: 0 0 8px; }
.contact-card p { font-size: 14.5px; line-height: 1.55; color: #d8ccff; margin: 0 0 20px; }
.contact-links { display: flex; flex-direction: column; gap: 10px; }
.contact-link { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background: rgba(255,255,255,.08); border-radius: 12px; color: #fff; font-size: 14.5px; font-weight: 500; }
.contact-link:hover { background: rgba(255,255,255,.16); color: #fff; }
.contact-link .arr { color: var(--gold); }

/* Footer */
.footer { border-top: 1px solid var(--border); background: #f8f5ff; margin-top: 60px; }
.footer-inner { max-width: 1180px; margin: 0 auto; padding: 40px 24px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; }
.footer .logo-mark { width: 28px; height: 28px; }
.footer .logo-name { font-size: 18px; }
.footer-note { font-size: 14px; color: var(--faint); margin: 0; }

.empty { color: var(--faint); font-size: 16px; padding: 30px 0; }

/* Responsive */
@media (max-width: 900px) {
  .hero-grid, .about-grid, .blog-hero-grid { grid-template-columns: 1fr; }
  .cards, .post-grid { grid-template-columns: 1fr; }
  .proj-grid { grid-template-columns: 1fr; }
  .h1 { font-size: 46px; }
  .navlinks { display: none; }
  .about-aside { position: static; }
  .exp-row { grid-template-columns: 1fr; gap: 8px; }
}
