/* =========================================================
   本編のスタイル（まだ最小限。オープニング確認用）
   ========================================================= */
:root {
    --purple: #8B5CF6;
    --purple-dark: #7C3AED;
    --pink: #EC4899;
    --cyan: #06B6D4;
    --yellow: #FACC15;
    --bg: #F4FAFA;      /* 背景動画が読めないときの色 */
    --text: #1F2937;
    --text-light: #6B7280;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Zen Maru Gothic', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.8;
}

/* オープニング表示中は本編をスクロールさせない */
body.is-opening { overflow: hidden; }

.site { max-width: 960px; margin: 0 auto; padding: 0 20px; }
.site > .section:first-child { padding-top: 10vh; }







.btn {
    display: inline-block;
    padding: .9em 2em;
    border-radius: 999px;
    background: linear-gradient(120deg, var(--purple), var(--pink));
    color: #fff; text-decoration: none; font-weight: 700;
    box-shadow: 0 6px 20px rgba(139,92,246,.3);
    transition: transform .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(139,92,246,.4); }

.placeholder {
    margin: 0 0 12vh;
    padding: 2em;
    border: 2px dashed #cbd5e1;
    border-radius: 16px;
    color: var(--text-light);
    text-align: center;
}

/* =========================================================
   本編セクション
   ========================================================= */
.section { padding: 8vh 0; }
.section-title {
    margin: 0 0 .6em;
    font-size: clamp(22px, 4.2vw, 34px);
    font-weight: 900;
    text-align: center;
}
.section-lead { margin: 0 0 2.5em; text-align: center; color: var(--text-light); }

.btn-ghost {
    background: none;
    color: var(--purple-dark);
    border: 2px solid var(--purple);
    box-shadow: none;
    margin-left: .6em;
}
.btn-ghost:hover { box-shadow: 0 6px 18px rgba(139,92,246,.2); }


/* カード */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-top: 2.5em;
}
.card {
    background: #fff;
    border-radius: 16px;
    padding: 2em 1.6em;
    box-shadow: 0 4px 24px rgba(139,92,246,.1);
    transition: transform .25s ease, box-shadow .25s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 10px 34px rgba(139,92,246,.18); }
.card h3 { margin: .2em 0 .6em; font-size: 19px; }
.card p { margin: 0; color: var(--text-light); font-size: 15px; }
.card-icon { font-size: 30px; }

.note { margin-top: 2em; text-align: center; color: var(--text-light); font-size: 14px; }

/* ご依頼の流れ */
.flow { counter-reset: step; list-style: none; margin: 2.5em 0 0; padding: 0; }
.flow li {
    counter-increment: step;
    position: relative;
    padding: 0 0 1.8em 3.4em;
    border-left: 2px dashed #d8b4fe;
    margin-left: 1.2em;
}
.flow li:last-child { border-left-color: transparent; padding-bottom: 0; }
.flow li::before {
    content: counter(step);
    position: absolute; left: -1.2em; top: -.15em;
    width: 2.4em; aspect-ratio: 1;
    display: grid; place-items: center;
    border-radius: 50%;
    background: linear-gradient(120deg, var(--purple), var(--pink));
    color: #fff; font-weight: 700;
}
.flow strong { display: block; font-size: 17px; }
.flow span { color: var(--text-light); font-size: 15px; }

/* お問い合わせ */
.section-contact { padding-bottom: 10vh; }
.contact-wrap { max-width: 620px; margin: 0 auto; }
.contact-form {
    position: relative;
    background: #fff;
    border-radius: 18px;
    padding: 2.2em;
    box-shadow: 0 4px 24px rgba(139,92,246,.1);
}
.cf-group { margin-bottom: 1.4em; }
.cf-group label { display: block; margin-bottom: .5em; font-weight: 700; font-size: 15px; }
.cf-req { color: var(--pink); }
.cf-group input,
.cf-group select,
.cf-group textarea {
    width: 100%;
    padding: .8em 1em;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font: inherit;
    font-size: 15px;
    background: #fff;
    color: var(--text);
    transition: border-color .2s ease;
}
.cf-group input:focus,
.cf-group select:focus,
.cf-group textarea:focus { outline: none; border-color: var(--purple); }
.cf-group textarea { resize: vertical; }
.cf-actions { text-align: center; }
.cf-actions .btn { border: 0; font-size: 16px; }

