/* MachSoft solution detail pages — additive styles only.
   Keep styles.css unchanged. Palette and type inherit from the existing website. */
.solution-page-main {
  position: relative;
  z-index: 1;
  padding-top: 6rem;
}

.solution-breadcrumb {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 8vw 1.1rem;
  color: #F8FAFC;
  font-size: .9rem;
  text-shadow: 0 1px 5px rgba(0,0,0,.55);
}

.solution-breadcrumb a {
  color: #F8FAFC;
  text-decoration: underline;
  text-decoration-color: rgba(80,255,232,.8);
  text-underline-offset: .2em;
}

.solution-page-hero {
  padding: 0 8vw 3.5rem;
}

.solution-page-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, .85fr);
  align-items: center;
  gap: 2.5rem;
}

.solution-page-hero-copy {
  box-sizing: border-box;
  padding: clamp(1.6rem, 4vw, 3.2rem);
  color: #fff;
  background: rgba(0, 0, 0, .84);
  border-radius: 5.8rem 1.8rem 5.8rem 0;
}

.solution-page-kicker {
  margin: 0 0 .8rem;
  color: #50ffe8;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.solution-page-hero h1 {
  margin: 0 0 1rem;
  color: #fff;
  text-align: left;
  font-size: clamp(2rem, 3.1vw, 3.1rem);
  font-weight: 600;
  line-height: 1.15;
}

.solution-page-hero .solution-page-lead {
  margin: 0;
  color: #fff;
  font-size: 1.03rem;
  line-height: 1.7;
}

.solution-page-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
  margin-top: 1.25rem;
}

.solution-page-tags span {
  border: 1px solid rgba(80,255,232,.45);
  border-radius: 999px;
  padding: .35rem .65rem;
  color: #fff;
  font-size: .8rem;
}

.solution-page-hero-image {
  display: block;
  width: 100%;
  max-height: 390px;
  object-fit: cover;
  border-radius: 1rem;
  box-shadow: 0 14px 36px rgba(0,0,0,.2);
}

.solution-page-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem 1.4rem;
  margin-top: 1.5rem;
}

.solution-page-action {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  min-height: 2.65rem;
  padding: .45rem 0;
  border: 0;
  border-bottom: 1px solid rgba(255,255,255,.75);
  background: transparent;
  color: #fff;
  font-size: .95rem;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 180ms ease, color 180ms ease;
}

.solution-page-action:hover {
  color: #50ffe8;
  border-bottom-color: #50ffe8;
}

.solution-page-action:focus-visible,
.solution-breadcrumb a:focus-visible {
  outline: 2px solid #50ffe8;
  outline-offset: 4px;
}

.solution-page-section {
  padding: clamp(2.3rem, 5vw, 4.5rem) 8vw;
  background: #F8FAFC;
  color: #172033;
}

.solution-page-section:nth-of-type(even) {
  background: #BCCCDC;
}

.solution-page-content {
  max-width: 1100px;
  margin: 0 auto;
}

.solution-page-heading {
  margin: 0 0 1rem;
  color: #172033;
  text-align: left;
  font-size: clamp(1.55rem, 2.2vw, 2.1rem);
  font-weight: 600;
  line-height: 1.25;
}

.solution-page-answer {
  max-width: 900px;
  margin: 0;
  font-size: 1.06rem;
  line-height: 1.8;
}

.solution-capability-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.7rem;
}

.solution-capability {
  padding: 1.35rem 1.45rem;
  background: rgba(255,255,255,.64);
  border: 1px solid rgba(74,98,138,.18);
  border-radius: 1rem;
}

.solution-capability h3 {
  margin: 0 0 .55rem;
  color: #172033;
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.35;
}

.solution-capability p {
  margin: 0;
  line-height: 1.7;
}

.solution-page-list {
  padding-left: 1.25rem;
  margin: 1rem 0 0;
}

.solution-page-list li {
  padding-left: .2rem;
  margin: .55rem 0;
  line-height: 1.65;
}

.solution-page-callout {
  padding: clamp(2rem, 4vw, 3.5rem) 8vw;
  background: #4A628A;
  color: #fff;
}

.solution-page-callout-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.solution-page-callout h2 {
  margin: 0 0 .6rem;
  text-align: left;
  color: #fff;
  font-size: clamp(1.5rem, 2.5vw, 2.25rem);
  font-weight: 600;
}

.solution-page-callout p {
  max-width: 680px;
  margin: 0;
  line-height: 1.7;
}

.solution-page-callout .solution-page-action {
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .solution-page-hero-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
  }
  .solution-page-hero-image {
    max-height: 340px;
  }
}

@media (max-width: 767.98px) {
  .solution-page-main { padding-top: 5rem; }
  .solution-breadcrumb { padding: .5rem 1rem 1rem; }
  .solution-page-hero { padding: 0 1rem 2.25rem; }
  .solution-page-hero-copy { border-radius: 3.2rem 1.35rem 3.2rem 0; padding: 1.6rem 1.25rem; }
  .solution-page-hero h1 { font-size: 1.9rem; }
  .solution-page-hero .solution-page-lead { font-size: .97rem; }
  .solution-page-hero-image { max-height: 260px; }
  .solution-page-section { padding: 2.25rem 1rem; }
  .solution-capability-grid { grid-template-columns: minmax(0, 1fr); }
  .solution-page-callout { padding: 2.25rem 1rem; }
  .solution-page-callout-inner { flex-direction: column; align-items: flex-start; gap: 1rem; }
}


