/* =====================================================================
   Hardware landing page (/products/hardware/)
   Layout + animations. Header/menu styles live in /css/bmv-header.css.
===================================================================== */
:root {
    --hw-green: #0d5c2f;
    --hw-green-dark: #094522;
    --hw-green-deep: #0b3d22;
    --hw-gold: #c9a24d;
    --hw-gold-soft: #f1d79a;
    --hw-ink: #1f2421;
    --hw-text: #4b524e;
    --hw-cream: #f7f2ea;
    --hw-line: #e9e5dd;
    --hw-serif: "Noto Serif", Georgia, "Times New Roman", serif;
    --hw-sans: "Noto Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
    --hw-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --hw-ease-io: cubic-bezier(0.65, 0, 0.35, 1);
    --hw-gutter: clamp(16px, 4vw, 56px);
}

body { margin: 0; background: #ffffff; color: var(--hw-ink); font-family: var(--hw-sans); }
.hw-page { overflow-x: clip; font-family: var(--hw-sans); }
.hw-page *, .hw-page *::before, .hw-page *::after { box-sizing: border-box; }
.hw-page img { max-width: 100%; display: block; }
.hw-container { width: min(100% - 2 * var(--hw-gutter), 1360px); margin-inline: auto; }

/* ---------- Shared bits ---------- */
.hw-eyebrow {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0 0 14px;
    color: var(--hw-ink);
    font-size: clamp(11.5px, 0.85vw, 14px);
    font-weight: 600;
    letter-spacing: 0.32em;
    text-transform: uppercase;
}
.hw-eyebrow-line {
    display: inline-block;
    width: 46px;
    height: 2px;
    background: var(--hw-green);
    transform-origin: left;
}
.hw-h2 {
    margin: 0 0 16px;
    font-family: var(--hw-serif);
    font-size: clamp(30px, 3.1vw, 50px);
    font-weight: 600;
    line-height: 1.12;
    letter-spacing: -0.01em;
    color: var(--hw-ink);
}
.hw-text { margin: 0; color: var(--hw-text); font-size: clamp(15px, 1.1vw, 18px); line-height: 1.6; }

.hw-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 52px;
    padding: 0 28px;
    border-radius: 8px;
    border: 1.5px solid var(--hw-green);
    font-family: var(--hw-sans);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none !important;
    overflow: hidden;
    isolation: isolate;
    transition: color 0.45s var(--hw-ease), border-color 0.45s var(--hw-ease), transform 0.45s var(--hw-ease), box-shadow 0.45s var(--hw-ease);
}
.hw-btn::before {                       /* sweep fill */
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.55s var(--hw-ease);
}
.hw-btn:hover::before, .hw-btn:focus-visible::before { transform: scaleX(1); transform-origin: left; }
.hw-btn:hover { transform: translateY(-2px); }
.hw-btn i { transition: transform 0.45s var(--hw-ease); }
.hw-btn:hover .fa-arrow-right { transform: translateX(5px); }
.hw-btn:hover .fa-whatsapp { transform: rotate(-12deg) scale(1.12); }
.hw-btn--solid { background: var(--hw-green); color: #fff !important; box-shadow: 0 10px 24px rgba(13, 92, 47, 0.22); }
.hw-btn--solid::before { background: var(--hw-green-deep); }
.hw-btn--solid:hover { box-shadow: 0 16px 30px rgba(13, 92, 47, 0.28); }
.hw-btn--outline { background: rgba(255, 255, 255, 0.7); color: var(--hw-green) !important; }
.hw-btn--outline::before { background: var(--hw-green); }
.hw-btn--outline:hover { color: #fff !important; }
.hw-btn--outline .fa-whatsapp { font-size: 1.35em; }
.hw-btn--gold { background: var(--hw-gold-soft); border-color: var(--hw-gold-soft); color: var(--hw-ink) !important; }
.hw-btn--gold::before { background: #ffffff; }

/* ---------- Hero entrance (html.hw-ready) ---------- */
.hw-in {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.9s var(--hw-ease), transform 1s var(--hw-ease);
    transition-delay: calc(var(--d, 0) * 90ms + 150ms);
}
.hw-ready .hw-in { opacity: 1; transform: none; }
.hw-in .hw-eyebrow-line, .hw-eyebrow-line { transform: scaleX(0); transition: transform 0.9s var(--hw-ease) 0.5s; }
.hw-ready .hw-in .hw-eyebrow-line, [data-reveal].is-in .hw-eyebrow-line { transform: scaleX(1); }

.hw-char {
    display: inline-block;
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.8s var(--hw-ease), transform 1s var(--hw-ease);
    transition-delay: calc(var(--c, 0) * 30ms + 380ms);
}
.hw-ready .hw-char { opacity: 1; transform: none; }
.hw-word { display: inline-block; white-space: nowrap; }

/* Scroll reveals */
[data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.9s var(--hw-ease), transform 1s var(--hw-ease);
    transition-delay: calc(var(--d, 0) * 80ms);
}
[data-reveal="zoom"] { transform: scale(0.92); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* ---------- Hero ---------- */
.hw-hero {
    position: relative;
    min-height: clamp(400px, 30vw, 560px);
    display: flex;
    align-items: center;
    background:
        radial-gradient(60% 90% at 18% 30%, #fffdf9 0%, rgba(255, 253, 249, 0) 70%),
        linear-gradient(180deg, #fbf8f3 0%, var(--hw-cream) 100%);
    overflow: hidden;
}
.hw-hero-inner { position: relative; z-index: 2; padding-block: clamp(26px, 3vw, 48px) clamp(34px, 3.4vw, 58px); }
.hw-hero-inner > * { max-width: min(640px, 50%); }

.hw-breadcrumb {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: clamp(16px, 1.6vw, 26px);
    font-size: 15px;
    color: var(--hw-text);
}
.hw-breadcrumb a { color: var(--hw-text); text-decoration: none; transition: color 0.3s var(--hw-ease); }
.hw-breadcrumb a:hover { color: var(--hw-green); }
.hw-breadcrumb i { font-size: 10px; opacity: 0.7; }
.hw-breadcrumb span { color: var(--hw-ink); font-weight: 600; }

.hw-hero-title {
    margin: 0 0 clamp(12px, 1.2vw, 20px);
    font-family: var(--hw-serif);
    font-size: clamp(36px, 4.1vw, 68px);
    font-weight: 600;
    line-height: 1.06;
    letter-spacing: -0.015em;
    color: var(--hw-ink);
}
.hw-split { display: block; }
.hw-split.is-accent { color: var(--hw-green); }
.hw-hero-sub {
    margin: 0 0 clamp(20px, 2vw, 32px);
    max-width: 30em;
    color: var(--hw-text);
    font-size: clamp(15.5px, 1.2vw, 19px);
    line-height: 1.6;
}
.hw-hero-actions { display: flex; flex-wrap: wrap; gap: 16px; }

/* Curved photo on the right: green + gold bands follow the same curve */
.hw-hero-media {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 50%;
    z-index: 1;
}
.hw-hero-arc {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    border-top-left-radius: 62% 100%;
    opacity: 0;
    transform: translateX(6%);
    transition: opacity 1.1s var(--hw-ease), transform 1.4s var(--hw-ease);
}
.hw-hero-arc--green { left: 0; background: linear-gradient(160deg, #1a7a42 0%, var(--hw-green) 45%, var(--hw-green-deep) 100%); transition-delay: 0.05s; }
.hw-hero-arc--gold  { left: 16px; background: linear-gradient(170deg, #f6dfa4 0%, var(--hw-gold) 55%, #a8812f 100%); transition-delay: 0.15s; }
.hw-hero-photo      { left: 24px; overflow: hidden; background: #efe6d6; transition-delay: 0.25s; }
.hw-hero-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 30% 55%;
    transform: scale(1.12);
    transition: transform 7s cubic-bezier(0.2, 0.6, 0.2, 1) 0.2s;
}
.hw-ready .hw-hero-arc { opacity: 1; transform: none; }
.hw-ready .hw-hero-photo img { transform: scale(1.02); }

/* ---------- Feature strip ---------- */
.hw-features {
    position: relative;
    z-index: 3;
    background: #ffffff;
    border-bottom: 1px solid var(--hw-line);
    box-shadow: 0 10px 30px rgba(31, 36, 33, 0.04);
}
.hw-features-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin: 0 auto;
    padding: 0;
    list-style: none;
}
.hw-feature {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: clamp(18px, 1.6vw, 26px) 14px;
    position: relative;
}
.hw-feature + .hw-feature::before {
    content: "";
    position: absolute;
    left: 0;
    top: 26%;
    bottom: 26%;
    width: 1px;
    background: var(--hw-line);
}
.hw-feature svg {
    flex-shrink: 0;
    width: clamp(36px, 2.8vw, 46px);
    height: clamp(36px, 2.8vw, 46px);
    fill: none;
    stroke: var(--hw-green);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.6s var(--hw-ease);
}
.hw-feature:hover svg { transform: translateY(-3px) scale(1.08); }
.hw-feature strong { display: block; font-size: clamp(14.5px, 1.05vw, 17px); font-weight: 700; color: var(--hw-ink); line-height: 1.3; }
.hw-feature span { display: block; font-size: clamp(12.5px, 0.85vw, 14px); color: var(--hw-text); line-height: 1.4; }

/* ---------- Explore by space ---------- */
.hw-spaces {
    position: relative;
    padding-block: clamp(48px, 5.5vw, 96px) clamp(36px, 4vw, 64px);
    background:
        radial-gradient(30% 50% at 22% 78%, rgba(13, 92, 47, 0.07) 0%, rgba(13, 92, 47, 0) 70%),
        #ffffff;
}
.hw-spaces-inner {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.4fr) minmax(0, 0.9fr);
    align-items: center;
    gap: clamp(16px, 2vw, 36px);
}
.hw-spaces-copy .hw-text { max-width: 22em; }
.hw-spaces-copy .hw-h2 { font-size: clamp(28px, 2.7vw, 48px); }

.hw-space-detail { margin-top: clamp(20px, 2vw, 30px); min-height: 150px; }
.hw-space-detail-in { animation: hwFadeUp 0.6s var(--hw-ease) both; }
.hw-space-detail-head {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px 12px;
    margin: 0 0 12px;
}
.hw-space-detail-head strong { font-size: 17px; color: var(--hw-green); }
.hw-space-detail-head span {
    padding: 2px 10px;
    border-radius: 999px;
    background: #eef4f0;
    color: var(--hw-green);
    font-size: 12.5px;
    font-weight: 600;
}
.hw-chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.hw-chips li { animation: hwFadeUp 0.55s var(--hw-ease) both; animation-delay: calc(var(--i, 0) * 70ms + 80ms); }
.hw-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: 1px solid var(--hw-line);
    border-radius: 999px;
    background: #ffffff;
    color: var(--hw-ink);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(31, 36, 33, 0.05);
    transition: background 0.35s var(--hw-ease), color 0.35s var(--hw-ease), border-color 0.35s var(--hw-ease), transform 0.45s var(--hw-ease);
}
.hw-chip i {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1.5px solid var(--hw-green);
    color: var(--hw-green);
    font-size: 9px;
    transition: transform 0.5s var(--hw-ease), background 0.35s, color 0.35s, border-color 0.35s;
}
.hw-chip:hover { background: var(--hw-green); border-color: var(--hw-green); color: #fff; text-decoration: none; transform: translateY(-2px); }
.hw-chip:hover i { background: #fff; border-color: #fff; color: var(--hw-green); transform: rotate(90deg); }

/* House cut-away with "+" hotspots */
.hw-house { position: relative; width: 100%; max-width: 660px; margin-inline: auto; container-type: inline-size; }
.hw-house-img {
    width: 100%;
    height: auto;
    mix-blend-mode: multiply;               /* off-white picture melts into the page */
    /* soft edges so the picture has no visible box */
    -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent), linear-gradient(transparent, #000 5%, #000 95%, transparent);
    mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent), linear-gradient(transparent, #000 5%, #000 95%, transparent);
    -webkit-mask-composite: source-in;
    mask-composite: intersect;
    transition: filter 0.6s var(--hw-ease);
}
.hw-house.has-open .hw-house-img { filter: saturate(0.92) brightness(0.97); }
.hw-house-pins { position: absolute; inset: 0; }

.hw-hot {
    position: absolute;
    z-index: 1;
    transform: translate(-50%, -50%);
    opacity: 0;
    scale: 0.4;
    transition: opacity 0.5s var(--hw-ease), scale 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
    transition-delay: calc(var(--n, 0) * 120ms + 450ms);
}
.hw-house.is-in .hw-hot { opacity: 1; scale: 1; }
.hw-hot.is-open { z-index: 5; }
.hw-house.has-open .hw-hot:not(.is-open) { opacity: 0.55; transition-delay: 0s; }

.hw-pin {
    position: relative;
    display: grid;
    place-items: center;
    width: max(30px, 6.2cqw);
    aspect-ratio: 1;
    padding: 0;
    border: 2px solid var(--hw-green);
    border-radius: 50%;
    background: #ffffff;
    color: var(--hw-green);
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(13, 92, 47, 0.25);
    transition: background 0.35s var(--hw-ease), color 0.35s var(--hw-ease), transform 0.5s var(--hw-ease), box-shadow 0.4s var(--hw-ease);
}
.hw-pin::after {                              /* soft pulse ring */
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    border: 2px solid rgba(13, 92, 47, 0.55);
    animation: hwPulse 2.4s var(--hw-ease) infinite;
    animation-delay: calc(var(--n, 0) * 0.45s);
    pointer-events: none;
}
.hw-pin-plus { position: relative; width: 44%; aspect-ratio: 1; transition: transform 0.5s var(--hw-ease); }
.hw-pin-plus::before, .hw-pin-plus::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 100%;
    height: 2.5px;
    border-radius: 2px;
    background: currentColor;
    transform: translate(-50%, -50%);
}
.hw-pin-plus::after { transform: translate(-50%, -50%) rotate(90deg); }
.hw-hot.is-active .hw-pin,
.hw-pin:hover, .hw-pin:focus-visible {
    background: var(--hw-green);
    color: #ffffff;
    transform: scale(1.12);
    box-shadow: 0 10px 24px rgba(13, 92, 47, 0.35);
}
.hw-hot.is-open .hw-pin-plus { transform: rotate(45deg); }
.hw-hot.is-open .hw-pin::after { animation: none; opacity: 0; }
.hw-pin:focus-visible { outline: 2px solid var(--hw-green); outline-offset: 4px; }

/* Card that opens from a "+" */
.hw-pop {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 14px);
    width: 280px;
    padding: 14px 14px 10px;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 22px 50px rgba(31, 36, 33, 0.2), 0 0 0 1px rgba(31, 36, 33, 0.05);
    text-align: left;
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, 10px) scale(0.96);
    transform-origin: 50% 100%;
    transition: opacity 0.3s var(--hw-ease), transform 0.45s var(--hw-ease), visibility 0s linear 0.45s;
}
.hw-pop::before {                             /* bridge so the pointer can travel into the card */
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 18px;
}
.hw-pop::after {                              /* arrow */
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    width: 14px;
    height: 14px;
    background: #ffffff;
    transform: translate(-50%, -7px) rotate(45deg);
    box-shadow: 4px 4px 8px rgba(31, 36, 33, 0.06);
}
.hw-hot.is-left .hw-pop { left: auto; right: -18px; transform: translateY(10px) scale(0.96); transform-origin: 90% 100%; }
.hw-hot.is-left .hw-pop::after { left: auto; right: calc(18px + max(30px, 6.2cqw) / 2 - 7px); transform: translateY(-7px) rotate(45deg); }
.hw-hot.is-below .hw-pop { bottom: auto; top: calc(100% + 14px); transform-origin: 50% 0; }
.hw-hot.is-left.is-below .hw-pop { transform-origin: 90% 0; }
.hw-hot.is-below .hw-pop::before { top: auto; bottom: 100%; }
.hw-hot.is-below .hw-pop::after { top: auto; bottom: 100%; transform: translate(-50%, 7px) rotate(45deg); box-shadow: -4px -4px 8px rgba(31, 36, 33, 0.05); }
.hw-hot.is-left.is-below .hw-pop::after { transform: translateY(7px) rotate(45deg); }
.hw-hot.is-open .hw-pop {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0) scale(1);
    transition: opacity 0.35s var(--hw-ease), transform 0.5s var(--hw-ease), visibility 0s;
}
.hw-hot.is-left.is-open .hw-pop { transform: none; }

.hw-pop-room {
    margin: 0 0 2px;
    color: var(--hw-green);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}
.hw-pop-title { margin: 0 0 8px; color: var(--hw-ink); font-size: 16px; font-weight: 700; line-height: 1.25; }
.hw-pop-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.hw-pop-list li {
    opacity: 0;
    transform: translateX(-8px);
    transition: opacity 0.3s var(--hw-ease), transform 0.4s var(--hw-ease);
}
.hw-hot.is-open .hw-pop-list li {
    opacity: 1;
    transform: none;
    transition-delay: calc(var(--k, 0) * 60ms + 120ms);
}
.hw-pop-list a {
    display: grid;
    grid-template-columns: 44px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 6px;
    border-radius: 10px;
    color: var(--hw-ink);
    text-decoration: none;
    transition: background 0.3s var(--hw-ease), color 0.3s var(--hw-ease);
}
.hw-pop-thumb { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 9px; background: #f5f3ee; overflow: hidden; }
.hw-pop-thumb img { width: 86%; height: 86%; object-fit: contain; mix-blend-mode: multiply; transition: transform 0.5s var(--hw-ease); }
.hw-pop-name { font-size: 14px; font-weight: 600; line-height: 1.25; }
.hw-pop-name small { display: block; color: var(--hw-text); font-size: 12px; font-weight: 500; }
.hw-pop-list i { font-size: 12px; color: var(--hw-green); opacity: 0; transform: translateX(-6px); transition: opacity 0.3s, transform 0.4s var(--hw-ease); }
.hw-pop-list a:hover, .hw-pop-list a:focus-visible { background: #f2f7f3; color: var(--hw-green); text-decoration: none; }
.hw-pop-list a:hover i, .hw-pop-list a:focus-visible i { opacity: 1; transform: none; }
.hw-pop-list a:hover .hw-pop-thumb img { transform: scale(1.1); }

@keyframes hwPulse {
    0% { transform: scale(1); opacity: 0.8; }
    70%, 100% { transform: scale(1.7); opacity: 0; }
}

.hw-space-list { display: grid; gap: clamp(10px, 1vw, 16px); margin: 0; padding: 0; list-style: none; }
.hw-space {
    display: grid;
    grid-template-columns: clamp(96px, 9vw, 150px) 1fr auto;
    align-items: center;
    gap: clamp(12px, 1.2vw, 20px);
    width: 100%;
    padding: 0 clamp(14px, 1.3vw, 22px) 0 0;
    border: 1px solid var(--hw-line);
    border-radius: 999px;
    background: #ffffff;
    color: var(--hw-ink);
    font: inherit;
    text-align: left;
    cursor: pointer;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(31, 36, 33, 0.06);
    transition: transform 0.5s var(--hw-ease), box-shadow 0.5s var(--hw-ease), border-color 0.4s var(--hw-ease), background 0.4s var(--hw-ease);
}
.hw-space-thumb { display: block; height: clamp(60px, 4.8vw, 78px); overflow: hidden; border-radius: 999px 0 0 999px; }
.hw-space-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--hw-ease); }
.hw-space-name { font-size: clamp(14.5px, 1.1vw, 18px); font-weight: 700; line-height: 1.2; transition: color 0.35s var(--hw-ease); }
.hw-space i { font-size: 13px; color: var(--hw-text); transition: transform 0.45s var(--hw-ease), color 0.35s; }
.hw-space:hover, .hw-space:focus-visible { transform: translateX(-6px); box-shadow: 0 14px 30px rgba(31, 36, 33, 0.1); }
.hw-space:hover .hw-space-thumb img { transform: scale(1.1); }
.hw-space.is-active { border-color: var(--hw-green); background: #f4f8f5; }
.hw-space.is-active .hw-space-name, .hw-space.is-active i { color: var(--hw-green); }
.hw-space.is-active i { transform: translateX(4px); }
.hw-space:focus-visible { outline: 2px solid var(--hw-green); outline-offset: 3px; }

/* ---------- All categories ---------- */
.hw-cats { padding-block: clamp(24px, 3vw, 48px) clamp(40px, 4.5vw, 72px); scroll-margin-top: 90px; }
.hw-cats-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(14px, 2vw, 26px);
    margin: 0 0 8px;
    color: var(--hw-ink);
    font-size: clamp(13px, 1.05vw, 17px);
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    text-align: center;
    scroll-margin-top: 100px;
}
.hw-cats-title::before, .hw-cats-title::after {
    content: "";
    flex: 0 0 clamp(28px, 3.4vw, 50px);
    height: 2px;
    background: var(--hw-green);
}
.hw-cats-sub { margin: 0 0 clamp(20px, 2.2vw, 32px); text-align: center; color: var(--hw-text); font-size: 15px; }
.hw-cat-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: clamp(10px, 1vw, 16px);
}
.hw-cat {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: clamp(12px, 1vw, 16px) 10px clamp(14px, 1.2vw, 18px);
    border: 1px solid var(--hw-line);
    border-radius: 14px;
    background: linear-gradient(180deg, #ffffff 0%, #faf8f4 100%);
    color: var(--hw-ink);
    text-align: center;
    text-decoration: none;
    overflow: hidden;
    transition: opacity 0.9s var(--hw-ease), transform 0.6s var(--hw-ease), box-shadow 0.5s var(--hw-ease), border-color 0.4s var(--hw-ease);
    transition-delay: calc(var(--d, 0) * 60ms), 0s, 0s, 0s;
}
.hw-cat::after {                           /* green bar grows on hover */
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: var(--hw-green);
    transform: scaleX(0);
    transition: transform 0.5s var(--hw-ease);
}
.hw-cat-img { position: relative; display: block; width: 100%; aspect-ratio: 1.15; }
.hw-cat-img img { position: absolute; inset: 8%; width: 84%; height: 84%; object-fit: contain; mix-blend-mode: multiply; transition: transform 0.7s var(--hw-ease); }
.hw-cat-name { font-size: clamp(13.5px, 0.95vw, 15.5px); font-weight: 700; line-height: 1.25; transition: color 0.35s var(--hw-ease); }
.hw-cat-count { font-size: 12px; color: var(--hw-text); }
.hw-cat.is-in:hover, .hw-cat:focus-visible {
    transform: translateY(-6px);
    border-color: rgba(13, 92, 47, 0.35);
    box-shadow: 0 18px 34px rgba(31, 36, 33, 0.1);
    text-decoration: none;
}
.hw-cat:hover::after { transform: scaleX(1); }
.hw-cat:hover .hw-cat-img img { transform: scale(1.09) rotate(-2deg); }
.hw-cat:hover .hw-cat-name { color: var(--hw-green); }
.hw-error { grid-column: 1 / -1; color: var(--hw-text); padding: 20px 0; }

/* ---------- CTA ---------- */
.hw-cta-wrap { padding-bottom: clamp(40px, 5vw, 80px); }
.hw-cta {
    position: relative;
    display: grid;
    grid-template-columns: auto 1px minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(16px, 2vw, 34px);
    min-height: clamp(110px, 9vw, 140px);
    padding: 22px clamp(20px, 2.6vw, 40px) 22px 33%;
    border-radius: 18px;
    background: radial-gradient(80% 140% at 80% 0%, #146b3a 0%, var(--hw-green-deep) 70%);
    color: #ffffff;
    overflow: hidden;
    box-shadow: 0 24px 50px rgba(11, 61, 34, 0.25);
}
.hw-cta-media {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 32%;
    border-top-right-radius: 70% 100%;
    border-right: 5px solid var(--hw-gold);
    overflow: hidden;
}
.hw-cta-media img { width: 100%; height: 100%; object-fit: cover; object-position: 40% 70%; transition: transform 1.4s var(--hw-ease); }
.hw-cta:hover .hw-cta-media img { transform: scale(1.06); }
.hw-cta-title {
    grid-column: 1;
    margin: 0;
    font-family: var(--hw-serif);
    font-size: clamp(22px, 1.9vw, 32px);
    font-weight: 600;
    line-height: 1.15;
    color: #ffffff;
    white-space: nowrap;
}
.hw-cta-text {
    grid-column: 3;
    margin: 0;
    padding-left: clamp(16px, 2vw, 30px);
    border-left: 1px solid rgba(255, 255, 255, 0.35);
    font-size: clamp(13.5px, 0.95vw, 15.5px);
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.88);
}
.hw-cta .hw-btn { grid-column: 4; white-space: nowrap; }

@keyframes hwFadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------- Large tablets / small laptops ---------- */
@media (max-width: 1199px) {
    .hw-spaces-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    /* copy on top, then house | list, with the selected space's chips under the list */
    .hw-spaces-inner { grid-template-areas: "eb eb" "h2 h2" "tx tx" "house list" "house detail"; align-items: start; row-gap: 0; column-gap: 32px; }
    .hw-spaces-copy { display: contents; }
    .hw-spaces-copy .hw-eyebrow { grid-area: eb; }
    .hw-spaces-copy .hw-h2 { grid-area: h2; }
    .hw-spaces-copy .hw-text { grid-area: tx; max-width: 34em; margin-bottom: 26px; }
    .hw-house { grid-area: house; align-self: center; }
    .hw-space-list { grid-area: list; }
    .hw-space-detail { grid-area: detail; margin-top: 18px; min-height: 0; }
    .hw-hero-inner > * { max-width: min(600px, 56%); }
    .hw-hero-actions .hw-btn { padding: 0 20px; }
    .hw-house { max-width: 560px; }
    .hw-cta { grid-template-columns: minmax(0, 1fr) auto; padding-left: 36%; }
    .hw-cta-title { white-space: normal; }
    .hw-cta-text { grid-column: 1; border-left: 0; padding-left: 0; }
    .hw-cta .hw-btn { grid-column: 2; grid-row: 1 / span 2; }
}

/* ---------- Tablets ---------- */
@media (max-width: 991px) {
    .hw-hero { flex-direction: column; align-items: stretch; min-height: 0; }
    .hw-hero-inner > * { max-width: 640px; }
    .hw-hero-media { position: relative; order: 2; width: 100%; height: clamp(220px, 44vw, 380px); }
    .hw-hero-arc { border-top-left-radius: 46% 70%; }
    .hw-hero-arc--gold { left: 10px; }
    .hw-hero-photo { left: 16px; }
    .hw-hero-photo img { object-position: 40% 60%; }
    .hw-features-list { grid-template-columns: repeat(2, 1fr); }
    .hw-feature { justify-content: flex-start; padding-inline: clamp(10px, 3vw, 28px); }
    .hw-feature:nth-child(3)::before { display: none; }
    .hw-feature:nth-child(n + 3) { border-top: 1px solid var(--hw-line); }
    .hw-cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ---------- Phones ---------- */
@media (max-width: 767px) {
    .hw-spaces-inner { grid-template-columns: 1fr; grid-template-areas: none; gap: 0; }
    .hw-spaces-copy > *, .hw-house, .hw-space-list, .hw-space-detail { grid-area: auto; }
    .hw-spaces-copy { display: contents; }
    .hw-spaces-copy > * { grid-column: 1; }
    .hw-house { order: 2; margin-top: 18px; }
    .hw-space-detail { order: 3; grid-row: auto; margin-top: 14px; min-height: 0; }
    .hw-space-list { order: 4; margin-top: 22px; }
    .hw-pop { display: none; }              /* phones: the chips under the picture list the hardware */
    .hw-cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .hw-cta { grid-template-columns: 1fr; padding: 180px 22px 26px; text-align: left; }
    .hw-cta-media { width: 100%; height: 160px; bottom: auto; border-right: 0; border-bottom: 4px solid var(--hw-gold); border-radius: 0 0 50% 50% / 0 0 26% 26%; }
    .hw-cta-text, .hw-cta .hw-btn { grid-column: 1; grid-row: auto; }
    .hw-cta .hw-btn { justify-self: start; }
}
@media (max-width: 560px) {
    .hw-hero-actions { flex-direction: column; align-items: stretch; }
    .hw-hero-actions .hw-btn { width: 100%; }
    .hw-features-list { grid-template-columns: 1fr 1fr; }
    .hw-feature { flex-direction: column; align-items: flex-start; gap: 8px; padding: 16px 12px; }
    .hw-space { grid-template-columns: 84px 1fr auto; }
    .hw-space:hover, .hw-space:focus-visible { transform: none; }
    .hw-cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 380px) {
    .hw-breadcrumb { font-size: 14px; }
    .hw-hero-title { font-size: 32px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    .hw-in, .hw-char, [data-reveal], .hw-hero-arc, .hw-hero-photo img, .hw-hot { transition-duration: 0.01ms !important; transition-delay: 0s !important; }
    .hw-in, .hw-char, [data-reveal], .hw-hero-arc { opacity: 1; transform: none; }
    .hw-hot { opacity: 1; scale: 1; }
    .hw-pin::after { animation: none; }
    .hw-space-detail-in, .hw-chips li { animation: none; }
}
