body {
    font-family: 'Open Sans', sans-serif;
    background: linear-gradient(135deg, #f9f9f2, #fafaf0);
    color: #3a3a3a;
    max-width: 800px;
    margin: 2rem auto;
    padding: 1rem 1.5rem;
    box-sizing: border-box;
  }
  h1 {
    font-weight: 700;
    font-size: 2.8rem;
    color: #556b2f;
    margin-bottom: 0.3rem;
    text-align: center;
  }
  h2.section-title {
    font-weight: 600;
    font-size: 1.8rem;
    color: #556b2f;
    margin-top: 2rem;
    margin-bottom: 0.6rem;
    border-bottom: 2px solid #c3d084;
    padding-bottom: 0.25rem;
  }
  p.welcome {
    font-style: italic;
    color: #7a7a50;
    text-align: center;
    margin-bottom: 2rem;
    letter-spacing: 0.05em;
  }
  input[type="text"], button {
    font-size: 1.1rem;
    padding: 0.75rem;
    border-radius: 8px;
    border: 1.5px solid #aab48f;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 1rem;
    font-family: inherit;
    color: #3a3a3a;
  }
  button {
    background-color: #556b2f;
    color: white;
    cursor: pointer;
    border: none;
    font-weight: 600;
    transition: background-color 0.3s ease;
  }
  button:hover,
  button:focus {
    background-color: #43521d;
    outline: none;
  }
  #curated-toggle {
    display: inline-block;
    margin-bottom: 0.6rem;
    cursor: pointer;
    color: #556b2f;
    font-weight: 600;
    user-select: none;
    font-size: 0.95rem;
  }
  #curated-toggle:hover,
  #curated-toggle:focus {
    text-decoration: underline;
  }

  /* Smooth toggle with max-height transition */
  #curated-section {
    max-height: 1000px; /* enough to show content */
    overflow: hidden;
    transition: max-height 0.5s ease, padding 0.5s ease, margin 0.5s ease;
  }
  #curated-section.hidden {
    max-height: 0;
    padding: 0;
    margin: 0;
  }

  #curated-reflections {
    margin-bottom: 1rem;
  }
  #curated-reflections p {
    margin: 1.1rem 0;
    font-size: 1.15rem;
    line-height: 1.7;
    white-space: pre-wrap;
  }
  #curated-empty {
    font-style: italic;
    color: #999;
    font-size: 1rem;
  }
  /* Suggestion chips styling */
  #quick-suggestions {
    margin-top: 0.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    position: relative;
  }
  .suggestion-chip {
    font-family: 'Open Sans', sans-serif;
    font-weight: 600;
    min-width: 60px;
    max-width: 160px;
    width: auto;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-radius: 20px;
    background-color: #c3d084;
    border: none;
    color: #556b2f;
    cursor: pointer;
    user-select: none;
    box-sizing: border-box;
    transition: background-color 0.3s ease, transform 0.2s ease;
    text-align: center;
  }
  .suggestion-chip:hover,
  .suggestion-chip:focus {
    background-color: #a8b96c;
    outline: none;
    transform: scale(1.05);
  }
  #quick-suggestions::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 3rem;
    height: 100%;
    pointer-events: none;
    background: linear-gradient(to right, rgba(250, 250, 240, 0), #fafaf0);
    transition: opacity 0.3s ease;
  }
  #quick-suggestions.scrolled-end::after {
    opacity: 0;
  }
  #quick-suggestions::-webkit-scrollbar {
    height: 6px;
  }
  #quick-suggestions::-webkit-scrollbar-track {
    background: transparent;
  }
  #quick-suggestions::-webkit-scrollbar-thumb {
    background-color: #c3d084;
    border-radius: 3px;
  }
  #helper-text {
    font-size: 0.9rem;
    color: #7a7a50;
    text-align: center;
    margin-bottom: 1rem;
    font-style: italic;
  }
  #ai-reflection {
    font-style: italic;
    line-height: 1.8;
    white-space: pre-wrap;
    color: #4b4b4b;
    margin-top: 1rem;
    padding: 1rem 1.2rem;     /* added some padding for comfort */
    border-left: 5px solid #c3d084;
    background-color: #fafaf0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(150,150,100,0.1);
    max-height: 300px;       /* limit max height */
    overflow-y: auto;        /* add vertical scrollbar when needed */
    font-size: 1.15rem;
  }

  a.custom-link {
    color: #556b2f;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
    display: inline-block;
    margin-top: 2rem;
    text-align: center;
    font-size: 1.1rem;
  }
  a.custom-link:hover,
  a.custom-link:focus {
    text-decoration: underline;
  }
  button#reflect-btn {
    width: 100%;
    max-width: 240px;
    margin-left: auto;
    margin-right: auto;
    display: block;
  }
  @media(min-width: 480px) {
    button#reflect-btn {
      width: auto;
      padding: 0.75rem 2rem;
    }
  }

  .poem {
    max-width: 700px;
    margin: 1.6em 0;
    text-align: center;
    line-height: 1.0;
    white-space: pre-wrap;
    font-size: 1.2em;
    border: 1px solid #e0e0e0; 
    border-radius: 5px; 
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    }
    .footer {
    font-style: italic;
    color: #777;
    margin-top: 2em;
    }