/* 申し込みの画面（app.cs-analytics.jp）。サービスサイトの style.css の語彙をそのまま使い、足りない部品だけを足す */
body.buy { background: var(--bg-gray); }
.buy .site-header { position: static; }
.buy .gnav { margin-left: auto; }
.buy-main { padding: 72px 0 120px; }
.buy-head { max-width: 760px; margin-bottom: 48px; }
.buy-head h1 { font-size: clamp(32px, 3.6vw, 46px); margin-bottom: 20px; }
.buy-head p { color: var(--ink-soft); font-size: 15.5px; }
.buy .pricing { padding: 0; overflow: visible; }

/* 流れ（プランを選ぶ画面は、サイトの「しくみ」の部品 .mech-steps をそのまま使う） */
.buy-flow { margin-top: 104px; }
.buy-flow .kicker { margin-bottom: 64px; }
.buy-flow .mech-step { padding-bottom: 32px; }
@media (max-width: 960px) { .buy-flow .mech-steps { grid-template-columns: 1fr; gap: 56px; } }
/* 完了の画面の手順 */
.bsteps { margin-top: 96px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; }
.bstep { border-top: 2px solid var(--ink); padding-top: 22px; }
.bstep-num { font-family: var(--font-num); font-weight: 800; font-size: 40px; line-height: 1; color: var(--teal); display: block; margin-bottom: 14px; }
.bstep h3 { font-size: 18px; margin-bottom: 8px; }
.bstep p { font-size: 14px; color: var(--ink-soft); line-height: 1.95; }
.buy-note { margin-top: 56px; font-size: 13px; color: var(--ink-soft); line-height: 1.9; max-width: 860px; }
.buy-note a, .buy-sub a { color: var(--teal-deep); text-decoration: underline; text-underline-offset: 3px; }

