/* =================================================
   HERO
================================================= */

.hero-section {
  position: relative;
  padding: 172px 0 56px;
  background: linear-gradient(180deg, #F6F9FF 0%, var(--bg) 100%);
  overflow: hidden;
  isolation: isolate;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: .55;
  z-index: -1;
  animation: drift 16s ease-in-out infinite alternate;
}

.hero-orb-one {
  width: 460px;
  height: 460px;
  top: -160px;
  left: -120px;
  background: radial-gradient(circle, var(--aurora-blue), transparent 70%);
}

.hero-orb-two {
  width: 420px;
  height: 420px;
  top: -40px;
  right: -160px;
  background: radial-gradient(circle, var(--aurora-violet), transparent 70%);
  animation-delay: -6s;
}

.hero-orb-three {
  display: none;
}

@keyframes drift {
  from {
    transform: translate(0,0) scale(1);
  }

  to {
    transform: translate(30px,-20px) scale(1.08);
  }
}

.hero-content h1 {
  font-size: clamp(2.15rem, 4.4vw, 3.3rem);
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}

.hero-content p {
  font-size: 1.1rem;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin: 28px 0 30px;
  flex-wrap: wrap;
}

.btn-primary-custom {
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  color: #fff;
  font-weight: 700;
  padding: 13px 26px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 14px 30px -12px rgba(15,108,189,0.55);
  transition: transform .2s var(--ease), box-shadow .2s;
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  color: #fff;
  box-shadow: 0 18px 34px -12px rgba(15,108,189,0.6);
}

.btn-outline-custom {
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(10px);
  border: 1.5px solid rgba(20,33,61,0.14);
  color: var(--ink);
  font-weight: 700;
  padding: 13px 24px;
  border-radius: 14px;
  transition: border-color .2s, transform .2s var(--ease), background .2s;
}

.btn-outline-custom:hover {
  border-color: var(--blue);
  color: var(--blue-ink);
  transform: translateY(-2px);
  background: #fff;
}

.hero-tags {
  display: flex;
  justify-content: center;
  gap: 12px 22px;
  flex-wrap: wrap;
  margin-bottom: 46px;
}

.hero-tags span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: .86rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.hero-tags i {
  color: var(--good);
}

.hero-image-wrap {
  position: relative;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  padding: 10px;
  background: linear-gradient(135deg, rgba(15,108,189,0.35), rgba(139,124,240,0.25), rgba(41,198,198,0.3));
  box-shadow: var(--shadow-lift);
}

.hero-products-carousel {
  overflow: hidden;
}

.m365-carousel {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius-lg) - 8px);
  min-height: 470px;
  color: #ffffff;
  background:
    radial-gradient(680px 320px at 12% 8%, rgba(79,166,255,0.42), transparent 58%),
    radial-gradient(560px 300px at 92% 92%, rgba(41,198,198,0.30), transparent 58%),
    linear-gradient(135deg, #07152f 0%, #09244a 48%, #0a4c87 100%);
}

.m365-carousel::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.14;
  background-image:
    linear-gradient(rgba(255,255,255,0.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.18) 1px, transparent 1px);
  background-size: 42px 42px;
  pointer-events: none;
}

.m365-carousel .carousel-inner,
.m365-carousel .carousel-item {
  min-height: 470px;
}

.m365-product-slide {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 0.85fr 1.55fr;
  align-items: center;
  gap: 46px;
  min-height: 470px;
  padding: 50px 84px 62px;
}

.m365-product-intro span {
  display: inline-block;
  margin-bottom: 12px;
  color: #bfdbfe;
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.m365-product-intro h3 {
  color: #ffffff;
  font-size: clamp(1.7rem, 2.6vw, 2.35rem);
  margin-bottom: 12px;
}

.m365-product-intro p {
  color: rgba(228,238,251,0.82);
  font-size: .98rem;
  line-height: 1.7;
  margin-bottom: 0;
}

.m365-product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.m365-app-card {
  min-height: 190px;
  padding: 22px;
  border-radius: 20px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.16);
  box-shadow: 0 18px 46px rgba(0,0,0,0.16);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform .25s var(--ease), background .25s, border-color .25s;
}

.m365-app-card:hover {
  transform: translateY(-5px);
  background: rgba(255,255,255,0.18);
  border-color: rgba(255,255,255,0.28);
}

.m365-app-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 14px;
  color: #ffffff;
  font-size: 1.25rem;
  box-shadow: 0 14px 28px -14px rgba(0,0,0,0.8);
}

.m365-app-card h4 {
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
  margin: 0 0 6px;
}

.m365-app-card p {
  color: rgba(228,238,251,0.74);
  font-size: .82rem;
  line-height: 1.55;
  margin: 0;
}

