/* ==================================================
 * features/shop.css：店舗検索・一覧・情報・キャンペーン固有の配置・装飾
 * 各区画は :where(body の画面クラス) で限定し、詳細度を上げない
 * ================================================== */

/* ==================================================
 * 店舗検索（shopsearch.html）
 * ================================================== */

/* === ページヘッダー === */
/* タイトルに地図アイコンを付ける（標準形は surfaces.css） */
:where(.shopsearch) .md3-page-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

:where(.shopsearch) .md3-page-title .material-symbols-outlined {
  color: var(--md-primary);
  font-size: 32px;
}

/* === ステッパー === */
:where(.shopsearch) .md3-stepper-card {
  margin-bottom: 40px;
}

:where(.shopsearch) .md3-section-title {
  margin: 0 0 32px;
}

:where(.shopsearch) .md3-step-icon {
  padding: 0 !important;
  margin: 0 !important;
}

/* === 地域別カード（Filled Card） === */
:where(.shopsearch) .md3-regions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

:where(.shopsearch) .md3-region-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  background-color: var(--md-surface-container-low);
  border: none;
  border-radius: var(--border-radius-lg);
  padding: 24px;
  transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

/* カード全体をホバーで浮き上がらせる */
:where(.shopsearch) .md3-region-card:hover {
  background-color: var(--md-surface);
  box-shadow: var(--md-elevation-3);
  transform: translateY(-2px);
}

:where(.shopsearch) .md3-region-title {
  font-size: var(--typescale-body);
  line-height: var(--typescale-body-line-height);
  font-weight: 700;
  color: var(--text-main);
  margin: 0;
  padding: 4px 12px;
  background-color: transparent;
  border-left: 4px solid var(--md-secondary);
}

:where(.shopsearch) .md3-pref-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 12px;
}

/* === 都道府県リンク（Tonal Chip） === */
:where(.shopsearch) .md3-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 8px 12px;
  border: none;
  border-radius: var(--border-radius-md);
  color: var(--text-main);
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  font-weight: 500;
  transition: all 0.2s cubic-bezier(0.2, 0, 0, 1);
  background-color: var(--md-surface-container-high);
}

:where(.shopsearch) .md3-chip::after {
  content: "chevron_right";
  font-family: 'Material Symbols Outlined';
  font-size: 16px;
  color: var(--text-muted);
  transition: inherit;
}

:where(.shopsearch) .md3-chip:hover {
  background-color: var(--md-surface);
  color: var(--md-primary) !important;
  box-shadow: var(--md-elevation-2);
}

:where(.shopsearch) .md3-chip:hover::after {
  color: var(--md-primary);
}

@media (max-width: 600px) {

  :where(.shopsearch) .md3-stepper-card {
  padding: 24px 16px;
  }

  :where(.shopsearch) .md3-region-card {
  padding: 20px 16px;
  }

  :where(.shopsearch) .md3-regions-grid {
  grid-template-columns: 1fr;
  gap: 20px;
  }

  :where(.shopsearch) .md3-step-icon {
  width: 24px;
  height: 24px;
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  }

  :where(.shopsearch) .md3-step-label {
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  padding: 0 2px;
  }

  :where(.shopsearch) .md3-stepper::before {
  top: 11px;
  }

  :where(.shopsearch) .md3-pref-list {
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  }
}

body.shopsearch #main .md3-theme {
  padding: 8px 0 40px;
  text-align: left;
  font-size: var(--typescale-body);
  line-height: var(--typescale-body-line-height);
  font-weight: 400;
  overflow-wrap: anywhere;
}

:where(.shopsearch) .md3-theme .md3-page-title,
:where(.shopsearch) .md3-theme .md3-section-title,
:where(.shopsearch) .md3-theme .md3-step,
:where(.shopsearch) .md3-theme .md3-step-label,
:where(.shopsearch) .md3-theme .md3-region-title,
:where(.shopsearch) .md3-theme .md3-step-icon {
  font-weight: 700;
}

