/* ======== Free Resources ======== */
#free-resources {
    text-align: center;
    font-family: 'Poppins', sans-serif;
  }

  /* Header section (white background) */
  .resources-header {
    background-color: #fff;
    padding: 30px 20px 20px; /* reduced top padding for less gap from navbar */
  }

  .section-title {
    color: #e32b68;
    font-size: 3em;
    letter-spacing: 3px;
    margin-bottom: 10px;
  }

  .rainbow {
    width: 140px;
    margin-bottom: 25px;
  }

  .section-description {
    max-width: 800px;
    margin: 0 auto 10px auto;
    font-size: 18px;
    line-height: 1.8;
  }

  /* ======== Framed Resource Cards Section ======== */
  .resources-grid-container {
    background-color: #f8c8d4;
    padding: 70px 80px;
    border-radius: 10px;
    width: 70%;
    margin:  40px auto 20px auto;
  }

  .resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px 60px;
    justify-items: center;
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
  }

  /* Outer frame (colored border area) */
  .resource-card {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 400px;
    height: 300px;
    border-radius: 10px;
    background-color: #e5c9d6; /* Default soft pink */
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-decoration: none;
    position: relative;
  }

  /* Inner image */
  .resource-card img {
    width: 90%;
    height: 90%;
    border-radius: 8px;
    object-fit: cover;
    display: block;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
  }

  /* Text overlay */
  .resource-card h3 {
    position: absolute;
    bottom: 15px;
    width: 100%;
    text-align: center;
    color: #fff;
    font-size: 1.05em;
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
    letter-spacing: 0.5px;
    line-height: 1.4;
  }

  /* Colored backgrounds (matching frames) */
  .resource-card.yellow {
    background-color: #f8d773;
  }

  .resource-card.purple {
    background-color: #d8c5f1;
  }

  /* Hover effect */
  .resource-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  }

  .resource-card:hover img {
    transform: scale(1.05);
  }

/* ========== HELP SECTION ========== */
.help-section {
    text-align: center;
    padding: 50px 0 80px; /* reduce top gap */
  }

  /* Title styling */
  .help-header h2 {
    font-family: 'Chelsea Market', cursive;
    color: #e32b68;
    font-size: 44px;
    margin: 0 auto 40px auto;
  }

  /* Content wrapper */
  .help-content {
    max-width: 800px;
    margin: 0 auto;
  }

  /* Left-aligned text paragraphs */
  .help-text {
    text-align: left;
    color: #333;
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 40px;
  }

  /* Container for image + buttons */
  .help-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 40px;
  }

  .help-image-container {
    position: relative;
    flex: 1 1 400px;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    transform: rotate(-5deg);
  }

  /* yellow background (behind image) */
  .help-image-container::before {
    content: "";
    position: absolute;
    top: 0; /* no offset so image fits inside */
    left: 0;
    width: 300px;  /* slightly larger than image */
    height: 350px;
    background-color: #f6dc79;
    border-radius: 12px;
    z-index: 0;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  }

  /* actual image */
  .help-image-container img {
    position: relative;
    width: 250px;
    border-radius: 10px;
    z-index: 1;
    transform: translateY(20px) translateX(25px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
  }

  /* Right-aligned buttons */
  .help-buttons {
    flex: 1 1 300px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 15px;
  }

  /* Individual button style */
  .help-btn {
    background-color: #79b6d9;
    color: white;
    padding: 14px 30px;
    border-radius: 25px;
    font-size: 16px;
    text-decoration: none;
    width: 350px;
    text-align: center;
    transition: background-color 0.3s ease, transform 0.2s ease;
  }

  .help-btn:hover {
    background-color: #5aa1c2;
    transform: translateY(-2px);
  }


  /* ========== RESPONSIVE DESIGN ========== */
  @media (max-width: 900px) {
    .help-bottom {
      flex-direction: column;
      align-items: center;
      text-align: center;
    }

    .help-buttons {
      align-items: center;
    }

    .help-image-container {
      justify-content: center;
      margin-bottom: 30px;
    }

    .help-image {
      width: 220px;
      margin-left: 0;
      transform: rotate(-5deg);
    }
  }



  /* ======== Responsive Adjustments ======== */
  @media (max-width: 900px) {
    .resources-grid {
      grid-template-columns: 1fr;
    }

    .resources-grid a:nth-child(3) {
      grid-column: auto;
    }

    .help-container {
      grid-template-columns: 1fr;
      text-align: center;
    }

    .help-text p {
      text-align: center;
    }

    .help-image img {
      margin-top: 20px;
      transform: rotate(0deg);
    }
  }
