/* ==========================================================================
   お客さまサポート 公開ページ（Apple風・スッキリデザイン）
   白ベース / 余白広め / 黒ピルボタン / 角丸大きめ / E&Yロゴ(水色)
   ========================================================================== */

* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink: #1d1d1f;          /* Apple風の黒 */
  --ink-soft: #424245;
  --muted: #86868b;
  --bg: #ffffff;
  --bg-soft: #f5f5f7;      /* Appleのライトグレー */
  --border: #d2d2d7;
  --brand: #6bc1e1;        /* E&Yロゴの水色 */
  --accent: #0071e3;       /* ボタンの青 */
  --accent-dark: #005bb8;
  --danger: #d70015;
  --radius: 18px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue",
    "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", Meiryo, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* ---------- ロゴ（正式画像・角丸なし） ---------- */
.brand-logo {
  display: inline-block;
  width: 72px; height: 72px;
  object-fit: cover;
}
.brand-logo-sm { width: 36px; height: 36px; }

/* ==========================================================================
   TOP（モール選択）
   ========================================================================== */
.page-top { background: var(--bg); }

.top-container {
  max-width: 560px;
  margin: 0 auto;
  padding: 72px 24px 48px;
  text-align: center;
  min-height: calc(100vh - 90px);
}
.brand-block h1 {
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: .01em;
  line-height: 1.3;
  margin: 22px 0 10px;
}
.brand-lead { color: var(--muted); font-size: .95rem; margin-bottom: 40px; }

.mall-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 44px;
}
@media (max-width: 480px) { .mall-grid { grid-template-columns: repeat(2, 1fr); } }

.mall-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 118px;
  padding: 14px 8px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
  cursor: pointer;
  font-weight: 600;
  font-size: .9rem;
  color: var(--ink-soft);
  transition: border-color .15s, box-shadow .15s, transform .12s;
  -webkit-tap-highlight-color: transparent;
}
.mall-card:hover {
  transform: translateY(-3px);
  border-color: #a8a8ad;
  box-shadow: 0 8px 22px rgba(0,0,0,.10);
}
.mall-card:active { transform: translateY(0) scale(.97); }
.mall-card input { position: absolute; opacity: 0; pointer-events: none; }
.mall-card:has(input:checked) {
  border-color: var(--accent);
  box-shadow: 0 0 0 1.5px var(--accent), 0 8px 22px rgba(0,0,0,.10);
  color: var(--ink);
}

.mall-icon { display: block; width: 44px; height: 44px; }
.mall-icon svg { width: 100%; height: 100%; display: block; }
.mall-label { line-height: 1.3; text-align: center; }

/* 選択時のチェックバッジ */
.mall-check {
  position: absolute;
  top: 9px; right: 9px;
  width: 21px; height: 21px;
  opacity: 0;
  transform: scale(.6);
  transition: opacity .15s, transform .15s;
}
.mall-check svg { width: 100%; height: 100%; display: block; }
.mall-card:has(input:checked) .mall-check { opacity: 1; transform: scale(1); }

.mall-tap-hint {
  color: var(--muted);
  font-size: .84rem;
  margin: -26px 0 30px;
}

/* ---------- 黒ピルボタン（ワイヤー準拠） ---------- */
.btn-pill {
  display: block;
  width: min(320px, 100%);
  margin: 0 auto;
  background: var(--accent);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  border: none;
  border-radius: 999px;
  padding: 16px 32px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 113, 227, .3);
  transition: background .15s, transform .1s;
}
.btn-pill:hover { background: var(--accent-dark); }
.btn-pill:active { transform: scale(.98); }

/* ==========================================================================
   内容入力ページ
   ========================================================================== */
.form-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
}
.header-title { font-weight: 700; font-size: 1.02rem; }

.container {
  max-width: 680px;
  margin: 36px auto 64px;
  padding: 0 20px;
}

.lead { color: var(--ink-soft); font-size: .95rem; text-align: center; margin-bottom: 18px; }

.mall-indicator {
  text-align: center;
  font-size: .9rem;
  color: var(--ink-soft);
  margin-bottom: 30px;
}
.mall-indicator strong { color: var(--ink); }
.mall-change { margin-left: 10px; font-size: .82rem; color: #0066cc; text-decoration: none; }
.mall-change:hover { text-decoration: underline; }

/* ---------- セクション ---------- */
.form-section {
  background: var(--bg-soft);
  border-radius: 22px;
  padding: 30px 26px;
  margin-bottom: 26px;
}
.section-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 22px;
}

.field { margin-bottom: 24px; }
.field:last-child { margin-bottom: 0; }
.field > label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
  font-size: .95rem;
}
label.required::after {
  content: "必須";
  background: var(--danger);
  color: #fff;
  font-size: .68rem;
  font-weight: 500;
  border-radius: 5px;
  padding: 2px 7px;
  margin-left: 8px;
  vertical-align: 2px;
}
.field-note { font-size: .84rem; color: var(--muted); margin-bottom: 10px; }
.note-em { color: var(--danger); }

