:root {
  color-scheme: light;
  --navy: #1A1A1A;
  --navy-2: #2A2A2A;
  --ink: #1A1A1A;
  --muted: #555555;
  --line: #E8E4DE;
  --paper: #FFFFFF;
  --white: #FFFFFF;
  --gold: #B8966E;
  --gold-2: #D4B896;
  --cyan: #B8966E;
  --mint: #D4B896;
  --shadow: 0 22px 50px rgba(184, 150, 110, 0.15);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Pretendard", "Noto Sans KR", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.72;
  letter-spacing: 0;
}

body.menu-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

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

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  transform: translateY(-160%);
  border-radius: var(--radius);
  background: var(--gold);
  color: var(--navy);
  padding: 10px 14px;
  font-weight: 800;
}

.skip-link:focus {
  transform: translateY(0);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(26, 26, 26, 0.9);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 132px;
  color: var(--white);
  font-weight: 900;
}

.brand-mark {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: var(--radius);
  background: var(--gold);
  color: var(--navy);
  font-size: 14px;
}

.brand-text {
  font-size: 18px;
}

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

.site-nav a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius);
  padding: 8px 12px;
  color: #F0EDE8;
  font-size: 15px;
  font-weight: 800;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: var(--gold);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  cursor: pointer;
}

.menu-button span:not(.sr-only) {
  display: block;
  width: 18px;
  height: 2px;
  margin: 3px auto;
  border-radius: 999px;
  background: var(--white);
}

.hero {
  position: relative;
  min-height: 650px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--navy);
  color: var(--white);
}

.hero::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(26, 26, 26, 0.96) 0%, rgba(26, 26, 26, 0.78) 48%, rgba(26, 26, 26, 0.34) 100%);
  content: "";
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.9;
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 72px 0;
}

.hero-copy {
  position: relative;
  z-index: 2;
  min-width: 0;
  max-width: 690px;
}

.eyebrow,
.section-kicker,
.panel-kicker {
  margin: 0 0 10px;
  color: var(--gold-2);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.4;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  color: var(--white);
  font-size: 64px;
  line-height: 1.06;
  font-weight: 900;
}

.hero-role {
  margin: 10px 0 0;
  color: var(--gold-2);
  font-size: 24px;
  font-weight: 900;
}

.hero-summary {
  max-width: 650px;
  margin: 26px 0 0;
  color: #d8e7f3;
  font-size: 18px;
  overflow-wrap: anywhere;
}

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

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 12px 18px;
  font-weight: 900;
  line-height: 1.2;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.button:hover {
  transform: translateY(-2px);
}

.button.primary {
  background: var(--gold);
  color: var(--navy);
}

.button.ghost {
  border-color: rgba(255, 255, 255, 0.35);
  color: var(--white);
}

.button.resume-download {
  border-color: rgba(184, 150, 110, 0.86);
  background: var(--white);
  color: var(--navy);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.button.resume-download:hover {
  border-color: var(--gold-2);
  background: #F0EDE8;
  color: var(--navy);
}

.button.dark {
  background: var(--navy);
  color: var(--white);
}

.resume-layout {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  align-items: start;
  background: var(--white);
  box-shadow: var(--shadow);
}

.profile-panel {
  align-self: stretch;
  min-width: 0;
  background: var(--navy);
  color: #c5d8e8;
}

.profile-sticky {
  position: sticky;
  top: 72px;
  padding: 42px 28px;
}

.avatar {
  display: block;
  width: 156px;
  height: 156px;
  margin-bottom: 24px;
  border: 1px solid rgba(224, 185, 106, 0.72);
  border-radius: var(--radius);
  object-fit: cover;
  object-position: center top;
}

.profile-panel h2 {
  margin: 0;
  color: var(--white);
  font-size: 34px;
  line-height: 1.16;
}

.panel-role {
  margin: 8px 0 0;
  color: var(--gold-2);
  font-weight: 800;
}

.panel-block {
  margin-top: 34px;
}

.panel-block h3 {
  margin: 0 0 18px;
  border-bottom: 2px solid var(--gold);
  padding-bottom: 10px;
  color: var(--gold-2);
  font-size: 18px;
}

.tech-logo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 22px;
}

.tech-logo-item {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 5px;
  border: 1px solid rgba(224, 185, 106, 0.24);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
  padding: 9px 5px;
}

.tech-logo-item img {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--white);
  padding: 3px;
  object-fit: contain;
}

.tech-logo-item span {
  max-width: 100%;
  color: #c5d8e8;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  overflow-wrap: anywhere;
}

.info-list {
  display: grid;
  gap: 18px;
  margin: 0;
}