.contact-done,
.contact-error {
    border-radius: 14px;
    padding: 1.6em;
    text-align: center;
}
.contact-done { background: #ecfdf5; border: 2px solid #6ee7b7; }
.contact-done p { margin: .3em 0; }
.contact-error { background: #fef2f2; border: 2px solid #fca5a5; margin-bottom: 1.4em; color: #b91c1c; }

/* フッター */
.footer {
    padding: 4vh 20px;
    text-align: center;
    background: linear-gradient(120deg, var(--purple), var(--pink) 55%, var(--cyan));
    color: #fff;
}
.footer-logo { margin: 0; font-size: 22px; font-weight: 900; letter-spacing: .06em; }
.footer-note { margin: .3em 0 1.4em; font-size: 14px; opacity: .9; }
.footer-copy { margin: 0; font-size: 12px; opacity: .75; }

@media (max-width: 600px) {
    
    .btn-ghost { margin-left: 0; }
    .contact-form { padding: 1.6em; }
}


/* =========================================================
   オープニングからの着地
   ========================================================= */
/* 着地直後、Heroがすっと立ち上がる */


}

/* 背景ブロブの上に本文を載せる */
.site, .footer { position: relative; z-index: 1; }
body { background: var(--bg); }

@media (prefers-reduced-motion: reduce) {

}


/* =========================================================
   ヘッダー
   ========================================================= */
.header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px clamp(16px, 3vw, 40px);
    padding-top: calc(14px + env(safe-area-inset-top, 0px));
    background: rgba(255,255,255,.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(139,92,246,.12);
    /* オープニング中は隠しておき、着地と同時に降りてくる */
    transform: translateY(-100%);
    opacity: 0;
    transition: transform .7s cubic-bezier(.22,1,.36,1) .15s, opacity .5s ease .15s;
}
body.is-opened .header,
body:not(.is-opening) .header { transform: translateY(0); opacity: 1; }

.header-logo {
    font-size: clamp(16px, 2vw, 21px);
    font-weight: 900;
    letter-spacing: .04em;
    text-decoration: none;
    background: linear-gradient(120deg, var(--purple), var(--pink) 60%, var(--cyan));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.header-nav { display: flex; align-items: center; gap: clamp(12px, 2vw, 28px); }
.header-nav a {
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    transition: color .2s ease;
}
.header-nav a:hover { color: var(--purple-dark); }
.header-cta {
    padding: .5em 1.3em;
    border-radius: 999px;
    background: linear-gradient(120deg, var(--purple), var(--pink));
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(139,92,246,.3);
}
@media (max-width: 640px) {
    .header-nav a:not(.header-cta) { display: none; }
}

/* =========================================================
   ページトップ（オープニングの着地先）
   横長画面 : 画面いっぱい（cover）
   縦長画面 : 画像を丸ごと見せる（16:9のまま・横100%）
   どちらもオープニングの映像と同じ描画になるよう揃えてある。
   ========================================================= */
.visual {
    position: relative;
    background: #14121c;
}
.visual-img {
    width: 100%;
    background: #000 url("../images/top1.webp") center / cover no-repeat;
}

/* ---------- 画像より横長の画面：画面を覆う（上下が切れるだけで横は100%） ---------- */
@media (min-aspect-ratio: 16/9) {
    .visual {
        min-height: 100svh;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        align-items: center;
        gap: 18px;
        padding: 0 20px 96px;
    }
    .visual-img { position: absolute; inset: 0; }
    /* 下端を軽く暗くしてボタンを読みやすく */
    .visual::after {
        content: "";
        position: absolute;
        inset: auto 0 0 0;
        height: 34%;
        background: linear-gradient(180deg, transparent, rgba(0,0,0,.55));
        pointer-events: none;
    }
}

/* ---------- 画像より縦長の画面 ----------
   横は常に100%。画像は切らずに全体を見せる
   （16:9より縦長だと cover は左右を切ってしまうので、この分岐にする） ---------- */
@media (max-aspect-ratio: 16/9) {
    .visual {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 20px;
        padding: 0 0 36px;
        overflow: hidden;
    }
    /* ヘッダーのぶんだけ下げて、オープニングと同じ位置・同じ大きさに置く */
    .visual-img {
        width: 100%;
        aspect-ratio: 16 / 9;
        margin-top: var(--header-h, 56px);
        margin-bottom: 24px;
        flex: 0 0 auto;
    }
    .visual-actions {
        width: 100%;
        max-width: 420px;
        padding: 0 20px;
        flex-direction: column;
    }
    .visual-actions .btn { text-align: center; }
}

.visual-actions {
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}
body.is-opened .visual-actions {
    animation: visual-land .7s cubic-bezier(.22,1,.36,1) both .45s;
}
@keyframes visual-land {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: none; }
}

.btn-on-dark {
    background: rgba(255,255,255,.92);
    color: var(--purple-dark);
    border-color: transparent;
}
.btn-on-dark:hover { background: #fff; }

.visual-scroll {
    position: relative;
    z-index: 2;
    font-size: 11px;
    letter-spacing: .28em;
    color: rgba(255,255,255,.85);
    text-shadow: 0 2px 8px rgba(0,0,0,.6);
}
.visual-scroll::after {
    content: "";
    display: block;
    width: 1px; height: 30px;
    margin: 8px auto 0;
    background: linear-gradient(180deg, rgba(255,255,255,.9), transparent);
    animation: scroll-line 2s ease-in-out infinite;
    transform-origin: top;
}
@keyframes scroll-line {
    0%,100% { transform: scaleY(.4); opacity: .4; }
    50%     { transform: scaleY(1);  opacity: 1; }
}

/* オープニング表示中はスクロール禁止 */
body.is-opening { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
    .visual-scroll::after { animation: none; }
    body.is-opened .visual-actions { animation: none; }
    .header { transform: none; opacity: 1; }
}


/* =========================================================
   ステージ版の調整（配信画面）
   ========================================================= */
/* 最後のチャプター（旧フッター） */
.chapter--end .chapter-inner { text-align: center; }
.chapter--end .footer-logo {
    margin: 0;
    font-size: clamp(24px, 4vw, 36px);
    font-weight: 900;
    letter-spacing: .06em;
    background: linear-gradient(120deg, var(--purple), var(--pink) 55%, var(--cyan));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.chapter--end .footer-note { margin: .4em 0 1.8em; color: var(--text-light); font-size: 15px; }
.chapter--end .footer-copy { margin: 2em 0 0; font-size: 12px; color: var(--text-light); }
.end-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 0;
}
.end-actions .btn-ghost { margin-left: 0; }

/* ステージ内では問い合わせフォームを1画面に収める */
.stage .contact-form { padding: 1.6em; }
.stage .cf-group { margin-bottom: 1em; }
.stage .section-lead { margin-bottom: 1.4em; }


/* =========================================================
   背景動画に載せるときの調整
   （@mp4/雑談用.mp4 のパネルに合わせて、白＋細い線の箱にする）
   ========================================================= */
.stage .card,
.stage .contact-form,
.stage .contact-done,
.stage .contact-error {
    border: 1.5px solid var(--ink, #17313a);
    border-radius: 18px;
    background: rgba(255,255,255,.93);
    box-shadow: 0 10px 30px rgba(23,49,58,.10);
}
.stage .card:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(23,49,58,.16); }
.stage .card p,
.stage .section-lead,
.stage .note { color: #4b6670; }

/* 流れの線も動画の色に合わせる */
.stage .flow li { border-left-color: rgba(23,49,58,.35); }

/* 背景が明るいので、見出しの未読文字を少し濃くする */
.stage [data-chars] .ch { color: #9fb7be; }

/* 入力欄 */
.stage .cf-group input,
.stage .cf-group select,
.stage .cf-group textarea { border-color: rgba(23,49,58,.25); }
.stage .cf-group input:focus,
.stage .cf-group select:focus,
.stage .cf-group textarea:focus { border-color: var(--mint-d, #3FB6BE); }


/* =========================================================
   カーソル
   ・ふつう … ▲のグラデーション（images/cursor/arrow.svg）
   ・リンク … ▲＋「Link」のボタン（images/cursor/link.svg）
   ・ボタン等 … ▲の大きいほう（images/cursor/arrow-lg.svg）
   形や色を変えるときは images/cursor/*.svg を直接編集し、
   同じ名前の .png も作り直す（SVGカーソルを読めないブラウザ用の控え）。
   PNGは 128px 以下でないとブラウザに無視されるので注意。
   ========================================================= */
/* メディアクエリで囲まない。
   タッチ対応のノートPCなどは (hover: hover) / (pointer: fine) が偽になり、
   マウスがあってもカーソル指定が効かなくなるため。
   タッチだけの端末にはカーソル自体が無いので、指定しても害はない。 */
body {
    cursor: url("../images/cursor/arrow.svg") 4 3,
            url("../images/cursor/arrow.png") 4 3, default;
}

/* リンクの上では、▲の右下に「Link」のボタンが付く */
a {
    cursor: url("../images/cursor/link.svg") 4 3,
            url("../images/cursor/link.png") 4 3, default;
}

/* ボタン・選択・シークバーは▲の大きいほう */
button, label, summary, select, .seek, .seek-bar, .modal-close,
.seek-row, .seek-icon, .seek-time, .seek-chapter {
    cursor: url("../images/cursor/arrow-lg.svg") 5 3,
            url("../images/cursor/arrow-lg.png") 5 3, default;
}

/* 入力欄はブラウザ標準（Iビーム）のまま */
input[type="text"], input[type="email"], textarea { cursor: auto; }
