/* ==========================================================================
   ELECTROMAT — HOME PAGE
   Built on top of the shared tokens/utilities in style.css
   (--brand-*, --ink-*, --amber-*, --surface*, --font-*, .container, .btn)
   ========================================================================== */

/* --------------------------------------------------------------------------
   HOME HERO
   -------------------------------------------------------------------------- */
.h-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 64px) 0 72px;
  background: var(--ink-950);
  color: #fff;
}

.h-hero__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.h-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}

.h-hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(8, 11, 34, .97) 0%, rgba(8, 11, 34, .90) 32%, rgba(8, 11, 34, .58) 58%, rgba(8, 11, 34, .42) 100%),
    linear-gradient(0deg, rgba(8, 11, 34, .55) 0%, transparent 30%);
}

.h-hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .5;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, .045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
}

.h-hero__container {
  position: relative;
  max-width: 1220px;
}

.h-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 22px;
  padding: 7px 14px 7px 11px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 999px;
  background: rgba(255, 255, 255, .05);
  font-family: var(--font-mono);
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff;
}

.h-hero__badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--amber-500);
  box-shadow: 0 0 0 3px rgba(217, 45, 39, .25);
}

.h-hero h1 {
  color: #fff;
  font-size: clamp(2.4rem, 4.4vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: -.02em;
  margin-bottom: 18px;
}

.h-hero h1 span {
  display: block;
  margin-top: 8px;
  font-size: .42em;
  font-weight: 500;
  font-family: var(--font-body);
  color: var(--text-on-dark-muted);
  letter-spacing: 0;
}

.h-hero__desc {
  max-width: 560px;
  font-size: 1.06rem;
  line-height: 1.7;
  color: var(--text-on-dark-muted);
  margin-bottom: 34px;
}

.h-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 44px;
}

.h-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, .14);
}

.h-hero__meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.h-hero__meta-item strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: #fff;
}

.h-hero__meta-item span {
  font-family: var(--font-mono);
  font-size: .66rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

/* Applications strip along hero base */
.h-hero__strip {
  position: relative;
  z-index: 2;
  margin-top: -1px;
  background: rgba(8, 11, 34, .92);
  border-top: 1px solid rgba(255, 255, 255, .1);
  backdrop-filter: blur(6px);
}

.h-hero__strip-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  padding: 18px 0;
}

.h-hero__strip-label {
  font-family: var(--font-mono);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--amber-500);
  white-space: nowrap;
}

.h-hero__strip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .03em;
  color: var(--text-on-dark-muted);
}

@media (max-width: 780px) {
  .h-hero {
    min-height: 0;
    padding: calc(var(--header-h) + 40px) 0 44px;
  }

  .h-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .h-hero__actions .btn {
    justify-content: center;
  }

  .h-hero__meta {
    gap: 20px 28px;
  }

  .h-hero__strip-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 14px 0;
  }
}

/* --------------------------------------------------------------------------
   TRUST / CERTIFICATION BAR
   -------------------------------------------------------------------------- */
.h-trust {
  background: var(--surface-alt);
  border-bottom: 1px solid var(--line);
}

.h-trust__inner {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
}

.h-trust__item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 26px 22px;
  border-left: 1px solid var(--line);
}

.h-trust__item:first-child {
  border-left: none;
}

.h-trust__item svg {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  color: var(--brand-700);
}

.h-trust__item strong {
  display: block;
  font-family: var(--font-display);
  font-size: .95rem;
  color: var(--text-primary);
}

