/* ============================================
   Loading Overlay
   ============================================ */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: #FFFBEB;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s, visibility 0.5s;
}
.loading-overlay.hidden {
  opacity: 0;
  visibility: hidden;
}
.loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #E5E7EB;
  border-top-color: #92400E;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================
   Form Thanks
   ============================================ */
.form-thanks {
  text-align: center;
  padding: 40px 20px;
}
.form-thanks svg {
  margin: 0 auto 16px;
  display: block;
}
.form-thanks-title {
  margin-bottom: 8px;
  color: #92400E;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 18px;
  font-weight: 700;
}
.form-thanks-text {
  color: #6B7280;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 14px;
  line-height: 1.8;
}

/* ============================================
   CSS変数
   ============================================ */
:root {
  --primary: #92400E;
  --primary-dark: #78350F;
  --primary-light: #FEF3C7;
  --accent: #F59E0B;
  --accent-light: #FDE68A;
  --bg: #FFFBEB;
  --bg-alt: #FFFFFF;
  --text: #1F2937;
  --text-muted: #6B7280;
  --border: #E5E7EB;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.1);
  --radius: 12px;
  --radius-lg: 20px;
  --text-hero: clamp(36px, 5vw, 56px);
  --text-h2: clamp(28px, 3.5vw, 40px);
  --text-h3: clamp(20px, 2.5vw, 24px);
  --text-body: 16px;
  --text-small: 14px;
  --text-caption: 12px;
  --space-section: clamp(80px, 10vw, 120px);
  --space-group: clamp(40px, 5vw, 64px);
  --space-element: clamp(16px, 2vw, 24px);
}

/* ============================================
   リセット・ベース
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Nunito', 'Noto Sans JP', sans-serif;
  color: var(--text);
  line-height: 1.7;
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  animation: fadeIn 0.5s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: 'Noto Sans JP', sans-serif; }

/* ============================================
   共通コンポーネント
   ============================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 80px);
}
.section { padding: var(--space-section) 0; }
.section:nth-child(odd) { background: var(--bg); }
.section:nth-child(even) { background: var(--bg-alt); }

.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll.visible { opacity: 1; transform: translateY(0); }
.animate-on-scroll.visible .stagger-item:nth-child(1) { transition-delay: 0s; }
.animate-on-scroll.visible .stagger-item:nth-child(2) { transition-delay: 0.1s; }
.animate-on-scroll.visible .stagger-item:nth-child(3) { transition-delay: 0.15s; }
.animate-on-scroll.visible .stagger-item:nth-child(4) { transition-delay: 0.2s; }
.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}
.animate-on-scroll.visible .stagger-item { opacity: 1; transform: translateY(0); }

.section-header { text-align: center; margin-bottom: var(--space-group); }
.section-label {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.section-title {
  font-size: var(--text-h2);
  font-weight: 800;
  line-height: 1.3;
  color: var(--primary);
  letter-spacing: -0.02em;
}
.section-subtitle {
  font-size: var(--text-body);
  color: var(--text-muted);
  margin-top: 16px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.8;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--primary);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  border: none;
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(146,64,14,0.3);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(146,64,14,0.4);
  filter: brightness(1.05);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  background: transparent;
  color: var(--primary);
  font-size: 15px;
  font-weight: 700;
  border: 2px solid var(--primary);
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.btn-secondary:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
}
.btn-full { width: 100%; }

/* Forms */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}
.form-input {
  width: 100%;
  padding: 12px 16px;
  font-size: 15px;
  border: 2px solid #E5E7EB;
  border-radius: var(--radius);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  background: #fff;
  color: var(--text);
}
.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(146,64,14,0.1);
}
.form-input::placeholder { color: #9CA3AF; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-note {
  font-size: var(--text-small);
  color: var(--text-muted);
  text-align: center;
  margin-top: 12px;
}
.required { font-size: 11px; color: #DC2626; margin-left: 4px; }

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
}
.back-to-top.show { opacity: 1; transform: translateY(0); }
.back-to-top:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

/* ============================================
   ヘッダー
   ============================================ */
header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  transition: background-color 0.3s, box-shadow 0.3s, backdrop-filter 0.3s;
}
header.scrolled {
  background: rgba(255,251,235,0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 80px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-icon {
  width: 40px;
  height: 40px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.logo-icon-sm {
  display: flex;
  align-items: center;
}
.logo-text {
  font-weight: 800;
  font-size: 20px;
  color: var(--primary);
  line-height: 1.2;
}
.logo-sub {
  display: block;
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
.desktop-nav { display: flex; align-items: center; gap: 24px; }
.nav-link {
  font-size: var(--text-small);
  font-weight: 600;
  color: var(--text);
  transition: color 0.2s;
}
.nav-link:hover { color: var(--primary); }
.header-cta {
  padding: 10px 24px;
  font-size: 13px;
}
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
}
.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: all 0.3s;
}

/* Mobile menu */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  z-index: 1000;
}
.overlay.open { opacity: 1; pointer-events: auto; }
.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 360px;
  height: 100vh;
  background: var(--bg);
  transition: right 0.3s ease;
  z-index: 1001;
  padding: 24px;
  display: flex;
  flex-direction: column;
}
.mobile-menu.open { right: 0; }
.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}
.mobile-close { background: none; border: none; color: var(--text); padding: 4px; }
.mobile-link {
  display: block;
  padding: 14px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}
