/* 앱별 다운로드 페이지 공통 스타일 (/apps/<앱>/) */
:root {
  color-scheme: light;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --subtle: #eef1f5;
  --dark: #181a1e;
  --text: #3a3f47;
  --muted: #767e89;
  --border: #dfe3e8;
  --focus: #2457ff;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard", system-ui, -apple-system, "Noto Sans KR", sans-serif;
  word-break: keep-all;
  -webkit-text-size-adjust: 100%;
}
main {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: 20px 16px calc(32px + env(safe-area-inset-bottom));
}
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.brand { margin: 0 4px 10px; }
.brand a { display: inline-flex; align-items: center; min-height: 44px; }
.brand img { display: block; width: auto; height: 32px; }

.card {
  overflow: hidden;
  border-radius: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05);
}
.hero {
  margin: 0;
  aspect-ratio: 1024 / 500;
  background: var(--subtle);
}
.hero img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.card-body { padding: 20px 20px 22px; }

.head {
  display: flex;
  align-items: center;
  gap: 14px;
}
.head img {
  flex: none;
  width: 68px;
  height: 68px;
  border-radius: 17px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
}
h1 {
  margin: 0 0 4px;
  font-size: 24px;
  line-height: 1.25;
  color: var(--dark);
}
.tagline {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
}
.desc {
  margin: 16px 0 0;
  font-size: 15px;
  line-height: 1.7;
  color: var(--muted);
}

.actions {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}
.install {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 54px;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--dark);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.install svg { width: 18px; height: 18px; flex: none; }
.install:active { transform: scale(0.98); }
.install--sub {
  background: var(--surface);
  color: var(--dark);
  border: 1px solid var(--border);
}
.install.pending {
  background: var(--subtle);
  color: var(--muted);
  cursor: default;
}
.install.pending:active { transform: none; }
@media (hover: hover) {
  a.install:hover { opacity: 0.86; }
}

.notice {
  margin: 8px 0 -10px;
  text-align: center;
  font-size: 13px;
}
.notice a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 8px;
  color: var(--text);
  text-underline-offset: 3px;
}

/* 인앱 브라우저 안내 (접힌 상태) */
.guide {
  margin-top: 14px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.guide summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 14px 18px;
  font-size: 16px;
  font-weight: 700;
  color: var(--dark);
  cursor: pointer;
  list-style: none;
  border-radius: 20px;
}
.guide summary::-webkit-details-marker { display: none; }
.guide summary::after {
  content: "";
  flex: none;
  width: 9px;
  height: 9px;
  margin-right: 4px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-3px) rotate(45deg);
  transition: transform 0.2s ease;
}
.guide[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.guide-body {
  padding: 14px 18px 18px;
  border-top: 1px solid var(--border);
}
.guide-lead {
  margin: 0 0 10px;
  font-size: 15px;
  line-height: 1.6;
}
.guide ol {
  margin: 0;
  padding-left: 20px;
  font-size: 15px;
  line-height: 1.75;
}
.guide b {
  display: inline-block;
  padding: 0 6px;
  border-radius: 6px;
  background: var(--subtle);
  color: var(--dark);
}
.guide-note {
  margin: 10px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}
.copy {
  margin-top: 14px;
  width: 100%;
  min-height: 48px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--dark);
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.more {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  min-height: 56px;
  padding: 14px 18px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--dark);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
}
.more span { color: var(--muted); }

footer {
  margin-top: 24px;
  text-align: center;
  font-size: 13px;
}
footer a { color: var(--muted); }

/* 번체 중국어·일본어 페이지: 글꼴과 줄바꿈 */
:lang(zh-Hant) body {
  font-family: "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", system-ui, sans-serif;
  word-break: normal;
}
:lang(ja) body {
  font-family: "Hiragino Sans", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", system-ui, sans-serif;
  word-break: normal;
  line-break: strict;
}
:lang(ja) :is(.tagline, .desc, .guide-body) { word-break: auto-phrase; }
:lang(ja) h1 { font-size: 18px; }
:lang(ja) h1 span { display: inline-block; }

@media (prefers-reduced-motion: reduce) {
  .install, .guide summary::after { transition: none; }
}
@media (min-width: 640px) {
  main { padding-top: 40px; }
  .card-body { padding: 26px 28px 28px; }
  h1 { font-size: 28px; }
  :lang(ja) h1 { font-size: 26px; }
}
