/* ============================================================
   ZenKanji Landing Page — Shared Styles
   ============================================================ */

/* -- CSS Custom Properties (language-specific overrides) -- */
:root {
  --font-body: "Noto Sans JP", "Inter", sans-serif;
  --font-zen: "Shippori Mincho", serif;
  --subtitle-letter-spacing: 0.3em;
  --catch-copy-font-weight: 500;
}

/* -- Reset -- */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: var(--font-body);
  background-color: #f5f0e8;
  background-image: url('assets/normal-washi.webp');
  background-size: cover;
  background-attachment: fixed;
  background-position: center;
  color: #3a2e1e;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.8;
  overflow-x: hidden;
}

/* 和風・明朝体を使用する要素 */
.zen-font {
  font-family: var(--font-zen);
}

/* ── ヘッダー ── */
.header {
  width: 100%;
  max-width: 800px;
  padding: 16px 24px;
  display: flex;
  justify-content: flex-end;
  position: absolute;
  top: 0;
  z-index: 10;
}

/* サブタイトル・キャッチコピーの視認性向上 */
.title-jp, .subtitle-jp, .catch-copy, .title-en {
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.9), 0 0 24px rgba(255, 255, 255, 0.5);
}

/* 言語切り替えボタン */
.lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  color: #3a2e1e;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 8px 16px;
  border: 1px solid rgba(139, 115, 85, 0.3);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}
.lang-switcher:hover {
  background: #8b7355;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(139, 115, 85, 0.2);
}
.lang-switcher svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ── メインコンテンツ ── */
main {
  flex: 1;
  width: 100%;
  max-width: 800px;
  padding: 60px 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 80px;
}

/* ── ヒーローセクション ── */
.hero {
  text-align: center;
  padding-top: 40px;
  animation: fadeIn 1.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.app-icon {
  width: 200px;
  height: auto;
  margin-bottom: 24px;
  filter: drop-shadow(0 12px 24px rgba(58, 46, 30, 0.15));
}
.title-jp {
  font-size: 3.5rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #3a2e1e;
  margin-bottom: 4px;
}
.subtitle-jp {
  font-size: 1.2rem;
  font-weight: 500;
  color: #5a4a32;
  letter-spacing: var(--subtitle-letter-spacing);
  margin-bottom: 12px;
}
.title-en {
  font-size: 1rem;
  font-weight: 400;
  color: #8b7355;
  letter-spacing: 0.15em;
  margin-bottom: 32px;
}
.catch-copy {
  font-size: 1.5rem;
  font-weight: var(--catch-copy-font-weight);
  color: #3a2e1e;
  margin-bottom: 48px;
}

/* ── ストアボタン ── */
.stores {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}
.store-badge {
  display: inline-block;
  transition: transform 0.3s ease, filter 0.3s ease;
}
.store-badge:hover {
  transform: translateY(-2px);
  filter: drop-shadow(0 4px 12px rgba(58, 46, 30, 0.2));
}
.store-badge img {
  height: 48px;
  width: auto;
  display: block;
}

/* ── セクション紹介（Feature カード） ── */
.feature {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
  padding: 56px 48px;
  background-image: url('assets/foreground-washi.webp');
  background-size: cover;
  background-position: center;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(58, 46, 30, 0.12), 0 0 0 1px rgba(139, 115, 85, 0.08);
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out, box-shadow 0.4s ease;
  position: relative;
}
.feature:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 24px 60px rgba(58, 46, 30, 0.16), 0 0 0 1px rgba(139, 115, 85, 0.12);
}
/* 和紙の端の装飾 */
.feature::before {
  content: '';
  position: absolute;
  top: 6px; left: 6px; right: 6px; bottom: 6px;
  border: 1px solid rgba(139, 115, 85, 0.1);
  pointer-events: none;
}
.feature.visible {
  opacity: 1;
  transform: translateY(0);
}
.feature.visible:hover {
  transform: translateY(-4px);
}

@media (min-width: 640px) {
  .feature {
    flex-direction: row;
    align-items: center;
    text-align: left;
  }
  .feature:nth-child(even) {
    flex-direction: row-reverse;
  }
}

img.feature-img {
  width: 100%;
  max-width: 220px;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(58, 46, 30, 0.25);
  transition: transform 0.4s ease;
}
.feature:hover img.feature-img {
  transform: scale(1.02);
}

.feature-text {
  flex: 1;
  text-align: center;
}
@media (min-width: 640px) {
  .feature-text {
    text-align: left;
    padding: 0 24px;
  }
}

.feature-title {
  font-size: 2rem;
  color: #3a2e1e;
  margin-bottom: 20px;
  line-height: 1.4;
}
.feature-desc {
  font-size: 1.05rem;
  color: #4a3e2a;
  line-height: 2;
}

/* ── 白毫の語りセクション ── */
.byakugo-speech {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 40px 36px;
  background-image: url('assets/foreground-washi.webp');
  background-size: cover;
  background-position: center;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(58, 46, 30, 0.12), 0 0 0 1px rgba(139, 115, 85, 0.08);
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
  position: relative;
}
.byakugo-speech::before {
  content: '';
  position: absolute;
  top: 6px; left: 6px; right: 6px; bottom: 6px;
  border: 1px solid rgba(139, 115, 85, 0.1);
  pointer-events: none;
}
.byakugo-speech.visible {
  opacity: 1;
  transform: translateY(0);
}
.byakugo-avatar {
  width: 100px;
  height: 100px;
  flex-shrink: 0;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(58, 46, 30, 0.15));
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-6px); }
}
.byakugo-dialogue {
  flex: 1;
}
.byakugo-name {
  font-size: 0.85rem;
  color: #8b7355;
  margin-bottom: 6px;
  letter-spacing: 0.1em;
}
.byakugo-text {
  font-size: 1.1rem;
  color: #3a2e1e;
  line-height: 2;
}
@media (max-width: 639px) {
  .byakugo-speech {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 32px 24px;
  }
  .byakugo-avatar {
    width: 80px;
    height: 80px;
  }
}

/* ── フッター ── */
.footer {
  width: 100%;
  text-align: center;
  padding: 60px 24px;
  margin-top: 40px;
  background: linear-gradient(to top, rgba(245, 240, 232, 0.9), transparent);
}
.social-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 32px;
}
.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(139, 115, 85, 0.3);
  background: rgba(255, 255, 255, 0.5);
  color: #8b7355;
  transition: all 0.3s ease;
}
.social-links a:hover {
  background: #8b7355;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 115, 85, 0.2);
}
.social-links a svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}
.links a {
  color: #8b7355;
  font-size: 0.95rem;
  text-decoration: none;
  margin: 0 16px;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: all 0.3s ease;
}
.links a:hover {
  color: #3a2e1e;
  border-bottom-color: #3a2e1e;
}
.copyright {
  margin-top: 32px;
  font-size: 0.85rem;
  color: #8b7355;
  letter-spacing: 0.05em;
}

/* ── アニメーション ── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); filter: blur(4px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}