.h-trust__item span {
  display: block;
  font-size: .78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

@media (max-width: 900px) {
  .h-trust__inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .h-trust__item:nth-child(3) {
    border-left: none;
  }

  .h-trust__item:nth-child(1),
  .h-trust__item:nth-child(2) {
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 520px) {
  .h-trust__inner {
    grid-template-columns: 1fr;
  }

  .h-trust__item {
    border-left: none !important;
    border-bottom: 1px solid var(--line);
  }

  .h-trust__item:last-child {
    border-bottom: none;
  }
}

/* --------------------------------------------------------------------------
   STANDARD STORY (existing content section, retained layout family)
   -------------------------------------------------------------------------- */
.h-story {
  padding: 92px 0;
  background: var(--paper);
}

.h-story__grid {
  display: grid;
  grid-template-columns: .92fr 1fr;
  gap: 64px;
  align-items: center;
}

.h-story__media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 3.1;
}

.h-story__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.h-story__media-tag {
  position: absolute;
  left: 18px;
  bottom: 18px;
  padding: 8px 14px;
  background: rgba(8, 11, 34, .82);
  backdrop-filter: blur(6px);
  border-radius: var(--radius-xs);
  color: #fff;
  font-family: var(--font-mono);
  font-size: .68rem;
  letter-spacing: .07em;
}

.h-story p {
  font-size: 1rem;
  line-height: 1.75;
}

@media (max-width: 900px) {
  .h-story {
    padding: 64px 0;
  }

  .h-story__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* --------------------------------------------------------------------------
   PRODUCT RANGE — large editorial cards
   -------------------------------------------------------------------------- */
.h-products {
  padding: 100px 0 96px;
  background: var(--ink-950);
  color: #fff;
}

.h-products__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 44px;
}

.h-products__head .eyebrow {
  color: var(--amber-500);
}

.h-products__head h2 {
  color: #fff;
  max-width: 640px;
  margin: 0;
}

.h-products__head p {
  max-width: 380px;
  color: var(--text-on-dark-muted);
  margin: 0;
  font-size: .94rem;
  line-height: 1.7;
}

.h-products__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.h-product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--ink-900);
  border: 1px solid rgba(255, 255, 255, .08);
  transition: transform .35s ease, border-color .35s ease, box-shadow .35s ease;
}

.h-product-card:hover {
  transform: translateY(-6px);
  border-color: rgba(217, 45, 39, .4);
  box-shadow: 0 24px 55px rgba(0, 0, 0, .4);
}

.h-product-card__media {
  position: relative;
  aspect-ratio: 4 / 3.2;
  overflow: hidden;
}

.h-product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .7s cubic-bezier(.2, .7, .2, 1);
}

.h-product-card:hover .h-product-card__media img {
  transform: scale(1.07);
}

.h-product-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 11, 34, 0) 45%, rgba(8, 11, 34, .88) 100%);
}

.h-product-card__arrow {
  position: absolute;
  z-index: 2;
  top: 16px;
  right: 16px;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .3);
  color: #fff;
  transition: all .35s ease;
}

.h-product-card:hover .h-product-card__arrow {
  background: var(--amber-500);
  border-color: var(--amber-500);
  transform: rotate(45deg);
}

.h-product-card__body {
  padding: 22px 22px 26px;
}

.h-product-card__cat {
  display: block;
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--amber-500);
  text-transform: uppercase;
}

.h-product-card__body h3 {
  color: #fff;
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.h-product-card__body p {
  color: var(--text-on-dark-muted);
  font-size: .88rem;
  line-height: 1.65;
  margin-bottom: 16px;
}

.h-product-card__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .84rem;
  font-weight: 700;
  color: #fff;
}

.h-product-card__link svg {
  width: 15px;
  height: 15px;
  transition: transform .25s ease;
}

.h-product-card:hover .h-product-card__link svg {
  transform: translateX(4px);
}

@media (max-width: 1024px) {
  .h-products__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .h-products {
    padding: 68px 0 64px;
  }

  .h-products__head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .h-products__grid {
    grid-template-columns: 1fr;
  }
}

/* --------------------------------------------------------------------------
   APPLICATIONS — featured + list
   -------------------------------------------------------------------------- */
.h-apps {
  padding: 96px 0;
  background: var(--paper);
}

.h-apps__head {
  max-width: 640px;
  margin-bottom: 40px;
}

.h-apps__layout {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 22px;
}

.h-app-feature {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  min-height: 460px;
  display: flex;
  align-items: flex-end;
}

.h-app-feature img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2, .7, .2, 1);
}

.h-app-feature:hover img {
  transform: scale(1.05);
}

.h-app-feature::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 11, 34, 0) 30%, rgba(8, 11, 34, .92) 100%);
}

.h-app-feature__body {
  position: relative;
  z-index: 1;
  padding: 30px;
  color: #fff;
}