/* Reliable social icons: inline SVG avoids font-glyph and CDN rendering issues. */
.solution-detail-page .footer-distributed .footer-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
}

.solution-detail-page .footer-distributed .footer-icons svg {
  display: block;
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Desktop uses the muted background video. Mobile and reduced-motion modes use
   a lightweight CSS-only technical pattern instead of a frame from the video. */
.solution-detail-page {
  --solution-pattern-background:
    radial-gradient(circle at 18px 18px, rgba(80, 255, 232, .28) 0 1.5px, transparent 1.9px),
    radial-gradient(circle at 74px 74px, rgba(255, 208, 82, .22) 0 1.3px, transparent 1.8px),
    linear-gradient(135deg, transparent 0 48%, rgba(214, 233, 248, .075) 49%, transparent 50%),
    repeating-linear-gradient(0deg, transparent 0 31px, rgba(214, 233, 248, .14) 31px 32px),
    repeating-linear-gradient(90deg, transparent 0 31px, rgba(214, 233, 248, .14) 31px 32px),
    linear-gradient(135deg, #2A4562 0%, #3A5A79 58%, #263F5A 100%);
  --solution-pattern-size:
    120px 120px,
    160px 160px,
    100% 100%,
    32px 32px,
    32px 32px,
    100% 100%;
  --solution-pattern-repeat: repeat, repeat, no-repeat, repeat, repeat, no-repeat;
}

/* Keep the video subtle on desktop; content below the hero uses solid surfaces. */
.solution-detail-page #myVideo {
  filter: brightness(.50) saturate(.72);
  pointer-events: none;
}

/* Image stays below the video hero in the page content. */
.solution-page-hero-inner {
  max-width: 1000px;
  grid-template-columns: minmax(0, 1fr);
}

.solution-page-hero-copy {
  width: 100%;
  max-width: 1000px;
  margin-inline: auto;
}

.solution-page-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, .85fr);
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3.25rem);
}

.solution-page-overview-figure {
  min-width: 0;
  margin: 0;
}

.solution-page-overview-image {
  display: block;
  width: 100%;
  height: auto;
  max-height: 390px;
  object-fit: cover;
  border-radius: 1rem;
  box-shadow: 0 14px 36px rgba(0, 0, 0, .18);
}

.solution-page-overview-figure figcaption {
  margin-top: .65rem;
  color: #41536B;
  font-size: .82rem;
  line-height: 1.45;
}

@media (max-width: 900px) {
  .solution-page-overview-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .solution-page-overview-image {
    max-height: 360px;
  }
}

@media (max-width: 767.98px) {
  .solution-detail-page #myVideo {
    display: none;
  }

  /* CSS-drawn static pattern: no screenshot or extra image request on mobile. */
  .solution-detail-page {
    background-color: #2A4562;
    background-image: var(--solution-pattern-background);
    background-size: var(--solution-pattern-size);
    background-repeat: var(--solution-pattern-repeat);
    background-position: top center;
    background-attachment: scroll;
  }

  .solution-detail-page .solution-breadcrumb,
  .solution-detail-page .solution-page-hero {
    background: transparent;
  }

  .solution-page-overview-grid {
    gap: 1.4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .solution-detail-page #myVideo {
    display: none;
  }

  .solution-detail-page {
    background-color: #2A4562;
    background-image: var(--solution-pattern-background);
    background-size: var(--solution-pattern-size);
    background-repeat: var(--solution-pattern-repeat);
    background-position: top center;
    background-attachment: scroll;
  }

  .solution-detail-page .solution-breadcrumb,
  .solution-detail-page .solution-page-hero {
    background: transparent;
  }
}


/* Theme-matched hover treatment for the explanatory capability cards. */
@media (hover: hover) and (pointer: fine) {
  .solution-capability {
    position: relative;
    overflow: hidden;
    transition:
      transform 220ms ease,
      background-color 220ms ease,
      border-color 220ms ease,
      box-shadow 220ms ease;
  }

  .solution-capability::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: linear-gradient(180deg, #50FFE8 0%, #FFD052 100%);
    opacity: 0;
    transform: scaleY(.55);
    transform-origin: center;
    transition: opacity 220ms ease, transform 220ms ease;
  }

  .solution-capability:hover {
    transform: translateY(-4px);
    background-color: rgba(255, 255, 255, .9);
    border-color: rgba(80, 255, 232, .58);
    box-shadow: 0 12px 28px rgba(23, 48, 75, .13);
  }

  .solution-capability:hover::before {
    opacity: 1;
    transform: scaleY(1);
  }

  .solution-capability h3 {
    transition: color 220ms ease;
  }

  .solution-capability:hover h3 {
    color: #245575;
  }
}

@media (prefers-reduced-motion: reduce) {
  .solution-capability,
  .solution-capability::before,
  .solution-capability h3 {
    transition: none !important;
  }
}

/* MachSoft horizontal infographic timeline. Applied only to the automation-control workflow; other solution pages keep their own content treatment. */
.solution-automation-control-page #scope .automation-workflow-timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  margin: 2.2rem 0 0;
  padding: 0;
  list-style: none;
  counter-reset: scope-route;
}