.info-list div {
  min-width: 0;
}

.info-list dt,
.skill-group h4 {
  margin: 0 0 5px;
  color: var(--gold-2);
  font-size: 14px;
  font-weight: 900;
}

.info-list dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 14px;
}

.info-list a {
  color: #8fc6e3;
}

.skill-group {
  margin-top: 18px;
}

.skill-group ul {
  display: grid;
  gap: 5px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
}

.skill-group li {
  position: relative;
  padding-left: 14px;
}

.skill-group li::before {
  position: absolute;
  left: 0;
  top: 0.78em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cyan);
  content: "";
}

.content-panel {
  min-width: 0;
  background: var(--paper);
}

.section {
  padding: 52px 48px;
  border-bottom: 1px solid var(--line);
}

.section h2,
.contact-section h2 {
  margin: 0;
  color: var(--navy);
  font-size: 30px;
  line-height: 1.26;
}

.heading-emoji {
  display: inline-block;
  margin-right: 9px;
  font-size: 0.9em;
  line-height: 1;
  vertical-align: -0.04em;
}

.section p {
  margin: 14px 0 0;
  color: #334253;
}

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

#projects.section {
  padding-left: 36px;
  padding-right: 36px;
}

.lead {
  font-size: 17px;
}

.timeline-list {
  display: grid;
  gap: 24px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 24px;
  margin-top: 24px;
}

.timeline-list .timeline-item {
  margin-top: 0;
}

.timeline-meta {
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.timeline-body {
  position: relative;
  padding-left: 22px;
}

.timeline-body::before {
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 5px rgba(200, 151, 58, 0.18);
  content: "";
}

.timeline-body h3,
.certificate h3,
.project-card h3,
.strength h3 {
  margin: 0;
  color: var(--navy);
  font-size: 20px;
  line-height: 1.34;
}

.project-card h3 {
  font-size: 24px;
}

.project-card > h3 + .project-topline {
  margin-top: 10px;
}

.item-role {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 800;
}

.check-list {
  display: grid;
  gap: 7px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 18px;
  color: #334253;
}

.check-list li::before {
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--mint);
  content: "";
}

.certificate-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.strength-grid,
.preference-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.certificate,
.strength,
.preference-grid div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  padding: 20px;
}

.certificate span {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  color: var(--gold);
  font-size: 14px;
  font-weight: 900;
}

.card-emoji {
  line-height: 1;
}

.certificate p,
.strength p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 15px;
}

.project-carousel {
  margin-top: 28px;
}

.project-carousel-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 14px;
}

.carousel-button {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--navy);
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.carousel-button:hover,
.carousel-button:focus-visible {
  border-color: rgba(184, 150, 110, 0.56);
  background: #F0EDE8;
  color: var(--navy);
}

.carousel-button:hover {
  transform: translateY(-1px);
}

.carousel-button:disabled {
  cursor: default;
  opacity: 0.42;
  transform: none;
}

.carousel-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-counter {
  min-width: 56px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  text-align: center;
}

.project-grid {
  display: flex;
  align-items: flex-start;
  gap: 32px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  scroll-padding-inline: 2px;
  scroll-snap-type: x mandatory;
  /* 스크롤바 숨기기 (Firefox, IE/Edge) */
  scrollbar-width: none;
  -ms-overflow-style: none;
  /* 높이 리사이징 전환 애니메이션 */
  transition: height 0.4s cubic-bezier(0.16, 1, 0.3, 1);

  /* 호버 시 카드가 위로 떠오를 때 상단 테두리가 잘리는 현상 방지 */
  padding-top: 12px;
  padding-bottom: 12px;
  margin-top: -12px;
  margin-bottom: -12px;
}

/* 스크롤바 숨기기 (Chrome, Safari, Opera) */
.project-grid::-webkit-scrollbar {
  display: none;
}

.project-card {
  flex: 0 0 100%;
  align-self: flex-start;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  padding: 32px;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(184, 150, 110, 0.12);
  border-color: var(--gold-2);
}


.featured-card {
  border-color: var(--gold);
  background: var(--white);
}

.project-grid .project-card {
  scroll-snap-align: start;
}

.project-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.project-topline span {
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
}

.project-topline a {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--navy);
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.project-topline a:hover {
  background-color: var(--gold);
  border-color: var(--gold);
  color: var(--white);
}

.project-topline svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-topline a:hover svg {
  transform: translate(2px, -2px);
}

.project-media,
.project-gallery {
  margin-bottom: 22px;
}

.project-media {
  overflow: hidden;
  width: 100%;
  aspect-ratio: 16 / 9.6;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.project-media img,
.project-gallery img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: top center;
}

