/* Shared top bar for the pages that still use the old styles (ABOUT, WORK, PARTNERS, CONTACT),
   so every page has exactly the home page's header. Generated from css/style.css (header + KR/EN),
   with .hd -> .nh and .mnav -> .nmnav so the old .hd rules in legacy.css never touch it.
   body.nh-over = transparent bar with the white logo over a dark first screen (like home). */
:root { --nh-h: 84px; --nh-pad: clamp(20px, 4vw, 64px); }
@media (max-width: 860px) { :root { --nh-h: 64px; } }
body.nh-page { padding-top: var(--nh-h); }
body.nh-page.nh-over { padding-top: 0; }
.nh-over .pw-hero { height: 100vh; height: 100svh; }
.nh, .nmnav { font-family: "Pretendard Variable", -apple-system, BlinkMacSystemFont, system-ui, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; --ease: cubic-bezier(0.19, 1, 0.22, 1); }
.nh button, .nmnav button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
.nh a, .nmnav a { color: inherit; text-decoration: none; }
.nh img { display: block; max-width: 100%; }
body.menu-open { overflow: hidden; }

/* ---------- header ---------- */
.nh {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--nh-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--nh-pad);
  color: #111;
  background: rgba(255, 255, 255, 0.96);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  transition: background 0.45s var(--ease), color 0.45s var(--ease), transform 0.5s var(--ease);
}
.nh__logo { position: relative; display: block; width: clamp(128px, 11vw, 190px); height: auto; }
.nh__logo img { width: 100%; height: auto; transition: opacity 0.4s var(--ease); }
.nh__logo .is-light { position: absolute; inset: 0; opacity: 0; }
.nh__nav { display: flex; gap: clamp(26px, 3vw, 48px); }
.nh__nav a {
  position: relative;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 8px 0;
  opacity: 0.9;
  transition: opacity 0.3s;
}
.nh__nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 2px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}
.nh__nav a:hover::after, .nh__nav a[aria-current="page"]::after { transform: scaleX(1); }
.nh__nav a:hover { opacity: 1; }
/* home: the bar sits on the photo with no background until the page scrolls */
.nh-over .nh:not(.is-scrolled):not(.is-open) {
  color: #fff;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
.nh-over .nh:not(.is-scrolled):not(.is-open) .nh__logo .is-dark { opacity: 0; }
.nh-over .nh:not(.is-scrolled):not(.is-open) .nh__logo .is-light { opacity: 1; }

.nh__burger {
  display: none;
  width: 44px; height: 44px;
  margin-right: -10px;
  position: relative;
}
.nh__burger span {
  position: absolute;
  left: 11px; right: 11px;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.4s var(--ease), top 0.4s var(--ease);
}
.nh__burger span:first-child { top: 18px; }
.nh__burger span:last-child { top: 25px; }
.nh.is-open .nh__burger span:first-child { top: 21.5px; transform: rotate(45deg); }
.nh.is-open .nh__burger span:last-child { top: 21.5px; transform: rotate(-45deg); }

.nmnav {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--nh-h) var(--nh-pad) 40px;
  background: #fff;
  color: #111;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--ease), visibility 0.4s;
}
.nmnav.is-open { opacity: 1; visibility: visible; }
.nmnav a {
  display: block;
  font-size: clamp(40px, 11vw, 64px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  padding: 6px 0;
  transform: translateY(14px);
  opacity: 0;
  transition: transform 0.6s var(--ease), opacity 0.5s;
}
.nmnav.is-open a { transform: none; opacity: 1; }
.nmnav.is-open a:nth-child(2) { transition-delay: 0.05s; }
.nmnav.is-open a:nth-child(3) { transition-delay: 0.1s; }
.nmnav.is-open a:nth-child(4) { transition-delay: 0.15s; }
.nmnav__mail { margin-top: 36px; font-size: 14px; color: #6b6b6b; }
@media (max-width: 860px) {
  .nh__nav { display: none; }
  .nh__burger { display: block; }
}

/* ---------- KR / EN switch (right of the menu) ---------- */
.nh__right { display: flex; align-items: center; gap: clamp(26px, 3vw, 48px); }
.nh__lang { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.1em; }
.nh__lang i { font-style: normal; opacity: 0.5; }
.nh__lang button { padding: 8px 0; opacity: 0.5; transition: opacity 0.3s; }
.nh__lang button:hover, .nh__lang button.is-on { opacity: 1; }
.nh__lang button.is-on { text-decoration: underline; text-underline-offset: 5px; }
.nmnav__lang { display: flex; gap: 18px; margin-top: 28px; font-size: 15px; font-weight: 700; letter-spacing: 0.12em; }
.nmnav__lang button { opacity: 0.45; }
.nmnav__lang button.is-on { opacity: 1; text-decoration: underline; text-underline-offset: 6px; }
@media (max-width: 860px) { .nh__lang { display: none; } }

/* keep the scrollbar space reserved so the top bar never shifts between pages */
html { scrollbar-gutter: stable; }

/* ---------- white everywhere on the old-style pages (matches the home page) ---------- */
/* footer: the old one was black; same content, white like home */
.nh-page .ft { background: #fff; color: #111; border-top: 1px solid #e8e8e8; }
.nh-page .ft__cta { color: #111; border-color: #111; }
.nh-page .ft__cta:hover { color: #6b6b6b; }
.nh-page .ft__col h4 { color: #8c8c8c; }
.nh-page .ft__col a, .nh-page .ft__col p, .nh-page .ft__col b, .nh-page .ft__col > a { color: #111; }
.nh-page .ft__col a:hover { color: #6b6b6b; }
.nh-page .ft__bottom { border-color: #e8e8e8; color: #8c8c8c; }
.nh-page .ft__top-btn:hover { color: #111; }
.nh-page .ft__word { -webkit-text-stroke-color: rgba(0, 0, 0, 0.12); }

/* ABOUT / PARTNERS first screen: no poster wall, plain white with the big line in black */
.pg-white .pw-hero {
  height: auto;
  min-height: 0;
  padding: clamp(80px, 16vh, 180px) 0 clamp(64px, 11vh, 130px);
  background: #fff;
  color: #111;
  border-bottom: 1px solid #e8e8e8;
}
.pg-white .pw-wall, .pg-white .pw-hero__shade, .pg-white .pw-hero__cue { display: none; }
.pg-white .pw-hero__in { height: auto; }
.pg-white .pw-k { color: #8c8c8c; }
.pg-white .pw-hero__title { color: #111; }
/* the black "contact us" band becomes white too */
.pg-white .ab-cta { background: #fff; color: #111; border-top: 1px solid #e8e8e8; }
.pg-white .bx-btn--light { background: #111; color: #fff; border-color: #111; }
.pg-white .bx-btn--light:hover { background: #fff; color: #111; }
.nh-page #ft-offices p, .nh-page #ft-offices b { color: #111; }
.nh-page #ft-offices p { color: #555; }

/* PARTNERS opens straight on the partner list (no intro banner) */
.pg-partners .pt-first { padding-top: clamp(48px, 7vw, 110px); }

/* ABOUT opens straight on the company intro, then the CEO (no opening banner) */
.pg-white .ab-first { padding-top: clamp(48px, 7vw, 110px); }
.pg-white .ab-first + .ab-ceo { margin-top: clamp(56px, 7vw, 110px); }

/* LOCATION: track record of places (kinds only), big words that light up gold on hover */
.loc-rec { padding-top: clamp(80px, 11vw, 160px); }
.loc-rec__k { font-size: 11px; font-weight: 700; letter-spacing: 0.28em; color: #b08d57; }
.loc-rec__t { margin-top: 16px; font-size: clamp(30px, 3.6vw, 60px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.2; color: #111; }
.loc-rec__groups { margin-top: clamp(36px, 5vw, 70px); border-top: 1px solid #111; }
.loc-rec__g { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 20px; padding: clamp(18px, 2.4vw, 30px) 0; border-bottom: 1px solid #e3e3e3; }
.loc-rec__gl { padding-top: 0.55em; font-size: 12px; font-weight: 700; letter-spacing: 0.16em; color: #8a8a8a; }
.loc-rec__g ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 0; }
.loc-rec__g li { font-size: clamp(24px, 2.8vw, 46px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.25; color: #111; transition: color 0.3s; }
.loc-rec__g li + li::before { content: "/"; margin: 0 0.45em; font-weight: 300; color: #cfcfcf; }
.loc-rec__g li:hover { color: #b08d57; }
.loc-rec__more { margin-top: 18px; font-size: 15px; font-weight: 600; color: #6f6f6f; text-align: right; }
@media (max-width: 760px) {
  .loc-rec__g { grid-template-columns: 1fr; gap: 8px; }
  .loc-rec__gl { padding-top: 0; }
  .loc-rec__g li { font-size: 24px; }
}

/* ---------- shared page footer (ABOUT, WORK, LOCATION, PARTNERS, IMPACT) ---------- */
.pg-ft { width: 100%; max-width: 1760px; margin: 0 auto; padding: 0 clamp(20px, 4vw, 64px) 28px; }
.pg-ft__line { height: 1px; background: #111; transform: scaleX(0); transform-origin: left; animation: line-in 1.4s cubic-bezier(0.19, 1, 0.22, 1) 0.7s forwards; }
@keyframes line-in { to { transform: none; } }
.pg-ft__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px clamp(32px, 6vw, 120px); padding-top: 26px; font-size: 14px; font-weight: 600; line-height: 1.7; }
.pg-ft__in p + p { margin-top: 14px; }
.pg-ft__in a:hover { color: #b08d57; }
.pg-ft__in .mute { font-weight: 500; color: #111; }
@media (max-width: 860px) { .pg-ft__in { grid-template-columns: 1fr; font-size: 13px; } }
/* the old-style pages (IMPACT) carry legacy footer rules for #ft-offices; keep this footer identical */
.pg-ft #ft-offices p { font-size: inherit; line-height: inherit; color: #111; }
.pg-ft #ft-offices b { display: inline; color: #111; }
body:not(.pg) .pg-ft { font-family: "Pretendard Variable", -apple-system, BlinkMacSystemFont, system-ui, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; letter-spacing: 0; }
@media (max-width: 640px) {
  body:not(.pg) .pg-ft { padding-bottom: 18px; }
  body:not(.pg) .pg-ft__in { gap: 10px; padding-top: 16px; font-size: 12px; line-height: 1.6; }
  body:not(.pg) .pg-ft__in p + p { margin-top: 6px; }
}

/* phone menu: centred while it fits, scrolls from the top when the screen is short (e.g. a phone held sideways) */
.nmnav { justify-content: flex-start; overflow-y: auto; overscroll-behavior: contain; }
.nmnav > :first-child { margin-top: auto; }
.nmnav > :last-child { margin-bottom: auto; }
.nmnav a { font-size: clamp(28px, min(11vw, 7vh), 64px); }

/* bigger touch area for the small footer links (looks the same) */
.pg-ft__in a { position: relative; }
.pg-ft__in a::after { content: ""; position: absolute; inset: -12px -6px; }

/* KR / EN switch only on the home page until the other pages have English copy */
.nh__lang, .nmnav__lang { display: none !important; }
