/* =============================================
   記事詳細 — お気に入りボタン
   ============================================= */

button.favorite_button_in {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 160px;
    height: 38px;
    border: 1px solid #e2e8ee;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .08);
    cursor: pointer;
    border-radius: 6px;
    font-size: 13px;
    transition: opacity .2s;
    background: #fff;
    font-weight: 400;
    color: #333;
}

button.favorite_button_in p {
    display: inline-block;
    margin: 0;
}

button.favorite_button_in:hover {
    opacity: 0.75;
}

button.favorite_button_in i {
    color: #f5a623;
    font-size: 14px;
    vertical-align: -1px;
    margin-right: 6px;
}

.is-choosen .favorite_button_in {
    background: #1a2e3d;
    border-color: #1a2e3d;
    color: #fff;
}

.is-choosen .favorite_button_in i {
    color: #fff;
}

.is-choosen .favorite_button_in p {
    font-size: 0;
    font-weight: 600;
}

.is-choosen .favorite_button_in p:before {
    font-size: 13px;
    content: "お気に入り登録済";
    color: #fff;
}


/* =============================================
   記事詳細 — ご要望フォーム
   ============================================= */
.single__detail__box__left__box__contact {
    border: 1px solid #e8edf2;
    border-top: 3px solid #2a627e;
    border-radius: 0 0 8px 8px;
    padding: 28px 32px;
    margin-top: 24px;
    background: #fff;
}


.single__detail__box__left__box__contact__box__title {
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    margin-top: 8px;
    margin-bottom: 16px;
    color: #1a2e3d;
    line-height: 1.5;
}

.single__detail__box__left__box__contact__box__des {
    margin-bottom: 16px;
    font-size: 13px;
    color: #555;
    line-height: 1.8;
}

.single__detail__box__left__box__contact textarea {
    background: #f8fafc;
    width: 100%;
    border: 1px solid #dde3e8;
    border-radius: 6px;
    padding: 12px 14px;
    font-size: 14px;
    transition: border-color .2s;
}

.single__detail__box__left__box__contact textarea:focus {
    outline: none;
    border-color: #2a627e;
}

.single__detail__box__left__box__contact textarea::placeholder {
    color: #bbb;
}

.single__detail__box__left__box__contact__box__el__submit {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

.single__detail__box__left__box__contact__box__el__submit__left {
    font-size: 13px;
    color: #666;
}


.single__detail__box__left__box__contact__box__el__submit input[type="submit"] {
    background: #2a627e;
    color: #fff;
    width: 160px;
    height: 44px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: opacity .2s;
}

.single__detail__box__left__box__contact__box__el__submit input[type="submit"]:hover {
    opacity: .85;
}

.single__detail__box__left__box__contact__box__el__submit input[type="submit"]:disabled {
    background: #c8d6de;
    cursor: not-allowed;
}

.single__detail__box__left__box__contact__box__el__submitText {
    background: #f0f8e8;
    border: 1px solid #c5e0a5;
    border-radius: 6px;
    padding: 16px 24px;
    font-weight: 600;
    font-size: 14px;
    color: #3a6a1e;
}

.single__detail__box__left__box__contact__box__el__link {
    color: #2a627e;
    text-decoration: underline;
}

.g-recaptcha {
    display: none;
}

@media screen and (max-width: 768px) {
    .single__detail__box__left__box__contact {
        padding: 20px;
        margin-top: 16px;
    }

    .single__detail__box__left__box__contact__box__title {
        font-size: 17px;
    }

    .single__detail__box__left__box__contact__box__el__submit {
        display: block;
    }

    .single__detail__box__left__box__contact__box__el__submit__left {
        text-align: center;
        margin-bottom: 16px;
    }

    .single__detail__box__left__box__contact__box__el__submit__right {
        margin-top: 0;
    }

    .single__detail__box__left__box__contact__box__el__submit input[type="submit"] {
        margin: auto;
        width: 70%;
        height: 48px;
    }

    .single__detail__box__left__box__contact__box__el__link {
        margin-top: 10px;
        display: inline-block;
    }
}


/* =============================================
   SCROLL TO TOP BUTTON
   ============================================= */
.stt {
    position: fixed;
    bottom: 32px;
    right: 28px;
    z-index: 9990;
    width: 52px;
    height: 52px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity .35s ease, visibility .35s ease, transform .35s ease;
    -webkit-tap-highlight-color: transparent;
}

.stt.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Progress ring SVG */
.stt__ring {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
    pointer-events: none;
}

.stt__track {
    fill: none;
    stroke: rgba(255, 255, 255, .12);
    stroke-width: 2;
}

.stt__progress {
    fill: none;
    stroke: #1e9bb5;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 138.23;
    /* 2πr, r=(52-4)/2=24 → 2π≂24=150.80... — will be set by JS */
    stroke-dashoffset: 138.23;
    transition: stroke-dashoffset .1s linear;
}

/* Inner circle */
.stt__inner {
    position: absolute;
    inset: 5px;
    border-radius: 50%;
    background: #1a2e3d;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, .28),
        inset 0 1px 0 rgba(255, 255, 255, .07);
    transition: background .25s, transform .25s, box-shadow .25s;
}

.stt:hover .stt__inner {
    background: #2a627e;
    transform: scale(1.06);
    box-shadow:
        0 8px 24px rgba(42, 98, 126, .4),
        inset 0 1px 0 rgba(255, 255, 255, .12);
}

.stt__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, .9);
    transition: transform .25s;
}

