/* ============================================================
   Nan Aye Lwin — Portfolio
   Palette: warm paper · deep forest ink · muted gold
   ============================================================ */

:root {
  --paper: #f6f3ec;
  --paper-2: #efe9dd;
  --ink: #23281e;
  --ink-2: #55584c;
  --forest: #4c6b48;
  --forest-deep: #2f4430;
  --gold: #b08a3e;
  --gold-soft: #d8c391;
  --line: rgba(35, 40, 30, 0.14);
  --card: #fffdf8;
  --shadow: 0 24px 60px -24px rgba(35, 40, 30, 0.35);
  --shadow-sm: 0 10px 30px -12px rgba(35, 40, 30, 0.25);
  --r-lg: 28px;
  --r-md: 18px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", system-ui, sans-serif;
  background:
    radial-gradient(1200px 600px at 85% -5%, rgba(176, 138, 62, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(76, 107, 72, 0.08), transparent 55%),
    var(--paper);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--forest); color: var(--paper); }

h1, h2, h3, .hero__role, .modal__title {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.01em;
}
em { font-style: italic; font-weight: 300; }

/* ---------- scroll progress ---------- */
.progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 90;
  pointer-events: none;
}
.progress span {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--forest), var(--gold));
  transition: width 0.12s linear;
}

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 18px; left: 50%; transform: translateX(-50%);
  width: min(1160px, calc(100% - 32px));
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px 12px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(246, 243, 236, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 80;
  transition: box-shadow 0.4s var(--ease), background 0.4s;
}
.nav.is-scrolled { box-shadow: var(--shadow-sm); background: rgba(246, 243, 236, 0.9); }

.nav__brand { display: flex; align-items: center; gap: 12px; }
.nav__monogram {
  display: grid; place-items: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--forest-deep); color: var(--paper);
  font-family: "Fraunces", serif; font-size: 14px; letter-spacing: 0.08em;
  transition: transform 0.5s var(--ease-spring);
}
.nav__brand:hover .nav__monogram { transform: rotate(-10deg) scale(1.06); }
.nav__name { font-family: "Fraunces", serif; font-size: 18px; }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a { font-size: 14px; color: var(--ink-2); position: relative; transition: color 0.3s; }
.nav__links a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: -4px; height: 1.5px; width: 100%;
  background: var(--forest); transform: scaleX(0); transform-origin: right;
  transition: transform 0.35s var(--ease);
}
.nav__links a:not(.btn):hover { color: var(--ink); }
.nav__links a:not(.btn):hover::after { transform: scaleX(1); transform-origin: left; }

