/* Our Machines — Figma 229:16219 (1440 × 5231) */

/* ---- banner hero: the Figma banner has its text baked into the image.
   ≥900px: show the image as designed, real text kept for screen readers/SEO.
   <900px: image becomes a cropped background (right side, no baked text) and the real text is shown. ---- */
.banner-hero { position: relative; background: #2a0508; color: #fff; isolation: isolate; overflow: hidden; }
.banner-hero__img { width: 100%; height: auto; aspect-ratio: 1440 / 638; object-fit: cover; }
.banner-hero__text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.banner-hero__eyebrow { font: 500 15px/1.3 var(--font-th); text-transform: uppercase; margin: 0 0 8px; }
.banner-hero__title { font: 700 clamp(30px, 8vw, 44px)/1.05 var(--font-en); text-transform: uppercase; }
.banner-hero__title > span { display: block; }
.banner-hero__lead { font: 300 16px/1.5 var(--font-th); margin: 14px 0 0; max-width: 34em; }
.banner-hero__tags { font: 400 13px/1.5 var(--font-th); text-transform: uppercase; letter-spacing: .04em; margin: 14px 0 0; opacity: .9; }
@media (max-width: 899px) {
  .banner-hero { min-height: 100vw; display: flex; align-items: flex-end; }
  .banner-hero__img { position: absolute; inset: 0; z-index: -2; height: 100%; aspect-ratio: auto; object-position: 100% 50%; }
  .banner-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(40,4,8,.05) 0%, rgba(40,4,8,.55) 45%, rgba(30,3,6,.92) 100%); }
  .banner-hero__text { position: relative !important; width: 100%; height: auto; overflow: visible; clip: auto; white-space: normal; padding-top: 56px; padding-bottom: 36px; }
}

.accent { color: var(--red); }
.mc-rule { width: 50px; height: 3px; background: var(--red-dark); border: 0; margin: 0 0 14px; }
.mc-rule--center { width: 78px; margin: 0 auto 6px; }

/* ---- intro ---- */
.mc-intro { padding: 48px 0 26px; }
.mc-intro__title { font: 600 clamp(36px, 4.2vw, 60px)/1.3 var(--font-en); }
.mc-intro__sub { font: 600 clamp(22px, 2.8vw, 40px)/1.3 var(--font-en); margin: 0 0 30px; }
.mc-intro__text { max-width: 1208px; }
.mc-intro__text p { font-size: clamp(17px, 1.4vw, 20px); line-height: 1.5; margin-bottom: 1.5em; }
.mc-intro__text p:last-child { margin-bottom: 0; }

/* ---- machine cards ---- */
.mc-list { padding: 0 0 90px; }
.mc-list > .container { max-width: calc(1268px + 2 * var(--gutter)); }
.machine { display: grid; grid-template-columns: 560fr 708fr; min-height: 710px; background: #f2f2ef; border: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 16px); }
.machine + .machine { margin-top: 27px; }
.machine__img { width: 100%; height: 0; min-height: 100%; object-fit: cover; border-right: 1px solid var(--line); }
.machine__body { padding: 38px 30px 20px 40px; display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.machine__title { font: 700 clamp(28px, 3.05vw, 44px)/1.0 var(--font-en); }
.machine__title > span { display: block; }
.machine__tagline { font: italic 300 15px/1.4 var(--font-th); color: var(--red); margin: 6px 0 12px; }
.machine__desc p { font-size: 15px; line-height: 1.53; margin-bottom: 6px; }
.machine__label { font: 600 15px/1.4 var(--font-th); margin: 10px 0 8px; }
.machine__tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 9px 12px; }
.machine__tags li { background: var(--line); border: 1px solid #dadada; border-radius: 12px; color: #636363; font: 300 12px/22px var(--font-th); padding: 0 10px; }
.machine__features { width: 100%; display: flex; gap: 6px 12px; padding: 0 0 12px; border-bottom: 1px solid var(--line); }
.machine__features ul { list-style: none; margin: 0; padding: 0; flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.machine__features ul:first-child { flex-grow: 1.12; }
.machine__features li { position: relative; padding-left: 26px; font-size: 15px; line-height: 1.53; }
.machine__features li::before { content: ""; position: absolute; left: 3px; top: 4px; width: 16px; height: 16px; background: url("../../img/machines/check.svg") center/contain no-repeat; }
.machine__gallery { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 9px; }
.machine__gallery img { width: 97px; height: 97px; object-fit: cover; border: 1px solid var(--line); }

@media (max-width: 1100px) {
  .machine { grid-template-columns: 38% 1fr; }
  .machine__features { flex-direction: column; }
}
@media (max-width: 760px) {
  .mc-intro { padding-top: 40px; }
  .mc-list { padding-bottom: 56px; }
  .machine { grid-template-columns: 1fr; min-height: 0; }
  .machine__img { height: auto; aspect-ratio: 4 / 5; max-height: 520px; border-right: 0; border-bottom: 1px solid var(--line); }
  .machine__body { padding: 26px 18px 20px; }
  .machine__gallery img { width: 88px; height: 88px; }
}

/* ---- English page (html[lang="en"]): the banner's baked lead text is Thai, so the real text is shown at every
   width. <900px already uses the phone treatment above; >=900px the image stays full-bleed and a solid left-hand
   panel (fading out to the right) hides the baked text behind the real headline. Thai pages are unaffected. ---- */
@media (min-width: 900px) {
  html[lang="en"] .banner-hero { display: flex; align-items: center; min-height: clamp(440px, 44.3vw, 720px); }
  html[lang="en"] .banner-hero__img { position: absolute; inset: 0; z-index: -2; height: 100%; aspect-ratio: auto; object-position: 100% 50%; }
  html[lang="en"] .banner-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgb(42,5,8) 0%, rgb(42,5,8) 50%, rgba(42,5,8,.85) 58%, rgba(42,5,8,0) 72%); }
  html[lang="en"] .banner-hero__text { position: relative !important; width: 100%; height: auto; overflow: visible; clip: auto; white-space: normal; padding-top: 72px; padding-bottom: 72px; }
  html[lang="en"] .banner-hero__text > * { max-width: min(560px, 47vw); }
  html[lang="en"] .banner-hero__text > .banner-hero__title { max-width: 680px; }
  html[lang="en"] .banner-hero__eyebrow { font-size: 16px; margin-bottom: 14px; }
  html[lang="en"] .banner-hero__title { font-size: clamp(38px, 4vw, 58px); }
  html[lang="en"] .banner-hero__lead { font-size: clamp(17px, 1.4vw, 20px); margin-top: 20px; }
}