:where(.shopsearch) .md3-theme .md3-chip {
  font-weight: 500;
}

:where(.shopsearch) .md3-theme .md3-chip,
:where(.shopsearch) .md3-theme .md3-chip:link,
:where(.shopsearch) .md3-theme .md3-chip:visited {
  color: var(--text-main);
}

body.shopsearch #main .md3-theme .md3-chip {
  min-height: 44px;
}

:where(.shopsearch) .md3-theme .md3-chip:focus-visible {
  outline: 3px solid var(--md-secondary);
  outline-offset: 3px;
}

:where(.shopsearch) .md3-theme .md3-step {
  min-width: 0;
}

:where(.shopsearch) .md3-theme .md3-step-icon {
  flex-shrink: 0;
}

:where(.shopsearch) .md3-theme .md3-regions-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

:where(.shopsearch) .md3-theme .md3-region-card {
  min-width: 0;
}

@media (max-width: 737px) {

  body.shopsearch #main .md3-theme {
  padding: 16px 4% 32px;
  }

  :where(.shopsearch) .md3-theme .md3-regions-grid {
  grid-template-columns: 1fr;
  }
}

/* ==================================================
 * 店舗一覧
 * ================================================== */

/* === 電話番号リンク === */
:where(.shop-select) .md3-phone-link {
  color: var(--text-main) !important; /* ブラウザ標準のリンク色を打ち消す */
  text-decoration: none !important;
}

@media (hover: hover) {

  :where(.shop-select) .md3-phone-link:hover {
    color: var(--md-secondary) !important;
    text-decoration: underline !important;
  }
}

/* === 市区町村の絞り込みバー（Sticky Filter Chips） === */
:where(.shop-select) .md3-filter-bar {
  position: sticky;
  top: 80px; /* 親サイトの固定ヘッダーの高さ分ずらす */
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  padding: 16px 0;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border-light);
  z-index: 10;
}

:where(.shop-select) .md3-filter-title {
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  font-weight: 700;
  color: var(--text-muted);
  margin: 0 0 12px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

:where(.shop-select) .md3-filter-title .material-symbols-outlined { font-size: 16px; }

:where(.shop-select) .md3-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

:where(.shop-select) .md3-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background-color: var(--md-surface-container);
  border: none;
  border-radius: var(--border-radius-md);
  color: var(--text-main) !important;
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  font-weight: 700;
  transition: all 0.2s;
}

:where(.shop-select) .md3-filter-chip:hover {
  background-color: var(--md-surface-container-high);
  color: var(--md-secondary) !important;
}

:where(.shop-select) .md3-filter-badge {
  background-color: var(--md-surface);
  color: var(--text-muted);
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  padding: 2px 6px;
  border-radius: var(--border-radius-full);
  font-weight: 700;
}

/* === 市区町村セクション === */
/* 店舗一覧はヘッダーで囲まず、見出しだけを置く */
:where(.shop-select) .md3-page-title {
  margin: 0 0 16px 0;
}

:where(.shop-select) .md3-city-section { scroll-margin-top: 180px; margin-bottom: 56px; }

:where(.shop-select) .md3-city-heading {
  font-size: var(--typescale-title);
  line-height: var(--typescale-title-line-height);
  font-weight: 700;
  color: var(--text-main);
  margin: 0 0 20px 0;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 8px;
}

:where(.shop-select) .md3-city-heading .material-symbols-outlined { color: var(--text-muted); }

:where(.shop-select) .md3-city-count {
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  color: var(--text-muted);
  font-weight: 400;
  margin-left: auto;
}

/* === 店舗カード（Filled Card・枠線なし） === */
:where(.shop-select) .md3-shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 20px;
}

