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

:root {
  --bg: #0d1424;
  --panel: rgba(255, 255, 255, 0.08);
  --line: rgba(216, 189, 127, 0.28);
  --gold: #d8bd7f;
  --gold-light: #fff0b5;
  --blue: #8ec5ff;
  --text: #f8f1dc;
  --muted: #dfd7c7;
  --muted-2: #bdb6a8;
}

html {
  scroll-behavior: smooth;
  /* scroll-snap có thể gây giật khi trang nhiều section/ảnh nền */
  scroll-snap-type: none;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: "Be Vietnam Pro", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -5;
  background:
    linear-gradient(rgba(8, 14, 28, 0.66), rgba(8, 14, 28, 0.78)),
    radial-gradient(
      circle at top left,
      rgba(54, 94, 136, 0.45) 0%,
      transparent 32%
    ),
    radial-gradient(
      circle at bottom right,
      rgba(111, 91, 153, 0.38) 0%,
      transparent 30%
    ),
    var(--page-bg, none), linear-gradient(135deg, #0d1424, #101b31 50%, #182238);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  /* fixed background khá tốn CPU/GPU khi cuộn, nhất là trên Linux/browser yếu */
  background-attachment: scroll;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -4;
  opacity: 0.18;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, black, transparent 92%);
}

a {
  color: inherit;
  text-decoration: none;
}

.particles span {
  position: fixed;
  z-index: -1;
  width: var(--size);
  height: var(--size);
  left: var(--left);
  top: var(--top);
  border-radius: 999px;
  background: var(--gold-light);
  box-shadow: 0 0 18px rgba(245, 217, 140, 0.9);
  animation: float var(--duration) ease-in-out infinite;
  animation-delay: var(--delay);
  opacity: 0.45;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(-20px);
    opacity: 0.12;
  }
  50% {
    transform: translateY(20px);
    opacity: 0.85;
  }
}

.topbar {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 50;
  width: min(1120px, calc(100% - 32px));
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 14px 12px 18px;
  border: 1px solid rgba(216, 189, 127, 0.28);
  border-radius: 999px;
  background: rgba(13, 20, 36, 0.56);
  /* blur lớn tốn GPU, giảm xuống để mượt hơn */
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(216, 189, 127, 0.42);
  border-radius: 50%;
  background: linear-gradient(
    135deg,
    rgba(142, 197, 255, 0.28),
    rgba(216, 189, 127, 0.18)
  );
  color: var(--gold-light);
  box-shadow: 0 0 24px rgba(216, 189, 127, 0.18);
}

.brand-text {
  font-family: "HYWenHei-85W", serif;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}

.nav a {
  padding: 11px 14px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 14px;
  transition: 0.25s ease;
}

.nav a:hover,
.nav a.active {
  color: var(--gold-light);
  background: rgba(216, 189, 127, 0.14);
}

.section {
  position: relative;
  min-height: 100vh;
  scroll-snap-align: start;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  align-items: center;
  padding: 120px 24px 80px;
}

.section::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -3;
  background: var(--bg-image) center center / cover no-repeat;
  opacity: 0.32;
}

.section::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(
      90deg,
      rgba(9, 14, 27, 0.82),
      rgba(9, 14, 27, 0.54),
      rgba(9, 14, 27, 0.84)
    ),
    radial-gradient(
      circle at top left,
      rgba(142, 197, 255, 0.16),
      transparent 34%
    ),
    radial-gradient(
      circle at bottom right,
      rgba(216, 189, 127, 0.14),
      transparent 36%
    );
}

.section-frame {
  position: absolute;
  inset: 88px 24px 32px;
  z-index: -1;
  border: 1px solid rgba(216, 189, 127, 0.18);
  border-radius: 36px;
  pointer-events: none;
  box-shadow: inset 0 0 60px rgba(216, 189, 127, 0.045);
}

.container {
  width: min(1120px, 100%);
  margin: 0 auto;
}

