/*
 * Alf Theme — Hydroforming Process Section
 * Figma node: 699:1663
 *
 * Loaded only on the Hydroforming page template.
 * Three sub-components: step cards, detail panel, strategic benefits.
 */

/* ═══════════════════════════════════════════════════════════════════
   SECTION
   ═══════════════════════════════════════════════════════════════════ */
.hydro-process {
  padding-block: 160px;
  background-color: var(--color-bg);
}

.hydro-process__wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
}

/* ── Section header ───────────────────────────────────────────────── */
.hydro-process__header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  max-width: 896px;
  width: 100%;
  text-align: center;
}

.hydro-process__title {
  font-size: var(--font-size-h2);
  /* 36px */
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-dark);
  margin: 0;
}

.hydro-process__subtitle {
  font-size: var(--font-size-h4);
  /* 20px */
  font-weight: 400;
  line-height: 1.5;
  color: var(--color-dark);
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   1. PROCESS STEP CARDS
   ═══════════════════════════════════════════════════════════════════ */
.hydro-process__steps {
  display: flex;
  flex-wrap: wrap;
  gap: 21px;
  width: 100%;
  max-width: 1200px;
}

/* ── Individual step card ─────────────────────────────────────────── */
.hydro-step {
  position: relative;
  /* anchor for absolute badge */
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1 0 200px;
  min-height: 220px;
  padding: 16px 12px;
  border-radius: 16px;
  border: 1px solid rgba(37, 37, 37, 0.12);
  background-color: var(--color-white);
  overflow: visible;
  /* badge bleeds outside */
  cursor: default;
  transition:
    background-color 0.25s ease,
    border-color 0.25s ease;
}

/* Default text colours */
.hydro-step__label {
  color: var(--color-primary);
}

.hydro-step__title {
  color: var(--color-dark);
}

.hydro-step__body {
  color: var(--color-darker);
}

/* Hover — dark state (what Figma showed as the "active" card) */
.hydro-step:hover {
  background-color: var(--color-dark);
  border-color: var(--color-bg);
}

.hydro-step:hover .hydro-step__title,
.hydro-step:hover .hydro-step__body {
  color: var(--color-bg);
}

/* ── Step number badge (absolute, top-right) ──────────────────────── */
.hydro-step__badge {
  position: absolute;
  top: -11px;
  right: -10.8px;
  width: 32px;
  height: 32px;
  background-color: var(--color-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-white);
  box-shadow:
    0px 10px 7.5px rgba(0, 0, 0, 0.1),
    0px 4px 3px rgba(0, 0, 0, 0.1);
  line-height: 1;
  pointer-events: none;
  z-index: 1;
}

/* ── Icon container ───────────────────────────────────────────────── */
.hydro-step__icon-wrap {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
}

.hydro-step__icon-wrap img {
  display: block;
  width: 48px;
  height: 48px;
  border-radius: 14px;
}

/* ── Step text ────────────────────────────────────────────────────── */
.hydro-step__label {
  font-size: 14px;
  font-weight: 400;
  line-height: 16px;
  letter-spacing: 0.04em;
  margin: 0;
}

.hydro-step__title {
  font-size: var(--font-size-h4);
  /* 20px */
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

.hydro-step__body {
  font-size: var(--font-size-body-md);
  /* 16px */
  font-weight: 400;
  line-height: 1.5;
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   2. DETAIL PANEL
   ═══════════════════════════════════════════════════════════════════ */
.hydro-process__detail {
  display: flex;
  align-items: stretch;
  gap: 32px;
  width: 100%;
  max-width: 1200px;
  padding: 64px 40px;
  background-color: var(--color-dark);
  border: 1px solid var(--color-bg);
  border-radius: 16px;
}

/* ── Benefits column (left) ───────────────────────────────────────── */
.hydro-process__benefits {
  display: flex;
  flex-direction: column;
  gap: 32px;
  flex: 1 0 0;
  min-width: 0;
}

.hydro-process__benefit {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px 24px;
  background-color: var(--color-bg);
  border-radius: 24px;
}

.hydro-process__benefit-text {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hydro-process__benefit-title {
  font-size: var(--font-size-body-md);
  /* 16px */
  font-weight: 600;
  line-height: 1.3;
  color: var(--color-primary);
  margin: 0;
}

.hydro-process__benefit-body {
  font-size: var(--font-size-body-md);
  font-weight: 300;
  line-height: 1.5;
  color: var(--color-black);
  margin: 0;
}

/* ── Engineering photo (right) ────────────────────────────────────── */
.hydro-process__image {
  flex: 1 0 0;
  min-width: 0;
  display: flex;
  /* stretch the picture to match the height of the detail panel */
  align-items: stretch;
}

/* Ensure the picture wrapper and its img fill the flex item's height */
.hydro-process__image picture,
.hydro-process__image picture img,
.hydro-process__image .hydro-process__photo {
  width: 100%;
  height: 100%;
  display: block;
}

.hydro-process__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0px 25px 50px -12px rgba(0, 0, 0, 0.25);
  display: block;
}

/* ═══════════════════════════════════════════════════════════════════
   3. STRATEGIC BENEFITS
   ═══════════════════════════════════════════════════════════════════ */
.hydro-process__strategic {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  width: 100%;
  max-width: 1200px;
}

.hydro-process__strategic-heading {
  font-size: var(--font-size-h2);
  /* 36px */
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-dark);
  text-align: center;
  margin: 0;
}

.hydro-process__strategic-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  width: 100%;
}

/* ── Benefit card ────────────────────────────────────────────────── */
.hydro-benefit {
  display: flex;
  flex-direction: column;
  gap: 24px;
  flex: 1 0 236px;
  padding: 32px 16px;
  background-color: var(--color-dark);
  border-radius: 16px;
}

/* Large label with left red-bar accent (matches Figma screenshot) */
.hydro-benefit__heading {
  border-left: 4px solid var(--color-primary);
  padding-left: 14px;
}

.hydro-benefit__label {
  font-size: var(--font-size-h2);
  /* 36px */
  font-weight: var(--font-weight-bold);
  line-height: 1.1;
  color: var(--color-bg);
  margin: 0;
}

.hydro-benefit__title {
  font-size: var(--font-size-body-md);
  /* 16px */
  font-weight: var(--font-weight-semibold);
  line-height: 1.3;
  color: var(--color-bg);
  margin: 0;
}

.hydro-benefit__body {
  font-size: var(--font-size-body-md);
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-grey);
  margin: 0;
}

