/**
 * @file
 * Styles for NextDC Hero Banner block.
 */

.nextdc-hero-banner {
  position: relative;
  width: 100%;
  overflow: hidden;
}

/* Animated Border Frame - Full outline with 40px spacing */
.nextdc-hero-banner__border-frame {
  position: absolute;
  top: 20px;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 10;
  pointer-events: none;
  @media (min-width: 1024px) {
    top: 40px;
    left: 40px;
    right: 40px;
    bottom: 40px;
  }
}

/* Border segments - all four corners */
.nextdc-hero-banner__border-top-left,
.nextdc-hero-banner__border-top-right,
.nextdc-hero-banner__border-bottom-left,
.nextdc-hero-banner__border-bottom-right {
  position: absolute;
  width: 0;
  height: 0;
  box-sizing: border-box;
  animation-duration: 1.2s;
  animation-timing-function: ease-out;
  animation-fill-mode: forwards;
}

/* Top-left corner - animates top and left borders */
.nextdc-hero-banner__border-top-left {
  top: 0;
  left: 0;
  border-top: 2px solid transparent;
  border-left: 2px solid transparent;
  animation-name: borderTopLeft;
}

/* Top-right corner - animates top and right borders */
.nextdc-hero-banner__border-top-right {
  top: 0;
  right: 0;
  border-top: 2px solid transparent;
  border-right: 2px solid transparent;
  animation-name: borderTopRight;
}

/* Bottom-left corner - animates bottom and left borders */
.nextdc-hero-banner__border-bottom-left {
  bottom: 0;
  left: 0;
  border-bottom: 2px solid transparent;
  border-left: 2px solid transparent;
  animation-name: borderBottomLeft;
}

/* Bottom-right corner - animates bottom and right borders */
.nextdc-hero-banner__border-bottom-right {
  bottom: 0;
  right: 0;
  border-bottom: 2px solid transparent;
  border-right: 2px solid transparent;
  animation-name: borderBottomRight;
}

@keyframes borderTopLeft {
  0% {
    width: 0;
    height: 0;
    border-top-color: transparent;
    border-left-color: transparent;
  }
  50% {
    border-top-color: #E8AD1A;
    border-left-color: #E8AD1A;
  }
  100% {
    width: 50%;
    height: 50%;
    border-top-color: #E8AD1A;
    border-left-color: #E8AD1A;
  }
}

@keyframes borderTopRight {
  0% {
    width: 0;
    height: 0;
    border-top-color: transparent;
    border-right-color: transparent;
  }
  50% {
    border-top-color: #E8AD1A;
    border-right-color: #E8AD1A;
  }
  100% {
    width: 50%;
    height: 50%;
    border-top-color: #E8AD1A;
    border-right-color: #E8AD1A;
  }
}

@keyframes borderBottomLeft {
  0% {
    width: 0;
    height: 0;
    border-bottom-color: transparent;
    border-left-color: transparent;
  }
  50% {
    border-bottom-color: #E8AD1A;
    border-left-color: #E8AD1A;
  }
  100% {
    width: 50%;
    height: 50%;
    border-bottom-color: #E8AD1A;
    border-left-color: #E8AD1A;
  }
}

@keyframes borderBottomRight {
  0% {
    width: 0;
    height: 0;
    border-bottom-color: transparent;
    border-right-color: transparent;
  }
  50% {
    border-bottom-color: #E8AD1A;
    border-right-color: #E8AD1A;
  }
  100% {
    width: 50%;
    height: 50%;
    border-bottom-color: #E8AD1A;
    border-right-color: #E8AD1A;
  }
}

/* Logo Container - Absolute to image */
.nextdc-hero-banner__logo {
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: 20;
  overflow: hidden;
  padding-left: 10px;
  padding-bottom: 20px;
  @media (min-width: 1024px) {
    padding-left: 20px;
    padding-bottom: 40px;
  }
}

/* Desktop Logo (min-width 1024px) */
.nextdc-hero-banner__logo--desktop {
  display: none;
  max-width: 280px;
  height: auto;
}

/* Mobile Logo (max-width 1023px) */
.nextdc-hero-banner__logo--mobile {
  display: none;
  max-width: 200px;
  height: auto;
}

