@font-face {
  font-family: "Agustina Regular";
  src: url("assets/fonts/Agustina.woff") format("woff");
  font-display: swap;
}

@font-face {
  font-family: "Montserrat";
  src: url("assets/fonts/Montserrat-Regular.ttf") format("truetype");
  font-display: swap;
}

:root {
  --button: #55198b;
  --button-hover: #8c43ce;
  --button-soft: #efe3ff;
  --accent: #0f9dca;
  --header-bg: rgba(255, 255, 255, 0.92);
  --header-hover: #f4f4f4;
  --mobile-nav-bg: rgba(255, 255, 255, 0.98);
  --chip-border: #e9d8ff;
  --btn-hover-bg: #ffffff;
  --title: #000000;
  --text: #111111;
  --sub: #868e96;
  --card-sub: #666666;
  --surface: #ffffff;
  --surface-soft: #f5f2f4;
  --line: rgba(211, 211, 211, 0.48);
  --shadow-strong: rgba(0, 0, 0, 0.24);
  --progress-bg: rgb(243, 239, 239);
  --progress-fill: #aaa5ff;
  --facebook: #3b5998;
  --linkedin: #0e76a8;
  --github: #333333;
  --leetcode: #ffa116;
  --gitlab: #fca326;
  --medium: #000000;
  --stackoverflow: #f48024;
  --gmail: #ea4335;
  --radius-card: 16px;
  --radius-pill: 999px;
  --section-gap: clamp(3rem, 5.5vw, 5.6rem);
  --card-padding: clamp(1rem, 2vw, 1.45rem);
  --shadow-card: 0 18px 36px -26px var(--shadow-strong);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  font: 18px/1.62 "Montserrat", sans-serif;
  background: #ffffff;
}

