/* ========== CUSTOM FONT (Bruney Season) ========== */
@font-face {
  font-family: 'Bruney Season';
  src: url('../fonts/Bruney Season.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ========== BASE ========== */
:root {
  --ink: #130218;
  --muted: #5b6358;
  --lime: #7c36977e;
  --mint: #ab7cb8;
  --paper: #ffffff;
  --sans: 'Outfit', system-ui, sans-serif;
  --serif: 'Instrument Serif', Georgia, serif;
  --ui: 'Inter', system-ui, sans-serif;
}
button, input, textarea { font: inherit; }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--ui);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
section { scroll-margin-top: 80px; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ========== NAVBAR ========== */
.nav {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 5%;
  transition: background .3s ease, box-shadow .3s ease;
}
.nav.scrolled {
  background: rgba(255, 255, 255, .72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(11, 15, 10, .08);
}

.nav__logo {
  font-family: var(--ui);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -.02em;
  padding: 6px 12px;
  border-radius: 10px;
  transition: box-shadow .3s ease, transform .3s ease, background .3s ease;
}
.nav__logo:hover {
  box-shadow: 0 10px 26px rgba(11, 15, 10, .18);
  transform: translateY(-2px);
  background: #fff;
}

.nav__links {
  display: flex;
  gap: 4px;
  padding: 6px;
  background: rgba(255, 255, 255, .6);
  border: 1px solid rgba(11, 15, 10, .08);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.nav__links a {
  padding: 8px 18px;
  border-radius: 999px;
  font-size: .95rem;
  transition: background .25s ease, color .25s ease;
}
.nav__links a:hover,
.nav__links a.active { background: var(--ink); color: #fff; }

.nav__cta {
  padding: 10px 22px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: .95rem;
  transition: background .25s ease, color .25s ease;
}
.nav__cta:hover { background: var(--ink); color: #fff; }

.nav__toggle {
  display: none;
  width: 44px; height: 44px;
  border: 1px solid rgba(11, 15, 10, .15);
  border-radius: 50%;
  background: #fff;
  font-size: 1.3rem;
  cursor: pointer;
}

/* ========== HERO ========== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 100px 5% 0;
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff 0%, #f7ffe3 45%, #ffffff 100%);
}

.hero__glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  z-index: 0;
  animation: drift 14s ease-in-out infinite alternate;
}
.glow-1 {
  width: 120vw; height: 46vh;
  left: -10vw; top: 48%;
  background: var(--lime);
  opacity: .95;
}
.glow-2 {
  width: 40vw; height: 40vw;
  left: -10vw; top: 45%;
  background: var(--mint);
  opacity: .45;
  animation-delay: -6s;
}

.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 24vh;
  background: linear-gradient(rgba(255, 255, 255, 0), #fff 85%);
  z-index: 1;
  pointer-events: none;
}

.hero__tag {
  position: relative;
  z-index: 3;
  padding: 7px 16px;
  background: #fff;
  border: 1px solid rgba(11, 15, 10, .1);
  border-radius: 999px;
  font-size: .85rem;
  animation: fadeIn .8s ease both;
}

.hero__title {
  position: relative;
  z-index: 1;
  margin-top: 16px;
  text-align: center;
  font-family: var(--sans);
  font-weight: 300;
  font-size: clamp(2.4rem, min(6.5vw, 11vh), 6rem);
  line-height: 1;
  letter-spacing: -.04em;
}
.line {
  display: block;
  overflow: hidden;
  padding: .06em .1em .16em;
}
.word {
  display: inline-block;
  animation: rise 1s cubic-bezier(.2, .8, .2, 1) both;
}
.line:nth-child(2) .word { animation-delay: .15s; }

/* Role line ("AI & ML Engineer") — Bruney Season script font */
.role {
  font-family: 'Bruney Season', cursive;
  font-style: normal;
  font-weight: 400;
  font-size: 1.6em;
  letter-spacing: 0;
}
.line.role { padding: .2em .15em .32em; }

.cursor {
  display: inline-block;
  width: 3px; height: .8em;
  margin-left: 6px;
  background: var(--ink);
  vertical-align: -.05em;
  animation: blink 1s steps(1) infinite;
}

.hero__photo {
  position: absolute;
  left: 50%; bottom: 0;
  z-index: 2;
  height: clamp(400px, 66vh, 660px);
  width: auto;
  max-width: 92vw;
  object-fit: contain;
  object-position: bottom;
  filter: grayscale(1) brightness(1.15) contrast(.90)
          drop-shadow(0 20px 40px rgba(11, 15, 10, .25));
  pointer-events: none;
  animation: photoIn 1.2s .3s cubic-bezier(.2, .8, .2, 1) both;
}


.hero__pill {
  position: absolute;
  left: 6%; top: 62%;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background: #fff;
  border-radius: 999px;
  box-shadow: 0 6px 20px rgba(11, 15, 10, .08);
  font-size: .9rem;
  animation: fadeIn .8s .6s ease both;
}
.dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #3dd13d;
  box-shadow: 0 0 0 4px rgba(61, 209, 61, .25);
  animation: pulse 1.8s ease-in-out infinite;
}

.hero__text {
  position: absolute;
  right: 6%; top: 60%;
  z-index: 3;
  width: min(280px, 24vw);
  font-size: 1rem;
  line-height: 1.5;
  animation: fadeIn .8s .7s ease both;
}

.hero__stats {
  position: absolute;
  left: 6%; bottom: 7%;
  z-index: 3;
  font-size: .85rem;
  line-height: 1.5;
  color: var(--muted);
  animation: fadeIn .8s .9s ease both;
}
.hero__stats strong { color: var(--ink); font-size: 1.1rem; }

.hero__cta {
  position: absolute;
  right: 6%; bottom: 8%;
  z-index: 3;
  animation: fadeIn .8s .9s ease both;
}

.btn-dark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 26px;
  background: var(--ink);
  color: #fff;
  border-radius: 999px;
  box-shadow: 0 0 0 5px rgba(255, 255, 255, .55);
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn-dark:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(11,15,10,.25), 0 0 0 5px rgba(255,255,255,.55); }
.btn-dark i { transition: transform .25s ease; }
.btn-dark:hover i { transform: translateX(4px); }


/* ========== KEYFRAMES ========== */
@keyframes rise   { from { transform: translateY(110%); } to { transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes photoIn {
  from { opacity: 0; transform: translateX(-50%) translateY(40px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
@keyframes drift  { from { transform: translate(0, 0); } to { transform: translate(30px, -20px); } }
@keyframes blink  { 50% { opacity: 0; } }
@keyframes pulse  { 50% { box-shadow: 0 0 0 8px rgba(61, 209, 61, 0); } }
@keyframes iconPop { 0% { transform: scale(1) rotate(0deg); } 50% { transform: scale(1.12) rotate(-6deg); } 100% { transform: scale(1.06) rotate(0deg); } }

/* ========== RESPONSIVE (hero) ========== */
@media (max-width: 820px) {
  .nav__cta { display: none; }
  .nav__toggle { display: block; }
  .nav__links {
    position: absolute;
    top: 100%; left: 5%; right: 5%;
    flex-direction: column;
    display: none;
    padding: 12px;
    border-radius: 20px;
    background: #fff;
  }
  .nav__links.open { display: flex; }

  .hero { padding-top: 110px; }
  .hero__pill, .hero__text, .hero__cta {
    position: static;
    width: auto;
    margin-top: 18px;
    text-align: center;
  }
  .hero__text { order: 2; max-width: 360px; }
  .hero__pill { order: 3; }
  .hero__cta  { order: 4; }
  .hero__stats { display: none; }
  .hero__photo {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    margin: 0 auto;
    z-index: 2;
    order: 5;
    margin-top: auto;
    height: 50vh;
    animation-name: fadeIn;
  }
}

/* ========== SHARED SECTION STYLES ========== */
.container { width: min(1120px, 90%); margin-inline: auto; position: relative; z-index: 1; }
.section { padding: 110px 0; position: relative; overflow: hidden; }
.section--tint { background: #f8fbef; }

/* Subtle "something's there" glass-like texture on every section after the hero */
.section::before {
  content: "";
  position: absolute;
  inset: -10%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(520px circle at 12% 15%, rgba(124, 54, 151, .06), transparent 60%),
    radial-gradient(460px circle at 88% 85%, rgba(171, 124, 184, .06), transparent 60%);
}

.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head h2 {
  font-family: var(--sans);
  font-weight: 300;
  font-size: clamp(2.1rem, 4.6vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -.035em;
  margin-bottom: 12px;
}
.section-head p { color: var(--muted); font-size: 1.05rem; }

.card {
  background: #fff;
  border: 1px solid rgba(11, 15, 10, .1);
  border-radius: 20px;
  padding: 26px;
  transition: box-shadow .3s ease, border-color .3s ease, transform .3s ease;
}
.card:hover { box-shadow: 0 18px 40px rgba(11, 15, 10, .08); border-color: rgba(11, 15, 10, .25); transform: translateY(-4px); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.chips li {
  padding: 5px 13px;
  border-radius: 999px;
  background: #eef6d8;
  font-size: .82rem;
  transition: background .25s ease, transform .25s ease;
}
.chips li:hover { background: var(--lime); transform: translateY(-2px); }

.link {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 18px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: .9rem;
  transition: background .25s ease, color .25s ease, transform .25s ease;
}
.link:hover { background: var(--ink); color: #fff; transform: translateY(-2px); }
.link--solid { background: var(--ink); color: #fff; }
.link--solid:hover { background: #2a3525; }

/* ===== Scroll reveal: visible by default (safe fallback if JS fails),
   animated only once main.js confirms it loaded (adds .js-ready) ===== */
.reveal { opacity: 1; transform: none; }
.js-ready .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s ease var(--d, 0s),
              transform .8s cubic-bezier(.2, .8, .2, 1) var(--d, 0s),
              box-shadow .3s ease, border-color .3s ease;
}
.js-ready .reveal.in { opacity: 1; transform: none; }

/* ========== ABOUT ========== */
/* Photo column sits beside BOTH the heading and the text, top-aligned with
   the "About me" title itself — not just with the paragraphs below it. */
.about__layout { display: flex; align-items: flex-start; gap: 40px; flex-wrap: wrap; }
.about__left { flex: 1 1 58%; }
.about__left .section-head { margin-bottom: 32px; }
.about__text p { font-size: 1.1rem; margin-bottom: 18px; text-align: justify; }
.about__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.about__side {
  flex: 1 1 32%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.about__photo {
  width: 150px; height: 150px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 6px #fff, 0 18px 40px rgba(124, 54, 151, .45);
  transition: transform .3s ease, box-shadow .3s ease;
}
.about__photo:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 0 6px #fff, 0 22px 50px rgba(124, 54, 151, .6);
}

.facts { list-style: none; padding: 4px 22px; width: 100%; }
.facts li {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(11, 15, 10, .08);
}
.facts li:last-child { border-bottom: 0; }
.facts span { color: var(--muted); }
.facts b { font-weight: 500; text-align: right; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 40px; }
.stat { padding: 22px; border-radius: 20px; background: var(--lime); transition: transform .3s ease; }
.stat:hover { transform: translateY(-4px); }
.stat b {
  display: block;
  font-family: var(--sans);
  font-weight: 300;
  font-size: 2.6rem;
  line-height: 1;
  letter-spacing: -.04em;
}
.stat span { font-size: .9rem; }

/* ========== EXPERIENCE / EDUCATION (shared timeline) ========== */
.timeline { list-style: none; position: relative; display: grid; gap: 22px; padding-left: 34px; }
.timeline::before {
  content: "";
  position: absolute; left: 7px; top: 8px; bottom: 8px;
  width: 2px;
  background: rgba(11, 15, 10, .15);
}
.tl-item { position: relative; }
.tl-dot {
  position: absolute; left: -34px; top: 30px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--lime);
  border: 2px solid var(--ink);
  transition: transform .3s ease, box-shadow .3s ease;
}
.tl-item:hover .tl-dot { transform: scale(1.3); box-shadow: 0 0 0 6px rgba(124, 54, 151, .18); }
.tl-date { font-size: .85rem; color: var(--muted); margin-bottom: 4px; }
.tl-card h3 { font-size: 1.25rem; font-weight: 500; }
.tl-org { font-weight: 500; margin-bottom: 10px; }
.tl-card .chips { margin-top: 14px; }

/* ========== SKILLS ========== */
.skills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.skills h3 { font-size: 1.1rem; font-weight: 500; margin-bottom: 14px; }
.soft { margin-top: 28px; color: var(--muted); }

.skills-core { margin-bottom: 40px; }
.skills-core .col-title { font-size: 1.1rem; font-weight: 500; margin-bottom: 18px; }
.skills-core__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 14px;
}
.skill-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 20px 10px;
  background: #fff;
  border: 1px solid rgba(11, 15, 10, .1);
  border-radius: 18px;
  text-align: center;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.skill-icon i {
  font-size: 1.7rem;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--lime);
}
.skill-icon span { font-size: .85rem; font-weight: 500; }
.skill-icon:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 30px rgba(11, 15, 10, .1);
  border-color: rgba(11, 15, 10, .25);
}
.skill-icon:hover i { animation: iconPop .4s ease forwards; }

/* ========== PROJECTS ========== */
.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.project { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.project__art {
  position: relative;
  height: 170px;
  display: grid; place-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, var(--lime), var(--mint));
  transition: transform .4s ease;
}
.project:hover .project__art { transform: scale(1.04); }
.project:nth-child(even) .project__art { background: linear-gradient(135deg, var(--mint), #bfe6ff); }
.project__art img { width: 100%; height: 100%; object-fit: cover; }

/* decorative dot pattern so it reads as an illustration, not a flat block */
.project__art::before {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.35) 1.5px, transparent 1.5px);
  background-size: 18px 18px;
  opacity: .5;
}

.project__icon-main {
  position: relative;
  z-index: 1;
  font-size: 3rem;
  color: #fff;
  background: rgba(11, 15, 10, .18);
  width: 92px; height: 92px;
  display: grid; place-items: center;
  border-radius: 50%;
  box-shadow: 0 10px 24px rgba(11, 15, 10, .18);
}
.project__icon-badge {
  position: absolute;
  z-index: 2;
  font-size: 1.3rem;
  color: var(--ink);
  background: #fff;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  box-shadow: 0 8px 16px rgba(11, 15, 10, .18);
  transition: transform .3s ease;
}
.badge-a { top: 16px; right: 20%; }
.badge-b { bottom: 16px; left: 18%; }
.project:hover .badge-a { transform: translateY(-4px) rotate(-8deg); }
.project:hover .badge-b { transform: translateY(4px) rotate(8deg); }
.project__body { padding: 26px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.project__meta { font-size: .82rem; color: var(--muted); }
.project h3 { font-size: 1.3rem; font-weight: 500; }
.project__links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 6px; }

.more { margin-top: 48px; }
.more h3 { font-size: 1.1rem; font-weight: 500; margin-bottom: 14px; }
.more ul { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; list-style: none; }
.more li { padding: 16px 20px; border-radius: 16px; border: 1px solid rgba(11, 15, 10, .1); background: #fff; transition: transform .25s ease, box-shadow .25s ease; }
.more li:hover { transform: translateY(-3px); box-shadow: 0 14px 28px rgba(11,15,10,.08); }
.more li b { display: block; font-weight: 500; }
.more li span { color: var(--muted); font-size: .9rem; }

/* ========== CERTIFICATIONS ========== */
.cert-list { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.cert { display: flex; align-items: flex-start; gap: 14px; padding: 18px 20px; }
.cert i {
  flex: none;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: var(--lime);
  font-size: 1.5rem;
  transition: transform .3s ease;
}
.cert:hover i { transform: rotate(-12deg) scale(1.1); }
.cert b { display: block; font-weight: 500; }
.cert span { color: var(--muted); font-size: .9rem; }

/* ========== CONTACT + FOOTER ========== */
.contact { background: var(--ink); color: #fff; }
.contact .section-head p { color: #b9c4b0; }
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact__list { list-style: none; display: grid; gap: 14px; }
.contact__list a, .contact__list div {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 16px;
  transition: background .25s ease, transform .25s ease;
}
.contact__list a:hover { background: rgba(255, 255, 255, .08); transform: translateX(4px); }
.contact__list i { font-size: 1.4rem; color: var(--lime); }

.form { display: grid; gap: 16px; }
.form label { display: grid; gap: 6px; font-size: .9rem; color: #b9c4b0; }
.form input, .form textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .06);
  color: #fff;
}
.form input:focus, .form textarea:focus { outline: 2px solid var(--lime); outline-offset: 2px; }
.form textarea { min-height: 140px; resize: vertical; }

.btn-lime {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 16px 26px;
  border: 0;
  border-radius: 999px;
  background: #c9a9d4;
  color: var(--ink);
  font-weight: 500;
  cursor: pointer;
  transition: transform .25s ease, background .25s ease, box-shadow .25s ease;
}
.btn-lime:hover {
  background: #ddc2e6;
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(171, 124, 184, .45);
}

.footer { background: var(--ink); color: #8a9783; padding: 24px 0; border-top: 1px solid rgba(255, 255, 255, .1); font-size: .9rem; }
.footer .container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.footer a:hover { color: #fff; }

/* ========== RESPONSIVE (sections) ========== */
@media (max-width: 900px) {
  .section { padding: 80px 0; }
  .about__layout { flex-direction: column; }
  .contact__grid,
  .projects, .skills, .more ul, .cert-list { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .skills-core__grid { grid-template-columns: repeat(3, 1fr); }
}
