/* ═══════════════════════════════════════════════
   RoomAI - メインスタイルシート
   ═══════════════════════════════════════════════ */

:root {
  --primary:      #2C5F8A;
  --primary-dark: #1A3A5C;
  --accent:       #E8934A;
  --accent-dark:  #d4803a;
  --green:        #2E7D52;
  --navy:         #1a1a2e;
  --navy-light:   #0f3460;
  --bg:           #FAFAFA;
  --bg-gray:      #F4F4F4;
  --text:         #222222;
  --text-sub:     #666666;
  --border:       #E0E0E0;
  --radius:       12px;
  --shadow:       0 4px 20px rgba(0,0,0,0.08);
  --shadow-lg:    0 8px 40px rgba(0,0,0,0.12);
  --font:         'Noto Sans JP', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.7; word-break: auto-phrase; overflow-wrap: break-word; }
a { color: var(--primary); text-decoration: none; }
img { max-width: 100%; height: auto; }

/* ─── Typography ─────────────────────────────── */
h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 700; line-height: 1.3; word-break: keep-all; overflow-wrap: anywhere; }
h2 { font-size: clamp(1.3rem, 3vw, 1.8rem); font-weight: 700; word-break: keep-all; overflow-wrap: anywhere; }
h3 { font-size: 1.1rem; font-weight: 700; word-break: keep-all; overflow-wrap: anywhere; }

/* ─── Layout ──────────────────────────────────── */
.container    { max-width: 1000px; margin: 0 auto; padding: 0 1.5rem; }
.page-container { max-width: 720px; margin: 0 auto; padding: 2rem 1.5rem 4rem; }
.text-center  { text-align: center; }
.hidden       { display: none !important; }

/* ─── Header ─────────────────────────────────── */
.site-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.9rem 1.5rem;
  background: white;
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.site-header nav { display: flex; align-items: center; gap: 1.2rem; }
.pc-nav { display: flex; align-items: center; gap: 1.2rem; }
.nav-link {
  font-size: 0.9rem; font-weight: 500; color: var(--text-sub);
  text-decoration: none; transition: color .15s;
}
.nav-link:hover { color: var(--primary); }