.erd-media {
  aspect-ratio: 16 / 9.2;
  background: #1d1b2d;
}

.erd-media img {
  object-fit: contain;
}

.market-hero-media {
  aspect-ratio: 16 / 9.6;
  background: var(--paper);
}

.market-hero-media img {
  object-fit: contain;
}

.tech-logo-item.badge-logo-item img {
  width: 74px;
  height: 22px;
  padding: 0;
  border-radius: 4px;
  background: transparent;
}

.artesia-flow-media {
  aspect-ratio: 1000 / 487;
  background: var(--paper);
}

.placeholder-media {
  min-height: 180px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 18px;
  background: var(--card);
}

.placeholder-media span {
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--gold);
  font-weight: 900;
}

.project-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}

.project-gallery img {
  aspect-ratio: 16 / 9.6;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.artesia-gallery img {
  aspect-ratio: 16 / 9.8;
}

.market-gallery {
  grid-template-columns: repeat(2, minmax(320px, 1fr));
}

.market-gallery img {
  aspect-ratio: 16 / 9.6;
  object-fit: contain;
}

.o2o-gallery {
  grid-template-columns: 1fr;
  gap: 18px;
}

.o2o-gallery img {
  height: auto;
  aspect-ratio: auto;
  object-fit: initial;
  background: var(--paper);
}

.link21-gallery {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.project-card p {
  margin-top: 12px;
}

.project-note {
  border-left: 3px solid var(--gold);
  padding-left: 12px;
  color: var(--muted);
  font-size: 14px;
}

.project-summary-list {
  display: grid;
  gap: 8px;
  margin: 16px 0 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  list-style: none;
}

.project-summary-list li {
  color: #334253;
  font-size: 14px;
  line-height: 1.58;
}

.project-summary-list strong {
  display: inline-block;
  min-width: 36px;
  margin-right: 6px;
  color: var(--gold);
  font-weight: 900;
}

.project-detail-section {
  background: var(--white);
}

.project-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.project-detail-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 24px;
}

.project-detail-heading span {
  display: block;
  margin-bottom: 8px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
}

.project-detail-heading h3 {
  margin: 0;
  color: var(--navy);
  font-size: 24px;
  line-height: 1.34;
}

.project-detail-list {
  display: grid;
  gap: 16px;
  margin: 22px 0 0;
}

.project-detail-list div {
  min-width: 0;
}

.project-detail-list dt {
  margin-bottom: 5px;
  color: var(--navy);
  font-size: 14px;
  font-weight: 900;
}

.project-detail-list dd {
  margin: 0;
  color: #334253;
  font-size: 14px;
  line-height: 1.68;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
  padding-top: 18px;
}

.tags span {
  border: 1px solid var(--navy);
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 900;
}

.strength-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  margin-bottom: 18px;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--gold-2);
  font-size: 14px;
  font-weight: 900;
}

.preference-grid div {
  min-height: 104px;
}

.preference-grid span {
  display: block;
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.preference-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--navy);
  font-size: 17px;
  line-height: 1.45;
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 32px;
  padding: 52px 48px;
  background: var(--white);
}

.contact-section p {
  margin: 14px 0 0;
  color: var(--muted);
}

.contact-section .section-kicker {
  color: var(--gold);
}

.contact-actions {
  justify-content: flex-end;
  margin-top: 0;
}

.project-media-stacked {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 22px;
}

