/* ============================================================
   Westmark – Redesign
   Warm & premium editorial homepage
   ============================================================ */

:root {
  /* Brand */
  --red:        #e4022e;
  --red-deep:   #be0226;

  /* Warm neutrals */
  --cream:      #f7f0e6;
  --cream-2:    #f1e7d8;
  --paper:      #fffdf9;
  --sand:       #ece0cd;
  --ink:        #2a221d;
  --ink-soft:   #6f6357;
  --espresso:   #221a15;
  --line:       rgba(42, 34, 29, .12);

  /* Type */
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* Layout */
  --wrap: 1240px;
  --gap: clamp(16px, 3vw, 32px);
  --radius: 18px;
  --shadow: 0 18px 50px -22px rgba(42, 34, 29, .35);
  --header-h: 76px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; padding: 0; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.08; letter-spacing: -.01em; }

.wrap { width: min(var(--wrap), 100% - 2 * clamp(18px, 5vw, 56px)); margin-inline: auto; }
.sr-only, .skip {
  position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip:focus {
  position: fixed; top: 12px; left: 12px; width: auto; height: auto; clip: auto;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; z-index: 200;
}

/* ---------- Shared bits ---------- */
.eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: .76rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 18px;
}
.eyebrow--light { color: #ffd9c7; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: .95em 1.7em;
  border-radius: 100px;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .01em;
  transition: transform .25s ease, background .25s ease, color .25s ease, box-shadow .25s ease;
  will-change: transform;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--red); color: #fff; box-shadow: 0 12px 24px -12px rgba(228,2,46,.7); }
.btn--primary:hover { background: var(--red-deep); transform: translateY(-2px); }
.btn--ghost { color: #fff; border: 1.5px solid rgba(255,255,255,.6); }
.btn--ghost:hover { background: rgba(255,255,255,.14); border-color: #fff; }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: var(--espresso); transform: translateY(-2px); }

.section { padding: clamp(64px, 9vw, 120px) 0; }
.section__head { max-width: 640px; margin-bottom: clamp(36px, 5vw, 60px); }
.section__title { font-size: clamp(1.9rem, 4vw, 3rem); }
.section__sub { color: var(--ink-soft); font-size: 1.08rem; margin-top: 18px; }

/* ---------- Utility bar ---------- */
.utilitybar {
  background: var(--espresso);
  color: #e9ddcd;
  font-size: .82rem;
}
.utilitybar__inner { display: flex; align-items: center; justify-content: space-between; min-height: 38px; gap: 16px; }
.utilitybar__claim { display: flex; align-items: center; gap: 9px; letter-spacing: .02em; }
.utilitybar .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 3px rgba(228,2,46,.25); }
.utilitybar__links { display: flex; align-items: center; gap: 22px; }
.utilitybar__links a { opacity: .85; transition: opacity .2s; }
.utilitybar__links a:hover { opacity: 1; }
.lang { display: inline-flex; gap: 2px; }
.lang__btn { font-size: .8rem; opacity: .55; padding: 2px 5px; border-radius: 6px; transition: .2s; }
.lang__btn:hover { opacity: .9; }
.lang__btn[aria-current="true"] { opacity: 1; color: #fff; font-weight: 600; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(247, 240, 230, .82);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s ease, background .3s ease;
}
.header.is-stuck { box-shadow: 0 10px 30px -18px rgba(42,34,29,.4); background: rgba(250, 246, 239, .94); }
.header__inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 24px; }
.brand img { height: 30px; width: auto; }
.nav { display: flex; gap: clamp(14px, 2vw, 30px); }
.nav a {
  position: relative; font-weight: 500; font-size: .98rem; padding: 6px 2px; color: var(--ink);
}
.nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%;
  background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .28s ease;
}
.nav a:hover::after { transform: scaleX(1); }