input[type=text], input[type=email], input[type=tel], select, textarea {
  width: 100%;
  padding: 13px 15px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-size: 16px;
  background: #fff;
  color: var(--ink);
  font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
  appearance: none;
  -webkit-appearance: none;
}
select {
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2386868b' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,113,227,.15);
}
::placeholder { color: #b6b6bb; }

/* 種別の選択肢（2列・ワイヤー準拠） */
.choice-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
@media (max-width: 480px) { .choice-grid { grid-template-columns: 1fr; } }
.choice-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 13px 16px;
  cursor: pointer;
  font-size: .93rem;
  font-weight: 600;
  color: var(--ink-soft);
  transition: border-color .15s, box-shadow .15s;
}
.choice-item:hover { border-color: #a8a8ad; }
.choice-item:has(input:checked) {
  border-color: var(--accent);
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--accent);
}
.choice-item input { accent-color: var(--accent); }

.product-select { display: grid; gap: 10px; }
@media (min-width: 560px) { .product-select { grid-template-columns: 1fr 2fr 1fr; } }

.hint { font-size: .8rem; color: var(--muted); margin-top: 6px; }

.zip-row { display: flex; gap: 10px; }
.zip-row input { flex: 1; }
.btn-sub {
  background: #fff;
  border: 1.5px solid var(--accent);
  color: var(--accent);
  border-radius: 999px;
  padding: 0 20px;
  font-weight: 700;
  font-size: .88rem;
  cursor: pointer;
  white-space: nowrap;
}
.btn-sub:hover { background: #f0f7ff; }

/* ---------- 注文番号の確認方法ポップアップ ---------- */
.help-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  color: var(--accent);
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  margin-left: 10px;
  vertical-align: 1px;
}
.help-link:hover { text-decoration: underline; }
.help-link .q-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px; height: 16px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  font-size: .68rem;
  font-weight: 800;
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .45);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: #fff;
  border-radius: 20px;
  max-width: 480px;
  width: 100%;
  padding: 28px 26px 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .25);
  animation: modalIn .18s ease-out;
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(12px) scale(.97); }
  to   { opacity: 1; transform: none; }
}
.modal-box h3 { font-size: 1.05rem; margin-bottom: 14px; }
.modal-body { font-size: .9rem; color: var(--ink-soft); line-height: 1.8; }
.modal-body ol { margin: 8px 0 8px 20px; }
.modal-body li { margin-bottom: 4px; }
.modal-note { font-size: .8rem; color: var(--muted); margin-top: 10px; }
.modal-close {
  display: block;
  width: 100%;
  margin-top: 18px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 12px;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
}
.modal-close:hover { background: var(--accent-dark); }

.error-box {
  background: #fff2f2;
  border: 1.5px solid var(--danger);
  color: var(--danger);
  border-radius: 14px;
  padding: 16px 20px;
  margin-bottom: 24px;
  font-size: .9rem;
}
.error-box ul { margin: 6px 0 0 20px; }

.hp-field { position: absolute; left: -9999px; }
.conditional[hidden] { display: none; }

.site-footer {
  text-align: center;
  font-size: .8rem;
  color: var(--muted);
  padding: 28px;
}

/* ==========================================================================
   確認画面
   ========================================================================== */
.confirm-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-soft);
  border-radius: 22px;
  overflow: hidden;
}
.confirm-table th, .confirm-table td {
  padding: 14px 18px;
  border-bottom: 1px solid #e6e6ea;
  text-align: left;
  font-size: .93rem;
  vertical-align: top;
}
.confirm-table tr:last-child th, .confirm-table tr:last-child td { border-bottom: none; }
.confirm-table th { width: 34%; color: var(--muted); font-weight: 600; }
.confirm-actions { display: flex; gap: 14px; margin-top: 28px; }
.confirm-actions form { flex: 1; }
.btn-back {
  display: block; width: 100%;
  background: #fff; color: var(--ink);
  border: 1.5px solid var(--border);
  border-radius: 999px; padding: 15px;
  font-size: .98rem; font-weight: 600; cursor: pointer;
}
.btn-back:hover { background: var(--bg-soft); }
.confirm-actions .btn-pill { width: 100%; }

/* ==========================================================================
   完了画面
   ========================================================================== */
.thanks-box {
  background: var(--bg-soft);
  border-radius: 22px;
  text-align: center;
  padding: 56px 28px;
}
.thanks-box h2 { font-size: 1.3rem; margin-bottom: 14px; }
.thanks-box .no { font-size: 1.05rem; margin-bottom: 14px; }
