/* =========================================================
   smile survey – AIオプション LP
   Figma: smile-servey-LP (node 1560:2169) を基にコーディング

   ※ サイト共通ヘッダー・フッターと同居させるため、
      全ルールを .ai-package（<main> に付与）配下にスコープしている。
      body / a / ul などの素の要素セレクタを追加しないこと
      （ヘッダー・フッターの font-family / font-size 等を上書きしてしまう）。
   ※ html の scroll-behavior: smooth も指定しない：
      サイト共通の jquery.page-scroller.js / pagetop.js（jQuery animate による
      スクロール制御）と競合し、アンカー移動・PAGE TOP が動かなくなるため
   ========================================================= */

:root {
  /* ---- カラートークン（Figmaの design tokens に対応） ---- */
  --color-brand-accent: #f28d00;
  --color-brand-accent-soft: #fff7eb;
  --color-text-default: #333333;
  --color-text-muted: #525252;
  --color-border-light: #e8e8e8;
  --color-border-warm: #f4eee4;
  --color-teal: #2ba2b7;
  --color-grad-purple: #a932fe;
  --color-grad-blue: #3a3dfe;

  --max-width: 1200px;
  --content-width: 964px;

  --font-jp: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
}

.ai-package,
.ai-package * { box-sizing: border-box; }
.ai-package {
  font-family: var(--font-jp);
  /* body.ss（layout.css）が font-size 62.5%（10px）・letter-spacing 0.1em を
     設定するため、LP 内では打ち消して元デザインの基準に戻す */
  font-size: 16px;
  letter-spacing: normal;
  color: var(--color-text-default);
  background: #ffffff;
  -webkit-font-smoothing: antialiased;
}
.ai-package img, .ai-package svg { display: block; max-width: 100%; }
.ai-package a:not(.a-button) { color: inherit; text-decoration: none; }
.ai-package ul { margin: 0; padding: 0; list-style: none; }
.ai-package h1, .ai-package h2, .ai-package h3, .ai-package p:not(.m-panel--text) { margin: 0; }

.ai-package .page-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 40px;
}

/* =========================================================
   Buttons / Pills
   ========================================================= */
.ai-package .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.02em;
  padding: 10px 24px;
  border-radius: 30px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, opacity .15s ease, background-color .15s ease;
  white-space: nowrap;
}
.ai-package .btn:hover { opacity: .88; }
.ai-package .btn:active { transform: translateY(1px); }