.mobile-link:hover { color: var(--primary); }
.mobile-cta {
  margin-top: 24px;
  background: var(--primary);
  color: #fff;
  text-align: center;
  border-radius: 100px;
  border-bottom: none;
  padding: 14px;
}

/* ============================================
   ① Hero
   ============================================ */
.hero {
  padding-top: 120px;
  padding-bottom: 60px;
  background: var(--bg);
  overflow: hidden;
}
.hero-content {
  display: flex;
  align-items: center;
  gap: clamp(40px, 5vw, 80px);
}
.hero-text { flex: 1; }
.hero-title {
  font-size: var(--text-hero);
  font-weight: 800;
  color: var(--primary);
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.hero-desc {
  font-size: var(--text-body);
  color: var(--text-muted);
  line-height: 1.9;
  margin-bottom: 24px;
}
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 32px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--primary-light);
  border-radius: 100px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}
.hero-btn { font-size: 16px; padding: 16px 40px; }
.hero-image {
  flex: 0 0 420px;
  position: relative;
}
.hero-image img {
  border-radius: var(--radius-lg);
  aspect-ratio: 4/5;
  object-fit: cover;
  position: relative;
  z-index: 1;
}
.hero-image-accent {
  position: absolute;
  bottom: -20px;
  right: -20px;
  width: 200px;
  height: 200px;
  background: var(--accent-light);
  border-radius: 50%;
  z-index: 0;
}

/* ============================================
   ② Medical
   ============================================ */
.medical-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.medical-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  text-align: center;
  transition: transform 0.3s, box-shadow 0.3s;
}
.medical-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.medical-icon {
  width: 64px;
  height: 64px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}
.medical-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
}
.medical-cost {
  font-size: 14px;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 16px;
}
.medical-cost span {
  font-size: 28px;
  font-weight: 800;
}
.medical-desc {
  font-size: var(--text-small);
  color: var(--text-muted);
  line-height: 1.8;
}
.medical-source {
  text-align: center;
  font-size: var(--text-caption);
  color: var(--text-muted);
  margin-top: 24px;
}

/* ============================================
   ③ Plans
   ============================================ */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}
.plan-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  text-align: center;
  transition: transform 0.3s, box-shadow 0.3s;
  position: relative;
}
.plan-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.plan-recommended {
  border: 3px solid var(--primary);
  transform: scale(1.05);
  box-shadow: var(--shadow-md);
}
.plan-recommended:hover {
  transform: scale(1.05) translateY(-4px);
}
.plan-badge-tag {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 20px;
  border-radius: 100px;
}
.plan-header h3 {
  font-size: 20px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 4px;
}
.plan-rate {
  font-size: var(--text-small);
  color: var(--text-muted);
}
.plan-rate strong {
  font-size: 20px;
  color: var(--primary);
}
.plan-price {
  font-size: 14px;
  color: var(--text);
  margin: 20px 0;
  padding: 16px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.plan-price span {
  font-size: 36px;
  font-weight: 800;
  color: var(--primary);
}
.plan-features {
  list-style: none;
  text-align: left;
  margin: 24px 0;
}
.plan-features li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--text-small);
  padding: 8px 0;
  color: var(--text);
}
.plan-card .btn-primary,
.plan-card .btn-secondary {
  width: 100%;
}

/* ============================================
   ④ Claim
   ============================================ */
.claim-steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  max-width: 900px;
  margin: 0 auto;
}
.claim-step {
  flex: 1;
  text-align: center;
  padding: 0 16px;
}
.claim-step-num {
  width: 32px;
  height: 32px;
  background: var(--accent-light);
  color: var(--primary);
  font-size: 14px;
  font-weight: 800;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.claim-step-icon {
  width: 80px;
  height: 80px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}
.claim-step h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.claim-step p {
  font-size: var(--text-small);
  color: var(--text-muted);
  line-height: 1.7;
}
.claim-arrow {
  display: flex;
  align-items: center;
  padding-top: 70px;
}

/* ============================================
   ⑤ Voices
   ============================================ */
.voices-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.voice-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
}
.voice-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.voice-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.voice-header img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-light);
}
.voice-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.voice-meta {
  font-size: 12px;
  color: var(--text-muted);
}
.voice-stars {
  display: flex;
  gap: 2px;
  margin-bottom: 12px;
}
.voice-text {
  font-size: var(--text-small);
  color: var(--text-muted);
  line-height: 1.8;
}