:where(.shop-select) .md3-shop-card {
  display: flex;
  flex-direction: column;
  background-color: var(--md-surface-container-low);
  border: none;
  border-radius: var(--border-radius-lg);
  padding: 24px;
  transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

:where(.shop-select) .md3-shop-card:hover {
  background-color: var(--md-surface);
  box-shadow: var(--md-elevation-3);
  transform: translateY(-2px);
}

:where(.shop-select) .md3-shop-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

:where(.shop-select) .md3-shop-title {
  font-size: var(--typescale-title);
  line-height: var(--typescale-title-line-height);
  font-weight: 700;
  color: var(--text-main);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

:where(.shop-select) .md3-shop-title .material-symbols-outlined {
  color: var(--md-primary);
  font-size: 22px;
}

:where(.shop-select) .md3-shop-link {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  font-weight: 700;
  color: var(--md-secondary) !important;
  padding: 6px 8px;
  border-radius: var(--border-radius-sm);
  transition: background-color 0.2s;
}

:where(.shop-select) .md3-shop-link:hover {
  background-color: rgba(26, 115, 232, 0.08);
}

:where(.shop-select) .md3-info-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: var(--typescale-label);
  color: var(--text-muted);
  margin-bottom: 8px;
  line-height: var(--typescale-label-line-height);
}

:where(.shop-select) .md3-info-row .material-symbols-outlined {
  font-size: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
  margin-top: 1px;
}

/* 取扱いメニューのチップをカード背景から白抜きで区別 */
:where(.shop-select) .md3-menu-section {
  margin: 16px 0 20px;
  flex: 1;
}

:where(.shop-select) .md3-menu-title {
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  font-weight: 700;
  color: var(--text-muted);
  margin: 0 0 10px 0;
}

:where(.shop-select) .md3-menu-chips { display: flex; flex-wrap: wrap; gap: 8px; }

:where(.shop-select) .md3-menu-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background-color: var(--md-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-sm);
  color: var(--text-main) !important;
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  font-weight: 700;
}

:where(.shop-select) span.md3-menu-chip-empty {
  background-color: transparent;
  border: none;
  color: var(--text-muted);
  font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height);
  padding: 0;
}

/* 操作ボタンを等幅で並べる */
:where(.shop-select) .md3-shop-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: auto;
}

:where(.shop-select) .md3-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border-radius: var(--border-radius-full);
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  text-align: center;
}

:where(.shop-select) .md3-btn-primary {
  background-color: var(--md-primary);
  color: var(--md-on-primary) !important;
}

:where(.shop-select) .md3-btn-primary:hover {
  background-color: var(--md-primary-hover);
  box-shadow: var(--md-elevation-2);
}

:where(.shop-select) .md3-btn-outlined {
  background-color: transparent;
  border: 1px solid var(--border-dark);
  color: var(--text-main) !important;
}

:where(.shop-select) .md3-btn-outlined:hover {
  background-color: var(--md-surface);
  border-color: var(--text-main);
}

@media (max-width: 737px) {

  :where(.shop-select) .md3-filter-bar { padding: 12px 0; top: 60px; }

  :where(.shop-select) .md3-filter-chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; }

  :where(.shop-select) .md3-filter-chip { flex-shrink: 0; }

  :where(.shop-select) .md3-shop-grid { grid-template-columns: 1fr; gap: 16px; }

  :where(.shop-select) .md3-shop-card { padding: 20px 16px; }
}

body.shop-select #main .md3-theme { padding: 8px 0 40px; text-align: left; min-width: 0; overflow-wrap: anywhere; }

:where(.shop-select) .md3-theme .md3-city-section { scroll-margin-top: var(--shop-select-anchor-offset, 280px); }

:where(.shop-select) .md3-theme a:focus-visible,
:where(.shop-select) .md3-theme button:focus-visible { outline: 3px solid var(--md-secondary); outline-offset: 3px; }

@media (min-width: 738px) {

  body.shop-select .md3-filter-bar { top: 111px; }
}