/* hamburger (mobile) */
.nav__toggle {
  display: none; width: 42px; height: 42px; border: 1px solid var(--line);
  border-radius: 50%; background: transparent; cursor: pointer;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.nav__toggle span {
  display: block; width: 16px; height: 1.8px; background: var(--ink); border-radius: 2px;
  transition: transform 0.35s var(--ease), opacity 0.3s;
}
.nav__toggle.is-open span:first-child { transform: translateY(3.4px) rotate(45deg); }
.nav__toggle.is-open span:last-child { transform: translateY(-3.4px) rotate(-45deg); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 22px; border-radius: 999px;
  font-size: 14px; font-weight: 500; letter-spacing: 0.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.35s var(--ease-spring), box-shadow 0.35s var(--ease),
              background 0.3s, color 0.3s, border-color 0.3s;
}
.btn svg { width: 16px; height: 16px; transition: transform 0.35s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn--primary {
  background: var(--forest-deep); color: var(--paper);
  box-shadow: 0 14px 30px -12px rgba(47, 68, 48, 0.55);
}
.btn--primary:hover { box-shadow: 0 20px 40px -14px rgba(47, 68, 48, 0.65); }
.btn--primary:hover svg { transform: translateY(3px); }
.btn--ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn--ghost:hover { border-color: var(--forest); background: rgba(76, 107, 72, 0.07); }
.btn--ghost:hover svg { transform: translateY(3px); }
.btn--small { padding: 9px 16px; font-size: 13px; border-color: var(--line); color: var(--ink); }
.btn--small:hover { border-color: var(--forest); background: rgba(76, 107, 72, 0.07); }
.btn--light { background: var(--paper); color: var(--forest-deep); }
.btn--light:hover { box-shadow: 0 18px 40px -16px rgba(0, 0, 0, 0.5); }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 140px 24px 80px;
}
.hero__inner {
  width: min(1160px, 100%); margin: 0 auto;
  display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center;
}
.hero__eyebrow {
  font-size: 13px; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--forest); margin-bottom: 22px;
}
.hero__title { font-size: clamp(3rem, 8.5vw, 6.2rem); }
.hero__line { display: block; overflow: hidden; }
.hero__line em { color: var(--forest); }
.hero__role {
  margin-top: 18px; font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  color: var(--gold); letter-spacing: 0.06em;
}
.hero__lead { max-width: 46ch; margin-top: 18px; color: var(--ink-2); font-size: 15.5px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

.hero__figure { position: relative; justify-self: center; width: min(380px, 80vw); aspect-ratio: 4/5; }
.hero__blob {
  position: absolute; inset: -7%;
  background: linear-gradient(140deg, rgba(76, 107, 72, 0.16), rgba(176, 138, 62, 0.14));
  border-radius: 58% 42% 55% 45% / 52% 55% 45% 48%;
  animation: blob 12s ease-in-out infinite alternate;
  filter: blur(2px);
}
@keyframes blob {
  0%   { border-radius: 58% 42% 55% 45% / 52% 55% 45% 48%; transform: rotate(0deg) scale(1); }
  50%  { border-radius: 45% 55% 42% 58% / 48% 42% 58% 52%; transform: rotate(8deg) scale(1.04); }
  100% { border-radius: 55% 45% 58% 42% / 55% 45% 48% 52%; transform: rotate(-6deg) scale(1); }
}
.hero__ring {
  position: absolute; inset: -16%;
  border: 1px dashed rgba(76, 107, 72, 0.4); border-radius: 50%;
  animation: spin 40s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.hero__frame {
  position: relative; height: 100%; border-radius: var(--r-lg); overflow: hidden;
  box-shadow: var(--shadow); border: 6px solid var(--card);
  transform-style: preserve-3d; transition: transform 0.2s ease-out;
  will-change: transform;
}
.hero__frame img { width: 100%; height: 100%; object-fit: cover; }
.hero__spark {
  position: absolute; top: 14px; right: 18px; font-size: 22px; color: var(--paper);
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.35);
  animation: twinkle 3.2s ease-in-out infinite;
}
@keyframes twinkle {
  0%, 100% { opacity: 0.5; transform: scale(0.85) rotate(0deg); }
  50%      { opacity: 1;   transform: scale(1.12) rotate(20deg); }
}

.hero__badge {
  position: absolute; left: -34px; bottom: 34px;
  display: flex; align-items: center; gap: 10px;
  background: var(--card); border: 1px solid var(--line);
  padding: 12px 18px; border-radius: 999px; box-shadow: var(--shadow-sm);
  animation: float 5.5s ease-in-out infinite;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
.hero__badge-num { font-family: "Fraunces", serif; font-size: 26px; color: var(--forest); }
.hero__badge-txt { font-size: 11px; line-height: 1.3; color: var(--ink-2); text-transform: uppercase; letter-spacing: 0.08em; }

.hero__scroll {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px;
  font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--ink-2);
}
.hero__scroll-line { width: 54px; height: 1px; background: var(--ink-2); position: relative; overflow: hidden; }
.hero__scroll-line::after {
  content: ""; position: absolute; inset: 0; background: var(--gold);
  transform: translateX(-100%); animation: slide 2.4s var(--ease) infinite;
}
@keyframes slide { 0% { transform: translateX(-100%); } 60%, 100% { transform: translateX(100%); } }

/* ---------- marquee ---------- */
.marquee {
  border-block: 1px solid var(--line);
  padding: 14px 0; overflow: hidden; white-space: nowrap;
  background: var(--paper-2);
}
.marquee__track {
  display: inline-flex; align-items: center; gap: 28px; padding-right: 28px;
  animation: marquee 26s linear infinite;
}
.marquee span { font-family: "Fraunces", serif; font-style: italic; font-size: 17px; color: var(--ink-2); }
.marquee i { color: var(--gold); font-style: normal; font-size: 12px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
.section { width: min(1160px, 100%); margin: 0 auto; padding: 110px 24px; }
.section--tint { width: 100%; background: var(--paper-2); border-block: 1px solid var(--line); }
.section--tint > * { width: min(1160px, 100%); margin-inline: auto; }

.section__head { display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: 8px 20px; margin-bottom: 54px; }
.section__num { grid-row: 1; font-size: 14px; color: var(--gold); letter-spacing: 0.12em; }
.section__title { grid-column: 2; font-size: clamp(2rem, 4.5vw, 3.2rem); }
.section__hint { grid-column: 2; font-size: 13px; color: var(--ink-2); letter-spacing: 0.06em; }

/* ---------- about ---------- */
.about { max-width: 860px; }
.about__quote {
  font-family: "Fraunces", serif; font-size: clamp(1.35rem, 3vw, 2rem);
  font-style: italic; line-height: 1.45; color: var(--forest-deep);
  border-left: 2px solid var(--gold); padding-left: 26px;
}
.about__body { margin-top: 26px; color: var(--ink-2); max-width: 62ch; font-size: 15.5px; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 56px; }
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 26px 22px; text-align: center;
  transition: transform 0.4s var(--ease-spring), box-shadow 0.4s var(--ease);
}
.stat:hover { transform: translateY(-6px); box-shadow: var(--shadow-sm); }
.stat__num { font-family: "Fraunces", Georgia, serif; font-size: 44px; color: var(--forest); }
.stat__plus { font-family: "Fraunces", serif; font-size: 26px; color: var(--gold); }
.stat__label { display: block; margin-top: 6px; font-size: 12.5px; color: var(--ink-2); }

/* ---------- experience cards ---------- */
.timeline { display: grid; gap: 18px; }
.card {
  position: relative; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 30px 32px; cursor: pointer;
  transition: transform 0.45s var(--ease-spring), box-shadow 0.45s var(--ease), border-color 0.3s;
}
.card:hover, .card:focus-visible {
  transform: translateY(-5px) scale(1.008);
  box-shadow: var(--shadow); border-color: rgba(76, 107, 72, 0.45);
}
.card__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.card__years { font-size: 13px; letter-spacing: 0.14em; color: var(--gold); }
.card__dot {
  width: 9px; height: 9px; border-radius: 50%; background: var(--forest); opacity: 0.35;
  transition: opacity 0.3s, transform 0.3s;
}
.card:hover .card__dot { opacity: 1; transform: scale(1.25); }
.card__title { font-size: clamp(1.3rem, 2.6vw, 1.7rem); }
.card__org { margin-top: 4px; font-size: 14px; color: var(--forest); }
.card__excerpt { margin-top: 12px; color: var(--ink-2); max-width: 60ch; font-size: 14.5px; }
.card__more {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 16px;
  font-size: 13px; color: var(--forest); letter-spacing: 0.05em;
}
.card__more i { font-style: normal; transition: transform 0.35s var(--ease); }
.card:hover .card__more i { transform: translate(4px, -4px); }

/* shimmer sweep on hover */
.card::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(176, 138, 62, 0.08) 45%, rgba(176, 138, 62, 0.08) 55%, transparent 70%);
  transform: translateX(-120%); transition: transform 0.9s var(--ease);
  pointer-events: none;
}
.card:hover::before { transform: translateX(120%); }