.stt:hover .stt__icon {
    transform: translateY(-2px);
}

.stt__icon svg {
    width: 16px;
    height: 16px;
}

/* Tooltip */
.stt__tip {
    position: absolute;
    right: 60px;
    top: 50%;
    transform: translateY(-50%) translateX(6px);
    background: #1a2e3d;
    color: rgba(255, 255, 255, .85);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .1em;
    padding: 5px 10px;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s, transform .2s;
}

.stt__tip::after {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 5px solid transparent;
    border-left-color: #1a2e3d;
}

.stt:hover .stt__tip {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

@media screen and (max-width: 768px) {
    .stt {
        bottom: 20px;
        right: 16px;
        width: 46px;
        height: 46px;
    }

    .stt__tip {
        display: none;
    }
}


/* ============================================================
   お気に入りページ (page-favorite)
   ============================================================ */

/* 件数 + 一括削除バー */
.page-template-page-favorite .single__detail__box__left__box__favoriteClear {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #dde4ed;
    border-radius: 10px;
    padding: 14px 20px;
    margin-bottom: 20px;
}

.page-template-page-favorite .single__detail__box__left__box__favoriteClear__numBox {
    font-size: 14px;
    color: #555;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.page-template-page-favorite .single__detail__box__left__box__favoriteClear__numBox__num {
    font-size: 22px;
    font-weight: 700;
    color: #2a627e;
    line-height: 1;
}

.page-template-page-favorite #clearFavorites {
    cursor: pointer;
    font-size: 12px;
    background: #fff;
    border: 1px solid #dde4ed;
    padding: 7px 16px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-radius: 6px;
    color: #aaa;
    transition: 0.2s;
    font-weight: 500;
}

.page-template-page-favorite #clearFavorites::before {
    content: "✕";
    font-size: 10px;
}

.page-template-page-favorite #clearFavorites:hover {
    background: #fff3f3;
    border-color: #e74c3c;
    color: #e74c3c;
}

/* --------------------------------------------------
   リスト全体: ベースCSSのmargin/paddingをリセット
   -------------------------------------------------- */
.page-template-page-favorite .single__detail__box__left__box__postList {
    margin-top: 0 !important;
}

