

.hero {
  background: linear-gradient(#f7f7f8);
  padding: 3rem 0 2.5rem;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: center;
}

.hero__copy {
  max-width: 600px;
}

.hero__title {
  font-size: clamp(1.9rem, 2.6vw + 1rem, 3rem);
  line-height: 1.1;
  margin-bottom: 0.75rem;
}

.hero__subtitle {
  font-size: 1.1rem;
  color: #374151;
  margin-bottom: 1.5rem;
}



/* container must be relative */
.hero__visual{
  position: relative;
  display: inline-block;
    overflow: visible;           /* IMPORTANT: lens can hang outside */
}

.hero__imgFrame{
  overflow: hidden;            /* IMPORTANT: image is clipped */
  border-radius: 12px;
  display: inline-block;
}
.hero__imgFrame img{
  display: block;
  width: 100%;
  max-width: 520px;
  height: auto;
}
/* the image stays normal */
.hero__visual img{
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border: 4px solid #b80000;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}
.hero__visual {
  justify-self: end;   /* pushes image to the right */
    margin-right: -60px;
      transform: translateX(40px);


}


/* the magnifier lens */
.img-lens{
  position: absolute;
  width: 170px;              /* lens size */
  height: 120px;
  border-radius: 12px;
  border: 2px solid rgba(184,0,0,0.9);
  box-shadow: 0 18px 45px rgba(0,0,0,0.35);
  background-repeat: no-repeat;

  /* hidden until hover */
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0,0,0);
  transition: opacity 0.12s ease;
}

/* show lens only when hovering the wrapper */
.hero__visual:hover .img-lens{
  opacity: 1;
}

/* optional: disable on touch devices */
@media (hover: none) {
  .img-lens{ display: none; }
}



.what-you-get-card {
  border: 4px solid #b80000; /* red border */
  border-radius: 12px;
  padding: 1.5rem;
  background: #fff;
  transition: all 0.3s ease;
  box-shadow: 0 3px 6px rgba(0,0,0,0.05);
  margin-bottom: 1.5rem;  /* adjust spacing */

}

.what-you-get-card:hover {
  box-shadow: 0 0 20px rgba(184, 0, 0, 0.7); /* red glow */
  transform: translateY(-3px);
}

.what-you-get-card h3 {
  color: #b80000; /* red header */
  margin-bottom: 0.5rem;
}

















.section-intro {
  text-align: center;
  margin-bottom: 2rem;
  height: 100px;
}

.section-intro .section-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #111827; /* near-black for contrast */
}

.section-intro .section-subtitle {
  font-size: 1.1rem;
  color: #374151; /* softer gray */
  max-width: 700px;
  margin: 0 auto;
}


/* Grid */
.solutions-grid{
  display:grid;
  gap:1.25rem;
  grid-template-columns: repeat(4, minmax(0,1fr));
}
@media (max-width: 1100px){ .solutions-grid{ grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px){  .solutions-grid{ grid-template-columns: 1fr; } }

/* Tall cards */
.solution-card{
  position:relative;
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:.5rem;
  min-height: 360px;                     /* taller rectangle */
  padding:1.25rem 1.25rem 1.5rem;
  border:4px solid #b22222;              /* brand red */
  border-radius:14px;
  background:#fff;
  box-shadow:0 0 12px rgba(178,34,34,.35);
  transition:transform .2s ease, box-shadow .2s ease;
}
.solution-card:hover{
  transform:translateY(-4px);
  box-shadow:0 0 22px rgba(178,34,34,.55);
}

/* Icon (swap to SVG later if you want) */
.card-icon{
  display:inline-grid; place-items:center;
  width:56px; height:56px;
  border-radius:12px;
  background:#f3f4f6;
  font-size:28px; line-height:1;
  margin-bottom:.25rem;
}

/* Text layers */
.solution-card h3{
  margin:.1rem 0 .15rem;
  font-weight:800;
}
.solution-card .benefit{
  margin:0;
  font-weight:600;
  color:#111827;
}
.solution-card .subtext{
  margin:0;
  color:#555;
}

/* Bullets */
.feature-list{
  margin:.5rem 0 0 0;
  padding-left:1.1rem;
  color:#374151;
}
.feature-list li{ margin:.15rem 0; }




/* Why Choose Fidelis section */
#why-fidelis {
  margin-top: 3rem; /* spacing below focus area */
  padding: 2rem 1rem;
}

#why-fidelis .why-head {
  text-align: center;
  margin-bottom: 2rem;
}

.why-grid {
  display: grid;
  gap: 1rem;
}

.why-card {
  border: 4px solid #b22222;   /* red border */
  border-radius: 12px;
  background: #fff;
  padding: 1.25rem;
  box-shadow: 0 0 12px rgba(178, 34, 34, 0.35);
  transition: transform .2s ease, box-shadow .2s ease;
}