@media (max-width: 737px) {

  body.shop-select #main .md3-theme { padding: 16px 4% 32px; }
}

/* ==================================================
 * 店舗情報
 * ================================================== */

/* === 上下の主要アクション === */
:where(.shop-info) .md3-action-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 32px;
}

:where(.shop-info) .md3-action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 8px;
  border-radius: var(--border-radius-lg);
  background-color: var(--md-surface-container-low);
  border: 1px solid var(--border-light);
  color: var(--md-secondary) !important;
  transition: all 0.2s;
}

:where(.shop-info) .md3-action-item:hover { background-color: var(--md-surface-container); }

:where(.shop-info) .md3-action-item.is-primary {
  background-color: var(--md-primary);
  color: var(--md-on-primary) !important;
  border-color: var(--md-primary);
  box-shadow: var(--md-elevation-1);
}

:where(.shop-info) .md3-action-item.is-primary:hover {
  background-color: var(--md-primary-hover);
  box-shadow: var(--md-elevation-2);
  transform: translateY(-1px);
}

:where(.shop-info) .md3-action-item.is-disabled {
  background-color: var(--md-surface-container) !important;
  color: var(--text-muted) !important;
  border-color: var(--border-light) !important;
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none !important;
  transform: none !important;
}

:where(.shop-info) .md3-action-item.is-disabled .md3-action-icon { color: var(--text-muted) !important; }

:where(.shop-info) .md3-action-icon { font-size: 26px; }

:where(.shop-info) .md3-action-label {
  font-size: var(--typescale-label);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

/* === カード（Filled Card） === */
:where(.shop-info) .md3-card {
  background-color: var(--md-surface-container-low);
  border: none;
  border-radius: var(--border-radius-lg);
  padding: 32px;
  margin-bottom: 24px;
  transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

:where(.shop-info) .md3-card:hover {
  background-color: var(--md-surface);
  box-shadow: var(--md-elevation-3);
  transform: translateY(-2px);
}

:where(.shop-info) .md3-card-title {
  font-size: var(--typescale-title);
  line-height: var(--typescale-title-line-height);
  font-weight: 700;
  margin: 0 0 20px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 2px solid var(--border-light);
  padding-bottom: 8px;
}

:where(.shop-info) .md3-card-title .material-symbols-outlined { color: var(--md-primary); }

/* === 電話番号・外部リンク === */
:where(.shop-info) .md3-phone-link,
:where(.shop-info) .md3-external-link {
  color: var(--md-secondary) !important;
  text-decoration: none !important;
  font-weight: 700;
  letter-spacing: 0.05em;
}

@media (hover: hover) {

  :where(.shop-info) .md3-phone-link:hover,
  :where(.shop-info) .md3-external-link:hover {
    color: var(--md-secondary) !important;
    text-decoration: underline !important;
  }
}

/* === 写真なしの代替表示（NO PHOTO） === */
:where(.shop-info) .md3-no-photo {
  background-color: var(--md-surface-container-high);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  border-radius: var(--border-radius-md);
  aspect-ratio: 4 / 3;
  width: 100%;
}

:where(.shop-info) .md3-no-photo .material-symbols-outlined { font-size: 32px; margin-bottom: 4px; opacity: 0.6; }

:where(.shop-info) .md3-no-photo span { font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height); font-weight: 700; letter-spacing: 0.05em; opacity: 0.8;
}

/* === 画像全般 === */
:where(.shop-info) .md3-img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--border-radius-md);
}

/* === 店舗写真集（ぼかし背景） === */
:where(.shop-info) .md3-gallery-main {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  background-color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

:where(.shop-info) .md3-gallery-main.md3-no-photo {
  background-color: var(--md-surface-container-high);
}

:where(.shop-info) .md3-gallery-bg {
  position: absolute;
  top: -10%;
  left: -10%;
  width: 120%;
  height: 120%;
  object-fit: cover;
  filter: blur(16px);
  opacity: 0.5;
  z-index: 0;
}

:where(.shop-info) .md3-gallery-img {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.4));
  transition: max-width 0.2s;
}

