/* ==========================================================
   다드림 — MCT · CNC 정밀가공
   Design tokens
   ========================================================== */
:root {
  /* color */
  --bg: #F3F3F1;
  --surface: #FFFFFF;
  --ink: #111111;
  --ink-2: #3A3A3A;
  --muted: #5E5E5E;          /* 6.1:1 on --bg */
  --line: #DADAD6;
  --dark: #0E0E0E;
  --dark-2: #191919;
  --dark-3: #262626;
  --on-dark: #EDEDEB;
  --on-dark-muted: #9A9A97;  /* 6.6:1 on --dark */
  --line-dark: #2E2E2E;
  --accent: #E5481F;         /* 장식·대형 요소에만 사용 */
  --grid-line: rgba(128, 128, 128, .14);
  --focus: #E5481F;
  --error: #C62A12;

  /* type */
  --font-sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, var(--font-sans);

  /* layout */
  --container: 1320px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;

  /* spacing */
  --s-1: 8px; --s-2: 16px; --s-3: 24px; --s-4: 32px;
  --s-5: 48px; --s-6: 64px; --s-7: 96px; --s-8: 128px;

  /* motion */
  --ease: cubic-bezier(.2, .7, .2, 1);
  --dur: 220ms;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 1000;
  background: var(--ink); color: #fff; padding: 10px 16px;
}
.skip-link:focus { top: 12px; }
.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;
}

/* ---------- layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }

/* 레퍼런스의 세로 그리드 라인 */
.grid-lines {
  position: fixed; inset: 0; z-index: 50; pointer-events: none;
}
.grid-lines .container {
  height: 100%;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
}
.grid-lines span { border-left: 1px solid var(--grid-line); }
.grid-lines span:last-child { border-right: 1px solid var(--grid-line); }
/* 흰 면(입력칸·카드·사진)은 그리드 라인 위로 */
.hero-card, .ph, .file-drop, .agree-box, .note, .tag, .filter-btn, .check span, .btn, .error-summary,
.field input, .field select, .field textarea, .site-footer, .svc-item .go {
  position: relative; z-index: 60;
}

.section { padding: var(--s-8) 0; position: relative; }
.section--dark { background: var(--dark); color: var(--on-dark); }
.section--white { background: var(--surface); }

