:root {
  --bg: #f6f7f3;
  --surface: #ffffff;
  --surface-strong: #ecf1ed;
  --ink: #16201e;
  --muted: #63706b;
  --line: #d9dfdb;
  --green: #1f7a55;
  --blue: #276a9f;
  --amber: #b96b18;
  --red: #b94444;
  --shadow: 0 18px 55px rgba(22, 32, 30, 0.1);
  --radius: 8px;
  --max: 1180px;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR",
    sans-serif;
  line-height: 1.6;
  word-break: keep-all;
  overflow-wrap: break-word;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(22, 32, 30, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, rgba(22, 32, 30, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
}

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 20;
  padding: 10px 14px;
  background: var(--ink);
  color: white;
  border-radius: var(--radius);
}

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

.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: 10;
  border-bottom: 1px solid rgba(22, 32, 30, 0.08);
  background: rgba(246, 247, 243, 0.88);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(var(--max), calc(100% - 40px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.brand-symbol {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--ink);
  color: white;
  font-weight: 800;
}

.brand-mark strong,
.brand-mark small {
  display: block;
}

.brand-mark small {
  color: var(--muted);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a,
.nav-contact {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: var(--radius);
  color: var(--muted);
}

.nav-links a:hover,
.nav-contact:hover {
  background: var(--surface-strong);
  color: var(--ink);
}

.nav-contact {
  border: 1px solid var(--line);
  color: var(--ink);
}

.hero-section {
  width: min(var(--max), calc(100% - 40px));
  min-height: calc(86svh - 72px);
  margin: 0 auto;
  padding: 52px 0 28px;
  display: grid;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 52px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 20px;
  font-size: clamp(1.95rem, 3.25vw, 2.72rem);
  line-height: 1.12;
  letter-spacing: 0;
}

.hero-title-line {
  display: block;
}

@media (min-width: 761px) {
  .hero-title-line {
    white-space: nowrap;
  }
}

h2 {
  margin-bottom: 12px;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.12;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 1.08rem;
  line-height: 1.25;
}

.hero-summary {
  max-width: 700px;
  color: #34413d;
  font-size: 1.08rem;
}

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

.primary-action,
.secondary-action {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  border: 1px solid var(--ink);
  padding: 0 18px;
  font-weight: 800;
}

.primary-action {
  background: var(--ink);
  color: white;
}

.secondary-action {
  background: transparent;
  color: var(--ink);
}

.hero-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.profile-media {
  aspect-ratio: 4 / 3;
  background: #e6ede7;
}

.profile-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.profile-text {
  padding: 22px;
}

.profile-text h2 {
  margin-bottom: 6px;
  font-size: 1.8rem;
}

.profile-role {
  margin-bottom: 6px;
  color: var(--blue);
  font-weight: 800;
}

.profile-text p:last-child {
  margin-bottom: 0;
  color: var(--muted);
}

.contact-list {
  margin: 0;
  padding: 0 22px 22px;
}

.contact-list div {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.contact-list dt {
  color: var(--muted);
}

.contact-list dd {
  margin: 0;
  font-weight: 700;
  word-break: normal;
  overflow-wrap: anywhere;
}

.section-shell {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
  padding: 74px 0;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 28px;
}

.section-heading p:not(.eyebrow) {
  color: var(--muted);
  font-size: 1rem;
}

.split-heading {
  max-width: none;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: end;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.metric-card {
  min-height: 156px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-top: 5px solid var(--accent);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 18px;
  box-shadow: 0 10px 34px rgba(22, 32, 30, 0.06);
}

.metric-card button {
  width: 100%;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}

.metric-label {
  color: var(--muted);
  font-size: 0.92rem;
}

.metric-value {
  display: block;
  margin: 14px 0 6px;
  font-size: 2.05rem;
  line-height: 1;
  font-weight: 900;
}

.metric-caption {
  color: #3f4b47;
  font-size: 0.92rem;
}

.filter-tabs button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  padding: 0 12px;
  font-weight: 700;
}

.filter-tabs button:hover,
.filter-tabs button.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: white;
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.project-list {
  display: grid;
  gap: 18px;
}

.project-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  scroll-margin-top: 92px;
}

.project-card.is-highlighted {
  outline: 3px solid rgba(31, 122, 85, 0.28);
}

.project-top {
  padding: 24px;
  border-bottom: 1px solid var(--line);
}

.project-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.project-title-row h3 {
  margin: 0;
  font-size: 1.4rem;
}

.period-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 10px;
  color: var(--muted);
  font-size: 0.84rem;
}

.project-description {
  margin-bottom: 14px;
  color: var(--muted);
}

.project-chip-rows {
  display: grid;
  gap: 8px;
}

.tag-row,
.focus-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-row span,
.focus-row span {
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.82rem;
  font-weight: 800;
}

.tag-row span {
  background: var(--surface-strong);
}

.focus-row span {
  border: 1px solid rgba(39, 106, 159, 0.22);
  background: rgba(39, 106, 159, 0.06);
  color: #46606f;
  font-size: 0.78rem;
}

.project-sections {
  display: grid;
  gap: 0;
}

.case-block {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 92px;
}

.case-block > div {
  min-width: 0;
}

.case-block:last-child {
  border-bottom: 0;
}

.case-block h4 {
  margin: 0;
  font-size: 1.05rem;
}

.case-result {
  margin-bottom: 14px;
  color: var(--green);
  font-weight: 800;
}

.case-copy {
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(22, 32, 30, 0.08);
  border-bottom: 1px solid rgba(22, 32, 30, 0.08);
}

.case-step {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(22, 32, 30, 0.08);
}

.case-step:last-child {
  border-bottom: 0;
}

.case-step strong {
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.65;
}

.case-step ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.case-step li {
  position: relative;
  min-width: 0;
  padding-left: 14px;
  color: var(--muted);
  word-break: keep-all;
  overflow-wrap: break-word;
}

.case-step li::before {
  content: "";
  position: absolute;
  top: 0.76em;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
}

.case-tables {
  margin-top: 20px;
}

.case-table {
  margin: 0;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: white;
  overflow: hidden;
}

.case-table figcaption {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-weight: 800;
}

.table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
}

.case-table table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.case-table th,
.case-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

.case-table th {
  background: var(--surface-strong);
  color: #34413d;
  font-size: 0.88rem;
}

.case-table td {
  color: var(--muted);
  font-weight: 650;
}

.case-table tbody tr:last-child td {
  border-bottom: 0;
}

.case-table tbody tr:last-child {
  background: rgba(31, 122, 85, 0.08);
}

.case-table tbody tr:last-child td {
  color: var(--ink);
}

.case-images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: 16px;
  margin-top: 20px;
}

