/* ============================================================
   MOTOHOUSE お問い合わせ 共通CSS  contact.css
   ============================================================ */

:root {
  --black:     #111111;
  --yellow:    #fcee21;
  --white:     #ffffff;
  --gray-bg:   #f6f6f6;
  --gray-line: #e4e4e4;
  --gray-mid:  #cccccc;
  --gray-text: #666666;
  --red:       #e53935;
  --radius:    4px;
  --shadow:    0 2px 16px rgba(0,0,0,.08);
  --header-h:  60px;
  --inner-w:   1100px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; font-family: "ヒラギノ角ゴ Pro W3","Hiragino Kaku Gothic Pro","メイリオ",Meiryo,sans-serif; }
body { padding-top: var(--header-h); }
img  { max-width: 100%; height: auto; display: block; }
a    { color: inherit; text-decoration: none; }

/* 既存CSS固定幅を上書き */
#allwrapperblock, #scrollblock, #scrollwrapperblock,
#contentsblock, #contentswrapperblock, .contentswidth, .contentsbody {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  overflow-x: hidden !important;
  box-sizing: border-box !important;
}
#contentswrapperblock {
  max-width: var(--inner-w) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 24px !important;
  padding-right: 24px !important;
}

/* ---- HEADER ---- */
#headerblock {
  position: fixed; top: 0; left: 0;
  width: 100%; height: var(--header-h);
  background: var(--black);
  z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px;
}
.header-logo { display: flex; align-items: center; flex-shrink: 0; }
.header-logo img { height: 36px; width: auto; }

.header-nav { display: flex; align-items: center; }
.header-nav > ul { display: flex; list-style: none; margin: 0; padding: 0; }
.header-nav > ul > li { position: relative; }
.header-nav > ul > li > a {
  display: block; padding: 0 13px; line-height: var(--header-h);
  font-size: 13px; color: #bbb; white-space: nowrap; transition: color .2s;
}
.header-nav > ul > li:hover > a,
.header-nav > ul > li.current > a { color: var(--yellow); }

.header-nav > ul > li > ul {
  display: none; position: absolute; top: var(--header-h); left: 0;
  min-width: 230px; background: rgba(17,17,17,.97);
  list-style: none; margin: 0; padding: 0;
  border-top: 2px solid var(--yellow);
  box-shadow: 0 8px 24px rgba(0,0,0,.3); z-index: 1001;
}
.header-nav > ul > li:hover > ul { display: block; }
.header-nav > ul > li > ul > li > a {
  display: block; padding: 11px 18px; font-size: 12px; color: #bbb;
  border-bottom: 1px solid rgba(255,255,255,.06); transition: color .2s, background .2s;
}
.header-nav > ul > li > ul > li > a:hover { color: var(--yellow); background: rgba(255,255,255,.05); }

.hamburger {
  display: none; flex-direction: column; justify-content: center; align-items: center;
  gap: 5px; width: 44px; height: 44px; background: none; border: none;
  cursor: pointer; padding: 10px; flex-shrink: 0;
}
.hamburger span {
  display: block; width: 22px; height: 2px; background: var(--white);
  border-radius: 2px; transition: transform .3s, opacity .3s;
}
.hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* SPドロワー：visibility で完全に制御（pointer-eventsだけでは不十分） */
.sp-nav-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 998;
  opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s;
}
.sp-nav-overlay.is-open { opacity: 1; visibility: visible; }

.sp-nav {
  position: fixed; top: var(--header-h); left: 0;
  width: 100%; max-height: calc(100vh - var(--header-h));
  overflow-y: auto; background: var(--black); z-index: 999;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity .3s, visibility .3s, transform .3s;
  pointer-events: none;
}
.sp-nav.is-open { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }

.sp-nav__list { list-style: none; margin: 0; padding: 0; }
.sp-nav__list > li > a,
.sp-nav__list > li > .sp-nav__parent {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 20px; font-size: 14px; font-weight: 700; color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,.08); cursor: pointer;
}
.sp-nav__list > li > .sp-nav__parent .arrow {
  width: 10px; height: 10px;
  border-right: 2px solid #888; border-bottom: 2px solid #888;
  transform: rotate(45deg); transition: transform .3s;
}
.sp-nav__list > li.is-open > .sp-nav__parent .arrow { transform: rotate(-135deg); }
.sp-nav__sub { display: none; background: rgba(255,255,255,.04); list-style: none; margin: 0; padding: 0; }
.sp-nav__sub.is-open { display: block; }
.sp-nav__sub li a {
  display: block; padding: 12px 20px 12px 36px; font-size: 13px; color: #aaa;
  border-bottom: 1px solid rgba(255,255,255,.04);
}
.sp-nav__tel { padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.sp-nav__tel a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--yellow); color: var(--black); font-weight: 700;
  font-size: 15px; padding: 14px 20px; border-radius: var(--radius);
}