/* 確認 */
.confirm { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 56px; align-items: start; }
.panel { background: #fff; border-radius: 24px; padding: 40px 40px 36px; box-shadow: var(--shadow-card); }
.panel h2 { font-size: 22px; margin-bottom: 8px; }
.panel .panel-lead { color: var(--ink-soft); font-size: 14px; margin-bottom: 30px; }
.f { margin-bottom: 22px; }
.f label { display: block; font-family: var(--font-head); font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.f label small { font-family: var(--font); font-weight: 400; font-size: 12.5px; color: var(--mute); margin-left: 8px; }
.f input, .f select { width: 100%; height: 52px; font: inherit; font-size: 15.5px; color: var(--ink); background: #fff; border: 1.5px solid #D5E0DC; border-radius: 12px; padding: 0 16px; }
.f input::placeholder { color: #B4C1BC; }
.f input:focus, .f select:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 4px rgba(14, 148, 136, .14); }
.f-row { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 16px; }
.f-hint { font-size: 12.5px; color: var(--ink-soft); margin-top: 7px; }
.panel .btn { width: 100%; justify-content: center; margin-top: 10px; }
.panel-foot { font-size: 12.5px; color: var(--ink-soft); line-height: 1.9; margin-top: 18px; }

.summary { position: sticky; top: 32px; background: #fff; color: var(--ink); border-radius: 24px; padding: 36px 34px 32px; box-shadow: 0 0 0 3px var(--teal), 0 30px 70px -24px rgba(8, 33, 29, .28); }
.summary .s-kick { font-family: var(--font-head); font-weight: 700; font-size: 13px; letter-spacing: .06em; color: var(--teal-deep); margin-bottom: 14px; }
.summary .s-name { font-family: var(--font-head); font-weight: 900; font-size: 30px; letter-spacing: .04em; line-height: 1.3; }
.summary .s-term { font-size: 14px; color: var(--ink-soft); margin-top: 2px; }
.summary .s-price { margin: 24px 0 4px; display: flex; align-items: baseline; gap: 8px; }
.summary .s-price b { font-family: var(--font-num); font-weight: 800; font-size: 50px; line-height: 1; letter-spacing: -.01em; }
.summary .s-price span { font-size: 14px; color: var(--ink-soft); }
.summary dl { margin-top: 24px; border-top: 1px solid var(--line); }
.summary dt { font-size: 12.5px; color: var(--ink-soft); padding-top: 15px; }
.summary dd { font-family: var(--font-head); font-weight: 700; font-size: 16px; padding-bottom: 15px; border-bottom: 1px solid var(--line); }
.summary dd small { display: block; font-family: var(--font); font-size: 12.5px; font-weight: 400; color: var(--ink-soft); margin-top: 2px; }
.summary .s-free { margin-top: 22px; background: var(--teal-pale); border-radius: 14px; padding: 14px 16px; font-size: 13.5px; line-height: 1.8; }
.summary .s-free b { color: var(--teal-deep); font-weight: 700; }
.summary a { color: var(--teal-deep); text-decoration: underline; text-underline-offset: 3px; font-size: 13px; display: inline-block; margin-top: 18px; }

/* 完了 */
.done { max-width: 820px; }
.done .buy-head { max-width: none; }
.keycard { background: #fff; border-radius: 24px; box-shadow: var(--shadow-card); padding: 34px 40px; margin: 8px 0 56px; }
.keycard .k-lab { font-family: var(--font-head); font-weight: 700; font-size: 13px; color: var(--ink-soft); margin-bottom: 10px; }
.keycard .k-val { font-family: var(--font-num); font-weight: 700; font-size: clamp(22px, 3vw, 34px); letter-spacing: .06em; color: var(--ink); word-break: break-all; }
.keycard .k-sub { font-size: 13px; color: var(--ink-soft); margin-top: 12px; }
.done .bsteps { margin-top: 0; grid-template-columns: 1fr; gap: 0; }
.done .bstep { display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: start; border-top: 1px solid var(--line); padding: 22px 0; }
.done .bstep:last-child { border-bottom: 1px solid var(--line); }
.done .bstep-num { font-size: 30px; margin: 2px 0 0; }
.done .actions { margin-top: 40px; display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }

/* 下の帯（サイトの濃い帯を、申し込みの画面用に低くしたもの） */
.buy-footer { background: #0A1714; color: rgba(255,255,255,.58); padding: 34px 0; font-size: 12.5px; }
.buy-footer .wrap { display: flex; gap: 26px; flex-wrap: wrap; align-items: center; }
.buy-footer a { color: rgba(255,255,255,.78); } .buy-footer a:hover { color: #fff; }
.buy-footer .sp { flex: 1; }
@media (max-width: 960px) { .confirm { grid-template-columns: 1fr; gap: 28px; } .summary { position: static; order: -1; } .bsteps { grid-template-columns: 1fr; gap: 34px; } .buy-main { padding: 48px 0 80px; } .panel { padding: 30px 24px; } .f-row { grid-template-columns: 1fr; gap: 0; } }

/* --- 実装で足した部品（見本に無い場面。サイトの色と角丸の語彙だけで組む） --- */
/* 手元デモの帯（DEMO_MODE のときだけ） */
.buy-demobar { background: var(--teal-pale); color: var(--teal-deep); font-size: 12.5px; }
.buy-demobar .wrap { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; padding-top: 7px; padding-bottom: 7px; }
.buy-demobar a { color: var(--teal-deep); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
/* 知らせ（受付の停止・プランの指定が不正・入力の誤り） */
.buy-notice { background: var(--teal-pale); color: var(--ink); border-radius: 14px; padding: 14px 18px; font-size: 14px; line-height: 1.85; max-width: 760px; margin: 0 0 24px; }
.buy-notice b { color: var(--teal-deep); font-weight: 700; }
.buy-notice-err { background: #FBEBE9; }
.buy-notice-err b { color: #A8322B; }
.buy-head + .buy-notice { margin-top: -24px; }
.buy-main > .wrap > .buy-notice:first-child { margin-bottom: 32px; }
.panel .buy-notice { max-width: none; margin-bottom: 26px; }
/* プランの「受け付けていません」 */
.plan-closed { font-size: 13.5px; color: var(--ink-soft); margin-top: 8px; padding: 14px 0; text-align: center; }
/* 入力欄の誤り */
.f.f-bad input, .f.f-bad select { border-color: #C0453D; }
.f.f-bad input:focus, .f.f-bad select:focus { border-color: #C0453D; box-shadow: 0 0 0 4px rgba(192, 69, 61, .14); }
.f-err { font-size: 12.5px; color: #A8322B; margin-top: 7px; line-height: 1.7; }
.panel .f-row .f { margin-bottom: 22px; }
/* お申し込みの内容の枠の中の告知（年契約・無料期間なし）。濃い色は使わず、淡い琥珀 */
.summary .s-warn { margin-top: 22px; background: rgba(223, 164, 60, .16); border-radius: 14px; padding: 14px 16px; font-size: 13px; line-height: 1.85; }
.summary .s-warn b { font-weight: 700; }
.summary .s-small { margin-top: 22px; font-size: 12.5px; color: var(--ink-soft); line-height: 1.85; }
.summary dd a { display: block; margin: 2px 0 0; font-size: 12.5px; font-weight: 400; }
.panel .panel-actions { margin-top: 10px; }
/* 完了の画面 */
.bstep p a { color: var(--teal-deep); text-decoration: underline; text-underline-offset: 3px; }
/* 利用規約・エラー */
.buy-legal { max-width: 760px; font-size: 15px; line-height: 2; }
.buy-legal h2 { font-size: 20px; margin: 40px 0 10px; }
.buy-legal p { margin-bottom: 12px; }
.buy-legal .buy-mute { color: var(--ink-soft); font-size: 14px; }
.buy-sub { margin-top: 28px; font-size: 14.5px; }

/* 短い画面でも下の帯を下に置く */
body.buy { min-height: 100vh; display: flex; flex-direction: column; }
.buy-main { flex: 1; }
