.fmp-site .fmp-button:hover { transform:none; }
.fmp-site :is(.fmp-button,.fmp-reservation-link,.fmp-performance-contact-link) span[aria-hidden] { display:inline-block; transition:translate .25s ease; }
.fmp-site :is(.fmp-button,.fmp-reservation-link,.fmp-performance-contact-link):hover span[aria-hidden] { translate:4px 0; }
.fmp-site :is(.fmp-button,.fmp-reservation-link,.fmp-performance-contact-link):active { background:#e6c94f; }

/* An invitation to host the band, between reservations and the closing message. */
.fmp-site .fmp-performance-request {
  position:relative;
  isolation:isolate;
  min-height:650px;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:88px 8% 92px;
  color:#fffdf6;
  background:#5b4a30 url('performance-cafe.jpeg') center 62% / cover no-repeat;
}
.fmp-site .fmp-performance-request::before {
  content:'';
  position:absolute;
  inset:0;
  z-index:-1;
  background:linear-gradient(90deg,rgba(31,25,16,.48) 0%,rgba(31,25,16,.70) 50%,rgba(31,25,16,.48) 100%);
}
.fmp-site .fmp-performance-request > .fmp-performance-content { flex:0 1 660px; width:100%; max-width:660px; margin:0 auto; text-align:center; }
.fmp-site .fmp-performance-request .fmp-eyebrow { color:#fff0b1; font-size:11px; letter-spacing:.16em; margin:0 0 25px; justify-content:center; }
.fmp-site .fmp-performance-request h2 { color:#fffdf6; font-size:clamp(32px,3.6vw,48px); line-height:1.65; letter-spacing:.09em; margin:0; }
.fmp-site .fmp-performance-copy { margin:27px 0 30px; font-size:var(--fmp-body-font-size,15px); line-height:2.05; letter-spacing:.025em; }
.fmp-site .fmp-performance-copy p + p { margin-top:20px; }
.fmp-site .fmp-performance-request .fmp-invite-button { min-width:290px; gap:32px; background:#f7d75c; color:#372d21; border:1px solid #f7d75c; font-size:14px; min-height:58px; }
.fmp-site .fmp-performance-request .fmp-invite-button:hover { background:#ffe58d; border-color:#ffe58d; }
.fmp-site .fmp-performance-caption { color:#fff3da; font-size:12px; line-height:1.9; margin:15px 0 0; }
@media(max-width:700px) {
  .fmp-site .fmp-performance-request { min-height:0; padding:62px 7% 65px; background-position:57% center; }
  .fmp-site .fmp-performance-request::before { background:rgba(31,25,16,.72); }
  .fmp-site .fmp-performance-request .fmp-eyebrow { font-size:10px; letter-spacing:.12em; margin-bottom:22px; }
  .fmp-site .fmp-performance-request h2 { font-size:32px; letter-spacing:.055em; line-height:1.65; }
  .fmp-site .fmp-performance-copy { margin:25px 0 28px; line-height:2; }
  .fmp-site .fmp-performance-request .fmp-invite-button { width:100%; min-width:0; justify-content:center; font-size:14px; padding-inline:25px; }
  .fmp-site .fmp-performance-caption { font-size:11px; margin-top:13px; }
}

/* Selected trio: only the performer groups animate. Both mic stand layers remain fixed. */
.fmp-site .band-stage { position:relative; width:100%; isolation:isolate; }
.fmp-site .band-layers { display:block; width:100%; height:auto; overflow:visible; }
.fmp-site .band-ensemble { transform-box:view-box; transform-origin:50% 90%; }
.fmp-site .microphone-stands { transform:none; animation:none; }
.fmp-site .member { transform-box:view-box; }
.fmp-site .member-bass { transform-origin:19% 92%; animation:bass-rhythm 3.8s ease-in-out infinite; }
.fmp-site .member-vocal { transform-origin:50% 92%; animation:vocal-rhythm 2.6s ease-in-out infinite; animation-delay:-.7s; }
.fmp-site .member-guitar { transform-origin:84% 93%; animation:guitar-rhythm 3.2s ease-in-out infinite; animation-delay:-1.8s; }
.fmp-site .music-notes { position:absolute; inset:0; pointer-events:none; }
.fmp-site .music-note { position:absolute; width:clamp(12px,1.45vw,20px); height:clamp(16px,1.9vw,26px); fill:#000; stroke:#000; stroke-width:2.1; stroke-linecap:round; stroke-linejoin:round; opacity:1; animation:note-rise 7.2s ease-in-out infinite; }
.fmp-site .music-note path { fill:none; }
.fmp-site .note-one { left:34%; top:23%; --drift:-9px; --tilt:-11deg; animation-delay:-1.2s; }
.fmp-site .note-two { left:64%; top:36%; --drift:9px; --tilt:9deg; animation-delay:-4.2s; }
.fmp-site .note-three { left:89%; top:8%; --drift:5px; --tilt:12deg; animation-delay:-6.2s; width:clamp(11px,1.25vw,17px); }
@keyframes bass-rhythm { 0%,100% { transform:rotate(-.85deg); } 50% { transform:rotate(.85deg); } }
@keyframes vocal-rhythm { 0%,100% { transform:translateY(0) rotate(.7deg); } 50% { transform:translateY(-5px) rotate(-.7deg); } }
@keyframes guitar-rhythm { 0%,100% { transform:rotate(-1deg); } 50% { transform:rotate(1deg); } }
@keyframes note-rise {
  0%,8% { transform:translate3d(0,8px,0) rotate(calc(var(--tilt) * -1)) scale(0); }
  20% { transform:translate3d(0,2px,0) rotate(calc(var(--tilt) * -.7)) scale(1); }
  65% { transform:translate3d(var(--drift),-20px,0) rotate(var(--tilt)) scale(1); }
  78%,100% { transform:translate3d(var(--drift),-26px,0) rotate(var(--tilt)) scale(0); }
}

/* Existing monochrome drawings, divided into stationary and moving parts. */
.fmp-site .motion-art { display:block; width:100%; height:auto; overflow:visible; }
.fmp-site .fmp-onair-decoration .motion-art { width:110px; height:56px; }
.fmp-site .steam { animation:coffee-steam 5.8s ease-in-out infinite; transform-box:view-box; transform-origin:50% 36%; }
.fmp-site .steam-b { animation-duration:6.7s; animation-delay:-2.4s; }
@keyframes coffee-steam { 0%,100% { transform:translate(-8px,0) rotate(-1deg); } 50% { transform:translate(12px,-32px) rotate(2deg); } }
.fmp-site .radio-wave { stroke-dasharray:1; stroke-dashoffset:1; animation:radio-signal 4.8s ease-in-out infinite; }
.fmp-site .wave-two { animation-delay:.45s; }
@keyframes radio-signal { 0%,10% { stroke-dashoffset:1; } 30%,66% { stroke-dashoffset:0; } 87%,100% { stroke-dashoffset:-1; } }
.fmp-site .onair-rays path { stroke-dasharray:1; stroke-dashoffset:1; }
.fmp-site .is-played .onair-rays path { animation:air-start 1.6s ease both; }
@keyframes air-start { 0%,12% { stroke-dashoffset:1; } 35%,65% { stroke-dashoffset:0; } 100% { stroke-dashoffset:-1; } }
.fmp-site .is-played .letter-paper { animation:letter-peek 2.3s cubic-bezier(.37,0,.28,1) both; }
@keyframes letter-peek { 0%,100% { transform:translateY(0); } 42%,64% { transform:translateY(-95px); } }
.fmp-site .ticket-back,.fmp-site .ticket-front { transform-box:view-box; transform-origin:45% 75%; }
.fmp-site .is-played .ticket-back { animation:ticket-open-back 2.2s ease both; }
.fmp-site .is-played .ticket-front { animation:ticket-open-front 2.2s ease both; }
@keyframes ticket-open-back { 0%,100% { transform:rotate(0); } 45%,65% { transform:rotate(-6deg) translateY(-15px); } }
@keyframes ticket-open-front { 0%,100% { transform:rotate(0); } 45%,65% { transform:rotate(2.5deg); } }

/* Reveal each heading/card once, preserving the ticket cards' existing rotation. */
.fmp-site.motion-ready .motion-reveal { opacity:0; translate:0 15px; transition:opacity .7s ease,translate .7s cubic-bezier(.22,.61,.36,1); transition-delay:var(--reveal-delay,0ms); }
.fmp-site.motion-ready .motion-reveal.is-revealed { opacity:1; translate:0 0; }
.fmp-site [data-motion-visible=false] :is(.member,.music-note,.steam,.radio-wave,.letter-paper,.ticket-back,.ticket-front,.onair-rays path,.fm-radio-scroll__wave) { animation-play-state:paused; }
.fmp-site.motion-paused :is(.member,.music-note,.steam,.radio-wave,.letter-paper,.ticket-back,.ticket-front,.onair-rays path,.fm-radio-scroll__wave) { animation-play-state:paused!important; }
.fmp-site.motion-paused .motion-reveal,.fmp-site.motion-reduced .motion-reveal { opacity:1!important; translate:none!important; transition:none!important; }
.fmp-site.motion-reduced :is(.member,.music-note,.steam,.radio-wave,.letter-paper,.ticket-back,.ticket-front,.onair-rays path,.fm-radio-scroll__wave) { animation:none!important; }
.fmp-site.motion-reduced .music-notes { display:none; }
.fmp-site.motion-reduced .radio-wave { stroke-dashoffset:0; }
@media(prefers-reduced-motion:reduce) {
 .fmp-site.motion-ready .motion-reveal { opacity:1; translate:none; transition:none; }
 .fmp-site :is(.member,.music-note,.steam,.radio-wave,.letter-paper,.ticket-back,.ticket-front,.onair-rays path,.fm-radio-scroll__wave) { animation:none!important; }
 .fmp-site .music-notes { display:none; }
 .fmp-site .radio-wave { stroke-dashoffset:0; }
}

/* Live-card actions retain their existing dimensions and anchor destinations. */
.fmp-site .fmp-live-ticket .fmp-reservation-link { text-decoration:none; }
.fmp-site .fmp-live-ticket .fmp-button[href="#letter-form"] { gap:18px; }
@media(max-width:700px) {
 .fmp-site .fmp-onair-decoration .motion-art { width:86px; height:44px; }
}
@media(prefers-reduced-motion:reduce) {
 .fmp-site :is(.fmp-button,.fmp-reservation-link,.fmp-performance-contact-link) span[aria-hidden] { transition:none; }
}
@media print {
 .fmp-site .motion-reveal { opacity:1!important; translate:none!important; }
}


/* ヒーローのロゴ（インラインSVG）と電波のアニメーション */
.hero-logo .fmp-logo { display: block; width: 100%; max-width: 600px; height: auto; overflow: visible; }

.fmp-logo .fmp-logo__ghost { opacity: 0; }
.fmp-logo .fmp-logo__dot   { animation: fmpLogoDot 0.5s ease-out 0.4s both; }
.fmp-logo .fmp-logo__arc--1 { animation: fmpLogoArc 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) 0.6s both; }
.fmp-logo .fmp-logo__arc--2 { animation: fmpLogoArc 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) 0.82s both; }
.fmp-logo .fmp-logo__ghost { animation: fmpLogoGhost 0.9s ease-out 1.15s forwards; }

@keyframes fmpLogoDot   { 0% { transform: scale(1); } 45% { transform: scale(1.4); } 100% { transform: scale(1); } }
@keyframes fmpLogoArc   { 0% { opacity: 0; transform: scale(0.4); } 100% { opacity: 1; transform: scale(1); } }
@keyframes fmpLogoGhost { 0% { opacity: 0.6; transform: scale(1); } 100% { opacity: 0; transform: scale(1.6); } }

/* 動きを減らす設定の人には動かさない（電波は最初から表示） */
@media (prefers-reduced-motion: reduce) {
  .fmp-logo .fmp-logo__dot, .fmp-logo .fmp-logo__arc, .fmp-logo .fmp-logo__ghost { animation: none; }
}

/* 送信後の受け取り画面（お便りフォーム・予約フォーム共通）
   カード（#letter-form / #reservation-form）の中で、フォームと入れ替わる。 */
.fmp-thanks { display: none; }
.fmp-thanks-host.is-sent > .wpcf7 { display: none; }
.fmp-thanks-host.is-sent > .fmp-picked-note { display: none; }
.fmp-thanks-host.is-sent > .fmp-thanks { display: flex; }

.fmp-thanks {
  --fmp-thanks-yellow: #F7D75C;
  --fmp-thanks-ink: #372D21;
  --fmp-thanks-cream: #FFFDF6;
  flex-direction: column; align-items: center; text-align: center;
  padding: 20px 0 8px;
  color: var(--fmp-thanks-ink);
  outline: none;
}
.fmp-thanks, .fmp-thanks * { box-sizing: border-box; }
.fmp-thanks p { margin: 0; padding: 0; }
.fmp-thanks [hidden] { display: none !important; }

.fmp-thanks .fmp-thanks__lamp { display: flex; align-items: center; gap: 8px; height: 30px; padding: 0 14px; border-radius: 15px; background: var(--fmp-thanks-ink); color: var(--fmp-thanks-yellow); font-size: 11px; font-weight: 500; line-height: 1; letter-spacing: 0.24em; }
.fmp-thanks .fmp-thanks__lamp::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.fmp-thanks .fmp-thanks__icon { display: block; width: 112px; height: auto; margin-top: 24px; overflow: visible; fill: none; stroke: currentColor; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.fmp-thanks .fmp-thanks__icon .fmp-thanks__fill { fill: var(--fmp-thanks-yellow); }
.fmp-thanks .fmp-thanks__icon circle { fill: currentColor; stroke: none; }
.fmp-thanks .fmp-thanks__icon .fmp-thanks__thin { stroke-width: 2.6; }
.fmp-thanks .fmp-thanks__icon .fmp-thanks__dots { stroke-width: 2.4; stroke-dasharray: 0.1 6; }
.fmp-thanks .fmp-thanks__arc { stroke-width: 3; }

.fmp-thanks .fmp-thanks__title { margin-top: 20px; font-size: 28px; font-weight: 700; line-height: 1.5; letter-spacing: 0.08em; }
.fmp-thanks .fmp-thanks__text { margin-top: 6px; font-size: 16px; font-weight: 400; line-height: 1.9; letter-spacing: 0.1em; }

/* 予約内容の確認（予約フォームのみ） */
.fmp-thanks .fmp-thanks__summary { display: flex; flex-direction: column; gap: 8px; width: 100%; margin-top: 20px; padding: 16px 22px; border-radius: 8px; background: #F6EFD6; text-align: left; }
.fmp-thanks .fmp-thanks__row { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 14px; align-items: baseline; }
.fmp-thanks .fmp-thanks__key { font-size: 12px; font-weight: 500; letter-spacing: 0.2em; }
.fmp-thanks .fmp-thanks__val { font-size: 15px; font-weight: 500; line-height: 1.6; letter-spacing: 0.04em; overflow-wrap: anywhere; }

.fmp-thanks .fmp-thanks__dial { position: relative; width: 242px; max-width: 100%; height: 34px; margin-top: 24px;
  background:
    repeating-linear-gradient(to right, currentColor 0 2px, transparent 2px 60px) 0 0 / 100% 18px no-repeat,
    repeating-linear-gradient(to right, currentColor 0 2px, transparent 2px 12px) 0 0 / 100% 10px no-repeat; }
.fmp-thanks .fmp-thanks__needle { position: absolute; top: 0; left: calc(100% - 1px); width: 4px; height: 28px; margin-left: -2px; border-radius: 2px; background: currentColor; }
.fmp-thanks .fmp-thanks__needle::after { content: ""; position: absolute; left: -3px; top: 24px; width: 10px; height: 10px; border-radius: 50%; background: currentColor; }

.fmp-thanks .fmp-thanks__cta { display: flex; align-items: center; justify-content: center; gap: 14px; width: 360px; max-width: 100%; height: 56px; margin-top: 36px; border-radius: 28px; background: var(--fmp-thanks-ink); color: var(--fmp-thanks-cream); font-size: 15px; font-weight: 500; letter-spacing: 0.12em; text-decoration: none; }
.fmp-thanks .fmp-thanks__cta:hover { opacity: 0.85; text-decoration: none; }
.fmp-thanks .fmp-thanks__cta svg { width: 18px; height: 18px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fmp-thanks .fmp-thanks__again { height: 44px; margin: 6px 0 0; padding: 0 16px; border: 0; background: transparent; color: inherit; font: inherit; font-size: 13px; font-weight: 500; letter-spacing: 0.1em; text-decoration: underline; text-underline-offset: 5px; cursor: pointer; }
.fmp-thanks .fmp-thanks__cta:focus-visible, .fmp-thanks .fmp-thanks__again:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

/* 表示された瞬間に1回だけ再生する動き */
.fmp-thanks-host.is-sent .fmp-thanks { animation: fmpThanksFade 0.5s ease both; }
.fmp-thanks-host.is-sent .fmp-thanks__lamp { animation: fmpThanksLamp 0.9s ease-out 0.3s both; }
.fmp-thanks-host.is-sent .fmp-thanks__arc--1 { animation: fmpThanksArc 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) 0.7s both; }
.fmp-thanks-host.is-sent .fmp-thanks__arc--2 { animation: fmpThanksArc 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) 0.92s both; }
.fmp-thanks-host.is-sent .fmp-thanks__title { animation: fmpThanksRise 0.6s ease-out 0.45s both; }
.fmp-thanks-host.is-sent .fmp-thanks__text { animation: fmpThanksRise 0.6s ease-out 0.6s both; }
.fmp-thanks-host.is-sent .fmp-thanks__summary { animation: fmpThanksRise 0.6s ease-out 0.75s both; }
.fmp-thanks-host.is-sent .fmp-thanks__needle { animation: fmpThanksNeedle 1.3s cubic-bezier(0.2, 0.8, 0.2, 1) 0.5s both; }

@keyframes fmpThanksFade   { from { opacity: 0; } to { opacity: 1; } }
@keyframes fmpThanksLamp   { 0% { opacity: 0.25; } 60% { opacity: 1; } 75% { opacity: 0.55; } 100% { opacity: 1; } }
@keyframes fmpThanksArc    { 0% { opacity: 0; transform: scale(0.4); } 100% { opacity: 1; transform: scale(1); } }
@keyframes fmpThanksRise   { 0% { opacity: 0; transform: translateY(14px); } 100% { opacity: 1; transform: translateY(0); } }
@keyframes fmpThanksNeedle { from { left: 1px; } to { left: calc(100% - 1px); } }

@media (max-width: 700px) {
  .fmp-thanks { padding: 8px 0 0; }
  .fmp-thanks .fmp-thanks__icon { width: 96px; margin-top: 22px; }
  .fmp-thanks .fmp-thanks__title { font-size: 22px; }
  .fmp-thanks .fmp-thanks__text { font-size: 15px; }
  .fmp-thanks .fmp-thanks__summary { padding: 14px 16px; }
  .fmp-thanks .fmp-thanks__row { grid-template-columns: 48px minmax(0, 1fr); gap: 10px; }
  .fmp-thanks .fmp-thanks__val { font-size: 14px; }
  .fmp-thanks .fmp-thanks__dial { width: 202px; background-image:
    repeating-linear-gradient(to right, currentColor 0 2px, transparent 2px 50px),
    repeating-linear-gradient(to right, currentColor 0 2px, transparent 2px 10px); }
  .fmp-thanks .fmp-thanks__cta { margin-top: 30px; font-size: 14px; letter-spacing: 0.08em; }
}

@media (prefers-reduced-motion: reduce) {
  .fmp-thanks-host.is-sent .fmp-thanks, .fmp-thanks-host.is-sent .fmp-thanks * { animation: none !important; }
}

/* Match the live image sizing rules and preserve the existing h1 offset. */
@media (max-width: 767px) { .fmp-site .hero-logo .fmp-logo { width: 100%; } }
/* Explicit local SVG origin keeps every wave centered on its adjacent dot. */
.fmp-logo :is(.fmp-logo__dot,.fmp-logo__arc,.fmp-logo__ghost),
.fmp-thanks .fmp-thanks__arc { transform-origin: 0 0; }
/* The live card's heading is a sibling of the CF7 form. Restore it on retry. */
.fmp-thanks-host.is-sent > :not(.fmp-thanks) { display: none; }
/* SWELL's universal font-size reset overrides SVG presentation attributes. */
.hero-logo .fmp-logo > g { font-family: "DM Sans", sans-serif; font-size: 24px; }

/* PCのメニュー（幅1001px以上のみ。ヒーローを過ぎたら上から降りてくる） */
.fmp-header { display: none; }

@media (min-width: 960px) {
  .fmp-header {
    position: fixed; left: 0; right: 0; top: 0; z-index: 100;
    display: flex; align-items: center; justify-content: space-between;
    box-sizing: border-box; height: 76px; padding: 0 40px;
    border-bottom: 1px solid #372D21; background: #FFFDF6; color: #372D21;
    font-family: "DM Sans", "Zen Kaku Gothic New", sans-serif; font-weight: 500;
    transform: translateY(-105%); visibility: hidden;
    transition: transform 0.4s ease, visibility 0s linear 0.4s;
  }
  .fmp-header.is-visible { transform: translateY(0); visibility: visible; transition: transform 0.4s ease, visibility 0s; }
  body.admin-bar .fmp-header { top: 32px; }

  /* 下の縁：ラジオのダイヤル目盛り */
  .fmp-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 7px; opacity: 0.4; pointer-events: none;
    background: repeating-linear-gradient(to right, #372D21 0 1px, transparent 1px 12px); }

  .fmp-header a { color: inherit; text-decoration: none; }
  .fmp-header .fmp-header__logo { display: flex; align-items: center; height: 44px; }
  .fmp-header .fmp-header__logo svg { display: block; width: 148px; height: auto; }

  .fmp-header .fmp-header__nav { display: flex; align-items: center; gap: 26px; height: 100%; }
  .fmp-header .fmp-header__link { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; height: 100%; white-space: nowrap; }
  .fmp-header .fmp-header__en { font-size: 11.5px; line-height: 1; letter-spacing: 0.12em; }
  .fmp-header .fmp-header__ja { font-size: 10px; line-height: 1; letter-spacing: 0.06em; color: #5A4E40; }
  .fmp-header .fmp-header__link:hover .fmp-header__en { opacity: 0.6; }

  /* 表示中のセクションの項目に、針を立てる */
  .fmp-header .fmp-header__link::before,
  .fmp-header .fmp-header__link::after { content: ""; position: absolute; left: 50%; background: #372D21; opacity: 0; transition: opacity 0.3s ease; z-index: 1; }
  .fmp-header .fmp-header__link::before { bottom: 0; width: 3px; height: 12px; margin-left: -1.5px; border-radius: 2px 2px 0 0; }
  .fmp-header .fmp-header__link::after  { bottom: 10px; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; }
  .fmp-header .fmp-header__link.is-active::before,
  .fmp-header .fmp-header__link.is-active::after { opacity: 1; }

  .fmp-header .fmp-header__btn { display: flex; align-items: center; justify-content: center; gap: 10px; height: 40px; padding: 0 20px; border-radius: 20px; background: #372D21; color: #FFFDF6; font-size: 13px; line-height: 1; letter-spacing: 0.08em; white-space: nowrap; }
  .fmp-header .fmp-header__btn:hover { opacity: 0.85; }
  .fmp-header .fmp-header__btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  .fmp-header a:focus-visible { outline: 2px solid #372D21; outline-offset: 3px; }

  /* メニューから移動したとき、見出しがメニューの下に隠れないようにする */
  #about, #live, #letters, #reservation, #performance-contact, #letter-form, #reservation-form { scroll-margin-top: 92px; }
}

/* 幅が狭めのPCでは間隔を詰める */
@media (min-width: 960px) and (max-width: 1140px) {
  .fmp-header { padding: 0 24px; }
  .fmp-header .fmp-header__logo svg { width: 128px; }
  .fmp-header .fmp-header__nav { gap: 16px; }
  .fmp-header .fmp-header__btn { padding: 0 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .fmp-header, .fmp-header.is-visible { transition: none; }
}

/* This site's custom body omits WordPress's admin-bar class. */
@media (min-width: 960px) {
  body:has(> #wpadminbar) .fmp-header { top: 32px; }
  body:has(> #wpadminbar) :is(#about,#live,#letters,#reservation,#performance-contact,#letter-form,#reservation-form) { scroll-margin-top: 124px; }
}

/* 予約フォームの「ご予約人数」を − 2名 ＋ の形式にする
   JS（stepper.js）が元の入力欄を包んで .fmp-stepper を作る。JSが動かないときは元の数字入力欄のまま。 */
.fmp-stepper {
  --fmp-stepper-h: 61px;                 /* ほかの入力欄と同じ高さ */
  --fmp-stepper-border: 1px solid #B4AC9B; /* ほかの入力欄と同じ枠線 */
  --fmp-stepper-radius: 5px;             /* ほかの入力欄と同じ角丸 */
  --fmp-stepper-w: 320px;                /* PCでの最大幅 */
  position: relative;
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; max-width: var(--fmp-stepper-w); height: var(--fmp-stepper-h);
  margin-top: 9px; padding: 0 4px;
  box-sizing: border-box;
  border: var(--fmp-stepper-border); border-radius: var(--fmp-stepper-radius);
  background: #FFFFFF; color: #372D21;
  font-weight: 400; line-height: 1;
}
.fmp-stepper *, .fmp-stepper *::before, .fmp-stepper *::after { box-sizing: border-box; }

/* 元の入力欄は見えなくするが、送信・キーボード操作・読み上げのために残す */
.fmp-stepper input.fmp-stepper__input {
  position: absolute !important; left: 0 !important; top: 0 !important;
  width: 1px !important; height: 1px !important; min-height: 0 !important;
  margin: 0 !important; padding: 0 !important; border: 0 !important;
  opacity: 0 !important; pointer-events: none !important;
  -moz-appearance: textfield; appearance: textfield;
}

.fmp-stepper .fmp-stepper__btn {
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  width: 56px; height: calc(100% - 8px); min-height: 44px;
  min-width: 0; margin: 0; padding: 0; border: 0; border-radius: 3px;
  background: transparent; color: inherit; box-shadow: none;
  -webkit-appearance: none; appearance: none;
  cursor: pointer; -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s ease, opacity 0.15s ease;
}
.fmp-stepper .fmp-stepper__btn svg { display: block; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.fmp-stepper .fmp-stepper__btn:hover { background: #F6EFD6; }
.fmp-stepper .fmp-stepper__btn:active { background: #F0E3B0; }
.fmp-stepper .fmp-stepper__btn:disabled { opacity: 0.28; cursor: default; background: transparent; }
.fmp-stepper .fmp-stepper__btn:focus-visible { outline: 2px solid #372D21; outline-offset: -2px; }

.fmp-stepper .fmp-stepper__value {
  flex: 1 1 auto; min-width: 0;
  display: flex; align-items: baseline; justify-content: center; gap: 1px;
  font-size: 18px; font-weight: 500; letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
  border-radius: 4px;
}
/* キーボードで元の入力欄にフォーカスしたときの印（↑↓キーで増減できる） */
.fmp-stepper:has(.fmp-stepper__input:focus-visible) { outline: 2px solid #372D21; outline-offset: 2px; }
@supports not selector(:has(*)) {
  .fmp-stepper .fmp-stepper__input:focus-visible ~ .fmp-stepper__value { text-decoration: underline; text-underline-offset: 6px; }
}

@media (max-width: 700px) {
  .fmp-stepper { max-width: none; }
}

/* Keep the number from inheriting the theme's small form-span styling. */
#reservation-form .fmp-stepper .fmp-stepper__num { font-size: inherit; font-weight: inherit; line-height: inherit; }

/* 送信ボタンに、送信後の画面と同じアイコンを小さく付ける
   （お便り＝封筒、予約＝チケット。どちらも右上に電波）
   文字はボタンの左右の中心。アイコンは文字の右隣に置き、中心の計算には入れない。 */
.fmp-submit {
  --fmp-submit-icon-w: 30px;    /* アイコンの幅 */
  --fmp-submit-icon-h: 25px;    /* アイコンの高さ（幅の約 0.82 倍） */
  --fmp-submit-gap: 10px;       /* 文字とアイコンの間 */
  --fmp-submit-icon-lift: 3px;  /* アイコンを上へずらす量。封筒・チケット本体の中心が文字の中心に揃う値 */
}
.fmp-submit--letter { --fmp-submit-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -14 88 72' fill='none' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='14' width='54' height='38' rx='6' fill='%23F7D75C'/%3E%3Cpath d='M10 22L31 36.5L52 22' stroke='%23372D21' stroke-width='4.2'/%3E%3Ccircle cx='62' cy='9' r='4.2' fill='%23FFFDF6'/%3E%3Cpath d='M63.7 -0.8A10 10 0 0 1 71.8 7.3M65 -7.7A17 17 0 0 1 78.7 6' stroke='%23FFFDF6' stroke-width='4.2'/%3E%3C/svg%3E"); }
.fmp-submit--reserve { --fmp-submit-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -14 88 72' fill='none' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 14H53A5 5 0 0 1 58 19V27A6 6 0 0 0 58 39V47A5 5 0 0 1 53 52H9A5 5 0 0 1 4 47V39A6 6 0 0 0 4 27V19A5 5 0 0 1 9 14Z' fill='%23F7D75C'/%3E%3Cpath d='M42 21V45' stroke='%23372D21' stroke-width='3.2' stroke-dasharray='0.1 6.2'/%3E%3Cpath d='M15 28H32M15 38H27' stroke='%23372D21' stroke-width='4.2'/%3E%3Ccircle cx='62' cy='9' r='4.2' fill='%23FFFDF6'/%3E%3Cpath d='M63.7 -0.8A10 10 0 0 1 71.8 7.3M65 -7.7A17 17 0 0 1 78.7 6' stroke='%23FFFDF6' stroke-width='4.2'/%3E%3C/svg%3E"); }

/* A：<button> で出している場合（推奨） */
:is(#letter-form, #reservation-form) button.fmp-submit {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 61px; margin: 0; padding: 0 24px;
  border: 0; border-radius: 40px;
  background: #372D21; color: #FFFDF6;
  font: inherit; font-size: 16px; font-weight: 400; line-height: 1; letter-spacing: normal;
  cursor: pointer; -webkit-appearance: none; appearance: none;
  transition: opacity 0.2s ease;
}
:is(#letter-form, #reservation-form) button.fmp-submit::before { content: none; } /* 左側に出していた以前のアイコンは使わない */
:is(#letter-form, #reservation-form) button.fmp-submit::after {
  content: ""; flex-shrink: 0;
  width: var(--fmp-submit-icon-w); height: var(--fmp-submit-icon-h);
  /* 左の余白＝文字との間。右の余白をマイナスにして自分の幅を打ち消し、文字だけが中央に来るようにする */
  margin: 0 calc(-1 * (var(--fmp-submit-icon-w) + var(--fmp-submit-gap))) 0 var(--fmp-submit-gap);
  transform: translateY(calc(-1 * var(--fmp-submit-icon-lift)));
  background: var(--fmp-submit-icon) center / contain no-repeat;
}
:is(#letter-form, #reservation-form) button.fmp-submit:hover { opacity: 0.85; }
:is(#letter-form, #reservation-form) button.fmp-submit:focus-visible { outline: 2px solid #372D21; outline-offset: 3px; }
:is(#letter-form, #reservation-form) button.fmp-submit:disabled { opacity: 0.5; cursor: default; }

/* B：<input type="submit"> のままの場合の代替。文字幅を前提に位置を決めるので、文言を変えたら --fmp-submit-text-w も直す */
input.fmp-submit {
  --fmp-submit-text-w: 96px; /* 「お便りを送る」＝16px × 6文字 */
  padding-left: 0; padding-right: 0; /* 文字を中央に */
  background-image: var(--fmp-submit-icon);
  background-repeat: no-repeat;
  background-size: var(--fmp-submit-icon-w) var(--fmp-submit-icon-h);
  background-position:
    left calc(50% + var(--fmp-submit-icon-w) / 2 + var(--fmp-submit-text-w) / 2 + var(--fmp-submit-gap))
    top calc(50% - var(--fmp-submit-icon-lift));
}
input.fmp-submit.fmp-submit--reserve { --fmp-submit-text-w: 64px; /* 「予約する」＝16px × 4文字 */ }

/* SP: the three letter steps enter from the right with a gentler stagger. */
@media (max-width: 700px) {
 .fmp-site.motion-ready .fmp-letter-process > article.motion-reveal { translate: 20px 0; }
 .fmp-site.motion-ready .fmp-letter-process > article.motion-reveal.is-revealed { translate: 0 0; }
 .fmp-site.motion-ready .fmp-letter-process > article.motion-reveal:nth-of-type(1) { transition-delay: 0ms; }
 .fmp-site.motion-ready .fmp-letter-process > article.motion-reveal:nth-of-type(2) { transition-delay: 360ms; }
 .fmp-site.motion-ready .fmp-letter-process > article.motion-reveal:nth-of-type(3) { transition-delay: 720ms; }
}

/* ① トップのロゴと「あなたの想い出の〜」の間を 15px 広げる（26→41px／700px以下 22→37px） */
.fmp-site .fmp-hero-description { margin-top: 41px; }
@media (max-width: 700px) {
  .fmp-site .fmp-hero-description { margin-top: 37px; }
}