/*
      BACKGROUND CONFIG
      Chỉ cần đổi đường dẫn ảnh trong các biến dưới đây.
      Nếu ảnh chưa tồn tại, fallback gradient vẫn giữ giao diện đẹp.
    */
body {
  --page-bg: url("images/bg-page.jpg");
  --profile-bg: url("images/bg-profile.jpg");
  --talents-bg: url("images/bg-talents.jpg");
  --commissions-bg: url("images/bg-commissions.jpg");
  --inventory-bg: url("images/bg-inventory.jpg");
  --socials-bg: url("images/bg-socials.jpg");
  --about-bg: url("images/bg-about.jpg");
  --contact-bg: url("images/bg-contact.jpg");
  --profile-card-bg: url("images/card-profile.jpg");
  --project-scam-bg: url("images/project-scam.jpg");
  --project-minecraft-bg: url("images/project-minecraft.jpg");
  --project-tools-bg: url("images/project-tools.jpg");
}

#profile {
  --bg-image:
    var(--profile-bg),
    radial-gradient(
      circle at 72% 35%,
      rgba(142, 197, 255, 0.24),
      transparent 34%
    ),
    linear-gradient(135deg, #162b46, #141c35 55%, #2c2748);
}

#talents {
  --bg-image:
    var(--talents-bg),
    radial-gradient(
      circle at 25% 30%,
      rgba(216, 189, 127, 0.22),
      transparent 34%
    ),
    linear-gradient(135deg, #1b2138, #18304b 55%, #20203a);
}

#commissions {
  --bg-image:
    var(--commissions-bg),
    radial-gradient(
      circle at 70% 32%,
      rgba(142, 197, 255, 0.2),
      transparent 36%
    ),
    linear-gradient(135deg, #162238, #27334b 55%, #171d32);
}

#inventory {
  --bg-image:
    var(--inventory-bg),
    radial-gradient(
      circle at 50% 35%,
      rgba(216, 189, 127, 0.2),
      transparent 38%
    ),
    linear-gradient(135deg, #151b2f, #293049 55%, #161d34);
}

#contact {
  --bg-image:
    var(--contact-bg),
    radial-gradient(
      circle at 35% 35%,
      rgba(142, 197, 255, 0.18),
      transparent 34%
    ),
    linear-gradient(135deg, #111a2d, #1d2942 55%, #2d2745);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 44px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(216, 189, 127, 0.34);
  background: rgba(216, 189, 127, 0.12);
  color: var(--gold-light);
  font-size: 14px;
}

.badge::before {
  content: "✦";
  color: var(--gold-light);
  filter: drop-shadow(0 0 10px rgba(245, 217, 140, 0.7));
}