.case-images.is-stacked {
  grid-template-columns: 1fr;
}

.case-images figure {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: white;
}

.case-images img {
  width: 100%;
  height: clamp(320px, 34vw, 460px);
  object-fit: contain;
  padding: 12px;
}

.case-images.is-stacked img {
  height: auto;
  min-height: 220px;
}

.case-images figcaption {
  padding: 10px 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.86rem;
}

.about-grid {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 38px;
}

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

.about-columns article {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 18px;
}

.about-columns p {
  margin-bottom: 0;
  color: var(--muted);
}

.site-footer {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 118px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p {
  margin: 0;
}

.nli-command {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 30;
  width: min(470px, calc(100% - 44px));
  height: min(520px, calc(100svh - 110px));
  display: block;
  pointer-events: none;
}

.nli-launcher {
  position: absolute;
  right: 0;
  bottom: 0;
  min-width: 178px;
  min-height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(22, 32, 30, 0.16);
  border-radius: var(--radius);
  background: var(--ink);
  color: white;
  box-shadow: 0 18px 55px rgba(22, 32, 30, 0.18);
  pointer-events: auto;
}

.nli-launcher strong {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: calc(var(--radius) - 2px);
  background: rgba(255, 255, 255, 0.14);
  font-size: 0.92rem;
}

.nli-launcher span {
  font-weight: 800;
}

.nli-panel {
  width: 100%;
  height: 100%;
  min-width: 360px;
  min-height: 390px;
  max-width: calc(100vw - 44px);
  max-height: calc(100svh - 110px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1px solid rgba(22, 32, 30, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 55px rgba(22, 32, 30, 0.18);
  backdrop-filter: blur(18px);
  overflow: hidden;
  resize: both;
  pointer-events: auto;
}

.nli-command.is-collapsed {
  width: auto;
  height: auto;
}

.nli-command.is-collapsed .nli-panel,
.nli-command:not(.is-collapsed) .nli-launcher {
  display: none;
}

.nli-panel-header {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 14px 12px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.nli-kicker {
  margin: 0 0 2px;
  color: var(--green);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.nli-panel-header h2 {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.25;
}

.nli-panel-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nli-panel-actions button {
  min-width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) - 2px);
  background: var(--surface-strong);
  color: var(--ink);
  padding: 0 9px;
  font-size: 0.78rem;
  font-weight: 800;
}

.nli-panel-body {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.nli-command.is-minimized {
  height: auto;
}

.nli-command.is-minimized .nli-panel {
  height: auto;
  min-height: 0;
  resize: none;
}

.nli-command.is-minimized .nli-panel-body {
  display: none;
}

.nli-messages {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  padding: 16px;
  background: linear-gradient(180deg, rgba(246, 247, 243, 0.72), rgba(255, 255, 255, 0.96));
}

.nli-message {
  max-width: 88%;
  display: grid;
  gap: 4px;
}

.nli-message.is-user {
  align-self: end;
}

.nli-message.is-assistant {
  align-self: start;
}

.nli-message-label {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
}

.nli-message.is-user .nli-message-label {
  text-align: right;
}

.nli-message p {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  background: var(--surface);
  color: #34413d;
  font-size: 0.92rem;
  line-height: 1.55;
  white-space: pre-wrap;
}

.nli-message.is-user p {
  border-color: var(--ink);
  background: var(--ink);
  color: white;
}

.nli-message.is-pending p {
  color: var(--muted);
}

.nli-typing {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding-left: 4px;
}

.nli-typing i {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--green);
  animation: nli-pulse 1s infinite ease-in-out;
}

.nli-typing i:nth-child(2) {
  animation-delay: 0.15s;
}

.nli-typing i:nth-child(3) {
  animation-delay: 0.3s;
}

.nli-form {
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 8px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.nli-form input {
  min-width: 0;
  min-height: 42px;
  border: 0;
  border-radius: calc(var(--radius) - 2px);
  background: var(--surface-strong);
  color: var(--ink);
  padding: 0 14px;
  outline: 0;
}

.nli-form input:focus {
  box-shadow: inset 0 0 0 2px rgba(31, 122, 85, 0.32);
}

.nli-form button {
  min-height: 42px;
  border: 0;
  border-radius: calc(var(--radius) - 2px);
  background: var(--ink);
  color: white;
  padding: 0 16px;
  font-weight: 800;
}

.nli-form button:disabled,
.nli-form input:disabled {
  cursor: wait;
  opacity: 0.72;
}

@keyframes nli-pulse {
  0%,
  80%,
  100% {
    transform: translateY(0);
    opacity: 0.42;
  }

  40% {
    transform: translateY(-3px);
    opacity: 1;
  }
}

@media (max-width: 1060px) {
  .hero-grid,
  .about-grid {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    max-width: 560px;
  }

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

  .project-top,
  .case-block {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .nav-shell {
    width: min(var(--max), calc(100% - 28px));
    min-height: auto;
    padding: 12px 0;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
  }

  .brand-mark {
    min-width: 0;
  }

  .brand-mark small,
  .nav-contact {
    display: none;
  }

  .nav-links {
    order: 3;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .nav-links a {
    min-height: 34px;
    padding: 0 9px;
    font-size: 0.9rem;
  }

  .hero-section,
  .section-shell,
  .site-footer {
    width: min(var(--max), calc(100% - 28px));
  }

  .hero-section {
    min-height: auto;
    padding-top: 46px;
  }

  h1 {
    font-size: clamp(1.75rem, 7.6vw, 2.35rem);
    line-height: 1.14;
  }

  .split-heading {
    display: block;
  }

  .filter-tabs {
    justify-content: flex-start;
    margin-top: 14px;
  }

  .metric-grid,
  .about-columns {
    grid-template-columns: 1fr;
  }

  .case-images {
    grid-template-columns: 1fr;
  }

  .case-step {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .case-images img {
    height: 300px;
  }

  .case-images.is-stacked img {
    height: 340px;
  }

  .site-footer {
    display: block;
  }

  .site-footer a {
    display: inline-flex;
    margin-top: 12px;
  }
}

@media (max-width: 480px) {
  .contact-list div {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .project-top,
  .case-block {
    padding: 20px;
  }

  .case-images img {
    width: 640px;
    max-width: none;
    height: 300px;
  }

  .case-images.is-stacked img {
    height: 320px;
  }

  .case-images figure {
    overflow-x: auto;
  }

  .nli-command {
    right: 14px;
    bottom: 14px;
    width: calc(100% - 28px);
    height: min(520px, calc(100svh - 96px));
  }

  .nli-command.is-collapsed {
    width: auto;
    height: auto;
  }

  .nli-panel {
    min-width: 0;
    min-height: 360px;
    max-width: calc(100vw - 28px);
    max-height: calc(100svh - 96px);
    resize: vertical;
  }

  .nli-launcher {
    min-width: 154px;
    min-height: 54px;
  }

  .nli-launcher span {
    font-size: 0.9rem;
  }

  .nli-form {
    grid-template-columns: 1fr;
  }

  .nli-form button {
    width: 100%;
  }
}
