/* ============================================================
   いよ館 GUIDE - スタイル
   原宿かわいい × 愛媛 × 旅行 × AI
   ============================================================ */

:root {
  --pink: #ff8fab;
  --pink-soft: #ffe3ec;
  --yellow: #ffca3a;
  --yellow-soft: #fff3d6;
  --orange: #ff9f5a;
  --orange-soft: #ffe8d6;
  --blue: #6fc3df;
  --blue-soft: #dff3fa;
  --cream: #fffaf2;
  --ink: #4a3b3b;
  --ink-soft: #8a7a7a;
  --white: #ffffff;
  --shadow: 0 8px 20px rgba(255, 143, 171, 0.18);
  --shadow-soft: 0 4px 14px rgba(74, 59, 59, 0.08);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "BIZ UDPGothic",
    "Yu Gothic", "Meiryo", sans-serif;
  background: #fff3ea;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  position: relative;
}

/* 背景写真（下灘駅・夕日）。position:fixedの疑似要素でビューポート基準にすることで、
   ページが長くてもcoverが正しく効き、iOSでもスクロール時にガクつかない。 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image: url("assets/bg-sunset.jpg");
  background-size: cover;
  background-position: center 30%;
  background-repeat: no-repeat;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
}

#app {
  max-width: 520px;
  margin: 0 auto;
  min-height: 100vh;
  padding-bottom: 48px;
  position: relative;
}

/* ---------- ヘッダー ---------- */
.top-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px 10px;
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 248, 239, 0.85);
  backdrop-filter: blur(6px);
}

.lang-switch {
  margin-left: auto;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 12px;
  border-radius: 20px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
}

.lang-switch:active {
  transform: scale(0.95);
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 17px;
}

.logo-link .logo-emoji {
  font-size: 22px;
}

.back-btn {
  border: none;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex: none;
  color: var(--ink);
}

.back-btn:active {
  transform: scale(0.94);
}

.header-title {
  font-weight: 700;
  font-size: 16px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-decoration: none;
  color: inherit;
}

/* ---------- 汎用レイアウト ---------- */
.view {
  padding: 6px 20px 30px;
  animation: fadeSlideIn 0.28s ease;
}

@keyframes fadeSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero {
  text-align: center;
  padding: 18px 8px 22px;
}

.hero-emoji {
  font-size: 44px;
  display: block;
  margin-bottom: 6px;
}

.hero h1 {
  font-size: 24px;
  margin: 0 0 6px;
  font-weight: 800;
  color: var(--white);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.28);
}

.hero p {
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: 15px;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
}

.section-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--white);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
  margin: 22px 4px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.section-desc {
  margin: -4px 4px 14px;
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
  font-size: 13.5px;
}

/* ---------- ホームの3大カード ---------- */
.home-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 8px;
}

.home-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--ink);
  box-shadow: var(--shadow);
  border: none;
  cursor: pointer;
  text-align: left;
  width: 100%;
  font-family: inherit;
  position: relative;
  overflow: hidden;
  transition: transform 0.15s ease;
}

.home-card:active {
  transform: scale(0.98);
}

.home-card.main {
  background: linear-gradient(135deg, var(--pink) 0%, var(--orange) 100%);
  color: var(--white);
  padding: 24px 20px;
}

.home-card.house {
  background: var(--white);
  border: 2px solid var(--blue-soft);
}

.home-card.help {
  background: var(--white);
  border: 2px solid var(--yellow-soft);
}

.home-card.contact {
  background: var(--white);
  border: 2px solid var(--pink-soft);
}

.home-card .card-emoji {
  font-size: 38px;
  flex: none;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

.home-card .card-text {
  min-width: 0;
}

.home-card .card-text .card-sub {
  display: block;
}

.home-card.main .card-emoji {
  font-size: 42px;
}

.home-card .card-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.home-card .card-text .card-title {
  font-weight: 800;
  font-size: 18px;
}

.home-card .card-text .card-sub {
  font-size: 13.5px;
  opacity: 0.85;
}

.home-card .card-badge {
  position: absolute;
  top: 12px;
  right: 14px;
  background: rgba(255, 255, 255, 0.28);
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.02em;
}

.home-card .card-arrow {
  margin-left: auto;
  font-size: 20px;
  flex: none;
  opacity: 0.6;
}

/* ---------- グリッド（施設一覧・カテゴリー一覧） ---------- */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.tile {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 18px 12px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  border: none;
  cursor: pointer;
  font-family: inherit;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: transform 0.15s ease;
}

.tile:active {
  transform: scale(0.96);
}

.tile .tile-emoji {
  font-size: 30px;
}

.tile .tile-title {
  font-weight: 700;
  font-size: 13.5px;
  line-height: 1.3;
}

.tile.c-pink { background: var(--pink-soft); }
.tile.c-orange { background: var(--orange-soft); }
.tile.c-blue { background: var(--blue-soft); }
.tile.c-yellow { background: var(--yellow-soft); }

/* 今日どうする？の特別カード */
.today-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, #ffd36e 0%, #ff9f5a 100%);
  color: var(--white);
  box-shadow: var(--shadow);
  border: none;
  cursor: pointer;
  width: 100%;
  text-align: left;
  font-family: inherit;
  margin-bottom: 18px;
}