.hero-title {
  max-width: 720px;
  font-family: "HYWenHei-85W", serif;
  font-size: clamp(44px, 7vw, 86px);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.hero-title span {
  color: var(--gold-light);
  text-shadow: 0 0 26px rgba(216, 189, 127, 0.2);
}

.hero-desc {
  max-width: 640px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.9;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border-radius: 18px;
  padding: 14px 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
  transition: 0.25s ease;
}

.btn.primary {
  border-color: rgba(216, 189, 127, 0.45);
  background: rgba(216, 189, 127, 0.15);
  color: var(--gold-light);
  box-shadow: 0 0 24px rgba(216, 189, 127, 0.08);
}

.btn:hover {
  transform: translateY(-3px);
  border-color: rgba(216, 189, 127, 0.62);
  background: rgba(216, 189, 127, 0.18);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.profile-card {
  position: relative;
  overflow: hidden;
  min-height: 480px;
  border: 1px solid rgba(216, 189, 127, 0.24);
  border-radius: 36px;
  background:
    linear-gradient(rgba(16, 24, 42, 0.72), rgba(16, 24, 42, 0.72)),
    var(--profile-card-bg, none) center center / cover no-repeat,
    radial-gradient(
      circle at 50% 18%,
      rgba(142, 197, 255, 0.28),
      transparent 30%
    ),
    linear-gradient(135deg, #1b2d46, #181f37 60%, #39305b);
  backdrop-filter: blur(10px);
  box-shadow: 0 14px 42px rgba(0, 0, 0, 0.22);
}

.profile-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      circle at 50% 20%,
      rgba(142, 197, 255, 0.26),
      transparent 30%
    ),
    linear-gradient(to top, rgba(13, 20, 36, 0.92), transparent 55%);
}

.profile-inner {
  position: absolute;
  inset: auto 24px 24px;
  display: grid;
  gap: 14px;
}

.avatar {
  width: 120px;
  height: 120px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 2px solid var(--gold);
  background: linear-gradient(135deg, #9ccfff, #564d86);
  color: var(--gold-light);
  font-size: 50px;
  box-shadow: 0 0 36px rgba(156, 207, 255, 0.32);
}

.profile-name {
  font-family: "HYWenHei-85W", serif;
  font-size: 32px;
  line-height: 1;
}

.profile-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.meta-item {
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
}

.meta-item small {
  display: block;
  color: var(--muted-2);
  font-size: 12px;
}

.meta-item strong {
  display: block;
  margin-top: 4px;
  color: var(--gold-light);
  font-size: 14px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 30px;
}

.section-kicker {
  color: var(--gold);
  font-size: 13px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
}

.section-title {
  margin-top: 10px;
  font-family: "HYWenHei-85W", serif;
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1;
}

.section-desc {
  max-width: 420px;
  color: var(--muted);
  line-height: 1.75;
  text-align: right;
}

.glass-panel {
  border: 1px solid var(--line);
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.2);
}

.talent-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.talent-card,
.project-card,
.tool-card,
.stat-card {
  border: 1px solid rgba(216, 189, 127, 0.22);
  background: rgba(255, 255, 255, 0.075);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14);
  transition: 0.25s ease;
}

.talent-card {
  padding: 22px;
  border-radius: 28px;
}

.talent-card:hover,
.project-card:hover,
.tool-card:hover,
.stat-card:hover {
  transform: translateY(-6px);
  border-color: rgba(216, 189, 127, 0.68);
  box-shadow:
    0 0 18px rgba(216, 189, 127, 0.1),
    0 12px 32px rgba(0, 0, 0, 0.18);
}

.talent-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.talent-name {
  display: flex;
  align-items: center;
  gap: 12px;
}

.talent-icon {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: rgba(142, 197, 255, 0.15);
  color: var(--blue);
  font-size: 22px;
}

.talent-card h3 {
  font-size: 17px;
}

.talent-card p {
  margin-top: 4px;
  color: var(--gold);
  font-size: 13px;
}

.bar {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.11);
}

.bar span {
  display: block;
  width: var(--level);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), #f5d98c);
  box-shadow: 0 0 20px rgba(245, 217, 140, 0.24);
}

.stars {
  margin-top: 14px;
  color: #f5d98c;
  letter-spacing: 2px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.project-card {
  overflow: hidden;
  border-radius: 30px;
  background: rgba(17, 27, 46, 0.72);
}

.project-cover {
  height: 180px;
  background:
    linear-gradient(rgba(13, 20, 36, 0.18), rgba(13, 20, 36, 0.62)),
    var(--cover) center center / cover no-repeat,
    radial-gradient(
      circle at 30% 30%,
      rgba(142, 197, 255, 0.55),
      transparent 35%
    ),
    linear-gradient(135deg, rgba(216, 189, 127, 0.28), rgba(88, 77, 134, 0.35));
}

.project-body {
  padding: 24px;
}

.project-type {
  color: var(--gold);
  font-size: 13px;
}

.project-body h3 {
  margin-top: 8px;
  font-size: 22px;
}

.project-body p {
  min-height: 92px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tags span {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  background: rgba(255, 255, 255, 0.065);
  font-size: 12px;
}

.reward {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.11);
  color: var(--blue);
  font-size: 14px;
}

.inventory-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 22px;
  align-items: stretch;
}