/* Show mobile logo from 0px to 1023px */
@media (max-width: 1023px) {
  .nextdc-hero-banner__logo--desktop {
    display: none !important;
  }
  .nextdc-hero-banner__logo--mobile {
    display: block !important;
    transform: translateY(100%);
    opacity: 0;
    animation: slideUpFromBottom 1.2s ease-out forwards;
  }
}

/* Show desktop logo from 1024px and above */
@media (min-width: 1024px) {
  .nextdc-hero-banner__logo--desktop {
    display: block;
    transform: translateY(100%);
    opacity: 0;
    animation: slideUpFromBottom 1.2s ease-out forwards;
  }
  .nextdc-hero-banner__logo--mobile {
    display: none !important;
  }
}

/* Logo Animation - Slide up from bottom to higher position */
@keyframes slideUpFromBottom {
  0% {
    transform: translateY(100%);
    opacity: 0;
  }
  100% {
    transform: translateY(0px); 
    opacity: 1;
  }
}

/* Hero Banner Image */
.nextdc-hero-banner__image {
  width: 100%;
  position: relative; /* Relative positioning for logo absolute positioning */
}

.nextdc-hero-banner__image picture,
.nextdc-hero-banner__image img {
  width: 100%;
  height: auto;
  display: block;
}

/* Banner Image with Aspect Ratio and Focal Point */
.nextdc-hero-banner__image .nextdc-hero-banner__hero-banner-image {
  width: 100%;
  aspect-ratio: 23 / 16; /* Mobile aspect ratio */
  object-fit: cover;
  object-position: center top; /* Focal point on center top */
  display: block;
}

/* Desktop Aspect Ratio */
@media (min-width: 768px) {
  .nextdc-hero-banner__image .nextdc-hero-banner__hero-banner-image {
    aspect-ratio: 22 / 9; 
  }
}

/* Hero Banner Content Section */
.nextdc-hero-banner__content {
  background-color: #1a1a3e; 
  padding: 2rem 1.5rem;
  color: #ffffff !important;

}

/* Description Text with Typography */
.nextdc-hero-banner__description {
  font-family: "Jost", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 22px;
  line-height: 130%; /* 1.3 */
  letter-spacing: 3.2%; /* 0.032em */
  color: #ffffff !important;
  margin-bottom: 0;
}

.nextdc-hero-banner__description p {
  font-family: "Jost", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 22px;
  line-height: 130%;
  letter-spacing: 3.2%;
  color: #ffffff !important;
}

.nextdc-hero-banner__description p:last-child {
  margin-bottom: 0;
}

/* Links in description */
.nextdc-hero-banner__description a {
  color: #3BB7B3 !important; 
  transition: color 0.3s ease;
}

.nextdc-hero-banner__description a:hover,
.nextdc-hero-banner__description a:focus {
  color: #ffffff;
  text-decoration: none;
}

/* Content wrapper for text and icons layout */
.nextdc-hero-banner__content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .nextdc-hero-banner__content-wrapper {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
  }
}

/* Icons Container - aligned with bottom text line */
.nextdc-hero-banner__icons {
  display: flex;
  flex-wrap: nowrap;
  gap: 1rem;
  align-items: center;
  justify-content: flex-start;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .nextdc-hero-banner__icons {
    justify-content: flex-end;
    gap: 1rem;
  }
}

/* Individual Icon */
.nextdc-hero-banner__icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nextdc-hero-banner__icon img {
  width: 24px;
  height: 24px;
  object-fit: contain;
  display: block;
}

/* Responsive Styles */
@media (min-width: 768px) {
  .nextdc-hero-banner__content {
    padding: 3rem 2rem;
  }

  .nextdc-hero-banner__description {
    font-size: 22px;
    flex: 1;
  }
}

@media (min-width: 1024px) {
  .nextdc-hero-banner__content {
    padding: 40px 80px 80px 80px;
    display: flex;
    align-items: flex-end;
  }
}

/* Mobile specific adjustments */
@media (max-width: 767px) {
  .nextdc-hero-banner__content {
    padding: 32px 50px;
  }

  .nextdc-hero-banner__content-wrapper {
    flex-direction: column;
    align-items: flex-start;
  }

  .nextdc-hero-banner__icons {
    gap: 0.75rem;
    justify-content: flex-end;
    width: 100%;
  }
}

