/* =====================================================
 * サービス詳細ページ（新デザイン。2026-09-21）
 *
 * Webサイト制作・動画制作・写真撮影の3ページ共通。
 * 畔栁さんが3案から「余白と大きな数字」を選び、そのうえで
 *   ・「お悩み」から入るネガティブな訴求をやめ、サービスを端的に説明する
 *   ・文字を減らして図で見せる
 * という指示。見本 ops/design/service-website-preview.html
 *
 *   見出し → SERVICE（図）→ STRENGTH（番号つき2列）→ SCOPE（1本の帯）
 *         → RENEWAL → CASE（導入事例から自動）→ FLOW（縦のタイムライン）
 *         → RELATED（関連事業。画像を薄く敷いた帯）
 *
 * 色・書体・白い丸いボタンはサイト共通（common.css の :root、.futura、.pillButton）。
 * SEO対策・MEO対策の2ページは旧デザインのまま（assets/css/service-detail.css）。
 * ===================================================== */

@property --sweep {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

.wrapTitlePage .titleEn,
.wrapTitlePage .titleJp {
    color: #000000;
}

.areaServicePage {
    --sp-line: #E3E3E6;
    --sp-line-soft: #EFEFF2;
    --sp-soft: #F7F7F8;
    --sp-muted: #6A6A72;
    --sp-text: #292929;
    --sp-text-soft: #4A4A52;
    --sp-gold-deep: #A8812F;
    --sp-gold-light: #E8D39A;
    --sp-ease: cubic-bezier(.22, .61, .36, 1);
    padding: clamp(24px, 2.8vw, 40px) 0 0;
    background-color: #fff;
    color: var(--sp-text);
}

.areaServicePage .inner {
    max-width: 1080px;
}

.areaServicePage p,
.areaServicePage h2,
.areaServicePage h3,
.areaServicePage li,
.areaServicePage b,
.areaServicePage span {
    /* 日本語の折り返しを、語のまとまりで切る */
    word-break: auto-phrase;
}

/* ---------- 節 ---------- */
.spSec {
    padding: clamp(44px, 5.2vw, 80px) 0;
}

.spSec + .spSec {
    border-top: 1px solid var(--sp-line);
}

.spSec--soft {
    background: var(--sp-soft);
    border-top: 0;
}

.spKicker {
    font-size: 12.5px;
    letter-spacing: .28em;
    color: var(--sp-gold-deep);
}

.spH2 {
    margin-top: 13px;
    font-size: clamp(23px, 2.9vw, 35px);
    font-weight: 400;
    line-height: 1.5;
}

.spLead {
    max-width: 760px;
    margin-top: 16px;
    font-size: clamp(14px, 1.5vw, 16px);
    font-weight: 300;
    line-height: 2;
    color: var(--sp-text-soft);
}

.spCap {
    margin-top: 14px;
    font-size: 11.5px;
    font-weight: 300;
    line-height: 1.8;
    color: var(--sp-muted);
}

/* ---------- 図 ---------- */
.spFig {
    margin-top: clamp(24px, 3vw, 40px);
}

.spFigIn {
    max-width: 840px;
    margin-inline: auto;
}

.spFigSvg {
    display: block;
    width: 100%;
    height: auto;
    font-family: "Noto Sans JP", sans-serif;
}

/* 縦組みの図（狭い画面用）。広いあいだは出さない。
   同じ中身を2通り持っているのは、横長の図を縮めると文字が7px以下になって読めないため
   （2026-09-22 実測。inc/service-page.php の「スマートフォン用の図」を参照） */
.spFigWide {
    display: block;
}

.spFigNarrow {
    display: none;
}

/* 図の下の案内。図が収まりきらない狭い画面でだけ出す（下の「画面が狭いとき」を参照） */
.spFigHint {
    display: none;
}

.spFgT { font-size: 13px; fill: var(--sp-text); }
.spFgS { font-size: 11px; fill: var(--sp-muted); }
.spFgW { font-size: 12px; fill: #fff; }

.spFgEn {
    font-family: "FuturaLTProLight", "Futura", sans-serif;
    font-size: 11px;
    letter-spacing: .16em;
    fill: var(--sp-gold-deep);
}

/* 左に文・右に図 */
.spSplit {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(24px, 4vw, 60px);
    align-items: center;
}

/* ---------- 強み ---------- */
.spSt {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(22px, 3.2vw, 52px);
    margin-top: clamp(26px, 3.2vw, 44px);
    list-style: none;
}

.spSt li {
    padding-top: 20px;
    border-top: 1px solid var(--sp-line);
}

.spStN {
    font-size: clamp(26px, 3.4vw, 42px);
    font-weight: 300;
    line-height: 1;
    color: var(--sp-gold-light);
}

.spSt b {
    display: block;
    margin-top: 12px;
    font-size: clamp(17px, 2.1vw, 22px);
    font-weight: 400;
    line-height: 1.5;
}

.spStD {
    margin-top: 12px;
    font-size: 13.5px;
    font-weight: 300;
    line-height: 2;
    color: var(--sp-text-soft);
}

/* ---------- 自由に使える節（3列の一覧） ----------
   Webサイト制作は「作り替え」、動画は「AI動画制作例」、写真は「写真撮影例」。
   太い線をやめ、細い線と金色の短い印だけにしている（2026-09-21 畔栁さんの指示でシンプルに） */
.spRn {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(20px, 3vw, 44px) clamp(20px, 3vw, 46px);
    margin-top: clamp(26px, 3.2vw, 44px);
    list-style: none;
}

.spRn li {
    position: relative;
    padding-top: 20px;
    border-top: 1px solid var(--sp-line);
}

/* 線の左端だけ金色にして、区切りを分かりやすくする */
.spRn li::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 0;
    width: 28px;
    height: 1px;
    background: var(--gold);
}

.spRn b {
    display: block;
    font-size: clamp(15.5px, 1.8vw, 18px);
    font-weight: 400;
    line-height: 1.55;
}

.spRn p {
    margin-top: 10px;
    font-size: 12.5px;
    font-weight: 300;
    line-height: 1.95;
    color: var(--sp-text-soft);
}

/* しるしを選んだとき（動画・写真）。2列にして、線画を文字の左に置く。
   丸で囲わず線だけ（2026-09-21 畔栁さんが5案から「2 しるしを左、文字を右」）。
   1つあたりの幅が広くなるので、説明が2行に収まって読みやすい */
.spRn--ico {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(26px, 3.2vw, 44px) clamp(34px, 4.4vw, 70px);
}

.spRn--ico li {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    gap: clamp(16px, 2vw, 24px);
    align-items: start;
    padding-top: 0;
    border-top: 0;
}

.spRn--ico li::before {
    content: none;
}

.spRnIco svg {
    display: block;
    width: 34px;
    height: 34px;
    margin-top: 2px;
    overflow: visible;
    fill: none;
    stroke: var(--sp-gold-deep);
    stroke-width: 1.05;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ---------- 制作の事例（プラグインが出す形にあてる） ---------- */
.spCase {
    margin-top: clamp(26px, 3.2vw, 42px);
}

.spCaseMore {
    margin-top: clamp(26px, 3vw, 40px);
}

/* ---------- ご依頼の流れ ---------- */
.spFlow {
    margin-top: clamp(26px, 3.2vw, 42px);
    padding-left: clamp(20px, 3vw, 44px);
    border-left: 1px solid var(--sp-line);
    list-style: none;
}

.spFlow li {
    position: relative;
    padding: 0 0 clamp(22px, 2.8vw, 34px);
}

.spFlow li:last-child {
    padding-bottom: 0;
}

.spFlow li::before {
    content: "";
    position: absolute;
    top: 8px;
    left: calc(clamp(20px, 3vw, 44px) * -1 - 4px);
    width: 9px;
    height: 9px;
    border: 1px solid var(--gold);
    border-radius: 50%;
    background: #fff;
}

.spFlowK {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 13px;
}

.spFlowM {
    font-size: 12px;
    letter-spacing: .16em;
    color: var(--sp-gold-deep);
}

.spFlow b {
    font-size: clamp(16px, 1.9vw, 20px);
    font-weight: 400;
}

.spFlow p {
    max-width: 700px;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 300;
    line-height: 1.95;
    color: var(--sp-text-soft);
}

/* ---------- 関連事業 ----------
   横いっぱいの帯に画像を薄く敷き、その上に文字を置く（畔栁さんが5案から案4）。
   帯ぜんたいが1つのリンク。カーソルを合わせると下に金色の線が引かれ、
   右端の丸いボタンのふちを金色の線が一周する（トップページの丸いボタンと同じ動き）。 */
.spRel {
    margin-top: clamp(24px, 2.8vw, 36px);
    list-style: none;
}

.spRel li + li {
    margin-top: 10px;
}

.spRel a {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 30px;
    align-items: center;
    gap: 16px;
    padding: clamp(24px, 3vw, 34px) clamp(20px, 2.6vw, 32px);
    overflow: hidden;
    background: var(--sp-soft);
    color: inherit;
    text-decoration: none;
}

.spRelImg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.spRelImg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(255, 255, 255, .96) 0%, rgba(255, 255, 255, .9) 46%, rgba(255, 255, 255, .45) 100%);
}