/* Each list item acts as one timeline milestone, not as a card. */
.solution-automation-control-page #scope .automation-workflow-timeline li {
  position: relative;
  z-index: 1;
  display: block;
  min-width: 0;
  min-height: 13.5rem;
  margin: 0;
  padding: 4.5rem .75rem 1rem;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  color: #172033;
  text-align: center;
  font-size: .96rem;
  line-height: 1.68;
  counter-increment: scope-route;
  transition: color 200ms ease;
}

/* Numbered milestone nodes. */
.solution-automation-control-page #scope .automation-workflow-timeline li::before {
  content: counter(scope-route, upper-roman);
  position: absolute;
  z-index: 2;
  top: 0;
  left: 50%;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin: 0;
  transform: translateX(-50%);
  border: 2px solid #4A628A;
  border-radius: 50%;
  background: linear-gradient(145deg, #FFFFFF 0%, #E8F2F8 100%);
  color: #245575;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .035em;
  line-height: 1;
  box-shadow: 0 0 0 .38rem rgba(248, 250, 252, .94), 0 5px 14px rgba(23, 32, 51, .12);
  transition: transform 200ms ease, border-color 200ms ease, background 200ms ease, color 200ms ease, box-shadow 200ms ease;
}

/* Directional connectors between milestones, using a clean infographic arrow. */
.solution-automation-control-page #scope .automation-workflow-timeline li::after {
  content: "";
  position: absolute;
  z-index: 0;
  top: 1.22rem;
  left: calc(50% + 1.45rem);
  width: calc(100% - 2.9rem);
  height: .58rem;
  background: linear-gradient(90deg, #4A628A 0%, #087EAC 58%, #50FFE8 100%);
  clip-path: polygon(0 35%, calc(100% - 7px) 35%, calc(100% - 7px) 0, 100% 50%, calc(100% - 7px) 100%, calc(100% - 7px) 65%, 0 65%);
  opacity: .72;
}

.solution-automation-control-page #scope .automation-workflow-timeline li:last-child::after {
  display: none;
}

/* Subtle stage-to-stage color progression; yellow is reserved for the final milestone. */
.solution-automation-control-page #scope .automation-workflow-timeline li:nth-child(1)::before {
  border-color: #4A628A;
}
.solution-automation-control-page #scope .automation-workflow-timeline li:nth-child(2)::before {
  border-color: #087EAC;
}
.solution-automation-control-page #scope .automation-workflow-timeline li:nth-child(3)::before {
  border-color: #50BFD2;
}
.solution-automation-control-page #scope .automation-workflow-timeline li:nth-child(4)::before {
  border-color: #D3A52B;
}

@media (hover: hover) and (pointer: fine) {
  .solution-automation-control-page #scope .automation-workflow-timeline li:hover {
    color: #245575;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li:hover::before {
    transform: translateX(-50%) scale(1.07);
    border-color: #087EAC;
    background: linear-gradient(145deg, #FFFFFF 0%, #DDF8FC 100%);
    color: #075985;
    box-shadow: 0 0 0 .38rem rgba(80, 255, 232, .16), 0 7px 18px rgba(8, 126, 172, .2);
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li:hover::after {
    opacity: 1;
  }
}

/* Tablet and mobile: the horizontal illustration becomes a vertical route. */
@media (max-width: 1000px) {
  .solution-automation-control-page #scope .automation-workflow-timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 1.65rem;
    padding: .1rem 0;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline::before {
    content: "";
    position: absolute;
    z-index: 0;
    top: 1.45rem;
    bottom: 1.45rem;
    left: 1.33rem;
    width: 3px;
    background: linear-gradient(180deg, #4A628A 0%, #087EAC 43%, #50FFE8 78%, #FFD052 100%);
    border-radius: 999px;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li {
    min-height: 0;
    padding: .85rem .25rem .85rem 4.35rem;
    text-align: left;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li::before {
    top: 50%;
    left: 0;
    width: 2.7rem;
    height: 2.7rem;
    transform: translateY(-50%);
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li::after {
    display: none;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li:hover::before {
    transform: translateY(-50%) scale(1.05);
  }
}

@media (max-width: 767.98px) {
  .solution-automation-control-page #scope .automation-workflow-timeline li {
    padding: .8rem 0 .8rem 3.75rem;
    font-size: .96rem;
    line-height: 1.65;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline::before {
    left: 1.1rem;
  }

  .solution-automation-control-page #scope .automation-workflow-timeline li::before {
    width: 2.25rem;
    height: 2.25rem;
    font-size: .68rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .solution-automation-control-page #scope .automation-workflow-timeline li,
  .solution-automation-control-page #scope .automation-workflow-timeline li::before,
  .solution-automation-control-page #scope .automation-workflow-timeline li::after {
    transition: none !important;
  }
}


/* Related-solution links: keep the same lightweight surface and hover language. */
.solution-related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.6rem;
}
.solution-related-card {
  display: block;
  height: 100%;
  color: #172033;
  text-decoration: none;
}
.solution-related-card h3::after {
  content: " ↗";
  color: #087EAC;
  white-space: nowrap;
}
.solution-related-card:focus-visible {
  outline: 2px solid #087EAC;
  outline-offset: 4px;
}
.solution-page-overview-grid.is-text-only {
  grid-template-columns: minmax(0, 1fr);
}
.solution-media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 1.6rem;
}
.solution-media-card {
  min-width: 0;
  padding: 1rem;
  border: 1px solid rgba(74,98,138,.18);
  border-radius: 1rem;
  background: rgba(255,255,255,.65);
}
.solution-media-card video,
.solution-media-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: .65rem;
  background: #102036;
}
.solution-media-card h3 {
  margin: .8rem 0 .35rem;
  color: #172033;
  font-size: 1.04rem;
  line-height: 1.4;
}
.solution-media-card p {
  margin: 0;
  line-height: 1.65;
}
@media (max-width: 900px) {
  .solution-related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .solution-media-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .solution-related-grid { grid-template-columns: minmax(0, 1fr); }
}


/* Desktop language switcher is a normal navigation link; no floating overlay remains. */
.solution-detail-page .navigation .solution-language-switch {
  white-space: nowrap;
}

/* Keep the mobile menu and its language item above the page content. */
.solution-detail-page .mobile-nav {
  z-index: 12000;
}

.solution-detail-page .mobile-nav .nav-links {
  z-index: 12001;
}


/* Industrial Automation & Control pilot: four-stage workflow timeline.
   This override is scoped to this page so other solution pages can be reviewed individually. */
.solution-automation-control-page #scope .automation-workflow-timeline {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.solution-automation-control-page #scope .automation-timeline-title {
  display: block;
  margin: 0 0 .65rem;
  color: #172033;
  font-weight: 700;
  line-height: 1.4;
}

.solution-automation-control-page #scope .automation-timeline-description {
  display: block;
  color: #41536B;
  font-size: .91rem;
  line-height: 1.6;
}

