:root {
  --bg: #e9dfcf;
  --surface: #fffaf2;
  --surface-soft: #f8f1e7;
  --text: #17231e;
  --muted: #69736e;
  --line: rgba(23, 35, 30, 0.12);
  --accent: #a24a2d;
  --accent-strong: #d46d42;
  --accent-soft: #f4dfd1;
  --radius: 28px;
  --body-font: "Segoe UI Variable Text", "Segoe UI", "Aptos", sans-serif;
  --display-font: Cambria, "Times New Roman", serif;
  --mono-font: "SF Mono", "Cascadia Mono", "Consolas", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--body-font);
  color: var(--text);
  background:
    radial-gradient(circle at 15% 6%, rgba(255, 250, 242, 0.92), transparent 34rem),
    radial-gradient(circle at 92% 14%, rgba(162, 74, 45, 0.1), transparent 24rem),
    var(--bg);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.2;
  background-image:
    linear-gradient(rgba(23, 35, 30, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 35, 30, 0.04) 1px, transparent 1px);
  background-size: 44px 44px;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 20;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  border-radius: 8px;
}

.skip-link:focus {
  top: 12px;
}

.page {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 42px;
  position: relative;
}

.language-switch {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 50;
  display: flex;
  gap: 6px;
  padding: 5px;
  border: 1px solid rgba(23, 35, 30, 0.1);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.86);
  backdrop-filter: blur(10px);
}

.lang-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 1rem;
  cursor: pointer;
}

.lang-button.active {
  background: var(--text);
}

.flag {
  display: block;
  width: 22px;
  height: 15px;
  overflow: hidden;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.12);
}

.flag-us {
  position: relative;
  background: repeating-linear-gradient(
    to bottom,
    #b22234 0,
    #b22234 1.15px,
    #ffffff 1.15px,
    #ffffff 2.3px
  );
}

.flag-us::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 9px;
  height: 8px;
  background: #3c3b6e;
}

.flag-vn {
  position: relative;
  background: #da251d;
}

.flag-vn::before {
  content: "★";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #ffdf00;
  font-size: 9px;
  line-height: 1;
}

.top-layout,
.facts,
.grid,
.section {
  margin-bottom: 18px;
  animation: rise 560ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.top-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.95fr);
  gap: 18px;
  align-items: start;
}

.hero {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  box-shadow: 0 20px 70px rgba(64, 48, 34, 0.08);
}

.hero::after {
  content: "";
  position: absolute;
  right: -42px;
  bottom: -86px;
  width: 190px;
  height: 190px;
  border-radius: 42% 58% 48% 52%;
  background: rgba(23, 35, 30, 0.08);
  transform: rotate(-18deg);
}

.avatar {
  width: 128px;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 18px;
  background: var(--surface-soft);
  border: 1px solid rgba(23, 35, 30, 0.1);
  position: relative;
  z-index: 1;
}

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

.hero-copy {
  position: relative;
  z-index: 1;
}

.eyebrow {
  display: block;
  font-size: 0.73rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 800;
}

h1,
h2,
h3,
strong {
  margin: 0;
}

h1 {
  margin-top: 10px;
  font-family: var(--display-font);
  font-size: clamp(2.85rem, 4.2vw, 3.75rem);
  font-weight: 800;
  line-height: 0.96;
  overflow-wrap: normal;
  word-break: keep-all;
  letter-spacing: -0.025em;
  white-space: nowrap;
  font-kerning: normal;
  text-rendering: geometricPrecision;
}

h2 {
  font-family: var(--display-font);
  font-size: 2.1rem;
  letter-spacing: -0.035em;
  line-height: 1.16;
}

h3 {
  font-size: 1rem;
  line-height: 1.3;
}

p,
li,
a,
span {
  line-height: 1.62;
}

.role,
.muted,
.meta span,
.skill-group p {
  color: var(--muted);
}

.role {
  margin: 12px 0 10px;
  font-size: 1.04rem;
}

.summary-title {
  margin: 16px 0 8px;
  font-family: var(--body-font);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.summary-list,
.bullet-list,
.plain-list {
  margin: 0;
  padding-left: 18px;
}

.summary-list {
  max-width: 580px;
  font-size: 0.96rem;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-weight: 800;
  text-decoration: none;
  transition: transform 180ms ease, background-color 180ms ease;
}

.button.primary {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: #fffaf2;
}

.button.secondary {
  background: rgba(255, 255, 255, 0.58);
  color: var(--text);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

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

.fact,
.card,
.section {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 20px 70px rgba(64, 48, 34, 0.06);
}

.fact {
  padding: 14px 20px;
}

.fact span {
  display: block;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  font-weight: 700;
  font-family: var(--mono-font);
}

.fact strong {
  display: block;
  margin-top: 4px;
  font-size: 1.04rem;
}

.grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  gap: 16px;
}

.card,
.section {
  padding: 26px;
}

.card h2,
.section h2 {
  margin-bottom: 16px;
}

.contact-card {
  padding: 28px 24px;
}

.contact-card h2,
.card h2,
.section-head h2 {
  font-family: var(--mono-font);
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.plain-list {
  list-style: none;
  padding: 0;
}

.plain-list li {
  display: grid;
  gap: 3px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.plain-list li:last-child {
  border-bottom: 0;
}

.plain-list span {
  font-size: 0.72rem;
  color: var(--muted);
  font-family: var(--mono-font);
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.plain-list a,
.text-link {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
}

.plain-list strong {
  font-size: 0.95rem;
}

.skills-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 18px;
}

.skill-group {
  min-width: 0;
}

.skill-group h3 {
  margin-bottom: 5px;
  font-size: 0.92rem;
}

.skill-group p {
  margin: 0;
  font-size: 0.92rem;
}

.section-head {
  margin-bottom: 16px;
}

.section {
  overflow: hidden;
}

.section h3,
.card h3 {
  font-weight: 800;
}

.row {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
}

.meta p {
  margin: 0 0 7px;
  font-weight: 700;
}

.bullet-list.compact {
  margin-top: 10px;
}

.text-link {
  border-bottom: 1px solid transparent;
  font-weight: 800;
}

.text-link:hover,
.text-link:focus-visible {
  border-bottom-color: var(--text);
}

.project-slider {
  margin-top: 14px;
  max-width: 640px;
}

.slider-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.slider-frame {
  position: relative;
  min-height: 240px;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
}

.slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  transition: opacity 220ms ease;
}

.slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: var(--surface-soft);
  cursor: zoom-in;
}

#vkutk-slide-1:checked ~ .slider-frame .slide-1,
#vkutk-slide-2:checked ~ .slider-frame .slide-2,
#vkutk-slide-3:checked ~ .slider-frame .slide-3,
#vkutk-slide-4:checked ~ .slider-frame .slide-4,
#vkutk-slide-5:checked ~ .slider-frame .slide-5,
#vkutk-slide-6:checked ~ .slider-frame .slide-6,
#guidetar-slide-1:checked ~ .slider-frame .slide-1,
#guidetar-slide-2:checked ~ .slider-frame .slide-2,
#guidetar-slide-3:checked ~ .slider-frame .slide-3,
#guidetar-slide-4:checked ~ .slider-frame .slide-4,
#guidetar-slide-5:checked ~ .slider-frame .slide-5 {
  opacity: 1;
}