.why-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 20px rgba(178, 34, 34, 0.55);
}

.why-card h3 {
  margin: 0 0 .35rem 0;
}

/* CTA buttons at the bottom */
.why-cta {
  margin-top: 1.5rem;
  text-align: center;
}

.why-cta .btn {
  display: inline-block;
  padding: .65rem 1rem;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  margin: 0 .5rem;
}

.why-cta .btn-primary {
  background: #b22222;
  color: #fff;
}

.why-cta .btn-ghost {
  background: #fff;
  color: #111827;
  border: 2px solid #e5e7eb;
}


.why-card .subtext {
  font-size: 0.9rem;
  color: #555;   /* softer color than main text */
  margin-top: 0.5rem;
}



/* ===== Outsourcing Section ===== */
#outsourcing {
  margin-top: 3rem;
  padding: 2rem 1rem;
  background: #f7f7f8; /* same as hero gradient base */
}

#outsourcing .section-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #111827;
}

#outsourcing .section-subtitle {
  font-size: 1.1rem;
  color: #374151;
  max-width: 700px;
  margin: 0 auto 2rem;
}

/* Grid reused from Core Solutions */
#outsourcing .solutions-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 1100px) {
  #outsourcing .solutions-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 560px) {
  #outsourcing .solutions-grid {
    grid-template-columns: 1fr;
  }
}

/* Cards styled to match Core Solutions exactly */
#outsourcing .solution-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .5rem;
  min-height: 360px;
  padding: 1.25rem 1.25rem 1.5rem;
  border: 4px solid #b22222;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 0 12px rgba(178, 34, 34, 0.35);
  transition: transform .2s ease, box-shadow .2s ease;
}
#outsourcing .solution-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 22px rgba(178, 34, 34, 0.55);
}

#outsourcing .solution-card h3 {
  color: #b22222;
  margin: 0.25rem 0;
}

#outsourcing .subtext {
  color: #555;
  font-size: 0.95rem;
}

#outsourcing .feature-list {
  margin-top: 0.5rem;
  color: #374151;
  padding-left: 1.1rem;
}
#outsourcing .feature-list li {
  margin: .15rem 0;
}

/* Icons to match top section */
#outsourcing .card-icon {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: #f3f4f6;
  font-size: 28px;
  line-height: 1;
  margin-bottom: .25rem;
}







.demo-play {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.12);
  background: rgba(255,255,255,0.9);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.demo-play:hover {
  transform: scale(1.04);
}

.demo-play i {
  font-size: 14px;
}

/* Modal */
.demo-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
}

.demo-modal.is-open {
  display: block;
}

.demo-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
}

.demo-modal__panel {
  position: relative;
  width: min(920px, calc(100vw - 32px));
  margin: 6vh auto;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 70px rgba(0,0,0,0.35);
}

.demo-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.demo-modal__close {
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 18px;
}

.demo-modal__body {
  padding: 14px 16px 18px;
}

.demo-modal__body video {
  width: 100%;
  height: auto;
  border-radius: 12px;
}









/* ===========================
   HOME hero image: mobile no-cut
   =========================== */
@media (max-width: 860px){

  /* Stack hero nicely */
  .hero__inner{
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  /* Center + prevent clipping */
  #dsMagnify{
    width: 100%;
    display: flex;
    justify-content: center;
    overflow: visible !important;
    margin-top: 16px;
  }

  .hero__imgFrame{
    width: 100%;
    max-width: 100%;
    overflow: visible !important;
  }

  /* Make image responsive */
  #dsImg{
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    margin: 0 auto;
  }

  /* Touch UX: disable magnifier lens on phones */
  #dsMagnify .img-lens{
    display: none !important;
  }
}

/* ===========================
   FIX: Hero image cut-off on mobile
   =========================== */
@media (max-width: 860px){

  /* Undo desktop right-shift */
  .hero__visual{
    justify-self: center !important;
    margin-right: 0 !important;
    transform: none !important;
  }

  /* Don’t clip the image on mobile */
  .hero__imgFrame{
    overflow: visible !important;
  }

  /* Make sure the screenshot never exceeds the viewport */
  #dsImg{
    max-width: 100% !important;
  }
}
/* ===========================
   FIX: section intro height on mobile
   =========================== */
@media (max-width: 860px){
  .section-intro{
    height: auto !important;
  }
}
/* ===========================
   FIX: Outsourcing subtitle wrap + spacing (mobile)
   =========================== */
@media (max-width: 860px){

  #outsourcing .section-intro{
    padding: 0 16px !important;
    text-align: center;
    margin-bottom: 16px !important;
  }

  #outsourcing .section-subtitle{
    max-width: 40ch !important;
    margin: 0 auto 12px !important;
    overflow-wrap: anywhere !important;
    word-break: normal !important;
    line-height: 1.35 !important;
  }

  #outsourcing .solutions-grid{
    padding: 0 16px !important;
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
}