:where(.shop-info) .md3-gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
  gap: 8px;
}

:where(.shop-info) .md3-gallery-thumbs > div,
:where(.shop-info) .md3-gallery-thumbs > button {
  aspect-ratio: 4 / 3;
  border-radius: var(--border-radius-sm);
  overflow: hidden;
  position: relative;
}

:where(.shop-info) .md3-gallery-thumb {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  transition: opacity 0.2s;
}

:where(.shop-info) .md3-gallery-thumb:hover { opacity: 0.7; }

:where(.shop-info) .md3-gallery-thumb::after {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border: 2px solid transparent;
  border-radius: inherit;
  pointer-events: none;
  transition: border-color 0.2s;
}

:where(.shop-info) .md3-gallery-thumb.is-active::after { border-color: var(--md-primary); }

:where(.shop-info) .md3-gallery-thumb.is-active { opacity: 1 !important; }

:where(.shop-info) .md3-gallery-thumb > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 0;
}

/* === チラシ・料金表グリッド === */
:where(.shop-info) .md3-flyer-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
}

:where(.shop-info) .md3-flyer-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

:where(.shop-info) .md3-flyer-grid > div {
  aspect-ratio: 1 / 1;
}

/* === キャンペーン・ブログ バナーグリッド === */
:where(.shop-info) .md3-banner-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  align-items: stretch;
}

:where(.shop-info) .md3-banner-link {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  background-color: var(--md-surface);
  transition: opacity 0.2s, box-shadow 0.2s;
}

:where(.shop-info) .md3-banner-link[href]:hover {
  opacity: 0.85;
  box-shadow: var(--md-elevation-1);
}

:where(.shop-info) .md3-banner-img {
  max-width: 100%;
  max-height: 120px;
  height: auto;
  object-fit: contain;
}

/* === スタッフ紹介グリッド === */
:where(.shop-info) .md3-staff-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

:where(.shop-info) .md3-staff-item {
  background-color: var(--md-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

:where(.shop-info) .md3-staff-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

:where(.shop-info) .md3-staff-img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

:where(.shop-info) .md3-staff-info { display: flex; flex-direction: column; }

:where(.shop-info) .md3-staff-role { font-size: var(--typescale-label-small);
  line-height: var(--typescale-label-small-line-height); color: var(--text-muted); font-weight: 700;
}

:where(.shop-info) .md3-staff-name { font-size: var(--typescale-title);
  line-height: var(--typescale-title-line-height); font-weight: 700; color: var(--text-main);
}

:where(.shop-info) .md3-staff-comment { font-size: var(--typescale-body); color: var(--text-muted); line-height: var(--typescale-body-line-height); }

/* === 詳細情報テーブル === */
:where(.shop-info) .md3-info-table {
  width: 100%;
  border-collapse: collapse;
}

:where(.shop-info) .md3-info-table th,
:where(.shop-info) .md3-info-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border-light);
  text-align: left;
  vertical-align: top;
}

:where(.shop-info) .md3-info-table tr:last-child th,
:where(.shop-info) .md3-info-table tr:last-child td {
  border-bottom: none;
}

:where(.shop-info) .md3-info-table th {
  width: 25%;
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  color: var(--text-muted);
  font-weight: 500;
  white-space: nowrap;
}

:where(.shop-info) .md3-info-table td {
  color: var(--text-main);
  font-size: var(--typescale-body);
  line-height: var(--typescale-body-line-height);
}

/* === 地図枠 === */
:where(.shop-info) .md3-map-container {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--border-radius-md);
  overflow: hidden;
}