.today-card .card-emoji {
  font-size: 40px;
}

.today-card .card-title {
  font-weight: 800;
  font-size: 18px;
}

.today-card .card-sub {
  font-size: 13px;
  opacity: 0.9;
}

/* ---------- 質問チップ ---------- */
.chip-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chip-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 14px 14px;
  box-shadow: var(--shadow-soft);
}

.chip-main {
  flex: 1;
  border: none;
  background: transparent;
  text-align: left;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
  padding: 4px 2px;
}

.chip-copy {
  flex: none;
  border: none;
  background: var(--cream);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chip-copy:active {
  transform: scale(0.9);
}

.chip-copy.copied {
  background: var(--blue-soft);
}

.category-banner {
  border-radius: var(--radius-lg);
  padding: 22px 18px;
  margin-bottom: 18px;
  color: var(--white);
  text-align: center;
}

.category-banner .banner-emoji {
  font-size: 34px;
  display: block;
  margin-bottom: 6px;
}

.category-banner .banner-title {
  font-weight: 800;
  font-size: 19px;
  margin-bottom: 2px;
}

.category-banner .banner-sub {
  font-size: 13.5px;
  opacity: 0.9;
}

.category-banner.bg-pink { background: linear-gradient(135deg, #ff8fab, #ffb6c1); }
.category-banner.bg-orange { background: linear-gradient(135deg, #ff9f5a, #ffca7a); }
.category-banner.bg-blue { background: linear-gradient(135deg, #6fc3df, #9fdcee); }
.category-banner.bg-yellow { background: linear-gradient(135deg, #ffca3a, #ffdd6e); color: var(--ink); }

/* ---------- 施設詳細 ---------- */
.detail-photo {
  height: 160px;
  border-radius: var(--radius-md);
  background: repeating-linear-gradient(
    45deg,
    #fff0f4,
    #fff0f4 10px,
    #ffe8ee 10px,
    #ffe8ee 20px
  );
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  font-size: 13.5px;
  margin-bottom: 16px;
  text-align: center;
  padding: 12px;
}

.step-list {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.step-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--white);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  box-shadow: var(--shadow-soft);
  font-size: 14px;
}

.step-num {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--orange-soft);
  color: var(--orange);
  font-weight: 800;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.owner-note {
  border: 2px dashed #f3c9d4;
  border-radius: var(--radius-sm);
  padding: 14px;
  font-size: 13px;
  color: var(--ink-soft);
  text-align: center;
  background: #fffafc;
}

/* ---------- 困ったとき ---------- */
.help-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.help-item {
  background: var(--white);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.help-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  width: 100%;
  border: none;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
}

.help-head .help-emoji {
  font-size: 24px;
  flex: none;
}

.help-head .help-title {
  flex: 1;
  font-weight: 700;
  font-size: 15px;
}

.help-head .chevron {
  color: var(--ink-soft);
  transition: transform 0.2s ease;
}

.help-item.open .chevron {
  transform: rotate(90deg);
}

.help-body {
  display: none;
  padding: 0 14px 16px;
}

.help-item.open .help-body {
  display: block;
}

.help-field {
  font-size: 13.5px;
  color: var(--ink-soft);
  margin-bottom: 4px;
}

.help-note {
  border: 2px dashed #d8ecf4;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-bottom: 10px;
  background: #f7fcfe;
}

.help-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.pill-btn {
  flex: 1;
  min-width: 120px;
  text-align: center;
  padding: 10px 10px;
  border-radius: 20px;
  border: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 12.5px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.pill-btn.map {
  background: var(--blue-soft);
  color: #227a99;
}

.pill-btn.ai {
  background: var(--pink-soft);
  color: #c23a63;
}

/* ---------- CTAボタン（ChatGPTへ） ---------- */
.cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 15px;
  border-radius: 26px;
  border: none;
  background: linear-gradient(135deg, #10a37f, #1ac599);
  color: var(--white);
  font-weight: 800;
  font-size: 15px;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(16, 163, 127, 0.3);
  text-decoration: none;
  font-family: inherit;
}

.cta-btn:active {
  transform: scale(0.98);
}

/* ---------- 今日どうする？フォーム ---------- */
.field-block {
  margin-bottom: 18px;
}

.field-label {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 8px;
  color: var(--white);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
}

.option-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.option-btn {
  padding: 9px 14px;
  border-radius: 20px;
  border: 2px solid #ffe0c2;
  background: var(--white);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
}

.option-btn.selected {
  background: linear-gradient(135deg, #ffd36e, #ff9f5a);
  border-color: transparent;
  color: var(--white);
}

.sticky-cta {
  position: sticky;
  bottom: 14px;
  margin-top: 20px;
}

/* ---------- 空きスペース / フッター ---------- */
.footer-note {
  text-align: center;
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
  font-size: 12px;
  margin-top: 30px;
}

.company-link {
  display: block;
  text-align: center;
  margin-top: 18px;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.7);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- ページ下部の移動カード（3枚横並び） ---------- */
.footer-nav {
  display: flex;
  gap: 6px;
  margin: 22px 0;
}

.footer-nav-card {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 2px;
  border: none;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
  font-family: inherit;
  color: var(--ink);
  cursor: pointer;
  text-align: center;
  transition: transform 0.15s ease;
}

.footer-nav-card:active {
  transform: scale(0.96);
}

.footer-nav-card .fn-emoji {
  font-size: 19px;
}

.footer-nav-card .fn-label {
  font-size: 9.5px;
  font-weight: 700;
  line-height: 1.25;
}

.footer-nav-card.fn-house {
  background: var(--blue-soft);
}

.footer-nav-card.fn-ehime {
  background: linear-gradient(135deg, var(--pink), var(--orange));
  color: var(--white);
}

.footer-nav-card.fn-help {
  background: var(--yellow-soft);
}

.footer-nav-card.fn-current {
  box-shadow: inset 0 0 0 2px rgba(74, 59, 59, 0.18);
  opacity: 0.6;
}

.footer-nav-card.fn-contact {
  background: var(--pink-soft);
}

/* ---------- 📞 管理人に連絡 ---------- */
.contact-hero {
  text-align: center;
  padding: 10px 0 6px;
}

.contact-photo {
  width: 112px;
  height: 112px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--white);
  border: 4px solid var(--white);
  box-shadow: var(--shadow);
  margin-bottom: 12px;
}

.contact-message {
  margin: 0;
  font-weight: 700;
  font-size: 16px;
  color: var(--white);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.24);
}

.contact-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  padding: 18px;
  text-align: center;
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-name {
  font-size: 18px;
  font-weight: 800;
}

.contact-name.is-placeholder {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
  border: 2px dashed #f3c9d4;
  border-radius: var(--radius-sm);
  padding: 10px;
  background: #fffafc;
}

.contact-tel-btn {
  background: linear-gradient(135deg, var(--blue), #8ecae6);
  box-shadow: 0 8px 18px rgba(111, 195, 223, 0.3);
}

.sns-row {
  display: flex;
  gap: 10px;
}

.sns-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 10px;
  border-radius: 20px;
  background: var(--cream);
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
}

.sns-btn .sns-emoji {
  font-size: 15px;
}

.line-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  padding: 20px;
  text-align: center;
  margin-bottom: 6px;
}

.line-cta-btn {
  background: linear-gradient(135deg, #06c755, #3ddc84);
  box-shadow: 0 8px 18px rgba(6, 199, 85, 0.32);
  margin-bottom: 14px;
}

.line-id {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 6px;
}

.line-id.is-placeholder {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
  border: 2px dashed #f3c9d4;
  border-radius: var(--radius-sm);
  padding: 10px;
  background: #fffafc;
  margin-bottom: 6px;
}

.qr-secondary {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px dashed #eee2e2;
}

/* ---------- 民泊届出済証明書ボタン & ライトボックス ---------- */
.cert-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 14px;
  border: none;
  border-radius: 20px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  font-family: inherit;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  margin: 6px 0 22px;
}

.cert-btn:active {
  transform: scale(0.98);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(20, 12, 8, 0.78);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.lightbox.show {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-img {
  max-width: 100%;
  max-height: 85vh;
  border-radius: var(--radius-md);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
  background: var(--white);
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  font-size: 18px;
  cursor: pointer;
}

.line-qr-img {
  width: 180px;
  height: 180px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
  display: block;
  margin: 0 auto;
}

.line-qr-img.is-secondary {
  width: 128px;
  height: 128px;
}

.line-hint {
  margin: 0 0 12px;
  font-size: 12.5px;
  color: var(--ink-soft);
}

/* OGPカード風のリンクカード */
.link-card {
  display: block;
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
  border: 1px solid #eee2e2;
}

.link-card-img {
  width: 100%;
  aspect-ratio: 1.91 / 1;
  object-fit: cover;
  display: block;
  background: var(--cream);
}

.link-card-body {
  padding: 14px 16px 16px;
}

.link-card-title {
  font-weight: 800;
  font-size: 15.5px;
  margin-bottom: 3px;
}

.link-card-desc {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 6px;
}

.link-card-url {
  font-size: 11.5px;
  color: #7a9a3a;
  font-weight: 700;
}

/* ---------- トースト ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%) translateY(20px);
  background: var(--ink);
  color: var(--white);
  padding: 10px 20px;
  border-radius: 20px;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s ease;
  z-index: 50;
  white-space: nowrap;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
