/* Lumimo website
   Direction: the app's own two moods. A night sky (the logo) opens the page, then it
   turns to the warm cream-and-violet of the app screens. No JavaScript anywhere. */

@font-face {
  font-family: "Fredoka One";
  src: url("fonts/fredoka-one.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  /* colour */
  --night-deep: #0b1038;
  --night: #141b57;
  --mist: #c9d0ff;
  --violet: #5a34c8;
  --violet-deep: #43249f;
  --gold: #f7b733;
  --cream: #fff3e3;
  --lilac: #ece6fb;
  --ink: #1f1750;
  --ink-soft: #4b4180;
  --line: rgba(90, 52, 200, 0.28);

  /* type */
  --display: "Fredoka One", "Hiragino Maru Gothic ProN", "Yu Gothic UI", "Meiryo", "Noto Sans JP", "Noto Sans CJK JP", system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Hiragino Sans", "Yu Gothic UI", "Noto Sans JP", "Noto Sans CJK JP", sans-serif;

  /* layout */
  --gutter: max(20px, env(safe-area-inset-left, 0px));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px));
  --wrap: 1120px;
  --focus: var(--violet);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color-scheme: light;
}
html[lang="ja"] body { line-height: 1.85; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--violet); }
h1, h2, h3 {
  font-family: var(--display);
  font-weight: 400;
  font-synthesis: none;
  line-height: 1.12;
  margin: 0;
  text-wrap: balance;
}
html[lang="ja"] h1, html[lang="ja"] h2, html[lang="ja"] h3, html[lang="ja"] summary { font-weight: 800; letter-spacing: 0.02em; line-height: 1.35; }
html[lang="ja"] p, html[lang="ja"] li { word-break: auto-phrase; line-break: strict; }
p { margin: 0; text-wrap: pretty; }
.nb { display: inline-block; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.sky :focus-visible, .sky-flat :focus-visible { --focus: var(--gold); }

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + var(--gutter) + var(--gutter-r));
  margin-inline: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter-r);
}

