/* ==========================================================================
   MES Platform pages (group A): Production, Quality, Data and insights
   ========================================================================== */

/* Hero ------------------------------------------------------------------ */

.mes-hero { padding-top: 72px; }
.mes-hero .hero__eyebrow { margin-top: 28px; }
.mes-hero__title {
  margin-top: 20px; max-width: 1080px;
  font-size: clamp(42px, 6vw, 72px); line-height: 1; font-weight: 700; letter-spacing: -0.04em;
  color: var(--navy);
}
.mes-hero .hero__row { margin-top: 28px; }
.mes-hero .hero__lede { max-width: 660px; }
.mes-hero .container--wide { padding-bottom: 88px; }

.mes-photo { position: relative; height: 440px; border-radius: 32px 32px 0 0; overflow: hidden; }
.mes-photo img { width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
.mes-photo::after { content: ""; position: absolute; inset: 0; background: rgba(15,23,41,.18); }
.mes-float {
  position: absolute; z-index: 1;
  background: var(--white); border-radius: 16px; padding: 14px 18px;
  box-shadow: 0 16px 36px rgba(15,23,41,.3);
  animation: piq-float 6s ease-in-out infinite;
}
.mes-float--a { left: 5%; top: var(--top, 14%); }
.mes-float--b { right: 6%; bottom: 18%; background: var(--orange); animation-duration: 7s; animation-delay: 1s; }
.mes-float__label { font-size: 12px; font-weight: 600; color: var(--petrol); }
.mes-float--b .mes-float__label { color: var(--navy); }
.mes-float__value { margin-top: 4px; font-size: 15px; font-weight: 700; color: var(--navy); }
.mes-illus {
  position: absolute; right: 16px; bottom: 12px; z-index: 1;
  font-size: 11px; color: var(--white); background: rgba(15,23,41,.55); padding: 3px 7px; border-radius: 4px;
}

/* Section spacing ------------------------------------------------------- */

.mes-first > .container--threaded { padding-top: 24px; }
.mes-node-top .thread__node { top: 8px; }
.mes-pad-80 > .container--threaded { padding-bottom: 80px; }
.mes-h2-xl { font-size: clamp(34px, 4.4vw, 52px); }

/* Shared marks ---------------------------------------------------------- */

.mes-check {
  flex: none; width: 24px; height: 24px;
  fill: none; stroke: var(--teal); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.compare--mes { margin-top: 40px; }
.compare--mes .compare__head { padding-bottom: 12px; }
.compare--mes .compare__row { padding: 24px 0; }

.mes-tag {
  display: inline-block; margin-top: 12px;
  font-size: 12px; font-weight: 600; line-height: 1.4; color: var(--navy);
  background: var(--teal-bright); padding: 4px 10px; border-radius: 999px;
}
.mes-tag span { font-weight: 400; }
.mes-tag--grey { background: var(--grey); }
.mes-tag--orange { background: var(--orange); margin-top: 0; }
.mes-tags { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-top: 12px; }
.mes-tags .mes-tag { margin-top: 0; }

/* Capabilities ---------------------------------------------------------- */

.mes-caps { display: flex; flex-wrap: wrap; gap: 48px 40px; margin-top: 56px; }
.mes-caps--tight { gap: 40px; margin-top: 48px; }
.mes-caps--sm { gap: 36px; margin-top: 40px; }
.mes-cap { flex: 1 1 300px; padding-top: 24px; border-top: 2px solid var(--teal-bright); }
.mes-caps--tight .mes-cap { flex-basis: 280px; }
.mes-caps--sm .mes-cap { flex-basis: 260px; padding-top: 22px; }
.mes-cap svg {
  width: 32px; height: 32px; fill: none; stroke: var(--teal-bright);
  stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.mes-cap h3 { margin-top: 16px; font-size: 22px; line-height: 1.25; font-weight: 700; color: var(--white); }
.mes-cap p { margin-top: 10px; font-size: 16px; line-height: 1.6; color: var(--mist); }
.mes-caps--sm .mes-cap h3 { margin-top: 0; font-size: 20px; }
.mes-caps--sm .mes-cap p { margin-top: 8px; line-height: 1.55; }

/* Light-background variant */
.section--light .mes-cap { border-top-color: var(--navy); }
.section--light .mes-cap svg { stroke: var(--teal); }
.section--light .mes-cap h3 { color: var(--navy); }
.section--light .mes-cap p { color: var(--ink); }

/* Shop floor at a glance (Production) ----------------------------------- */

.mes-head { display: flex; flex-wrap: wrap; gap: 24px 48px; align-items: flex-end; justify-content: space-between; }
.mes-head__main { flex: 1 1 520px; }
.mes-head__main .h3-lg { font-size: clamp(32px, 3.6vw, 44px); }
.mes-head__aside { flex: 1 1 320px; font-size: 17px; line-height: 1.6; }

.mes-floor {
  position: relative; margin-top: 40px; padding: 32px;
  display: flex; flex-wrap: wrap; gap: 16px;
  background-color: var(--slate);
  background-image: radial-gradient(rgba(20,184,162,.22) 1.5px, transparent 1.5px);
  background-size: 22px 22px;
  border-radius: 28px;
}
.mes-station {
  flex: 1 1 200px; padding: 18px; border-radius: 16px;
  background: var(--white); box-shadow: 0 10px 24px rgba(15,23,41,.18);
}
.mes-station__top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.mes-station__name { font-size: 13px; font-weight: 700; color: var(--navy); }
.mes-station__status { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--slate); }
.mes-station__status::before {
  content: ""; width: 8px; height: 8px; border-radius: 999px; background: var(--teal);
  animation: piq-blink 1.8s ease-in-out var(--d, 0s) infinite;
}
.mes-station__status--qc::before { background: var(--orange); }
.mes-station__status--ready::before { background: var(--grey); }
.mes-station__product { margin-top: 12px; font-size: 18px; font-weight: 700; color: var(--navy); }
.mes-station__variant { margin-top: 4px; font-size: 14px; color: var(--slate); }
.mes-floor__note { position: absolute; right: 18px; bottom: 10px; font-size: 11px; color: var(--mist); }

/* Quote ------------------------------------------------------------------ */

.mes-quote { max-width: 980px; }
.mes-quote__mark { height: 56px; font-size: 120px; line-height: 1; font-weight: 700; color: var(--teal-bright); }
.mes-quote blockquote {
  font-size: clamp(26px, 3.2vw, 40px); line-height: 1.25; font-weight: 600; letter-spacing: -0.02em; color: var(--navy);
}
.mes-quote figcaption {
  margin-top: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  font-size: 16px; color: var(--slate);
}
.mes-quote figcaption::before { content: ""; width: 32px; height: 2px; background: var(--teal); }

/* Editions table --------------------------------------------------------- */

.mes-editions__link { padding: 8px 0; font-size: 16px; font-weight: 600; }
.mes-table-wrap {
  margin-top: 28px; overflow-x: auto;
  background: var(--white); border-radius: 24px; box-shadow: 0 20px 48px rgba(15,23,41,.08);
}
.mes-table { width: 100%; min-width: 520px; border-collapse: collapse; }
.mes-table th, .mes-table td { padding: 13px 8px; text-align: center; vertical-align: middle; }
.mes-table th:first-child, .mes-table td:first-child { width: 40%; padding-left: 28px; text-align: left; }
.mes-table tr > :last-child { padding-right: 28px; }
.mes-table thead th { padding-top: 18px; padding-bottom: 18px; background: var(--navy); color: var(--white); font-size: 15px; font-weight: 700; }
.mes-table thead th:first-child { font-size: 13px; font-weight: 600; color: #DDF3EF; }
.mes-table thead th:last-child { color: var(--teal-bright); }
.mes-table tbody tr { border-top: 1px solid #EEF2F4; }
.mes-table tbody th { font-size: 15px; font-weight: 400; color: var(--ink); }
.mes-table .mes-check { width: 22px; height: 22px; display: block; }
.mes-yes { display: inline-flex; }
.mes-no { display: inline-block; width: 14px; height: 2px; background: #C9D3D9; vertical-align: middle; }
.mes-addon { font-size: 12px; font-weight: 600; color: var(--navy); background: var(--line); padding: 3px 9px; border-radius: 999px; }
.mes-basic { font-size: 13px; font-weight: 600; color: var(--slate); }
.mes-table-note { margin-top: 14px; font-size: 14px; color: var(--slate); }

/* Decisions at every level (Data) ---------------------------------------- */

.mes-intro { margin-top: 20px; max-width: 640px; font-size: 19px; line-height: 1.6; }
.mes-intro--wide { margin-top: 24px; max-width: 960px; }

.mes-ladder { position: relative; margin-top: 64px; padding-top: 40px; }
.mes-ladder__line {
  position: absolute; left: 0; top: -24px; width: 100%; height: 264px;
  overflow: visible; pointer-events: none;
}
.mes-ladder__line path {
  stroke: var(--teal); stroke-width: 2; stroke-dasharray: 6 8; fill: none;
  animation: piq-flow 6s linear infinite;
}
.mes-ladder__end { position: absolute; font-size: 13px; font-weight: 600; color: var(--slate); }
.mes-ladder__end--start { left: 0; top: 148px; }
.mes-ladder__end--finish { right: 0; top: -56px; }
.mes-ladder__steps { position: relative; display: flex; flex-wrap: wrap; gap: 32px 28px; align-items: flex-start; }
.mes-rung {
  flex: 1 1 220px; min-width: 0; margin-top: var(--rise, 0);
  display: flex; flex-direction: column; gap: 14px; padding-top: 22px;
}
.mes-rung__who { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; color: var(--petrol); }
.mes-rung__num {
  flex: none; width: 30px; height: 30px; border-radius: 999px; background: var(--navy); color: var(--white);
  display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700;
}
.mes-rung .mes-rung__q { font-size: 24px; line-height: 1.3; font-weight: 700; color: var(--navy); }
.mes-rung p { font-size: 16px; line-height: 1.55; }
.mes-rung .mes-tag { align-self: flex-start; margin-top: 0; }

/* How your data flows (Data) --------------------------------------------- */

.mes-flow { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 48px; align-items: stretch; }
.mes-flow__box { flex: 1 1 220px; padding: 24px; border-radius: 20px; background: var(--white); }
.mes-flow__num { font-size: 13px; font-weight: 600; color: var(--petrol); }
.mes-flow__title { margin-top: 6px; font-size: 22px; font-weight: 700; color: var(--navy); }
.mes-flow__text { margin-top: 6px; font-size: 15px; line-height: 1.5; color: var(--ink); }
.mes-flow__box--hub { background: var(--teal); }
.mes-flow__box--hub .mes-flow__num, .mes-flow__box--hub .mes-flow__text { color: var(--navy); }
.mes-flow__arrow {
  flex: none; align-self: center; width: 48px; height: 24px;
  fill: none; stroke: var(--teal-bright); stroke-width: 2.5; stroke-linecap: round;
}
.mes-flow__arrow .dash { stroke-dasharray: 5 6; animation: piq-flow 3s linear infinite; }

/* Coming next (Data) ----------------------------------------------------- */

.mes-roadmap { padding: 48px; border-radius: 32px; background: var(--navy); color: var(--white); }
.mes-roadmap__head { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; font-size: 18px; font-weight: 600; }
.mes-roadmap h2 { margin-top: 16px; font-size: clamp(30px, 3.4vw, 40px); line-height: 1.1; font-weight: 700; letter-spacing: -0.02em; color: var(--white); }
.mes-roadmap__cols { display: flex; flex-wrap: wrap; gap: 32px; margin-top: 32px; }
.mes-roadmap__cols > div { flex: 1 1 260px; }
.mes-roadmap h3 { font-size: 20px; font-weight: 600; color: var(--white); }
.mes-roadmap__cols p { margin-top: 8px; font-size: 15px; line-height: 1.55; color: var(--mist); }
.mes-roadmap__note { margin-top: 28px; font-size: 13px; color: var(--mist); }

/* Responsive ------------------------------------------------------------- */

@media (max-width: 960px) {
  .mes-ladder { margin-top: 40px; padding-top: 0; }
  .mes-ladder__line, .mes-ladder__end { display: none; }
  .mes-rung { margin-top: 0; padding-top: 0; }
}

@media (max-width: 720px) {
  .mes-hero { padding-top: 56px; }
  .mes-hero .container--wide { padding-bottom: 64px; }
  .mes-photo { height: 300px; }
  .mes-float { padding: 10px 14px; }
  .mes-float--a { left: 16px; top: 16px; }
  .mes-float--b { right: 16px; bottom: 40px; }
  .mes-float__value { font-size: 14px; }
  .mes-floor { padding: 20px 16px 36px; }
  .mes-head__aside { font-size: 16px; }
  .mes-table th:first-child, .mes-table td:first-child { padding-left: 20px; }
  .mes-table tr > :last-child { padding-right: 20px; }
  .mes-flow { flex-direction: column; }
  .mes-flow__box { flex: none; }
  .mes-flow__arrow { transform: rotate(90deg); }
  .mes-roadmap { padding: 32px 24px; }
}
