/* Hero Pro Standalone Styles
   A modern, professional hero section for EventsXP Rwanda
   Author: Generated by AI Assistant
   Notes:
   - All selectors are namespaced with .hero-pro to avoid collisions.
   - Uses CSS custom properties for easy theming.
*/

.hero-pro {
  /* Brand Tokens - Updated from brand guidelines */
  --hero-bg: #ffffff;
  --hero-accent: #138e9e; /* Primary Viridian Green from brand guidelines */
  --hero-accent-soft: #19abc0; /* Secondary shade of Viridian */
  --hero-accent-tint-bg: #e2f5f7; /* Light brand surface */
  --hero-accent-tint-bg-alt: #d7eef2; /* Secondary light surface */
  --hero-text: #000000; /* Black from brand guidelines */
  --hero-text-soft: #3d4a52; /* Muted supporting text */
  --hero-border: #dbecee; /* Subtle border aligned with tint */
  --hero-radius: 1.25rem;
  --hero-radius-sm: 0.75rem;
  --hero-shadow: 0 8px 24px -8px rgba(19, 142, 158, 0.15),
    0 2px 6px -2px rgba(0, 0, 0, 0.08);
  --hero-gradient: radial-gradient(
      circle at 15% 25%,
      rgba(19, 142, 158, 0.08) 0%,
      transparent 40%
    ),
    radial-gradient(
      circle at 85% 75%,
      rgba(19, 142, 158, 0.06) 0%,
      transparent 40%
    ),
    linear-gradient(135deg, #ffffff 0%, #f8fafb 100%);
  --hero-focus: 0 0 0 3px rgba(19, 142, 158, 0.35);
  --hero-transition: 220ms cubic-bezier(0.4, 0, 0.2, 1);
  background: var(--hero-bg);
  position: relative;
  overflow: clip;
  padding: 3rem 1.25rem clamp(3rem, 6vw, 4rem);
  color: var(--hero-text);
  isolation: isolate;
  margin-top: 0;
}

.hero-pro__bg {
  position: absolute;
  inset: 0;
  background: var(--hero-gradient);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  animation: heroFadeIn 1s ease 0.15s forwards;
}

/* Animated Geometric Background Elements */
.hero-pro::before {
  content: '';
  position: absolute;
  top: 10%;
  right: 8%;
  width: 200px;
  height: 200px;
  background: linear-gradient(
    135deg,
    rgba(19, 142, 158, 0.1),
    rgba(19, 142, 158, 0.05)
  );
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation: float 6s ease-in-out infinite;
  z-index: 0;
}

.hero-pro::after {
  content: '';
  position: absolute;
  bottom: 15%;
  left: 5%;
  width: 150px;
  height: 150px;
  background: linear-gradient(
    45deg,
    rgba(19, 142, 158, 0.08),
    rgba(19, 142, 158, 0.03)
  );
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  animation: float 8s ease-in-out infinite reverse;
  z-index: 0;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px) rotate(0deg);
  }
  25% {
    transform: translateY(-20px) rotate(5deg);
  }
  50% {
    transform: translateY(-10px) rotate(-3deg);
  }
  75% {
    transform: translateY(-25px) rotate(2deg);
  }
}

@keyframes heroFadeIn {
  to {
    opacity: 1;
  }
}

.hero-pro__container {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(2rem, 3vw, 3.5rem);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-pro__content {
  grid-column: span 7;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  width: 100%; /* Ensure it takes full width on smaller screens */
  max-width: 100%; /* Prevent overflow */
}

.hero-pro__eyebrow {
  display: inline-block;
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.25px;
  color: var(--hero-accent);
  background: var(--hero-accent-tint-bg);
  border-radius: var(--hero-radius-sm);
  margin-bottom: 0.5rem;
  border: 1px solid var(--hero-accent); /* Adding a brand color border for better visibility */
}

.hero-pro__title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--hero-text);
}

.hero-pro__accent {
  color: var(--hero-accent);
}

.hero-pro__subtitle {
  font-size: clamp(1.05rem, 1.3vw, 1.25rem);
  line-height: 1.55;
  max-width: 58ch;
  color: var(--hero-text-soft);
}

.hero-pro__value-list {
  list-style: none;
  margin: 1.5rem 0 2rem;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem 1.5rem;
}

.hero-pro__value-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff !important;
  background: var(--hero-accent);
  border: 2px solid var(--hero-accent);
  padding: 0.85rem 1.1rem;
  border-radius: var(--hero-radius-sm);
  box-shadow: 0 4px 12px rgba(19, 142, 158, 0.25), 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: all var(--hero-transition);
}

.hero-pro__value-item i {
  color: #ffffff !important;
  font-size: 1rem;
  font-weight: bold;
  flex-shrink: 0;
}

.hero-pro__value-item:hover {
  background: var(--hero-accent-soft);
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(19, 142, 158, 0.35),
    0 4px 10px rgba(0, 0, 0, 0.15);
  border-color: var(--hero-accent-soft);
}

.hero-pro__value-item:hover i {
  color: #ffffff !important;
}

.hero-pro__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.5rem;
}

.btn {
  --btn-bg: var(--hero-accent);
  --btn-color: #fff;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  padding: 0.95rem 1.4rem;
  border-radius: var(--hero-radius-sm);
  text-decoration: none;
  background: var(--btn-bg);
  color: var(--btn-color);
  box-shadow: 0 4px 14px -4px rgba(19, 142, 158, 0.45);
  transition: background var(--hero-transition),
    transform var(--hero-transition), box-shadow var(--hero-transition);
}
.btn:focus-visible {
  outline: none;
  box-shadow: var(--hero-focus);
}
.btn:hover {
  transform: translateY(-2px);
}
.btn:active {
  transform: translateY(0);
}