.header__tools { display: flex; align-items: center; gap: 6px; }
.iconbtn {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
  position: relative; transition: background .2s, color .2s;
}
.iconbtn:hover { background: rgba(42,34,29,.07); }
.iconbtn svg { width: 21px; height: 21px; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.badge {
  position: absolute; top: 4px; right: 3px; min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--red); color: #fff; border-radius: 100px; font-size: .66rem; font-weight: 700;
  display: grid; place-items: center; font-family: var(--sans);
}
.burger { display: none; flex-direction: column; gap: 5px; width: 42px; height: 42px; align-items: center; justify-content: center; }
.burger span { width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: .3s; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Mobile nav ---------- */
.mobilenav {
  position: fixed; inset: 0 0 0 auto; width: min(320px, 84vw); z-index: 99;
  background: var(--paper); padding: calc(var(--header-h) + 28px) 28px 28px;
  display: flex; flex-direction: column; gap: 4px;
  transform: translateX(100%); transition: transform .35s cubic-bezier(.4,0,.2,1);
  box-shadow: -20px 0 60px -30px rgba(0,0,0,.5);
}
.mobilenav.is-open { transform: translateX(0); }
.mobilenav a { padding: 13px 4px; border-bottom: 1px solid var(--line); font-weight: 500; font-size: 1.05rem; }
.mobilenav__cta { margin-top: 16px; border: none !important; background: var(--red); color: #fff; text-align: center; border-radius: 100px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: clamp(540px, 82vh, 760px);
  display: flex; align-items: flex-end;
  overflow: hidden;
}
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 50%; }
.hero__scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(34,26,21,.86) 0%, rgba(34,26,21,.5) 40%, rgba(34,26,21,0) 72%),
    linear-gradient(0deg, rgba(34,26,21,.55), rgba(34,26,21,0) 45%);
}
.hero__inner { position: relative; padding-bottom: clamp(54px, 8vw, 96px); padding-top: 90px; }
.hero__content { max-width: 620px; color: #fff; }
.hero__title {
  font-size: clamp(2.6rem, 6.4vw, 5rem);
  font-weight: 600;
  letter-spacing: -.02em;
  text-shadow: 0 2px 30px rgba(0,0,0,.3);
}
.hero__lead { font-size: clamp(1.05rem, 1.6vw, 1.3rem); margin-top: 22px; max-width: 520px; color: rgba(255,255,255,.92); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero__scroll {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%);
  width: 26px; height: 42px; border: 2px solid rgba(255,255,255,.7); border-radius: 16px; z-index: 2;
}
.hero__scroll span {
  position: absolute; top: 8px; left: 50%; width: 4px; height: 8px; background: #fff; border-radius: 4px;
  transform: translateX(-50%); animation: scrolldot 1.8s infinite;
}
@keyframes scrolldot { 0% { opacity: 0; transform: translate(-50%, 0); } 40% { opacity: 1; } 80% { opacity: 0; transform: translate(-50%, 12px); } 100% { opacity: 0; } }

/* ---------- Values ---------- */
.values { background: var(--paper); border-bottom: 1px solid var(--line); }
.values__grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: clamp(20px, 3vw, 40px);
  padding: clamp(40px, 5vw, 64px) 0;
}
.value { position: relative; padding-left: 2px; }
.value + .value::before { content: none; }
.value__icon { width: 34px; height: 34px; fill: none; stroke: var(--red); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 16px; }
.value h3 { font-size: 1.2rem; margin-bottom: 7px; }
.value p { color: var(--ink-soft); font-size: .95rem; line-height: 1.55; }

/* ---------- Categories ---------- */
.cats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(14px, 1.6vw, 22px);
}
.cat {
  position: relative; overflow: hidden; border-radius: var(--radius);
  min-height: 290px; display: flex; align-items: flex-end;
  background: var(--sand); box-shadow: var(--shadow);
  isolation: isolate;
}
.cat--wide { grid-column: span 2; }
.cat img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2;
  transition: transform .7s cubic-bezier(.2,.6,.2,1);
}
.cat::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(0deg, rgba(28,21,17,.82) 2%, rgba(28,21,17,.28) 42%, rgba(28,21,17,0) 70%);
  transition: opacity .4s;
}
.cat:hover img { transform: scale(1.06); }
.cat__body { padding: clamp(18px, 2vw, 26px); color: #fff; }
.cat__title { font-size: clamp(1.3rem, 2vw, 1.75rem); }
.cat--wide .cat__title { font-size: clamp(1.5rem, 2.4vw, 2.1rem); }
.cat__desc { font-size: .92rem; color: rgba(255,255,255,.82); margin-top: 4px; }
.cat__link {
  display: inline-flex; align-items: center; gap: 7px; margin-top: 14px;
  font-weight: 600; font-size: .9rem; color: #fff;
  opacity: 0; transform: translateY(8px); transition: .35s ease;
}
.cat__link em { font-style: normal; transition: transform .3s; }
.cat:hover .cat__link { opacity: 1; transform: translateY(0); }
.cat:hover .cat__link em { transform: translateX(4px); }
.cat__flag {
  position: absolute; top: 16px; left: 16px; z-index: 1;
  background: var(--red); color: #fff; font-size: .72rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; padding: 6px 12px; border-radius: 100px;
}

/* ---------- Heritage ---------- */
.heritage { position: relative; overflow: hidden; color: #fff; padding: clamp(70px, 10vw, 130px) 0; }
.heritage__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.heritage__scrim { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(34,26,21,.9) 0%, rgba(34,26,21,.7) 50%, rgba(110,20,30,.55) 100%); }
.heritage__inner { position: relative; max-width: 720px; }
.heritage__title { font-size: clamp(2.4rem, 6vw, 4.4rem); }
.heritage__title span { color: #ffd9c7; font-style: italic; }
.heritage__lead { font-size: clamp(1.05rem, 1.6vw, 1.28rem); margin-top: 22px; color: rgba(255,255,255,.92); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 48px; }
.stat { border-left: 2px solid rgba(255,217,199,.5); padding-left: 16px; }
.stat strong { display: block; font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 600; }
.stat span { font-size: .85rem; color: rgba(255,255,255,.8); }

/* ---------- Split (sustainability) ---------- */
.split__grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.split__media { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.split__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.split__tag {
  position: absolute; bottom: 16px; left: 16px;
  background: rgba(255,253,249,.92); color: var(--ink); font-size: .78rem; font-weight: 600;
  padding: 7px 14px; border-radius: 100px; backdrop-filter: blur(4px);
}
.split__text p { color: var(--ink-soft); font-size: 1.05rem; margin-top: 16px; }
.ticks { margin: 24px 0 30px; display: grid; gap: 12px; }
.ticks li { position: relative; padding-left: 32px; font-weight: 500; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--red);
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='white' d='M20 6 9 17l-5-5'/></svg>") center / 13px no-repeat;
          mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path fill='white' d='M20 6 9 17l-5-5'/></svg>") center / 13px no-repeat;
  box-shadow: 0 0 0 5px rgba(228,2,46,.12);
}

/* ---------- Stories ---------- */
.stories { display: grid; grid-template-columns: 1.6fr 1fr; grid-template-rows: auto auto; gap: clamp(16px, 2vw, 26px); }
.story {
  background: var(--paper); border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); transition: transform .3s ease, box-shadow .3s ease;
  display: flex; flex-direction: column;
}
.story:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.story--feature { grid-row: span 2; }
.story--feature .story__media { aspect-ratio: 16 / 11; overflow: hidden; }
.story--feature .story__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.story--feature:hover .story__media img { transform: scale(1.04); }
.story__body { padding: clamp(20px, 2.4vw, 30px); }
.story__cat { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--red); margin-bottom: 12px; }
.story h3 { font-size: clamp(1.25rem, 1.8vw, 1.6rem); margin-bottom: 10px; }
.story p { color: var(--ink-soft); font-size: .97rem; }
.textlink { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: var(--ink); margin-top: 16px; }
.textlink em { font-style: normal; transition: transform .3s; }
.textlink:hover { color: var(--red); }
.textlink:hover em { transform: translateX(4px); }