@media (min-width: 1000.01px) {
  .solution-automation-control-page #scope .automation-workflow-timeline li {
    min-height: 15rem;
  }
}

.solution-automation-control-page #capabilities .solution-automation-support-capability {
  grid-column: 1 / -1;
}


/* Scroll progress indicator fix for solution-detail pages.
   Keep the indicator pinned directly below the fixed navigation and above page content. */
.solution-detail-page .scroll-indicator-container {
  position: fixed;
  top: 4rem;
  left: 0;
  right: 0;
  z-index: 10000;
  width: 100%;
  height: 0.7vh;
  margin: 0;
  overflow: hidden;
  pointer-events: none;
}

.solution-detail-page .scroll-indicator-bar {
  display: block;
  margin-top: 0;
  width: 0%;
  max-width: 100%;
  height: 0.7vh;
  box-sizing: border-box;
  will-change: width;
}


/* Machine Modernization page — real project galleries and workflow, scoped to this page. */
.solution-modernization-page .modernization-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem;
  margin-top: 1.5rem;
}
.solution-modernization-page .modernization-gallery figure {
  min-width: 0;
  margin: 0;
}
.solution-modernization-page .modernization-gallery img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid rgba(74, 98, 138, .22);
  box-shadow: 0 8px 24px rgba(23, 32, 51, .10);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}
.solution-modernization-page .modernization-gallery figcaption {
  margin-top: .7rem;
  color: #41536B;
  font-size: .92rem;
  line-height: 1.55;
}
@media (hover: hover) and (pointer: fine) {
  .solution-modernization-page .modernization-gallery figure:hover img {
    transform: translateY(-3px);
    border-color: #50BFD2;
    box-shadow: 0 12px 28px rgba(8, 126, 172, .16);
  }
}

.solution-modernization-page .modernization-evidence-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}
.solution-modernization-page .modernization-evidence-card {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(0, 1fr);
  align-items: center;
  gap: 1rem;
  padding: .9rem;
  background: rgba(255,255,255,.66);
  border: 1px solid rgba(74,98,138,.20);
  border-radius: 12px;
  box-shadow: 0 8px 22px rgba(23,32,51,.07);
  transition: border-color 200ms ease, box-shadow 200ms ease, transform 200ms ease;
}
.solution-modernization-page .modernization-evidence-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
}
.solution-modernization-page .modernization-evidence-card h3 {
  margin: 0 0 .45rem;
  color: #172033;
  font-size: 1.02rem;
  line-height: 1.4;
}
.solution-modernization-page .modernization-evidence-card p {
  margin: 0;
  color: #41536B;
  font-size: .92rem;
  line-height: 1.55;
}
@media (hover: hover) and (pointer: fine) {
  .solution-modernization-page .modernization-evidence-card:hover {
    transform: translateY(-2px);
    border-color: #50BFD2;
    box-shadow: 0 12px 28px rgba(8,126,172,.13);
  }
}

