/* EH Services Carousel — front-end styles
   This stylesheet intentionally mirrors the user's provided HTML/CSS as closely as possible.
*/

.ehGridHome *{ box-sizing: border-box; }

.ehGridHome{
  --blue:#2B3A9B; --green:#79BE3A;
  --ink:#0b1020; --muted:rgba(20,27,55,.72);
  --r: 26px; --cardR: 26px;
  --grad: linear-gradient(135deg, rgba(43,58,155,.98), rgba(121,190,58,.92));
  --btn: linear-gradient(180deg, rgba(52,108,220,.92), rgba(34,63,168,.92));

  /* carousel controls (set inline on the section) */
  --ehArrowSize: 46px;
  --ehArrowColor: var(--blue);

  /* keep the original visual gap, but expose as a variable for carousel sizing */
  --gap: clamp(14px, 2vw, 22px);

  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  color: var(--ink);
  position: relative; isolation: isolate;
  padding: clamp(18px, 2.6vw, 34px);
  border-radius: calc(var(--r) + 16px);
  overflow: hidden;
  max-width: 1280px; margin: 0 auto;

  background:
    radial-gradient(1300px 700px at 50% -8%, rgba(255,255,255,.55), transparent 60%),
    radial-gradient(950px 520px at 10% 20%, rgba(129,196,255,.55), transparent 55%),
    radial-gradient(950px 520px at 92% 10%, rgba(140,255,220,.42), transparent 56%),
    radial-gradient(900px 520px at 70% 90%, rgba(170,170,255,.35), transparent 60%),
    linear-gradient(180deg, #eaf0ff 0%, #f7fbff 35%, #ffffff 100%);

  border: 1px solid rgba(255,255,255,.6);
  box-shadow: 0 30px 120px rgba(15, 35, 90, .18), inset 0 0 0 1px rgba(255,255,255,.35);
}

.ehGridHome::before{
  content:""; position:absolute; inset: 10px;
  border-radius: calc(var(--r) + 10px);
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.55);
  box-shadow:
    0 0 0 1px rgba(255,255,255,.35),
    0 0 40px rgba(160,210,255,.30),
    0 0 70px rgba(160,255,210,.20);
  z-index:-2; pointer-events:none;
}

.ehHead{ text-align:center; padding: 8px 8px 18px; }
.ehHead h2{
  margin:0; font-weight:950; letter-spacing:-.03em;
  font-size: clamp(22px, 2.6vw, 38px);
  line-height:1.12; color: rgba(11,16,32,.92);
  text-shadow: 0 20px 60px rgba(35,60,160,.18);
}
.ehHead h2 .accent{ background: var(--grad); -webkit-background-clip:text; background-clip:text; color:transparent; }
.ehHead p{ margin:10px auto 0; max-width:78ch; color: rgba(20,27,55,.72); font-size:15px; line-height:1.55; }

/* ===== Carousel Track (keeps the same look as the original grid at each breakpoint) ===== */
.ehServicesCarousel .ehCards{
  display:flex;
  flex-wrap:nowrap;
  gap: var(--gap);
  padding: 10px;
  border-radius: calc(var(--r) + 8px);
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.35);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.22), 0 22px 80px rgba(20,35,90,.12);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);

  overflow-x:auto;
  scroll-snap-type:x mandatory;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}
.ehServicesCarousel .ehCards::-webkit-scrollbar{ display:none; }
.ehServicesCarousel .ehCards{ scrollbar-width:none; }

/* Slide widths = 1 / 2 / 3 cards per view (matching original grid breakpoints) */
.ehServicesCarousel .ehCard{ flex:0 0 100%; scroll-snap-align:start; }
@media (min-width: 680px){
  .ehServicesCarousel .ehCard{ flex-basis: calc((100% - var(--gap)) / 2); }
}
@media (min-width: 1100px){
  .ehServicesCarousel .ehCard{ flex-basis: calc((100% - (var(--gap) * 2)) / 3); }
}

/* ===== Card (original styles) ===== */
.ehCard{
  border-radius: var(--cardR);
  border: 1px solid rgba(255,255,255,.52);
  background:
    radial-gradient(520px 340px at 20% 10%, rgba(255,255,255,.35), transparent 60%),
    radial-gradient(420px 260px at 90% 0%, rgba(140,255,220,.20), transparent 58%),
    radial-gradient(520px 300px at 50% 100%, rgba(129,196,255,.22), transparent 62%),
    rgba(255,255,255,.10);
  box-shadow: 0 22px 70px rgba(15,35,90,.18), inset 0 0 0 1px rgba(255,255,255,.20);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform .25s ease, box-shadow .25s ease;
  overflow:hidden;
  position:relative;
  display:flex;
  flex-direction:column;
  height: 100%;
  cursor:pointer;

  /* equal height */
  min-height: 620px;
}
.ehCard:hover{
  transform: translateY(-6px);
  box-shadow: 0 30px 100px rgba(15,35,90,.22), 0 0 0 1px rgba(255,255,255,.30) inset;
}
.ehCard::before{
  content:""; position:absolute; inset:10px; z-index:1;
  border-radius: calc(var(--cardR) - 6px);
  border: 1px solid rgba(255,255,255,.40);
  box-shadow: 0 0 22px rgba(170,220,255,.20), 0 0 34px rgba(170,255,215,.14);
  pointer-events:none;
}

.ehInner{
  position:relative; z-index:2;
  padding: 16px 18px;
  display:flex; flex-direction:column;
  height:100%;
  gap: 12px;
}