.app-word .m365-app-icon,
.app-outlook .m365-app-icon {
  background: linear-gradient(135deg, #185abd, #41a5ee);
}

.app-excel .m365-app-icon {
  background: linear-gradient(135deg, #107c41, #21a366);
}

.app-powerpoint .m365-app-icon {
  background: linear-gradient(135deg, #c43e1c, #f0642d);
}

.app-onenote .m365-app-icon,
.app-teams .m365-app-icon {
  background: linear-gradient(135deg, #464eb8, #7b83eb);
}

.app-onedrive .m365-app-icon {
  background: linear-gradient(135deg, #0364b8, #0a93e0);
}

.app-sharepoint .m365-app-icon {
  background: linear-gradient(135deg, #03787c, #0fa3a8);
}

.app-custom .m365-app-icon {
  background: linear-gradient(
    135deg,
    var(--m365-custom-app-color, #0F6CBD),
    #41a5ee
  );
}

.m365-app-icon span {
  color: #ffffff;
  font-size: 1.25rem;
  line-height: 1;
}

.m365-carousel .carousel-indicators {
  bottom: 14px;
  margin-bottom: 0;
}

.m365-carousel .carousel-indicators [data-bs-target] {
  width: 9px;
  height: 9px;
  border: 0;
  border-radius: 999px;
  background-color: rgba(255,255,255,0.58);
  opacity: 1;
}

.m365-carousel .carousel-indicators .active {
  width: 26px;
  background-color: #ffffff;
}

.m365-carousel .carousel-control-prev,
.m365-carousel .carousel-control-next {
  top: 50%;
  z-index: 5;
  width: 48px;
  height: 48px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  border: 1px solid rgba(255,255,255,0.24);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 1;
  cursor: pointer;
}

.m365-carousel .carousel-control-prev {
  left: 18px;
}

.m365-carousel .carousel-control-next {
  right: 18px;
}

.m365-carousel .carousel-control-prev:hover,
.m365-carousel .carousel-control-next:hover {
  background: rgba(255,255,255,0.24);
}

.m365-carousel .carousel-control-prev-icon,
.m365-carousel .carousel-control-next-icon {
  width: 1.15rem;
  height: 1.15rem;
}

/* =================================================
   HERO SLIDE ALIGNMENT MODES
================================================= */

.m365-product-slide--left {
  text-align: left;
}

.m365-product-slide--center {
  grid-template-columns: 1fr;
  text-align: center;
  gap: 22px;
  padding: 34px 76px 56px;
  align-content: center;
  justify-items: center;
}

.m365-product-slide--center .m365-product-intro {
  max-width: 760px;
  margin: 0 auto;
}

.m365-product-slide--center .m365-product-grid {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  grid-template-columns: repeat(auto-fit, minmax(180px, 210px));
  justify-content: center;
}

.m365-product-slide--center .m365-app-card {
  min-height: 170px;
  text-align: center;
}

.m365-product-slide--center .m365-app-icon {
  margin-left: auto;
  margin-right: auto;
}

.m365-product-slide--text-only {
  grid-template-columns: 1fr;
}

.m365-product-slide--text-only .m365-product-intro {
  max-width: 760px;
}

.m365-product-slide--text-only.m365-product-slide--center .m365-product-intro {
  margin: 0 auto;
}

.m365-product-slide--text-only.m365-product-slide--left .m365-product-intro {
  margin-right: auto;
}

/* =================================================
   FIX HERO CAROUSEL HEIGHT - ORIGINAL SIZE
================================================= */

@media (min-width: 992px) {
  .m365-carousel {
    height: 470px;
    min-height: 470px;
  }

  .m365-carousel .carousel-inner,
  .m365-carousel .carousel-item {
    height: 470px;
    min-height: 470px;
  }

  .m365-product-slide,
  .m365-product-slide--center,
  .m365-product-slide--text-only {
    height: 470px;
    min-height: 470px;
  }
}

/* =================================================
   RESPONSIVE
================================================= */

@media (max-width: 991px) {
  .hero-section {
    padding: 146px 0 48px;
  }

  .m365-carousel,
  .m365-carousel .carousel-inner,
  .m365-carousel .carousel-item,
  .m365-product-slide,
  .m365-product-slide--center,
  .m365-product-slide--text-only {
    height: auto;
    min-height: auto;
  }

  .m365-product-slide,
  .m365-product-slide--center {
    grid-template-columns: 1fr;
    gap: 34px;
    padding: 46px 44px 62px;
    text-align: center;
  }

  .m365-product-intro {
    max-width: 760px;
    margin: 0 auto;
  }

  .m365-product-grid,
  .m365-product-slide--center .m365-product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .m365-app-icon {
    margin-left: auto;
    margin-right: auto;
  }

  .m365-app-card {
    text-align: center;
  }
}

@media (max-width: 575px) {
  .hero-section {
    padding: 128px 0 40px;
  }

  .hero-actions {
    gap: 10px;
  }

  .btn-primary-custom,
  .btn-outline-custom {
    width: 100%;
    justify-content: center;
  }

  .hero-tags {
    margin-bottom: 34px;
  }

  .hero-image-wrap {
    padding: 7px;
    border-radius: 24px;
  }

  .m365-carousel {
    border-radius: 18px;
  }

  .m365-product-slide,
  .m365-product-slide--center {
    padding: 38px 22px 64px;
    gap: 24px;
  }

  .m365-product-grid,
  .m365-product-slide--center .m365-product-grid {
    grid-template-columns: 1fr;
  }

  .m365-product-intro h3 {
    font-size: 1.55rem;
  }

  .m365-product-intro p {
    font-size: .94rem;
  }

  .m365-app-card {
    min-height: auto;
  }

  .m365-carousel .carousel-control-prev,
  .m365-carousel .carousel-control-next {
    width: 40px;
    height: 40px;
  }

  .m365-carousel .carousel-control-prev {
    left: 10px;
  }

  .m365-carousel .carousel-control-next {
    right: 10px;
  }
}