/* The same Roman-numeral horizontal process infographic, independently scoped to this solution page. */
.solution-modernization-page #approach .automation-workflow-timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 2.2rem 0 0;
  padding: 0;
  list-style: none;
  counter-reset: modernization-route;
}
.solution-modernization-page #approach .automation-workflow-timeline li {
  position: relative;
  z-index: 1;
  display: block;
  min-width: 0;
  min-height: 14rem;
  margin: 0;
  padding: 4.5rem .75rem 1rem;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  color: #172033;
  text-align: center;
  font-size: .96rem;
  line-height: 1.62;
  counter-increment: modernization-route;
  transition: color 200ms ease;
}
.solution-modernization-page #approach .automation-workflow-timeline li::before {
  content: counter(modernization-route, upper-roman);
  position: absolute;
  z-index: 2;
  top: 0;
  left: 50%;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  transform: translateX(-50%);
  border: 2px solid #4A628A;
  border-radius: 50%;
  background: linear-gradient(145deg, #FFFFFF 0%, #E8F2F8 100%);
  color: #245575;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .035em;
  line-height: 1;
  box-shadow: 0 0 0 .38rem rgba(248,250,252,.94), 0 5px 14px rgba(23,32,51,.12);
  transition: transform 200ms ease, border-color 200ms ease, background 200ms ease, color 200ms ease, box-shadow 200ms ease;
}
.solution-modernization-page #approach .automation-workflow-timeline li::after {
  content: "";
  position: absolute;
  z-index: 0;
  top: 1.22rem;
  left: calc(50% + 1.45rem);
  width: calc(100% - 2.9rem);
  height: .58rem;
  background: linear-gradient(90deg, #4A628A 0%, #087EAC 58%, #50FFE8 100%);
  clip-path: polygon(0 35%, calc(100% - 7px) 35%, calc(100% - 7px) 0, 100% 50%, calc(100% - 7px) 100%, calc(100% - 7px) 65%, 0 65%);
  opacity: .72;
}
.solution-modernization-page #approach .automation-workflow-timeline li:last-child::after { display: none; }
.solution-modernization-page #approach .automation-workflow-timeline li:nth-child(2)::before { border-color: #087EAC; }
.solution-modernization-page #approach .automation-workflow-timeline li:nth-child(3)::before { border-color: #50BFD2; }
.solution-modernization-page #approach .automation-workflow-timeline li:nth-child(4)::before { border-color: #D3A52B; }
.solution-modernization-page #approach .automation-timeline-title {
  display: block;
  margin: 0 0 .55rem;
  color: #172033;
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
}
.solution-modernization-page #approach .automation-timeline-description {
  display: block;
  color: #41536B;
  font-size: .91rem;
  line-height: 1.6;
}
@media (hover: hover) and (pointer: fine) {
  .solution-modernization-page #approach .automation-workflow-timeline li:hover { color: #245575; }
  .solution-modernization-page #approach .automation-workflow-timeline li:hover::before {
    transform: translateX(-50%) scale(1.07);
    border-color: #087EAC;
    background: linear-gradient(145deg, #FFFFFF 0%, #DDF8FC 100%);
    color: #075985;
    box-shadow: 0 0 0 .38rem rgba(80,255,232,.16), 0 7px 18px rgba(8,126,172,.2);
  }
  .solution-modernization-page #approach .automation-workflow-timeline li:hover::after { opacity: 1; }
}
@media (max-width: 1000px) {
  .solution-modernization-page .modernization-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .solution-modernization-page #approach .automation-workflow-timeline {
    display: flex; flex-direction: column; gap: 0; margin-top: 1.65rem; padding: .1rem 0;
  }
  .solution-modernization-page #approach .automation-workflow-timeline::before {
    content: ""; position: absolute; z-index: 0; top: 1.45rem; bottom: 1.45rem; left: 1.33rem; width: 3px;
    background: linear-gradient(180deg, #4A628A 0%, #087EAC 43%, #50FFE8 78%, #FFD052 100%); border-radius: 999px;
  }
  .solution-modernization-page #approach .automation-workflow-timeline li { min-height: 0; padding: .85rem .25rem .85rem 4.35rem; text-align: left; }
  .solution-modernization-page #approach .automation-workflow-timeline li::before { top: 50%; left: 0; width: 2.7rem; height: 2.7rem; transform: translateY(-50%); }
  .solution-modernization-page #approach .automation-workflow-timeline li::after { display: none; }
  .solution-modernization-page #approach .automation-workflow-timeline li:hover::before { transform: translateY(-50%) scale(1.05); }
}
@media (max-width: 767.98px) {
  .solution-modernization-page .modernization-gallery { grid-template-columns: minmax(0,1fr); }
  .solution-modernization-page .modernization-evidence-grid { grid-template-columns: minmax(0,1fr); }
  .solution-modernization-page .modernization-evidence-card { grid-template-columns: minmax(0,1fr); }
  .solution-modernization-page #approach .automation-workflow-timeline li { padding: .8rem 0 .8rem 3.75rem; font-size: .96rem; line-height: 1.65; }
  .solution-modernization-page #approach .automation-workflow-timeline::before { left: 1.1rem; }
  .solution-modernization-page #approach .automation-workflow-timeline li::before { width: 2.25rem; height: 2.25rem; font-size: .68rem; }
}
@media (prefers-reduced-motion: reduce) {
  .solution-modernization-page .modernization-gallery img,
  .solution-modernization-page .modernization-evidence-card,
  .solution-modernization-page #approach .automation-workflow-timeline li,
  .solution-modernization-page #approach .automation-workflow-timeline li::before,
  .solution-modernization-page #approach .automation-workflow-timeline li::after { transition: none !important; }
}


