/* ==========================================================================
   YHRS Consulting LLC
   Brand colors are sampled from the logo and brochure headline.
   ========================================================================== */

:root {
  /* Brand */
  --teal: #165D7B;         /* logo "Y" + "S", HR Solutions bar; primary buttons */
  --teal-deep: #0F4862;    /* button hover */
  --sky: #6CAFE4;          /* logo accent on dark backgrounds */
  --blue: #4A7FB1;         /* focus ring, small icons */
  --navy: #254C77;         /* hero headline, CTA band */
  --navy-deep: #0D1B35;    /* footer */
  --black: #000000;        /* logo "HR" */

  /* Neutrals */
  --ink: #111A2B;
  --paper: #FFFFFF;
  --mist: #F2F6F9;
  --line: #DCE3EA;
  --muted: #535E6C;        /* 6.3:1 on white */
  --error: #B42318;
  --focus: #4A7FB1;

  /* Type: Inter as a free stand-in for Graphik */
  --font: "Inter", "Graphik", system-ui, -apple-system, "Segoe UI", sans-serif;
  --text-base: 1.0625rem;
  --text-sm: 0.9375rem;
  --text-lg: 1.1875rem;
  --h1: clamp(2.6rem, 1.4rem + 5vw, 5rem);
  --h2: clamp(1.9rem, 1.4rem + 2vw, 2.75rem);
  --h3: 1.1875rem;

  /* Layout */
  --container: 1200px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --section-y: clamp(4.5rem, 3rem + 6vw, 7.5rem);
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --header-h: 76px;
  --shadow-card: 0 1px 2px rgba(13, 27, 53, .06), 0 18px 44px -14px rgba(13, 27, 53, .28);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
[hidden] { display: none !important; } /* keeps hidden sections hidden even when a class sets display */
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: var(--teal); text-underline-offset: 3px; }
a:hover { color: var(--teal-deep); }