.cols-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 0; }
.cols-4 > * { padding-right: var(--s-4); }
.c-12 { grid-column: 1 / 3; }
.c-23 { grid-column: 2 / 4; }
.c-34 { grid-column: 3 / 5; }
.cols-4 > .pl { padding-left: var(--s-3); padding-right: 0; }
.gap-y { row-gap: var(--s-6); }
.stack { display: grid; gap: 10px; margin-top: var(--s-4); }
.mt-3 { margin-top: var(--s-3); }
.section--dark .h-1, .section--dark .h-2 { color: #fff; }

/* ---------- type ---------- */
.label {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: 0.02em; color: var(--muted);
}
.label::before { content: "["; }
.label::after { content: "]"; }
.section--dark .label { color: var(--on-dark-muted); }
.label .dot { width: 6px; height: 6px; background: var(--accent); display: inline-block; }

.h-display {
  font-size: clamp(36px, 5.4vw, 76px);
  line-height: 1.12; font-weight: 700; letter-spacing: -0.045em;
}
.h-1 { font-size: clamp(30px, 3.8vw, 52px); line-height: 1.2; font-weight: 700; letter-spacing: -0.04em; }
.h-2 { font-size: clamp(24px, 2.6vw, 36px); line-height: 1.3; font-weight: 700; letter-spacing: -0.035em; }
.h-3 { font-size: 20px; line-height: 1.4; font-weight: 700; letter-spacing: -0.02em; }
.lead { font-size: clamp(17px, 1.4vw, 19px); line-height: 1.75; color: var(--ink-2); max-width: 36em; }
.section--dark .lead { color: var(--on-dark-muted); }
.muted { color: var(--muted); }
.section--dark .muted { color: var(--on-dark-muted); }
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 22px;
  font-size: 15px; font-weight: 600; letter-spacing: -0.01em;
  border: 1px solid var(--ink); background: var(--ink); color: #fff;
  cursor: pointer; touch-action: manipulation;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.btn:hover { background: var(--accent); border-color: var(--accent); color: #111; }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.section--dark .btn, .btn--light { background: #fff; color: var(--ink); border-color: #fff; }
.section--dark .btn:hover, .btn--light:hover { background: var(--accent); border-color: var(--accent); color: #111; }
.section--dark .btn--ghost { background: transparent; color: #fff; border-color: #fff; }
.section--dark .btn--ghost:hover { background: #fff; color: var(--ink); }
.btn .arrow { width: 16px; height: 16px; transition: transform var(--dur) var(--ease); }
.btn:hover .arrow { transform: translateX(3px); }

.text-link {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-weight: 600; border-bottom: 1px solid currentColor;
}
.text-link:hover { color: var(--accent); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease);
}
/* 흐림 효과는 가상 요소에 둔다. 헤더 자체에 backdrop-filter를 걸면
   그 안의 position:fixed 모바일 메뉴가 헤더 높이에 갇혀 펼쳐지지 않는다. */
.site-header::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: rgba(243, 243, 241, .88);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 800; font-size: 19px; letter-spacing: -0.04em; }
.brand svg { width: 26px; height: 26px; flex: none; }
.brand small { font-family: var(--font-mono); font-size: 11px; font-weight: 500; color: var(--muted); letter-spacing: 0; margin-left: 2px; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px;
  font-size: 15px; font-weight: 500; color: var(--ink-2);
  transition: color var(--dur) var(--ease);
}
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.nav a[aria-current="page"]::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 8px; height: 2px; background: var(--accent);
}
.header-cta { min-height: 42px; padding: 0 18px; font-size: 14px; }

.nav-toggle {
  display: none; width: 44px; height: 44px; border: 0; background: transparent; cursor: pointer;
  align-items: center; justify-content: center;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); position: relative; transition: background var(--dur); }
.nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; left: 0; width: 22px; height: 2px; background: var(--ink);
  transition: transform var(--dur) var(--ease);
}
.nav-toggle span::before { top: -7px; }
.nav-toggle span::after { top: 7px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- hero (home) ---------- */
.hero { position: relative; overflow: hidden; }
.hero-grid {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-height: min(calc(100dvh - var(--header-h)), 980px);
  padding-top: var(--s-5); padding-bottom: var(--s-6);
}
.hero-tag { grid-column: 1; grid-row: 1; padding-right: var(--s-3); z-index: 2; }
.hero-tag p { margin-top: var(--s-2); font-size: 14px; color: var(--muted); line-height: 1.7; }
.hero-art { grid-column: 2 / 4; grid-row: 1 / 3; align-self: center; padding: 0 var(--s-3); z-index: 1; }
.hero-side { grid-column: 4; grid-row: 1; padding-left: var(--s-3); z-index: 2; }
.hero-side p { font-size: 15px; color: var(--ink-2); margin-bottom: var(--s-3); }
.hero-title { grid-column: 1 / 4; grid-row: 3; align-self: end; z-index: 2; }
.hero-title .h-display span { display: block; }
.hero-card {
  grid-column: 4; grid-row: 3; align-self: end; margin-left: var(--s-3);
  background: var(--surface); border: 1px solid var(--line); z-index: 2;
}
.hero-card a { display: block; padding: var(--s-3); }
.hero-card .row { display: flex; justify-content: space-between; align-items: center; font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.hero-card ul { margin-top: var(--s-2); display: grid; gap: 2px; }
.hero-card li { display: flex; justify-content: space-between; padding: 8px 0; border-top: 1px solid var(--line); font-weight: 600; font-size: 15px; }
.hero-card li span:last-child { font-family: var(--font-mono); font-weight: 400; font-size: 12px; color: var(--muted); }
.hero-card a:hover li:first-child { color: var(--accent); }

/* 도면 일러스트 */
.drawing { width: 100%; height: auto; color: var(--ink); }
.drawing .ln { fill: none; stroke: currentColor; stroke-width: 1.4; }
.drawing .ln-thin { fill: none; stroke: currentColor; stroke-width: .8; }
.drawing .cl { fill: none; stroke: currentColor; stroke-width: .7; stroke-dasharray: 14 4 2 4; opacity: .55; }
.drawing .hid { fill: none; stroke: currentColor; stroke-width: .9; stroke-dasharray: 6 4; opacity: .7; }
.drawing .dim { fill: none; stroke: currentColor; stroke-width: .7; opacity: .75; }
.drawing .acc { stroke: var(--accent); fill: none; stroke-width: 1; }
.drawing .hatch { stroke: currentColor; stroke-width: .6; opacity: .35; }
.drawing text { font-family: var(--font-mono); font-size: 11px; fill: currentColor; }
.drawing text.acc-t { fill: var(--accent); font-weight: 600; }
.drawing .draw { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1.8s var(--ease) forwards; }
.drawing .fade { opacity: 0; animation: fade .8s var(--ease) 1.2s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade { to { opacity: 1; } }

/* ---------- page hero (sub pages) ---------- */
.page-hero { padding: var(--s-7) 0 var(--s-6); border-bottom: 1px solid var(--line); }
.page-hero .cols-4 { align-items: end; row-gap: var(--s-4); }
.page-hero .title-wrap { grid-column: 1 / 4; }
.page-hero .h-display { margin-top: var(--s-3); }
.page-hero .desc { grid-column: 4; font-size: 15px; color: var(--ink-2); }
.breadcrumb { display: flex; gap: 8px; font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.breadcrumb a:hover { color: var(--ink); }

/* ---------- section head ---------- */
.sec-head { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: var(--s-6); row-gap: var(--s-3); }
.sec-head .label { grid-column: 1; align-self: start; padding-top: 10px; }
.sec-head .h-1, .sec-head .h-2 { grid-column: 2 / 4; }
.sec-head .side { grid-column: 4; align-self: end; padding-left: var(--s-3); }

/* ---------- about intro (dark) ---------- */
.intro .cols-4 { row-gap: var(--s-5); }
.intro .statement { grid-column: 2 / 4; }
.intro .statement .h-2 { color: #fff; font-weight: 600; line-height: 1.45; }
.intro .statement .lead { margin-top: var(--s-4); font-size: 16px; }
.intro .statement .btn { margin-top: var(--s-4); }
.intro .media-col { grid-column: 4; padding-right: 0; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: var(--s-7); border-top: 1px solid var(--line-dark); }
.stat { padding: var(--s-4) var(--s-3) 0 0; }
.stat .num { font-family: var(--font-mono); font-size: clamp(32px, 3.6vw, 52px); font-weight: 500; letter-spacing: -0.04em; color: #fff; line-height: 1.1; }
.stat .num small { font-size: .45em; margin-left: 4px; color: var(--on-dark-muted); letter-spacing: 0; }
.stat .cap { margin-top: var(--s-1); font-size: 14px; color: var(--on-dark-muted); }

/* ---------- placeholder media ---------- */
.ph {
  position: relative; width: 100%; aspect-ratio: 4 / 5; overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255,255,255,.04), rgba(0,0,0,.08)),
    repeating-linear-gradient(0deg, transparent 0 23px, rgba(128,128,128,.12) 23px 24px),
    repeating-linear-gradient(90deg, transparent 0 23px, rgba(128,128,128,.12) 23px 24px),
    #DCDCD8;
  display: flex; align-items: flex-end;
}
.ph--dark { background:
    linear-gradient(135deg, rgba(255,255,255,.05), rgba(0,0,0,.2)),
    repeating-linear-gradient(0deg, transparent 0 23px, rgba(255,255,255,.05) 23px 24px),
    repeating-linear-gradient(90deg, transparent 0 23px, rgba(255,255,255,.05) 23px 24px),
    var(--dark-3); }
.ph--wide { aspect-ratio: 16 / 10; }
.ph--square { aspect-ratio: 1; }
.ph::before, .ph::after { content: ""; position: absolute; left: 50%; top: 50%; background: rgba(128,128,128,.45); }
.ph::before { width: 28px; height: 1px; transform: translate(-50%, -50%); }
.ph::after { width: 1px; height: 28px; transform: translate(-50%, -50%); }
.ph > span {
  position: relative; z-index: 1; margin: 14px; padding: 4px 8px;
  font-family: var(--font-mono); font-size: 11px; color: var(--muted);
  background: rgba(255,255,255,.7);
}
.ph--dark > span { background: rgba(0,0,0,.5); color: var(--on-dark-muted); }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ---------- service list ---------- */
.svc-list { border-top: 1px solid var(--ink); }
.svc-item { border-bottom: 1px solid var(--line); }
.svc-item a {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: start;
  padding: var(--s-4) 0; transition: background var(--dur) var(--ease);
}
.svc-item .no { font-family: var(--font-mono); font-size: 13px; color: var(--muted); padding-top: 6px; }
.svc-item .h-2 { grid-column: 2; }
.svc-item .desc { grid-column: 3; color: var(--ink-2); font-size: 15px; padding-right: var(--s-3); }
.svc-item .meta { grid-column: 4; display: flex; justify-content: space-between; align-items: start; gap: 12px; padding-left: var(--s-3); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-family: var(--font-mono); font-size: 12px; padding: 3px 9px; border: 1px solid var(--line); color: var(--ink-2); background: var(--surface); white-space: nowrap; }
.section--dark .tag { border-color: var(--line-dark); background: transparent; color: var(--on-dark); }
.svc-item .go { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border: 1px solid var(--line); transition: all var(--dur) var(--ease); }
.svc-item .go svg { width: 16px; height: 16px; }
.svc-item a:hover .go { background: var(--ink); color: #fff; border-color: var(--ink); }
.svc-item a:hover .h-2 { color: var(--accent); }

/* ---------- feature cards ---------- */
.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line-dark); }
.feature { padding: var(--s-4) var(--s-4) var(--s-4) 0; border-right: 1px solid var(--line-dark); }
.feature + .feature { padding-left: var(--s-4); }
.feature:last-child { border-right: 0; }
.feature .no { font-family: var(--font-mono); font-size: 12px; color: var(--accent); }
.feature .h-3 { margin-top: var(--s-5); color: #fff; }
.feature p { margin-top: var(--s-2); color: var(--on-dark-muted); font-size: 15px; }
.section:not(.section--dark) .features { border-top-color: var(--line); }
.section:not(.section--dark) .feature { border-right-color: var(--line); }
.section:not(.section--dark) .feature .h-3 { color: var(--ink); }
.section:not(.section--dark) .feature p { color: var(--ink-2); }

/* ---------- process ---------- */
.process { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); counter-reset: step; border-top: 1px solid var(--ink); }
.step { padding: var(--s-3) var(--s-3) 0 0; position: relative; }
.step::before {
  content: ""; position: absolute; top: -5px; left: 0; width: 9px; height: 9px; background: var(--bg); border: 1px solid var(--ink);
}
.step:first-child::before { background: var(--accent); border-color: var(--accent); }
.step .no { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.step .h-3 { margin-top: var(--s-2); }
.step p { margin-top: var(--s-1); font-size: 14px; color: var(--ink-2); }

/* ---------- equipment ---------- */
.eq-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; }
.eq-card { padding-right: var(--s-3); }
.eq-card .ph { aspect-ratio: 4 / 5; }
.eq-card .info { padding-top: var(--s-2); display: flex; justify-content: space-between; gap: 12px; }
.eq-card .info strong { font-size: 17px; }
.eq-card .info span { font-family: var(--font-mono); font-size: 13px; color: var(--on-dark-muted); }
.section:not(.section--dark) .eq-card .info span { color: var(--muted); }

.spec-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.spec-table caption { text-align: left; }
.spec-table th, .spec-table td { text-align: left; padding: 18px 16px 18px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec-table thead th { font-family: var(--font-mono); font-size: 12px; font-weight: 500; color: var(--muted); border-bottom: 1px solid var(--ink); padding-top: 0; }
.spec-table tbody th { font-weight: 700; }
.spec-table td.num { font-family: var(--font-mono); }
.table-wrap { overflow-x: auto; }

/* ---------- CTA band ---------- */
.cta-band { padding: var(--s-8) 0; }
.cta-band .cols-4 { align-items: end; row-gap: var(--s-4); }
.cta-band .h-display { grid-column: 1 / 4; color: #fff; }
.cta-band .actions { grid-column: 4; display: grid; gap: 12px; padding-right: 0; }
.cta-band .actions .btn { width: 100%; justify-content: space-between; }
.cta-band .contact-line { font-family: var(--font-mono); font-size: 13px; color: var(--on-dark-muted); margin-top: 4px; }

/* ---------- portfolio ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: var(--s-5); }
.filter-btn {
  min-height: 44px; padding: 0 18px; border: 1px solid var(--line); background: var(--surface);
  font-size: 14px; font-weight: 600; cursor: pointer; transition: all var(--dur) var(--ease);
}
.filter-btn:hover { border-color: var(--ink); }
.filter-btn[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.works { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: var(--s-3); row-gap: var(--s-5); }
.work .ph { aspect-ratio: 1; }
.work h3 { margin-top: var(--s-2); font-size: 17px; font-weight: 700; }
.work .tags { margin-top: var(--s-1); }
.work[hidden] { display: none; }
.note {
  margin-top: var(--s-5); padding: 14px 16px; border: 1px dashed var(--line);
  font-size: 14px; color: var(--muted); background: var(--surface);
}

/* ---------- about page ---------- */
.greeting { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: var(--s-4); }
.greeting .media-col { grid-column: 1; padding-right: var(--s-4); }
.greeting .body { grid-column: 2 / 4; }
.greeting .body p + p { margin-top: var(--s-3); }
.greeting .sign { margin-top: var(--s-5); font-size: 15px; }
.greeting .sign strong { font-size: 20px; margin-left: 8px; }

.info-list { border-top: 1px solid var(--ink); }
.info-list div { display: grid; grid-template-columns: minmax(0, 1fr) 3fr; padding: 18px 0; border-bottom: 1px solid var(--line); }
.info-list dt { font-family: var(--font-mono); font-size: 13px; color: var(--muted); padding-top: 2px; }
.info-list dd { font-weight: 600; }
.info-list dd a:hover { color: var(--accent); }
.section--dark .info-list { border-top-color: #fff; }
.section--dark .info-list div { border-bottom-color: var(--line-dark); }

.timeline { border-top: 1px solid var(--ink); }
.timeline li { display: grid; grid-template-columns: minmax(0, 1fr) 3fr; padding: var(--s-3) 0; border-bottom: 1px solid var(--line); }
.timeline .yr { font-family: var(--font-mono); font-size: 22px; font-weight: 500; }

/* ---------- service detail ---------- */
.svc-detail { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: var(--s-7) 0; border-top: 1px solid var(--line); row-gap: var(--s-4); }
.svc-detail:first-child { border-top: 0; padding-top: 0; }
.svc-detail .no { font-family: var(--font-mono); font-size: 13px; color: var(--muted); }
.svc-detail .main { grid-column: 2 / 4; padding-right: var(--s-5); }
.svc-detail .main .lead { margin-top: var(--s-3); font-size: 17px; }
.svc-detail .points { margin-top: var(--s-4); border-top: 1px solid var(--line); }
.svc-detail .points li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.svc-detail .points li::before { content: ""; flex: none; width: 6px; height: 6px; margin-top: 10px; background: var(--accent); }
.svc-detail .main .tags { margin-top: var(--s-3); }
.svc-detail .media-col { grid-column: 4; }

/* ---------- contact / form ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: var(--s-6); }
.contact-aside { grid-column: 1; padding-right: var(--s-5); }
.contact-aside .info-list div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
.contact-main { grid-column: 2 / 5; }

.form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s-4) var(--s-3); }
.field { display: grid; gap: 8px; align-content: start; }
.field--full { grid-column: 1 / -1; }
.field label, .field legend { font-size: 14px; font-weight: 700; padding: 0; }
.field .req { color: var(--error); margin-left: 2px; }
.field input[type="text"], .field input[type="tel"], .field input[type="email"], .field input[type="date"],
.field select, .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 0;
  font-size: 16px; transition: border-color var(--dur) var(--ease);
  -webkit-appearance: none; appearance: none;
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23111' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px;
}
.field textarea { min-height: 180px; resize: vertical; line-height: 1.6; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #9a9a96; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--ink); outline: 2px solid var(--ink); outline-offset: -2px; }
.field .help { font-size: 13px; color: var(--muted); }
.field .err { font-size: 13px; color: var(--error); font-weight: 600; display: none; }
.field.has-error .err { display: block; }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--error); }

fieldset.field { border: 0; margin: 0; padding: 0; min-width: 0; }
.checks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.check { position: relative; }
.check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px;
  border: 1px solid var(--line); background: var(--surface); font-size: 14px; font-weight: 600; cursor: pointer;
  transition: all var(--dur) var(--ease);
}
.check span:hover { border-color: var(--ink); }
.check input:checked + span { background: var(--ink); color: #fff; border-color: var(--ink); }
.check input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }

.file-drop {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 18px; border: 1px dashed #A9A9A5; background: var(--surface);
}
.file-drop input { font-size: 14px; max-width: 100%; }

.agree { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; }
.agree input { width: 20px; height: 20px; margin: 3px 0 0; accent-color: var(--ink); flex: none; }
.agree-box { margin-top: 8px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); font-size: 13px; color: var(--muted); line-height: 1.7; }

.form-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: var(--s-2); border-top: 1px solid var(--line); }
.form-status { font-size: 14px; font-weight: 600; }
.form-status.ok { color: #1F7A3A; }
.form-status.bad { color: var(--error); }
.error-summary { grid-column: 1 / -1; padding: 16px 18px; border: 1px solid var(--error); background: #FFF4F1; color: var(--error); }
.error-summary h2 { font-size: 15px; }
.error-summary ul { margin-top: 6px; list-style: disc; padding-left: 20px; font-size: 14px; }
.error-summary a { text-decoration: underline; }

.map-box { margin-top: var(--s-3); }

/* ---------- footer ---------- */
.site-footer { background: var(--dark); color: var(--on-dark); padding: var(--s-7) 0 var(--s-4); border-top: 1px solid var(--line-dark); }
.footer-top { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: var(--s-5); padding-bottom: var(--s-6); }
.footer-top .brand { color: #fff; }
.footer-top .brand small { color: var(--on-dark-muted); }
.footer-top .tagline { margin-top: var(--s-2); color: var(--on-dark-muted); font-size: 14px; }
.footer-col h2 { font-family: var(--font-mono); font-size: 12px; font-weight: 500; color: var(--on-dark-muted); margin-bottom: var(--s-2); }
.footer-col li a, .footer-col li { display: inline-flex; min-height: 36px; align-items: center; font-size: 15px; }
.footer-col ul { display: grid; }
.footer-col li a:hover { color: var(--accent); }
.footer-biz { border-top: 1px solid var(--line-dark); padding-top: var(--s-3); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--on-dark-muted); }
.footer-biz p span + span::before { content: "·"; margin: 0 8px; opacity: .6; }

/* ---------- photo media ---------- */
.media { position: relative; z-index: 60; overflow: hidden; background: var(--dark-3); aspect-ratio: var(--ar, 4 / 3); }
.media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
a:hover .media img, .card:hover .media img { transform: scale(1.03); }
.media-stack { display: flex; flex-direction: column; gap: var(--s-2, 12px); }
.media-stack .media { --ar: 3 / 2; }
.media.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: grayscale(1) contrast(1.05); transition: filter .4s var(--ease); }
.media.map:hover iframe, .media.map:focus-within iframe { filter: none; }

/* 핵심 기술 카드 */
.cards-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-5) var(--s-3); }
.card .media { --ar: 16 / 9; }
.card .card-body { padding-top: var(--s-2); display: flex; gap: 14px; align-items: baseline; }
.card .no { font-family: var(--font-mono); font-size: 12px; color: var(--muted); flex: none; }
.card h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.card p { margin-top: 6px; font-size: 14px; color: var(--ink-2); line-height: 1.65; }
.section--dark .card p { color: var(--on-dark-muted); }
.section--dark .card .no { color: var(--on-dark-muted); }

/* 적용 분야 */
.fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-2); }
.field-card { position: relative; }
.field-card .media { --ar: 4 / 3; }
.field-card .media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.72), rgba(0,0,0,0) 55%); }
.field-card figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 61; padding: var(--s-3);
  color: #fff; display: flex; justify-content: space-between; align-items: end; gap: 12px;
}
.field-card figcaption strong { font-size: 19px; letter-spacing: -0.02em; }
.field-card figcaption span { font-family: var(--font-mono); font-size: 12px; color: rgba(255,255,255,.75); }