/* V2.1: before/after comparison is part of the mold-change project; TIA Portal photo is separate evidence of HMI engineering. */
.solution-modernization-page .modernization-gallery figure.modernization-before-after {
  grid-column: 1 / -1;
}
.solution-modernization-page .modernization-gallery figure.modernization-before-after img {
  aspect-ratio: auto;
  object-fit: contain;
  max-height: 460px;
  background: #F4F8FC;
}
.solution-modernization-page .modernization-engineering-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 1.4rem;
  align-items: center;
  margin-top: 1.3rem;
  padding: 1rem;
  background: rgba(255,255,255,.68);
  border: 1px solid rgba(74,98,138,.20);
  border-radius: 12px;
  box-shadow: 0 8px 22px rgba(23,32,51,.07);
}
.solution-modernization-page .modernization-engineering-feature img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid rgba(74,98,138,.18);
}
.solution-modernization-page .modernization-engineering-feature .solution-page-answer { margin: 0; }
@media (max-width: 767.98px) {
  .solution-modernization-page .modernization-engineering-feature { grid-template-columns: minmax(0,1fr); }
  .solution-modernization-page .modernization-gallery figure.modernization-before-after img { max-height: none; }
}


/* V2.2: consistent photo-card geometry and full-frame images for the modernization page. */
.solution-modernization-page .modernization-gallery {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 1.2rem;
}
.solution-modernization-page .modernization-gallery figure {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  margin: 0;
  padding: .8rem;
  background: rgba(255,255,255,.78);
  border: 1px solid rgba(74,98,138,.20);
  border-radius: 12px;
  box-shadow: 0 8px 22px rgba(23,32,51,.07);
}
.solution-modernization-page .modernization-gallery figure.modernization-before-after {
  grid-column: auto;
}
.solution-modernization-page .modernization-gallery img,
.solution-modernization-page .modernization-gallery figure.modernization-before-after img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  max-height: none;
  object-fit: contain;
  object-position: center;
  border-radius: 8px;
  border: 1px solid rgba(74,98,138,.16);
  background: #F4F8FC;
  box-shadow: none;
}
.solution-modernization-page .modernization-gallery figcaption {
  flex: 1 0 auto;
  min-height: 3.2em;
  display: flex;
  align-items: flex-start;
  margin-top: .75rem;
  color: #41536B;
  font-size: .92rem;
  line-height: 1.55;
}
.solution-modernization-page .modernization-engineering-feature img {
  width: 100%;
  max-height: 360px;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  object-position: center;
  background: #F4F8FC;
}
.solution-modernization-page .modernization-evidence-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
}
.solution-modernization-page .modernization-evidence-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  padding: 0;
  gap: 0;
  overflow: hidden;
}
.solution-modernization-page .modernization-evidence-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  object-position: center;
  border-radius: 0;
  border: 0;
  background: #F4F8FC;
}
.solution-modernization-page .modernization-evidence-card > div {
  flex: 1 0 auto;
  padding: 1rem;
}
.solution-modernization-page .modernization-evidence-card h3 { margin-top: 0; }
.solution-modernization-page .modernization-evidence-card p { margin-bottom: 0; }
@media (max-width: 767.98px) {
  .solution-modernization-page .modernization-gallery,
  .solution-modernization-page .modernization-evidence-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}


/* V2.2 media-stage treatment: uniform image boxes without cropping original photos. */
.solution-modernization-page .modernization-gallery-media,
.solution-modernization-page .modernization-evidence-media {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  background: #EAF0F6;
}
.solution-modernization-page .modernization-gallery-media::before,
.solution-modernization-page .modernization-evidence-media::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: -12px;
  background-image: var(--gallery-photo);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  filter: blur(18px) saturate(.72);
  opacity: .24;
  transform: scale(1.05);
}
.solution-modernization-page .modernization-gallery-media img,
.solution-modernization-page .modernization-evidence-media img {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  max-height: none;
  object-fit: contain;
  object-position: center;
  padding: .2rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.solution-modernization-page .modernization-gallery figure.modernization-before-after .modernization-gallery-media img {
  aspect-ratio: auto;
  max-height: none;
  object-fit: contain;
}
.solution-modernization-page .modernization-gallery figure:hover .modernization-gallery-media img {
  transform: none;
  border: 0;
  box-shadow: none;
}
.solution-modernization-page .modernization-gallery figure:hover .modernization-gallery-media {
  outline: 1px solid rgba(80,191,210,.75);
  outline-offset: -1px;
}
.solution-modernization-page .modernization-evidence-card .modernization-evidence-media {
  border-radius: 0;
  flex: 0 0 auto;
}
.solution-modernization-page .modernization-engineering-feature img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 360px;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  object-position: center;
  background: #F4F8FC;
}
@media (max-width: 767.98px) {
  .solution-modernization-page .modernization-gallery-media,
  .solution-modernization-page .modernization-evidence-media {
    aspect-ratio: 4 / 3;
  }
}