/* ---------- education ---------- */
.edu-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.edu {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 26px 22px; cursor: pointer;
  display: flex; flex-direction: column; gap: 8px;
  transition: transform 0.45s var(--ease-spring), box-shadow 0.45s var(--ease), border-color 0.3s;
}
.edu:hover, .edu:focus-visible {
  transform: translateY(-6px) rotate(-0.5deg);
  box-shadow: var(--shadow-sm); border-color: rgba(76, 107, 72, 0.45);
}
.edu__icon {
  width: 46px; height: 46px; border-radius: 14px;
  display: grid; place-items: center;
  background: rgba(76, 107, 72, 0.1); color: var(--forest);
  transition: transform 0.4s var(--ease-spring), background 0.3s, color 0.3s;
}
.edu:hover .edu__icon { transform: rotate(-8deg) scale(1.1); background: rgba(176, 138, 62, 0.14); color: var(--gold); }
.edu__icon svg { width: 22px; height: 22px; }
.edu__years { font-size: 12px; letter-spacing: 0.14em; color: var(--gold); margin-top: 10px; }
.edu__title { font-size: 19px; line-height: 1.25; }
.edu__org { font-size: 13.5px; color: var(--ink-2); }

/* ---------- skills ---------- */
.skills { display: flex; flex-wrap: wrap; gap: 12px; }
.chip {
  padding: 12px 20px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line);
  font-size: 14px; cursor: default;
  transition: transform 0.35s var(--ease-spring), border-color 0.3s, background 0.3s;
}
.chip:hover { transform: translateY(-4px) rotate(-1deg); border-color: var(--forest); background: rgba(76, 107, 72, 0.07); }
.chip small { color: var(--ink-2); font-size: 12px; }

