/* ============ TOPIK暗記 landing page ============ */

:root {
  --orange: #FF8A3D;
  --orange-light: #FFB376;
  --orange-dark: #E5701F;
  --cream: #FFF8EE;
  --cream-2: #FFF1DC;
  --ink: #1E2A39;
  --ink-soft: #4a5868;
  --white: #ffffff;
  --line: #efe2cf;
  --shadow: 0 18px 50px rgba(30, 42, 57, 0.14);
  --shadow-sm: 0 6px 20px rgba(30, 42, 57, 0.10);
  --radius: 18px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
          "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Noto Sans JP", sans-serif;
}

/* hide content until JS swaps language on ?lang=ja (head sets the class) */
.i18n-pending body { visibility: hidden; }

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--orange-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.container-narrow { max-width: 760px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 0 0 10px 0; z-index: 100;
}
.skip-link:focus { left: 0; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 248, 238, 0.85);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 18px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; }
.brand:hover { text-decoration: none; }
.brand-mark { border-radius: 8px; }
.brand-name { font-size: 1.12rem; }
.site-nav { display: flex; gap: 24px; margin-left: auto; }
.site-nav a { color: var(--ink-soft); font-weight: 600; font-size: 0.95rem; }
.site-nav a:hover { color: var(--orange-dark); text-decoration: none; }

.lang-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; background: #fff; }
.site-nav + .lang-switch { margin-left: 4px; }
.header-inner .lang-switch { margin-left: auto; }
.site-nav ~ .lang-switch { margin-left: 4px; }
.lang-btn {
  font: inherit; font-size: 0.85rem; font-weight: 700; cursor: pointer;
  border: 0; background: transparent; color: var(--ink-soft);
  padding: 7px 14px; line-height: 1;
}
.lang-btn[aria-pressed="true"] { background: var(--orange); color: #fff; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1100px 480px at 78% -8%, rgba(255, 179, 118, 0.45), transparent 60%),
    radial-gradient(900px 420px at 8% 4%, rgba(255, 138, 61, 0.18), transparent 55%);
  padding: 64px 0 56px;
}
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 40px; align-items: center; }
.eyebrow { color: var(--orange-dark); font-weight: 800; font-size: 0.92rem; letter-spacing: 0.02em; text-transform: uppercase; margin-bottom: 14px; }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.2rem); font-weight: 850; margin-bottom: 18px; }
.lede { font-size: clamp(1.02rem, 1.6vw, 1.18rem); color: var(--ink-soft); max-width: 38ch; }
.hero .lede { margin-bottom: 26px; }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.store-badge {
  display: inline-flex; align-items: center; gap: 12px;
  background: var(--ink); color: #fff; border-radius: 14px;
  padding: 10px 18px; min-width: 180px; box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.store-badge:hover { text-decoration: none; transform: translateY(-2px); }
.store-badge svg { width: 26px; height: 26px; flex: none; }
.store-badge span { display: flex; flex-direction: column; line-height: 1.15; }
.store-badge small { font-size: 0.68rem; opacity: 0.85; font-weight: 500; }
.store-badge strong { font-size: 1.12rem; font-weight: 700; }
.store-badge.is-soon { opacity: 0.55; cursor: default; }
.store-badge.is-soon:hover { transform: none; }
.cta-note { margin-top: 14px; font-size: 0.9rem; color: var(--ink-soft); }

.hero-art { display: flex; justify-content: center; }

/* ---------- Phone mockup ---------- */
.phone {
  background: var(--ink); border-radius: 38px; padding: 10px;
  box-shadow: var(--shadow); position: relative;
}
.phone::before {
  content: ""; position: absolute; top: 16px; left: 50%; transform: translateX(-50%);
  width: 96px; height: 6px; background: rgba(255, 255, 255, 0.35); border-radius: 999px; z-index: 2;
}
.phone img { border-radius: 30px; }
.phone-sm { border-radius: 32px; padding: 8px; }
.phone-sm img { border-radius: 26px; }

/* ---------- Trust strip ---------- */
.trust { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: #fff; }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding: 28px 22px; text-align: center; }
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-n { font-size: clamp(1.3rem, 2.6vw, 1.7rem); font-weight: 850; color: var(--orange-dark); }
.stat-l { font-size: 0.9rem; color: var(--ink-soft); }

/* ---------- Sections ---------- */
.section { padding: 72px 0; }
.section-alt { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-title { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 800; text-align: center; max-width: 22ch; margin: 0 auto 44px; }

/* ---------- Features ---------- */
.feature-list { display: flex; flex-direction: column; gap: 56px; }
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.feature.reverse .feature-text { order: 2; }
.feature-text h3 { font-size: 1.5rem; font-weight: 800; margin-bottom: 12px; }
.feature-text p { color: var(--ink-soft); font-size: 1.05rem; max-width: 46ch; }
.feature-art { display: flex; justify-content: center; }

.tag {
  display: inline-block; background: var(--cream-2); color: var(--orange-dark);
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px; margin-bottom: 12px;
}

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; list-style: none; }
.step { background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 24px; }
.step-n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 12px; margin-bottom: 14px;
  background: var(--orange); color: #fff; font-weight: 800; font-size: 1.1rem;
}
.step h3 { font-size: 1.2rem; margin-bottom: 8px; }
.step p { color: var(--ink-soft); }

/* ---------- Premium ---------- */
.premium-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px; align-items: center; }
.premium-copy h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 800; margin-bottom: 14px; }
.premium-copy .lede { margin-bottom: 22px; }
.checklist { list-style: none; display: grid; gap: 12px; }
.checklist li { position: relative; padding-left: 32px; font-size: 1.04rem; }
.checklist li::before {
  content: "✓"; position: absolute; left: 0; top: 1px;
  width: 22px; height: 22px; border-radius: 999px;
  background: var(--orange); color: #fff; font-size: 0.8rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.premium-art { display: flex; justify-content: center; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; }
.faq details {
  background: var(--cream); border: 1px solid var(--line); border-radius: 14px; padding: 4px 20px;
}
.section-alt .faq details { background: var(--cream); }
.faq summary {
  cursor: pointer; font-weight: 700; font-size: 1.06rem; padding: 16px 0; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--orange-dark); font-size: 1.5rem; font-weight: 700; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--ink-soft); padding: 0 0 18px; }

