/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-weight: 300;
  font-size: clamp(15px, 1vw + 0.5rem, 17px);
  line-height: 1.55;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
::selection { background: #000; color: #fff; }

/* ===== Tokens ===== */
:root {
  --bg: #FAFAFA;
  --bg-alt: #F1F1EE;
  --fg: #0A0A0A;
  --fg-muted: #666666;
  --fg-dim: #B0B0B0;
  --inverse: #FFFFFF;
  --line: rgba(0,0,0,0.12);
  --line-strong: rgba(0,0,0,0.28);
  --container: 1320px;
  --pad-x: clamp(20px, 4vw, 56px);
  --section-y: clamp(80px, 12vw, 160px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ===== Layout ===== */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--pad-x);
  padding-right: var(--pad-x);
}

/* ===== Typography ===== */
.eyebrow {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-muted);
  font-weight: 400;
  margin-bottom: 24px;
}
.section-title {
  font-size: clamp(34px, 5vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 300;
  margin-bottom: 8px;
}
.section-head { margin-bottom: clamp(48px, 6vw, 96px); max-width: 900px; }

/* ===== Header ===== */
.header {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 22px 0;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.4s var(--ease), background 0.4s var(--ease), padding 0.4s var(--ease), backdrop-filter 0.4s var(--ease);
}
.header.is-scrolled {
  padding: 14px 0;
  border-bottom-color: var(--line);
  background: rgba(250,250,250,0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
/* over dark hero: white logo + nav */
.header .header__logo-img { color: #fff; transition: color 0.4s var(--ease); }
.header .nav__link { color: rgba(255,255,255,0.78); }
.header .nav__link:hover { color: #fff; }
.header .nav__link::after { background: #fff; }
.header .lang-toggle { color: rgba(255,255,255,0.7); }
.header .lang-toggle__option.is-active { color: #fff; }
.header .lang-toggle__sep { color: rgba(255,255,255,0.35); }
.header .menu-toggle span { background: #fff; }
/* after scroll: revert to dark */
.header.is-scrolled .header__logo-img { color: var(--fg); }
.header.is-scrolled .nav__link { color: var(--fg-muted); }
.header.is-scrolled .nav__link:hover { color: var(--fg); }
.header.is-scrolled .nav__link::after { background: var(--fg); }
.header.is-scrolled .lang-toggle { color: var(--fg-muted); }
.header.is-scrolled .lang-toggle__option.is-active { color: var(--fg); }
.header.is-scrolled .lang-toggle__sep { color: var(--fg-dim); }
.header.is-scrolled .menu-toggle span { background: var(--fg); }
.header__inner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding-left: clamp(8px, 1vw, 18px);
}
.header__logo {
  display: block; height: 144px;
  margin-left: -100px;
  transition: height 0.4s var(--ease), margin-left 0.4s var(--ease);
}
.header__logo-img {
  height: 100%; width: auto; color: var(--fg);
  filter: brightness(0) invert(1);
  transition: filter 0.4s var(--ease);
}
.header.is-scrolled .header__logo { height: 80px; margin-left: -50px; }
.header.is-scrolled .header__logo-img { filter: none; }

.nav { display: flex; gap: clamp(20px, 2.5vw, 40px); }
.nav__link {
  font-size: 14px;
  font-weight: 400;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
  position: relative;
  transition: color 0.3s var(--ease);
}
.nav__link::after {
  content: ''; position: absolute; bottom: -6px; left: 0;
  width: 0; height: 1px; background: var(--fg);
  transition: width 0.4s var(--ease);
}
.nav__link:hover { color: var(--fg); }
.nav__link:hover::after { width: 100%; }

.header__right { display: flex; align-items: center; gap: 16px; }

.lang-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; letter-spacing: 0.1em;
  color: var(--fg-muted);
  padding: 6px 0;
}
.lang-toggle__option {
  transition: color 0.3s var(--ease);
  padding: 2px 4px;
}
.lang-toggle__option.is-active { color: var(--fg); }
.lang-toggle__option:hover { color: var(--fg); }
.lang-toggle__sep { color: var(--fg-dim); }

.menu-toggle { display: none; width: 28px; height: 22px; flex-direction: column; justify-content: space-between; }
.menu-toggle span { display: block; height: 1px; background: var(--fg); transition: transform 0.4s var(--ease), opacity 0.3s var(--ease); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 10px;
  padding: 18px 36px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid transparent;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.btn--primary {
  background: var(--fg); color: var(--inverse);
}
.btn--primary:hover { background: transparent; color: var(--fg); border-color: var(--fg); }
.btn--ghost {
  border-color: var(--line-strong); color: var(--fg);
}
.btn--ghost:hover { background: var(--fg); color: var(--inverse); border-color: var(--fg); }

/* ===== Hero (full-bleed villa) ===== */
.hero {
  min-height: 100vh;
  display: flex; align-items: center;
  position: relative;
  padding: 140px 0 100px;
  overflow: hidden;
  color: #fff;
  background: #0A0A0A;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: url('assets/hero.jpg') center/cover no-repeat;
  z-index: 0;
  animation: heroZoom 12s var(--ease) forwards;
}
@keyframes heroZoom {
  from { transform: scale(1.08); }
  to { transform: scale(1); }
}
.hero::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(0,0,0,0.35) 0%, rgba(0,0,0,0.2) 30%, rgba(0,0,0,0.55) 100%),
    linear-gradient(90deg, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.15) 60%, rgba(0,0,0,0.0) 100%);
  z-index: 1;
  pointer-events: none;
}
.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1100px;
}
.hero__title {
  font-size: clamp(44px, 7vw, 108px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  font-weight: 200;
  margin-bottom: 32px;
  color: #fff;
}
.hero__subtitle {
  font-size: clamp(16px, 1.4vw, 22px);
  color: rgba(255, 255, 255, 0.85);
  max-width: 640px;
  line-height: 1.5;
  margin-bottom: 56px;
  font-weight: 300;
}
.hero .eyebrow { color: rgba(255, 255, 255, 0.78); }
.hero__cta { display: flex; gap: 16px; flex-wrap: wrap; }

.hero__scroll {
  position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  color: rgba(255,255,255,0.7);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  z-index: 3;
}
.hero__scroll-line {
  width: 1px; height: 40px; background: linear-gradient(to bottom, rgba(255,255,255,0.6), transparent);
  position: relative; overflow: hidden;
}
.hero__scroll-line::after {
  content: ''; position: absolute; top: -40px; left: 0; width: 100%; height: 40px;
  background: linear-gradient(to bottom, transparent, #fff);
  animation: scrollLine 2.4s var(--ease) infinite;
}
/* CTA on dark hero */
.hero .btn--primary { background: #fff; color: #000; border-color: #fff; }
.hero .btn--primary:hover { background: transparent; color: #fff; border-color: #fff; }
.hero .btn--ghost { border-color: rgba(255,255,255,0.45); color: #fff; }
.hero .btn--ghost:hover { background: #fff; color: #000; border-color: #fff; }
@keyframes scrollLine {
  0% { transform: translateY(0); }
  100% { transform: translateY(80px); }
}

/* ===== Problems ===== */
.problems { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.problems__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.problem {
  background: var(--bg);
  padding: clamp(28px, 3vw, 48px);
  display: flex; flex-direction: column;
  min-height: 320px;
  transition: background 0.4s var(--ease);
}
.problem:hover { background: var(--bg-alt); }
.problem__num {
  font-size: 13px;
  letter-spacing: 0.15em;
  color: var(--fg-dim);
  margin-bottom: 32px;
  font-weight: 500;
}
.problem__bad {
  font-size: clamp(18px, 1.6vw, 22px);
  font-weight: 400;
  color: var(--fg-muted);
  margin-bottom: 20px;
  line-height: 1.3;
  text-decoration: line-through;
  text-decoration-color: rgba(0,0,0,0.3);
  text-decoration-thickness: 1px;
}
.problem__good {
  font-size: clamp(15px, 1.1vw, 17px);
  color: var(--fg);
  line-height: 1.5;
  margin-top: auto;
}

/* ===== Services ===== */
.services { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.services__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.service {
  background: var(--bg);
  padding: clamp(36px, 4vw, 64px);
  display: flex; flex-direction: column;
  min-height: 280px;
  transition: background 0.4s var(--ease);
  position: relative;
  overflow: hidden;
}
.service::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 1px; background: var(--fg);
  transition: width 0.6s var(--ease);
}
.service:hover { background: var(--bg-alt); }
.service:hover::after { width: 100%; }
.service__num {
  font-size: 14px;
  color: var(--fg-dim);
  letter-spacing: 0.1em;
  margin-bottom: 32px;
}
.service__title {
  font-size: clamp(24px, 2.4vw, 36px);
  font-weight: 300;
  letter-spacing: -0.015em;
  margin-bottom: 20px;
}
.service__desc {
  color: var(--fg-muted);
  margin-bottom: 28px;
  max-width: 520px;
}
.service__price {
  margin-top: auto;
  font-size: 14px;
  letter-spacing: 0.08em;
  color: var(--fg);
  text-transform: uppercase;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

/* ===== Process ===== */
.process { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.process__list {
  display: flex; flex-direction: column;
}
.step {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: clamp(24px, 4vw, 80px);
  padding: clamp(28px, 3vw, 48px) 0;
  border-top: 1px solid var(--line);
  align-items: start;
  transition: opacity 0.4s var(--ease);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step__num {
  font-size: clamp(40px, 4vw, 64px);
  font-weight: 200;
  letter-spacing: -0.03em;
  color: var(--fg);
  font-feature-settings: "tnum";
}
.step__body { padding-top: 12px; }
.step__title {
  font-size: clamp(22px, 2vw, 30px);
  font-weight: 300;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}
.step__desc {
  color: var(--fg-muted);
  max-width: 640px;
  line-height: 1.5;
}

/* ===== Projects ===== */
.projects { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.projects__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.project { display: flex; flex-direction: column; gap: 24px; }
.project__visual {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--bg-alt);
  overflow: hidden;
  border: 1px solid var(--line);
}
.project__placeholder {
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(
      45deg,
      rgba(0,0,0,0.035) 0,
      rgba(0,0,0,0.035) 1px,
      transparent 1px,
      transparent 24px
    ),
    linear-gradient(135deg, #EFEFEC 0%, #F7F7F4 100%);
  transition: transform 0.8s var(--ease);
}
.project:hover .project__placeholder { transform: scale(1.04); }
.project__year {
  position: absolute; top: 20px; left: 24px;
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--fg-muted);
  font-weight: 500;
}
.project__title {
  font-size: clamp(18px, 1.4vw, 22px);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}
.project__info {
  font-size: 14px;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}

/* ===== About ===== */
.about { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.about__inner {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(40px, 6vw, 100px);
  align-items: start;
}
.about__left { position: sticky; top: 120px; }
.about__text {
  font-size: clamp(16px, 1.2vw, 20px);
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: 28px;
}
.about__text:nth-of-type(2) { color: var(--fg); }
.about__stats {
  margin-top: 48px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.stat {
  background: var(--bg);
  padding: 32px clamp(20px, 2vw, 32px);
}
.stat__num {
  font-size: clamp(36px, 4vw, 56px);
  font-weight: 200;
  letter-spacing: -0.03em;
  margin-bottom: 8px;
}
.stat__label {
  font-size: 13px;
  color: var(--fg-muted);
  letter-spacing: 0.05em;
}

/* ===== Contact ===== */
.contact { padding: var(--section-y) 0; border-top: 1px solid var(--line); }
.contact__inner { max-width: 1000px; }
.contact__lead {
  font-size: clamp(16px, 1.2vw, 19px);
  color: var(--fg-muted);
  max-width: 600px;
  margin-top: 24px;
  margin-bottom: 56px;
}
.contact__actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 80px;
}
.contact__btn {
  display: flex; align-items: center; gap: 24px;
  padding: 28px clamp(24px, 2.5vw, 40px);
  border: 1px solid var(--line-strong);
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease), color 0.3s var(--ease);
}
.contact__btn:hover {
  background: var(--fg);
  color: var(--inverse);
  border-color: var(--fg);
}
.contact__btn-icon {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.contact__btn-icon svg { width: 100%; height: 100%; }
.contact__btn-text { display: flex; flex-direction: column; flex: 1; gap: 2px; }
.contact__btn-label {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-muted);
  transition: color 0.3s var(--ease);
}
.contact__btn:hover .contact__btn-label { color: rgba(255,255,255,0.55); }
.contact__btn-sub {
  font-size: 18px;
  font-weight: 400;
  letter-spacing: 0.02em;
}
.contact__btn-arrow {
  font-size: 20px;
  transition: transform 0.3s var(--ease);
}
.contact__btn:hover .contact__btn-arrow { transform: translateX(6px); }

.contact__info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding-top: 48px;
  border-top: 1px solid var(--line);
}
.contact__info-item { display: flex; flex-direction: column; gap: 8px; }
.contact__info-label {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-muted);
}
.contact__info-value {
  font-size: 16px;
  color: var(--fg);
  line-height: 1.5;
  transition: color 0.3s var(--ease);
}
a.contact__info-value:hover { color: var(--fg-muted); }

/* ===== Footer ===== */
.footer { padding: 60px 0 40px; border-top: 1px solid var(--line); }
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.footer__logo { height: 32px; }
.footer__logo img { height: 100%; width: auto; color: var(--fg); }
.footer__col { display: flex; flex-direction: column; gap: 8px; }
.footer__col--right { align-items: flex-end; justify-self: end; }
.footer__label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 4px;
}
.footer__link, .footer__text {
  font-size: 14px;
  color: var(--fg);
  line-height: 1.5;
}
.footer__link { transition: color 0.3s var(--ease); }
.footer__link:hover { color: var(--fg-muted); }
.footer__copyright {
  font-size: 12px;
  color: var(--fg-muted);
  letter-spacing: 0.05em;
}

/* ===== Reveal animation ===== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .problems__grid { grid-template-columns: repeat(2, 1fr); }
  .projects__grid { grid-template-columns: repeat(2, 1fr); }
  .about__inner { grid-template-columns: 1fr; }
  .about__left { position: static; }
  .footer__inner { grid-template-columns: 1fr 1fr; }
  .footer__col--right { justify-self: start; align-items: flex-start; grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid var(--line); }
}

@media (max-width: 768px) {
  .nav { display: none; }
  .menu-toggle { display: flex; }
  .header__logo { height: 64px; margin-left: -40px; }
  .header.is-scrolled .header__logo { height: 44px; margin-left: -28px; }
  .hero { padding: 130px 0 80px; min-height: 88vh; }
  .hero__title { font-size: clamp(38px, 9vw, 62px); }
  .hero__cta { width: 100%; }
  .hero__cta .btn { flex: 1; min-width: 140px; padding: 16px 20px; }
  .hero__scroll { display: none; }
  .problems__grid { grid-template-columns: 1fr; }
  .services__grid { grid-template-columns: 1fr; }
  .projects__grid { grid-template-columns: 1fr; }
  .step { grid-template-columns: 60px 1fr; gap: 16px; }
  .step__num { font-size: 32px; }
  .about__stats { grid-template-columns: repeat(2, 1fr); }
  .contact__actions { grid-template-columns: 1fr; }
  .contact__info { grid-template-columns: 1fr; gap: 24px; }
  .footer__inner { grid-template-columns: 1fr; gap: 24px; }
  .footer__col--right { padding-top: 24px; border-top: 1px solid var(--line); }
}
