{%- comment -%} ── Google Fonts for italic em text ── {%- endcomment -%}
{% if section.settings.italic_font_family == 'georgia-pro' or section.settings.italic_font_family == 'bodoni-moda' or section.settings.italic_font_family == 'instrument-serif' %}
  <link rel="preconnect" href="https://fonts.googleapis.com">
  <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  {% if section.settings.italic_font_family == 'georgia-pro' %}
    <link href="https://fonts.googleapis.com/css2?family=Georgia+Pro:ital,wght@0,400;0,600;0,700;1,400;1,600;1,700&display=swap" rel="stylesheet">
  {% endif %}
  {% if section.settings.italic_font_family == 'bodoni-moda' %}
    <link href="https://fonts.googleapis.com/css2?family=Bodoni+Moda:ital,opsz,wght@0,6..96,400;0,6..96,500;0,6..96,600;0,6..96,700;1,6..96,400;1,6..96,500;1,6..96,600;1,6..96,700&display=swap" rel="stylesheet">
  {% endif %}
  {% if section.settings.italic_font_family == 'instrument-serif' %}
    <link href="https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&display=swap" rel="stylesheet">
  {% endif %}
{% endif %}

{%- style -%}
  /* ── Section padding / margin ── */
  .section-{{ section.id }}-padding {
    padding-top: {{ section.settings.padding_top | times: 0.75 | round: 0 }}px;
    padding-bottom: {{ section.settings.padding_bottom | times: 0.75 | round: 0 }}px;
  }
  @media screen and (min-width: 750px) {
    .section-{{ section.id }}-padding {
      padding-top: {{ section.settings.padding_top }}px;
      padding-bottom: {{ section.settings.padding_bottom }}px;
    }
  }

  .section-{{ section.id }}-margin {
    margin-top: {{ section.settings.mobile_margin_top }}px;
    margin-bottom: {{ section.settings.mobile_margin_bottom }}px;
  }
  @media screen and (min-width: 750px) {
    .section-{{ section.id }}-margin {
      margin-top: {{ section.settings.desktop_margin_top }}px;
      margin-bottom: {{ section.settings.desktop_margin_bottom }}px;
    }
  }

  /* ── Custom color scheme overrides ── */
  .color-scheme-{{ section.id }}.color-custom {
    --color-background: {{ section.settings.custom_colors_background.red }}, {{ section.settings.custom_colors_background.green }}, {{ section.settings.custom_colors_background.blue }};
    --gradient-background: {% if section.settings.custom_gradient_background != blank %}{{ section.settings.custom_gradient_background }}{% else %}{{ section.settings.custom_colors_background }}{% endif %};
    {% if section.settings.custom_image_background != blank %}
      {% # theme-check-disable %}
      --gradient-background: url('{{ section.settings.custom_image_background | img_url: 'master' }}') center center / cover no-repeat;
      {% # theme-check-enable %}
    {% endif %}
    --color-foreground: {{ section.settings.custom_colors_text.red }}, {{ section.settings.custom_colors_text.green }}, {{ section.settings.custom_colors_text.blue }};
  }
  {% if section.settings.custom_mobile_image_background != blank %}
    @media screen and (max-width: 740px) {
      .color-scheme-{{ section.id }}.color-custom {
        {% # theme-check-disable %}
        --gradient-background: url('{{ section.settings.custom_mobile_image_background | img_url: 'master' }}') center center / cover no-repeat;
        {% # theme-check-enable %}
      }
    }
  {% endif %}

  /* ── Bold / strong gradient on heading ── */
  {% if section.settings.enable_gradient %}
    #CustomerReviewsV2-{{ section.id }} .crv2-heading strong {
      background: {{ section.settings.title_gradient_background }};
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
      font-style: normal;
    }
  {% endif %}

  /* ── Italic em styling on heading ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-heading em {
    {% if section.settings.italic_style == 'italic' %}
      text-decoration: none !important;
      font-style: italic !important;
    {% elsif section.settings.italic_style == 'font_family' and section.settings.italic_font_family != 'inherit' %}
      text-decoration: none !important;
      font-style: italic !important;
      {% if section.settings.italic_font_family == 'serif' %}
        font-family: serif !important;
      {% elsif section.settings.italic_font_family == 'georgia-pro' %}
        font-family: 'Georgia Pro', Georgia, serif !important;
      {% elsif section.settings.italic_font_family == 'bodoni-moda' %}
        font-family: 'Bodoni Moda', Georgia, serif !important;
      {% elsif section.settings.italic_font_family == 'instrument-serif' %}
        font-family: 'Instrument Serif', Georgia, serif !important;
      {% elsif section.settings.italic_font_family == 'cursive' %}
        font-family: cursive !important;
      {% endif %}
      {% if section.settings.italic_font_weight != 'inherit' %}
        font-weight: {{ section.settings.italic_font_weight }} !important;
      {% endif %}
    {% else %}
      text-decoration: underline !important;
      font-style: normal !important;
      text-decoration-color: {{ section.settings.underlinetextcolor }} !important;
      text-decoration-thickness: {{ section.settings.underlinethickness }}px !important;
    {% endif %}
  }

  /* ── Heading alignment ── */
  #CustomerReviewsV2-{{ section.id }} .title-wrapper-with-link {
    display: flex;
    flex-direction: column;
    width: 100%;
    {% if section.settings.heading_alignment == 'left' %}
      text-align: left;
      align-items: flex-start;
    {% elsif section.settings.heading_alignment == 'right' %}
      text-align: right;
      align-items: flex-end;
    {% else %}
      text-align: center;
      align-items: center;
    {% endif %}
    margin-top: {{ section.settings.header_top_spacing }}px;
    margin-bottom: {{ section.settings.header_bottom_spacing }}px;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-header-wrap {
    text-align: {{ section.settings.heading_alignment }};
  }
  #CustomerReviewsV2-{{ section.id }} .multicolumn-text {
    text-align: {{ section.settings.heading_alignment }};
  }

  /* ── Rating summary pill ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-rating-summary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: {{ section.settings.rating_summary_bg_color }};
    color: {{ section.settings.summary_text_color }};
    border-radius: {{ section.settings.rating_summary_border_radius }}px;
    padding: 5px 16px;
    font-size: {{ section.settings.rating_summary_font_size }}px;
    {% if section.settings.enable_rating_summary_border %}
      border: {{ section.settings.rating_summary_border_width }}px {{ section.settings.rating_summary_border_style }} {{ section.settings.rating_summary_border_color }};
    {% endif %}
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-summary-stars {
    display: flex;
    gap: 1px;
    align-items: center;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-summary-star {
    width: 13px;
    height: 13px;
    color: {{ section.settings.summary_star_color }};
    display: block;
  }

  /* ── Reviews grid ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: {{ section.settings.card_gap }}px;
  }
  @media screen and (min-width: 750px) {
    #CustomerReviewsV2-{{ section.id }} .crv2-grid {
      grid-template-columns: repeat({{ section.settings.columns_desktop }}, 1fr);
    }
  }

  /* ── Review card ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-card {
    background: rgb(var(--color-background));
    padding: {{ section.settings.card_padding_v }}px {{ section.settings.card_padding_h }}px;
    border: {{ section.settings.card_border_width }}px solid {{ section.settings.card_border_color }};
    border-radius: {{ section.settings.card_border_radius }}px;
    display: flex;
    flex-direction: column;
    gap: {{ section.settings.card_inner_gap }}px;
    {% if section.settings.card_shadow %}
      box-shadow: {{ section.settings.card_shadow_x }}px {{ section.settings.card_shadow_y }}px {{ section.settings.card_shadow_blur }}px {{ section.settings.card_shadow_spread }}px {{ section.settings.card_shadow_color }};
    {% endif %}
  }

  /* ── Review title (quote) ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-card__title {
    font-weight: {{ section.settings.title_font_weight }};
    font-size: {{ section.settings.title_font_size_mobile }}px;
    line-height: 1.2;
    margin: 0;
    color: rgb(var(--color-foreground));
  }
  @media screen and (min-width: 750px) {
    #CustomerReviewsV2-{{ section.id }} .crv2-card__title {
      font-size: {{ section.settings.title_font_size_desktop }}px;
    }
  }

  /* ── Review body text ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-card__body {
    font-size: {{ section.settings.body_font_size }}px;
    line-height: 1.6;
    color: rgb(var(--color-foreground));
    margin: 0;
    flex: 1;
  }

  /* ── Review tags ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-tags {
    display: flex;
    flex-wrap: wrap;
    gap: {{ section.settings.tag_gap }}px;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-tag {
    background: {{ section.settings.tag_bg_color }};
    color: {{ section.settings.tag_text_color }};
    border: {{ section.settings.tag_border_width }}px solid {{ section.settings.tag_border_color }};
    border-radius: {{ section.settings.tag_border_radius }}px;
    font-size: {{ section.settings.tag_font_size }}px;
    padding: {{ section.settings.tag_padding_v }}px {{ section.settings.tag_padding_h }}px;
    white-space: nowrap;
  }

  /* ── Reviewer info ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-reviewer {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: {{ section.settings.reviewer_font_size }}px;
    flex-wrap: wrap;
    color: rgb(var(--color-foreground));
    margin-top: auto;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-reviewer__name {
    font-weight: var(--font-body-weight-bold, 700);
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-verified {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    color: {{ section.settings.verified_badge_color }};
    font-weight: var(--font-body-weight-bold, 700);
    font-size: {{ section.settings.verified_badge_font_size }}px;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-verified svg {
    width: {{ section.settings.verified_badge_font_size | times: 1.2 }}px;
    height: {{ section.settings.verified_badge_font_size | times: 1.2 }}px;
  }

  /* ── View more button ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-view-more-wrap {
    text-align: center;
    margin-top: {{ section.settings.view_more_margin_top }}px;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-view-more-btn {
    display: inline-block;
    cursor: pointer;
    background: {{ section.settings.view_more_bg_color }};
    color: {{ section.settings.view_more_text_color }};
    border: {{ section.settings.view_more_border_width }}px solid {{ section.settings.view_more_border_color }};
    border-radius: {{ section.settings.view_more_border_radius }}px;
    padding: {{ section.settings.view_more_padding_v }}px {{ section.settings.view_more_padding_h }}px;
    font-size: {{ section.settings.view_more_font_size }}px;
    font-weight: {{ section.settings.view_more_font_weight }};
    line-height: 1.2;
    transition: opacity 0.2s ease;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-view-more-btn:hover { opacity: 0.8; }

  /* ── Hidden cards (collapsed state) ── */
  #CustomerReviewsV2-{{ section.id }} .crv2-card--hidden {
    display: none;
  }
  #CustomerReviewsV2-{{ section.id }} .crv2-card--hidden.crv2-card--revealed {
    display: flex;
  }
{%- endstyle -%}

