:root {
  --bg: #ffffff;
  --bg-soft: #f6f8fb;
  --text: #172033;
  --muted: #566176;
  --brand: #3b2f79;
  --brand-dark: #241a55;
  --brand-soft: #ebe8ff;
  --border: #dfe4ee;
  --shadow: 0 18px 45px rgba(23, 32, 51, 0.10);
  --max: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

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

a { color: var(--brand); text-decoration-thickness: 0.08em; text-underline-offset: 0.18em; }
a:hover { color: var(--brand-dark); }
a:focus-visible, button:focus-visible { outline: 3px solid #ffbf47; outline-offset: 3px; }

.skip-link {
  position: absolute;
  left: 1rem;
  top: -5rem;
  z-index: 1000;
  padding: .75rem 1rem;
  background: var(--brand-dark);
  color: #fff;
  border-radius: .5rem;
}
.skip-link:focus { top: 1rem; color: #fff; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.site-header__inner, .site-footer__inner, .site-main > .section, .page-shell, .frontpage-shell, .site-main > .page-header {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1rem 0;
}

.site-brand { display: inline-flex; flex-direction: column; color: var(--text); text-decoration: none; font-weight: 800; line-height: 1.15; }
.site-brand__ko { color: var(--muted); font-size: .9rem; font-weight: 600; }
.site-nav ul { display: flex; flex-wrap: wrap; gap: .35rem .65rem; align-items: center; justify-content: flex-end; padding: 0; margin: 0; list-style: none; }
.site-nav a { display: inline-block; padding: .35rem .35rem; border-radius: 999px; font-size: .92rem; font-weight: 700; line-height: 1.2; text-decoration: none; }
.site-nav a:hover, .site-nav a:focus-visible, .site-nav a[aria-current="page"] { background: var(--brand-soft); color: var(--brand-dark); }
.site-nav a[aria-current="page"] { box-shadow: inset 0 0 0 1px rgba(59, 47, 121, .25); }
.site-nav__cv { border: 1px solid var(--border); background: #fff; }
.site-nav__cv:hover, .site-nav__cv:focus-visible { border-color: var(--brand); }


.site-main { outline: none; }
.section { padding: 4.5rem 0; }
.section--compact { padding-top: 3.25rem; padding-bottom: 3.25rem; }
.section--tinted { width: 100% !important; max-width: none !important; padding-inline: max(1rem, calc((100% - var(--max)) / 2)); background: var(--bg-soft); }
.section--contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, .9fr); gap: 2rem; align-items: center; border-top: 1px solid var(--border); }

.hero { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(240px, .65fr); gap: 3rem; align-items: center; min-height: 68vh; }
.hero h1 { margin: .2rem 0 .8rem; font-size: clamp(2.6rem, 6vw, 5.2rem); line-height: .98; letter-spacing: -.055em; }
.hero h1 span { display: block; color: var(--brand); font-size: .48em; letter-spacing: 0; margin-top: .45rem; }
.hero__title { max-width: 780px; color: var(--brand-dark); font-size: clamp(1.05rem, 1.8vw, 1.3rem); font-weight: 800; line-height: 1.35; }
.hero__positioning { max-width: 760px; font-size: 1.12rem; color: var(--muted); }
.hero__portrait { margin: 0; }
.hero__portrait img { width: 100%; border-radius: 1.4rem; box-shadow: var(--shadow); aspect-ratio: 4 / 5; object-fit: cover; }

.eyebrow { margin: 0 0 .7rem; color: var(--brand); font-size: .82rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
h1, h2, h3 { color: var(--text); line-height: 1.16; }
h2 { max-width: 850px; margin: 0 0 1.4rem; font-size: clamp(1.75rem, 3vw, 2.75rem); letter-spacing: -.035em; }
h3 { margin-top: 0; font-size: 1.22rem; }

.button-row, .link-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 2.75rem; padding: .68rem 1rem; border-radius: 999px; background: var(--brand); color: #fff; font-weight: 800; text-decoration: none; }
.button:hover { background: var(--brand-dark); color: #fff; }
.button--secondary { background: var(--text); }
.button--ghost { color: var(--brand); background: var(--brand-soft); }
.button--ghost:hover { color: #fff; }

.card-grid { display: grid; gap: 1rem; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 1rem; }
.card-grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.awards-grid { align-items: stretch; }
.card, .research-card, .mini-paper { padding: 1.25rem; border: 1px solid var(--border); border-radius: 1rem; background: #fff; box-shadow: 0 8px 28px rgba(23, 32, 51, 0.06); }
.research-list { display: grid; gap: 1.25rem; }
.research-card { display: grid; grid-template-columns: minmax(220px, .72fr) minmax(0, 1.28fr); gap: 1.5rem; }
.research-card__summary, .research-card__body { min-width: 0; }
.research-card__venue { margin: 0 0 .4rem; color: var(--brand); font-weight: 800; }
.research-card__citation { grid-column: 1 / -1; margin: 1.1rem 0 0; padding-top: .85rem; border-top: 1px solid var(--border); color: var(--muted); font-size: .92rem; line-height: 1.55; overflow-wrap: anywhere; }

dl { margin: 0; }
dt { margin-top: .75rem; color: var(--text); font-weight: 900; }
dd { margin-left: 0; color: var(--muted); }

.split-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 1.5rem 0; }
.timeline-list { padding: 0; margin: 1rem 0 0; list-style: none; border-top: 1px solid var(--border); }
.timeline-list li { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 1rem; padding: .9rem 0; border-bottom: 1px solid var(--border); }
.timeline-list time { color: var(--brand); font-weight: 900; }
address { font-style: normal; }
.contact__intro, .contact__details { min-width: 0; }
.contact__name { font-size: 1.15rem; }
.contact-card { display: grid; gap: 1rem; padding: 1.5rem; border: 1px solid var(--border); border-radius: 1.1rem; background: var(--bg-soft); box-shadow: 0 8px 28px rgba(23, 32, 51, 0.05); }
.contact-card__row { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 1rem; align-items: start; }
.contact-card dt { margin: 0; color: var(--text); font-weight: 900; }
.contact-card dd { margin: 0; overflow-wrap: anywhere; word-break: normal; }
.contact-card .link-row { gap: .55rem .85rem; }
.contact-card .link-row a { display: inline-flex; }

.review-note { font-weight: 900; color: #8a5a00; }
.award-card { display: flex; flex-direction: column; gap: .35rem; }
.award-card p { margin: 0; }
.card-label { align-self: flex-start; padding: .2rem .55rem; border: 1px solid var(--border); border-radius: 999px; background: var(--brand-soft); color: var(--brand-dark); font-size: .75rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.award-card__date { color: var(--muted); font-weight: 800; }
.representative-paper-list a { font-weight: 800; text-decoration-thickness: .1em; }
.representative-paper-list a:hover { color: var(--brand-dark); }
.publication-item { scroll-margin-top: 6.5rem; }
.publication-citation { overflow-wrap: anywhere; }
.publication-links a { font-weight: 800; }
.status-badge { display: inline-block; max-width: 100%; padding: .28rem .65rem; border: 1px solid #e5cf8e; border-radius: .65rem; background: #fff8e6; color: #684600; font-size: .95rem; font-weight: 800; line-height: 1.45; overflow-wrap: anywhere; }
.lead-text { max-width: 860px; color: var(--muted); font-size: 1.1rem; }
.industry-page .card h3 + p { margin-top: .45rem; }
.capstone-card { display: flex; flex-direction: column; gap: .75rem; }
.capstone-card p { margin-bottom: 0; }
.video-embed { position: relative; width: 100%; aspect-ratio: 16 / 9; margin-top: .35rem; overflow: hidden; border: 1px solid var(--border); border-radius: .85rem; background: var(--bg-soft); }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.site-footer { border-top: 1px solid var(--border); background: var(--bg-soft); }
.site-footer__inner { padding: 2rem 0; color: var(--muted); }
.site-footer p { margin: .2rem 0; }

.page-header { padding-top: 3rem; }
.page-shell, .frontpage-shell { padding-bottom: 4rem; }
.page-content, .frontpage-content { min-width: 0; }

@media (max-width: 820px) {
  body { font-size: 16px; }
  .site-header { position: static; }
  .site-header__inner { align-items: flex-start; flex-direction: column; }
  .site-nav { width: 100%; min-width: 0; }
  .site-nav ul { width: 100%; justify-content: flex-start; gap: .3rem .45rem; }
  .site-nav a { padding: .32rem .3rem; font-size: .86rem; }
  .hero, .section--contact, .research-card, .split-list, .card-grid--three { grid-template-columns: 1fr; }
  .section--contact { align-items: stretch; }
  .contact-card { padding: 1.1rem; }
  .contact-card__row { grid-template-columns: 1fr; gap: .2rem; }
  .hero { min-height: auto; padding-top: 3rem; }
  .hero__portrait { max-width: 330px; }
  .timeline-list li { grid-template-columns: 1fr; gap: .2rem; }
}
.card-grid--four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card-grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.page-section h1 { margin: .2rem 0 1.2rem; font-size: clamp(2.2rem, 4vw, 3.5rem); letter-spacing: -.04em; }
.page-section h2 { margin-top: 2.4rem; }
.citation, .publication-list li { overflow-wrap: anywhere; }
.publication-list { padding-left: 1.4rem; }
.publication-list li { margin-bottom: 1rem; padding-left: .3rem; }
.muted { color: var(--muted); }
.pill-list { display: flex; flex-wrap: wrap; gap: .6rem; padding: 0; list-style: none; }
.pill-list li { padding: .45rem .75rem; border: 1px solid var(--border); border-radius: 999px; background: var(--brand-soft); color: var(--brand-dark); font-weight: 800; }
.table-wrap { width: 100%; overflow-x: auto; margin: 1rem 0 2rem; }
.data-table { width: 100%; border-collapse: collapse; background: #fff; }
.data-table th, .data-table td { padding: .8rem; border: 1px solid var(--border); text-align: left; vertical-align: top; }
.data-table th { background: var(--bg-soft); color: var(--brand-dark); }
.card h2 { font-size: 1.25rem; letter-spacing: 0; }
@media (max-width: 1050px) { .card-grid--four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 820px) { .card-grid--four, .card-grid--two { grid-template-columns: 1fr; } .data-table { min-width: 680px; } }

@media (max-width: 380px) {
  .site-header__inner, .site-footer__inner, .site-main > .section, .page-shell, .frontpage-shell, .site-main > .page-header { width: min(var(--max), calc(100% - 1rem)); }
  .site-nav a { font-size: .8rem; padding: .28rem .24rem; }
}

.post-shell { padding-bottom: 4rem; }
.post-content { min-width: 0; }
.post-content .date { margin-bottom: 1rem; color: var(--muted); font-weight: 800; }
.post-content .content { margin-bottom: 2rem; }
.tag_box { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 1rem 0; list-style: none; }
.tag_box a { display: inline-flex; align-items: center; padding: .25rem .6rem; border: 1px solid var(--border); border-radius: 999px; background: var(--bg-soft); font-weight: 800; text-decoration: none; }
.pagination ul { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .75rem; padding: 0; margin: 1.5rem 0; list-style: none; }
.pagination a { font-weight: 800; }
.pagination .disabled a { color: var(--muted); cursor: default; text-decoration: none; }
.error-page { margin-top: 2rem; }
.error-page__content { max-width: 42rem; }
.error-page__content p { margin-top: .5rem; }