/* ============================================
   ⑥ Pets
   ============================================ */
.pets-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  justify-items: center;
}
.pet-card {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s, box-shadow 0.3s;
}
.pet-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.pet-img-wrap {
  aspect-ratio: 16/10;
  overflow: hidden;
}
.pet-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}
.pet-card:hover .pet-img-wrap img {
  transform: scale(1.05);
}
.pet-card h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
  padding: 20px 24px 8px;
}
.pet-card p {
  font-size: var(--text-small);
  color: var(--text-muted);
  line-height: 1.7;
  padding: 0 24px;
}
.pet-age {
  display: block;
  font-size: var(--text-caption);
  color: var(--accent);
  font-weight: 700;
  padding: 12px 24px 24px;
}

/* ============================================
   ⑦ Quote
   ============================================ */
.quote { background: var(--primary) !important; }
.quote .section-label { color: var(--accent-light); }
.quote .section-title { color: #fff; text-align: left; }
.quote-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 5vw, 80px);
  align-items: start;
}
.quote-desc {
  font-size: var(--text-body);
  color: rgba(255,255,255,0.7);
  line-height: 1.8;
  margin-top: 20px;
}
.quote-trust {
  display: flex;
  gap: 40px;
  margin-top: 32px;
}
.quote-trust-item { text-align: left; }
.quote-trust-num {
  display: block;
  font-size: 32px;
  font-weight: 800;
  color: var(--accent-light);
  line-height: 1.2;
}
.quote-trust-label {
  font-size: var(--text-small);
  color: rgba(255,255,255,0.6);
}
.quote-form-wrap {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

/* ============================================
   ⑧ FAQ
   ============================================ */
.faq-list {
  max-width: 720px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  background: none;
  border: none;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  gap: 16px;
}
.faq-question:hover { color: var(--primary); }
.faq-icon {
  flex-shrink: 0;
  transition: transform 0.3s;
}
.faq-item.open .faq-icon {
  transform: rotate(180deg);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}
.faq-item.open .faq-answer {
  max-height: 300px;
}
.faq-answer p {
  padding-bottom: 20px;
  font-size: var(--text-small);
  color: var(--text-muted);
  line-height: 1.8;
}

/* ============================================
   フッター
   ============================================ */
footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.8);
  padding: 60px 0 0;
}
.footer-main {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.footer-logo .logo-text { color: #fff; }
.footer-desc {
  font-size: var(--text-small);
  color: rgba(255,255,255,0.6);
  line-height: 1.8;
  margin-bottom: 20px;
}
.footer-social { display: flex; gap: 12px; }
.footer-social a {
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.7);
  transition: background 0.2s, color 0.2s;
}
.footer-social a:hover { background: var(--accent); color: #fff; }
.footer-nav h4 {
  font-size: var(--text-small);
  font-weight: 700;
  color: #fff;
  margin-bottom: 16px;
}
.footer-nav a {
  display: block;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  padding: 6px 0;
  transition: color 0.2s;
}
.footer-nav a:hover { color: var(--accent-light); }
.footer-hours {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  margin-top: 8px;
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0;
  font-size: var(--text-caption);
  color: rgba(255,255,255,0.4);
}
.footer-links { display: flex; gap: 24px; }
.footer-links a { color: rgba(255,255,255,0.4); transition: color 0.2s; }
.footer-links a:hover { color: rgba(255,255,255,0.8); }

/* ============================================
   レスポンシブ
   ============================================ */
@media (max-width: 1024px) {
  .hero-content { flex-direction: column; text-align: center; }
  .hero-badges { justify-content: center; }
  .hero-image { flex: 0 0 auto; max-width: 400px; }
  .plan-recommended { transform: scale(1); }
  .plan-recommended:hover { transform: translateY(-4px); }
}

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

  .hero { padding-top: 100px; }
  .section-title br { display: none; }

  .medical-grid { grid-template-columns: 1fr; }
  .plans-grid { grid-template-columns: 1fr; max-width: 400px; margin: 0 auto; }
  .claim-steps { flex-direction: column; gap: 24px; }
  .claim-arrow { transform: rotate(90deg); padding-top: 0; justify-content: center; }
  .voices-grid { grid-template-columns: 1fr; }
  .pets-grid { grid-template-columns: 1fr; }
  .quote-wrapper { grid-template-columns: 1fr; }
  .quote .section-title { text-align: center; }
  .quote-trust { justify-content: center; }
  .footer-main { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .form-row { grid-template-columns: 1fr; }
}

@media (max-width: 375px) {
  .quote-form-wrap { padding: 24px 20px; }
  .plan-card { padding: 24px; }
}