/* ------------------------------------------------------------ night sky */
.sky {
  position: relative;
  isolation: isolate;
  color: #fff;
  background:
    radial-gradient(900px 520px at 78% 38%, rgba(104, 118, 255, 0.34), transparent 70%),
    linear-gradient(180deg, var(--night-deep) 0%, var(--night) 100%);
}
.sky::before, .sky::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
/* small static stars */
.sky::before {
  background-image:
    radial-gradient(1.4px 1.4px at 22px 34px, #fff, transparent 60%),
    radial-gradient(1px 1px at 96px 120px, rgba(255, 255, 255, 0.9), transparent 60%),
    radial-gradient(1.2px 1.2px at 170px 62px, #fff, transparent 60%),
    radial-gradient(1px 1px at 240px 190px, rgba(255, 255, 255, 0.8), transparent 60%),
    radial-gradient(1.5px 1.5px at 310px 96px, #fff, transparent 60%),
    radial-gradient(1px 1px at 58px 236px, rgba(255, 255, 255, 0.85), transparent 60%),
    radial-gradient(1.2px 1.2px at 352px 250px, #fff, transparent 60%),
    radial-gradient(1px 1px at 196px 288px, rgba(255, 255, 255, 0.8), transparent 60%),
    radial-gradient(1.3px 1.3px at 120px 330px, #fff, transparent 60%),
    radial-gradient(1px 1px at 288px 352px, rgba(255, 255, 255, 0.9), transparent 60%);
  background-size: 380px 380px;
}
/* larger golden stars that twinkle */
.sky::after {
  background-image:
    radial-gradient(2.6px 2.6px at 70px 80px, var(--gold), transparent 70%),
    radial-gradient(2.2px 2.2px at 330px 210px, #ffe39a, transparent 70%),
    radial-gradient(2.4px 2.4px at 190px 330px, var(--gold), transparent 70%);
  background-size: 460px 460px;
  animation: twinkle 5.5s ease-in-out infinite alternate;
}
@keyframes twinkle { from { opacity: 0.35; } to { opacity: 1; } }

/* ------------------------------------------------------------ top bar */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; color: #fff; text-decoration: none; font-family: var(--display); font-size: 1.6rem; line-height: 1; }
.brand img { border-radius: 11px; }
.top-end { display: flex; align-items: center; gap: 6px; }
.top-nav { display: flex; gap: 4px; }
.top-nav a, .lang summary {
  color: #fff;
  text-decoration: none;
  padding: 9px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  line-height: 1.2;
}
.top-nav a:hover, .lang summary:hover { background: rgba(255, 255, 255, 0.12); }
.lang { position: relative; }
.lang summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary svg { width: 16px; height: 16px; flex: none; }
.lang[open] summary { background: rgba(255, 255, 255, 0.14); }
.lang ul {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 10;
  margin: 0;
  padding: 8px;
  list-style: none;
  min-width: 11rem;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 18px 48px rgba(7, 10, 40, 0.45);
}
.lang li a {
  display: block;
  padding: 10px 14px;
  border-radius: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}
.lang li a:hover { background: var(--lilac); }
.lang li a[aria-current="page"] { background: var(--violet); color: #fff; }
.lang :focus-visible { --focus: var(--violet); }

/* ------------------------------------------------------------ hero */
.hero { padding-bottom: 0; overflow: hidden; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: center;
  padding-block: clamp(28px, 5vw, 56px) clamp(120px, 14vw, 170px);
}
.hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.5rem); max-width: 11em; }
html[lang="ja"] .hero h1 { font-size: clamp(2.2rem, 4.8vw, 3.7rem); }
.hero .sub { margin-top: 22px; font-size: clamp(1.1rem, 1.7vw, 1.3rem); color: var(--mist); max-width: 31em; }
.cta-row { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 26px; }
.play { display: inline-block; line-height: 0; border-radius: 14px; margin-left: -9px; }
.play img { width: 206px; height: auto; }
.link-soft { color: #fff; font-weight: 700; text-decoration: underline; text-decoration-color: var(--gold); text-decoration-thickness: 3px; text-underline-offset: 6px; }
.link-soft:hover { text-decoration-color: #fff; }
.trust { list-style: none; padding: 0; margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 8px 26px; color: var(--mist); font-size: 0.98rem; }
.trust li { display: inline-flex; align-items: center; gap: 9px; }
.trust li::before { content: ""; width: 11px; height: 11px; background: var(--gold); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); }

/* phone frame (shared with the steps) */
.phone {
  position: relative;
  width: 100%;
  padding: 8px;
  border-radius: 38px;
  background: #0a0e30;
  box-shadow: 0 0 0 1.5px rgba(255, 255, 255, 0.14) inset, 0 28px 70px rgba(5, 8, 40, 0.5);
}
.screen { position: relative; border-radius: 30px; overflow: hidden; aspect-ratio: 560 / 1042; background: #fdf0e6; }
.screen img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-phone { justify-self: center; width: min(300px, 68vw); transform: rotate(3deg); filter: drop-shadow(0 0 70px rgba(110, 125, 255, 0.45)); }

/* the one orchestrated moment: the app's real screens play in turn */
.cycle .s2, .cycle .s3, .cycle .s1b { opacity: 0; }
.cycle .s2 { animation: show2 16s infinite; }
.cycle .s3 { animation: show3 16s infinite; }
.cycle .s1b { animation: show1 16s infinite; }
@keyframes show2 { 0%, 31% { opacity: 0; } 36%, 100% { opacity: 1; } }
@keyframes show3 { 0%, 64% { opacity: 0; } 69%, 100% { opacity: 1; } }
@keyframes show1 { 0%, 95% { opacity: 0; } 100% { opacity: 1; } }

.hill { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: clamp(54px, 8vw, 110px); fill: var(--cream); display: block; }

/* ------------------------------------------------------------ sections */
.section { padding-block: clamp(56px, 8vw, 104px); }
.section h2 { font-size: clamp(1.9rem, 3.6vw, 2.75rem); }
html[lang="ja"] .section h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }

/* how it works: a real sequence, so the steps are numbered */
.how { background: var(--cream); padding-top: clamp(24px, 4vw, 48px); }
.steps-wrap { position: relative; margin-top: clamp(32px, 5vw, 56px); }
.path { position: absolute; left: 0; top: 0; width: 100%; height: 460px; z-index: 0; overflow: visible; }
.path path { fill: none; stroke: var(--gold); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 1 13; vector-effect: non-scaling-stroke; }
.steps { position: relative; z-index: 1; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 5vw, 64px); }
.step { display: flex; flex-direction: column; gap: 22px; }
.step:nth-child(2) { margin-top: 56px; }
.step .phone { width: 100%; background: var(--night-deep); box-shadow: 0 24px 50px rgba(40, 20, 110, 0.28); }
.step-shot { position: relative; width: min(230px, 100%); }
.step-no {
  position: absolute;
  left: -14px;
  top: -14px;
  z-index: 2;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--gold);
  color: var(--ink);
  font-family: var(--display);
  font-size: 1.45rem;
  line-height: 1;
  box-shadow: 0 6px 14px rgba(90, 52, 200, 0.3);
}
.step h3 { font-size: 1.5rem; color: var(--violet); }
.step p { color: var(--ink-soft); margin-top: 6px; max-width: 24em; }

.features { background: var(--lilac); }
.features-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
.feat-list { list-style: none; margin: 0; padding: 0; }
.feat { display: grid; grid-template-columns: 30px minmax(0, 1fr); column-gap: 14px; padding-block: 22px; border-top: 2px dotted var(--line); }
.feat:last-child { border-bottom: 2px dotted var(--line); }
.feat::before { content: ""; width: 22px; height: 22px; margin-top: 3px; background: var(--gold); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); }
.feat h3 { font-size: 1.35rem; color: var(--violet); }
.feat p { grid-column: 2; margin-top: 4px; color: var(--ink-soft); max-width: 36em; }

.langs { margin-top: clamp(28px, 4vw, 44px); }
.langs h3 { font-size: 1.35rem; }
.langs p { margin-top: 8px; color: var(--ink-soft); }
.pills { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 999px;
  border: 2px solid var(--violet);
  background: #fff;
  color: var(--violet);
  text-decoration: none;
  font-family: var(--display);
  font-size: 1.05rem;
  line-height: 1.2;
  font-synthesis: none;
}
html[lang="ja"] .pill { font-weight: 700; }
.pill:hover { background: #f5f0ff; }
.pill[aria-current="page"] { background: var(--violet); color: #fff; }

.ai { background: var(--violet); color: #fff; padding-block: clamp(40px, 6vw, 68px); }
.ai-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(20px, 5vw, 80px); align-items: center; }
.ai h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); display: flex; align-items: center; gap: 16px; }
.ai-mark { flex: none; display: grid; place-items: center; width: 54px; height: 54px; border-radius: 15px; background: #0a0e30; color: #fff; font-family: var(--body); font-weight: 800; font-size: 1.1rem; letter-spacing: 0.02em; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3) inset; }
.ai p { color: #efeaff; max-width: 38em; }

.faq { background: var(--cream); }
.faq-box { max-width: 760px; }
.faq-list { margin-top: 30px; }
.faq details { border-top: 2px dotted var(--line); }
.faq details:last-child { border-bottom: 2px dotted var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 0; font-family: var(--display); font-size: 1.25rem; color: var(--ink); line-height: 1.3; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--lilac); color: var(--violet); font-family: var(--body); font-size: 1.5rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; background: var(--violet); color: #fff; }
.faq details p { padding: 0 54px 22px 0; color: var(--ink-soft); }
.faq a { font-weight: 700; }

.final { text-align: center; padding-block: clamp(64px, 9vw, 112px); }
.final .wrap { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.final img.logo { border-radius: 26px; box-shadow: 0 0 80px rgba(110, 125, 255, 0.55); }
.final h2 { font-size: clamp(2rem, 4.2vw, 3.2rem); max-width: 14em; }
.final p { color: var(--mist); }
.final .play { margin: 6px 0 0; }

.foot { background: var(--night-deep); color: var(--mist); padding-block: 26px calc(26px + env(safe-area-inset-bottom, 0px)); font-size: 0.95rem; }
.foot .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 28px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.foot a { color: #fff; text-underline-offset: 4px; }
.foot :focus-visible { --focus: var(--gold); }

/* ------------------------------------------------------------ small screens */
@media (max-width: 860px) {
  .top-nav { display: none; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); padding-bottom: clamp(96px, 22vw, 140px); }
  .hero-phone { order: 2; transform: rotate(2deg); margin-top: 18px; width: min(260px, 66vw); }
  .path { display: none; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .step { display: grid; grid-template-columns: 128px minmax(0, 1fr); align-items: center; gap: 20px; }
  .step:nth-child(2) { margin-top: 0; }
  .step-shot { width: 128px; }
  .step .phone { padding: 5px; border-radius: 24px; }
  .step .screen { border-radius: 19px; }
  .step-no { width: 38px; height: 38px; left: -10px; top: -10px; font-size: 1.2rem; }
  .features-grid, .ai-grid { grid-template-columns: minmax(0, 1fr); }
  .faq details p { padding-right: 0; }
}
@media (max-width: 420px) {
  .brand { font-size: 1.35rem; }
  .brand img { width: 36px; height: 36px; }
  .cta-row { gap: 6px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .sky::after { animation: none; opacity: 0.8; }
  .cycle .s2, .cycle .s3, .cycle .s1b { animation: none; opacity: 0; }
}