/* 帯は横長なので画像は上下を切り落とす。見せたいものが中央に無い行だけ --sp-pos で動かす */
.spRelImg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--sp-pos, center);
    transition: transform .7s var(--sp-ease);
}

.spRelTx,
.spRel i {
    position: relative;
    z-index: 1;
}

/* 背景に写真がある分、文字は濃いめにして読みやすさを確保する */
.spRelEn {
    display: block;
    font-weight: 400;
    font-size: 11.5px;
    letter-spacing: .2em;
    color: var(--sp-gold-deep);
}

.spRelT {
    display: block;
    margin-top: 6px;
    font-size: clamp(17px, 2.2vw, 24px);
    font-weight: 500;
    line-height: 1.5;
    color: var(--ink);
}

.spRelD {
    display: block;
    max-width: 460px;
    margin-top: 7px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.85;
    color: #3C3C44;
}

/* 帯の下に引かれる金色の線 */
.spRel a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 2;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: width .55s var(--sp-ease);
}

.spRel i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 1px solid #CFCFD6;
    border-radius: 50%;
    background: #fff;
    font-style: normal;
    transition: background-color .45s var(--sp-ease), border-color .45s var(--sp-ease);
}

/* ふちを一周する金色の線。common.css の .pillButton とまったく同じ仕掛け */
.spRel i::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1.5px;
    pointer-events: none;
    background: conic-gradient(from -90deg, var(--gold) var(--sweep), transparent 0);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
    transition: --sweep .9s cubic-bezier(.65, 0, .35, 1);
}