.ehHero{
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.55);
  box-shadow: 0 18px 55px rgba(8,16,56,.16), inset 0 0 0 1px rgba(0,0,0,.05);
  position: relative;
  aspect-ratio: 16/10;
  background: rgba(255,255,255,.08);
}
.ehHero img{
  width:100%; height:100%;
  object-fit: cover;
  display:block;
  transform: scale(1.04);
  transition: transform .6s cubic-bezier(.2,.9,.2,1), filter .6s cubic-bezier(.2,.9,.2,1);
  filter: saturate(1.08) contrast(1.03);
}
.ehCard:hover .ehHero img{ transform: scale(1.12); filter: saturate(1.18) contrast(1.05); }

.ehHero::after{
  content:""; position:absolute; inset:-40% -60%;
  background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,.26) 45%, transparent 55%);
  transform: translateX(-55%) rotate(10deg);
  animation: ehSheen 5.4s ease-in-out infinite;
  pointer-events:none;
}
@keyframes ehSheen{
  0%,55%{ transform:translateX(-60%) rotate(10deg); opacity:0; }
  65%{ opacity:.95; }
  100%{ transform:translateX(45%) rotate(10deg); opacity:0; }
}

.ehHeroFallback{
  width:100%; height:100%;
  background:
    radial-gradient(520px 340px at 20% 10%, rgba(255,255,255,.35), transparent 60%),
    radial-gradient(420px 260px at 90% 0%, rgba(140,255,220,.20), transparent 58%),
    radial-gradient(520px 300px at 50% 100%, rgba(129,196,255,.22), transparent 62%),
    rgba(255,255,255,.10);
}

.ehTitle{ margin:0; font-weight:950; letter-spacing:-.02em; font-size:26px; line-height:1.1; color: rgba(11,16,32,.92); }
.ehTag{
  display:inline-flex; align-items:center; gap:10px;
  padding: 7px 12px; width: fit-content;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.55);
  background: rgba(255,255,255,.26);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 14px 36px rgba(8,16,56,.10);
  font-weight: 850;
  color: rgba(11,16,32,.76);
  font-size: 14px;
}
.ehDot{ width:10px; height:10px; border-radius:999px; background: var(--green); box-shadow: 0 0 0 6px rgba(121,190,58,.16); display:inline-block; }

.ehDesc{
  margin:0; color: rgba(20,27,55,.70);
  font-size:14.5px; line-height:1.62;
  display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:3;
  overflow:hidden; min-height: calc(3 * 1.62em);
}

.ehList{ margin:2px 0 0; padding:0; list-style:none; display:grid; gap:8px; min-height:82px; }
.ehList li{ display:flex; align-items:flex-start; gap:10px; color: rgba(20,27,55,.68); font-size:14px; line-height:1.45; }
.ehList li::before{
  content:""; width:9px; height:9px; border-radius:999px; margin-top:6px;
  background: rgba(121,190,58,.95);
  box-shadow: 0 0 0 6px rgba(121,190,58,.12);
  flex: 0 0 auto;
}

.ehSpacer{ flex:1; }

.ehBtn{
  display:inline-flex; align-items:center; justify-content:space-between; gap:12px;
  width: fit-content;
  padding: 12px 18px;
  border-radius: 999px;
  text-decoration:none !important;
  font-weight:950;
  color: rgba(255,255,255,.92);
  background: var(--btn);
  border: 1px solid rgba(255,255,255,.22);
  box-shadow: 0 18px 42px rgba(10,18,60,.18), inset 0 0 0 1px rgba(255,255,255,.18);
  position: relative; overflow:hidden;
  transition: transform .2s ease, box-shadow .2s ease;
}
.ehBtn:hover{ transform: translateY(-1px); box-shadow: 0 26px 70px rgba(10,18,60,.22); }
.ehBtnIcon{
  width:34px; height:34px; border-radius:999px;
  background: rgba(255,255,255,.16);
  display:grid; place-items:center;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18);
  flex: 0 0 auto;
}
.ehBtnIcon svg{ width:16px; height:16px; color: rgba(255,255,255,.92); }

.ehFoot{ display:flex; align-items:center; gap:10px; margin-top:10px; color: rgba(20,27,55,.70); font-weight:850; font-size:15px; }

/* ===== Arrows (admin-controlled size & color) ===== */
.ehServicesCarousel .ehArrow{
  position:absolute;
  top: 58%;
  transform: translateY(-50%);
  width: var(--ehArrowSize);
  height: var(--ehArrowSize);
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.65);
  background: rgba(255,255,255,.60);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 18px 55px rgba(15,35,90,.18), inset 0 0 0 1px rgba(255,255,255,.35);
  color: var(--ehArrowColor);
  display:grid;
  place-items:center;
  cursor:pointer;
  z-index: 10;
  transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
}
.ehServicesCarousel .ehArrow:hover{
  transform: translateY(-50%) scale(1.04);
  box-shadow: 0 26px 75px rgba(15,35,90,.22), inset 0 0 0 1px rgba(255,255,255,.45);
}
.ehServicesCarousel .ehArrow:active{ transform: translateY(-50%) scale(.98); }
.ehServicesCarousel .ehPrev{ left: 12px; }
.ehServicesCarousel .ehNext{ right: 12px; }

.ehServicesCarousel .ehArrowIcon svg{
  width: calc(var(--ehArrowSize) * .46);
  height: calc(var(--ehArrowSize) * .46);
}

/* Hide arrows on very small screens where swipe is easier */
@media (max-width: 420px){
  .ehServicesCarousel .ehArrow{ opacity:.0; pointer-events:none; }
}

/* Motion */
@media (prefers-reduced-motion: reduce){
  .ehHero::after{ animation:none !important; }
  .ehCard, .ehHero img, .ehBtn, .ehArrow{ transition:none !important; }
}
