/* Help page */

/* SEARCH BAR WRAPPER */
.help-search-wrapper {
    max-width: 800px;
  }
  
  /* SEARCH INPUT CONTAINER */
  .help-search-container {
    position: relative;
    width: 100%;
  }
  
  /* SEARCH INPUT */
  .help-search-input {
    width: 100%;
    border: 1px solid rgba(28, 120, 160, 0.35);
    padding: 8px 36px 8px 12px;
    border-radius: 4px;
  }
  
  /* CLEAR BUTTON (×) */
  .help-clear-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 20px;
    color: #1c78a0;
    opacity: 0.6;
    transition: opacity 0.2s ease;
  }
  
  .help-clear-btn:hover {
    opacity: 1;
  }
  
  /* EXACT MATCH TOGGLE */
  .help-exact-toggle {
    font-size: 0.85em;
    color: #145470;
  }
  
  /* MATCH COUNT */
  .help-search-count {
    font-size: 0.85em;
    color: #145470;
  }
  
  /* STICKY BUTTON BAR */
  .help-controls-top {
    position: sticky;
    top: 0;
    background: #ffffff;
    padding: 10px 0;
    z-index: 50;
    display: flex;
    gap: 8px;
  }
  
  /* INNER WRAPPER */
  .help-controls-inner {
    display: flex;
    gap: 8px;
  }
  
  /* HELP CONTAINER */
  .help-container {
    max-width: 800px;
    margin: 0;
    padding: 20px 0;
    color: #1c78a0;
  }
  
  /* SECTION HEADINGS */
  .help-section {
    margin-bottom: 14px;
  }
  
  .help-section-heading {
    width: 100%;
    background: rgba(28, 120, 160, 0.06);
    border: none;
    padding: 6px 12px;
    color: #1c78a0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    border-radius: 4px;
  }
  
  /* SECTION CONTENT — collapsed by default */
  .help-section-content {
    display: none;
  }

  /* SECTION CONTENT — expanded */
  .help-section-content.open {
    display: block;
  }
  
  /* HELP ITEM */
  .help-item {
    border-top: 1px solid rgba(28, 120, 160, 0.15);
    margin-top: 10px;
    position: relative;
    z-index: 0;
  }
  
  /* QUESTIONS */
  .help-question {
    position: relative;
    width: 100%;
    background: none;
    border: none;
    padding: 12px 12px 12px 28px;
    color: #1c78a0;
    font-weight: 550;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    font-size: 0.78em;
    transition: background 0.25s ease, border-left 0.25s ease;
  }
  
  /* QUESTION WHEN OPEN */
  .help-question.active {
    background: rgba(28, 120, 160, 0.10);
    border-left: 3px solid rgba(28, 120, 160, 0.45);
  }

  /* Helps in answer sections */
  div.help-answer p {
    margin-bottom: .25rem;
  } 

  div.help-answer ul {
    padding-left: 14px;
  }
  
  /* COPY LINK ICON — now inside .help-question */
  .help-copy-link {
    position: absolute;
    right: 32px; /* leaves room for + icon */
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    opacity: 0;
    cursor: pointer;
    background: url('/wp-content/themes/sheddey/assets/icons/link01.svg') center/14px no-repeat;
    transition: opacity 0.2s ease;
  }
  
  .help-question:hover .help-copy-link {
    opacity: 1;
  }
  
  .help-copy-link.copied {
    background-color: #d1ffd1;
    border-radius: 4px;
  }
  
  /* FOCUS STATE FOR KEYBOARD NAVIGATION */
  .help-focus {
    outline: 2px solid #4da3ff;
    border-radius: 4px;
  }
  
  /* ANSWERS — fade + slide animation */
  .help-answer {
    max-height: none;          /* no height cap */
    height: auto;              /* natural height */
    overflow: hidden;
    opacity: 0;
    display: none;
    transform: translateY(-4px) scaleY(0);
    transform-origin: top;
    transition:
        transform 0.35s ease,
        opacity 0.35s ease,
        padding 0.25s ease;

    padding-left: 56px;
    padding-right: 12px;
    padding-top: 0;
    padding-bottom: 0;

    font-size: 0.72em;
    line-height: 1.45;

    background: rgba(28, 120, 160, 0.02);
    border-left: 3px solid transparent;
    border-radius: 3px;
  }

  .help-answer.open {
      display: block;
      opacity: 1;
      transform: translateY(0) scaleY(1);
      padding-top: 10px;
      padding-bottom: 10px;
      border-left: 3px solid rgba(28, 120, 160, 0.45);
  }
  
  /* ICONS */
  .help-icon {
    font-size: 1.4rem;
    transition: transform 0.3s ease, color 0.3s ease;
  }
  
  .help-section-heading.active .help-icon,
  .help-question.active .help-icon {
    transform: rotate(45deg);
    color: #145470;
  }
  
  /* HIGHLIGHT */
  .help-highlight {
    background: #ffeb8a;
    padding: 0 2px;
    border-radius: 2px;
  }
  
  /* MOBILE */
  @media (max-width: 480px) {
    .help-question {
      padding-left: 20px;
    }
    .help-answer {
      padding-left: 36px;
    }
    .help-icon {
      font-size: 1.2rem;
    }
    .help-controls-inner {
      flex-wrap: wrap;
      gap: 6px;
    }
  }
  
  /* OPTIONAL: SMOOTH LINK COPY FEEDBACK */
  .help-copy-link.copied {
    background-color: #d1ffd1;
    border-radius: 4px;
    transition: background-color 0.25s ease;
  }
  
  /* OPTIONAL: ACCESSIBILITY FOCUS OUTLINE */
  .help-question:focus-visible {
    outline: 2px solid #4da3ff;
    border-radius: 4px;
  }
  
  /* OPTIONAL: IMPROVED SPACING FOR LONG HELP LISTS */
  .help-section + .help-section {
    margin-top: 20px;
  }
  
  /* OPTIONAL: ENSURE LINKS INSIDE ANSWERS ARE CLEARLY VISIBLE */
  .help-answer a {
    color: #1c78a0;
    text-decoration: underline;
  }
  
  .help-answer a:hover {
    text-decoration: none;
  }
  
  /* End of HELP page */