h1, h2 { font-weight: 700; letter-spacing: -0.025em; text-wrap: balance; }
h1 { font-size: var(--h1); line-height: 1; }
h2 { font-size: var(--h2); line-height: 1.12; }
h3 { font-size: var(--h3); line-height: 1.35; font-weight: 600; letter-spacing: -0.01em; }
p { text-wrap: pretty; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -100px; z-index: 100; background: var(--teal); color: #fff; padding: .75rem 1rem; border-radius: var(--radius-sm); }
.skip-link:focus { top: 1rem; color: #fff; }

.icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.icon-lg { width: 30px; height: 30px; stroke-width: 1.5; }

/* ---------- Logo (text placeholder until the real file arrives) ---------- */
.logo { display: inline-grid; justify-items: stretch; line-height: 1; }
.logo-word { font-weight: 800; font-size: 1.75rem; letter-spacing: -0.02em; color: var(--black); }
.logo-teal { color: var(--teal); }
.logo-bar {
  margin-top: 3px; padding: 3px 4px 2px;
  background: var(--teal); color: #fff;
  font-size: .5rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; text-align: center;
}
.logo-invert .logo-word { color: #fff; }
.logo-invert .logo-teal { color: var(--sky); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 48px; padding: .75rem 1.5rem;
  font: 600 1rem/1.2 var(--font);
  text-decoration: none; border-radius: var(--radius-sm); border: 1.5px solid transparent;
  cursor: pointer; transition: background-color .2s, color .2s, border-color .2s;
}
.btn-primary { background: var(--teal); color: #fff; }
.btn-primary:hover { background: var(--teal-deep); color: #fff; }
.btn-ghost { background: transparent; color: var(--teal); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--teal); color: var(--teal-deep); }
.btn-light { background: #fff; color: var(--navy-deep); }
.btn-light:hover { background: #E7F1FB; color: var(--navy-deep); }
.btn-sm { min-height: 44px; padding: .5rem 1.1rem; font-size: .9375rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand { display: inline-flex; text-decoration: none; }

.nav-menu { display: flex; align-items: center; gap: 2rem; }
.nav-menu a:not(.btn) {
  color: var(--ink); text-decoration: none; font-size: 1rem; font-weight: 500;
  padding: .5rem 0; border-bottom: 2px solid transparent; transition: border-color .2s, color .2s;
}
.nav-menu a:not(.btn):hover { color: var(--teal); border-bottom-color: var(--teal); }
.nav-toggle {
  display: none; width: 44px; height: 44px; place-items: center;
  border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; color: var(--ink); cursor: pointer;
}

/* ---------- Hero ---------- */
/* Full-bleed photo under a flat navy tint (no gradient), text set directly on it,
   numbers bar pinned to the bottom of the banner. */
.hero {
  position: relative; isolation: isolate;
  min-height: min(90vh, 880px);
  display: flex;
  padding-block: clamp(4rem, 9vw, 7rem) clamp(1.25rem, 3vw, 2.5rem);
  overflow: hidden; color: #fff;
}
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 35%; z-index: -2; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(13, 27, 53, .68); }
.hero-inner { display: flex; flex-direction: column; justify-content: space-between; gap: clamp(3rem, 7vw, 5.5rem); }
.hero-content { max-width: 760px; animation: card-in .7s cubic-bezier(.2, .7, .2, 1) both; }
.hero-title {
  text-transform: uppercase; font-weight: 800; letter-spacing: -0.02em; line-height: .98;
  color: #fff;
}
.hero-line { display: block; }
.hero-line-accent { color: var(--sky); }
.hero-lede { margin-top: 1.5rem; max-width: 36em; font-size: var(--text-lg); color: rgba(255, 255, 255, .88); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.25rem; }
.btn-sky { background: var(--sky); color: var(--navy-deep); }
.btn-sky:hover { background: #91C4EC; color: var(--navy-deep); }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .6); }
.btn-outline-light:hover { background: rgba(255, 255, 255, .12); border-color: #fff; color: #fff; }
.hero :focus-visible { outline-color: #fff; }

/* Numbers bar */
/* Stays hidden while any figure is still blank (data-to=""), so placeholders never go live. */
.stat-bar:has(.count[data-to=""]) { display: none; }
.stat-bar {
  display: grid; grid-template-columns: repeat(4, 1fr); margin: 0;
  background: rgba(13, 27, 53, .5);
  border: 1px solid rgba(255, 255, 255, .18); border-radius: var(--radius-lg);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.stat {
  display: flex; flex-direction: column-reverse; justify-content: flex-end; align-items: center; gap: .4rem;
  padding: 1.5rem 1rem; text-align: center;
  border-left: 1px solid rgba(255, 255, 255, .16);
}
.stat:first-child { border-left: 0; }
.stat dt { color: rgba(255, 255, 255, .8); font-size: .875rem; }
.stat-num {
  margin: 0; color: #fff;
  font-size: clamp(1.9rem, 1.4rem + 1.6vw, 2.6rem); font-weight: 700; line-height: 1; letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
/* Placeholder value: dashed so it can't be mistaken for a real figure */
.ph { padding: 0 .1em; border: 2px dashed currentColor; border-radius: 6px; opacity: .7; }

@keyframes card-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ---------- Sections ---------- */
.section { padding-block: var(--section-y); }
.section-head { max-width: 680px; margin-bottom: clamp(2.5rem, 4vw, 3.5rem); }
.section-head p { margin-top: 1rem; color: var(--muted); font-size: var(--text-lg); }

/* Problem */
.problem-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2.5rem, 6vw, 6rem); align-items: center; }
.problem-copy h2 { max-width: 15ch; }
.problem-copy .lead { margin-top: 1.5rem; font-size: 1.25rem; line-height: 1.55; }
.pain-list { margin-top: 2rem; display: grid; gap: .85rem; }
.pain-list li { display: flex; gap: .75rem; align-items: flex-start; color: var(--muted); }
.pain-list .icon { margin-top: .2rem; color: var(--blue); }
.problem-answer {
  margin-top: 2rem; padding-left: 1.25rem; border-left: 3px solid var(--teal);
  font-weight: 500; font-size: 1.125rem;
}
.problem-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-lg); }

/* Who we help: a growth sequence, so the cards step up in tone */
.who { background: var(--mist); }
.stage-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.stage { padding: 2rem; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); }
.stage:nth-child(2) { background: #E4EEF6; border-color: #E4EEF6; }
.stage:nth-child(3) { background: var(--teal); border-color: var(--teal); color: #fff; }
.stage-size { font-weight: 700; font-size: 1.5rem; letter-spacing: -0.02em; color: var(--teal); }
.stage:nth-child(3) .stage-size { color: #fff; }
.stage h3 { margin-top: 1.5rem; }
.stage p:last-child { margin-top: .5rem; font-size: var(--text-sm); color: var(--muted); }
.stage:nth-child(3) p:last-child { color: rgba(255, 255, 255, .86); }

/* Services */
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem 2.5rem; }
.service { display: grid; gap: 1rem; align-content: start; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.service .icon { color: var(--teal); }
.service p { margin-top: .4rem; color: var(--muted); font-size: var(--text-sm); }
/* HR Business Partnership is the core offer, so it takes the full first row */
.service-lead {
  grid-column: 1 / -1;
  grid-template-columns: auto 1fr; align-items: start; gap: 1.5rem;
  padding: 2rem; border: 0; border-radius: var(--radius); background: var(--mist);
}
.service-lead h3 { font-size: 1.5rem; }
.service-lead p { font-size: var(--text-base); max-width: 60ch; }
.service-lead .icon { width: 40px; height: 40px; }

/* CTA band */
.cta-band { background: var(--navy); color: #fff; padding-block: clamp(4rem, 8vw, 6rem); }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem 4rem; flex-wrap: wrap; }
.cta-inner h2 { max-width: 18ch; }
.cta-inner p { margin-top: 1rem; max-width: 40em; color: rgba(255, 255, 255, .86); font-size: var(--text-lg); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(2.5rem, 6vw, 6rem); align-items: start; }
.contact-info > p { margin-top: 1.25rem; color: var(--muted); font-size: var(--text-lg); max-width: 32em; }
.contact-details { margin-top: 2.25rem; display: grid; gap: 1.5rem; }
.contact-details li { display: flex; align-items: flex-start; gap: 1rem; }
.contact-details > li > .icon { margin-top: .15rem; color: var(--teal); }
.contact-label { font-size: .875rem; color: var(--muted); }
.contact-details a { color: var(--ink); font-weight: 500; text-decoration: none; }
.contact-details a:hover { color: var(--teal); text-decoration: underline; }
.wechat { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem 1rem; }
.copy-btn {
  display: inline-flex; align-items: center; gap: .4rem; min-height: 36px; padding: .35rem .75rem;
  font: 500 .875rem/1 var(--font); color: var(--teal);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; cursor: pointer;
  transition: border-color .2s, color .2s;
}
.copy-btn .icon { width: 16px; height: 16px; }
.copy-btn:hover { border-color: var(--teal); }
.copy-btn.is-copied { color: #146C43; border-color: #146C43; }

.contact-form { background: var(--mist); padding: clamp(1.5rem, 4vw, 2.5rem); border-radius: var(--radius-lg); display: grid; gap: 1.25rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.field { display: grid; gap: .4rem; }
.field label { font-weight: 500; font-size: .9375rem; }
.optional { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: .7rem .85rem;
  font: inherit; font-size: 1rem; color: var(--ink);
  background: #fff; border: 1px solid #B6C1CC; border-radius: var(--radius-sm);
  transition: border-color .15s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--muted); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 3px solid #D6E6F5; outline-offset: 0; border-color: var(--teal); }
.field [aria-invalid="true"] { border-color: var(--error); }
.field-error { color: var(--error); font-size: .875rem; }
.form-status { font-size: .9375rem; min-height: 1.5em; }
.form-status.is-success { color: #146C43; }
.form-status.is-error { color: var(--error); }

/* Footer */
.site-footer { background: var(--navy-deep); color: rgba(255, 255, 255, .8); padding-top: 3.5rem; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap; padding-bottom: 2.5rem; border-bottom: 1px solid rgba(255, 255, 255, .14); }
.footer-brand { display: flex; align-items: center; gap: 1.25rem; }
.footer-tag { font-size: .9375rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; }
.footer-links a { color: rgba(255, 255, 255, .86); text-decoration: none; display: inline-block; padding: .5rem 0; }
.footer-links a:hover { color: #fff; text-decoration: underline; }
.footer-legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 2rem; padding-block: 1.5rem 2rem; font-size: .8125rem; color: rgba(255, 255, 255, .7); }
.footer-legal a { color: rgba(255, 255, 255, .86); }
.site-footer :focus-visible { outline-color: #fff; }

/* ---------- Our clients ---------- */
.client-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1rem; }
.client-slot, .client-logo {
  display: grid; place-items: center; aspect-ratio: 3 / 2; padding: 1rem;
  border-radius: var(--radius);
}
.client-slot { border: 1.5px dashed #B6C1CC; color: var(--muted); font-size: .875rem; }
.client-logo img { max-height: 48px; width: auto; filter: grayscale(1); opacity: .75; transition: filter .2s, opacity .2s; }
.client-logo:hover img { filter: none; opacity: 1; }

/* ---------- 404 page ---------- */
.notfound { min-height: 100vh; display: grid; align-items: center; }
.notfound h1 { margin-top: 3rem; font-size: var(--h2); color: var(--navy); }
.notfound p { margin-top: 1rem; max-width: 36em; color: var(--muted); font-size: var(--text-lg); }

/* ---------- Language switch ---------- */
.nav-menu a.lang-switch {
  display: inline-grid; place-items: center; min-width: 44px; min-height: 36px; padding: .25rem .65rem;
  border: 1px solid var(--line); border-radius: 999px;
  font-size: .9375rem; font-weight: 500; color: var(--teal);
}
.nav-menu a.lang-switch:hover { border-color: var(--teal); color: var(--teal-deep); }

/* ---------- Chinese page ---------- */
:root:lang(zh) {
  --font: "Inter", "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --h1: clamp(2.25rem, 1.4rem + 3.6vw, 4rem);
}
:lang(zh) body { line-height: 1.75; }
:lang(zh) h1, :lang(zh) h2, :lang(zh) h3 { letter-spacing: 0; }
:lang(zh) h2 { line-height: 1.3; }
:lang(zh) .hero-title { line-height: 1.2; text-transform: none; font-weight: 700; }
:lang(zh) .problem-copy h2 { max-width: 11em; }
:lang(zh) .cta-inner h2 { max-width: 14em; }
:lang(zh) .stage-size { letter-spacing: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .nav-menu { gap: 1.25rem; }
  .contact-grid { grid-template-columns: 1fr; }
  .service-grid { grid-template-columns: 1fr 1fr; }
  .client-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 880px) {
  .nav-toggle { display: grid; }
  .nav-menu {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: .5rem var(--gutter) 1.5rem;
    box-shadow: 0 16px 30px -16px rgba(13, 27, 53, .25);
    visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity .2s, transform .2s, visibility 0s linear .2s;
  }
  .nav-menu.is-open { visibility: visible; opacity: 1; transform: none; transition: opacity .2s, transform .2s; }
  .nav-menu li a:not(.btn) { display: block; padding: .9rem 0; border-bottom: 1px solid var(--line); }
  .nav-menu li a:not(.btn):hover { border-bottom-color: var(--line); }
  .nav-menu .btn { margin-top: 1.25rem; width: 100%; }
  .nav-menu a.lang-switch { margin-top: 1.25rem; justify-self: start; display: inline-grid; padding: .5rem 1rem; border: 1px solid var(--line); }
  .nav-menu li:has(.lang-switch) { display: grid; }

  .problem-grid { grid-template-columns: 1fr; }
  .problem-photo { order: -1; }
  .stage-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  :root { --header-h: 64px; }
  .logo-word { font-size: 1.5rem; }
  .hero { min-height: 0; padding-top: 3.5rem; padding-bottom: 1rem; }
  .hero-bg { object-position: 70% 30%; }
  .hero-actions .btn { flex: 1 1 100%; }
  .stat-bar { grid-template-columns: 1fr 1fr; }
  .stat { padding: 1.25rem .75rem; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid rgba(255, 255, 255, .16); }
  .service-grid, .field-row { grid-template-columns: 1fr; }
  .service-grid { gap: 2rem; }
  .service-lead { grid-template-columns: 1fr; padding: 1.5rem; }
  .cta-inner .btn { width: 100%; }
  .client-grid { grid-template-columns: 1fr 1fr; }
}

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