:root {
  --rose: #b34b61;
  --wine: #6d2638;
  --ink: #2a2426;
  --muted: #6e6266;
  --paper: #fff9f6;
  --line: #ead9d2;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Microsoft JhengHei", "PingFang TC", Arial, sans-serif;
  background: var(--paper);
  line-height: 1.7;
}

a {
  color: inherit;
}

.nav {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 70px;
  padding: 14px clamp(18px, 5vw, 72px);
  background: rgba(255, 249, 246, .94);
  border-bottom: 1px solid rgba(179, 75, 97, .18);
  backdrop-filter: blur(12px);
}

.brand {
  color: var(--wine);
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 20px;
  margin-left: auto;
  color: var(--wine);
  font-weight: 700;
}

.nav-links a {
  text-decoration: none;
}

.language-switch {
  display: inline-flex;
  flex: 0 0 auto;
  overflow: hidden;
  border: 1px solid rgba(109, 38, 56, .22);
  border-radius: 6px;
  background: #fff;
}

.language-switch button {
  min-width: 38px;
  min-height: 34px;
  padding: 4px 10px;
  color: var(--wine);
  font: inherit;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  background: transparent;
  border: 0;
}

.language-switch button + button {
  border-left: 1px solid rgba(109, 38, 56, .16);
}

.language-switch button.active {
  color: #fff;
  background: var(--rose);
}

.hero {
  position: relative;
  min-height: 720px;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 120px 20px 60px;
  background: #3d1b25;
}

.slides,
.slide {
  position: absolute;
  inset: 0;
}

.slide {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 900ms ease;
}

.slide.active {
  opacity: 1;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(53, 18, 30, .76), rgba(53, 18, 30, .2));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1040px, 100%);
  color: #fff;
}

.eyebrow {
  margin: 0 0 6px;
  color: #ffe2e9;
  font-size: 28px;
  font-weight: 700;
}

.hero h1 {
  max-width: 850px;
  margin: 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.08;
}

.hero p:not(.eyebrow) {
  max-width: 720px;
  margin: 22px 0 30px;
  font-size: 21px;
}

.cta {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 10px 24px;
  color: #fff;
  background: var(--rose);
  border-radius: 6px;
  text-decoration: none;
  font-weight: 800;
}

.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
}

.principles article {
  min-height: 260px;
  padding: 42px 30px;
  background: #fff;
}

.principles h2,
.reason h2,
.content h2,
.cases h2,
.contact h2 {
  margin: 0 0 18px;
  color: var(--wine);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.2;
}

.principles h2 {
  font-size: 28px;
}

.section-inner {
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
}

.reason,
.cases {
  padding: 78px 0;
  color: #fff;
  background: linear-gradient(rgba(109, 38, 56, .88), rgba(109, 38, 56, .88)), url("../images/slider/hero-3.jpg") center/cover fixed;
}

.reason h2,
.cases h2 {
  color: #fff;
}

.reason p {
  max-width: 980px;
  font-size: 19px;
}

.content {
  padding: 84px 0;
  background: #fff9f6;
}

.content h3 {
  margin: 30px 0 8px;
  color: var(--rose);
  font-size: 24px;
}

.content p {
  color: var(--muted);
  font-size: 18px;
}

.service-blocks {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 20px;
  margin: 50px 0;
}

.service-blocks article,
.case-grid article {
  padding: 26px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.service-blocks h2 {
  font-size: 28px;
}

.portfolio-grid,
.case-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.portfolio-grid a {
  position: relative;
  min-height: 260px;
  overflow: hidden;
  border-radius: 8px;
  color: #fff;
  text-decoration: none;
  background: #32161e;
}

.portfolio-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: .84;
  transition: transform 300ms ease, opacity 300ms ease;
}

.portfolio-grid span {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  font-size: 20px;
  font-weight: 800;
  text-shadow: 0 2px 12px rgba(0, 0, 0, .5);
}

.portfolio-grid a:hover img {
  transform: scale(1.05);
  opacity: .68;
}

.case-grid article {
  display: flex;
  flex-direction: column;
  gap: 18px;
  color: var(--ink);
}

.case-grid p {
  margin: 0;
}

.case-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
  border: 5px solid #fff0f3;
}

.contact {
  padding: 78px 0;
  text-align: center;
  background: #fff;
}

.contact .lead {
  color: var(--rose);
  font-size: 24px;
  font-weight: 800;
}

.contact h3 {
  margin: 30px 0 18px;
  color: var(--wine);
  font-size: 30px;
}

.contact p {
  margin: 8px 0;
  font-size: 22px;
}

footer {
  padding: 26px 18px;
  color: #fff;
  text-align: center;
  background: var(--wine);
}

@media (max-width: 900px) {
  .nav {
    align-items: center;
    flex-direction: column;
    text-align: center;
  }

  .nav-links {
    justify-content: center;
    margin-left: 0;
    width: 100%;
  }

  .language-switch {
    margin-top: -4px;
  }

  .hero {
    min-height: 640px;
  }

  .principles,
  .service-blocks,
  .portfolio-grid,
  .case-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-blocks article:first-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 560px) {
  .brand {
    white-space: normal;
  }

  .hero {
    min-height: 620px;
  }

  .principles,
  .service-blocks,
  .portfolio-grid,
  .case-grid {
    grid-template-columns: 1fr;
  }

  .contact p {
    font-size: 18px;
  }
}