@media (max-width: 600px) {

  :where(.shop-info) .md3-flyer-groups,
  :where(.shop-info) .md3-flyer-grid { grid-template-columns: 1fr; }

  :where(.shop-info) .md3-card { padding: 20px 16px; }

  :where(.shop-info) .md3-info-table th,
  :where(.shop-info) .md3-info-table td { display: block; width: 100%; padding: 12px 0; }

  :where(.shop-info) .md3-info-table th { padding-bottom: 4px; border-bottom: none; font-weight: 700; }

  :where(.shop-info) .md3-action-panel { gap: 8px; }

  :where(.shop-info) .md3-action-label { font-size: var(--typescale-label-small); }
}

body.shop-info #main .md3-theme { padding: 8px 0 40px; text-align: left; min-width: 0; overflow-wrap: anywhere; }

:where(.shop-info) .md3-theme .md3-card[id] { scroll-margin-top: 140px; }

:where(.shop-info) .md3-theme a:focus-visible,
:where(.shop-info) .md3-theme button:focus-visible { outline: 3px solid var(--md-secondary); outline-offset: 3px; }

@media (max-width: 737px) {

  body.shop-info #main .md3-theme { padding: 16px 4% 32px; }

  :where(.shop-info) .md3-theme .md3-card[id] { scroll-margin-top: 100px; }
}

:where(.shop-info) .md3-image-open { display: block; width: 100%; height: 100%; padding: 0; border: 0; border-radius: var(--border-radius-md); background: transparent; cursor: zoom-in; }

:where(.shop-info) .md3-lightbox { box-sizing: border-box; position: fixed; inset: 0; width: fit-content; max-width: 95vw; max-height: 95vh; max-height: 95dvh; margin: auto; padding: 56px 24px 24px; border: none; border-radius: var(--border-radius-md); background: var(--md-surface); color: var(--text-main); }

:where(.shop-info) .md3-lightbox::backdrop { background: rgba(0, 0, 0, 0.8); backdrop-filter: blur(4px); }

:where(.shop-info) .md3-lightbox-content { display: flex; align-items: center; justify-content: center; }

:where(.shop-info) .md3-lightbox-content img { display: block; width: auto; height: auto; max-width: 100%; max-height: calc(95vh - 80px); max-height: calc(95dvh - 80px); object-fit: contain; border-radius: var(--border-radius-md); }

