/* Version 2 — "Our planned ecosystem" (categories). Layout reference: the crysmed.ae home "Find the right care, your way"
   category row (version2/optimizations/October 19 - Home page, #categories): a sliding row of cards with round arrows
   on the sides. No search bar (client). Content: Crysmed New/Content (Ecosystem / Services: 21 services, each with
   "Enquire about this service"). Icons: crysmed.ae category icons, plus 6 drawn to match (_build/make_icons.py). */
/* background: the same mild tint as the crysmed.ae categories section (category-explorer.css #categories) — teal at
   ~24% at the bottom, fading to nothing at the top */
.eco2 { padding: var(--sec-y) 15px; background: linear-gradient(2deg, #0779943d, transparent); font-family: var(--v2-sans); color: var(--ink-900); }
.eco2__head { display: flex; flex-direction: column; align-items: center; text-align: center; }
.eco2__badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 100px; background: #fff; box-shadow: 0 1px 2px rgba(10,69,80,.06), 0 6px 18px -12px rgba(10,69,80,.3), inset 0 0 0 1px #eef1f1; font-size: 14px; font-weight: 500; line-height: 1; }
.eco2__badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-700); }
.eco2__title { margin-top: 20px; font-size: 46px; font-weight: 500; line-height: 1.08; letter-spacing: -.03em; max-width: 20ch; }
.eco2__title em { font-family: var(--v2-serif); font-style: italic; font-weight: 500; color: var(--brand-700); }
.eco2__sub { margin-top: 16px; max-width: 52ch; font-size: 18px; line-height: 1.4; letter-spacing: -.01em; color: var(--ink-500); }

/* the sliding row */
.eco2__row { position: relative; width: min(100%, 1240px); margin: 48px auto 0; }
.eco2__track { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 6px 4px 18px; scrollbar-width: none; overscroll-behavior-x: contain; }
.eco2__track::-webkit-scrollbar { display: none; }
.svc2 { position: relative; flex: 0 0 calc((100% - 3 * 16px) / 4); scroll-snap-align: start; display: flex; flex-direction: column; padding: 18px 18px 20px; border-radius: 18px; background: #fff;
  box-shadow: inset 0 0 0 1px #e8eded; transition: box-shadow .45s, transform .55s var(--v2-ease); }
.svc2:hover { transform: translateY(-4px); box-shadow: inset 0 0 0 1px var(--brand-tint-strong), 0 24px 40px -28px rgba(10,69,80,.45); }
.svc2__n { position: absolute; top: 16px; right: 18px; font-size: 13px; font-weight: 600; color: #a9b8ba; font-variant-numeric: tabular-nums; }
.svc2__media { display: grid; place-items: center; height: 140px; margin-bottom: 16px; border-radius: 14px; background: linear-gradient(180deg, #f3f8f9, #eaf3f4); overflow: hidden; }
/* the crysmed.ae icons have a white box baked in; multiply lets that white disappear into the tinted tile */
.svc2__media img { max-width: 78%; max-height: 112px; width: auto; height: auto; object-fit: contain; mix-blend-mode: multiply; transition: transform .7s var(--v2-ease); }
.svc2__media img[src$=".svg"] { mix-blend-mode: normal; } /* the 6 drawn icons are already transparent */
.svc2:hover .svc2__media img { transform: scale(1.06) translateY(-3px); }
.svc2__t { font-size: 19px; font-weight: 500; line-height: 1.22; letter-spacing: -.01em; }
.svc2__d { margin-top: 8px; font-size: 14.5px; line-height: 1.5; color: var(--ink-500); }
.svc2__go { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 16px; font-size: 14.5px; font-weight: 600; color: var(--brand-700); text-decoration: none; }
.svc2__go span { transition: transform .4s var(--v2-ease); }
.svc2__go:hover span, .svc2:hover .svc2__go span { transform: translateX(4px); }
.svc2.is-flash { animation: svcFlash 1.8s var(--v2-ease); }
@keyframes svcFlash { 0%, 100% { box-shadow: inset 0 0 0 1px #e8eded; } 25% { box-shadow: inset 0 0 0 2px var(--brand-700), 0 0 0 6px var(--brand-tint); } }

/* round arrows on the sides, as on crysmed.ae */
.eco2__arrow { position: absolute; top: 140px; z-index: 2; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: #fff; color: var(--ink-900); cursor: pointer;
  box-shadow: 0 8px 20px -10px rgba(10,69,80,.45), inset 0 0 0 1px #e3eaea; transition: background-color .3s, color .3s, opacity .3s, transform .4s var(--v2-ease); }
.eco2__arrow svg { width: 18px; height: 18px; }
.eco2__arrow:hover { background: var(--brand-700); color: #fff; transform: scale(1.06); }
.eco2__arrow[disabled] { opacity: 0; pointer-events: none; }
.eco2__arrow--prev { left: -20px; } .eco2__arrow--next { right: -20px; }
/* a thin progress line under the row */
.eco2__bar { width: min(100%, 220px); height: 3px; margin: 10px auto 0; border-radius: 3px; background: #e7eded; overflow: hidden; }
.eco2__bar span { display: block; height: 100%; width: 25%; border-radius: 3px; background: var(--brand-700); transform-origin: left; transition: transform .3s; }

.js .eco2 [data-up] { opacity: 0; transform: translateY(26px); transition: opacity .85s var(--v2-ease), transform .95s var(--v2-ease); transition-delay: var(--d, 0s); }
.js .eco2.is-in [data-up] { opacity: 1; transform: none; }

@media (max-width: 1100px) { .svc2 { flex-basis: calc((100% - 2 * 16px) / 3); } }
@media (max-width: 780px) { .svc2 { flex-basis: calc((100% - 16px) / 2); } .eco2__title { font-size: 38px; } }
@media (max-width: 600px) {
  .eco2__title { font-size: 32px; }
  .eco2__sub { font-size: 16px; }
  .eco2__row { margin-top: 36px; }
  .eco2__track { gap: 12px; margin: 0 -15px; padding: 6px 15px 18px; scroll-padding-inline: 15px; }
  .svc2 { flex-basis: 78%; }
  .eco2__arrow { display: none; }
}
/* 2026-10-19 (tablet: page slid left/right): between 601 and 1200px the page margin is only 15px, so the arrows
   (20px outside the slider) stuck 5px past the screen edge and made the whole page wider than the screen. Pulled
   in to 10px there; phones hide the arrows (above), wider screens keep the original -20px. */
@media (min-width: 601px) and (max-width: 1240px) { .eco2__arrow--prev { left: -10px; } .eco2__arrow--next { right: -10px; } }
@media (prefers-reduced-motion: reduce) { .eco2__track { scroll-behavior: auto; } .js .eco2 [data-up] { opacity: 1; transform: none; transition: none; } }