.langs { margin-top: 64px; }
.langs__title { font-family: "Fraunces", serif; font-size: 22px; margin-bottom: 24px; }
.langs__row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.lang {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 20px 22px;
}
.lang__name { font-family: "Fraunces", serif; font-size: 19px; }
.lang__level {
  display: block; font-size: 12.5px; color: var(--gold);
  letter-spacing: 0.1em; text-transform: uppercase; margin-top: 2px;
}
.lang__bar {
  display: block; height: 5px; margin-top: 14px; border-radius: 99px;
  background: rgba(35, 40, 30, 0.08); overflow: hidden;
}
.lang__bar i {
  display: block; height: 100%; width: var(--w); border-radius: 99px;
  background: linear-gradient(90deg, var(--forest), var(--gold));
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.2s var(--ease) 0.2s;
}
.langs.in-view .lang__bar i { transform: scaleX(1); }

/* ---------- contact (dark) ---------- */
.section--dark {
  width: 100%;
  background:
    radial-gradient(700px 400px at 80% 20%, rgba(176, 138, 62, 0.14), transparent 60%),
    var(--forest-deep);
  color: var(--paper);
  padding: 120px 24px 90px;
}
.section--dark .section__head { width: min(1160px, 100%); margin: 0 auto 54px; }
.section--dark .section__title em { color: var(--gold-soft); }

.contact-grid {
  width: min(1160px, 100%); margin: 0 auto;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.contact {
  position: relative; overflow: hidden;
  border: 1px solid rgba(246, 243, 236, 0.18); border-radius: var(--r-md);
  padding: 30px; display: block;
  transition: transform 0.4s var(--ease-spring), background 0.3s, border-color 0.3s;
}
.contact:hover {
  transform: translateY(-6px);
  background: rgba(246, 243, 236, 0.06); border-color: rgba(246, 243, 236, 0.4);
}
.contact__label { display: block; font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: #b8c2ae; }
.contact__value { display: block; margin-top: 10px; font-family: "Fraunces", serif; font-size: clamp(1.05rem, 2vw, 1.35rem); }
.contact__arrow {
  position: absolute; top: 26px; right: 26px; font-style: normal; opacity: 0.5;
  transition: transform 0.35s var(--ease), opacity 0.3s;
}
.contact:hover .contact__arrow { transform: translate(4px, -4px); opacity: 1; }

.contact__cta {
  width: min(1160px, 100%); margin: 44px auto 0;
  display: flex; flex-wrap: wrap; align-items: center; gap: 22px;
}
.contact__cta p { color: #b8c2ae; font-size: 14px; }
.btn--light:hover svg { transform: translateY(3px); }

/* ---------- footer ---------- */
.footer {
  background: var(--forest-deep); color: rgba(246, 243, 236, 0.75);
  border-top: 1px solid rgba(246, 243, 236, 0.12);
  padding: 30px 24px;
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap;
  gap: 8px 22px; font-size: 13.5px;
}
.footer__mark { color: var(--gold); }
.footer__top { border-bottom: 1px solid transparent; transition: border-color 0.3s, color 0.3s; }
.footer__top:hover { color: var(--paper); border-color: currentColor; }

/* ============================================================
   MODAL — the animated popup
   ============================================================ */
.modal {
  position: fixed; inset: 0; z-index: 120;
  display: grid; place-items: center; padding: 24px;
  pointer-events: none;
}
.modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(30, 34, 26, 0.55);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  opacity: 0; transition: opacity 0.45s var(--ease);
}
.modal__dialog {
  position: relative; width: min(620px, 100%);
  max-height: min(82vh, 780px); overflow: auto;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.55);
  padding: 46px 46px 40px;
  opacity: 0; transform: translateY(60px) scale(0.92);
  transition: transform 0.55s var(--ease-spring), opacity 0.4s;
}
.modal__halo {
  position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
  background: radial-gradient(420px 200px at 50% 0%, rgba(176, 138, 62, 0.12), transparent 70%);
}
.modal__close {
  position: sticky; top: 0; float: right; margin: -14px -18px 0 0;
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--card); color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
  transition: transform 0.35s var(--ease-spring), background 0.3s, color 0.3s;
}
.modal__close:hover { transform: rotate(90deg) scale(1.08); background: var(--forest-deep); color: var(--paper); }
.modal__close svg { width: 16px; height: 16px; }
.modal__tag {
  display: inline-block; padding: 6px 14px; border-radius: 999px;
  background: rgba(76, 107, 72, 0.1); color: var(--forest);
  font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
}
.modal__title { margin-top: 16px; font-size: clamp(1.6rem, 4vw, 2.1rem); }
.modal__org { margin-top: 6px; color: var(--gold); font-size: 15px; }
.modal__divider { margin: 24px 0; height: 1px; background: var(--line); position: relative; }
.modal__divider i {
  position: absolute; left: 0; top: -1px; height: 3px; width: 56px;
  background: linear-gradient(90deg, var(--forest), var(--gold));
  border-radius: 3px;
}
.modal__points { list-style: none; }
.modal__points li {
  position: relative; padding-left: 26px; margin-bottom: 13px;
  color: var(--ink-2); font-size: 14.5px;
  opacity: 0; transform: translateX(-14px);
}
.modal__points li::before {
  content: "✦"; position: absolute; left: 0; top: 0;
  font-size: 11px; color: var(--gold);
}
.modal.is-open .modal__points li { animation: pointIn 0.55s var(--ease) forwards; }
.modal.is-open .modal__points li:nth-child(1) { animation-delay: 0.20s; }
.modal.is-open .modal__points li:nth-child(2) { animation-delay: 0.28s; }
.modal.is-open .modal__points li:nth-child(3) { animation-delay: 0.36s; }
.modal.is-open .modal__points li:nth-child(4) { animation-delay: 0.44s; }
.modal.is-open .modal__points li:nth-child(5) { animation-delay: 0.52s; }
.modal.is-open .modal__points li:nth-child(6) { animation-delay: 0.60s; }
.modal.is-open .modal__points li:nth-child(7) { animation-delay: 0.68s; }
@keyframes pointIn { to { opacity: 1; transform: translateX(0); } }