/* V2.3: balanced galleries, centered full-frame photos, and consistent project-example cards. */
.solution-modernization-page .modernization-gallery {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}
.solution-modernization-page .modernization-gallery-media,
.solution-modernization-page .modernization-evidence-media {
  display: grid;
  place-items: center;
}
.solution-modernization-page .modernization-gallery-media img,
.solution-modernization-page .modernization-evidence-media img {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: 50% 50%;
}
.solution-modernization-page .modernization-evidence-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}
.solution-modernization-page .modernization-evidence-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}
.solution-modernization-page .modernization-evidence-card > div:last-child {
  flex: 1 0 auto;
}
@media (max-width: 1000px) {
  .solution-modernization-page .modernization-gallery,
  .solution-modernization-page .modernization-evidence-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 767.98px) {
  .solution-modernization-page .modernization-gallery,
  .solution-modernization-page .modernization-evidence-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Navigation contact link inherits the original menu treatment. Do not style it as a separate button. */
.solution-detail-page .solution-page-action[href$="#contact"]:focus-visible {
  outline: 2px solid #50ffe8;
  outline-offset: 3px;
}

.solution-detail-page .solution-page-action[href$="#contact"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 2.75rem;
  padding: .6rem .9rem;
  border: 1px solid rgba(80, 255, 232, .72);
  border-radius: .45rem;
  background: rgba(3, 19, 36, .14);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  filter: none;
  transition: color 180ms ease, background-color 180ms ease,
              border-color 180ms ease, box-shadow 180ms ease;
}

.solution-detail-page .solution-page-action[href$="#contact"]:hover,
.solution-detail-page .solution-page-action[href$="#contact"]:focus-visible {
  color: #50ffe8;
  background: rgba(80, 255, 232, .12);
  border-color: #50ffe8;
  font-weight: 600;
  filter: none;
  box-shadow: 0 0 0 3px rgba(80, 255, 232, .12);
  text-decoration: none;
}

@media (prefers-reduced-motion: reduce) {
  .solution-detail-page .solution-page-action[href$="#contact"] {
    transition: none;
  }
}


/* ============================================================
   MACHSOFT DETAIL-PAGE HEADER PILOT v1
   Mirrors the approved homepage header sizing and accent tone.
   Intentionally preserves the original translucent grey header,
   white scroll indicator, existing hero/video layout and mobile nav.
   ============================================================ */

/* Desktop logo: convert the existing transparent mark to white and
   size it like the approved homepage header, preserving its aspect ratio. */
body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child img {
  display: block !important;
  width: clamp(172px, 11.8vw, 184px) !important;
  max-width: none !important;
  max-height: 42px !important;
  height: auto !important;
  padding: 0 !important;
  object-fit: contain !important;
  filter: brightness(0) invert(1) drop-shadow(0 1px 2px rgba(0, 0, 0, 0.18)) !important;
}

/* Shared desktop navigation: logo left, menu grouped and right-aligned. */
@media (min-width: 1351px) {
  body.solution-detail-page > header > div.nav-bar > div.navigation {
    justify-content: flex-start !important;
    gap: clamp(1rem, 1.35vw, 1.45rem) !important;
  }

  body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child {
    margin-right: auto !important;
    flex: 0 0 auto !important;
  }

  body.solution-detail-page > header > div.nav-bar > div.navigation > a:not(:first-child):not(.site-language-switcher) {
    flex: 0 0 auto !important;
    margin: 0 !important;
    text-align: right !important;
  }
}

/* Tablet/laptop: keep the menu compact enough to fit without large gaps. */
@media (min-width: 769px) and (max-width: 1350px) {
  body.solution-detail-page > header > div.nav-bar > div.navigation {
    display: flex !important;
    justify-content: flex-start !important;
    gap: clamp(0.35rem, 0.85vw, 0.75rem) !important;
    padding: 0 clamp(1rem, 2.4vw, 2rem) !important;
    width: 100vw !important;
  }

  body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child {
    flex: 0 0 auto !important;
    margin-right: auto !important;
  }

  body.solution-detail-page > header > div.nav-bar > div.navigation > a:not(:first-child):not(.site-language-switcher) {
    flex: 0 0 auto !important;
    margin: 0 !important;
    text-align: right !important;
    font-size: clamp(0.86rem, 1.1vw, 0.98rem) !important;
  }

  body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child img {
    /* Match the homepage logo size across desktop and laptop widths. */
    width: clamp(172px, 11.8vw, 184px) !important;
    max-width: none !important;
    max-height: 42px !important;
    height: auto !important;
  }
}

/* Menu text sizing and the calmer Siemens-like cyan accent. */
body.solution-detail-page > header > div.nav-bar > div.navigation > a:not(:first-child):not(.site-language-switcher) {
  font-size: clamp(1rem, 1vw, 1.08rem) !important;
  font-weight: 550 !important;
  transition: color 160ms ease !important;
}

body.solution-detail-page > header > div.nav-bar > div.navigation > a:not(:first-child):not(.site-language-switcher):hover,
body.solution-detail-page > header > div.nav-bar > div.navigation > a:not(:first-child):not(.site-language-switcher):focus-visible {
  color: #00A6B2 !important;
}

/* Keep the language control compact; its flag, border and placement stay as-is. */
body.solution-detail-page > header > div.nav-bar > div.navigation > a.site-language-switcher {
  flex: 0 0 auto !important;
}

/* Mobile: retain the existing hamburger menu/background; only use a readable white logo. */
@media (max-width: 768px) {
  body.solution-detail-page .LogoForMobile img {
    content: url("images/logo-transparent-beyaz.webp") !important;
    display: block !important;
    width: auto !important;
    max-width: 156px !important;
    height: 38px !important;
    max-height: none !important;
    object-fit: contain !important;
    filter: none !important;
  }

  body.solution-detail-page .mobile-nav .nav-links a:hover,
  body.solution-detail-page .mobile-nav .nav-links a:focus-visible {
    color: #00A6B2 !important;
  }
}

/* Apply the same accent to the detail-page kicker, tags and link hover states. */
body.solution-detail-page .solution-page-kicker {
  color: #00A6B2 !important;
}

body.solution-detail-page .solution-page-tags span {
  border-color: rgba(0, 166, 178, 0.48) !important;
}

body.solution-detail-page .solution-breadcrumb a {
  text-decoration-color: rgba(0, 166, 178, 0.78) !important;
}

body.solution-detail-page .solution-page-action:hover,
body.solution-detail-page .solution-page-action:focus-visible {
  color: #00A6B2 !important;
  border-bottom-color: #00A6B2 !important;
}

body.solution-detail-page .solution-page-action:focus-visible,
body.solution-detail-page .solution-breadcrumb a:focus-visible {
  outline-color: #00A6B2 !important;
}

@media (prefers-reduced-motion: reduce) {
  body.solution-detail-page > header > div.nav-bar > div.navigation > a,
  body.solution-detail-page .solution-page-action {
    transition: none !important;
  }
}



/* ============================================================
   MACHSOFT DETAIL-PAGE HEADER PILOT v3 — LOGO SIZE FIX
   Use the same tightly-cropped white wordmark as the approved homepage.
   The previous black PNG had a different intrinsic canvas/visible-area ratio,
   so the nominal width did not look as large as the homepage logo.
   No header background, nav placement, scroll indicator, or mobile menu changes.
   ============================================================ */
body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child img {
  content: url("images/logo-transparent-beyaz.webp") !important;
  display: block !important;
  width: clamp(190px, 13vw, 210px) !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  padding: 0 !important;
  object-fit: contain !important;
  filter: none !important;
}

/* Give the logo anchor enough intrinsic room while keeping the nav layout intact. */
@media (min-width: 769px) {
  body.solution-detail-page > header > div.nav-bar > div.navigation > a:first-child {
    flex: 0 0 auto !important;
    min-width: clamp(190px, 13vw, 210px) !important;
  }
}

/* LinkedIn icon correction only — merged onto the approved detail-header v4 stylesheet. */
/* LinkedIn icon parity with the homepage footer: use the same compact white-square brand mark.
   Replaces only the LinkedIn SVG artwork; Instagram and X remain unchanged. */
.solution-detail-page .footer-distributed .footer-icons a[aria-label="LinkedIn"] > svg {
  display: none;
}

.solution-detail-page .footer-distributed .footer-icons a[aria-label="LinkedIn"]::before {
  content: "";
  display: block;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCI+PHJlY3QgeD0iMS41IiB5PSIxLjUiIHdpZHRoPSIyMSIgaGVpZ2h0PSIyMSIgcng9IjIiIGZpbGw9IiNGRkZGRkYiLz48Y2lyY2xlIGN4PSI2LjciIGN5PSI3IiByPSIxLjM1IiBmaWxsPSIjNEE2MjhBIi8+PHBhdGggZmlsbD0iIzRBNjI4QSIgZD0iTTUuNDUgOS4zNWgyLjV2OS4yaC0yLjV6TTEwIDkuMzVoMi40djEuMjVoLjA0Yy4zNC0uNjUgMS4xOC0xLjYgMi43LTEuNiAyLjg4IDAgMy40MiAxLjkgMy40MiA0LjM2djUuMTloLTIuNXYtNC42YzAtMS4xLS4wMi0yLjUyLTEuNTQtMi41Mi0xLjU0IDAtMS43OCAxLjItMS43OCAyLjQ0djQuNjhIMTB6Ii8+PC9zdmc+");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

/* ============================================================
   MOBILE DETAIL MENU — CONTENT-HEIGHT PANEL
   The black dropdown ends after the final navigation item instead
   of covering the rest of the viewport. Only tall menus scroll.
   Scoped to detail pages; header, scroll indicator and galleries stay intact.
   ============================================================ */
@media (max-width: 768px) {
  body.solution-detail-page .mobile-nav {
    height: 40px !important;
    min-height: 40px !important;
    box-sizing: border-box !important;
  }

  body.solution-detail-page .mobile-nav .nav-links {
    position: fixed !important;
    top: 40px !important;
    left: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    width: 100vw !important;
    margin: 0 !important;
    padding: 0 1rem !important;
    box-sizing: border-box !important;
    height: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    background: #000 !important;
    border: 0 !important;
    transition: max-height 220ms ease !important;
    z-index: 12001 !important;
  }

  body.solution-detail-page .mobile-nav > #hamburger-toggle:checked ~ .nav-links {
    top: 40px !important;
    bottom: auto !important;
    height: auto !important;
    max-height: calc(100vh - 40px) !important;
    max-height: calc(100dvh - 40px) !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    -webkit-overflow-scrolling: touch !important;
    padding-bottom: 0 !important;
    background: #000 !important;
  }
}