.project-media-item {
  overflow: hidden;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.project-media-item img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Scroll Reveal (스크롤 감지 애니메이션) */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* 히어로 배경 발광 효과 (Hero Glow Animation) */
.hero-copy::before {
  content: "";
  position: absolute;
  top: -10%;
  left: -10%;
  width: 120%;
  height: 120%;
  background: radial-gradient(circle, rgba(184, 150, 110, 0.12) 0%, rgba(26, 26, 26, 0) 70%);
  filter: blur(40px);
  z-index: -1;
  pointer-events: none;
  animation: heroGlowPulse 8s infinite alternate ease-in-out;
}

@keyframes heroGlowPulse {
  0% {
    opacity: 0.7;
    transform: scale(0.95);
  }
  100% {
    opacity: 1;
    transform: scale(1.05);
  }
}

/* 타임라인 진행 중 활성 노드 펄싱 (Timeline Pulsing Dot) */
.timeline-item.is-current .timeline-body::before {
  background: var(--gold);
  box-shadow: 0 0 0 0 rgba(184, 150, 110, 0.5);
  animation: pulseTimelineDot 2s infinite ease-out;
}

@keyframes pulseTimelineDot {
  0% {
    box-shadow: 0 0 0 0 rgba(184, 150, 110, 0.5);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(184, 150, 110, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(184, 150, 110, 0);
  }
}

/* 언어 노출 제어 */
html[lang="ko"] .lang-en {
  display: none !important;
}
html[lang="en"] .lang-ko {
  display: none !important;
}

/* 언어 토글 버튼 스타일 */
.lang-toggle-container {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  margin-right: 16px;
}

.lang-btn {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color 0.3s ease, background-color 0.3s ease;
}

.lang-btn.active {
  color: var(--gold);
}

.lang-btn:hover:not(.active) {
  color: var(--white);
  background-color: rgba(255, 255, 255, 0.08);
}

.lang-divider {
  color: rgba(255, 255, 255, 0.15);
  font-size: 13px;
  user-select: none;
}

@media (max-width: 760px) {
  .lang-toggle-container {
    margin-right: 8px;
  }
}

.site-footer {
  width: min(1180px, calc(100% - 48px));
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 14px;
}

.site-footer a {
  font-weight: 900;
}

@media (max-width: 1020px) {
  .hero {
    min-height: 620px;
  }

  .hero-inner {
    padding: 64px 0;
  }

  .hero-bg {
    object-position: center right;
  }

  .resume-layout {
    grid-template-columns: 1fr;
  }

  .profile-sticky {
    position: static;
  }

  .profile-panel {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .certificate-grid,
  .strength-grid,
  .preference-grid,
  .project-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-section {
    grid-template-columns: 1fr;
  }

  .contact-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  body {
    font-size: 15px;
  }

  .site-header {
    min-height: 64px;
    padding: 10px 16px;
  }

  .menu-button {
    display: block;
  }

  .site-nav {
    position: fixed;
    inset: 64px 12px auto 12px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    border: 1px solid var(--navy-2);
    border-radius: var(--radius);
    background: var(--navy);
    padding: 8px;
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    justify-content: center;
  }

  .hero-inner,
  .resume-layout,
  .site-footer {
    width: min(1180px, calc(100% - 28px));
  }

  .hero-inner {
    padding: 44px 0;
  }

  .hero h1 {
    font-size: 46px;
  }

  .hero-role {
    font-size: 20px;
  }

  .hero-summary {
    font-size: 16px;
  }

  .hero-actions,
  .contact-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .hero::after {
    background: rgba(26, 26, 26, 0.88);
  }

  .profile-sticky,
  .section,
  .contact-section {
    padding: 34px 22px;
  }

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

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .project-grid,
  .certificate-grid,
  .strength-grid,
  .preference-grid,
  .project-detail-grid {
    grid-template-columns: 1fr;
  }

  .project-card {
    min-height: 0;
    padding: 22px;
  }

  #projects.section {
    padding-left: 18px;
    padding-right: 18px;
  }

  .project-carousel-controls {
    justify-content: center;
  }

  .project-gallery,
  .link21-gallery {
    grid-template-columns: 1fr;
  }

  .placeholder-media {
    grid-template-columns: 1fr;
  }

  .section h2,
  .contact-section h2 {
    font-size: 25px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 24px 0;
  }
}

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


/* --- Project GitHub Repository Bottom Link --- */
.project-github-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s ease;
  width: fit-content;
}

.project-github-link:hover {
  color: var(--gold);
}

.project-github-link .github-icon {
  width: 14px;
  height: 14px;
  fill: currentColor;
  transition: transform 0.3s ease;
}

.project-github-link:hover .github-icon {
  transform: scale(1.05);
}

/* On mobile, keep it inline-flex and don't stretch */
@media (max-width: 768px) {
  .project-github-link {
    width: auto;
    justify-content: flex-start;
  }
}

/* --- Dark Theme Variables & Styles --- */
[data-theme="dark"] {
  color-scheme: dark;
  --navy: #0F172A;
  --navy-2: #1E293B;
  --ink: #F1F5F9;
  --muted: #94A3B8;
  --line: #334155;
  --paper: #0B1120;
  --white: #1E293B;
  --gold: #D4B896;
  --gold-2: #E8D5C0;
  --cyan: #D4B896;
  --mint: #E8D5C0;
  --shadow: 0 22px 50px rgba(0, 0, 0, 0.5);
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-toggle-btn {
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 20px;
  padding: 6px 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
  font-size: 14px;
}

.theme-toggle-btn:hover {
  border-color: var(--gold);
  transform: scale(1.05);
}

[data-theme="dark"] .theme-icon.sun {
  display: inline-block;
}
[data-theme="dark"] .theme-icon.moon {
  display: none;
}

.theme-icon.sun {
  display: none;
}
.theme-icon.moon {
  display: inline-block;
}

/* --- Project Category Filter Bar --- */
.project-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 24px 0;
}

.filter-btn {
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--navy);
  color: #ffffff;
  border-color: var(--navy);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.project-card.is-hidden,
.project-detail-card.is-hidden {
  display: none !important;
}

.private-badge,
.project-topline .private-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #d97706;
}