.modal__foot {
  margin-top: 26px; padding-top: 18px; border-top: 1px dashed var(--line);
  font-size: 13px; color: var(--ink-2); font-style: italic;
}
.modal__foot:empty { display: none; }

.modal.is-open { pointer-events: auto; }
.modal.is-open .modal__backdrop { opacity: 1; }
.modal.is-open .modal__dialog {
  opacity: 1; transform: translateY(0) scale(1);
  transition: transform 0.6s var(--ease-spring), opacity 0.45s;
}
.modal.is-closing .modal__dialog { transform: translateY(40px) scale(0.94); opacity: 0; }
body.modal-open { overflow: hidden; }

/* ---------- toast ---------- */
.toast {
  position: fixed; bottom: 30px; left: 50%; transform: translate(-50%, 80px);
  background: var(--ink); color: var(--paper);
  padding: 12px 22px; border-radius: 999px;
  font-size: 13.5px; opacity: 0; z-index: 140; pointer-events: none;
  transition: transform 0.5s var(--ease-spring), opacity 0.4s;
}
.toast.is-visible { transform: translate(-50%, 0); opacity: 1; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero__inner { grid-template-columns: 1fr; gap: 64px; text-align: center; }
  .hero__figure { order: -1; }
  .hero__lead { margin-inline: auto; }
  .hero__actions { justify-content: center; }
  .hero__badge { left: -10px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .edu-grid { grid-template-columns: repeat(2, 1fr); }
  .langs__row { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav__links {
    position: fixed; inset: 74px 16px auto; flex-direction: column; align-items: stretch;
    background: rgba(246, 243, 236, 0.97); backdrop-filter: blur(16px);
    border: 1px solid var(--line); border-radius: 24px; padding: 22px; gap: 16px;
    box-shadow: var(--shadow);
    transform: translateY(-16px); opacity: 0; visibility: hidden;
    transition: transform 0.4s var(--ease), opacity 0.3s, visibility 0.3s;
  }
  .nav__links.is-open { transform: none; opacity: 1; visibility: visible; }
  .nav__links a { font-size: 16px; }
  .nav__toggle { display: flex; }
  .section { padding: 80px 20px; }
  .modal { padding: 16px; }
  .modal__dialog { padding: 34px 26px 30px; }
  .hero { padding-top: 120px; }
  .card { padding: 24px 22px; }
  .section__hint { display: none; }
  .hero__scroll { display: none; }
}

@media (max-width: 460px) {
  .stats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .stat { padding: 20px 14px; }
  .stat__num { font-size: 34px; }
  .edu-grid { grid-template-columns: 1fr; }
  .hero__badge { padding: 9px 14px; left: -6px; bottom: 20px; }
  .hero__badge-num { font-size: 21px; }
}