.stat-stack {
  display: grid;
  gap: 16px;
}

.stat-card {
  padding: 22px;
  border-radius: 26px;
}

.stat-card small {
  color: var(--muted-2);
}

.stat-card strong {
  display: block;
  margin-top: 5px;
  color: var(--gold-light);
  font-size: 36px;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.tool-card {
  padding: 22px;
  border-radius: 26px;
  text-align: center;
}

.tool-icon {
  width: 58px;
  height: 58px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: rgba(216, 189, 127, 0.16);
  color: var(--gold-light);
  font-size: 22px;
}

.contact-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
  padding: 36px;
}

.contact-panel h2 {
  font-family: "HYWenHei-85W", serif;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1;
}

.contact-panel p {
  margin-top: 16px;
  max-width: 620px;
  color: var(--muted);
  line-height: 1.8;
}

.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 34px;
  z-index: 4;
  transform: translateX(-50%);
  color: var(--muted-2);
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  animation: bounce 1.8s ease-in-out infinite;
}

@keyframes bounce {
  0%,
  100% {
    transform: translate(-50%, 0);
    opacity: 0.45;
  }
  50% {
    transform: translate(-50%, 8px);
    opacity: 1;
  }
}

@media (max-width: 1020px) {
  .hero-grid,
  .inventory-layout,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .talent-grid,
  .project-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .section-desc {
    text-align: left;
  }

  .profile-card {
    min-height: 420px;
  }
}

@media (max-width: 760px) {
  html {
    scroll-snap-type: none;
  }

  .topbar {
    top: 12px;
    border-radius: 24px;
    align-items: flex-start;
    flex-direction: column;
  }

  .nav {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .nav a {
    white-space: nowrap;
  }

  .section {
    min-height: auto;
    padding: 150px 14px 60px;
  }

  .section-frame {
    inset: 112px 12px 24px;
    border-radius: 28px;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .talent-grid,
  .project-grid,
  .tool-grid {
    grid-template-columns: 1fr;
  }

  .profile-meta {
    grid-template-columns: 1fr;
  }

  .hero-title {
    font-size: 44px;
  }

  .scroll-hint {
    display: none;
  }
}

/* Tối ưu cho máy yếu hoặc người dùng bật giảm chuyển động */
@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;
  }

  .particles {
    display: none;
  }
}

/* Chế độ tiết kiệm hiệu năng: thêm class low-power vào body nếu cần */
body.low-power .particles {
  display: none;
}

body.low-power .section::before {
  opacity: 0.22;
}

body.low-power .topbar,
body.low-power .glass-panel,
body.low-power .talent-card,
body.low-power .project-card,
body.low-power .tool-card,
body.low-power .stat-card,
body.low-power .profile-card {
  backdrop-filter: none;
}

body.low-power .talent-card:hover,
body.low-power .project-card:hover,
body.low-power .tool-card:hover,
body.low-power .stat-card:hover {
  transform: none;
}

/* font */
@font-face {
font-family: 'HYWenHei-85W';
font-style: normal;
font-weight: normal;
src: local('HYWenHei 85W'), url('zhcn.woff') format('woff');
}

/* social */
#socials {
  --bg-image:
    var(--socials-bg, var(--inventory-bg)),
    radial-gradient(circle at 70% 28%, rgba(216,189,127,.20), transparent 35%),
    linear-gradient(135deg, #171d32, #22304b 55%, #2a2544);
}

.social-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  align-items: stretch;
}

.social-card,
.fact-card {
  border: 1px solid rgba(216, 189, 127, .22);
  border-radius: 28px;
  background: rgba(255, 255, 255, .075);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 28px rgba(0,0,0,.14);
  transition: .25s ease;
}