.spRel i span {
    display: block;
    font-size: 12px;
    line-height: 1;
    color: var(--sp-muted);
    transition: transform .45s var(--sp-ease), color .45s;
}

@media (hover: hover) {
    .spRel a:hover .spRelImg img { transform: scale(1.04); }
    .spRel a:hover::after { width: 100%; }
    .spRel a:hover i { background: #FBF8F1; border-color: transparent; }
    .spRel a:hover i::before { --sweep: 360deg; }
    .spRel a:hover i span { color: var(--sp-gold-deep); transform: translateX(2px); }
}

@media (prefers-reduced-motion: reduce) {
    .spRel a::after,
    .spRel .spRelImg img,
    .spRel i,
    .spRel i::before,
    .spRel i span {
        transition: none;
    }

    .spRel a:hover::after {
        width: 100%;
    }
}

/* ---------- 画面が狭いとき ---------- */
@media screen and (max-width: 900px) {
    .spSplit,
    .spSt {
        grid-template-columns: minmax(0, 1fr);
    }

    .spRn {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    /* しるしのある一覧は、ここで1列にする（しるしの分だけ幅を使うため） */
    .spRn--ico {
        grid-template-columns: minmax(0, 1fr);
    }

    /* 縦組みの図があるものは、そちらに入れ替える。横にずらす必要がなくなる */
    .spFig--both .spFigWide {
        display: none;
    }

    .spFig--both .spFigNarrow {
        display: block;
    }

    .spFig--both .spFigScroll {
        overflow-x: visible;
    }

    /* 縦組みの図が無いものは、枠の中で横にずらして見てもらう。
       ただ切れているだけに見えないよう、案内を出す（2026-09-22。それまでは何も出ていなかった） */
    .spFigScroll {
        overflow-x: auto;
        overscroll-behavior-x: contain;
        scrollbar-width: thin;
        scrollbar-color: var(--sp-line) transparent;
    }

    .spFigScroll .spFigWide .spFigSvg {
        min-width: 620px;
    }


}

/* 図の案内は、図がはみ出す幅でだけ出す。
   図は620px、左右の余白は24pxずつなので、画面が 668px より狭いとはみ出す */
@media screen and (max-width: 667px) {
    .spFigHint {
        display: block;
        margin-top: 10px;
        text-align: right;
        font-size: 11.5px;
        font-weight: 300;
        line-height: 1.6;
        color: var(--sp-muted);
    }

    /* 矢印は飾りなので、文字ではなくこちらで足す */
    .spFigHint::after {
        content: " →";
        color: var(--sp-gold-deep);
    }
}

@media screen and (max-width: 560px) {
    .spRn {
        grid-template-columns: minmax(0, 1fr);
    }

    .spRn--ico li {
        grid-template-columns: 30px minmax(0, 1fr);
        gap: 14px;
    }

    .spRnIco svg {
        width: 28px;
        height: 28px;
    }
}
