/* 첫 화면 전용. 처리방침·약관 페이지는 style.css를 그대로 쓴다. 글꼴 파일은 tools/web/fonts.py가 첫 화면에 쓰인 글자만 남겨 만든다. */
@font-face { font-family: "Allday Sans"; src: url("/fonts/allday-sans.woff") format("woff"); font-weight: 45 930; font-display: swap; }
@font-face { font-family: "Dunggeunmiso"; src: url("/fonts/dunggeunmiso.woff") format("woff"); font-weight: 400; font-display: swap; }
/* 스토어 사진(#1080)과 같은 짜임: 장마다 칩 → 두 줄 제목(강조 낱말은 글자 색만) → 한 줄 설명 → 폰 그림. 바탕 빛도 스토어 사진 값 그대로 */
:root {
  color-scheme: light;
  --night: #2f3a7a;
  --day: #f9d776;
  --cream: #fff4da;
  --ink: #1e2340;
  --sun: #f2b53a;
  --paper: #fffaee;
  --surface: #ffffff;
  --muted: #5b5f78;
  --line: rgba(30, 35, 64, 0.12);
  --navy: #23306b;
  --sub: #4f5574;
  --accent: #3f4c97;
  --gold: #f9d776;
  --display: "Dunggeunmiso", "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  --body: "Allday Sans", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --wrap: 1200px;
  --gutter: 24px;
  --star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M50,0 L63,37 L100,50 L63,63 L50,100 L37,63 L0,50 L37,37 Z' fill='%23fff4da'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.65; word-break: keep-all; -webkit-font-smoothing: antialiased; }
/* 그림에 적은 width·height 값은 자리 잡기용이다. 높이를 비우지 않으면 CSS로 너비만 바꾼 그림이 세로로 늘어난다. */
img { max-width: 100%; height: auto; }
a { color: inherit; }
a:focus-visible, summary:focus-visible { outline: 3px solid var(--sun); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
ul, ol { margin: 0; padding: 0; list-style: none; }
/* 가운뎃점으로 이은 낱말이 점에서 갈라지지 않게 */
.nw { white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }

/* 위 막대 */
.site-nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: rgba(255, 250, 238, 0.9); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); }
.site-nav .wrap { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img.icon { width: 34px; height: 34px; border-radius: 9px; display: block; }
.brand img.word { height: 21px; width: auto; display: block; }
.site-nav nav { display: flex; gap: 24px; margin-left: auto; font-size: 15px; font-weight: 650; color: var(--ink); }
.site-nav nav a { text-decoration: none; opacity: 0.78; }
.site-nav nav a:hover { opacity: 1; }
.btn { display: inline-flex; align-items: center; font-weight: 700; font-size: 15px; text-decoration: none; padding: 10px 18px; border-radius: 999px; background: var(--night); color: var(--cream); }
.btn:hover { background: #262f66; }

/* 배지 규칙: 애플 40px·구글 28px 이상에 두 배지 높이를 같게, 둘레 여백은 높이의 1/4 이상, 그림은 고치지 않고 App Store를 먼저 둔다. */
.stores { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; }
.stores a.badge { display: inline-block; line-height: 0; }
.stores a.badge img { height: 48px; width: auto; display: block; }
/* 폰에서 받기 막대와 추천 안내 페이지는 그 폰의 스토어 배지 하나만 둔다(머리의 data-os). 첫 화면 위·끝 받기 칸(.both)과 컴퓨터·모르는 기기는 둘 다 */
html[data-os="ios"] .stores:not(.both) a.badge.play, html[data-os="android"] .stores:not(.both) a.badge.apple { display: none; }

/* 밤 글 옆 별 둘(로고 모자의 별) */
.stars { display: inline-block; position: relative; width: 34px; height: 30px; margin-left: 10px; vertical-align: -6px; }
.stars::before, .stars::after { content: ""; position: absolute; background: var(--star) center / contain no-repeat; }
.stars::before { width: 18px; height: 18px; left: 0; top: -4px; opacity: 0.9; }
.stars::after { width: 11px; height: 11px; left: 20px; top: 12px; opacity: 0.6; }

/* 장 바탕: 스토어 사진 store1080.py의 TONES·background()와 같은 빛 두 개 + 위아래 흐름 */
.tone { position: relative; isolation: isolate; overflow: hidden;
  background: radial-gradient(95% 34% at 92% 40%, var(--glow-a), transparent 70%), radial-gradient(95% 32% at 4% 80%, var(--glow-b), transparent 70%), linear-gradient(180deg, var(--top), var(--bottom)); }
.tone-night { --top: #1b2150; --bottom: #0e1230; --glow-a: #3b3f9a; --glow-b: #1d4a7a; color: #fff; }
.tone-dawn { --top: #eaf0ff; --bottom: #ffe7d9; --glow-a: #ffd3bc; --glow-b: #c9d3ff; }
.tone-peach { --top: #fff2ea; --bottom: #ffdccd; --glow-a: #ffc9b8; --glow-b: #ffe9b5; }
.tone-lilac { --top: #f5f0ff; --bottom: #e3daff; --glow-a: #ffd9e8; --glow-b: #d3e1ff; }
.tone-butter { --top: #fff8e3; --bottom: #ffecb8; --glow-a: #ffd6b3; --glow-b: #ddf0d4; }
.tone-cream { --top: #fff6ea; --bottom: #ffe3d2; --glow-a: #ffcdb5; --glow-b: #eadcff; }
.tone-mint { --top: #edf9f3; --bottom: #d1eee0; --glow-a: #d8e9ff; --glow-b: #ffe9c2; }
.tone-rose { --top: #fff1f4; --bottom: #ffd9e3; --glow-a: #ebd8ff; --glow-b: #ffe3c8; }
.tone-sky { --top: #eef4ff; --bottom: #d5e4ff; --glow-a: #e2d8ff; --glow-b: #cdefe4; }
/* 밤 바탕의 잔별: 스토어 사진처럼 작고 흐리게 */
.tone-night::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0.85; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cg fill='%23fff6d6'%3E%3Ccircle cx='18' cy='30' r='1.3' opacity='.7'/%3E%3Ccircle cx='96' cy='12' r='.9' opacity='.5'/%3E%3Ccircle cx='170' cy='48' r='1.6' opacity='.8'/%3E%3Ccircle cx='236' cy='22' r='1' opacity='.45'/%3E%3Ccircle cx='60' cy='104' r='1' opacity='.4'/%3E%3Ccircle cx='132' cy='130' r='1.4' opacity='.65'/%3E%3Ccircle cx='214' cy='118' r='.8' opacity='.5'/%3E%3Ccircle cx='28' cy='190' r='1.5' opacity='.6'/%3E%3Ccircle cx='104' cy='214' r='.9' opacity='.45'/%3E%3Ccircle cx='190' cy='200' r='1.2' opacity='.7'/%3E%3Ccircle cx='246' cy='176' r='1' opacity='.4'/%3E%3C/g%3E%3C/svg%3E") 0 0 / 260px 260px; }

/* 칩(누구를 위한 장인지): 제목보다 먼저 읽히지 않게 옅게 */
.chip { display: inline-block; font-weight: 700; font-size: 13.5px; line-height: 1; letter-spacing: -0.01em; color: var(--navy); background: rgba(35, 48, 107, 0.08); box-shadow: inset 0 0 0 1px rgba(35, 48, 107, 0.1); padding: 8px 14px 9px; border-radius: 999px; }
.tone-night .chip { color: #ffe9a8; background: rgba(255, 255, 255, 0.1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16); }
.title { font-family: var(--display); font-weight: 400; line-height: 1.22; letter-spacing: -0.01em; color: var(--ink); }
.title em { font-style: normal; color: var(--accent); }
.tone-night .title { color: #fff; }
.tone-night .title em { color: var(--gold); }
.desc { font-weight: 500; color: var(--sub); }
.tone-night .desc { color: #c9ccea; }

/* 첫 화면: 제목 · 설명 · 배지가 폰 첫 화면 안에 들고, 그 아래 폰이 판 아래로 이어진다 */
.hero-in { display: grid; gap: 26px; padding-top: 34px; }
.hero-copy { display: grid; gap: 14px; justify-items: center; text-align: center; padding-inline: var(--gutter); }
.hero h1 { font-size: clamp(34px, 9.4vw, 62px); }
.hero .desc { font-size: 16.5px; line-height: 1.55; max-width: 25em; }
.hero .stores { margin-top: 8px; }
.facts { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; font-size: 13.5px; font-weight: 650; color: rgba(255, 255, 255, 0.74); }
.facts li::before { content: "✓"; color: var(--gold); margin-right: 5px; font-weight: 800; }
.hero-art img { display: block; width: min(100%, 560px); margin: 0 auto; }
.hero-art.one img { width: min(78%, 320px); }

/* 기능 장: 스토어 사진 한 장 = 한 장. 폰은 장 아래 끝에서 잘린다(그림 아래 끝 = 장 아래 끝) */
.feat { scroll-margin-top: 64px; }
.feat-in { display: grid; gap: 26px; padding-top: 60px; }
.feat .copy { display: grid; gap: 12px; justify-items: center; text-align: center; padding-inline: var(--gutter); }
.feat h2 { font-size: clamp(30px, 8.2vw, 50px); }
.feat .desc { font-size: 16px; line-height: 1.5; }
.feat .art img { display: block; width: min(100%, 560px); margin: 0 auto; }

/* 이런 기능도 */
.more { padding-block: 88px 24px; }
.more .wrap { display: grid; gap: 34px; }
.more h2, .head h2, .faq h2 { font-family: var(--display); font-weight: 400; font-size: clamp(30px, 3.6vw, 44px); line-height: 1.18; color: var(--ink); text-align: center; }
.more-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.more-grid li { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 22px 20px; display: grid; gap: 6px; align-content: start; }
.more-grid svg { width: 26px; height: 26px; fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 6px; }
.more-grid h3 { font-size: 16.5px; line-height: 1.35; }
.more-grid p { font-size: 14.5px; line-height: 1.5; color: var(--muted); text-wrap: pretty; }

/* 안심 */
.trust { padding-block: 80px; }
.head { display: grid; gap: 10px; justify-items: center; text-align: center; }
.eyebrow { font-weight: 750; font-size: 15px; color: var(--night); letter-spacing: 0.02em; }
.trust-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.trust-row div { border-top: 3px solid var(--night); padding-top: 18px; display: grid; gap: 8px; align-content: start; }
.trust-row h3 { font-size: 17.5px; }
.trust-row p { font-size: 15.5px; color: var(--muted); text-wrap: pretty; }

/* 자주 묻는 질문 */
.faq { padding-block: 8px 96px; }
.faq .wrap { display: grid; gap: 30px; max-width: 840px; }
.qlist { display: grid; gap: 10px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding-inline: 22px; }
.faq summary { cursor: pointer; list-style: none; font-weight: 700; padding-block: 18px; display: flex; justify-content: space-between; gap: 14px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 22px; line-height: 1; color: var(--night); }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--muted); padding-bottom: 18px; margin-top: -4px; }

/* 마지막 받기 */
.cta { padding-block: 0 96px; }
.cta-box { border-radius: 44px; padding: 64px clamp(28px, 6vw, 80px); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 32px; align-items: center; }
.cta-copy { display: grid; gap: 14px; }
.cta-box h2 { font-size: clamp(32px, 3.8vw, 50px); line-height: 1.18; }
.cta-box .desc { font-size: 17px; }
.cta-box .stores { justify-content: flex-start; margin-top: 10px; }
.cta-box .tile { width: 120px; height: 120px; border-radius: 32px; display: block; box-shadow: 0 22px 40px -16px rgba(0, 0, 0, 0.5); }

/* 아래에 붙는 받기 막대(폰만): 첫 화면 배지가 화면 밖으로 나가면 뜨고, 마지막 받기 칸·아래 정보가 보이면 숨는다.
   한 화면에 App Store 배지가 둘 보이지 않게(애플 배지 규칙 '한 화면에 하나') 둔다. */
.getbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; align-items: center; gap: 12px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px)); background: rgba(255, 250, 238, 0.94); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-top: 1px solid var(--line); box-shadow: 0 -12px 30px -20px rgba(30, 35, 64, 0.4); transform: translateY(110%); visibility: hidden; transition: transform 0.28s ease, visibility 0s linear 0.28s; }
.getbar.on { transform: none; visibility: visible; transition: transform 0.28s ease; }
.getbar .tile { width: 44px; height: 44px; border-radius: 12px; flex: none; }
.getbar .txt { display: grid; min-width: 0; line-height: 1.25; }
.getbar .txt b { font-size: 15px; font-weight: 800; color: var(--ink); }
.getbar .txt span { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.getbar .stores { margin-left: auto; flex-wrap: nowrap; gap: 8px; }
.getbar .stores a.badge img { height: 40px; }
/* 모르는 기기면 배지가 둘이라 글을 뺀다 */
html:not([data-os="ios"]):not([data-os="android"]) .getbar .txt { display: none; }
@media (prefers-reduced-motion: reduce) { .getbar, .getbar.on { transition: none; } }

.site-footer { border-top: 1px solid var(--line); padding-block: 40px 56px; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: grid; gap: 14px; }
.site-footer .links { display: flex; flex-wrap: wrap; gap: 6px 20px; font-weight: 650; color: var(--ink); }
.site-footer .links a { text-decoration: none; }
.site-footer .links a:hover, .site-footer a.mail:hover { color: var(--night); }
.site-footer .fine { max-width: 72ch; }

/* 넓은 화면: 글과 폰을 좌우로, 장마다 번갈아 */
@media (min-width: 960px) {
  .getbar { display: none; }
  .hero-in, .feat-in { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); grid-template-columns: minmax(0, 1fr) minmax(0, 460px); align-items: center; gap: 56px; }
  .hero-in { padding-top: 0; }
  .hero-copy, .feat .copy { justify-items: start; text-align: left; padding: 64px 0; }
  .hero h1 { font-size: 64px; }
  .hero .desc { font-size: 19px; }
  .hero .stores, .facts { justify-content: flex-start; }
  .hero .stores a.badge img { height: 52px; }
  .hero-art, .feat .art { align-self: end; padding-top: 64px; }
  .feat-in { padding-top: 0; }
  .feat.flip .copy { order: 2; }
  .feat h2 { font-size: 48px; }
  .feat .desc { font-size: 18px; }
  .cta .stores a.badge img { height: 52px; }
}
@media (max-width: 959px) {
  .site-nav nav { display: none; }
  .site-nav .btn { display: none; }
  .more-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .trust-row { gap: 28px 20px; }
  .cta-box { grid-template-columns: 1fr; justify-items: center; text-align: center; padding-block: 52px; }
  .cta-box .tile { grid-row: 1; width: 96px; height: 96px; border-radius: 26px; }
  .cta-box .stores { justify-content: center; }
}
@media (max-width: 520px) {
  :root { --gutter: 16px; }
  body { font-size: 16px; }
  .brand img.word { height: 18px; }
  .more { padding-block: 72px 16px; }
  .more-grid { gap: 10px; }
  .more-grid li { padding: 18px 16px; border-radius: 18px; }
  .more-grid h3 { font-size: 15.5px; }
  .more-grid p { font-size: 13.5px; }
  .trust { padding-block: 64px; }
  .trust-row { grid-template-columns: 1fr; }
  .cta { padding-bottom: 72px; }
  .cta-box { --pad: 22px; border-radius: 34px; padding: 44px var(--pad); }
  /* 배지 둘이 360px 폰에서도 한 줄에 들게 칸 너비로 높이를 정한다(40~48px, 두 배지 너비는 높이의 6.6배). 사이 12px는 48px의 1/4 */
  .stores.both { --badge: clamp(40px, calc((100vw - 2 * var(--gutter)) / 7), 48px); }
  .cta-box .stores.both { --badge: clamp(40px, calc((100vw - 2 * var(--gutter) - 2 * var(--pad)) / 7), 48px); }
  .stores.both a.badge img { height: var(--badge); }
}

/* 첫 화면 바탕: 밤(배 속) → 오른쪽 아래 새벽빛(태어난 뒤). 스토어 첫 장(store1946.py night_dawn)과 같은 빛 */
.tone-birth { background:
  radial-gradient(110% 50% at 98% 100%, rgba(255, 226, 200, 1), rgba(255, 186, 158, 0.62) 40%, transparent 74%),
  radial-gradient(80% 30% at 100% 64%, rgba(255, 226, 206, 0.48), transparent 70%),
  radial-gradient(95% 32% at 4% 70%, var(--glow-b), transparent 70%),
  linear-gradient(180deg, var(--top), var(--bottom)); }
.hero-art picture { display: block; }

/* 플러스 · 새 기능 표시: 플러스는 앱 PlusBadge와 같게 노란 그라데이션 + 별(PlusColors Light · Deep · Ink) */
.tag-plus, .tag-new { display: inline-flex; align-items: center; vertical-align: 0.15em; font-family: var(--body); font-weight: 800; font-size: 12px; line-height: 1; letter-spacing: 0; padding: 5px 8px; border-radius: 999px; white-space: nowrap; gap: 3px; }
.tag-plus { background: linear-gradient(135deg, var(--day), #f2b53a); color: var(--ink); }
.tag-plus svg { width: 11px; height: 11px; fill: currentColor; flex: none; }
.tag-new { background: var(--night); color: var(--cream); }
.chip-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; }
.chip-row .tag-plus { font-size: 13px; padding: 8px 12px 9px; }
.chip-row .tag-plus svg { width: 12px; height: 12px; }

/* 새로 생겼어요: 기록 장 바로 아래. 그림 카드(넓은 화면은 한 줄, 폰은 옆으로 밀기) + 친구 추천 띠 */
.new { padding-block: 84px 12px; scroll-margin-top: 64px; }
.new .wrap { display: grid; gap: 30px; }
.new h2 { font-family: var(--display); font-weight: 400; font-size: clamp(30px, 3.6vw, 44px); line-height: 1.18; color: var(--ink); text-align: center; }
.new-row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 16px; }
.new-card { background: var(--surface); border: 1px solid var(--line); border-radius: 26px; overflow: hidden; display: grid; grid-template-rows: auto 1fr; }
.new-card .pic { aspect-ratio: 3 / 2; display: grid; place-items: center; padding: 18px; }
.new-card .pic img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; filter: drop-shadow(0 14px 22px rgba(30, 35, 64, 0.18)); }
.new-card .pic img.screen { border-radius: 16px; }
.new-card .txt { padding: 18px 20px 22px; display: grid; gap: 8px; align-content: start; }
.new-card h3 { font-size: 17px; line-height: 1.35; }
.new-card p { font-size: 14.5px; line-height: 1.5; color: var(--muted); text-wrap: pretty; }
.new-card p.fine { font-size: 13px; }
:lang(ja) .new-card p.fine .tag-plus { margin-left: 6px; }
.new-ref { border-radius: 26px; padding: 22px 26px; display: flex; align-items: center; gap: 18px; }
.new-ref .ic { flex: none; width: 52px; height: 52px; border-radius: 16px; background: var(--day); display: grid; place-items: center; }
.new-ref .ic svg { width: 28px; height: 28px; fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.new-ref h3 { font-family: var(--display); font-weight: 400; font-size: 24px; line-height: 1.25; }
.new-ref p { font-size: 15px; line-height: 1.5; color: #c9ccea; margin-top: 4px; }
.more-grid h3 .tag-new { margin-left: 6px; }
@media (min-width: 960px) {
  .feat .chip-row { justify-content: flex-start; }
  /* 두 폰 그림이라 그림 칸을 460 → 540px로(폰 하나가 200px 밑으로 작아지지 않게) */
  .tone-birth .hero-in { grid-template-columns: minmax(0, 1fr) minmax(0, 540px); gap: 40px; }
  .hero-art.one img { width: min(100%, 400px); }
}
@media (max-width: 959px) {
  .new-row { grid-auto-columns: min(78%, 300px); overflow-x: auto; scroll-snap-type: x mandatory; margin-inline: calc(-1 * var(--gutter)); padding: 0 var(--gutter) 10px; scroll-padding-inline: var(--gutter); scrollbar-width: none; }
  .new-row::-webkit-scrollbar { display: none; }
  .new-card { scroll-snap-align: start; }
}
@media (max-width: 520px) {
  .new { padding-block: 64px 8px; }
  .new-ref { align-items: flex-start; padding: 20px; gap: 14px; border-radius: 22px; }
  .new-ref .ic { width: 44px; height: 44px; border-radius: 13px; }
  .new-ref .ic svg { width: 24px; height: 24px; }
  .new-ref h3 { font-size: 19px; text-wrap: balance; }
  .new-ref p { font-size: 14px; }
}

/* 새 장 · 넓힌 장의 칩 옆 '새 기능': 칩과 같은 높이로 */
.chip-row .tag-new { font-size: 13px; padding: 8px 12px 9px; }
.tone-night .tag-new { background: var(--cream); color: var(--night); }

/* 장 설명 아래 작은 글: 플러스 몫은 이득을 먼저 쓰고 '플러스'는 끝에 작게(앱 PlusBadge와 같은 꼬리표) */
.feat .fine { font-size: 14px; line-height: 1.55; color: var(--muted); max-width: 28em; text-wrap: pretty; }
.feat .fine .tag-plus { margin-left: 4px; }
.tone-night .feat .fine, .feat.tone-night .fine { color: #c9ccea; }