.h-app-feature__tag {
  display: block;
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--amber-500);
  text-transform: uppercase;
}

.h-app-feature__body h3 {
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.h-app-feature__body p {
  color: var(--text-on-dark-muted);
  font-size: .92rem;
  max-width: 420px;
  margin: 0;
}

.h-app-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.h-app-row {
  position: relative;
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}

.h-app-row:hover {
  border-color: rgba(33, 26, 120, .25);
  box-shadow: var(--shadow-sm);
  transform: translateX(4px);
}

.h-app-row__media {
  flex: 0 0 auto;
  width: 76px;
  height: 76px;
  border-radius: var(--radius-xs);
  overflow: hidden;
}

.h-app-row__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.h-app-row__body {
  flex: 1;
  min-width: 0;
}

.h-app-row__body span {
  display: block;
  font-family: var(--font-mono);
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--brand-700);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.h-app-row__body h4 {
  margin: 0 0 4px;
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--text-primary);
}

.h-app-row__body p {
  margin: 0;
  font-size: .82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

@media (max-width: 900px) {
  .h-apps {
    padding: 64px 0;
  }

  .h-apps__layout {
    grid-template-columns: 1fr;
  }

  .h-app-feature {
    min-height: 320px;
  }
}

@media (max-width: 480px) {
  .h-app-row {
    align-items: flex-start;
  }

  .h-app-row__media {
    width: 60px;
    height: 60px;
  }
}

/* --------------------------------------------------------------------------
   WHY ELECTROMAT — editorial statement + benefit list
   -------------------------------------------------------------------------- */
.h-why {
  padding: 100px 0;
  background: var(--surface-alt);
}

.h-why__grid {
  display: grid;
  grid-template-columns: .95fr 1.05fr;
  gap: 60px;
}

.h-why__statement {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  align-self: start;
}

.h-why__statement .eyebrow {
  margin-bottom: 18px;
}

.h-why__statement h2 {
  font-size: clamp(2rem, 3.2vw, 2.9rem);
  line-height: 1.14;
  margin-bottom: 20px;
}

.h-why__statement p {
  max-width: 420px;
  font-size: .96rem;
  line-height: 1.7;
}

.h-why__list {
  display: flex;
  flex-direction: column;
}

.h-why-item {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 22px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}

.h-why-item:last-child {
  border-bottom: 1px solid var(--line);
}

.h-why-item__num {
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 700;
  color: var(--amber-500);
  padding-top: 4px;
}

.h-why-item h3 {
  margin-bottom: 8px;
  font-size: 1.15rem;
}

.h-why-item p {
  margin: 0 0 12px;
  font-size: .92rem;
  line-height: 1.65;
}

.h-why-item__stat {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--brand-700);
  background: var(--brand-100);
  padding: 5px 11px;
  border-radius: 999px;
}

@media (max-width: 900px) {
  .h-why {
    padding: 64px 0;
  }

  .h-why__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .h-why__statement {
    position: static;
  }
}

@media (max-width: 480px) {
  .h-why-item {
    grid-template-columns: 40px 1fr;
    gap: 14px;
  }
}

/* --------------------------------------------------------------------------
   FINAL CTA
   -------------------------------------------------------------------------- */
.h-cta {
  padding: 30px 0 96px;
}

.cta-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 48px 52px;
  background: var(--ink-950);
  border-radius: var(--radius-lg);
  color: #fff;
}

.cta-banner h2 {
  color: #fff;
  margin-bottom: 10px;
  font-size: clamp(1.6rem, 2.6vw, 2.1rem);
}

.cta-banner p {
  margin: 0;
  max-width: 520px;
  color: var(--text-on-dark-muted);
}

.cta-banner .btn {
  flex: 0 0 auto;
}

@media (max-width: 780px) {
  .h-cta {
    padding: 12px 0 64px;
  }

  .cta-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 34px 26px;
  }

  .cta-banner .btn {
    width: 100%;
    justify-content: center;
  }
}

/* --------------------------------------------------------------------------
   Scroll reveal (hooks into existing main.js IntersectionObserver)
   -------------------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}