/* Footnote below the strategic-benefits grid */
.hydro-process__strategic-footnote {
  font-size: var(--font-size-body-md);
  font-family: var(--font-body);
  font-weight: var(--font-weight-regular);
  color: var(--color-dark);
  text-align: left;
  width: 100%;
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════ */

/* ── Tablet landscape (≤ 1280px) ─────────────────────────────────── */
@media (max-width: 1280px) {
  .hydro-process {
    padding-block: 120px;
  }

  .hydro-process__detail {
    padding: 48px 32px;
  }
}

/* ── Tablet portrait (≤ 900px) ───────────────────────────────────── */
@media (max-width: 900px) {
  .hydro-process {
    padding-block: 100px;
  }

  /* Step cards: 2 columns */
  .hydro-process__steps {
    gap: 16px;
  }

  .hydro-step {
    flex: 1 0 calc(50% - 8px);
  }

  /* Detail panel: stack vertically */
  .hydro-process__detail {
    flex-direction: column;
    padding: 40px 24px;
  }

  .hydro-process__image {
    width: 100%;
  }

  /* Strategic: 2 columns */
  .hydro-benefit {
    flex: 1 0 calc(50% - 10px);
  }
}

/* ── Mobile (≤ 640px) ────────────────────────────────────────────── */
@media (max-width: 640px) {
  .hydro-process {
    padding-block: 80px;
  }

  .hydro-process__wrap {
    gap: 32px;
  }

  .hydro-step {
    flex: 1 0 100%;
  }

  .hydro-benefit {
    flex: 1 0 100%;
  }

  .hydro-process__benefit {
    flex-direction: column;
  }
}