/* ---------- Privacy ---------- */
.privacy { text-align: center; }
.privacy-text { color: var(--ink-soft); font-size: 1.08rem; max-width: 60ch; margin: 0 auto 18px; }
.link-arrow { font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #cfd8e3; padding: 40px 0 26px; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; }
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { border-radius: 7px; }
.footer-name { color: #fff; font-weight: 800; }
.footer-tag { font-size: 0.88rem; color: #9fb0c2; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a { color: #cfd8e3; font-weight: 600; font-size: 0.95rem; }
.footer-links a:hover { color: #fff; }
.footer-lang { background: transparent; border-color: #34465a; }
.footer-lang .lang-btn { color: #9fb0c2; }
.footer-lang .lang-btn[aria-pressed="true"] { background: var(--orange); color: #fff; }
.copyright { text-align: center; color: #7e90a4; font-size: 0.85rem; margin-top: 28px; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .site-nav { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; text-align: center; }
  .hero .lede { margin-left: auto; margin-right: auto; }
  .cta-row { justify-content: center; }
  .feature { grid-template-columns: 1fr; gap: 24px; text-align: center; }
  .feature.reverse .feature-text { order: 0; }
  .feature-text p { margin-left: auto; margin-right: auto; }
  .steps { grid-template-columns: 1fr; }
  .premium-grid { grid-template-columns: 1fr; gap: 30px; text-align: center; }
  .checklist { max-width: 320px; margin: 0 auto; text-align: left; }
  .footer-inner { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .trust-grid { grid-template-columns: repeat(2, 1fr); gap: 22px 12px; }
  .store-badge { min-width: 0; flex: 1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .store-badge { transition: none; }
}
