/*
Theme Name: YuenChi Intelligence
Theme URI: https://yuenchi.hk
Author: YuenChi Global Intelligence
Description: Bilingual corporate theme for YuenChi Global Intelligence.
Version: 1.0.0
Text Domain: yuenchi
*/

:root {
  --ink: #10231f;
  --ink-soft: #40534e;
  --paper: #f6f5ef;
  --paper-deep: #e9eee8;
  --white: #ffffff;
  --accent: #ceff4a;
  --accent-deep: #a9dc27;
  --teal: #155d54;
  --line: rgba(16, 35, 31, 0.14);
  --shadow: 0 24px 70px rgba(18, 46, 39, 0.12);
  --radius: 24px;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }
.wrap { width: min(calc(100% - 40px), var(--max)); margin-inline: auto; }
.section { padding: 112px 0; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 18px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--accent-deep);
}
.display {
  margin: 0;
  font-family: "DM Sans", Inter, sans-serif;
  font-size: clamp(46px, 7.2vw, 98px);
  line-height: .98;
  letter-spacing: -.065em;
}
.section-title {
  margin: 0;
  font-family: "DM Sans", Inter, sans-serif;
  font-size: clamp(34px, 4.4vw, 58px);
  line-height: 1.05;
  letter-spacing: -.045em;
}
.lead { color: var(--ink-soft); font-size: clamp(17px, 1.6vw, 21px); }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  font-weight: 750;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.button:hover { transform: translateY(-2px); background: var(--teal); }
.button-light { border-color: var(--white); background: var(--white); color: var(--ink); }
.button-ghost { background: transparent; color: var(--ink); }
.button-ghost:hover { background: var(--ink); color: var(--white); }

.site-header {
  position: fixed;
  z-index: 50;
  top: 0;
  left: 0;
  width: 100%;
  border-bottom: 1px solid transparent;
  transition: background .25s ease, border-color .25s ease;
}
.site-header.scrolled {
  border-color: var(--line);
  background: rgba(246, 245, 239, .88);
  backdrop-filter: blur(18px);
}
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 82px; }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 850; letter-spacing: -.025em; }
.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 50% 50% 50% 12%;
  background: var(--ink);
  color: var(--accent);
  font-size: 14px;
}
.brand-sub { display: block; color: var(--ink-soft); font-size: 9px; letter-spacing: .18em; text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: 30px; font-size: 14px; font-weight: 700; }
.nav-links a:not(.button) { position: relative; }
.nav-links a:not(.button)::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -6px;
  left: 0;
  height: 2px;
  background: var(--accent-deep);
  transform: scaleX(0);
  transition: transform .2s ease;
}
.nav-links a:hover::after { transform: scaleX(1); }
.lang-switch {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}
.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
}
.menu-toggle span { display: block; width: 18px; height: 2px; margin: 5px auto; background: var(--ink); }

.hero {
  position: relative;
  min-height: 100svh;
  padding: 148px 0 70px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 58vw;
  height: 58vw;
  border: 1px solid rgba(21, 93, 84, .16);
  border-radius: 50%;
}
.hero::after {
  content: "";
  position: absolute;
  top: 21%;
  right: 8%;
  width: 24vw;
  height: 24vw;
  border-radius: 50% 50% 50% 10%;
  background: var(--accent);
  filter: blur(.2px);
  transform: rotate(16deg);
}
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 44px; align-items: end; }
.hero-copy { max-width: 850px; }
.hero .display span { color: var(--teal); }
.hero-intro { max-width: 600px; margin: 32px 0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-proof {
  position: relative;
  z-index: 2;
  align-self: end;
  max-width: 370px;
  margin-left: auto;
  padding: 28px;
  border: 1px solid rgba(255,255,255,.45);
  border-radius: var(--radius);
  background: rgba(16,35,31,.92);
  box-shadow: var(--shadow);
  color: var(--white);
}
.hero-proof strong { display: block; margin-bottom: 22px; font-size: 14px; letter-spacing: .05em; text-transform: uppercase; }
.signal { display: flex; gap: 12px; align-items: center; padding: 13px 0; border-top: 1px solid rgba(255,255,255,.15); }
.signal-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 6px rgba(206,255,74,.1); }
.signal small { display: block; color: rgba(255,255,255,.62); }
.hero-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 92px; }
.hero-meta div { padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; font-weight: 750; }
.hero-meta span { display: block; margin-bottom: 5px; color: var(--ink-soft); font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .12em; }

.marquee { overflow: hidden; border-block: 1px solid var(--line); background: var(--white); }
.marquee-track { display: flex; width: max-content; padding: 17px 0; animation: ticker 24s linear infinite; }
.marquee-item { display: flex; align-items: center; gap: 22px; padding-right: 22px; font-size: 13px; font-weight: 850; letter-spacing: .11em; text-transform: uppercase; white-space: nowrap; }
.marquee-item::after { content: "✦"; color: var(--accent-deep); }
@keyframes ticker { to { transform: translateX(-50%); } }