/* --------------------------------------------------
   各アイテム <li>
   ベースの空スタイル(.list__items{})を上書き
   -------------------------------------------------- */
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items {
    position: relative;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    border-bottom: 1px solid #e8eef4 !important;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 0;
    background: transparent;
    transition: background 0.2s, opacity 0.4s cubic-bezier(.4, 0, .2, 1), max-height 0.5s cubic-bezier(.4, 0, .2, 1);
    opacity: 1;
    max-height: 300px;
    overflow: visible;
    will-change: opacity, max-height;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items:first-child {
    border-top: 1px solid #e8eef4;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items:hover {
    background: #f4f8fb !important;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items.fade-out {
    opacity: 0 !important;
    max-height: 0 !important;
    border: none !important;
    overflow: hidden !important;
    pointer-events: none;
}

/* --------------------------------------------------
   リンク <a>
   ベースの display:flex / justify-content:space-between /
   padding / border-bottom を全上書き
   -------------------------------------------------- */
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__link {
    flex: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 16px 0 !important;
    border-bottom: none !important;
    gap: 16px;
}

/* --------------------------------------------------
   サムネイル
   -------------------------------------------------- */
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__thumbnail {
    display: block !important;
    flex-shrink: 0;
    width: 110px;
    height: 66px;
    overflow: hidden;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__thumbnail img,
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__thumbnail__img {
    width: 100% !important;
    height: 66px !important;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__link:hover .single__detail__box__left__box__postList__box__list__items__thumbnail img,
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__link:hover .single__detail__box__left__box__postList__box__list__items__thumbnail__img {
    transform: scale(1.06);
}

/* --------------------------------------------------
   メタ情報
   ベースの width:540px / display:inline-block を上書き
   -------------------------------------------------- */
.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta {
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    flex: 1 !important;
    width: auto !important;
    min-width: 0 !important;
    gap: 6px;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__title {
    font-size: 15px !important;
    font-weight: 600;
    line-height: 1.5;
    color: #1a2e3d;
    margin-bottom: 0 !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    display: -webkit-box;
    overflow: hidden;
    transition: color 0.2s;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__link:hover .single__detail__box__left__box__postList__box__list__items__meta__title {
    color: #2a627e;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__catAndTime {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__cat__link {
    font-size: 10px !important;
    padding: 3px 8px !important;
    border-radius: 3px;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__time {
    font-size: 11px !important;
    margin-left: 0 !important;
    color: #b0b8c4;
    display: flex;
    align-items: center;
    gap: 3px;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__time i {
    font-size: 10px;
}

.page-template-page-favorite .single__detail__box__left__box__postList__box__list__items__meta__time__2 {
    border-left: 1px solid #d8e0e8 !important;
    padding-left: 6px !important;
}

/* --------------------------------------------------
   削除ボタン
   -------------------------------------------------- */
.favorite-remove-btn {
    position: relative;
    flex-shrink: 0;
    background: none;
    border: 1.5px solid transparent;
    cursor: pointer;
    color: #f7b731;
    font-size: 18px;
    margin-left: 8px;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.favorite-remove-btn:hover {
    color: #e74c3c;
    background: #fff3f3;
    border-color: #ffd0d0;
}

/* ツールチップ */
.favorite-remove-badge {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    top: auto;
    transform: translateX(-50%);
    background: #1a2e3d;
    color: #fff;
    font-size: 11px;
    padding: 5px 10px;
    border-radius: 5px;
    white-space: nowrap;
    z-index: 20;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.18);
    pointer-events: none;
    opacity: 0;
    display: block;
    transition: opacity 0.2s;
}

.favorite-remove-badge::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #1a2e3d;
}

.favorite-remove-btn:hover .favorite-remove-badge {
    opacity: 1;
}

/* --------------------------------------------------
   空状態メッセージ
   -------------------------------------------------- */
.page-template-page-favorite .fav-empty-msg {
    margin-top: 32px !important;
    padding: 60px 40px;
    background: #f8fafc;
    border: 2px dashed #c8d6e5;
    border-radius: 16px;
    font-size: 14px;
    color: #9aabb8;
    text-align: center;
    display: block;
    line-height: 1.7;
}

.page-template-page-favorite .fav-empty-msg::before {
    content: "☆";
    display: block;
    font-size: 48px;
    color: #d0dde8;
    margin-bottom: 12px;
    line-height: 1;
}