/* ---- MAIN IMAGE ---- */
#mainimageblock { width: 100%; overflow: hidden; height: 170px; }
#mainimageblock img { width: 100%; height: 170px; object-fit: cover; }

/* ---- CONTENTS ---- */
#contentsblock { background: var(--gray-bg); padding: 0 0 60px; }
#contentsheaderblock { padding: 32px 0 20px; border-bottom: 1px solid var(--gray-line); margin-bottom: 36px; }
#contentsheaderblock h1 { font-size: 26px; font-weight: 700; color: var(--black); margin: 0 0 10px; padding: 0; }
.posmenu ul { display: flex; flex-wrap: wrap; list-style: none; margin: 0; padding: 0; font-size: 12px; color: var(--gray-text); }
.posmenu ul li + li::before { content: "›"; margin: 0 6px; }
.posmenu ul li a { color: var(--gray-text); text-decoration: underline; }

/* ---- STEPS ---- */
.contact-steps { display: flex; justify-content: center; align-items: flex-start; margin: 0 auto 40px; max-width: 440px; }
.contact-steps__item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 7px; position: relative; }
.contact-steps__item:not(:last-child)::after {
  content: ""; position: absolute; top: 17px; left: calc(50% + 20px);
  width: calc(100% - 40px); height: 2px; background: var(--gray-line);
}
.contact-steps__item.done:not(:last-child)::after,
.contact-steps__item.active:not(:last-child)::after { background: var(--yellow); }
.contact-steps__circle {
  width: 36px; height: 36px; border-radius: 50%; background: var(--gray-line); color: #aaa;
  display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; z-index: 1;
}
.contact-steps__item.done   .contact-steps__circle { background: var(--yellow); color: var(--black); }
.contact-steps__item.active .contact-steps__circle { background: var(--black); color: var(--yellow); box-shadow: 0 0 0 4px var(--yellow); }
.contact-steps__label { font-size: 11px; color: #aaa; white-space: nowrap; }
.contact-steps__item.done   .contact-steps__label { color: #777; }
.contact-steps__item.active .contact-steps__label { color: var(--black); font-weight: 700; }

/* ---- FORM ---- */
.contact-form-wrap { background: var(--white); border: 1px solid var(--gray-line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.form-section-heading { display: flex; align-items: center; background: var(--black); color: var(--white); font-size: 14px; font-weight: 700; padding: 12px 20px; margin: 0; border-left: 4px solid var(--yellow); letter-spacing: .06em; }

.form-table { width: 100%; border-collapse: collapse; }
.form-table tr { border-bottom: 1px solid var(--gray-line); }
.form-table tr:last-child { border-bottom: none; }
.form-table th { width: 200px; padding: 16px 20px; background: var(--gray-bg); font-size: 13px; font-weight: 700; color: #444; text-align: left; vertical-align: top; border-right: 1px solid var(--gray-line); line-height: 1.6; }
.form-table td { padding: 14px 20px; font-size: 14px; color: #333; vertical-align: top; line-height: 1.7; }

.must { display: inline-block; background: #e53935 !important; color: #fff !important; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 2px; margin-left: 6px; vertical-align: middle; }

.form-table input[type="text"],
.form-table input[type="email"],
.form-table select,
.form-textarea {
  font-size: 14px; color: #333; background: var(--white); border: 1px solid var(--gray-mid);
  border-radius: 3px; padding: 9px 12px; width: 100%; max-width: 420px;
  transition: border-color .2s, box-shadow .2s; font-family: inherit;
  pointer-events: auto; touch-action: auto; -webkit-appearance: none;
}
.form-table input[type="text"]:focus,
.form-table input[type="email"]:focus,
.form-table select:focus,
.form-textarea:focus { outline: none; border-color: var(--black); box-shadow: 0 0 0 3px rgba(252,238,33,.35); }
.form-textarea { max-width: 100%; resize: vertical; min-height: 150px; line-height: 1.8; }
.age-select { max-width: 120px; width: auto; }

.sub-label { display: block; font-size: 11px; color: #999; margin: 8px 0 3px; }
.sub-label:first-child { margin-top: 0; }
.zip-link { display: inline-block; margin-left: 10px; font-size: 12px; color: #555; text-decoration: underline; }

.checkbox-group { display: flex; flex-wrap: wrap; gap: 8px 10px; }
.checkbox-group label {
  display: flex; align-items: center; gap: 6px; font-size: 13px; color: #333; cursor: pointer;
  padding: 7px 14px; border: 1px solid var(--gray-line); border-radius: 3px; background: var(--white);
  transition: border-color .15s, background .15s; user-select: none;
  pointer-events: auto; touch-action: auto;
}
.checkbox-group label:hover { border-color: var(--black); background: #f9f9f9; }
.checkbox-group input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--black); flex-shrink: 0; cursor: pointer; }

.textarea-section { padding: 20px; border-bottom: 1px solid var(--gray-line); }
.textarea-section h3 { font-size: 14px !important; font-weight: 700 !important; color: var(--black) !important; margin: 0 0 12px !important; padding-left: 10px; border-left: 3px solid var(--yellow); }
.mail-notice { padding: 20px; background: var(--gray-bg); border-bottom: 1px solid var(--gray-line); font-size: 13px; color: var(--gray-text); line-height: 1.9; }
.mail-notice p { margin: 0 0 10px; }
.mail-notice p:last-child { margin-bottom: 0; }
.mail-notice strong { color: var(--black); font-weight: 700; }

.privacy-section { padding: 20px; border-bottom: 1px solid var(--gray-line); }
.privacy-section h4 { font-size: 14px !important; font-weight: 700 !important; color: var(--black) !important; margin: 0 0 12px !important; padding-left: 10px; border-left: 3px solid var(--yellow); }
.privacy-section > p { font-size: 13px; color: var(--gray-text); margin: 0 0 12px; line-height: 1.8; }
.privacy-frame { border: 1px solid var(--gray-line); border-radius: var(--radius); background: #fafafa; max-height: 200px; overflow-y: auto; padding: 14px 18px; margin-bottom: 14px; }
.privacy-frame pre { font-family: inherit; font-size: 12px; color: #555; line-height: 1.9; white-space: pre-wrap; word-break: break-all; margin: 0; }
.privacy-agree-text { font-size: 13px; color: #444; line-height: 1.8; margin: 0; }

.submit-area { padding: 28px 20px; text-align: center; background: var(--white); }
.submit-btn { display: inline-block; background: var(--black); color: var(--yellow); font-size: 15px; font-weight: 700; padding: 16px 56px; border: none; border-radius: var(--radius); cursor: pointer; letter-spacing: .1em; transition: background .2s, transform .2s, box-shadow .2s; font-family: inherit; pointer-events: auto; touch-action: auto; }
.submit-btn:hover { background: #333; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,.2); }

/* ---- VALIDATION ---- */
#validation-banner { display: none; background: #e53935; color: #fff; font-size: 13px; font-weight: 700; padding: 14px 20px; border-radius: var(--radius); margin-bottom: 20px; text-align: center; }
#validation-banner.is-visible { display: block; }
.form-table tr.has-error > th { background: #fff5f5; }
.form-table tr.has-error > td { background: #fff5f5; }
.input-error { border-color: #e53935 !important; background: #fff8f8 !important; box-shadow: 0 0 0 3px rgba(229,57,53,.2) !important; }
.checkbox-group.group-error { outline: 2px solid #e53935; outline-offset: 4px; border-radius: 3px; }
.error-msg { display: flex; align-items: center; gap: 5px; margin-top: 6px; font-size: 12px; color: #e53935; font-weight: 600; }
.error-msg::before { content: "⚠"; font-size: 13px; }

/* ---- CONFIRM ---- */
.confirm-section { margin-bottom: 36px; }
.confirm-section__heading { font-size: 14px !important; font-weight: 700 !important; color: var(--white) !important; background: var(--black) !important; margin: 0 !important; padding: 12px 20px !important; border-left: 4px solid var(--yellow); }
.confirm-section__table-wrap { border: 1px solid var(--gray-line); border-top: none; border-radius: 0 0 var(--radius) var(--radius); overflow: hidden; }
.confirm-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.confirm-table tr { border-bottom: 1px solid var(--gray-line); }
.confirm-table tr:last-child { border-bottom: none; }
.confirm-table th { width: 180px; padding: 14px 18px; background: var(--gray-bg); color: #444; font-weight: 700; text-align: left; vertical-align: top; border-right: 1px solid var(--gray-line); font-size: 13px; }
.confirm-table td { padding: 14px 20px; color: #333; vertical-align: top; line-height: 1.7; }
.confirm-message-block { border: 1px solid var(--gray-line); border-radius: var(--radius); overflow: hidden; margin-bottom: 32px; }
.confirm-message-block__heading { font-size: 14px !important; font-weight: 700 !important; color: var(--white) !important; background: var(--black) !important; margin: 0 !important; padding: 12px 20px !important; border-left: 4px solid var(--yellow); }
.confirm-message-block__body { padding: 20px; background: #fafafa; font-size: 14px; line-height: 1.9; min-height: 60px; white-space: pre-wrap; }
.confirm-notice { background: #fffbea; border: 1px solid #f0d800; border-left: 4px solid var(--yellow); border-radius: var(--radius); padding: 14px 20px; font-size: 13px; color: #555; line-height: 1.9; margin-bottom: 28px; }
.confirm-notice a { color: var(--black); text-decoration: underline; font-weight: 700; }
.form-buttons { display: flex; justify-content: center; align-items: center; gap: 16px; margin: 0 0 20px; }
.btn-back { padding: 13px 36px; background: var(--white); color: var(--black); font-size: 14px; font-weight: 700; border: 2px solid var(--black); border-radius: var(--radius); cursor: pointer; font-family: inherit; letter-spacing: .05em; transition: background .2s; }
.btn-back:hover { background: #f0f0f0; }
.btn-submit { padding: 13px 48px; background: var(--black); color: var(--yellow); font-size: 14px; font-weight: 700; border: 2px solid var(--black); border-radius: var(--radius); cursor: pointer; font-family: inherit; letter-spacing: .08em; min-width: 200px; transition: background .2s, transform .2s, box-shadow .2s; }
.btn-submit:hover { background: #333; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.15); }

/* ---- THANKS ---- */
.thanks-block { text-align: center; padding: 52px 40px 60px; background: var(--white); border: 1px solid var(--gray-line); border-radius: var(--radius); margin-bottom: 40px; position: relative; overflow: hidden; }
.thanks-block::before { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 4px; background: linear-gradient(90deg, var(--black) 50%, var(--yellow) 50%); }
.thanks-icon { width: 72px; height: 72px; background: var(--black); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 24px; animation: popIn .5s cubic-bezier(.175,.885,.32,1.275) both; }
@keyframes popIn { 0% { transform: scale(0); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.thanks-icon svg { width: 36px; height: 36px; }
.thanks-title { font-size: 22px !important; font-weight: 700 !important; color: var(--black) !important; margin: 0 0 8px !important; padding: 0 !important; letter-spacing: .05em; animation: fadeUp .5s .2s ease both; }
.thanks-subtitle { font-size: 14px; color: #888; margin: 0 0 32px; animation: fadeUp .5s .3s ease both; }
@keyframes fadeUp { 0% { transform: translateY(12px); opacity: 0; } 100% { transform: translateY(0); opacity: 1; } }
.thanks-message { font-size: 14px; color: #555; line-height: 2; margin: 0 auto 36px; max-width: 480px; text-align: left; background: #fafafa; border-radius: var(--radius); padding: 20px 28px; border-left: 3px solid var(--yellow); animation: fadeUp .5s .4s ease both; }
.thanks-back-btn { display: inline-block; background: var(--black); color: var(--yellow) !important; font-weight: 700; font-size: 14px; padding: 14px 48px; border-radius: var(--radius); text-decoration: none !important; transition: background .2s, transform .2s, box-shadow .2s; letter-spacing: .06em; animation: fadeUp .5s .5s ease both; }
.thanks-back-btn:hover { background: #333; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.2); }

/* ---- FOOTER ---- */
#footerblock { background: #1a1a1a; padding: 0; }
.footer-top { padding: 48px 24px 36px; max-width: var(--inner-w); margin: 0 auto; }
.footer-brand { font-size: 11px; font-weight: 700; color: var(--yellow); letter-spacing: .14em; text-transform: uppercase; margin: 0 0 28px; padding-bottom: 16px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-shops-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px 24px; }
.footer-shop { display: flex; flex-direction: column; gap: 6px; }
.footer-shop__name { font-size: 13px; font-weight: 700; color: var(--white); display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.footer-shop__name img { height: 20px; width: auto; }
.footer-shop__info { font-size: 12px; color: #888; line-height: 1.9; }
.footer-shop__links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.footer-shop__links a { font-size: 11px; color: #aaa; border: 1px solid rgba(255,255,255,.15); padding: 3px 10px; border-radius: 2px; transition: color .2s, border-color .2s; }
.footer-shop__links a:hover { color: var(--yellow); border-color: var(--yellow); }
.footer-shop__sns { display: flex; gap: 6px; list-style: none; margin: 4px 0 0; padding: 0; }
.footer-shop__sns li a img { width: 26px; height: 26px; border-radius: 3px; opacity: .75; transition: opacity .2s; }
.footer-shop__sns li a:hover img { opacity: 1; }
.footer-nav-area { background: rgba(0,0,0,.3); padding: 20px 24px; }
.footer-nav-inner { max-width: var(--inner-w); margin: 0 auto; display: flex; flex-wrap: wrap; gap: 8px 28px; justify-content: center; }
.footer-nav-inner a { font-size: 12px; color: #888; transition: color .2s; }
.footer-nav-inner a:hover { color: var(--yellow); }
.footer-copyright { background: var(--black); text-align: center; padding: 14px 24px; font-size: 11px; color: #444; letter-spacing: .05em; }


/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .footer-shops-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
  .header-nav { display: none; }
  .hamburger  { display: flex; }

  #contentswrapperblock { padding-left: 16px !important; padding-right: 16px !important; }
  #contentsblock { padding-bottom: 40px; }
  #mainimageblock { height: 100px; }
  #mainimageblock img { height: 100px; }
  #contentsheaderblock { padding: 20px 0 16px; margin-bottom: 20px; }
  #contentsheaderblock h1 { font-size: 20px; }

  .contact-steps { max-width: 270px; margin-bottom: 28px; }
  .contact-steps__circle { width: 30px; height: 30px; font-size: 12px; }
  .contact-steps__item:not(:last-child)::after { top: 15px; left: calc(50% + 16px); width: calc(100% - 32px); }
  .contact-steps__label { font-size: 10px; }

  .contact-form-wrap { border-radius: 0; border-left: none; border-right: none; margin: 0 -16px; width: calc(100% + 32px); }

  .form-table, .form-table tbody, .form-table tr, .form-table th, .form-table td { display: block; width: 100%; }
  .form-table th { padding: 10px 16px 6px; border-right: none; font-size: 12px; }
  .form-table td { padding: 8px 16px 14px; }
  .form-table input[type="text"],
  .form-table input[type="email"],
  .form-table select,
  .form-textarea { width: 100%; max-width: 100%; font-size: 16px; }
  .age-select  { width: auto; max-width: 140px; font-size: 16px; }
  .zip-link    { display: block; margin: 8px 0 0; }

  .checkbox-group { gap: 8px; }
  .checkbox-group label { width: calc(50% - 4px); font-size: 12px; padding: 8px 10px; }

  .textarea-section, .mail-notice, .privacy-section, .submit-area { padding: 16px; }
  .mail-notice { font-size: 12px; }
  .privacy-frame pre { font-size: 11px; }
  .submit-btn { width: 100%; padding: 16px; }

  .confirm-table, .confirm-table tbody, .confirm-table tr, .confirm-table th, .confirm-table td { display: block; width: 100%; }
  .confirm-table th { padding: 10px 16px 4px; border-right: none; font-size: 12px; }
  .confirm-table td { padding: 6px 16px 14px; }
  .confirm-section__table-wrap { border-left: none; border-right: none; border-radius: 0; }
  .confirm-message-block { border-left: none; border-right: none; border-radius: 0; }
  .form-buttons { flex-direction: column; gap: 10px; }
  .btn-back, .btn-submit { width: 100%; padding: 15px 20px; min-width: unset; }

  .thanks-block   { padding: 36px 20px 44px; }
  .thanks-message { padding: 16px 18px; }
  .thanks-back-btn { padding: 14px 32px; }

  .footer-top { padding: 32px 16px 28px; }
  .footer-shops-grid { grid-template-columns: 1fr 1fr; gap: 20px; }
  .footer-nav-area { padding: 16px; }
  .footer-nav-inner { gap: 6px 16px; }
  .footer-copyright { padding: 14px 16px; }
}

@media (max-width: 480px) {
  .footer-shops-grid { grid-template-columns: 1fr; }
  .checkbox-group label { width: 100%; }
}