.split-head { display: grid; grid-template-columns: .9fr 1.1fr; gap: 80px; align-items: end; margin-bottom: 58px; }
.split-head .lead { max-width: 610px; margin: 0; }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.service-card {
  position: relative;
  min-height: 380px;
  padding: 30px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  transition: transform .25s ease, box-shadow .25s ease;
}
.service-card:hover { transform: translateY(-7px); box-shadow: var(--shadow); }
.service-index { color: var(--teal); font-size: 12px; font-weight: 850; letter-spacing: .14em; }
.service-card h3 { margin: 75px 0 16px; font-size: 28px; line-height: 1.1; letter-spacing: -.035em; }
.service-card p { color: var(--ink-soft); }
.service-card ul { padding: 0; margin: 28px 0 0; list-style: none; font-size: 14px; font-weight: 700; }
.service-card li { padding: 9px 0; border-top: 1px solid var(--line); }
.service-card.featured { background: var(--ink); color: var(--white); }
.service-card.featured p { color: rgba(255,255,255,.68); }
.service-card.featured li { border-color: rgba(255,255,255,.14); }
.service-card.featured .service-index { color: var(--accent); }

.approach { background: var(--ink); color: var(--white); }
.approach .eyebrow { color: var(--accent); }
.approach-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 90px; }
.approach-intro { position: sticky; top: 130px; align-self: start; }
.approach-intro p { max-width: 440px; color: rgba(255,255,255,.66); }
.steps { counter-reset: step; }
.step {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 24px;
  padding: 36px 0;
  border-top: 1px solid rgba(255,255,255,.16);
}
.step:last-child { border-bottom: 1px solid rgba(255,255,255,.16); }
.step-num { display: grid; width: 52px; height: 52px; place-items: center; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; color: var(--accent); font-weight: 800; }
.step h3 { margin: 0 0 8px; font-size: 24px; }
.step p { margin: 0; color: rgba(255,255,255,.6); }

.outcomes { position: relative; overflow: hidden; }
.outcomes::after {
  content: "";
  position: absolute;
  right: -180px;
  bottom: -250px;
  width: 520px;
  height: 520px;
  border: 90px solid var(--accent);
  border-radius: 50%;
  opacity: .34;
}
.outcome-grid { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 56px; }
.outcome { padding: 28px; border-top: 2px solid var(--ink); background: rgba(255,255,255,.55); }
.outcome strong { display: block; margin-bottom: 52px; font-size: clamp(42px, 5vw, 68px); line-height: 1; letter-spacing: -.05em; }
.outcome p { margin: 0; color: var(--ink-soft); font-weight: 650; }

.contact { padding: 34px 0 100px; }
.contact-shell { display: grid; grid-template-columns: .85fr 1.15fr; gap: 70px; padding: 62px; border-radius: 34px; background: var(--teal); color: var(--white); box-shadow: var(--shadow); }
.contact-copy p { color: rgba(255,255,255,.7); }
.contact-note { margin-top: 45px; color: var(--accent); font-size: 13px; font-weight: 800; }
.inquiry-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field-full { grid-column: 1 / -1; }
.field label { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.field input, .field select, .field textarea {
  width: 100%;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 12px;
  outline: 0;
  background: rgba(255,255,255,.09);
  color: var(--white);
}
.field input, .field select { height: 52px; padding: 0 15px; }
.field textarea { min-height: 120px; padding: 14px 15px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); }
.field option { color: var(--ink); }
.form-footer { display: flex; grid-column: 1 / -1; gap: 14px; align-items: center; margin-top: 7px; }
.form-status { color: var(--accent); font-size: 13px; font-weight: 700; }

.site-footer { padding: 30px 0; border-top: 1px solid var(--line); }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 30px; color: var(--ink-soft); font-size: 13px; }
.footer-links { display: flex; gap: 22px; }

[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
[data-reveal].revealed { opacity: 1; transform: none; }

@media (max-width: 900px) {
  .section { padding: 82px 0; }
  .menu-toggle { display: block; }
  .nav-links {
    position: fixed;
    inset: 82px 0 auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 28px 20px 38px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
  }
  .menu-open .nav-links { display: flex; }
  .nav-links .button { width: 100%; }
  .hero { min-height: auto; padding-top: 130px; }
  .hero-grid, .split-head, .approach-grid, .contact-shell { grid-template-columns: 1fr; gap: 42px; }
  .hero::after { top: 12%; right: -12%; width: 45vw; height: 45vw; opacity: .45; }
  .hero-proof { max-width: 100%; margin: 0; }
  .hero-meta { margin-top: 52px; }
  .service-grid, .outcome-grid { grid-template-columns: 1fr; }
  .service-card { min-height: auto; }
  .service-card h3 { margin-top: 45px; }
  .approach-intro { position: static; }
  .contact-shell { padding: 38px 24px; }
}

@media (max-width: 580px) {
  .wrap { width: min(calc(100% - 28px), var(--max)); }
  .brand-sub { display: none; }
  .hero { padding-top: 118px; }
  .hero-actions .button { width: 100%; }
  .hero-meta { grid-template-columns: 1fr; gap: 0; }
  .hero-meta div { padding-bottom: 14px; }
  .step { grid-template-columns: 52px 1fr; gap: 14px; }
  .inquiry-form { grid-template-columns: 1fr; }
  .field-full { grid-column: auto; }
  .form-footer { grid-column: auto; flex-direction: column; align-items: stretch; }
  .footer-row { align-items: flex-start; flex-direction: column; }
}

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