/*
 * reien-search-panel.css（2026-05-18）
 * 霊園マッチング検索ブロック共通CSS。
 * 見た目・コンテンツ内容は変えず、インデックスとリストで同じ検索ブロックを稼働させる。
 */
.reien-search-panel .rl-search-select option:disabled {
  background: #EEF1F2;
  color: #9AA1A7;
}

@media (min-width: 769px) {
  .reien-search-panel {
    display: grid;
    grid-template-columns: minmax(0, 0.78fr) minmax(0, 0.84fr) minmax(0, 0.98fr) 168px;
    grid-template-areas:
      "area area type type"
      "feature feature feature feature"
      "actions actions actions actions"
      "name name name name";
    gap: 18px 0;
    padding: 24px;
    background: #FFFFFF;
    border: 1px solid #E5E5E5;
    border-radius: 0;
    box-shadow: 0 6px 18px rgba(10, 31, 61, 0.06);
    box-sizing: border-box;
    position: relative;
    overflow: visible;
    isolation: isolate;
    color: #111111;
    font-size: 13.5px;
    line-height: 1.7;
    letter-spacing: 0;
  }

  .rl-search-panel:has(.rl-search-type-details[open], .rl-search-feature-details[open]),
  .reien-search-panel:has(.rl-search-type-details[open], .rl-search-feature-details[open]) {
    position: relative;
    z-index: 200;
    overflow: visible;
  }

  .reien-search-panel .rl-search-form,
  .reien-search-panel .rl-name-search-form {
    display: contents;
    width: auto;
    max-width: none;
    margin: 0;
    box-shadow: none;
  }

  .reien-search-panel .rl-search-row {
    display: block;
    min-width: 0;
    border-top: none;
  }

  .reien-search-panel .rl-search-row-area {
    grid-area: area;
  }

  .reien-search-panel .rl-search-row-feature {
    grid-area: feature;
  }

  .reien-search-panel .rl-search-actions {
    grid-area: actions;
  }

  .reien-search-panel .rl-search-row-type {
    grid-area: type;
    position: relative;
    z-index: 120;
    margin-left: 18px;
  }

  .reien-search-panel .rl-search-row-name {
    grid-area: name;
  }

  .reien-search-panel .rl-search-label,
  .reien-search-panel .rl-search-row-area .rl-search-label,
  .reien-search-panel .rl-search-select-label,
  .reien-search-panel .rl-search-row-type .rl-search-label {
    display: none;
  }

  .reien-search-panel .rl-search-row-type .rl-search-label {
    display: none;
  }

  .reien-search-panel .rl-search-control {
    grid-template-columns: minmax(0, 0.72fr) minmax(0, 1fr);
    grid-template-rows: 48px;
    grid-template-areas: "pref-select municipality-select";
    column-gap: 0;
    row-gap: 0;
    padding: 0;
    background: transparent;
  }

  .reien-search-panel .rl-search-select {
    min-height: 48px;
    border: 1px solid #C8CDD2;
    border-right: none;
    color: #111111;
    font-size: 13.5px;
    line-height: 1.7;
    font-weight: 400;
    letter-spacing: 0;
    padding-left: 42px;
    background-image:
      url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg' fill='none' stroke='%231E3A4D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"),
      url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%231E3A4D' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat, no-repeat;
    background-position: 15px center, right 18px center;
    background-size: 20px 20px, 18px 18px;
    transform: translateY(1px);
  }

  .reien-search-panel #rl-search-municipality {
    border-right: 1px solid #C8CDD2;
  }

  .reien-search-panel .rl-search-type-details {
    position: relative;
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-type-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    min-height: 48px;
    padding: 0 18px 0 42px;
    border: 1px solid #C8CDD2;
    background: #FFFFFF;
    color: #111111;
    font-size: 13.5px;
    line-height: 1.7;
    font-weight: 400;
    letter-spacing: 0;
    cursor: pointer;
    list-style: none;
    box-sizing: border-box;
  }

  .reien-search-panel .rl-search-type-summary::before {
    content: "";
    position: absolute;
    left: 15px;
    top: 50%;
    width: 22.5px;
    height: 22.5px;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg' fill='none' stroke='%231E3A4D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 21V12a7 7 0 0 1 14 0v9'/%3E%3Cline x1='3' y1='21' x2='21' y2='21'/%3E%3Cline x1='12' y1='9' x2='12' y2='15'/%3E%3Cline x1='9' y1='12' x2='15' y2='12'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 22.5px 22.5px;
    transform: translateY(-50%);
  }

  .reien-search-panel .rl-search-type-summary::-webkit-details-marker {
    display: none;
  }

  .reien-search-panel .rl-search-type-summary > span:first-child {
    transform: translateY(1px);
  }

  .reien-search-panel .rl-search-type-summary .material-symbols-outlined {
    color: #1E3A4D;
    font-size: 24px;
  }

  .reien-search-panel .rl-search-type-details[open] .rl-search-type-summary .material-symbols-outlined {
    transform: rotate(180deg);
  }

  .reien-search-panel .rl-search-type-panel {
    position: absolute;
    top: 100%;
    right: 0;
    left: auto;
    bottom: auto;
    z-index: 140;
    width: 100%;
    margin-top: 0;
    padding: 18px;
    border: 1px solid #E5E5E5;
    border-top: none;
    background: #ECEFEF;
    box-shadow: 0 18px 42px rgba(10, 31, 61, 0.18), 0 2px 8px rgba(10, 31, 61, 0.08);
    box-sizing: border-box;
  }

  .reien-search-panel .rl-search-feature-summary {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
    min-height: 42px;
    padding: 0;
    border: none;
    background: transparent;
    color: #FFFFFF;
    font-size: 12px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
    text-decoration: none;
  }

  .reien-search-panel .rl-search-feature-summary .material-symbols-outlined {
    color: #FFFFFF;
  }

  .reien-search-panel .rl-search-feature-summary-pc {
    white-space: nowrap;
  }

  .reien-search-panel .rl-search-feature-details {
    position: static;
    background: transparent;
  }

  .reien-search-panel .rl-search-feature-details:not([open]) .rl-search-feature-groups {
    display: none;
  }

  .reien-search-panel .rl-search-feature-groups {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    z-index: 90;
    width: auto;
    max-height: clamp(360px, calc(100vh - 480px), 520px);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    border: 1px solid rgba(30, 58, 77, 0.16);
    background: #FFFFFF;
    box-shadow: 0 18px 42px rgba(10, 31, 61, 0.18), 0 2px 8px rgba(10, 31, 61, 0.08);
    box-sizing: border-box;
  }

  .reien-search-panel .reien-search-feature-preview-list {
    display: flex;
    flex: 1 1 auto;
    flex-wrap: nowrap;
    gap: 6px;
    min-width: 0;
    overflow: hidden;
  }

  .reien-search-panel .reien-search-feature-preview-title {
    display: flex;
    align-items: center;
    min-height: 42px;
    margin: 0;
    color: #FFFFFF;
    font-size: 15px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
    white-space: nowrap;
  }

  .reien-search-panel .reien-search-feature-preview-item span {
    width: 100%;
    justify-content: flex-start;
    min-height: 42px;
    padding: 8px 9px 8px 33px;
    background: #FFFFFF;
    color: #111111;
    font-size: 13.5px;
    line-height: 1.7;
    font-weight: 400;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-actions {
    display: flex;
    justify-content: stretch;
    gap: 0;
    padding: 0;
    background: transparent;
    align-self: start;
    box-sizing: border-box;
  }

  .reien-search-panel .rl-search-actions .rl-action-secondary {
    display: inline-flex;
    flex: 1 1 0;
    width: 50%;
    min-height: 48px;
    border: none;
    background: #ECEFEF;
    color: #1E3A4D;
    font-size: 13.5px;
    line-height: 1.5;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-actions .rl-action-primary {
    flex: 1 1 0;
    width: 50%;
    min-height: 48px;
    gap: 6px;
    font-size: 14px;
    line-height: 1;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-type-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: 1fr;
    gap: 9px;
    min-height: 0;
    padding: 0;
    background: transparent;
  }

  .reien-search-panel .rl-search-type {
    display: flex;
    min-height: 42px;
  }

  .reien-search-panel .rl-search-type span {
    width: 100%;
    min-width: 0;
    height: 100%;
    min-height: 42px;
    padding: 8px 12px 8px 39px;
    background: #FFFFFF;
    color: #111111;
    font-size: 13.5px;
    line-height: 1.7;
    font-weight: 400;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-type-done {
    display: flex;
    position: sticky;
    bottom: -18px;
    z-index: 1;
    width: calc(100% + 36px);
    margin: 18px -18px -18px;
  }

  .reien-search-panel .rl-search-feature-sheet-actions {
    position: sticky;
    bottom: 0;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    margin: 0;
    padding: 0;
    background: #ECEFEF;
    box-sizing: border-box;
  }

  .reien-matching-list .reien-search-panel .rl-search-feature-sheet-actions {
    bottom: 0;
    width: 100%;
    margin: 0;
  }

  .reien-search-panel .rl-search-feature-sheet-done {
    width: 100%;
  }

  .reien-search-panel .rl-search-feature-sheet-clear,
  .reien-search-panel .rl-search-feature-sheet-done {
    min-width: 0;
    min-height: 52px;
    border-radius: 0;
  }

  .reien-search-panel .rl-search-feature-sheet-clear {
    width: 100%;
    padding-right: 0;
    padding-left: 0;
  }

  .reien-search-panel .rl-search-row-name {
    display: grid;
    grid-template-columns: 216px minmax(0, 1fr);
    align-items: stretch;
    position: relative;
    margin-top: 6px;
    padding-top: 24px;
    border-top: none;
    background: transparent;
  }

  .reien-search-panel .rl-search-row-name::before {
    content: "";
    position: absolute;
    inset: 0 -24px -24px;
    z-index: -1;
    background: #ECEFEF;
  }

  .reien-search-panel .rl-search-row-name .rl-search-label {
    display: flex;
    min-height: 48px;
    padding: 0 18px;
    background: #1E3A4D;
    color: #FFFFFF;
    font-size: 15px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-name-search-control {
    padding: 0;
    background: transparent;
  }

  .reien-search-panel .rl-name-search-input-wrap {
    min-height: 48px;
  }

  .reien-search-panel .rl-name-search-input,
  .reien-search-panel .rl-name-search-submit {
    min-height: 48px;
  }

  .reien-search-panel .rl-search-row-feature {
    display: grid;
    grid-template-columns: 168px minmax(0, 1fr) minmax(0, max-content);
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1;
    height: 60px;
    padding: 0 24px;
    background: #1E3A4D;
    box-sizing: border-box;
    max-width: 100%;
    overflow: visible;
  }
}

@media (min-width: 769px) and (max-width: 1359px) {
  .reien-search-panel .reien-search-feature-preview-item:nth-child(5) {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1279px) {
  .reien-search-panel .reien-search-feature-preview-item:nth-child(4) {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1199px) {
  .reien-search-panel .reien-search-feature-preview-item:nth-child(3) {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1099px) {
  .reien-search-panel .reien-search-feature-preview-item:nth-child(2) {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 999px) {
  .reien-search-panel .rl-search-row-feature {
    grid-template-columns: minmax(0, 1fr) max-content;
  }

  .reien-search-panel .reien-search-feature-preview-list {
    display: none;
  }

  .reien-search-panel .reien-search-feature-preview-item:nth-child(1) {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1099px) {
  .reien-search-panel .rl-search-row-name {
    grid-template-columns: minmax(0, 1fr);
  }

  .reien-search-panel .rl-search-row-name .rl-search-label {
    display: none;
  }
}

@media (max-width: 768px) {
  .reien-search-panel {
    max-width: 100%;
    overflow-x: hidden;
  }

  .reien-search-panel {
    background: #FFFFFF;
    border: 1px solid #E5E5E5;
    padding: 24px 24px 0;
    box-sizing: border-box;
  }
}

@media (max-width: 768px) {
  .reien-search-panel .rl-search-row {
    display: block;
    padding: 0;
    border-top: none;
  }

  .reien-search-panel .rl-search-row:first-child {
    border-top: none;
  }

  .reien-search-panel .rl-search-row-area .rl-search-label {
    display: none;
  }

  .reien-search-panel .rl-search-label,
  .reien-search-panel .rl-search-feature-summary {
    justify-content: flex-start;
    min-height: 54px;
    margin: 0;
    padding: 0 15px;
    text-align: left;
  }

  .reien-search-panel .rl-search-label {
    background: #1E3A4D;
    color: #FFFFFF;
    font-size: 15px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-control {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: 48px;
    grid-template-areas:
      "pref-select municipality-select";
    column-gap: 0;
    row-gap: 0;
    padding: 0;
  }

  .reien-search-panel .rl-search-control .rl-search-select-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .reien-search-panel .rl-search-select-label[for="rl-search-municipality"] {
    margin-top: 0;
  }

  .reien-search-panel .rl-search-select {
    padding-left: 42px;
    padding-right: 30px;
    background-image:
      url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg' fill='none' stroke='%231E3A4D' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"),
      url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%231E3A4D' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat, no-repeat;
    background-position: 15px center, right 9px center;
    background-size: 20px 20px, 18px 18px;
  }

  .reien-search-panel #rl-search-prefecture {
    border-right: none;
  }

  .reien-search-panel .rl-search-type-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    padding: 0 15px 15px;
  }

  .reien-search-panel .rl-search-row-type .rl-search-label {
    display: none;
  }

  .reien-search-panel .rl-search-row-type {
    display: none;
  }

  .reien-search-panel .rl-search-feature-summary {
    min-height: 54px;
    margin: 0;
    padding: 0 15px;
    border: none;
    background: #1E3A4D;
    color: #FFFFFF;
    font-size: 15px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-row-feature {
    padding: 3px 0 18px;
    background: #FFFFFF;
  }

  .reien-search-panel .reien-search-feature-preview-title,
  .reien-search-panel .reien-search-feature-preview-list {
    display: none;
  }

  .reien-search-panel .rl-search-row-feature .rl-search-feature-details {
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-feature-summary-pc {
    display: none;
  }

  .reien-search-panel .rl-search-feature-summary-sp {
    display: inline;
  }

  .reien-search-panel .rl-search-feature-summary .material-symbols-outlined {
    color: #FFFFFF;
    margin-left: auto;
    transform: rotate(180deg);
  }

  .reien-search-panel .rl-search-feature-details[open]::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 800;
    background: rgba(0, 0, 0, 0.55);
    pointer-events: none;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-feature-details[open]::before {
    content: none;
  }

  .reien-search-panel.is-feature-sheet-active::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 800;
    background: rgba(0, 0, 0, 0.55);
    pointer-events: none;
  }

  .rl-search-panel.is-search-panel-active {
    z-index: 1100;
  }

  .reien-search-panel .rl-search-feature-details[open] .rl-search-feature-groups {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 801;
    display: block;
    max-height: 78vh;
    padding: 0 15px 84px;
    overflow-y: auto;
    background: #FFFFFF;
    border-radius: 0;
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.18);
    box-sizing: border-box;
    animation: none;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open {
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(90px + env(safe-area-inset-bottom));
    z-index: 801;
    height: 78vh;
    padding: 0 15px 0;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
    background: #FFFFFF;
    border-radius: 0;
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.18);
    box-sizing: border-box;
    animation: rl-filter-sheet-rise 0.24s ease-out;
  }

  body.rf-feature-sheet-scroll-locked .rf-search-style-nav,
  body.rf-feature-sheet-scroll-locked .rf-ending-learn-nav {
    display: none;
  }

  /*
   * 詳細条件シート中は、検索パネル以外を描画ツリーから外す。
   * /find/ は検索パネルがラッパー内、一覧は #main-content の直下にあるため、
   * 両方の構造を #main-content の直下だけで明示的に扱う。
   */
  body.rf-feature-sheet-scroll-locked #main-content:has(#block-search-panel) > *:not(#block-search-panel):not(:has(#block-search-panel)),
  body.rf-feature-sheet-scroll-locked #main-content > :has(#block-search-panel) > *:not(#block-search-panel),
  body.rf-feature-sheet-scroll-locked .reien-page-top {
    display: none !important;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-closing {
    animation: rl-filter-sheet-drop 0.21s ease-in forwards;
  }

  @keyframes rl-filter-sheet-rise {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  @keyframes rl-filter-sheet-drop {
    from {
      opacity: 1;
    }
    to {
      opacity: 0;
    }
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-feature-details[open] .rl-search-feature-groups {
    position: static;
    max-height: none;
    padding: 0;
    overflow: visible;
    border-radius: 0;
    box-shadow: none;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-feature-sheet-head,
  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-feature-sheet-actions,
  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-feature-summary {
    display: none;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-sp-filter-sheet-head {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 54px;
    margin: 0 -15px;
    padding: 9px 15px 0;
    border-bottom: none;
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-sp-filter-sheet-head::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 9px;
    width: 54px;
    height: 3px;
    background: #B0B8C1;
    transform: translateX(-50%);
  }

  .reien-search-panel .rl-sp-filter-sheet-title {
    margin: 0;
    color: #111111;
    font-size: 18px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-sp-filter-sheet-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    color: #444444;
  }

  .reien-search-panel .rl-sp-filter-sheet-close-icon {
    position: relative;
    display: block;
    width: 36px;
    height: 21px;
  }

  .reien-search-panel .rl-sp-filter-sheet-close-bar {
    position: absolute;
    top: 50%;
    left: 0;
    width: 36px;
    height: 2px;
    background: #444444;
    transform-origin: center;
  }

  .reien-search-panel .rl-sp-filter-sheet-close-bar:nth-child(1) {
    transform: translateY(-50%) rotate(15deg);
  }

  .reien-search-panel .rl-sp-filter-sheet-close-bar:nth-child(2) {
    transform: translateY(-50%) rotate(-15deg);
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-sp-filter-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 12px 0 0;
    border-bottom: 1px solid #E5E5E5;
  }

  .reien-search-panel .rl-sp-filter-tab {
    min-height: 48px;
    padding: 0 9px;
    color: #1E3A4D;
    font-size: 14px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
    border-bottom: 3px solid transparent;
  }

  .reien-search-panel .rl-sp-filter-tab.is-active {
    color: #29648D;
    border-bottom-color: #29648D;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-row-type,
  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-row-feature {
    display: none;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-row-type,
  .reien-search-panel .rl-search-form.is-filter-tab-feature .rl-search-row-feature {
    display: block;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-row-type {
    padding-top: 15px;
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type-details {
    display: block;
    background: transparent;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type-summary {
    display: none;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type-panel {
    position: static;
    display: block;
    width: auto;
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
    box-shadow: none;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-row-feature {
    padding-top: 15px;
    padding-bottom: 0;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type-list {
    padding-top: 15px;
    padding-bottom: 15px;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-feature .rl-search-feature-group:has(+ .rl-search-feature-sheet-actions),
  .reien-search-panel .rl-search-form.is-filter-tab-feature .rl-search-feature-group:last-child {
    /* 固定の「決定」ボタンの被覆63pxと、既存の末尾余白18pxを確保する。 */
    padding-bottom: 84px;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-type-done {
    display: none;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type span {
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type:hover span,
  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type:active span,
  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type:focus-within span,
  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type.is-action-hover span {
    filter: var(--rl-action-filter-hover) !important;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-type .rl-search-type input:checked + span {
    background: #29648D;
    color: #FFFFFF;
  }

  .reien-search-panel .rl-search-form.is-filter-tab-feature .rl-search-keyword-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-sp-filter-sheet-actions {
    position: fixed;
    left: 15px;
    right: 15px;
    bottom: calc(105px + env(safe-area-inset-bottom));
    z-index: 802;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    width: auto;
    margin: 0;
    padding-top: 0;
    background: transparent;
    box-sizing: border-box;
  }

  .reien-search-panel .rl-sp-filter-sheet-reset {
    display: none;
  }

  .reien-search-panel .rl-sp-filter-sheet-done {
    display: flex;
    width: 100%;
    min-height: 48px;
    margin: 0;
    border-radius: 0;
    font-size: 13.5px;
    line-height: 1.7;
    font-weight: 450;
    letter-spacing: 0.06em;
  }

  .reien-search-panel .rl-search-form.is-feature-sheet-open .rl-search-actions {
    display: none;
  }

  .reien-search-panel .rl-search-feature-sheet-head {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 60px;
    margin: 0 -15px;
    padding: 0 15px;
    border-bottom: 1px solid #E5E5E5;
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-feature-sheet-title {
    margin: 0;
    color: #111111;
    font-size: 18px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-feature-sheet-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    color: #444444;
  }

  .reien-search-panel .rl-search-feature-sheet-close .material-symbols-outlined {
    font-size: 27px;
  }

  .reien-search-panel .rl-search-feature-sheet-actions {
    position: fixed;
    left: 15px;
    right: 15px;
    bottom: 15px;
    z-index: 802;
    display: block;
  }

  .reien-search-panel .rl-search-feature-sheet-done {
    width: 100%;
  }

  .reien-search-panel .rl-search-type,
  .reien-search-panel .rl-search-check {
    width: 100%;
    min-width: 0;
  }

  .reien-search-panel .rl-search-type span,
  .reien-search-panel .rl-search-check span {
    width: 100%;
    min-width: 0;
    word-break: normal;
    overflow-wrap: anywhere;
  }

  .reien-search-panel .rl-search-feature-group {
    padding: 18px 15px;
  }

  .reien-search-panel .rl-search-feature-title {
    margin-bottom: 12px;
  }

  .reien-search-panel .rl-search-keyword-list {
    gap: 6px;
  }

  .reien-search-panel .rl-search-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0;
    padding: 0;
    background: #FFFFFF;
  }

  .reien-search-panel .rl-search-actions .rl-action-secondary,
  .reien-search-panel .rl-search-actions .rl-action-primary {
    width: auto;
    min-width: 0;
    padding-left: 9px;
    padding-right: 9px;
    white-space: normal;
    text-align: center;
    font-size: 14px;
    line-height: 1.7;
    font-weight: 500;
    letter-spacing: 0;
  }

  .reien-search-panel .rl-search-actions .rl-action-secondary {
    display: inline-flex;
    background: #ECEFEF;
    color: #1E3A4D;
  }

  .reien-search-panel .rl-name-search-form {
    margin-top: 24px;
  }

  .reien-search-panel .rl-search-row-name {
    width: calc(100% + 48px);
    margin-left: -24px;
    margin-right: -24px;
    padding: 24px;
    background: #ECEFEF;
    box-sizing: border-box;
  }

  .reien-search-panel .rl-search-row-name .rl-search-label {
    display: none;
  }

  .reien-search-panel .rl-name-search-control {
    padding: 0;
    background: transparent;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .reien-search-panel .rl-name-search-input-wrap {
    grid-template-columns: minmax(0, 1fr) 120px;
    width: 100%;
    min-width: 0;
  }

  .reien-search-panel .rl-name-search-clear {
    right: 129px;
  }

  .reien-search-panel .rl-name-search-submit {
    gap: 6px;
    padding: 0 12px;
    min-width: 0;
  }
}

/* 件数0の選択肢は、全ページ・全表示幅で同じ無効状態にする */
.reien-search-panel .rl-search-type.is-disabled,
.reien-search-panel .rl-search-check.is-disabled {
  cursor: not-allowed;
}

.reien-search-panel .rl-search-type input:disabled + span,
.reien-search-panel .rl-search-check input:disabled + span {
  background: #EEF1F2;
  color: #9AA1A7;
  box-shadow: inset 0 0 0 1px #DDE3E7;
  cursor: not-allowed;
  filter: none !important;
}

.reien-search-panel .rl-search-type input:disabled + span::before,
.reien-search-panel .rl-search-check input:disabled + span::before {
  border-color: #C7CDD2;
  background: #F7F8F9;
}

/* 2行以上の選択肢がある行でも、白背景を行の高さまで揃える */
.reien-search-panel .rl-search-type span,
.reien-search-panel .rl-search-check span {
  align-self: stretch;
}

.reien-search-panel .rl-search-type.is-disabled:hover span,
.reien-search-panel .rl-search-type.is-disabled:active span,
.reien-search-panel .rl-search-type.is-disabled:focus-within span,
.reien-search-panel .rl-search-check.is-disabled:hover span,
.reien-search-panel .rl-search-check.is-disabled:active span,
.reien-search-panel .rl-search-check.is-disabled:focus-within span {
  filter: none !important;
}