.btn--primary {
  --btn-bg: linear-gradient(
    90deg,
    var(--hero-accent) 0%,
    var(--hero-accent-soft) 100%
  );
}
.btn--secondary {
  --btn-bg: #ffffff;
  --btn-color: var(--hero-accent);
  border: 2px solid var(--hero-accent);
  box-shadow: none;
}
.btn--secondary:hover {
  background: var(--hero-accent-tint-bg);
}
.btn--secondary:focus-visible {
  box-shadow: var(--hero-focus);
}

.hero-pro__media {
  grid-column: span 5;
  position: relative;
}
.hero-pro__figure {
  margin: 0;
  position: relative;
  border-radius: var(--hero-radius);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: var(--hero-accent-tint-bg-alt);
  box-shadow: var(--hero-shadow);
}
.hero-pro__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05) contrast(1.02);
  transition: transform 1.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.hero-pro__figure:hover .hero-pro__image {
  transform: scale(1.04);
}
.hero-pro__caption {
  position: absolute;
  inset: auto 0.75rem 0.75rem 0.75rem;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(6px);
  padding: 0.55rem 0.75rem;
  border-radius: 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--hero-text-soft);
  box-shadow: 0 2px 6px -2px rgba(0, 0, 0, 0.15);
}

.hero-pro__badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: #ffffff;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 0.5rem 0.65rem;
  border-radius: 2rem;
  text-transform: uppercase;
  color: var(--hero-accent);
  box-shadow: 0 2px 8px -2px rgba(0, 0, 0, 0.2);
}
.hero-pro__badge i {
  color: var(--hero-accent);
  font-size: 0.85rem;
}

/* Entrance Animations (progressively enhanced) */
.hero-pro [data-animate] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--hero-transition),
    transform 0.6s var(--hero-transition);
}
.hero-pro [data-animate].in {
  opacity: 1;
  transform: translateY(0);
}

/* Reduced Motion: Disable transforms */
@media (prefers-reduced-motion: reduce) {
  .hero-pro__bg {
    animation: none;
    opacity: 1;
  }
  .hero-pro [data-animate] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .hero-pro__image {
    transition: none;
  }
}

/* Responsive */
@media (max-width: 1100px) {
  .hero-pro__content {
    grid-column: span 6;
  }
  .hero-pro__media {
    grid-column: span 6;
  }
}

@media (max-width: 920px) {
  .hero-pro__container {
    grid-template-columns: 1fr;
    gap: 2rem; /* Reduced gap for smaller screens */
  }
  .hero-pro__content,
  .hero-pro__media {
    grid-column: 1 / -1;
  }
  .hero-pro__media {
    max-width: 520px;
    margin: 0 auto;
    order: -1;
  }
  .hero-pro {
    padding-top: calc(
      var(--header-height) + 1rem
    ); /* Account for header height */
    padding-bottom: clamp(2rem, 5vw, 3rem);
  }
  .hero-pro__title {
    font-size: clamp(2.2rem, 7vw, 3.1rem);
  }
  .hero-pro__eyebrow {
    align-self: flex-start; /* Better alignment on mobile */
  }
  .hero-pro__br {
    display: none; /* Remove line break on narrow screens */
  }
}

@media (max-width: 640px) {
  .hero-pro__value-list {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem; /* Tighter spacing */
  }
  .hero-pro__badge {
    top: 0.55rem;
    left: 0.55rem;
  }
  .hero-pro__content {
    gap: 1.25rem; /* Tighter spacing between content elements */
  }
  .hero-pro__figure {
    aspect-ratio: 16 / 10; /* Wider aspect ratio for better visibility */
  }
  .hero-pro {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
}

@media (max-width: 460px) {
  .hero-pro__value-list {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
  .hero-pro__value-item {
    padding: 0.5rem 0.75rem; /* Slightly smaller padding */
  }
  .hero-pro__ctas {
    flex-direction: column;
    align-items: stretch;
    margin-top: 0;
  }
  .hero-pro__eyebrow {
    font-size: 0.75rem;
    padding: 0.4rem 0.65rem;
  }
  .hero-pro__subtitle {
    font-size: 1rem;
    line-height: 1.5;
  }
  .hero-pro__figure {
    aspect-ratio: 4 / 3; /* More compact for mobile */
  }
  .btn {
    padding: 0.8rem 1.2rem; /* Slightly smaller padding */
    text-align: center;
    justify-content: center;
  }
}

/* Extra small devices */
@media (max-width: 375px) {
  .hero-pro {
    padding: calc(var(--header-height) + 1rem) 0.5rem 2rem;
  }
  .hero-pro__title {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }
  .hero-pro__caption {
    font-size: 0.65rem;
    padding: 0.45rem 0.65rem;
    bottom: 0.5rem;
    left: 0.5rem;
    right: 0.5rem;
  }
}

/* Dark Mode (if user sets prefers-color-scheme dark; keep hero light-brand oriented) */
@media (prefers-color-scheme: dark) {
  .hero-pro {
    --hero-bg: #0f1415;
    --hero-text: #f5f7f7;
    --hero-text-soft: #becacc;
    --hero-border: #1f2d30;
  }
  .hero-pro,
  .hero-pro__value-item {
    background: #121c1e;
  }
  .hero-pro__value-item {
    border-color: #1f2d30;
  }
  .hero-pro__value-item:hover {
    background: #162427;
  }
  .hero-pro__caption {
    background: rgba(18, 28, 30, 0.85);
    color: #e2f5f7;
  }
  .btn--secondary {
    --btn-bg: #121c1e;
    border-color: var(--hero-accent);
    color: var(--hero-accent);
  }
  .btn--secondary:hover {
    background: #162427;
  }
}