/* 쇼케이스 (풀블리드 사진 + 문구) */
.showcase { position: relative; z-index: 60; background: #000; color: #fff; overflow: hidden; }
.showcase img { width: 100%; height: clamp(360px, 52vw, 720px); object-fit: cover; object-position: center 40%; opacity: .92; }
.showcase .overlay { position: absolute; inset: 0; display: flex; align-items: flex-end; }
.showcase .overlay .container { padding-bottom: var(--s-6); }
.showcase .h-display { color: #fff; text-shadow: 0 2px 30px rgba(0,0,0,.5); }
.showcase .label { color: rgba(255,255,255,.8); margin-bottom: var(--s-3); }

/* CTA 배경 사진 */
.cta-band--photo { position: relative; z-index: 60; overflow: hidden; }
.cta-band--photo > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .35; filter: grayscale(1); }
.cta-band--photo > .container { position: relative; }

/* 6단계 프로세스 */
.process--6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* 협력 네트워크 태그 */
.tag--net { border-style: dashed; color: var(--muted); }
.tag--own { border-color: var(--ink); color: var(--ink); }

/* 고객사 */
.clients { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.clients li {
  position: relative; z-index: 60; display: grid; place-items: center; min-height: 112px; padding: 16px; text-align: center;
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface);
  font-size: 17px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink-2);
}
.clients li small { display: block; font-family: var(--font-mono); font-size: 11px; font-weight: 400; color: var(--muted); margin-top: 4px; }
.clients-more { margin-top: var(--s-3); font-size: 14px; color: var(--muted); }