:where(.shop-info) .md3-lightbox-close { position: absolute; top: 12px; right: 12px; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 50%; background: var(--text-main); color: #fff; cursor: pointer; }

:where(.shop-info) .md3-lightbox-close .material-symbols-outlined { font-size: 20px; }

:where(.shop-info) .md3-lightbox-close:hover { background: var(--text-muted); transform: scale(1.05); transition: transform 0.2s; }

:where(.shop-info) .md3-flyer-title { font-size: var(--typescale-title); line-height: var(--typescale-title-line-height); margin: 0 0 12px; }

:where(.shop-info) .md3-access { color: var(--text-muted); font-size: var(--typescale-body); line-height: var(--typescale-body-line-height); margin: 0 0 16px; }

:where(.shop-info) .md3-campaign-image { display: block; max-width: 100%; height: auto; margin: 0 auto 24px; border-radius: var(--border-radius-md); }

:where(.shop-info) .md3-rich-text { font-size: var(--typescale-body); line-height: var(--typescale-body-line-height); overflow-x: auto; }

:where(.shop-info) .md3-rich-text h1,
:where(.shop-info) .md3-rich-text h2,
:where(.shop-info) .md3-rich-text h3,
:where(.shop-info) .md3-rich-text h4,
:where(.shop-info) .md3-rich-text h5,
:where(.shop-info) .md3-rich-text h6 { font-size: var(--typescale-title); line-height: var(--typescale-title-line-height); }

:where(.shop-info) .md3-rich-text p { margin: 0 0 16px; }

:where(.shop-info) .md3-rich-text img { max-width: 100%; height: auto; }

:where(.shop-info) .md3-rich-text table { max-width: 100%; border-collapse: collapse; }

:where(.shop-info) .md3-rich-text ul,
:where(.shop-info) .md3-rich-text ol { padding-left: 1.5em; }

/* ==================================================
 * 店舗キャンペーン
 * ================================================== */

/* === ページヘッダー === */
/* 補足行をアイコン付きで表示（標準形は surfaces.css） */
:where(.shop-campaign) .md3-page-subtitle {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 500;
}

/* === カード（Filled Card） === */
:where(.shop-campaign) .md3-card {
  background-color: var(--md-surface-container-low);
  border: none;
  border-radius: var(--border-radius-lg);
  padding: 36px;
  margin-bottom: 32px;
  transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

:where(.shop-campaign) .md3-card:hover {
  background-color: var(--md-surface);
  box-shadow: var(--md-elevation-3);
}

/* === キャンペーン画像 === */
:where(.shop-campaign) .md3-campaign-img {
  display: block;
  margin: 0 auto 36px auto;
  max-width: 100%;
  max-height: 440px; 
  height: auto;
  object-fit: contain;
  border-radius: var(--border-radius-md);
  box-shadow: var(--md-elevation-1);
  border: 1px solid var(--border-light);
}

/* 画像の直後の情報表との間隔を確保 */
:where(.shop-campaign) .md3-campaign-img + .md3-info-table {
  margin-top: 8px;
}

/* === 詳細情報テーブル === */
:where(.shop-campaign) .md3-info-table {
  width: 100%;
  border-collapse: collapse;
}

:where(.shop-campaign) .md3-info-table th,
:where(.shop-campaign) .md3-info-table td {
  padding: 20px 16px;
  border-bottom: 1px solid var(--border-light);
  text-align: left;
  vertical-align: top;
}

/* 最終行の罫線を非表示 */
:where(.shop-campaign) .md3-info-table tr:last-child th,
:where(.shop-campaign) .md3-info-table tr:last-child td {
  border-bottom: none;
}

:where(.shop-campaign) .md3-info-table th {
  width: 22%;
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  color: var(--text-muted);
  font-weight: 700;
  white-space: nowrap;
}

:where(.shop-campaign) .md3-info-table td {
  color: var(--text-main);
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
}

/* === 下部の操作ボタン === */
:where(.shop-campaign) .md3-bottom-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

:where(.shop-campaign) .md3-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-radius: var(--border-radius-full);
  font-size: var(--typescale-label);
  line-height: var(--typescale-label-line-height);
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  text-align: center;
  gap: 8px;
}

:where(.shop-campaign) .md3-btn-primary { background-color: var(--md-primary); color: var(--md-on-primary) !important; }

:where(.shop-campaign) .md3-btn-primary:hover { background-color: var(--md-primary-hover); box-shadow: var(--md-elevation-2); }

:where(.shop-campaign) .md3-btn-outlined { background-color: transparent; border: 1px solid var(--border-light); color: var(--text-main) !important; }

:where(.shop-campaign) .md3-btn-outlined:hover { background-color: var(--md-surface-container); border-color: var(--text-muted); }

@media (max-width: 600px) {

  :where(.shop-campaign) .md3-card { padding: 24px 16px; }

  :where(.shop-campaign) .md3-campaign-img { margin-bottom: 16px; }

  :where(.shop-campaign) .md3-campaign-img + .md3-info-table { margin-top: 8px; }

  :where(.shop-campaign) .md3-info-table th,
  :where(.shop-campaign) .md3-info-table td { display: block; width: 100%; padding: 12px 0; }

  :where(.shop-campaign) .md3-info-table th { padding-bottom: 4px; border-bottom: none; font-weight: 700; }

  :where(.shop-campaign) .md3-bottom-actions { grid-template-columns: 1fr; }
}

body.shop-campaign #main .md3-theme { padding: 8px 0 40px; text-align: left; min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 737px) {

  body.shop-campaign #main .md3-theme { padding: 16px 4% 32px; }
}