.slider-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.slider-nav label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 250, 242, 0.72);
  color: var(--muted);
  font-size: 0.8rem;
  font-family: var(--mono-font);
  cursor: pointer;
}

#vkutk-slide-1:checked ~ .slider-nav label[for="vkutk-slide-1"],
#vkutk-slide-2:checked ~ .slider-nav label[for="vkutk-slide-2"],
#vkutk-slide-3:checked ~ .slider-nav label[for="vkutk-slide-3"],
#vkutk-slide-4:checked ~ .slider-nav label[for="vkutk-slide-4"],
#vkutk-slide-5:checked ~ .slider-nav label[for="vkutk-slide-5"],
#vkutk-slide-6:checked ~ .slider-nav label[for="vkutk-slide-6"],
#guidetar-slide-1:checked ~ .slider-nav label[for="guidetar-slide-1"],
#guidetar-slide-2:checked ~ .slider-nav label[for="guidetar-slide-2"],
#guidetar-slide-3:checked ~ .slider-nav label[for="guidetar-slide-3"],
#guidetar-slide-4:checked ~ .slider-nav label[for="guidetar-slide-4"],
#guidetar-slide-5:checked ~ .slider-nav label[for="guidetar-slide-5"] {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: rgba(162, 74, 45, 0.2);
}

.guidetar-slider .slider-frame {
  min-height: 270px;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: rgba(23, 35, 30, 0.82);
  backdrop-filter: blur(12px);
}

.image-lightbox.open {
  display: flex;
}

.lightbox-panel {
  position: relative;
  width: min(1120px, 96vw);
  max-height: 92vh;
}

.lightbox-panel img {
  display: block;
  width: 100%;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.32);
}

.lightbox-close {
  position: absolute;
  right: 12px;
  top: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  min-height: 38px;
  border: 1px solid rgba(255, 250, 242, 0.42);
  border-radius: 999px;
  background: rgba(23, 35, 30, 0.72);
  color: #fffaf2;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.lightbox-control {
  position: absolute;
  top: 50%;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 52px;
  border: 1px solid rgba(255, 250, 242, 0.34);
  border-radius: 999px;
  background: rgba(23, 35, 30, 0.66);
  color: #fffaf2;
  font-size: 2.35rem;
  line-height: 1;
  cursor: pointer;
  transform: translateY(-50%);
}

.lightbox-prev {
  left: 12px;
}

.lightbox-next {
  right: 12px;
}

.lightbox-close:hover,
.lightbox-control:hover,
.lightbox-close:focus-visible,
.lightbox-control:focus-visible {
  background: rgba(23, 35, 30, 0.86);
}

.lightbox-caption {
  margin: 10px 0 0;
  color: #fffaf2;
  font-size: 0.9rem;
  text-align: center;
}

.project-compact {
  max-width: 760px;
  margin-top: 0;
  font-size: 0.94rem;
}

.project-url {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--text);
  font-weight: 800;
  text-decoration: none;
}

.secondary-url {
  margin-left: 12px;
  color: var(--accent);
}

.project-points {
  margin-top: 0;
  gap: 4px;
}

.achievement {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 10px 0 0;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--text);
}

.project-timeline {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.section-head + .project-timeline {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.project-date {
  position: relative;
  padding-left: 20px;
  border-left: 2px solid rgba(23, 35, 30, 0.42);
}

.project-date::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.project-date span {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
  font-weight: 700;
}

.project-date h3 {
  font-weight: 800;
  font-size: 1rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .top-layout,
  .grid,
  .facts,
  .row {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 0;
  }
}

@media (max-width: 720px) {
  .page {
    width: min(100% - 16px, 1080px);
    padding: 16px 0 24px;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 26px;
  }

  .avatar {
    width: 140px;
  }

  h1 {
    font-size: clamp(2.35rem, 12vw, 2.95rem);
    letter-spacing: -0.025em;
  }

  .project-timeline {
    grid-template-columns: 1fr;
  }

  .skills-list {
    grid-template-columns: 1fr;
  }

  .slider-frame {
    min-height: 220px;
  }

  .card,
  .section {
    padding: 22px;
  }
}