/* ─── Hamburger Button ─────────────────────── */
.hamburger-btn {
  display: none; flex-direction: column; justify-content: center;
  gap: 5px; background: none; border: none; cursor: pointer;
  padding: 6px; width: 36px; height: 36px;
}
.hamburger-btn span {
  display: block; width: 22px; height: 2px;
  background: var(--primary); border-radius: 2px;
  transition: all .25s ease;
}
.hamburger-btn.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-btn.is-open span:nth-child(2) { opacity: 0; }
.hamburger-btn.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ─── Mobile Menu ──────────────────────────── */
.mobile-menu {
  display: none; position: fixed; top: 0; right: 0; bottom: 0;
  width: 260px; background: var(--primary-dark);
  box-shadow: -4px 0 24px rgba(0,0,0,0.3);
  z-index: 200; flex-direction: column; padding: 1.5rem 0 1.5rem;
  transform: translateX(100%);
  transition: transform .25s ease;
  pointer-events: none;
}
.mobile-menu.is-open {
  transform: translateX(0); pointer-events: auto;
}
.mobile-menu-link {
  display: block; padding: 1rem 1.5rem;
  font-size: 1rem; font-weight: 500; color: rgba(255,255,255,0.85);
  text-decoration: none; border-bottom: 1px solid rgba(255,255,255,0.1);
  transition: background .15s, color .15s;
}
.mobile-menu-link:last-of-type { border-bottom: none; }
.mobile-menu-link:hover { background: rgba(255,255,255,0.08); color: white; }
.mobile-menu-cta-wrap {
  margin-top: auto; padding: 1.5rem;
}
.mobile-menu-cta {
  display: block; text-align: center;
  background: white; color: var(--primary) !important;
  font-weight: 800; font-size: 1rem;
  padding: 0.9rem 1rem; border-radius: 8px;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  transition: transform .15s, box-shadow .15s;
}
.mobile-menu-cta:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(0,0,0,0.3); }
.mobile-menu-overlay {
  display: none; position: fixed; inset: 0; z-index: 199;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.mobile-menu-overlay.is-open { display: block; }

@media (max-width: 768px) {
  .site-header .pc-nav { display: none; }
  .hamburger-btn { display: flex; }
  .mobile-menu { display: flex; }
}

.logo { font-size: 1.3rem; font-weight: 700; color: var(--primary); display: flex; align-items: center; gap: 6px; text-decoration: none; }
.beta-badge {
  font-size: 10px; font-weight: 800; letter-spacing: .05em;
  background: rgba(100,100,100,.12);
  color: var(--text-sub); padding: 2px 7px; border-radius: 99px;
  vertical-align: middle; line-height: 1.4;
}
.header-badge { margin: 0; flex-shrink: 0; }
@media (max-width: 480px) { .header-badge { display: none; } }

/* ─── Footer ─────────────────────────────────── */
.site-footer {
  text-align: center; padding: 2.5rem 1.5rem; margin-top: 4rem;
  background: #f8f9fb;
  border-top: none;
  color: var(--text-sub); font-size: 0.85rem;
  position: relative;
}
.site-footer::before {
  content: '';
  display: block;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  position: absolute; top: 0; left: 8%; right: 8%;
}
.footer-links {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 0.3rem 1.4rem;
  margin-bottom: 0.8rem; font-size: 0.82rem;
}
.footer-links a { color: var(--text-sub); transition: color .15s; }
.footer-links a:hover { color: var(--primary); }
.footer-copy { font-size: 0.8rem; color: #aaa; margin-top: 0.2rem; }

/* ─── Buttons ────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.7rem 1.4rem; border-radius: 8px; font-weight: 600;
  font-family: var(--font); font-size: 0.95rem; cursor: pointer;
  border: 2px solid transparent; transition: all 0.2s; white-space: nowrap;
}
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-primary  { background: var(--primary); color: white; }
.btn-primary:hover:not(:disabled) { background: var(--primary-dark); transform: translateY(-1px); }

/* ヘッダーCTA・CTAセクションはオレンジに統一 */
.site-header .btn-primary {
  background: var(--accent); border-color: transparent;
  box-shadow: 0 2px 12px rgba(232,147,74,.3);
}
.site-header .btn-primary:hover:not(:disabled) {
  background: #d4803a; box-shadow: 0 4px 16px rgba(232,147,74,.5); transform: translateY(-1px);
}
.section-cta .btn-primary {
  background: var(--accent); border-color: transparent;
  box-shadow: 0 4px 20px rgba(232,147,74,.5);
}
.section-cta .btn-primary:hover:not(:disabled) {
  background: #d4803a; box-shadow: 0 6px 28px rgba(232,147,74,.65); transform: translateY(-2px);
}
.btn-outline  { background: white; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: #EBF3FB; }
.btn-lg       { padding: 0.9rem 2rem; font-size: 1.05rem; }
.btn-sm       { padding: 0.45rem 0.9rem; font-size: 0.85rem; }
.btn-full     { width: 100%; }
.btn-share-x  { background: #000; color: white; border-radius: 8px; padding: 0.6rem 1.2rem; border: none; cursor: pointer; font-weight: 600; font-family: var(--font); }
.btn-share-line { background: #06C755; color: white; border-radius: 8px; padding: 0.6rem 1.2rem; border: none; cursor: pointer; font-weight: 600; font-family: var(--font); }

/* ─── Hero ───────────────────────────────────── */
.hero {
  display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center;
  max-width: 1100px; margin: 0 auto; padding: 5rem 1.5rem;
}
.hero.hero-single {
  grid-template-columns: 1fr; text-align: center;
  max-width: 720px; padding: 5rem 1.5rem;
}
.hero.hero-single .hero-inner { margin: 0 auto; }
.hero-badge {
  display: inline-block; background: #FEF3E8; color: var(--accent);
  padding: 0.3rem 0.9rem; border-radius: 20px; font-size: 0.85rem; font-weight: 600; margin-bottom: 1rem;
}
.hero h1 { margin-bottom: 1rem; }
.hero-sub { color: var(--text-sub); margin-bottom: 1.5rem; font-size: 1rem; }
.hero-note { margin-top: 0.8rem; font-size: 0.82rem; color: var(--text-sub); }
.hero-visual { display: flex; justify-content: center; }
.hero-card {
  background: white; border-radius: var(--radius); padding: 2rem;
  box-shadow: var(--shadow-lg); text-align: center; min-width: 240px;
}
.hero-card p { margin: 0.5rem 0; color: var(--text-sub); }
.hero-badge-style { font-size: 1.1rem; margin-bottom: 1rem; }

/* ─── Section ────────────────────────────────── */
.section { padding: 5rem 0; }
.section-gray { background: var(--bg-gray); }
.section-cta  { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: white; }
.section-cta h2, .section-cta p { color: white; }
.section-cta p { margin: 0.8rem 0 1.5rem; opacity: 0.9; }
.section-title {
  text-align: center; margin-bottom: 3rem;
  position: relative; padding-bottom: 1.1rem;
}
.section-title::after {
  content: '';
  position: absolute; bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 36px; height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 99px;
}

/* ─── Steps ──────────────────────────────────── */
.steps { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.step  { text-align: center; max-width: 190px; }
.step-icon {
  font-size: 1.8rem;
  display: flex; align-items: center; justify-content: center;
  width: 72px; height: 72px;
  background: linear-gradient(135deg, #EBF3FB, #FEF8F0);
  border: 2px solid rgba(44, 95, 138, 0.1);
  border-radius: 50%;
  margin: 0 auto 0.8rem;
  box-shadow: 0 2px 10px rgba(44, 95, 138, 0.08);
  transition: transform .2s, box-shadow .2s;
}
.step:hover .step-icon {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(44, 95, 138, 0.14);
}
.step h3 { margin-bottom: 0.4rem; }
.step p { font-size: 0.88rem; color: var(--text-sub); }
.step-arrow { font-size: 1.4rem; color: var(--accent); opacity: 0.65; }

/* ─── Features ───────────────────────────────── */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.5rem; }
.feature-card {
  background: white; border-radius: var(--radius); padding: 1.8rem 1.5rem;
  box-shadow: var(--shadow); text-align: center;
  border: 1px solid transparent;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(44, 95, 138, 0.1);
}
.feature-icon {
  font-size: 2rem;
  display: flex; align-items: center; justify-content: center;
  width: 56px; height: 56px;
  background: linear-gradient(135deg, #EBF3FB, #FEF8F0);
  border-radius: 14px;
  margin: 0 auto 1rem;
}
.feature-card h3 { margin-bottom: 0.5rem; }
.feature-card p { font-size: 0.88rem; color: var(--text-sub); }

/* ─── Page Header ─────────────────────────────── */
.page-header { text-align: center; margin-bottom: 2rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.page-header p { color: var(--text-sub); margin-top: 0.5rem; }

/* ─── Guide Card ─────────────────────────────── */
.guide-card {
  background: #FFF8F0; border: 1px solid #FDDBB4; border-radius: var(--radius);
  padding: 1.2rem 1.5rem; margin-bottom: 1.5rem;
}
.guide-card h3 { margin-bottom: 0.8rem; }
.guide-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.guide-item ul { padding-left: 1.2rem; }
.guide-item li { font-size: 0.88rem; margin: 0.3rem 0; }
.guide-label { display: inline-block; padding: 0.2rem 0.7rem; border-radius: 4px; font-size: 0.8rem; font-weight: 700; margin-bottom: 0.5rem; }
.guide-label.ok { background: #E8F5EE; color: var(--green); }
.guide-label.ng { background: #FEE; color: #C0392B; }

/* ─── Upload Area ────────────────────────────── */
.upload-area {
  border: 2px dashed var(--border); border-radius: var(--radius);
  padding: 2.5rem; text-align: center; transition: all 0.2s; cursor: pointer;
  background: white; margin-bottom: 1.5rem;
}
.upload-area.drag-over { border-color: var(--primary); background: #EBF3FB; }
.upload-icon { font-size: 3rem; display: block; margin-bottom: 0.8rem; }
.upload-text { color: var(--text-sub); margin-bottom: 1rem; line-height: 1.5; }
.upload-note { font-size: 0.8rem; color: #999; margin-top: 0.8rem; }
.upload-placeholder .btn { margin: 0 0.3rem; }
.upload-preview img { max-height: 300px; border-radius: 8px; object-fit: cover; }
.preview-actions { margin-top: 0.8rem; }
.preview-name { font-size: 0.85rem; color: var(--text-sub); margin-bottom: 0.5rem; }
.upload-actions { text-align: center; }
.error-msg { background: #FEE; border: 1px solid #F5C6C6; color: #C0392B; padding: 0.8rem 1rem; border-radius: 8px; margin-bottom: 1rem; font-size: 0.9rem; }

/* ─── Analyzing ──────────────────────────────── */
.analyzing-box { max-width: 480px; margin: 4rem auto; text-align: center; }
.analyzing-animation { display: flex; justify-content: center; gap: 0.6rem; margin-bottom: 1.5rem; }
.pulse-dot {
  width: 14px; height: 14px; border-radius: 50%; background: var(--primary);
  animation: pulse 1.2s ease-in-out infinite;
}
.pulse-dot:nth-child(2) { animation-delay: 0.2s; }
.pulse-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes pulse { 0%,100% { transform: scale(0.8); opacity: 0.5; } 50% { transform: scale(1.2); opacity: 1; } }
.analyzing-sub { color: var(--text-sub); margin: 0.8rem 0 1.5rem; }
.progress-bar { background: var(--border); border-radius: 4px; height: 6px; overflow: hidden; margin: 1.5rem 0; }
.progress-fill { height: 100%; background: var(--primary); border-radius: 4px; width: 0; transition: width 0.8s ease; }
.analyzing-steps { text-align: left; margin: 1.5rem 0; }
.astep { padding: 0.5rem 0.8rem; border-radius: 6px; font-size: 0.9rem; color: #999; margin: 0.3rem 0; }
.astep.active { color: var(--text); background: var(--bg-gray); }
.analyzing-note { font-size: 0.82rem; color: #999; margin-top: 1.5rem; }

/* ─── Report Sections ────────────────────────── */
.report-section { background: white; border-radius: var(--radius); padding: 1.8rem; margin-bottom: 1.5rem; box-shadow: var(--shadow); }
.report-section h2 { font-size: 1.2rem; margin-bottom: 1rem; color: var(--primary); }
.report-section h3 { font-size: 1rem; margin: 1rem 0 0.5rem; }

/* スタイルバッジ */
.style-badge {
  display: inline-block; background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white; padding: 0.5rem 1.5rem; border-radius: 20px; font-weight: 700;
  font-size: 1.1rem; margin: 0.5rem 0 1rem;
}
.style-comment { color: var(--text-sub); font-size: 0.92rem; }

/* スコアバー */
.score-row { display: flex; align-items: center; gap: 0.8rem; margin: 0.6rem 0; }
.score-label { font-size: 0.85rem; min-width: 80px; color: var(--text-sub); }
.score-bar { flex: 1; background: var(--border); border-radius: 4px; height: 8px; overflow: hidden; }
.score-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 4px; width: 0; }
.score-value { font-size: 0.85rem; font-weight: 600; min-width: 40px; text-align: right; }

/* 良い点 */
.strength-item { padding: 0.5rem 0; border-bottom: 1px solid var(--border); font-size: 0.92rem; }
.strength-item.blurred { filter: blur(4px); user-select: none; color: #aaa; }
.strengths-preview h3 { color: var(--green); }

/* ぼかしオーバーレイ */
.blur-overlay {
  background: linear-gradient(to bottom, transparent, white 40%);
  padding: 3rem 1.5rem 2rem; text-align: center; margin-top: -2rem;
  border-radius: 0 0 var(--radius) var(--radius);
}
.blur-message p { color: var(--text-sub); font-size: 0.9rem; }

/* ─── Purchase Section ───────────────────────── */
.purchase-section { margin: 2rem 0; }
.purchase-card {
  background: linear-gradient(135deg, #EBF3FB, white);
  border: 2px solid var(--primary); border-radius: var(--radius); padding: 2rem; text-align: center;
  box-shadow: var(--shadow-lg);
}
.purchase-card h2 { margin-bottom: 1rem; }
.purchase-features { list-style: none; text-align: left; display: inline-block; margin: 1rem auto; }
.purchase-features li { padding: 0.3rem 0; font-size: 0.92rem; }
.price-display { margin: 1.5rem 0; }
.price-label { font-size: 0.85rem; color: var(--text-sub); display: block; }
.price-value { font-size: 2.2rem; font-weight: 700; color: var(--primary); }
.price-note  { font-size: 0.82rem; color: var(--text-sub); }
.purchase-note { margin-top: 0.8rem; font-size: 0.78rem; color: #999; }

/* ─── Products ───────────────────────────────── */
.products-section { margin: 2rem 0; }
.products-section h2 { margin-bottom: 0.5rem; }
.products-note { color: var(--text-sub); font-size: 0.88rem; margin-bottom: 1.2rem; }
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1rem; }
.product-card {
  background: white; border: 1px solid var(--border); border-radius: 10px;
  overflow: hidden; transition: all 0.2s; display: block; color: var(--text);
}
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.product-card img { width: 100%; height: 150px; object-fit: cover; }
.product-info { padding: 0.8rem; }
.product-name { font-size: 0.82rem; line-height: 1.4; margin-bottom: 0.5rem; }
.product-footer { display: flex; justify-content: space-between; align-items: center; }
.product-price { font-weight: 700; color: var(--accent); font-size: 0.92rem; }
.product-shop { font-size: 0.75rem; background: var(--bg-gray); padding: 0.15rem 0.5rem; border-radius: 4px; }

/* ─── Share Section ──────────────────────────── */
.share-section { text-align: center; padding: 1.5rem; background: var(--bg-gray); border-radius: var(--radius); margin: 1.5rem 0; }
.share-section p { margin-bottom: 0.8rem; font-size: 0.9rem; color: var(--text-sub); }
.share-buttons { display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }
.report-share h3 { margin-bottom: 0.5rem; }

/* ─── Loading Placeholder ────────────────────── */
.loading-placeholder { text-align: center; padding: 3rem; color: var(--text-sub); }

/* ─── Responsive ─────────────────────────────── */
@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; padding: 3rem 1.5rem; text-align: center; }
  .hero-visual { margin-top: 1.5rem; }
  .steps { flex-direction: column; gap: 0.5rem; }
  .step-arrow { transform: rotate(90deg); font-size: 1.1rem; }
  .step-icon { width: 60px; height: 60px; font-size: 1.6rem; }
  .guide-grid { grid-template-columns: 1fr; }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-links { gap: 0.3rem 1rem; }
}