.page {
  min-height: 100vh;
  color: var(--text);
  background: radial-gradient(circle at 0% 0%, #f6f1ff 0%, #ffffff 42%),
    radial-gradient(circle at 100% 100%, #eef6ff 0%, rgba(238, 246, 255, 0) 38%);
  position: relative;
  transition: background 0.35s ease, color 0.25s ease;
}

.page::before {
  content: "";
  position: fixed;
  right: -120px;
  top: 22%;
  width: 340px;
  height: 340px;
  border-radius: 100%;
  background: radial-gradient(circle at 30% 30%, rgba(140, 67, 206, 0.22), rgba(140, 67, 206, 0));
  pointer-events: none;
  z-index: -1;
}

.theme-mode-toggle {
  position: fixed;
  opacity: 0;
  pointer-events: none;
}

.theme-mode-toggle:checked ~ .page {
  --button: #8c43ce;
  --button-hover: #55198b;
  --button-soft: #31264f;
  --accent: #5ed4ff;
  --header-bg: rgba(23, 28, 40, 0.95);
  --header-hover: rgba(255, 255, 255, 0.08);
  --mobile-nav-bg: rgba(23, 28, 40, 0.99);
  --chip-border: #3c315c;
  --btn-hover-bg: #ffffff;
  --title: #ffffff;
  --text: #ffffff;
  --sub: #b8bfca;
  --card-sub: #d9dde4;
  --surface: #171c28;
  --surface-soft: #212838;
  --line: rgba(255, 255, 255, 0.16);
  --shadow-strong: rgba(0, 0, 0, 0.6);
  --progress-bg: #2f3647;
  --progress-fill: #8477f0;
  background: radial-gradient(circle at 0% 0%, #2a2e44 0%, #171c28 40%),
    radial-gradient(circle at 100% 100%, #2d2448 0%, rgba(45, 36, 72, 0) 38%), #171c28;
}

.theme-mode-toggle:checked ~ .page::before {
  background: radial-gradient(circle at 30% 30%, rgba(132, 119, 240, 0.3), rgba(132, 119, 240, 0));
}

::selection {
  background: var(--button-soft);
  color: var(--title);
}

a {
  color: var(--button);
  text-decoration: none;
}

a:hover {
  color: var(--button-hover);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
label:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: 0.6rem;
  top: -100px;
  background: var(--title);
  color: #ffffff;
  padding: 0.6rem 0.85rem;
  border-radius: 0 0 8px 8px;
  z-index: 30;
}

.skip-link:focus {
  top: 0;
}

.shell {
  width: min(1240px, 92vw);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 10px 22px -20px rgba(0, 0, 0, 0.7);
  animation: header-drop 0.5s ease both;
}

@keyframes header-drop {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 76px;
  padding: 10px 4px;
}

.brand {
  font-family: "Agustina Regular", cursive;
  font-size: 1.5em;
  line-height: 1;
  color: var(--text);
}

.theme-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
}

.theme-switch .fa-sun {
  color: #f4a024;
}

.theme-switch .fa-moon {
  color: #6e62e3;
}

.theme-mode-toggle:checked ~ .page .theme-switch {
  background: #212838;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.site-nav a {
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 11px 14px;
  border-radius: 10px;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover {
  background: var(--header-hover);
  color: var(--text);
  transform: translateY(-1px);
}

.menu-toggle,
.menu-icon {
  display: none;
}

.hero {
  margin-top: 2.8rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(2rem, 4vw, 4.2rem);
  align-items: center;
}

.hero-copy {
  max-width: 680px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 1rem;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: linear-gradient(90deg, var(--button-soft), var(--surface));
  color: var(--button);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-kicker::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--button);
  box-shadow: 0 0 0 6px rgba(85, 25, 139, 0.12);
  animation: kicker-pulse 2.4s ease-in-out infinite;
}

@keyframes kicker-pulse {
  0%, 100% { box-shadow: 0 0 0 0   rgba(85, 25, 139, 0.45); }
  60%       { box-shadow: 0 0 0 9px rgba(85, 25, 139, 0);    }
}

.hero h1 {
  margin: 0;
  font-size: clamp(2rem, 4.8vw, 3.6rem);
  line-height: 1.08;
  color: var(--title);
}

.hero-typed {
  margin-top: 0.85rem;
  min-height: 2rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  font-size: clamp(1rem, 1.9vw, 1.22rem);
  font-weight: 700;
  line-height: 1.35;
}

.typed-label {
  color: var(--sub);
  font-weight: 600;
}

#typed-text {
  color: var(--button);
}

.typing-cursor {
  width: 3px;
  height: 1.1em;
  border-radius: 4px;
  background: var(--button);
  animation: cursor-blink 0.9s steps(1, end) infinite;
}

@keyframes cursor-blink {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

.subtitle {
  color: var(--sub);
  margin-top: 0.8rem;
  font-size: 18px;
  line-height: 1.5;
}

.hero-subtitle {
  color: var(--sub);
  margin-top: 0.9rem;
  max-width: 34ch;
  font-size: clamp(1rem, 2.1vw, 1.5rem);
  line-height: 1.58;
}

.wave {
  display: inline-block;
  transform-origin: 70% 70%;
  animation: wave 1.9s infinite;
}

@keyframes wave {
  0% {
    transform: rotate(0deg);
  }
  10% {
    transform: rotate(-10deg);
  }
  20% {
    transform: rotate(12deg);
  }
  30% {
    transform: rotate(-10deg);
  }
  40% {
    transform: rotate(9deg);
  }
  50%,
  100% {
    transform: rotate(0deg);
  }
}

.hero-art img {
  width: 100%;
  height: auto;
}

.hero-copy > * {
  animation: fade-up 0.62s ease both;
}

.hero-copy > :nth-child(1) { animation-delay: 0.05s; }
.hero-copy > :nth-child(2) { animation-delay: 0.20s; }
.hero-copy > :nth-child(3) { animation-delay: 0.36s; }
.hero-copy > :nth-child(4) { animation-delay: 0.46s; }
.hero-copy > :nth-child(5) { animation-delay: 0.58s; }
.hero-copy > :nth-child(6) { animation-delay: 0.70s; }

.hero-art {
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fade-up 0.95s ease both;
}

.photo-stage {
  position: relative;
  width: min(460px, 100%);
  padding: 18px 12px 28px;
}

.photo-stage::before,
.photo-stage::after {
  content: "";
  position: absolute;
  z-index: 0;
  pointer-events: none;
}

.photo-stage::before {
  inset: 14% 12% 8% 12%;
  border-radius: 44% 56% 48% 52% / 40% 42% 58% 60%;
  background: radial-gradient(circle at 50% 40%, rgba(140, 67, 206, 0.22), rgba(140, 67, 206, 0.04) 52%, rgba(140, 67, 206, 0) 72%);
}

.photo-stage::after {
  width: 74%;
  height: 18px;
  left: 13%;
  bottom: 18px;
  border-radius: 999px;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.28), rgba(0, 0, 0, 0));
  filter: blur(10px);
}

.photo-card {
  position: relative;
  z-index: 1;
  width: min(390px, 100%);
  margin: 0 auto;
  padding: 0;
  border-radius: 34px;
  background: transparent;
  border: none;
  box-shadow: none;
}

.hero-photo {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  object-position: center 15%;
  background: transparent;
  filter: drop-shadow(0px 26px 40px rgba(0, 0, 0, 0.28));
}

.photo-badge {
  position: absolute;
  z-index: 2;
  padding: 10px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0px 16px 32px -20px var(--shadow-strong);
  color: var(--title);
  font-size: 0.82rem;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.theme-mode-toggle:checked ~ .page .photo-badge {
  background: rgba(23, 28, 40, 0.86);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.photo-badge-top {
  top: 18px;
  left: 0;
  animation: float-up-down 3.4s ease-in-out infinite;
}

.photo-badge-bottom {
  right: 6px;
  bottom: 18px;
  animation: float-up-down 4.0s ease-in-out infinite 0.9s;
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float-up-down {
  0%, 100% { transform: translateY(0);   }
  50%       { transform: translateY(-7px); }
}

.hero-cta {
  margin-top: 1.7rem;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  background: var(--button);
  border: 1px solid var(--button);
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 12px 20px;
  border-radius: var(--radius-pill);
  font-size: 0.86rem;
  transition: all 0.25s ease;
  box-shadow: 0 10px 22px -16px rgba(85, 25, 139, 0.75);
}

.btn:hover {
  color: var(--button);
  background: var(--btn-hover-bg);
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--button);
}

.btn-ghost:hover {
  background: var(--button);
  color: #ffffff;
}

.social-grid {
  margin-top: 1.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 2em;
}

.social {
  display: inline-block;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.social i {
  width: 2.85rem;
  height: 2.85rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 1.18rem;
  box-shadow: 0 10px 20px -14px var(--shadow-strong);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.social-icon-image {
  width: 2.85rem;
  height: 2.85rem;
  display: block;
  padding: 0.68rem;
  border-radius: 50%;
  background-color: var(--leetcode);
  box-shadow: 0 10px 20px -14px var(--shadow-strong);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.social span {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.social:hover {
  transform: translateY(-4px);
}

.facebook {
  color: var(--facebook);
}

.linkedin {
  color: var(--linkedin);
}

.github {
  color: var(--github);
}

.leetcode {
  color: var(--leetcode);
}

.gitlab {
  color: var(--gitlab);
}

.medium {
  color: var(--medium);
}

.stackoverflow {
  color: var(--stackoverflow);
}

.gmail {
  color: var(--gmail);
}

.facebook i {
  background-color: var(--facebook);
}

.linkedin i {
  background-color: var(--linkedin);
}

.github i {
  background-color: var(--github);
}

.leetcode .social-icon-image {
  background-color: var(--leetcode);
}

.gitlab i {
  background-color: var(--gitlab);
}

.medium i {
  background-color: var(--medium);
}

.stackoverflow i {
  background-color: var(--stackoverflow);
}

.gmail i {
  background-color: var(--gmail);
}

.social:hover i,
.social:hover .social-icon-image {
  transform: scale(1.06);
  filter: brightness(1.04) saturate(1.02);
  box-shadow: 0 16px 28px -18px var(--shadow-strong);
}

.section {
  margin-top: var(--section-gap);
}

.section-head {
  max-width: 760px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.split {
  margin-top: 1.8rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: var(--card-padding);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0px 22px 36px -20px var(--shadow-strong);
  border-color: rgba(140, 67, 206, 0.45);
}

.image-card {
  display: grid;
  place-items: center;
}

.image-card img {
  max-width: 100%;
  height: auto;
}

.card h3,
.card h4,
.timeline-card h3,
.project-card h3,
.achievement-card h3,
.blog-card h3,
.talk-card h3 {
  margin-top: 0;
  margin-bottom: 0.55rem;
}

.bullet-list {
  margin: 0;
  padding-left: 1.2rem;
}

.bullet-list li {
  margin-bottom: 0.7rem;
  line-height: 1.6;
}

.skill-icons {
  margin: 1.7rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 0.9rem;
}

.skill-icons li {
  text-align: center;
  color: var(--sub);
  padding: 0.55rem 0.3rem;
  border-radius: 14px;
  background: linear-gradient(180deg, var(--surface), var(--button-soft));
  transition: transform 0.22s ease, color 0.22s ease;
}

.skill-icons i {
  display: block;
  font-size: 3rem;
  margin-bottom: 0.25rem;
  transition: color 0.22s ease;
}

.skill-icons li:hover {
  transform: translateY(-5px) scale(1.1);
  color: #645beb;
}

.skill-icons li:hover i {
  color: #645beb;
}

.skill-icons span {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.proficiency {
  margin-top: 1.7rem;
  display: grid;
  gap: 1rem;
}

.proficiency p {
  margin: 0 0 0.35rem;
}

.meter {
  height: 14px;
  background: var(--progress-bg);
  border-radius: 999px;
  overflow: hidden;
}

.meter > span {
  display: block;
  height: 100%;
  background: var(--progress-fill);
  border-radius: 999px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.timeline-list {
  margin-top: 1.8rem;
  display: grid;
  gap: 1rem;
}

.timeline-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 1rem;
  align-items: start;
  padding: 1.15rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: var(--shadow-card);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.timeline-card:hover {
  transform: translateY(-3px);
  border-color: rgba(140, 67, 206, 0.45);
  box-shadow: 0px 22px 36px -20px var(--shadow-strong);
}

.timeline-card img {
  width: 92px;
  height: 92px;
  object-fit: contain;
  border-radius: 14px;
  padding: 8px;
  background: #ffffff;
  box-shadow: 0 10px 24px -12px var(--shadow-strong);
}

.line-strong {
  font-weight: 700;
}

.line-faint {
  color: var(--sub);
}

.card-grid {
  margin-top: 1.8rem;
  display: grid;
  gap: 1.2rem;
}

.three-up {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.two-up {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.exp-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.exp-card:hover,
.project-card:hover,
.achievement-card:hover,
.blog-card:hover,
.talk-card:hover {
  transform: translateY(-4px);
  box-shadow: 0px 22px 36px -20px var(--shadow-strong);
}

.exp-top {
  background: linear-gradient(135deg, rgba(16, 20, 32, 0.92), rgba(85, 25, 139, 0.78));
  color: #ffffff;
  text-align: center;
  padding: 1.1rem 1rem 1.2rem;
}

.exp-top h3 {
  margin: 0;
  font-size: 1.35rem;
  line-height: 1.25;
}

.exp-top img {
  width: 116px;
  height: 116px;
  border-radius: 16px;
  object-fit: contain;
  padding: 8px;
  box-shadow: 0 8px 18px -6px var(--shadow-strong);
  margin-top: 1rem;
  background: #ffffff;
}

.exp-body {
  padding: 1.15rem 1.2rem 1.3rem;
  text-align: left;
}

.exp-body h4 {
  margin: 0 0 0.3rem;
  font-size: 1.08rem;
  line-height: 1.35;
}

.exp-body > p {
  margin: 0 0 0.75rem;
  line-height: 1.6;
}

.exp-body > .line-faint {
  margin-bottom: 0.55rem;
}

.exp-body ul {
  margin: 0.15rem 0 0;
  padding-left: 1.15rem;
}

.exp-body li {
  margin-bottom: 0.42rem;
  line-height: 1.55;
}

.cert-no {
  margin-top: 0;
  margin-bottom: 0.75rem;
  letter-spacing: 0.02em;
}

.project-card,
.achievement-card,
.blog-card,
.talk-card {
  border-radius: var(--radius-card);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-card);
}

.project-card,
.achievement-card,
.talk-card {
  padding: 1.2rem;
}

.project-card img,
.achievement-card img {
  max-width: 180px;
  max-height: 100px;
  width: auto;
  height: auto;
}

.tag-row {
  margin-top: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--button);
  color: #ffffff;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tag-link:hover {
  background: var(--button-hover);
  color: #ffffff;
}

.blog-card {
  color: var(--card-sub);
  padding: 1.4rem;
  position: relative;
  overflow: hidden;
  transition: color 0.3s ease;
  min-height: 200px;
}

.blog-card::before {
  content: "";
  position: absolute;
  right: -20px;
  top: -20px;
  width: 40px;
  height: 40px;
  border-radius: 100%;
  background: var(--button);
  transition: transform 0.36s ease;
  transform: scale(1);
  z-index: 0;
}

.blog-card h3,
.blog-card p {
  position: relative;
  z-index: 1;
}

.blog-card:hover::before {
  transform: scale(35);
}

.blog-card:hover h3,
.blog-card:hover p {
  color: #ffffff;
}

.talk-card {
  background: #ffffff url("assets/images/talksCardBack.svg") center/cover no-repeat;
  min-height: 270px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  isolation: isolate;
}

.talk-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 10px;
  background: linear-gradient(rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.32));
  z-index: -1;
}

.talk-card h3 {
  color: #ffffff;
  max-width: 28ch;
}

.talk-card p {
  color: #c8ced8;
}

.podcast-wrap iframe {
  width: 100%;
  border: 0;
  border-radius: 8px;
  min-height: 192px;
}

.contact-split .card {
  min-height: 260px;
}

.site-footer {
  margin-top: var(--section-gap);
  padding: 1rem 0 2rem;
  color: var(--sub);
  text-align: center;
}

.to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--button);
  color: #ffffff;
  box-shadow: 0 10px 20px -10px rgba(85, 25, 139, 0.72);
}

.to-top:hover {
  color: #ffffff;
  background: var(--button-hover);
}

/* ── Scroll reveal ────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.56s ease, transform 0.56s 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;
    scroll-behavior: auto !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .typing-cursor {
    animation: none;
  }
}

@media (max-width: 1380px) {
  .hero-typed {
    font-size: 1.08rem;
  }

  .hero-subtitle {
    font-size: 1.1rem;
    line-height: 1.58;
  }

  .photo-stage {
    width: min(400px, 100%);
  }

  .section-head h2 { font-size: 2.4rem; }
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    margin-top: 2rem;
    gap: 1.6rem;
  }

  .hero-art {
    order: -1;
  }

  .hero-copy {
    max-width: 100%;
  }

  .photo-stage {
    width: min(360px, 96vw);
    padding: 18px;
  }

  .split {
    grid-template-columns: 1fr;
  }

  .timeline-card {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .timeline-card img {
    margin: 0;
  }

  .two-up {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .theme-switch {
    margin-left: 0;
  }

  .menu-icon {
    display: inline-flex;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    border: 1px solid var(--line);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    background: var(--surface);
  }

  .menu-icon span {
    width: 22px;
    height: 2px;
    background: var(--text);
    display: block;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  .site-nav {
    position: absolute;
    top: 78px;
    left: 0;
    right: 0;
    padding: 10px 4vw 14px;
    border-bottom: 1px solid var(--line);
    background: var(--mobile-nav-bg);
    display: none;
    flex-direction: column;
  }

  .site-nav a {
    border-radius: 8px;
    padding: 12px 14px;
  }

  .menu-toggle:checked ~ .site-nav {
    display: flex;
  }

  .menu-toggle:checked + .menu-icon span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .menu-toggle:checked + .menu-icon span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle:checked + .menu-icon span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
}

@media (max-width: 768px) {
  body {
    font-size: 16px;
    line-height: 1.5;
  }

  .hero {
    margin-top: 1.25rem;
  }

  .hero-kicker {
    justify-content: center;
    font-size: 0.72rem;
  }

  .hero h1 {
    font-size: 1.8rem;
    text-align: center;
  }

  .hero-typed {
    justify-content: center;
    font-size: 1rem;
    min-height: 1.8rem;
  }

  .subtitle {
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
  }

  .hero-subtitle {
    font-size: 16px;
    line-height: 1.6;
    text-align: center;
    max-width: 100%;
  }

  .social-grid {
    justify-content: center;
  }

  .hero-copy,
  .section-head {
    text-align: center;
  }

  .card,
  .timeline-card,
  .project-card,
  .achievement-card,
  .exp-body,
  .contact-split .card {
    text-align: left;
  }

  .section-head h2 {
    font-size: 1.95rem;
    text-align: center;
  }

  .hero-cta {
    justify-content: center;
  }

  .photo-badge {
    position: static;
    margin-top: 10px;
    display: inline-flex;
    justify-content: center;
  }

  .photo-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .timeline-card img {
    margin: 0 auto;
  }

  .exp-body {
    padding: 1rem 1rem 1.2rem;
  }

  .to-top {
    width: 40px;
    height: 40px;
    right: 14px;
    bottom: 14px;
  }
}