/* 연혁 (납품 실적) */
.history { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 var(--s-4); }
.history-year { padding: var(--s-4) 0; border-top: 1px solid var(--line); }
.history-year h3 { font-family: var(--font-mono); font-size: 28px; font-weight: 500; letter-spacing: -0.03em; }
.history-year ul { margin-top: var(--s-2); display: grid; gap: 8px; }
.history-year li { font-size: 14px; line-height: 1.55; color: var(--ink-2); display: grid; grid-template-columns: auto 1fr; gap: 10px; }
.history-year li::before { content: ""; width: 5px; height: 5px; margin-top: 8px; background: var(--ink); }
.history-year li b { font-weight: 700; color: var(--ink); }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .5s var(--ease), transform .5s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
  .drawing .draw { stroke-dashoffset: 0; }
  .drawing .fade { opacity: 1; }
}

/* ==========================================================
   Responsive
   ========================================================== */
@media (max-width: 1080px) {
  .nav a { padding: 0 10px; font-size: 14px; }
  .hero-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: auto; min-height: 0; row-gap: var(--s-4); }
  .hero-tag { grid-column: 1; grid-row: 1; }
  .hero-side { grid-column: 2; grid-row: 1; }
  .hero-art { grid-column: 1 / -1; grid-row: 2; padding: 0; }
  .hero-title { grid-column: 1 / -1; grid-row: 3; }
  .hero-card { grid-column: 1 / -1; grid-row: 4; margin-left: 0; }
  .works { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .eq-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--s-5); }
  .process, .process--6 { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: var(--s-5); }
  .clients { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cards-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .history { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  :root { --header-h: 64px; }
  .nav-toggle { display: inline-flex; }
  .nav {
    position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: var(--s-3) var(--gutter); background: var(--bg);
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), visibility var(--dur);
    overflow-y: auto;
  }
  .nav.is-open { opacity: 1; transform: none; visibility: visible; }
  .nav a { min-height: 60px; padding: 0; font-size: 22px; font-weight: 700; border-bottom: 1px solid var(--line); }
  .nav a[aria-current="page"]::after { left: auto; right: 0; top: 50%; bottom: auto; width: 8px; height: 8px; transform: translateY(-50%); }
  .header-cta { display: none; }
  .nav .nav-cta { display: flex; justify-content: center; margin-top: var(--s-4); min-height: 56px; font-size: 17px; color: #fff; border-bottom: 0; }
  .nav .nav-cta:hover { color: #fff; }
  .grid-lines .container { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-lines span:nth-child(n+3) { display: none; }
  .grid-lines span:nth-child(2) { border-right: 1px solid var(--grid-line); }

  .section { padding: var(--s-7) 0; }
  .cols-4, .sec-head, .svc-item a, .footer-top, .greeting, .contact-grid, .svc-detail { grid-template-columns: minmax(0, 1fr); }
  .cols-4 > *, .cols-4 > .pl { padding-right: 0; padding-left: 0; }
  .c-12, .c-23, .c-34 { grid-column: 1; }
  .sec-head .label, .sec-head .h-1, .sec-head .h-2, .sec-head .side,
  .page-hero .title-wrap, .page-hero .desc,
  .intro .statement, .intro .media-col,
  .cta-band .h-display, .cta-band .actions,
  .greeting .media-col, .greeting .body,
  .contact-aside, .contact-main,
  .svc-detail .main, .svc-detail .media-col { grid-column: 1; padding-left: 0; padding-right: 0; }
  .sec-head { margin-bottom: var(--s-5); }
  .sec-head .label { padding-top: 0; }
  .page-hero { padding: var(--s-6) 0 var(--s-5); }

  .svc-item a { row-gap: 12px; position: relative; }
  .svc-item .h-2, .svc-item .desc, .svc-item .meta { grid-column: 1; padding: 0; }
  .svc-item .go { position: absolute; right: 0; top: var(--s-4); }
  .svc-item .no { padding-top: 0; }

  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--s-4); margin-top: var(--s-6); }
  .features { grid-template-columns: minmax(0, 1fr); }
  .feature, .feature + .feature { padding: var(--s-4) 0; border-right: 0; border-bottom: 1px solid var(--line-dark); }
  .section:not(.section--dark) .feature { border-bottom-color: var(--line); }
  .feature .h-3 { margin-top: var(--s-3); }
  .process, .process--6 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .fields { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
  .field-card figcaption { padding: 14px; }
  .field-card figcaption strong { font-size: 16px; }
  .field-card figcaption span { display: none; }
  .works { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--s-2); }
  .eq-card { padding-right: var(--s-2); }
  .greeting .media-col { max-width: 320px; }
  .contact-aside .info-list div { grid-template-columns: minmax(0, 1fr) 2fr; }
  .form { grid-template-columns: minmax(0, 1fr); }
  .svc-detail { padding: var(--s-6) 0; }
}

@media (max-width: 520px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); padding-top: var(--s-4); }
  .hero-tag { padding-right: 0; }
  .hero-side { grid-column: 1; grid-row: auto; padding-left: 0; }
  .hero-tag, .hero-art, .hero-title, .hero-card { grid-row: auto; }
  .process, .process--6 { grid-template-columns: minmax(0, 1fr); }
  .cards-3, .history { grid-template-columns: minmax(0, 1fr); }
  .clients { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .clients li { min-height: 88px; font-size: 15px; }
  .eq-grid { grid-template-columns: minmax(0, 1fr); }
  .eq-card { padding-right: 0; }
  .info-list div, .timeline li { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .cta-band { padding: var(--s-7) 0; }
}

@media (min-width: 861px) { .nav .nav-cta { display: none; } }
