/*
  『COSPLAY LOVE! : Enchanted princess』の作品ページとパッチのページ。
  置き場: confiture.info/cosplaylove/assets/cpl.css

  見た目の元は作品そのもの。キービジュアルの「水色の地に白い水玉と花」と、ロゴの
  「Enchanted Princess」のピンクのリボン。見出しはそのリボンの形にしてある。
  色はロゴから取った（ピンク・コーラル・ラベンダー・ミント・水色）。
  明るい作品なので、暗い画面への切り替えは持たない。色はすべてここで明示している。
  ストアのバッジは各社の配布物なので、切らず・角を変えず・縦横比を変えずに置く。
*/
:root {
  --ink: #3a2a3f;
  --ink-soft: #6e5f73;
  --paper: #ffffff;
  --sky: #e8f5fc;
  --sky-deep: #b9e2f6;
  --dot: #ffffff;
  --pink: #ef4f97;
  --pink-deep: #d63a82;
  --rose: #ff8fb8;
  --coral: #f6866f;
  --lavender: #a685e2;
  --mint: #7fd3ad;
  --line: #f3d6e5;
  --ribbon: linear-gradient(90deg, #f25b9c 0%, #ef4f97 50%, #e94791 100%);
  --round: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Zen Kaku Gothic New", sans-serif;
  --jp: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font-family: var(--jp); font-size: 16px; line-height: 1.9;
  overflow-wrap: anywhere;
  /* キービジュアルと同じ、水色の地に白い水玉 */
  background-color: var(--sky);
  background-image: radial-gradient(var(--dot) 22%, transparent 23%), radial-gradient(var(--dot) 22%, transparent 23%);
  background-size: 56px 56px; background-position: 0 0, 28px 28px;
}
/* 日本語は、書き出すときに BudouX が入れた <wbr>（文節の切れ目）でだけ折り返す。
   入力欄やコードは普通に折り返す（imel.co.jp の assets/overrides.css と同じ）。 */
html[lang="ja"] body { word-break: keep-all; }
html[lang="ja"] :is(textarea, input, pre, code, kbd, samp) { word-break: normal; }
img { display: block; max-width: 100%; height: auto; }
a { color: var(--pink-deep); }
:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.nb { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- ヘッダー ---- */
.head { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: blur(6px); border-bottom: 3px solid var(--rose); }
.head .wrap { display: flex; align-items: center; gap: 10px 22px; min-height: 64px; flex-wrap: wrap; }
.head .title-logo { margin-right: auto; }
.head .logo { width: 108px; }
.head nav.menu { display: flex; gap: 4px 18px; font-family: var(--round); font-weight: 700; font-size: 15px; flex-wrap: wrap; }
.head nav.menu a { color: var(--ink); text-decoration: none; }
.head nav.menu a:hover { color: var(--pink); }
/* ブランドのトップへ。作品ページの中からいつでも Confiture へ戻れるように、ヘッダーの右端に置く */
.brand-link { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 8px; border-radius: 99px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); text-decoration: none; }
.brand-link:hover { box-shadow: inset 0 0 0 2px var(--rose); }
.brand-link img:first-child { width: 20px; }
.brand-link img:last-child { width: 76px; }
.head .sns { display: flex; gap: 12px; font-size: 13px; font-weight: 700; }
.head .sns a { color: var(--ink-soft); text-decoration: none; }
.head .langs { display: flex; gap: 2px; font-size: 12px; font-weight: 700; }
.head .langs a { color: var(--ink-soft); text-decoration: none; padding: 2px 9px; border-radius: 99px; }
.head .langs a[aria-current="page"] { color: #fff; background: var(--pink); }

/* ---- ヒーロー ---- */
.hero { position: relative; background: #fff; }
.hero-art { position: relative; aspect-ratio: 16 / 9; max-height: 82vh; width: 100%; overflow: hidden; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.hero-art::after { content: ""; position: absolute; inset: auto 0 0 0; height: 38%; background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .92)); }
.hero-copy { position: absolute; left: max(16px, calc((100vw - 1120px) / 2)); bottom: clamp(18px, 4vw, 48px); display: grid; gap: 10px; justify-items: start; z-index: 2; }
.hero-copy h1 { margin: 0; }
.hero-copy .logo { width: clamp(220px, 32vw, 440px); filter: drop-shadow(0 6px 18px rgba(214, 58, 130, .25)); }
.onsale { font-family: var(--round); font-weight: 800; font-size: clamp(20px, 2.6vw, 30px); color: #fff; background: var(--ribbon); padding: 2px 22px 4px; clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 50%, 100% 100%, 0 100%, 12px 50%); }
.hero-plat { margin: 0; font-size: 13px; font-weight: 700; color: var(--ink); background: rgba(255, 255, 255, .85); padding: 2px 10px; border-radius: 4px; }

/* ---- 見出し（ロゴのリボンの形） ---- */
.section { padding-block: clamp(26px, 3.6vw, 44px); }
.ribbon { display: flex; align-items: center; gap: 16px; margin: 0 0 clamp(16px, 2.4vw, 24px); }
.ribbon h2 {
  margin: 0; font-family: var(--round); font-weight: 800; font-size: clamp(26px, 3.6vw, 38px); line-height: 1; letter-spacing: .03em;
  color: #fff; background: var(--ribbon); padding: 12px 40px 14px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 18px) 50%, 100% 100%, 0 100%, 18px 50%);
}
.ribbon span { font-size: 14px; color: var(--ink-soft); font-weight: 700; }
/* 中身が札より広がらないように。iPhone の音声の再生欄は既定の最小幅を持っていて、
   札の右へ突き抜けていた（2026-10-15）。 */
.panel > * { min-width: 0; }
.panel { background: rgba(255, 255, 255, .94); border-radius: 22px; box-shadow: 0 12px 36px -24px rgba(214, 58, 130, .45); padding: clamp(20px, 4vw, 44px); }

/* ---- 購入・パッチ ---- */
.buy .panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 40px); align-items: center; }
.buy h3 { margin: 0 0 12px; font-family: var(--round); font-size: 18px; }
.stores { --tile: 156px; --tile-h: calc(var(--tile) * 122 / 332); display: grid; grid-template-columns: repeat(3, var(--tile)); gap: 12px; align-items: center; }
.store { display: block; line-height: 0; width: var(--tile); }
/* 任天堂・PlayStation のバッジは 400×154 で、見える札は内側の 332×122（周りは透明） */
.store img.b400 { width: calc(var(--tile) * 400 / 332); max-width: none; margin: calc(var(--tile) * -16 / 332) calc(var(--tile) * -34 / 332); }
.store.ps img { filter: drop-shadow(0 0 1px rgba(58, 42, 63, .45)); }
/* App Store と Google Play のバッジは、札（--tile × --tile-h）の中に縦横比を保ったまま
   収める（object-fit: contain）。高さと最大幅を両方決めると、幅で詰まったときに画像が
   横につぶれる。実際に Google Play のバッジがつぶれていた。
   札の外へはみ出させない。Google Play の余白を見込んで外へ広げたら、隣の App Store に
   重なった（2026-10-15）。 */
.store img.apple, .store img.gplay { width: var(--tile); max-width: none; height: var(--tile-h); object-fit: contain; margin: 0; }
.store.steam { display: flex; align-items: center; justify-content: center; height: calc(var(--tile) * 122 / 332); background: #fff; border-radius: calc(var(--tile) * 5 / 156); filter: drop-shadow(0 0 1px rgba(58, 42, 63, .45)); }
.store.steam img { height: calc(var(--tile) * 26 / 156); width: auto; }
.steam-widget { width: 100%; max-width: 646px; height: 190px; border: 0; display: block; }
.btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 10px 24px;
  font-family: var(--round); font-weight: 800; font-size: 15px; text-decoration: none; border: 0; cursor: pointer;
  border-radius: 99px; color: #fff; background: var(--pink); box-shadow: 0 4px 0 var(--pink-deep);
  transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover { transform: translateY(1px); box-shadow: 0 3px 0 var(--pink-deep); }
.btn.sub { background: #fff; color: var(--pink-deep); box-shadow: 0 0 0 2px var(--pink) inset, 0 4px 0 var(--rose); }

/* ---- キャラクター ---- */
.chara .panel { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(20px, 4vw, 48px); align-items: start; }
.chara-img { border-radius: 18px; overflow: hidden; }
.name { margin: 0; font-family: var(--round); font-weight: 800; font-size: clamp(30px, 3.8vw, 42px); line-height: 1.3; }
.name rt { font-size: 13px; font-weight: 700; color: var(--pink); letter-spacing: .3em; }
.name small { display: block; font-family: var(--jp); font-size: 14px; font-weight: 700; color: var(--ink-soft); letter-spacing: .12em; }
.voices { margin: 18px 0; display: grid; gap: 8px; }
.voices h4, .chara h4 { margin: 0; font-size: 14px; color: var(--pink-deep); letter-spacing: .08em; }
.voice { display: grid; grid-template-columns: 4.5em minmax(0, 1fr); align-items: center; gap: 10px; font-size: 14px; font-weight: 700; }
.voice audio { width: 100%; min-width: 0; max-width: 100%; height: 36px; }
.profile { margin: 0 0 18px; display: flex; flex-wrap: wrap; gap: 6px 10px; font-size: 14px; }
.profile div { display: flex; gap: 6px; background: #fff3f8; border-radius: 99px; padding: 3px 14px; }
.profile dt { color: var(--ink-soft); }
.profile dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.chara .text p { margin: 0 0 12px; }

/* ---- イントロダクション ---- */
.intro-catch { margin: 0 0 24px; font-family: var(--round); font-weight: 800; font-size: clamp(19px, 2.4vw, 26px); line-height: 1.6; color: var(--pink-deep); text-wrap: balance; }
.intro .panel { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(20px, 4vw, 44px); align-items: start; }
.story p { margin: 0 0 14px; }
.story .quote { font-family: var(--round); font-weight: 700; font-size: 17px; color: var(--ink); padding-left: 14px; border-left: 4px solid var(--rose); }
.story .last { font-family: var(--round); font-weight: 800; font-size: 18px; color: var(--pink-deep); margin-top: 20px; }
.intro-side { display: grid; gap: 14px; position: sticky; top: 84px; }
.intro-side img { border-radius: 16px; }
.movie { position: relative; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #000; }
.movie iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cap { margin: -6px 0 0; font-size: 13px; color: var(--ink-soft); }

/* ---- ムービー（Introduction から独立させた） ---- */
.movie-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.movie-item { margin: 0; padding: 10px; background: rgba(255, 255, 255, .94); border-radius: 20px; box-shadow: 0 12px 36px -24px rgba(214, 58, 130, .45); }
.movie-item figcaption { margin: 8px 6px 2px; font-family: var(--round); font-weight: 800; font-size: 15px; color: var(--pink-deep); }
.playlist { margin: 12px 0 0; text-align: right; }

/* ---- ギャラリー ---- */
.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.gallery-grid a { display: block; border-radius: 14px; overflow: hidden; box-shadow: 0 0 0 4px #fff; transition: transform .15s ease; }
.gallery-grid a:hover { transform: translateY(-2px) rotate(-.4deg); }
.gallery-grid img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; }

/* ---- ギャラリーの拡大表示（スライドショー） ---- */
dialog.lightbox { width: 100vw; max-width: 100vw; height: 100vh; max-height: 100vh; margin: 0; padding: 0; border: 0; background: rgba(28, 18, 30, .92); color: #fff; }
dialog.lightbox::backdrop { background: transparent; }
.lightbox figure { margin: 0; height: 100%; display: grid; place-content: center; justify-items: center; gap: 10px; padding: 56px 64px; }
.lb-frame { position: relative; line-height: 0; }
.lb-frame img { max-width: min(1280px, calc(100vw - 128px)); max-height: calc(100vh - 140px); width: auto; height: auto; border-radius: 8px; }
/* 右下に小さく権利表記を重ねる（画像には手を入れない） */
.lb-mark { position: absolute; right: 10px; bottom: 8px; line-height: 1; font-size: clamp(10px, 1.1vw, 13px); font-weight: 700; letter-spacing: .04em; color: rgba(255, 255, 255, .78); text-shadow: 0 0 3px rgba(0, 0, 0, .6); pointer-events: none; user-select: none; }
.lb-count { font-size: 13px; color: rgba(255, 255, 255, .75); font-variant-numeric: tabular-nums; }
.lb-btn, .lb-close { position: absolute; border: 0; cursor: pointer; color: #fff; background: rgba(255, 255, 255, .14); border-radius: 50%; display: grid; place-items: center; }
.lb-btn { top: 50%; transform: translateY(-50%); width: 48px; height: 48px; font-size: 30px; line-height: 1; }
.lb-prev { left: 10px; }
.lb-next { right: 10px; }
.lb-close { top: 12px; right: 12px; width: 42px; height: 42px; font-size: 24px; }
.lb-btn:hover, .lb-close:hover { background: var(--pink); }

/* ---- インフォメーション ---- */
.info-list { margin: 0; display: grid; gap: 0; }
.info-row { display: grid; grid-template-columns: 9em minmax(0, 1fr); gap: 18px; padding-block: 18px; border-bottom: 2px dotted var(--line); }
.info-row:first-child { padding-top: 0; }
.info-row:last-child { border-bottom: 0; padding-bottom: 0; }
.info-row dt { font-family: var(--round); font-weight: 800; color: var(--pink-deep); }
.info-row dd { margin: 0; }
.info-row dd p { margin: 0 0 6px; }
.note { font-size: 13px; color: var(--ink-soft); }
/* 配信先・配信日・価格・スタッフ。1行に「名前 → 値」をのせ、行の間を細い線で区切る。
   名前のすぐ右に値が来るので、どれがどれの値か読める。枠や丸いタグや色の帯は使わない
   （作られた感じが強いと言われた。2026-10-15）。 */
.kv { display: grid; grid-template-columns: 11em minmax(0, 1fr); gap: 2px 16px; align-items: baseline; padding-block: 7px; border-bottom: 1px solid var(--line); }
.kv:last-of-type { border-bottom: 0; }
.kv b { font-size: 14px; }
.kv .vals { display: flex; flex-wrap: wrap; gap: 0 14px; font-variant-numeric: tabular-nums; }
/* 地域のリンクは「／」で区切って並べる */
.kv .links { gap: 0; }
.kv .links span + span::before { content: "／"; margin: 0 .35em; color: var(--ink-soft); }
.kv .links a { font-weight: 700; text-decoration: none; }
.kv .links a:hover { text-decoration: underline; }
.kv small { font-size: 12px; color: var(--ink-soft); }

/* ---- お問い合わせ ---- */
.contact .panel { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.contact p { margin: 0; }

/* ---- 配信ガイドライン（ダイアログ） ---- */
dialog.guide { width: min(760px, 100% - 32px); max-height: 86vh; border: 0; border-radius: 20px; padding: 0; color: var(--ink); background: #fff; }
dialog.guide::backdrop { background: rgba(58, 42, 63, .55); }
.guide-inner { padding: clamp(22px, 4vw, 40px); }
.guide h2 { margin: 0 0 14px; font-family: var(--round); font-size: 22px; color: var(--pink-deep); }
.guide ul { margin: 14px 0; padding-left: 1.3em; }
.guide li { margin-bottom: 8px; }
.guide .close { position: sticky; top: 0; float: right; margin: 12px 12px 0 0; width: 40px; height: 40px; border-radius: 50%; border: 0; background: #fff3f8; color: var(--pink-deep); font-size: 22px; cursor: pointer; }

/* ---- パッチのページ ---- */
.adult { display: inline-block; font-family: var(--round); font-weight: 800; font-size: 13px; letter-spacing: .12em; color: #fff; background: #c8264b; padding: 2px 12px; border-radius: 4px; }
.patch-title { margin: 12px 0 10px; font-family: var(--round); font-weight: 800; font-size: clamp(24px, 3.4vw, 36px); line-height: 1.4; }
.warn { margin: 0 0 16px; padding: 12px 16px; background: #fff0f2; border-left: 4px solid #c8264b; font-weight: 700; }
.patch .lead p { margin: 0 0 8px; }
.patch .lead strong { color: var(--pink-deep); }
.dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px 28px; align-items: center; margin-top: 22px; padding: 22px; background: #fff7fb; border-radius: 16px; }
.file { margin: 0; display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: 2px 12px; font-size: 14px; }
.file dt { color: var(--ink-soft); }
.file dd { margin: 0; font-variant-numeric: tabular-nums; }
.file code { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; font-size: 12.5px; word-break: break-all; }
.patch h3 { margin: 30px 0 12px; font-family: var(--round); font-weight: 800; font-size: 22px; color: var(--pink-deep); }
.cautions { margin: 0; padding-left: 1.3em; }
.cautions li { margin-bottom: 6px; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 22px; }
.steps > li { counter-increment: step; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; }
.steps > li::before { content: counter(step); display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--pink); color: #fff; font-family: var(--round); font-weight: 800; font-size: 20px; }
.steps > li > div > p { margin: 6px 0 10px; font-weight: 700; }
.steps ol { margin: 0 0 12px; padding-left: 1.3em; }
.steps ol li { margin-bottom: 4px; }
.steps figure { margin: 6px 0 0; }
.steps figure img { border-radius: 10px; box-shadow: 0 0 0 1px var(--line); background: #fff; }

/* PlayStation ファミリーマーク。imel.co.jp のフッターと同じ画像（13×10 を 21×16 で表示）。
   マークそのものは変えない（色を変えたり描き直したりしない）。 */
.psmark { display: inline-block; width: 21px; height: 16px; vertical-align: middle; }

/* ---- フッター ---- */
.foot { background: #fff; border-top: 3px solid var(--rose); padding-block: 36px 44px; font-size: 12px; line-height: 1.8; color: var(--ink-soft); }
.foot .wrap { display: grid; gap: 10px; justify-items: center; text-align: center; }
.foot .brand { width: 96px; }
.foot p { margin: 0; }
.foot .copy { font-size: 14px; font-weight: 700; color: var(--ink); }

@media (max-width: 860px) {
  .buy .panel, .chara .panel, .intro .panel { grid-template-columns: 1fr; }
  .intro-side { position: static; }
  /* 420px を上限にしつつ、札の幅を越えない（越えると札の中身が全部右へ突き抜けた） */
  .chara-img { max-width: min(420px, 100%); }
  .info-row { grid-template-columns: 1fr; gap: 6px; }
  .kv { grid-template-columns: 1fr; gap: 0; }
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .movie-grid { grid-template-columns: 1fr; }
  .dl { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .head .wrap { min-height: 56px; padding-block: 8px; }
  .head nav.menu { width: 100%; justify-content: space-between; font-size: 13px; gap: 4px; order: 3; }
  .hero-plat { font-size: 12px; max-width: calc(100vw - 32px); }
  .head .sns { display: none; }
  .stores { --tile: calc((100vw - 32px - 2 * 20px - 12px) / 2); grid-template-columns: repeat(2, var(--tile)); }
  .hero-art { aspect-ratio: 4 / 3; }
  .hero-copy .logo { width: 200px; }
  .ribbon h2 { padding: 10px 30px 12px; }
  .brand-link img:last-child { display: none; }
  .lightbox figure { padding: 56px 8px; }
  .lb-frame img { max-width: calc(100vw - 16px); }
  .lb-btn { top: auto; bottom: 14px; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .gallery-grid a { transition: none; }
}