/* ---------- CTA / newsletter ---------- */
.cta { background: var(--red); color: #fff; padding: clamp(48px, 6vw, 84px) 0 clamp(28px, 3vw, 40px); }
.cta__inner { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 4vw, 56px); align-items: center; }
.cta__text h2 { font-size: clamp(1.8rem, 3.4vw, 2.8rem); }
.cta__text p { margin-top: 12px; color: rgba(255,255,255,.9); font-size: 1.05rem; }
.cta__form { display: flex; gap: 10px; flex-wrap: wrap; }
.cta__form input {
  flex: 1; min-width: 220px; padding: 1em 1.2em; border-radius: 100px; border: none;
  font-size: 1rem; background: rgba(255,255,255,.96); color: var(--ink);
}
.cta__form input:focus { outline: 3px solid rgba(255,255,255,.5); }
.cta__form .btn--primary { background: var(--ink); box-shadow: none; }
.cta__form .btn--primary:hover { background: var(--espresso); }
.cta__dealer { margin-top: 28px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.25); font-size: .95rem; color: rgba(255,255,255,.92); }
.cta__dealer a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Footer ---------- */
.footer { background: var(--espresso); color: #cdbfae; padding: clamp(56px, 7vw, 88px) 0 36px; font-size: .92rem; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: clamp(28px, 4vw, 56px); }
.footer__logo { height: 46px; width: auto; margin-bottom: 18px; }
.footer__brand p { line-height: 1.7; }
.footer__phone { display: inline-block; margin-top: 14px; color: #fff; font-weight: 600; font-size: 1.05rem; }
.footer__col h4 { font-family: var(--sans); font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; color: #fff; margin-bottom: 16px; }
.footer__col a { display: block; padding: 5px 0; transition: color .2s, padding-left .2s; }
.footer__col a:hover { color: #fff; padding-left: 4px; }
.footer__bottom {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
  margin-top: clamp(40px, 5vw, 60px); padding-top: 26px; border-top: 1px solid rgba(255,255,255,.12); font-size: .85rem;
}
.footer__legal { display: flex; gap: 22px; }
.footer__legal a:hover { color: #fff; }
.footer__social { display: flex; gap: 10px; }
.footer__social a { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.1); display: grid; place-items: center; transition: background .25s, transform .25s; }
.footer__social a:hover { background: var(--red); transform: translateY(-2px); }
.footer__social img { width: 16px; height: 16px; filter: brightness(0) invert(1); opacity: .9; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.cats .cat { transition-delay: calc(var(--i, 0) * 60ms); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .nav { display: none; }
  .burger { display: flex; }
  .cats { grid-template-columns: repeat(2, 1fr); }
  .cat--wide { grid-column: span 2; }
  .split__grid { grid-template-columns: 1fr; }
  .stories { grid-template-columns: 1fr; }
  .story--feature { grid-row: auto; }
  .values__grid { grid-template-columns: repeat(2, 1fr); row-gap: 36px; }
  .cta__inner { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
  .utilitybar__claim { display: none; }
  .utilitybar__inner { justify-content: center; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 24px 18px; }
  .cats { grid-template-columns: 1fr; }
  .cat--wide { grid-column: span 1; }
  .cat { min-height: 240px; }
  .cat__link { opacity: 1; transform: none; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom { justify-content: center; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__scroll span { animation: none; }
  .cat img, .story__media img { transition: none; }
}
