body {
  background-color: #f5f7fa;
}

h1,
h2,
h3 {
  color: #2c3e50;
}

.container-2 {
  text-align: center;
}

.container-2 p {
  font-size: 24px;
  font-weight: 500px;
  color: #2F4F4F;
}

.underlined-text {
  position: relative;
  display: inline-block;
  text-align: center;
  font-size: 24px;
  margin-top: 40px;
  color: #111;
  padding-bottom: 20px;
  font-weight: 900;
  font-size: 32px;
}

.underlined-text::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: -5px;
  width: 40%;
  height: 4px;
  background-color: #ffe031;
  border-radius: 2px;
}

.chart-container {
  background: white;
  padding: 20px;
  margin-top: 40px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.card-container {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

/* From Uiverse.io by Creatlydev */
.card {
  width: 300px;
  height: 250px ;
  background-color: #f4f5f2;
  text-align: center;
  border-top-left-radius: 4rem;
  border: 2px solid #fff;
  position: relative;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.card__body {
  padding: 2rem 1rem 1.5rem;
  width: 100%;
  /* Removed max-width: 25ch */
  box-sizing: border-box;
}


.card__title {
  font-weight: 800;
  color: #121513;
  font-size: 26px;
  /* Increased from 2px */
  margin-block: 1.2rem 0.75rem;
  word-wrap: break-word;
}

.card__paragraph {
  color: #303830;
  font-size: 22px;
  /* Slightly reduced for balance */
  word-wrap: break-word;
  line-height: 1.4;
  max-width: 100%;
}


.card__ribbon {
  margin-top: 1rem;
  display: grid;
  place-items: center;
  height: 40px;
  background-color: #393e7f;
  position: relative;
  width: 110%;
  left: -5%;
  top: 10px;
  border-radius: 0 0 2rem 2rem;
}

.card__ribbon::after,
.card__ribbon::before {
  content: "";
  position: absolute;
  width: 20px;
  aspect-ratio: 1/1;
  bottom: 100%;
  z-index: -2;
  background-color: #191c39;
}

.card__ribbon::before {
  left: 0;
  transform-origin: left bottom;
  transform: rotate(45deg);
}

.card__ribbon::after {
  right: 0;
  transform-origin: right bottom;
  transform: rotate(-45deg);
}

.card__ribbon-label {
  display: block;
  width: 60px;
  aspect-ratio: 1/1;
  background-color: #fff;
  position: relative;
  transform: translateY(-50%);
  border-radius: 50%;
  border: 6px solid #393e7f;
  display: grid;
  place-items: center;
  font-weight: 900;
  line-height: 1;
  font-size: 1.2rem;
}

.card__ribbon-label::before,
.card__ribbon-label::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  bottom: 50%;
}

.card__ribbon-label::before {
  right: calc(100% + 4px);
  border-bottom-right-radius: 20px;
  box-shadow: 5px 5px 0 #393e7f;
}

.card__ribbon-label::after {
  left: calc(100% + 4px);
  border-bottom-left-radius: 20px;
  box-shadow: -5px 5px 0 #393e7f;
}

.mutual-fund-types {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  /* 3 cards per row by default */
  justify-items: center;
  align-items: start;
  gap: 60px 50px;
  margin: 40px;
}

.responsive-chart-wrapper {
  width: 100%;
  max-width: 600px;    /* limits how wide it can grow */
  height: 350px;        /* fixed height ensures it doesn't overgrow vertically */
  margin: auto;
  padding: 0 1rem;
}
.chart-container {
  padding: 20px;
  margin-top: 40px;
  border-radius: 16px;
  background: transparent;
  /* remove white bg */
  box-shadow: none;
  /* optional: remove card-like effect */
}

.chart-container {
  margin: 20px;
}

.company-list {
  list-style-type: none;
  padding-left: 0;
}

.company-item {
  margin-bottom: 10px;
  padding: 15px;
  border-left: 5px solid;
  font-size: 22px;
}

.mf-warning-box {
  display: flex;
  align-items: center;
  justify-content: space-around;
  /* Vertically center icon and text */
  /* Full screen width */
  background-color: #fff3cd;
  color: #856404;
  border-left: 6px solid #ffc107;
  box-sizing: border-box;
  gap: 30px;
  border-radius: 10px;
}

.mf-warning-icon {
  font-size: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 30%;
}

.mf-warning-text {
  flex: 1;
  font-size: 1.2rem;
  line-height: 1.6;
  text-align: left;
  max-width: 65%;

}

.footer-cta {
  background: linear-gradient(90deg, #e0f7fa, #e8f5e9);
  /* Light teal to green */
  text-align: center;
  padding: 30px 20px;
  font-family: 'Segoe UI', sans-serif;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  margin: 40px auto;
  max-width: 800px;
  color: #1b5e20;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-cta p {
  font-size: 1.4rem;
  margin-bottom: 10px;
}

.footer-cta strong {
  font-size: 1.1rem;
  color: #2e7d32;
}

/* From Uiverse.io by ryota1231 */
.animated-button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 32px;
  border: 4px solid;
  border-color: transparent;
  font-size: 12px;
  margin-top: 20px;
  background-color: #1f387e;
  border-radius: 100px;
  font-weight: 600;
  font-size: 14px;
  color: white;
  box-shadow: 0 0 0 2px #ffffff;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
  text-decoration: none;
}

.animated-button svg {
  position: absolute;
  width: 24px;
  fill: white;
  z-index: 9;
  transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.animated-button .arr-1 {
  right: 16px;
}

.animated-button .arr-2 {
  left: -25%;
}

.animated-button .circle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 15px;
  height: 15px;
  background-color: #c5e5e4;
  border-radius: 50%;
  opacity: 0;
  transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.animated-button .text {
  position: relative;
  z-index: 1;
  transform: translateX(-12px);
  transition: all 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.animated-button:hover {
  box-shadow: 0 0 0 12px transparent;
  color: #212121;
  border-radius: 12px;
}

.animated-button:hover .arr-1 {
  right: -25%;
}

.animated-button:hover .arr-2 {
  left: 16px;
}

.animated-button:hover .text {
  transform: translateX(12px);
}

.animated-button:hover svg {
  fill: #1f387e;
}

.animated-button:active {
  scale: 0.95;
  box-shadow: 0 0 0 4px greenyellow;
}

.animated-button:hover .circle {
  width: 220px;
  height: 220px;
  opacity: 1;
}


@media only screen and (min-width: 600px) and (max-width: 1023px) {
  /* General container spacing */
  body{
    width: 98%;
    overflow-x: hidden;
  }
  .container-2 {
    padding: 0 1rem;
  }

  .underlined-text {
    font-size: 24px;
    padding-bottom: 10px;
  }

  .container-2 p {
    font-size: 18px;
  }

  /* Card layout: 2 per row on tablets */
  .mutual-fund-types {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 30px;
    margin: 20px;
  }

  .card {
    width: 100%;
    max-width: 280px;
    height: auto;
  }

  .card__title {
    font-size: 20px;
  }

  .card__paragraph {
    font-size: 16px;
  }

  /* Company list font size */
  .company-item {
    font-size: 18px;
    padding: 12px;
  }

  /* Warning box */
  .mf-warning-box {
    flex-direction: column;
    text-align: center;
    padding: 20px;
    gap: 16px;
  }

  .mf-warning-icon {
    font-size: 48px;
    max-width: 100%;
  }

  .mf-warning-text {
    font-size: 1rem;
    max-width: 100%;
  }

  /* CTA section */
  .footer-cta p {
    font-size: 1.1rem;
  }

  .footer-cta strong {
    font-size: 1rem;
    text-align: center;
  }
    .responsive-chart-wrapper {
    height: 300px;      /* slightly smaller height for tablets/mobiles */
    padding: 0 0.5rem;
  }
}

@media only screen and (max-width: 600px)  {
  /* Layout adjustments for small screens */
  .mutual-fund-types {
    grid-template-columns: 1fr;
    gap: 30px;
    margin: 10px;
  }
  .underlined-text{
    margin-left: 20px;
  }
  .container-2 p{
    margin-left: 20px;
  }

  .card__title {
    font-size: 18px;
  }

  .card__paragraph {
    font-size: 15px;
  }

  .underlined-text {
    font-size: 22px;
  }

  .container-2 p {
    font-size: 16px;
  }

  .company-item {
    font-size: 16px;
    padding: 10px;
  }

  .footer-cta {
    padding: 20px;
    font-size: 14px;
  }

  .animated-button {
    padding: 10px 24px;
    font-size: 12px;
  }

  .animated-button svg {
    width: 20px;
  }

  .mf-warning-box {
    padding: 16px;
  }

  .mf-warning-icon {
    font-size: 40px;
  }

  .mf-warning-text {
    font-size: 0.95rem;
  }

  .chart-container {
    margin: 10px;
    padding: 10px;
  }
    .responsive-chart-container {
    padding: 0 0.5rem;
  }
}
