/* 랜딩(일반 앱 소개 페이지). 글꼴은 앱과 같은 Noto Sans KR(쓰는 글자만 남긴 서브셋, OFL) */
@font-face { font-family: "Nod Sans"; src: url("/fonts/nsk-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Nod Sans"; src: url("/fonts/nsk-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Nod Sans"; src: url("/fonts/nsk-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --bg: #FFFFFF;
  --alt: #F4F5F2;
  --ink: #141517;
  --body: #4A4D52;
  --muted: #7C8087;
  --line: #E4E6E1;
  --lime: #C8F03C;
  --lime-soft: #EEF9CB;
  --frame: #1B1C1E;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 17px/1.65 "Nod Sans", -apple-system, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  word-break: keep-all; overflow-wrap: anywhere;
}
a { color: inherit; }
a:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
img { display: block; max-width: 100%; }
.in { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* 상단 */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(255, 255, 255, 0.86); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; transition: border-color 0.3s; }
.nav.scrolled { border-bottom-color: var(--line); }
.nav .in { height: 64px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font-weight: 800; letter-spacing: -0.02em; font-size: 17px; }
.nav nav { display: flex; gap: 24px; }
.nav nav a { text-decoration: none; color: var(--body); font-size: 15px; }
.nav nav a:hover { color: var(--ink); }

/* 첫 화면 */
.hero { overflow: hidden; }
.hero .in { display: grid; gap: 48px; padding-top: 40px; padding-bottom: 0; }
.hero h1 { margin: 0; font-size: clamp(40px, 10vw, 68px); line-height: 1.15; letter-spacing: -0.045em; font-weight: 800; }
.lede { margin: 20px 0 0; font-size: clamp(17px, 2.2vw, 20px); line-height: 1.6; color: var(--body); }
.stores { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 32px; }
.store { display: block; border-radius: 9px; }
.store img { height: 48px; width: auto; }
.store.off { opacity: .35; cursor: default; pointer-events: none; }
.soon { margin: 12px 0 0; font-size: 14px; color: var(--muted); }

.hero-phones { position: relative; height: clamp(440px, 118vw, 600px); }
.hero-phones::before {
  content: ""; position: absolute; left: 50%; bottom: -120px; width: 520px; height: 520px; transform: translateX(-50%);
  border-radius: 50%; background: var(--lime-soft);
}
.hero-phones .layer { position: absolute; inset: 0; will-change: transform; }
.hero-phones .phone { position: absolute; bottom: -40px; }
.hero-phones .front { left: 50%; transform: translateX(-62%); width: min(62vw, 280px); }
.hero-phones .back { left: 50%; transform: translateX(-2%) rotate(6deg); transform-origin: bottom left; width: min(54vw, 244px); bottom: -10px; opacity: 0.96; }

/* 휴대폰 틀 */
.phone {
  margin: 0; border-radius: 40px; padding: 9px; background: var(--frame);
  box-shadow: 0 30px 60px -20px rgba(20, 21, 23, 0.35), 0 0 0 1px rgba(20, 21, 23, 0.08);
}
.phone img { width: 100%; height: auto; border-radius: 32px; }

/* 기능 */
.feature { padding: 96px 0; }
.feature + .feature { padding-top: 0; }
.feature .in { display: grid; gap: 40px; align-items: center; }
.feature .phone { width: min(72vw, 300px); justify-self: center; }
.feature h2, .privacy h2, .download h2 { margin: 0; font-size: clamp(28px, 5.4vw, 40px); line-height: 1.3; letter-spacing: -0.035em; font-weight: 800; }
.feature-copy > p { margin: 16px 0 0; color: var(--body); max-width: 30em; }
.points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; max-width: 32em; }
.points li { padding: 18px 20px; border-radius: 18px; background: var(--alt); color: var(--body); font-size: 16px; line-height: 1.6; }
.points b { display: block; color: var(--ink); font-size: 17px; margin-bottom: 2px; }

/* 개인정보 */
.privacy { background: var(--alt); padding: 96px 0; }
.privacy .sub { margin: 14px 0 0; color: var(--body); }
.grid { display: grid; gap: 16px; margin-top: 40px; }
.cell { background: var(--bg); border-radius: 20px; padding: 26px 24px; }
.cell h3 { margin: 0; font-size: 19px; letter-spacing: -0.02em; }
.cell p { margin: 8px 0 0; color: var(--body); font-size: 16px; line-height: 1.6; }

/* 다운로드 */
.download { padding: 104px 0; text-align: center; }
.download .mark { margin: 0 auto 24px; border-radius: 16px; }
.download p { margin: 12px 0 0; color: var(--body); }
.download .stores { justify-content: center; }

/* 아래 */
.foot { border-top: 1px solid var(--line); padding: 40px 0 56px; font-size: 14px; color: var(--muted); }
.foot .in { display: flex; flex-wrap: wrap; gap: 24px; justify-content: space-between; }
.foot .brand { font-size: 15px; color: var(--ink); }
.foot .co { margin: 12px 0 0; line-height: 1.7; }
.foot nav { display: flex; gap: 20px; }
.foot nav a { text-decoration: none; }
.foot nav a:hover { color: var(--ink); text-decoration: underline; }

@media (min-width: 900px) {
  .hero .in { grid-template-columns: 1fr 1fr; align-items: center; padding-top: 72px; min-height: 640px; }
  .hero-copy { padding-bottom: 80px; }
  .hero-phones { height: 620px; align-self: end; }
  .hero-phones .front { width: 290px; }
  .hero-phones .back { width: 254px; }
  .feature { padding: 128px 0; }
  .feature .in { grid-template-columns: 1fr 1fr; gap: 80px; }
  .feature.flip .phone { order: 2; }
  .feature .phone { width: 300px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .privacy { padding: 120px 0; }
}

/* 움직임: 스크립트(home.js)가 html에 js 클래스를 붙였을 때만 숨겼다가 화면에 들어오면 보인다.
   스크립트가 없거나 '동작 줄이기'면 처음부터 그대로 보인다 */
@media (prefers-reduced-motion: no-preference) {
  .js .rv { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1); }
  .js .rv.rise { transform: translateY(64px) scale(0.96); transition-duration: 0.8s, 1.1s; }
  .js .rv.on { opacity: 1; transform: none; }
  .js .rv.d1 { transition-delay: 0.08s; }
  .js .rv.d2 { transition-delay: 0.12s; }
  .js .rv.d3 { transition-delay: 0.18s; }
  .js .rv.d4 { transition-delay: 0.25s; }
  .js .rv.d5 { transition-delay: 0.32s; }

  /* 첫 화면 휴대폰: 열릴 때 아래에서 올라온다(앞 → 뒤) */
  .js .hero-phones .front { animation: rise-front 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.2s both; }
  .js .hero-phones .back { animation: rise-back 1.2s cubic-bezier(0.2, 0.7, 0.2, 1) 0.45s both; }
  .js .hero-phones::before { animation: glow 1.4s ease 0.1s both; }
  @keyframes rise-front { from { opacity: 0; transform: translateX(-62%) translateY(90px); } to { opacity: 1; transform: translateX(-62%); } }
  @keyframes rise-back { from { opacity: 0; transform: translateX(-30%) translateY(110px) rotate(0deg); } to { opacity: 0.96; transform: translateX(-2%) rotate(6deg); } }
  @keyframes glow { from { opacity: 0; transform: translateX(-50%) scale(0.8); } to { opacity: 1; transform: translateX(-50%); } }
}