.live-badge,
.project-topline .live-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #10b981;
}

.live-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  margin-top: 16px;
  font-size: 13px;
  font-weight: 700;
  color: #15803d;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.35);
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.25s ease;
}

.live-cta:hover {
  color: #ffffff;
  background: #16a34a;
  border-color: #16a34a;
  transform: translateY(-1px);
}

[data-theme="dark"] .live-cta {
  color: #4ade80;
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(74, 222, 128, 0.35);
}

[data-theme="dark"] .live-cta:hover {
  color: #0f172a;
  background: #4ade80;
  border-color: #4ade80;
}

/* --- Project Quick Spec Sheet (Role, What I Built, Service Type, Tech Stack) --- */
.project-spec-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 14px;
  margin: 12px 0 16px;
  padding: 12px 14px;
  background: rgba(184, 150, 110, 0.05);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 13px;
}

@media (max-width: 640px) {
  .project-spec-list {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 10px 12px;
  }
}

.project-spec-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
  line-height: 1.45;
}

.project-spec-item.full-width {
  grid-column: 1 / -1;
}

.project-spec-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--gold);
  flex-shrink: 0;
  min-width: 72px;
  letter-spacing: 0.03em;
}

.project-spec-value {
  color: var(--navy);
  font-weight: 600;
  font-size: 13px;
  word-break: keep-all;
}

[data-theme="dark"] .project-spec-value {
  color: var(--white);
}

.zero-to-one-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 800;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.1);
  border: 1px solid rgba(37, 99, 235, 0.35);
  border-radius: 4px;
}

[data-theme="dark"] .zero-to-one-tag {
  color: #60a5fa;
  background: rgba(37, 99, 235, 0.2);
  border-color: rgba(96, 165, 250, 0.4);
}

/* Gallery Item & Caption */
.gallery-item {
  display: flex;
  flex-direction: column;
}

.gallery-caption {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  font-weight: 600;
}

/* --- Interactive Flow Widget --- */
.interactive-flow-widget {
  margin: 20px 0;
  padding: 18px;
  background: rgba(184, 150, 110, 0.08);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.flow-widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.flow-badge {
  background: var(--gold);
  color: var(--navy);
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 10px;
  text-transform: uppercase;
}

.flow-widget-header h4 {
  margin: 0;
  font-size: 14px;
  color: var(--ink);
  font-weight: 700;
}

.flow-nodes-container {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-bottom: 14px;
}

.flow-node-btn {
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink);
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 5px;
}

.flow-node-btn .node-num {
  background: var(--line);
  color: var(--muted);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  font-size: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.flow-node-btn:hover,
.flow-node-btn.active {
  border-color: var(--gold);
  background: var(--navy);
  color: #ffffff;
}

.flow-node-btn.active .node-num {
  background: var(--gold);
  color: var(--navy);
}

.flow-content-box {
  background: var(--navy);
  color: #ffffff;
  padding: 14px;
  border-radius: 6px;
  font-size: 13px;
  line-height: 1.6;
}

.flow-content-box h5 {
  margin: 0 0 6px 0;
  color: var(--gold-2);
  font-size: 14px;
  font-weight: 700;
}

.flow-content-box p {
  margin: 0 0 10px 0;
  color: #e2e8f0;
  font-size: 13px;
}

.flow-content-box pre {
  background: rgba(0, 0, 0, 0.45);
  padding: 10px 12px;
  border-radius: 4px;
  overflow-x: auto;
  margin: 0;
  font-family: "Courier New", monospace;
  font-size: 12px;
  color: #818cf8;
}

/* Current Company Badge & Timeline */
.current-company-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding: 2px 10px;
  font-size: 13px;
  font-weight: 700;
  color: #16a34a;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  border-radius: 999px;
  vertical-align: middle;
  line-height: 1.4;
}

.current-company-tag::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
}

[data-theme="dark"] .current-company-tag {
  color: #4ade80;
  background: rgba(34, 197, 94, 0.18);
  border-color: rgba(74, 222, 128, 0.4);
}

.timeline-item.is-current .timeline-body::before {
  background: #22c55e;
  box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.22);
}

.timeline-item.is-current .item-role {
  color: #16a34a;
}

[data-theme="dark"] .timeline-item.is-current .item-role {
  color: #4ade80;
}