.social-card:hover,
.fact-card:hover {
  transform: translateY(-5px);
  border-color: rgba(216, 189, 127, .62);
  box-shadow:
    0 0 22px rgba(216, 189, 127, .12),
    0 14px 36px rgba(0,0,0,.20);
}

.social-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
}

.social-icon {
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 18px;
  border: 1px solid rgba(216, 189, 127, .24);
  background: rgba(216, 189, 127, .14);
  color: var(--gold-light);
  font-size: 22px;
}

.social-card strong,
.fact-card strong {
  display: block;
  font-size: 17px;
}

.social-card span,
.fact-card span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.fact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.fact-card {
  padding: 20px;
}

.fact-label {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(142, 197, 255, .12);
  color: var(--blue);
  font-size: 12px;
}

@media (max-width: 1020px) {
  .social-layout {
    grid-template-columns: 1fr;
  }

  .fact-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 760px) {
  .social-layout,
  .fact-grid {
    grid-template-columns: 1fr;
  }
}

/* copy discord username */
.copy-discord {
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

/* avatar */
.avatar {
  width: 120px;
  height: 120px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 2px solid var(--gold);
  background: linear-gradient(135deg, #9ccfff, #564d86);
  box-shadow: 0 0 36px rgba(156, 207, 255, .32);
  overflow: hidden;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* =========================
   RESPONSIVE MOBILE FIX
   ========================= */

@media (max-width: 900px) {
  body {
    overflow-x: hidden;
  }

  .topbar {
    top: 10px;
    width: calc(100% - 20px);
    max-height: none;
    padding: 12px;
    border-radius: 22px;
    flex-direction: column;
    align-items: flex-start;
  }

  .brand {
    width: 100%;
  }

  .nav {
    width: 100%;
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }

  .nav a {
    flex: 0 0 auto;
    white-space: nowrap;
    padding: 9px 12px;
    font-size: 13px;
  }

  .section {
    min-height: auto;
    padding: 145px 14px 56px;
  }

  .section-frame {
    inset: 112px 10px 20px;
    border-radius: 26px;
  }

  .container {
    width: 100%;
  }

  .hero-grid,
  .inventory-layout,
  .social-layout,
  .contact-panel {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .hero-title {
    font-size: 42px;
    line-height: 1.05;
  }

  .hero-desc {
    font-size: 15px;
    line-height: 1.75;
  }

  .hero-actions {
    gap: 10px;
  }

  .btn {
    width: 100%;
    justify-content: center;
    padding: 13px 16px;
  }

  .profile-card {
    min-height: 390px;
    border-radius: 28px;
  }

  .profile-inner {
    inset: auto 18px 18px;
  }

  .avatar {
    width: 96px;
    height: 96px;
  }

  .profile-name {
    font-size: 26px;
  }

  .profile-meta {
    grid-template-columns: 1fr;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 22px;
  }

  .section-kicker {
    font-size: 11px;
    letter-spacing: .25em;
  }

  .section-title {
    font-size: 36px;
  }

  .section-desc {
    max-width: 100%;
    text-align: left;
    font-size: 14px;
  }

  .talent-grid,
  .project-grid,
  .tool-grid,
  .fact-grid {
    grid-template-columns: 1fr;
  }

  .talent-card,
  .project-card,
  .tool-card,
  .stat-card,
  .fact-card,
  .social-card {
    border-radius: 22px;
  }

  .project-cover {
    height: 150px;
  }

  .project-body p {
    min-height: auto;
  }

  .tool-grid {
    gap: 12px;
  }

  .tool-card {
    padding: 18px;
  }

  .contact-panel {
    padding: 24px;
  }

  .contact-panel h2 {
    font-size: 34px;
  }
}

@media (max-width: 900px) {
  .profile-card {
    min-height: auto;
    padding: 24px;
  }

  .profile-inner {
    position: relative;
    inset: auto;
  }

  .avatar {
    width: 96px;
    height: 96px;
  }
}


/* music player */
.music-player {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 80;
  width: 340px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(216, 189, 127, .28);
  border-radius: 24px;
  background: rgba(13, 20, 36, .72);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, .24);
}

.music-toggle {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(216, 189, 127, .35);
  border-radius: 18px;
  background: rgba(216, 189, 127, .14);
  color: var(--gold-light);
  cursor: pointer;
  transition: .25s ease;
}

.music-toggle:hover {
  transform: translateY(-2px);
  background: rgba(216, 189, 127, .22);
  box-shadow: 0 0 22px rgba(216, 189, 127, .14);
}

.music-info {
  min-width: 0;
}

.music-info strong {
  display: block;
  color: var(--gold-light);
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-info span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.music-progress {
  height: 5px;
  margin-top: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
}

.music-progress-bar {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--gold-light));
  box-shadow: 0 0 12px rgba(245, 217, 140, .35);
}

.music-volume {
  width: 70px;
  accent-color: var(--gold);
  cursor: pointer;
}

@media (max-width: 760px) {
  .music-player {
    left: 12px;
    right: 12px;
    bottom: 12px;
    width: auto;
    grid-template-columns: auto 1fr;
  }

  .music-volume {
    grid-column: 1 / -1;
    width: 100%;
  }
}

/* toggle music player */
.music-player-toggle {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  width: 52px;
  height: 52px;
  display: none;
  place-items: center;
  border: 1px solid rgba(216, 189, 127, .35);
  border-radius: 18px;
  background: rgba(13, 20, 36, .76);
  color: var(--gold-light);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, .24);
  cursor: pointer;
  transition: .25s ease;
}

.music-player-toggle:hover {
  transform: translateY(-2px);
  background: rgba(216, 189, 127, .18);
}

.music-player-toggle.show {
  display: grid;
}

.music-player {
  transition:
    opacity .25s ease,
    transform .25s ease,
    visibility .25s ease;
}

.music-player.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(16px) scale(.96);
}