{%- comment -%} ── SECTION WRAPPER ── {%- endcomment -%}
<div
  id="CustomerReviewsV2-{{ section.id }}"
  class="customer-reviews-v2 color-scheme-{{ section.id }} color-{{ section.settings.color_scheme }} gradient content-for-grouping animate-section animate--hidden {{ section.settings.visibility }} section-{{ section.id }}-margin"
>

  {% if section.settings.display_id %}
    <copy-button class="section-id-btn button" data-content="#shopify-section-{{ section.id }}" data-success="false">
      <span class="copy-text">Click to copy section ID</span>
      <span class="copy-success">ID copied successfully!</span>
    </copy-button>
  {% endif %}

  <div class="page-width section-{{ section.id }}-padding isolate">

    {%- comment -%} ── Header ── {%- endcomment -%}
    <div class="animate-item animate-item--child" style="--index:0;">

      {%- comment -%} ── Rating summary pill ── {%- endcomment -%}
      {% if section.settings.show_rating_summary %}
        <div class="crv2-header-wrap">
          <div class="crv2-rating-summary">
            <span class="crv2-summary-stars" aria-hidden="true">
              {% for i in (1..5) %}
                <svg class="crv2-summary-star" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                  <path d="M11.5245 3.46353C11.6741 3.00287 12.3259 3.00287 12.4755 3.46353L14.1329 8.56434C14.1998 8.77035 14.3918 8.90983 14.6084 8.90983H19.9717C20.4561 8.90983 20.6575 9.52964 20.2656 9.81434L15.9266 12.9668C15.7514 13.0941 15.678 13.3198 15.745 13.5258L17.4023 18.6266C17.552 19.0873 17.0248 19.4704 16.6329 19.1857L12.2939 16.0332C12.1186 15.9059 11.8814 15.9059 11.7061 16.0332L7.3671 19.1857C6.97524 19.4704 6.448 19.0873 6.59768 18.6266L8.25503 13.5258C8.32197 13.3198 8.24864 13.0941 8.07339 12.9668L3.73438 9.81434C3.34253 9.52964 3.54392 8.90983 4.02828 8.90983H9.39159C9.6082 8.90983 9.80018 8.77035 9.86712 8.56434L11.5245 3.46353Z" fill="currentColor"/>
                </svg>
              {% endfor %}
            </span>
            <span>{{ section.settings.rating_summary_text }}</span>
          </div>
        </div>
      {% endif %}

      {%- unless section.settings.title == blank -%}
        <div class="title-wrapper-with-link title-wrapper--self-padded-mobile title-wrapper--no-top-margin{% if section.settings.text != blank %} multicolumn-title-with-text{% endif %}">
          <h2 class="title {{ section.settings.heading_size }} title-with-highlight crv2-heading" style="--hightlight-color:{{ section.settings.title_highlight_color }};--gradient-text:{{ section.settings.title_gradient_background }};">
            {{ section.settings.title }}
          </h2>
        </div>
      {%- endunless -%}

      {% if section.settings.show_description and section.settings.text != blank %}
        <div class="multicolumn-text rte animate-item animate-item--child" style="--index:1;">{{ section.settings.text }}</div>
      {% endif %}

    </div>{%- comment -%} /.animate-item index-0 {%- endcomment -%}

    {%- comment -%} ── Reviews grid ── {%- endcomment -%}
    {%- liquid
      assign visible_count = section.settings.initial_visible_count
      assign block_index = 0
    -%}

    <div class="crv2-grid animate-item animate-item--child" style="--index:2;" id="crv2-grid-{{ section.id }}">
      {%- for block in section.blocks -%}
        {%- if block.type == 'review' -%}
          {%- liquid
            assign block_index = block_index | plus: 1
            assign is_hidden = false
            if visible_count > 0 and block_index > visible_count
              assign is_hidden = true
            endif
          -%}
          <div
            class="crv2-card{% if is_hidden %} crv2-card--hidden{% endif %}"
            data-crv2-card
            {{ block.shopify_attributes }}
          >

            {%- comment -%} Stars — rendered via rating-stars-block snippet (same as main-product.liquid) {%- endcomment -%}
            {% render 'rating-stars-block', block: block, margins: false, block_attributes: false %}

            {%- comment -%} Review title {%- endcomment -%}
            {% if block.settings.review_title != blank %}
              <p class="crv2-card__title">{{ block.settings.review_title | escape }}</p>
            {% endif %}

            {%- comment -%} Review body {%- endcomment -%}
            {% if block.settings.review_text != blank %}
              <p class="crv2-card__body">{{ block.settings.review_text }}</p>
            {% endif %}

            {%- comment -%} Tags {%- endcomment -%}
            {%- liquid
              assign has_tags = false
              if block.settings.tag_1 != blank or block.settings.tag_2 != blank or block.settings.tag_3 != blank
                assign has_tags = true
              endif
            -%}
            {% if has_tags %}
              <div class="crv2-tags">
                {% if block.settings.tag_1 != blank %}<span class="crv2-tag">{{ block.settings.tag_1 | escape }}</span>{% endif %}
                {% if block.settings.tag_2 != blank %}<span class="crv2-tag">{{ block.settings.tag_2 | escape }}</span>{% endif %}
                {% if block.settings.tag_3 != blank %}<span class="crv2-tag">{{ block.settings.tag_3 | escape }}</span>{% endif %}
              </div>
            {% endif %}

            {%- comment -%} Reviewer info {%- endcomment -%}
            {% if block.settings.reviewer_name != blank %}
              <div class="crv2-reviewer">
                <span class="crv2-reviewer__name">{{ block.settings.reviewer_name | escape }}</span>
                {% if block.settings.reviewer_meta != blank %}
                  <span>,&nbsp;{{ block.settings.reviewer_meta | escape }}</span>
                {% endif %}
                {% if block.settings.show_verified_badge %}
                  <span class="crv2-verified">
                    <svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
                      <path fill-rule="evenodd" clip-rule="evenodd" d="M9.5924 3.20027C9.34888 3.4078 9.22711 3.51158 9.09706 3.59874C8.79896 3.79854 8.46417 3.93721 8.1121 4.00672C7.95851 4.03705 7.79903 4.04977 7.48008 4.07522C6.6787 4.13918 6.278 4.17115 5.94371 4.28923C5.17051 4.56233 4.56233 5.17051 4.28923 5.94371C4.17115 6.278 4.13918 6.6787 4.07522 7.48008C4.04977 7.79903 4.03705 7.95851 4.00672 8.1121C3.93721 8.46417 3.79854 8.79896 3.59874 9.09706C3.51158 9.22711 3.40781 9.34887 3.20027 9.5924C2.67883 10.2043 2.4181 10.5102 2.26522 10.8301C1.91159 11.57 1.91159 12.43 2.26522 13.1699C2.41811 13.4898 2.67883 13.7957 3.20027 14.4076C3.40778 14.6511 3.51158 14.7729 3.59874 14.9029C3.79854 15.201 3.93721 15.5358 4.00672 15.8879C4.03705 16.0415 4.04977 16.201 4.07522 16.5199C4.13918 17.3213 4.17115 17.722 4.28923 18.0563C4.56233 18.8295 5.17051 19.4377 5.94371 19.7108C6.278 19.8288 6.6787 19.8608 7.48008 19.9248C7.79903 19.9502 7.95851 19.963 8.1121 19.9933C8.46417 20.0628 8.79896 20.2015 9.09706 20.4013C9.22711 20.4884 9.34887 20.5922 9.5924 20.7997C10.2043 21.3212 10.5102 21.5819 10.8301 21.7348C11.57 22.0884 12.43 22.0884 13.1699 21.7348C13.4898 21.5819 13.7957 21.3212 14.4076 20.7997C14.6511 20.5922 14.7729 20.4884 14.9029 20.4013C15.201 20.2015 15.5358 20.0628 15.8879 19.9933C16.0415 19.963 16.201 19.9502 16.5199 19.9248C17.3213 19.8608 17.722 19.8288 18.0563 19.7108C18.8295 19.4377 19.4377 18.8295 19.7108 18.0563C19.8288 17.722 19.8608 17.3213 19.9248 16.5199C19.9502 16.201 19.963 16.0415 19.9933 15.8879C20.0628 15.5358 20.2015 15.201 20.4013 14.9029C20.4884 14.7729 20.5922 14.6511 20.7997 14.4076C21.3212 13.7957 21.5819 13.4898 21.7348 13.1699C22.0884 12.43 22.0884 11.57 21.7348 10.8301C21.5819 10.5102 21.3212 10.2043 20.7997 9.5924C20.5922 9.34887 20.4884 9.22711 20.4013 9.09706C20.2015 8.79896 20.0628 8.46417 19.9933 8.1121C19.963 7.95851 19.9502 7.79903 19.9248 7.48008C19.8608 6.6787 19.8288 6.278 19.7108 5.94371C19.4377 5.17051 18.8295 4.56233 18.0563 4.28923C17.722 4.17115 17.3213 4.13918 16.5199 4.07522C16.201 4.04977 16.0415 4.03705 15.8879 4.00672C15.5358 3.93721 15.201 3.79854 14.9029 3.59874C14.7729 3.51158 14.6511 3.40781 14.4076 3.20027C13.7957 2.67883 13.4898 2.41811 13.1699 2.26522C12.43 1.91159 11.57 1.91159 10.8301 2.26522C10.5102 2.4181 10.2043 2.67883 9.5924 3.20027ZM16.3735 9.86314C16.6913 9.5453 16.6913 9.03 16.3735 8.71216C16.0557 8.39433 15.5403 8.39433 15.2225 8.71216L10.3723 13.5624L8.77746 11.9676C8.45963 11.6498 7.94432 11.6498 7.62649 11.9676C7.30866 12.2854 7.30866 12.8007 7.62649 13.1186L9.79678 15.2889C10.1146 15.6067 10.6299 15.6067 10.9478 15.2889L16.3735 9.86314Z" fill="currentColor"/>
                    </svg>
                    {{ section.settings.verified_badge_text | escape }}
                  </span>
                {% endif %}
              </div>
            {% endif %}

          </div>{%- comment -%} /.crv2-card {%- endcomment -%}
        {%- endif -%}
      {%- endfor -%}
    </div>{%- comment -%} /.crv2-grid {%- endcomment -%}

    {%- comment -%} ── View more button ── {%- endcomment -%}
    {%- liquid
      assign review_count = 0
      for block in section.blocks
        if block.type == 'review'
          assign review_count = review_count | plus: 1
        endif
      endfor
      assign show_view_more = false
      if section.settings.initial_visible_count > 0 and review_count > section.settings.initial_visible_count
        assign show_view_more = true
      endif
    -%}
    {% if show_view_more %}
      <div class="crv2-view-more-wrap animate-item animate-item--child" style="--index:3;" id="crv2-view-more-wrap-{{ section.id }}">
        <button
          class="crv2-view-more-btn"
          id="crv2-view-more-{{ section.id }}"
          data-section-id="{{ section.id }}"
          data-label-more="{{ section.settings.view_more_label | escape }}"
          data-label-less="{{ section.settings.view_less_label | escape }}"
          aria-expanded="false"
        >
          {{ section.settings.view_more_label | escape }}
        </button>
      </div>
    {% endif %}

  </div>{%- comment -%} /.page-width {%- endcomment -%}
