/*
  =======================================================
  Hero Module Base Styles
  =======================================================
*/

.hero-container {
  width: 100%;
  overflow: visible;
  display: grid;
  row-gap: 20px;
  
}

.hero-content {
  max-width: 1900px;
  width: 100%;
  margin: 200px 20px 50px 0;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
  align-items: start;
}

.ty-text {
  grid-column: 2 / span 7;
  display: flex;
  flex-direction: column;
  justify-content: start;
  align-items: flex-start;
  margin: 30px 0 30px 0; 
}

.ty-text h1 {
  margin: 0 0 30px;
}

/*
  =======================================================
  Combined CTA and Hero Tags Layout
  =======================================================
*/

.download-cta {
  grid-column: 2 / span 7;
  width: 100%;
  justify-content: flex-start;
  display: flex;
}

.hero-tag-repeater {
  grid-column: 2 / span 7; /* Ensures it aligns with text */
  display: flex;
  flex-wrap: wrap; 
  gap: 12px; 
  align-items: flex-end; /* Matches the "good" module */
  padding-bottom: 20px;
  width: fit-content;
  max-width: 100%;
  
}

/* THE FIX: Clean, error-free tag styling */
.hero-tags {
  display: flex;
  align-items: center; /* Vertically centers icon and text inside the pill */
  justify-content: flex-start;
  max-width: 290px;
  background-color: rgba(255, 255, 255, 0.6); 
  color: #1A1A1A;
  padding: 12px 16px; 
  gap: 8px; /* Fixed typo: removed trailing slash */
  border-radius: 3px;
  box-sizing: border-box; 
}

/* Normalize children to prevent margin/height issues */
.hero-tags > * {
  margin: 0; 
  padding: 0;
  line-height: 1.2; 
  flex-shrink: 0; 
  display: flex; 
  align-items: center; 
}

/* Force Icon to match text size */
.hero-tags svg,
.hero-tags i {
  height: 1.2em;
  width: auto;
  display: block;
  flex-shrink: 0;
  color: #1A1A1A;
  fill: #1A1A1A;
}

/* Ensure text paragraph has no extra spacing */
.hero-tags p {
  margin: 0;
  padding: 0;
  line-height: 1.2;
  font-size: 16px; 
}

/* When there's no CTA, let tags align left */
.hero-tag-repeater.no-cta {
  margin-left: 0;
}

/*
  =======================================================
  2. TABLET (max-width: 1023px)
  =======================================================
  Switches to single column but KEEPS LEFT ALIGNMENT
*/
@media (max-width: 1023px) {
  .hero-container {
    min-height: clamp(250px, calc(450px - 15vw), 350px);
  }

  .hero-content {
    max-width: 90%;
    margin: 120px auto 30px;
  }

  /* Span full width but keep alignment LEFT */
  .ty-text, 
  .download-cta, 
  .hero-tag-repeater {
    grid-column: 1 / -1;
    align-items: flex-start; /* Left align items */
    text-align: left; /* Left align text */
  }

  .ty-text {
    margin: 10px 0;
    align-items: flex-start;
  }

  .download-cta {
    justify-content: flex-start;
    margin-bottom: 15px;
  }

  .hero-tag-repeater {
    justify-content: flex-start;
    align-items: flex-end;
    padding-bottom: 10px;
  }
}

=======================================================
  3. MOBILE (max-width: 690px)
  =======================================================
  Stacks vertically, removes grid, KEEPS LEFT ALIGNMENT
*/
@media (max-width: 690px) {
  .hero-container {
    min-height: auto;
    height: auto;
    display: block;
    padding-top: 120px;
    padding-bottom: 40px;
  }

  .hero-content {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0 24px;
    box-sizing: border-box;
  }

  /* --- UPDATED TAGS SECTION --- */
  .hero-tag-repeater {
    width: 100%;
    display: flex;
    flex-wrap: wrap;       /* Allows two items per line */
    justify-content: flex-start;
    align-items: flex-start;
    gap: 10px;             /* Reduced gap to fit two items */
    margin-bottom: 24px;   /* Space underneath before the heading */
    padding-bottom: 0;
  }

  .hero-tags {
    padding: 6px 12px;     
    font-size: 13px;     
    max-width: calc(50% - 5px); 
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 6px;              
  }
  
  .hero-tags p {
    margin: 0;
    line-height: 1.4;
  }

  .hero-tags svg, 
  .hero-tags i {
    flex-shrink: 0;        
    width: 14px;           
    height: 14px;
  }

  .ty-text {
    width: 100%;
    margin: 0 0 24px 0;
    align-items: flex-start;
    text-align: left;
  }

  .ty-text h1 {
    font-size: 28px;
    line-height: 1.2;
    margin: 0 0 16px 0;
    word-wrap: break-word;
  }

  .ty-text p {
    font-size: 16px;
    line-height: 1.4;
    margin: 0 0 20px 0;
    width: 100%;
  }

  .download-cta {
    width: 100%;
    justify-content: flex-start;
    margin-bottom: 24px;
    display: flex;
  }
}
/*
  =======================================================
  Background Styling
  =======================================================
*/
.ty-bg-purple {
  background: linear-gradient(135deg, #fff 15%, #f5ebff 30%, #e8c3ff 75%);
}

.ty-bg-purple-turquoise {
  background: linear-gradient(135deg, #fff 5%, #e8c3ff 50%, #baf9f4 90%);
}

.ty-bg-turquoise-purple {
  background: linear-gradient(135deg, #fff 5%, #99f6eb 30%, #e8c3ff 70%);
}

.ty-bg-yellow-purple {
  background: linear-gradient(135deg, #fff 12%, #fff2b2 40%, #e8ceff 75%, #b55dff 90%);
}