@media (max-width: 760px) {
  .music-player-toggle {
    right: 12px;
    bottom: 12px;
  }

  .music-player.hidden {
    transform: translateY(16px);
  }
}


/* muốn tìm hiểu */

#about-me {
  --bg-image:
    var(--about-bg, var(--profile-bg)),
    radial-gradient(circle at 25% 25%, rgba(216,189,127,.18), transparent 35%),
    linear-gradient(135deg, #151b2f, #24304a 55%, #2b2544);
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.story-card {
  position: relative;
  overflow: hidden;
  min-height: 260px;
  padding: 24px;
  border: 1px solid rgba(216, 189, 127, .22);
  border-radius: 28px;
  background: rgba(255, 255, 255, .075);
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .14);
  transition: .25s ease;
}

.story-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at top right, rgba(142, 197, 255, .13), transparent 36%),
    radial-gradient(circle at bottom left, rgba(216, 189, 127, .10), transparent 38%);
}

.story-card:hover {
  transform: translateY(-5px);
  border-color: rgba(216, 189, 127, .62);
  box-shadow:
    0 0 22px rgba(216, 189, 127, .12),
    0 14px 36px rgba(0, 0, 0, .20);
}

.story-number {
  display: inline-flex;
  margin-bottom: 14px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(216, 189, 127, .22);
  background: rgba(216, 189, 127, .12);
  color: var(--gold-light);
  font-size: 12px;
}

.story-card h3 {
  color: var(--text);
  font-size: 20px;
  line-height: 1.35;
}

.story-card p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

@media (max-width: 1020px) {
  .story-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 760px) {
  .story-grid {
    grid-template-columns: 1fr;
  }

  .story-card {
    min-height: auto;
    padding: 20px;
    border-radius: 22px;
  }
}