</div>{%- comment -%} /#CustomerReviewsV2-{{ section.id }} {%- endcomment -%}

<script>
(function () {
  var btn = document.getElementById('crv2-view-more-{{ section.id }}');
  if (!btn) return;

  var grid = document.getElementById('crv2-grid-{{ section.id }}');
  var hiddenCards = grid ? Array.prototype.slice.call(grid.querySelectorAll('[data-crv2-card].crv2-card--hidden')) : [];

  btn.addEventListener('click', function () {
    var isExpanded = btn.getAttribute('aria-expanded') === 'true';

    hiddenCards.forEach(function (card) {
      if (isExpanded) {
        card.classList.remove('crv2-card--revealed');
      } else {
        card.classList.add('crv2-card--revealed');
      }
    });

    btn.setAttribute('aria-expanded', isExpanded ? 'false' : 'true');
    btn.textContent = isExpanded
      ? btn.getAttribute('data-label-more')
      : btn.getAttribute('data-label-less');
  });
})();
</script>

{% schema %}
{
  "name": "Customer reviews V2",
  "tag": "section",
  "class": "section",
  "max_blocks": 30,
  "disabled_on": { "groups": ["header", "footer"] },
  "settings": [
    {
      "type": "checkbox",
      "id": "display_id",
      "label": "Display section ID",
      "default": false,
      "info": "ID can also be put inside any button link and the button will scroll to this section."
    },
    {
      "type": "select",
      "id": "visibility",
      "label": "Display on",
      "options": [
        { "value": "always-display", "label": "All devices"   },
        { "value": "mobile-hidden",  "label": "Desktop only"  },
        { "value": "desktop-hidden", "label": "Mobile only"   }
      ],
      "default": "always-display"
    },
    {
      "type": "header",
      "content": "Heading"
    },
    {
      "type": "inline_richtext",
      "id": "title",
      "label": "Heading",
      "default": "They Felt the Shift. You Will Too.",
      "info": "Bold words to highlight them with a color. Italicize words to apply the Italic text style set below."
    },
    {
      "type": "select",
      "id": "heading_size",
      "label": "Heading size",
      "options": [
        { "value": "h2", "label": "Small"  },
        { "value": "h1", "label": "Medium" },
        { "value": "h0", "label": "Large"  }
      ],
      "default": "h1"
    },
    {
      "type": "select",
      "id": "heading_alignment",
      "label": "Heading alignment",
      "options": [
        { "value": "left",   "label": "Left"   },
        { "value": "center", "label": "Center" },
        { "value": "right",  "label": "Right"  }
      ],
      "default": "center"
    },
    {
      "type": "range",
      "id": "header_top_spacing",
      "min": 0,
      "max": 60,
      "step": 4,
      "unit": "px",
      "label": "Space above heading",
      "default": 12
    },
    {
      "type": "range",
      "id": "header_bottom_spacing",
      "min": 0,
      "max": 60,
      "step": 4,
      "unit": "px",
      "label": "Space below header",
      "default": 24
    },
    {
      "type": "header",
      "content": "Bold text highlight"
    },
    {
      "type": "color",
      "id": "title_highlight_color",
      "label": "Heading highlight color",
      "default": "#009370"
    },
    {
      "type": "checkbox",
      "id": "enable_gradient",
      "label": "Use gradient for bold text",
      "default": false,
      "info": "Overrides the solid highlight color with a gradient."
    },
    {
      "type": "color_background",
      "id": "title_gradient_background",
      "label": "Bold text gradient",
      "default": "linear-gradient(45deg, #009370 0%, #00c99a 100%)",
      "visible_if": "{{ section.settings.enable_gradient }}"
    },
    {
      "type": "header",
      "content": "Italic text styling",
      "info": "Controls how italic text in the heading is displayed."
    },
    {
      "type": "select",
      "id": "italic_style",
      "label": "Italic style",
      "options": [
        { "value": "italic",      "label": "Normal italic"      },
        { "value": "underline",   "label": "Underline"          },
        { "value": "font_family", "label": "Custom font family" }
      ],
      "default": "underline"
    },
    {
      "type": "color",
      "id": "underlinetextcolor",
      "label": "Underline color",
      "default": "#009370",
      "visible_if": "{{ section.settings.italic_style == 'underline' }}"
    },
    {
      "type": "range",
      "id": "underlinethickness",
      "min": 1,
      "max": 8,
      "step": 1,
      "unit": "px",
      "label": "Underline thickness",
      "default": 3,
      "visible_if": "{{ section.settings.italic_style == 'underline' }}"
    },
    {
      "type": "select",
      "id": "italic_font_family",
      "label": "Italic font family",
      "options": [
        { "value": "inherit",          "label": "Default (Inherit)" },
        { "value": "serif",            "label": "Serif"             },
        { "value": "georgia-pro",      "label": "Georgia Pro"       },
        { "value": "bodoni-moda",      "label": "Bodoni Moda"       },
        { "value": "instrument-serif", "label": "Instrument Serif"  },
        { "value": "cursive",          "label": "Cursive"           }
      ],
      "default": "serif",
      "visible_if": "{{ section.settings.italic_style == 'font_family' }}"
    },
    {
      "type": "select",
      "id": "italic_font_weight",
      "label": "Italic font weight",
      "options": [
        { "value": "inherit", "label": "Default (Inherit)" },
        { "value": "300",     "label": "Light 300"         },
        { "value": "400",     "label": "Regular 400"       },
        { "value": "500",     "label": "Medium 500"        },
        { "value": "600",     "label": "Semi Bold 600"     },
        { "value": "700",     "label": "Bold 700"          },
        { "value": "800",     "label": "Extra Bold 800"    },
        { "value": "900",     "label": "Black 900"         }
      ],
      "default": "inherit",
      "visible_if": "{{ section.settings.italic_style == 'font_family' }}"
    },
    {
      "type": "header",
      "content": "Description"
    },
    {
      "type": "checkbox",
      "id": "show_description",
      "label": "Show description",
      "default": false
    },
    {
      "type": "richtext",
      "id": "text",
      "label": "Description",
      "default": "<p>See what our customers are saying.</p>",
      "visible_if": "{{ section.settings.show_description }}"
    },
    {
      "type": "header",
      "content": "Rating summary"
    },
    {
      "type": "checkbox",
      "id": "show_rating_summary",
      "label": "Show rating summary pill",
      "default": true
    },
    {
      "type": "text",
      "id": "rating_summary_text",
      "label": "Rating summary text",
      "default": "Rated 4.9 / 5 | Trusted by 75,000+",
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "range",
      "id": "rating_summary_font_size",
      "min": 10,
      "max": 20,
      "step": 1,
      "unit": "px",
      "label": "Rating summary font size",
      "default": 14,
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "range",
      "id": "rating_summary_border_radius",
      "min": 0,
      "max": 50,
      "step": 2,
      "unit": "px",
      "label": "Rating pill border radius",
      "default": 50,
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "color",
      "id": "rating_summary_bg_color",
      "label": "Rating summary background",
      "default": "#f0faf7",
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "color",
      "id": "summary_text_color",
      "label": "Rating summary text color",
      "default": "#005c48",
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "color",
      "id": "summary_star_color",
      "label": "Rating summary star color",
      "default": "#009370",
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "checkbox",
      "id": "enable_rating_summary_border",
      "label": "Show border on rating summary",
      "default": true,
      "visible_if": "{{ section.settings.show_rating_summary }}"
    },
    {
      "type": "range",
      "id": "rating_summary_border_width",
      "min": 1,
      "max": 4,
      "step": 1,
      "unit": "px",
      "label": "Border width",
      "default": 1,
      "visible_if": "{{ section.settings.enable_rating_summary_border }}"
    },
    {
      "type": "select",
      "id": "rating_summary_border_style",
      "label": "Border style",
      "options": [
        { "value": "solid",  "label": "Solid"  },
        { "value": "dashed", "label": "Dashed" },
        { "value": "dotted", "label": "Dotted" }
      ],
      "default": "solid",
      "visible_if": "{{ section.settings.enable_rating_summary_border }}"
    },
    {
      "type": "color",
      "id": "rating_summary_border_color",
      "label": "Border color",
      "default": "#009370",
      "visible_if": "{{ section.settings.enable_rating_summary_border }}"
    },
    {
      "type": "header",
      "content": "Layout"
    },
    {
      "type": "select",
      "id": "columns_desktop",
      "label": "Columns on desktop",
      "options": [
        { "value": "1", "label": "1 column"  },
        { "value": "2", "label": "2 columns" }
      ],
      "default": "1",
      "info": "Mobile is always 1 column."
    },
    {
      "type": "range",
      "id": "card_gap",
      "min": 8,
      "max": 48,
      "step": 4,
      "unit": "px",
      "label": "Gap between cards",
      "default": 20
    },
    {
      "type": "header",
      "content": "Show / hide reviews"
    },
    {
      "type": "range",
      "id": "initial_visible_count",
      "min": 0,
      "max": 30,
      "step": 1,
      "label": "Number of reviews to show initially",
      "default": 2,
      "info": "Set to 0 to always show all reviews with no button."
    },
    {
      "type": "text",
      "id": "view_more_label",
      "label": "\"View more\" button label",
      "default": "Read More Reviews"
    },
    {
      "type": "text",
      "id": "view_less_label",
      "label": "\"View less\" button label",
      "default": "Read Less Reviews"
    },
    {
      "type": "header",
      "content": "View more button style"
    },
    {
      "type": "color",
      "id": "view_more_bg_color",
      "label": "Button background",
      "default": "transparent"
    },
    {
      "type": "color",
      "id": "view_more_text_color",
      "label": "Button text color",
      "default": "#000000"
    },
    {
      "type": "range",
      "id": "view_more_border_width",
      "min": 0,
      "max": 3,
      "step": 1,
      "unit": "px",
      "label": "Button border width",
      "default": 0
    },
    {
      "type": "color",
      "id": "view_more_border_color",
      "label": "Button border color",
      "default": "#000000"
    },
    {
      "type": "range",
      "id": "view_more_border_radius",
      "min": 0,
      "max": 50,
      "step": 2,
      "unit": "px",
      "label": "Button border radius",
      "default": 0
    },
    {
      "type": "range",
      "id": "view_more_font_size",
      "min": 10,
      "max": 22,
      "step": 1,
      "unit": "px",
      "label": "Button font size",
      "default": 14
    },
    {
      "type": "select",
      "id": "view_more_font_weight",
      "label": "Button font weight",
      "options": [
        { "value": "400", "label": "Regular"   },
        { "value": "500", "label": "Medium"    },
        { "value": "600", "label": "Semi-Bold" },
        { "value": "700", "label": "Bold"      }
      ],
      "default": "400"
    },
    {
      "type": "range",
      "id": "view_more_padding_v",
      "min": 4,
      "max": 24,
      "step": 2,
      "unit": "px",
      "label": "Button vertical padding",
      "default": 8
    },
    {
      "type": "range",
      "id": "view_more_padding_h",
      "min": 8,
      "max": 60,
      "step": 4,
      "unit": "px",
      "label": "Button horizontal padding",
      "default": 24
    },
    {
      "type": "range",
      "id": "view_more_margin_top",
      "min": 0,
      "max": 60,
      "step": 4,
      "unit": "px",
      "label": "Space above button",
      "default": 20
    },
    {
      "type": "header",
      "content": "Card styling"
    },
    {
      "type": "range",
      "id": "card_border_radius",
      "min": 0,
      "max": 24,
      "step": 1,
      "unit": "px",
      "label": "Card border radius",
      "default": 4
    },
    {
      "type": "range",
      "id": "card_border_width",
      "min": 0,
      "max": 4,
      "step": 1,
      "unit": "px",
      "label": "Card border width",
      "default": 1
    },
    {
      "type": "color",
      "id": "card_border_color",
      "label": "Card border color",
      "default": "#00000033"
    },
    {
      "type": "range",
      "id": "card_padding_v",
      "min": 8,
      "max": 48,
      "step": 4,
      "unit": "px",
      "label": "Card vertical padding",
      "default": 24
    },
    {
      "type": "range",
      "id": "card_padding_h",
      "min": 8,
      "max": 48,
      "step": 4,
      "unit": "px",
      "label": "Card horizontal padding",
      "default": 20
    },
    {
      "type": "range",
      "id": "card_inner_gap",
      "min": 4,
      "max": 32,
      "step": 2,
      "unit": "px",
      "label": "Gap between card elements",
      "default": 16
    },
    {
      "type": "checkbox",
      "id": "card_shadow",
      "label": "Enable card shadow",
      "default": false
    },
    {
      "type": "color",
      "id": "card_shadow_color",
      "label": "Shadow color",
      "default": "#00000020",
      "visible_if": "{{ section.settings.card_shadow }}"
    },
    {
      "type": "range",
      "id": "card_shadow_x",
      "min": -20,
      "max": 20,
      "step": 1,
      "unit": "px",
      "label": "Shadow X offset",
      "default": 0,
      "visible_if": "{{ section.settings.card_shadow }}"
    },
    {
      "type": "range",
      "id": "card_shadow_y",
      "min": 0,
      "max": 40,
      "step": 1,
      "unit": "px",
      "label": "Shadow Y offset",
      "default": 8,
      "visible_if": "{{ section.settings.card_shadow }}"
    },
    {
      "type": "range",
      "id": "card_shadow_blur",
      "min": 0,
      "max": 60,
      "step": 2,
      "unit": "px",
      "label": "Shadow blur",
      "default": 20,
      "visible_if": "{{ section.settings.card_shadow }}"
    },
    {
      "type": "range",
      "id": "card_shadow_spread",
      "min": -10,
      "max": 20,
      "step": 1,
      "unit": "px",
      "label": "Shadow spread",
      "default": 0,
      "visible_if": "{{ section.settings.card_shadow }}"
    },
    {
      "type": "header",
      "content": "Review title"
    },
    {
      "type": "range",
      "id": "title_font_size_desktop",
      "min": 12,
      "max": 32,
      "step": 1,
      "unit": "px",
      "label": "Title font size (desktop)",
      "default": 18
    },
    {
      "type": "range",
      "id": "title_font_size_mobile",
      "min": 12,
      "max": 28,
      "step": 1,
      "unit": "px",
      "label": "Title font size (mobile)",
      "default": 18
    },
    {
      "type": "select",
      "id": "title_font_weight",
      "label": "Title font weight",
      "options": [
        { "value": "400", "label": "Regular"   },
        { "value": "500", "label": "Medium"    },
        { "value": "600", "label": "Semi-Bold" },
        { "value": "700", "label": "Bold"      }
      ],
      "default": "500"
    },
    {
      "type": "header",
      "content": "Review body text"
    },
    {
      "type": "range",
      "id": "body_font_size",
      "min": 10,
      "max": 22,
      "step": 1,
      "unit": "px",
      "label": "Body text size",
      "default": 15
    },
    {
      "type": "header",
      "content": "Review tags"
    },
    {
      "type": "color",
      "id": "tag_bg_color",
      "label": "Tag background",
      "default": "#e6f7f3"
    },
    {
      "type": "color",
      "id": "tag_text_color",
      "label": "Tag text color",
      "default": "#009370"
    },
    {
      "type": "range",
      "id": "tag_border_width",
      "min": 0,
      "max": 3,
      "step": 1,
      "unit": "px",
      "label": "Tag border width",
      "default": 1
    },
    {
      "type": "color",
      "id": "tag_border_color",
      "label": "Tag border color",
      "default": "#009370"
    },
    {
      "type": "range",
      "id": "tag_border_radius",
      "min": 0,
      "max": 50,
      "step": 2,
      "unit": "px",
      "label": "Tag border radius",
      "default": 20
    },
    {
      "type": "range",
      "id": "tag_font_size",
      "min": 8,
      "max": 18,
      "step": 1,
      "unit": "px",
      "label": "Tag font size",
      "default": 12
    },
    {
      "type": "range",
      "id": "tag_padding_v",
      "min": 2,
      "max": 16,
      "step": 1,
      "unit": "px",
      "label": "Tag vertical padding",
      "default": 6
    },
    {
      "type": "range",
      "id": "tag_padding_h",
      "min": 4,
      "max": 24,
      "step": 1,
      "unit": "px",
      "label": "Tag horizontal padding",
      "default": 14
    },
    {
      "type": "range",
      "id": "tag_gap",
      "min": 4,
      "max": 24,
      "step": 2,
      "unit": "px",
      "label": "Gap between tags",
      "default": 10
    },
    {
      "type": "header",
      "content": "Reviewer info"
    },
    {
      "type": "range",
      "id": "reviewer_font_size",
      "min": 8,
      "max": 18,
      "step": 1,
      "unit": "px",
      "label": "Reviewer info font size",
      "default": 13
    },
    {
      "type": "text",
      "id": "verified_badge_text",
      "label": "Verified badge text",
      "default": "Verified Buyer"
    },
    {
      "type": "color",
      "id": "verified_badge_color",
      "label": "Verified badge color",
      "default": "#1D9BF0"
    },
    {
      "type": "range",
      "id": "verified_badge_font_size",
      "min": 8,
      "max": 16,
      "step": 1,
      "unit": "px",
      "label": "Verified badge font size",
      "default": 11
    },
    {
      "type": "header",
      "content": "Color scheme"
    },
    {
      "type": "select",
      "id": "color_scheme",
      "label": "Color scheme",
      "options": [
        { "value": "accent-1",     "label": "Accent 1"     },
        { "value": "accent-2",     "label": "Accent 2"     },
        { "value": "background-1", "label": "Background 1" },
        { "value": "background-2", "label": "Background 2" },
        { "value": "inverse",      "label": "Inverse"      },
        { "value": "custom",       "label": "Custom"       }
      ],
      "default": "background-1"
    },
    {
      "type": "header",
      "content": "Custom color scheme",
      "info": "Applied when Color scheme is set to Custom."
    },
    {
      "type": "color",
      "id": "custom_colors_background",
      "label": "Background color",
      "default": "#FFFFFF",
      "visible_if": "{{ section.settings.color_scheme == 'custom' }}"
    },
    {
      "type": "color_background",
      "id": "custom_gradient_background",
      "label": "Gradient background",
      "info": "Replaces Background color when set.",
      "visible_if": "{{ section.settings.color_scheme == 'custom' }}"
    },
    {
      "type": "image_picker",
      "id": "custom_image_background",
      "label": "Image background",
      "visible_if": "{{ section.settings.color_scheme == 'custom' }}"
    },
    {
      "type": "image_picker",
      "id": "custom_mobile_image_background",
      "label": "Mobile image background",
      "info": "If empty, the desktop image is used on mobile.",
      "visible_if": "{{ section.settings.color_scheme == 'custom' }}"
    },
    {
      "type": "color",
      "id": "custom_colors_text",
      "label": "Text color",
      "default": "#2E2A39",
      "visible_if": "{{ section.settings.color_scheme == 'custom' }}"
    },
    {
      "type": "header",
      "content": "Section padding"
    },
    {
      "type": "range",
      "id": "padding_top",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Padding top",
      "default": 40
    },
    {
      "type": "range",
      "id": "padding_bottom",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Padding bottom",
      "default": 40
    },
    {
      "type": "header",
      "content": "Section margin"
    },
    {
      "type": "range",
      "id": "mobile_margin_top",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Mobile top margin",
      "default": 0
    },
    {
      "type": "range",
      "id": "mobile_margin_bottom",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Mobile bottom margin",
      "default": 0
    },
    {
      "type": "range",
      "id": "desktop_margin_top",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Desktop top margin",
      "default": 0
    },
    {
      "type": "range",
      "id": "desktop_margin_bottom",
      "min": 0,
      "max": 100,
      "step": 4,
      "unit": "px",
      "label": "Desktop bottom margin",
      "default": 0
    }
  ],
  "blocks": [
    {
      "type": "review",
      "name": "Review",
      "settings": [
        {
          "type": "header",
          "content": "Rating stars"
        },
        {
          "type": "range",
          "id": "rating",
          "label": "Rating",
          "min": 1,
          "max": 5,
          "step": 0.1,
          "default": 5.0
        },
        {
          "type": "color",
          "id": "star_color",
          "label": "Stars color",
          "default": "#009370"
        },
        {
          "type": "select",
          "id": "bg_stars_style",
          "label": "Background stars style",
          "options": [
            { "value": "outlined", "label": "Outlined" },
            { "value": "full",     "label": "Full"     }
          ],
          "default": "full"
        },
        {
          "type": "color",
          "id": "bg_star_color",
          "label": "Background stars color",
          "default": "#ececec"
        },
        {
          "type": "inline_richtext",
          "id": "label",
          "label": "Stars label text",
          "default": "5.0",
          "info": "Optional text shown next to the stars. Use italic formatting to underline text."
        },
        {
          "type": "range",
          "id": "size",
          "min": 10,
          "max": 24,
          "step": 1,
          "unit": "px",
          "label": "Star / text size",
          "default": 14
        },
        {
          "type": "header",
          "content": "Review content"
        },
        {
          "type": "text",
          "id": "review_title",
          "label": "Review title (quote)",
          "default": "\"This product completely changed my life.\""
        },
        {
          "type": "textarea",
          "id": "review_text",
          "label": "Review body",
          "default": "I've been using this for three weeks and I couldn't be happier with the results. It's become a staple in my daily routine."
        },
        {
          "type": "header",
          "content": "Tags"
        },
        {
          "type": "text",
          "id": "tag_1",
          "label": "Tag 1",
          "default": "Gut Support"
        },
        {
          "type": "text",
          "id": "tag_2",
          "label": "Tag 2",
          "default": "Bloat Relief"
        },
        {
          "type": "text",
          "id": "tag_3",
          "label": "Tag 3 (optional)"
        },
        {
          "type": "header",
          "content": "Reviewer"
        },
        {
          "type": "text",
          "id": "reviewer_name",
          "label": "Reviewer name",
          "default": "Sarah M."
        },
        {
          "type": "text",
          "id": "reviewer_meta",
          "label": "Age / location (optional)",
          "default": "28"
        },
        {
          "type": "checkbox",
          "id": "show_verified_badge",
          "label": "Show verified badge",
          "default": true
        },
        {
          "type": "header",
          "content": "Block margin"
        },
        {
          "type": "range",
          "id": "margin_top",
          "min": 0,
          "max": 30,
          "step": 3,
          "unit": "px",
          "label": "Top margin",
          "default": 0
        },
        {
          "type": "range",
          "id": "margin_bottom",
          "min": 0,
          "max": 30,
          "step": 3,
          "unit": "px",
          "label": "Bottom margin",
          "default": 0
        }
      ]
    }
  ],
  "presets": [
    {
      "name": "Customer reviews V2",
      "category": "Testimonials",
      "blocks": [
        {
          "type": "review",
          "settings": {
            "rating": 5.0,
            "star_color": "#009370",
            "bg_star_color": "#ececec",
            "review_title": "\"Helped my digestion more than probiotics.\"",
            "review_text": "I've struggled with bloating and irregular digestion for years. This made a noticeable difference in less than two weeks. My gut feels calm, and I feel way more regular now.",
            "tag_1": "Gut Support",
            "tag_2": "Bloat Relief",
            "reviewer_name": "Sarah M.",
            "reviewer_meta": "28",
            "show_verified_badge": true
          }
        },
        {
          "type": "review",
          "settings": {
            "rating": 5.0,
            "star_color": "#009370",
            "bg_star_color": "#ececec",
            "review_title": "\"A clean product that actually works.\"",
            "review_text": "I love that it's just two simple ingredients — nothing else. Most supplements are full of junk. Simple, pure, and powerful. I feel better overall and trust what I'm putting in my body.",
            "tag_1": "Clean Ingredients",
            "tag_2": "Whole-Body Health",
            "reviewer_name": "Michael R.",
            "reviewer_meta": "35",
            "show_verified_badge": true
          }
        },
        {
          "type": "review",
          "settings": {
            "rating": 5.0,
            "star_color": "#009370",
            "bg_star_color": "#ececec",
            "review_title": "\"My go-to during flu season.\"",
            "review_text": "Every time I feel something coming on, I take this and it usually stops it in its tracks. It's become a staple in my wellness routine, especially during fall and winter.",
            "tag_1": "Cold Prevention",
            "tag_2": "Daily Defense",
            "reviewer_name": "Jessica L.",
            "reviewer_meta": "42",
            "show_verified_badge": true
          }
        },
        {
          "type": "review",
          "settings": {
            "rating": 5.0,
            "star_color": "#009370",
            "bg_star_color": "#ececec",
            "review_title": "\"Subtle at first, but game-changing over time.\"",
            "review_text": "The benefits weren't overnight, but after 3 weeks I realized I had more energy, less brain fog, and my stomach was calmer after meals. It works quietly but effectively.",
            "tag_1": "Energy Support",
            "tag_2": "Long-Term Results",
            "reviewer_name": "David K.",
            "reviewer_meta": "51",
            "show_verified_badge": true
          }
        }
      ]
    }
  ]
}
{% endschema %}