.ai-package .btn-primary { background: var(--color-brand-accent); color: #fff; }
.ai-package .btn-outline-teal { background: #fff; color: var(--color-teal); border-color: var(--color-teal); }
.ai-package .btn-white { background: #fff; color: var(--color-brand-accent); width: 100%; padding: 16px 40px; border-radius: 16px; font-size: 16px; }
.ai-package .btn-outline-white { background: transparent; color: #fff; border: 2px solid #fff; width: 100%; padding: 16px 40px; border-radius: 16px; font-size: 16px; }

.ai-package .pill {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  font-size: 13px;
  padding: 4px 16px;
  border-radius: 30px;
  white-space: nowrap;
}
.ai-package .pill-gradient { background: linear-gradient(90deg, var(--color-grad-purple), var(--color-grad-blue)); color: #fff; font-size: 12px; padding: 3px 12px; }
.ai-package .pill-outline-orange { background: #fff; border: 1px solid var(--color-brand-accent); color: var(--color-brand-accent); }
.ai-package .pill-outline-teal { background: #fff; border: 1px solid var(--color-teal); color: var(--color-teal); }

/* =========================================================
   Hero
   ========================================================= */
.ai-package .hero {
  background: var(--color-brand-accent-soft);
  border-radius: 0 0 16px 16px;
  padding: 56px 40px;
}
.ai-package .hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 40px;
}
.ai-package .hero-copy { flex: 1 1 0; min-width: 0; }
.ai-package .hero-copy h1 {
  font-size: 42px !important;
  font-weight: 700;
  line-height: 1.5 !important;
  letter-spacing: 0 !important;
  color: var(--color-brand-accent);
}
.ai-package .hero-copy p {
  margin-top: 24px;
  font-size: 17px;
  font-weight: 500;
  line-height: 2;
  color: var(--color-text-muted);
}
.ai-package .hero-media {
  flex: 1.4 1 0;
  min-width: 0;
  width: 100%;
  aspect-ratio: 560 / 400;
  max-width: 640px;
  background: #ffffff;
  border-radius: 8px;
}
.ai-package .hero-media.has-video {
  position: relative;
  aspect-ratio: auto;
  overflow: hidden;
  border: 1px solid #ddd;
}
.ai-package .hero-media.has-video video {
  width: 100%;
  height: auto;
  display: block;
}

/* =========================================================
   Section heading (orange left-border bar)
   ========================================================= */
.ai-package .section { padding: 88px 0; }
.ai-package .section-heading {
  font-size: 32px !important;
  font-weight: 700;
  color: var(--color-text-default);
  border-left: 5px solid var(--color-brand-accent);
  padding: 0 20px;
  margin: 0 0 40px !important;
  line-height: 1.4;
  letter-spacing: 0 !important;
}

/* =========================================================
   About / lead text
   ========================================================= */
.ai-package .lead-text {
  font-size: 16px;
  font-weight: 500;
  line-height: 2;
  color: var(--color-text-muted);
  margin-bottom: 32px;
}
.ai-package .lead-text p + p { margin-top: 16px; }

/* Steps（Figmaからエクスポートした画像をそのまま使用） */
.ai-package .steps-image {
  display: block;
  width: 100%;
  max-width: 964px;
  height: auto;
  margin: 0 auto;
}

/* =========================================================
   Table
   ========================================================= */
.ai-package .table-wrap {
  overflow-x: auto;
  border: 1px solid var(--color-border-warm);
  border-radius: 16px;
}
.ai-package .feature-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}
.ai-package .feature-table thead th {
  background: var(--color-brand-accent-soft);
  font-size: 16px;
  font-weight: 700;
  text-align: left;
  padding: 12px 20px;
  border-bottom: 1px solid var(--color-border-warm);
  border-right: 1px solid var(--color-border-warm);
}
.ai-package .feature-table thead th:last-child { border-right: none; }
.ai-package .feature-table .col-status { width: 220px; text-align: center; }
.ai-package .feature-table tbody td {
  background: #fff;
  font-size: 16px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border-warm);
  border-right: 1px solid var(--color-border-warm);
  vertical-align: middle;
}
.ai-package .feature-table tbody tr:last-child td { border-bottom: none; }
.ai-package .feature-table tbody td:last-child { border-right: none; }
.ai-package .feature-table .cell-feature { display: flex; align-items: center; gap: 14px; white-space: nowrap; font-weight: 500; }
.ai-package .table-icon {
  width: 48px; height: 48px;
  flex-shrink: 0;
}
.ai-package .feature-table .col-status { text-align: center; }
.ai-package .status-date { display: block; font-size: 13px; margin-top: 6px; color: var(--color-text-default); }
.ai-package .date-label { display: none; }

/* =========================================================
   4つの機能 (feature rows)
   ========================================================= */
.ai-package .feature-rows { display: flex; flex-direction: column; }
.ai-package .feature-row {
  display: flex;
  align-items: flex-start;
  gap: 40px;
  padding-bottom: 32px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--color-border-light);
}
.ai-package .feature-row-last { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.ai-package .feature-row-copy { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.ai-package .feature-row-head { display: flex; align-items: center; gap: 14px; }
.ai-package .feature-row-icon {
  width: 64px; height: 64px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.ai-package .feature-row-icon img { width: 64px; height: 64px; }
.ai-package .feature-row-head h3 { font-size: 24px; font-weight: 700; }
.ai-package .feature-row-copy > p { font-size: 16px; line-height: 2; color: var(--color-text-muted); }
.ai-package .feature-row-media {
  flex: 0 0 auto;
  width: 640px;
  max-width: 640px;
  aspect-ratio: 421 / 276;
  background: #dddda;
  background-color: #dddad4;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ai-package .feature-row-media span { font-size: 24px; font-weight: 700; color: #fff; text-align: center; padding: 0 16px; }
.ai-package .feature-row-media.has-video {
  position: relative;
  width: 640px;
  max-width: 640px;
  aspect-ratio: auto;
  height: auto;
  background: #fff;
  border-radius: 8px;
  border: 1px solid #ddd;
  overflow: hidden;
}
.ai-package .feature-row-media.has-video video {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0;
}
.ai-package .video-replay-btn {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 72px;
  height: 72px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, background 0.2s ease;
}
.ai-package .video-replay-btn:hover { background: rgba(0, 0, 0, 0.72); }
.ai-package .video-replay-btn svg { width: 32px; height: 32px; margin-left: 4px; }
.ai-package .has-video.is-ended .video-replay-btn {
  opacity: 1;
  pointer-events: auto;
}

/* =========================================================
   FAQ（アコーディオン）
   ========================================================= */
.ai-package .faq-list { display: flex; flex-direction: column; gap: 12px; }

.ai-package .faq-item {
  background: #fff;
  border: 1px solid var(--color-border-light);
  border-radius: 12px;
  overflow: hidden;
}
.ai-package .faq-item + .faq-item { margin-top: 0; }

/* <summary> の既定の三角マーカーを消す */
.ai-package .faq-item > summary { list-style: none; }
.ai-package .faq-item > summary::-webkit-details-marker { display: none; }

.ai-package .faq-q {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text-default);
  letter-spacing: 0.01em;
  transition: background-color .15s ease;
}
.ai-package .faq-q:hover { background: var(--color-brand-accent-soft); }
.ai-package .faq-q-text { flex: 1 1 0; min-width: 0; }

.ai-package .faq-chev {
  width: 20px; height: 20px; flex-shrink: 0;
  color: var(--color-text-muted);
  transition: transform .2s ease;
}
.ai-package .faq-item[open] > .faq-q .faq-chev { transform: rotate(180deg); }

.ai-package .faq-a {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 0 20px 20px 20px;
  border-top: 1px solid var(--color-border-warm);
  padding-top: 16px;
}
.ai-package .faq-a p {
  flex: 1 1 0;
  min-width: 0;
  font-size: 16px;
  line-height: 1.8;
  color: var(--color-text-muted);
}

.ai-package .qa-badge {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  font-family: Roboto, var(--font-jp), sans-serif;
}
.ai-package .qa-badge-q { background: var(--color-brand-accent); color: #fff; }
.ai-package .qa-badge-a { background: var(--color-brand-accent-soft); color: var(--color-brand-accent); border: 1px solid var(--color-brand-accent); margin-top: 2px; }

/* =========================================================
   CTA
   ========================================================= */
.ai-package .cta {
  background: linear-gradient(115deg, #f28d00 30%, #ffb340 84%);
  padding: 40px 24px 0;
}
.ai-package .cta-inner {
  max-width: var(--content-width);
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  gap: 60px;
}
.ai-package .cta-media { flex: 0 0 auto; width: 340px; max-width: 40%; align-self: flex-end; }
.ai-package .cta-media img { display: block; width: 100%; height: auto; }
.ai-package .cta-copy { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 16px; align-self: center; padding-bottom: 40px; }
.ai-package .cta-copy h2 { font-size: 26px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.ai-package .cta-copy .btn { max-width: 360px; }

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 900px) {
  .ai-package .hero-inner { flex-direction: column; }
  .ai-package .hero-media { flex: none; width: 100%; max-width: 100%; }
  .ai-package .hero-copy h1 { font-size: 32px !important; }

  .ai-package .feature-row { flex-direction: column; }
  .ai-package .feature-row-media,
  .ai-package .feature-row-media.has-video { width: 100%; max-width: 100%; }

  .ai-package .cta-inner { flex-direction: column; align-items: center; text-align: center; }
  .ai-package .cta-copy { align-items: center; align-self: auto; padding-bottom: 0; }
  .ai-package .cta-media { width: 220px; align-self: auto; }
}

@media (max-width: 600px) {
  /* Figma「SP」フレーム（node 1602:178）に準拠 */
  .ai-package .page-container { padding: 0 16px; }

  .ai-package .hero { padding: 24px 16px; }
  .ai-package .hero-inner { gap: 24px; }
  .ai-package .hero-copy h1 { font-size: 24px !important; }
  .ai-package .hero-copy p { margin-top: 16px; font-size: 14px; }

  .ai-package .section-heading { font-size: 24px !important; padding: 4px 20px; margin-bottom: 24px !important; }
  .ai-package .lead-text { font-size: 14px; }

  /* 「いま利用できるAI機能」：SPでは個別のカード形式に
     （ピーチ色のヘッダー行＝アイコン＋機能名＋提供状況、白背景のボディ＝説明文＋提供予定日/月） */
  .ai-package .table-wrap { overflow-x: visible; border: none; border-radius: 0; }
  .ai-package .feature-table { min-width: 0; width: 100%; border-collapse: separate; border-spacing: 0 12px; }
  .ai-package .feature-table thead { display: none; }
  .ai-package .feature-table, .ai-package .feature-table tbody { display: block; width: 100%; }
  .ai-package .feature-table tbody tr {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    background: #fff;
    border: 1px solid var(--color-border-warm);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 12px;
  }
  .ai-package .feature-table tbody tr:last-child { margin-bottom: 0; }
  .ai-package .feature-table tbody td {
    display: block;
    border: none;
    padding: 0;
    font-size: 15px;
    box-sizing: border-box;
  }
  .ai-package .feature-table tbody td.cell-feature {
    order: 1;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: normal;
    background: var(--color-brand-accent-soft);
    border-bottom: 1px solid var(--color-border-warm);
    padding: 14px 8px 14px 16px;
  }
  .ai-package .feature-table tbody td.cell-feature .table-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #fff;
    padding: 6px;
    object-fit: contain;
  }
  .ai-package .feature-table tbody td.cell-feature span { font-size: 15px; font-weight: 700; }
  .ai-package .feature-table tbody td:nth-child(2) {
    order: 3;
    flex: 1 1 100%;
    width: 100%;
    padding: 16px;
    color: var(--color-text-muted);
  }
  .ai-package .feature-table tbody tr:has(.status-date) td:nth-child(2) { padding-bottom: 40px; }
  .ai-package .feature-table .col-status {
    order: 2;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    width: auto;
    text-align: right;
    background: var(--color-brand-accent-soft);
    border-bottom: 1px solid var(--color-border-warm);
    padding: 14px 16px 14px 8px;
  }
  .ai-package .status-date {
    display: inline-block;
    position: absolute;
    right: 16px;
    bottom: 14px;
    margin-top: 0;
    margin-left: 0;
    font-size: 12px;
    color: #737373;
  }
  .ai-package .date-label { display: inline; }

  .ai-package .feature-row { gap: 24px; padding-bottom: 24px; margin-bottom: 24px; }
  .ai-package .feature-row-icon { width: 50px; height: 50px; }
  .ai-package .feature-row-icon img { width: 50px; height: 50px; }
  .ai-package .feature-row-head h3 { font-size: 18px; }
  .ai-package .feature-row-copy > p { font-size: 14px; }
  .ai-package .feature-row-media span { font-size: 28px; }

  .ai-package .faq-q { font-size: 14px; padding: 16px; }
  .ai-package .faq-a { padding: 16px; padding-top: 12px; }
  .ai-package .faq-a p { font-size: 14px; }
}
