/* store.whendev.com — 색은 whendesk.app과 같은 "안개 + 라임"(FOG).
   라이트에서 라임은 면으로만 쓰고 글자·테두리는 올리브. OS 테마를 따른다.
   모양은 앱 스토어: 홈(추천 배너 + 앱 줄) → 상세(아이콘·받기 → 정보 줄 → 미리보기 → 설명 → 새로운 기능 → 정보) */
:root {
  color-scheme: light;
  --bg: #e8ecf0;
  --raised: #f7f9fa;
  --inset: #dde3e9;
  --line: #d0d8e0;
  --line-strong: #b4beca;
  --ink: #151a21;
  --soft: #3f4752;
  --muted: #5a6370;
  --accent: #476000;
  --lime: #c6ee3a;
  --on-lime: #1a2200;
  --lime-dim: color-mix(in srgb, var(--lime) 32%, transparent);
  --frame: #151a21;           /* 앱 아이콘·홍보 카드 바탕 — 테마와 상관없이 같다 */
  --frame-2: #1f2630;
  --frame-ink: #e8ecf0;
  --frame-soft: #9aa5b3;

  --font: "Pretendard Variable", Pretendard, -apple-system, "Malgun Gothic", "Apple SD Gothic Neo", system-ui, sans-serif;
  --mono: "Cascadia Code", "D2Coding", ui-monospace, Consolas, monospace;
  --wrap: 1040px;
  --r: 16px;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #12161c;
    --raised: #1a1f27;
    --inset: #0e1116;
    --line: #29303a;
    --line-strong: #3e4753;
    --ink: #e4e9ef;
    --soft: #b8c1cc;
    --muted: #98a2af;
    --accent: #c6ee3a;
    --lime-dim: color-mix(in srgb, var(--lime) 14%, transparent);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.6;
  word-break: keep-all; overflow-wrap: anywhere;
  min-height: 100vh; display: flex; flex-direction: column;
}
main { flex: 1; padding-bottom: 56px; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }
.wrap {
  max-width: var(--wrap); margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
h1, h2, h3, h4 { line-height: 1.25; letter-spacing: -.015em; text-wrap: balance; margin: 0; }
h2 { font-size: 22px; font-weight: 750; }
p { margin: 0; }
b { font-weight: 650; }
.eyebrow { font: 650 13px var(--font); letter-spacing: .03em; color: var(--accent); }
.muted { color: var(--muted); }
kbd {
  font: 500 .82em var(--mono); background: var(--raised); border: 1px solid var(--line-strong);
  border-bottom-width: 2px; border-radius: 6px; padding: .05em .45em; white-space: nowrap;
}
code { font: 500 .88em var(--mono); background: var(--inset); padding: .05em .35em; border-radius: 4px; }
pre { margin: 0; overflow-x: auto; background: var(--inset); border-radius: 10px; padding: 10px 12px; }
pre code { background: none; padding: 0; font-size: 13px; }

.appicon { border-radius: 23%; flex: none; display: block; }
/* 먹색 아이콘 틀은 다크 바탕에 묻힌다 — 다크에서만 얇은 윤곽 */
@media (prefers-color-scheme: dark) { .appicon { box-shadow: 0 0 0 1px var(--line-strong); } }

/* ── 머리띠 */
.top { border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 5; }
.top .wrap { display: flex; align-items: center; gap: 12px 22px; min-height: 56px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 16px; color: var(--ink); text-decoration: none; letter-spacing: .03em; white-space: nowrap; }
.logo .mark { width: 26px; height: 26px; }
.logo em { font-style: normal; color: var(--accent); }
.top nav { display: flex; gap: 18px; margin-left: auto; font-size: 15px; }
.top nav a { color: var(--soft); text-decoration: none; white-space: nowrap; }
.top nav a:hover { color: var(--ink); }

/* ── 받기 버튼(알약) */
.get-wrap { display: grid; justify-items: center; gap: 4px; flex: none; }
.get {
  display: inline-flex; align-items: center; justify-content: center; min-width: 76px; height: 32px; padding: 0 18px;
  border-radius: 99px; background: var(--lime); color: var(--on-lime); text-decoration: none;
  font: 750 14.5px var(--font); letter-spacing: .02em;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--on-lime) 14%, transparent);
}
.get:hover { filter: brightness(1.05); text-decoration: none; }
.get.soon { background: var(--inset); color: var(--muted); box-shadow: none; cursor: default; font-weight: 650; }
.get-sub { font: 550 12px var(--font); font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; text-align: center; }
.get-sub:empty { display: none; }
.get-wrap.big { justify-items: start; }
.get-wrap.big .get { height: 40px; min-width: 120px; font-size: 16px; padding: 0 28px; }
.get-wrap.big .get-sub { font-size: 12.5px; text-align: left; }

/* ── 홈 */
.store-head { padding-block: 40px 18px; display: grid; gap: 2px; }
.store-head h1 { font-size: clamp(32px, 5vw, 40px); font-weight: 800; }

.feature {
  background: var(--frame); color: var(--frame-ink); border-radius: calc(var(--r) + 6px); overflow: hidden;
  box-shadow: 0 18px 50px rgba(20, 30, 45, .16);
}
.feature-link { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 24px; padding: clamp(24px, 4vw, 40px); color: inherit; text-decoration: none; min-height: 240px; }
.feature .eyebrow { color: var(--lime); }
.feature h2 { font-size: clamp(24px, 3.4vw, 34px); font-weight: 800; margin-top: 8px; color: #fff; }
.feature-art { display: grid; place-items: center; }
.feature-foot { display: flex; align-items: center; gap: 14px; padding: 14px clamp(20px, 4vw, 40px); background: var(--frame-2); }
.feature-app { display: flex; align-items: center; gap: 14px; color: inherit; text-decoration: none; flex: 1; min-width: 0; }
.feature-app > span { display: grid; min-width: 0; }
.feature-app b { font-size: 16px; }
.feature-app span span { font-size: 13.5px; color: var(--frame-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feature .appicon { box-shadow: 0 0 0 1px #3e4753; }
.feature .get-sub { color: var(--frame-soft); }

.shelf { margin-top: 40px; }
.shelf-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 8px; }
.shelf-head .count { font: 500 13px var(--mono); color: var(--muted); }
.shelf-head a { margin-left: auto; font-size: 15px; text-decoration: none; }

.rows { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 440px), 1fr)); column-gap: 32px; }
.row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.row-link { display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0; color: inherit; text-decoration: none; }
.row-link:hover b { text-decoration: underline; text-underline-offset: 3px; }
.row-text { display: grid; min-width: 0; line-height: 1.4; }
.row-text b { font-size: 16.5px; letter-spacing: .02em; }
.row-cat { font-size: 13px; color: var(--muted); }
.row-sum { font-size: 14px; color: var(--soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── 상세 */
.crumb { padding-top: 18px; font-size: 14.5px; }
.crumb a { color: var(--soft); text-decoration: none; }
.crumb a:hover { color: var(--ink); }
.hero { display: flex; gap: clamp(18px, 3vw, 28px); align-items: flex-start; padding-block: 22px 26px; }
.hero > .appicon { width: clamp(96px, 16vw, 128px); height: auto; box-shadow: 0 10px 30px rgba(20, 30, 45, .18); }
@media (prefers-color-scheme: dark) { .hero > .appicon { box-shadow: 0 0 0 1px var(--line-strong), 0 10px 30px rgba(0, 0, 0, .4); } }
.hero-text { display: grid; gap: 2px; min-width: 0; }
.hero h1 { font-size: clamp(28px, 4.4vw, 38px); font-weight: 800; letter-spacing: .01em; }
.subtitle { font-size: clamp(16px, 2vw, 18px); color: var(--soft); }
.dev { font-size: 14px; }
.dev a { text-decoration: none; }
.hero-actions { margin-top: 14px; }
.others { margin-top: 6px; font-size: 13.5px; color: var(--muted); }

.infos {
  display: flex; margin: 0; padding: 14px 0; overflow-x: auto; scrollbar-width: none;
  border-block: 1px solid var(--line);
}
.infos::-webkit-scrollbar { display: none; }
.infos > div { flex: 1 0 auto; min-width: 104px; display: grid; justify-items: center; gap: 2px; padding: 0 14px; text-align: center; }
.infos > div + div { border-left: 1px solid var(--line); }
.infos dt { font-size: 11.5px; font-weight: 650; color: var(--muted); letter-spacing: .04em; }
.infos dd { margin: 0; font-size: 18px; font-weight: 750; white-space: nowrap; }
.infos span { font-size: 12px; color: var(--muted); white-space: nowrap; }

.block { padding-top: 34px; }
.block > h2 { margin-bottom: 14px; }

/* 미리보기 — 옆으로 넘기는 줄 */
.shots {
  display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 12px;
  scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent;
}
.shot {
  margin: 0; flex: 0 0 min(82%, 400px); aspect-ratio: 4 / 3; scroll-snap-align: start;
  border-radius: var(--r); background: var(--frame); color: var(--frame-ink);
  display: grid; grid-template-rows: auto 1fr; padding: 22px; overflow: hidden; position: relative;
}
.shot::after { content: ""; position: absolute; inset: auto -30% -55% auto; width: 80%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--lime) 22%, transparent), transparent); pointer-events: none; }
.shot figcaption { display: grid; gap: 4px; position: relative; z-index: 1; }
.shot strong { font-size: clamp(20px, 2.6vw, 24px); font-weight: 800; color: #fff; line-height: 1.25; }
.shot strong b, .feature h2 b { color: var(--lime); font-weight: 800; }
.shot figcaption span { font-size: 13.5px; color: var(--frame-soft); }
.shot .art { display: grid; place-items: center; position: relative; z-index: 1; }
.shot.img { padding: 0; background: var(--inset); aspect-ratio: auto; height: 300px; flex-basis: auto; }
.shot.img::after { display: none; }
.shot.img img { height: 100%; width: auto; display: block; }

/* 홍보 카드 그림 — apps.js의 art */
.art kbd {
  font: 700 22px var(--mono); color: var(--frame-ink); background: #262e39; border: 1px solid #3e4753; border-bottom-width: 4px;
  border-radius: 10px; padding: 12px 18px; min-width: 58px; text-align: center; display: inline-block;
}
.art-keys { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; }
.art-keys > span { font: 700 22px var(--mono); color: var(--frame-soft); }
.art-keys kbd.wide { min-width: 140px; }
.art-keys.small { gap: 8px; }
.art-keys.small kbd { font-size: 17px; padding: 9px 13px; min-width: 46px; }
.art-keys.small kbd.wide { min-width: 96px; }
.art-bullets { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 17px; font-weight: 600; width: min(100%, 230px); }
.art-bullets li { display: flex; gap: 14px; align-items: center; background: #1f2630; border-radius: 10px; padding: 7px 14px; }
.art-bullets i { font: 700 18px var(--mono); font-style: normal; color: var(--lime); width: 14px; text-align: center; }
.art-bullets .done { color: var(--frame-soft); text-decoration: line-through; }
.art-chips, .art-status { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 300px; }
.art-chips code { font: 600 15px var(--mono); background: #262e39; color: var(--frame-ink); border: 1px solid #3e4753; padding: 6px 12px; border-radius: 8px; }
.art-chips code:first-child { background: var(--lime); color: var(--on-lime); border-color: var(--lime); }
.art-status span { font: 700 13px var(--mono); padding: 6px 12px; border-radius: 99px; letter-spacing: .04em; }
.art-status .q { background: #2a313c; color: #9aa5b3; }
.art-status .r { background: #1f2630; color: var(--lime); box-shadow: inset 0 0 0 1px #3e4753; }
.art-status .r::before { content: "● "; }
.art-status .n { background: #e5484d; color: #fff; }
.art-status .v { background: var(--lime); color: var(--on-lime); }
.art-status .d { background: #2f9e5b; color: #fff; }
.art-diff { background: #0e1116; border: 1px solid #29303a; font: 500 15px/1.7 var(--mono); padding: 12px 18px; border-radius: 10px; width: min(100%, 280px); color: var(--frame-ink); }
.art-diff .h { color: var(--frame-soft); }
.art-diff .m { color: #ff8589; }
.art-diff .p { color: var(--lime); }
.art-tree { list-style: none; margin: 0; padding: 0; font: 500 16px/1.9 var(--mono); }
.art-tree li:first-child { color: var(--lime); font-weight: 700; }
.art-bars { display: grid; gap: 16px; width: min(100%, 260px); }
.art-bars label { display: grid; gap: 6px; font-size: 14px; font-weight: 650; color: var(--frame-soft); }
.art-bars span { height: 12px; border-radius: 99px; background: #262e39; position: relative; overflow: hidden; }
.art-bars span::before { content: ""; position: absolute; inset: 0 auto 0 0; width: calc(var(--v) * 100%); background: var(--lime); border-radius: inherit; }
.feature .art { transform: scale(1.05); }

/* 설명 */
.about { display: grid; gap: 18px; }
.desc { display: grid; gap: 10px; max-width: 46em; color: var(--soft); font-size: 16.5px; }
.feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.feats li { background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: grid; gap: 2px; font-size: 14.5px; color: var(--soft); }
.feats b { color: var(--ink); font-size: 15.5px; }
.require { font-size: 14.5px; color: var(--soft); background: var(--lime-dim); border-radius: 10px; padding: 10px 14px; }

/* 새로운 기능 */
.news-meta { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--muted); margin-bottom: 8px; }
.news-meta span:first-child { font-weight: 650; color: var(--soft); }
.notes { color: var(--soft); font-size: 15px; display: grid; gap: 8px; max-width: 48em; }
.notes ul { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; }
.notes h4 { font-size: 15.5px; color: var(--ink); margin-top: 6px; }
.notes b { color: var(--ink); }
.notes.clamp { max-height: 7.6em; overflow: hidden; -webkit-mask-image: linear-gradient(#000 60%, transparent); mask-image: linear-gradient(#000 60%, transparent); }
.more { margin-top: 6px; border: 0; background: none; padding: 4px 0; font: 650 14.5px var(--font); color: var(--accent); cursor: pointer; }

/* 설치 */
.install { display: grid; gap: 10px; }
.install details { background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; }
.install summary { font-weight: 650; cursor: pointer; }
.install details p { margin-top: 8px; font-size: 14.5px; color: var(--soft); }
.install pre { margin-top: 8px; }

/* 정보 */
.facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); border-top: 1px solid var(--line); }
.facts > div { padding: 12px 0; border-bottom: 1px solid var(--line); display: grid; gap: 2px; padding-right: 16px; }
.facts dt { font-size: 13px; color: var(--muted); }
.facts dd { margin: 0; font-size: 15px; }
.report { margin-top: 18px; font-size: 14.5px; color: var(--soft); }

/* ── 바닥 */
.foot { border-top: 1px solid var(--line); padding-block: 28px 40px; font-size: 14px; color: var(--muted); }
.foot .wrap { display: grid; gap: 10px; }
.foot .links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.foot .links a { color: var(--soft); }

@media (max-width: 640px) {
  .feature-link { grid-template-columns: 1fr; min-height: 0; gap: 22px; }
  .feature-art { padding-block: 6px 4px; }
  .hero { flex-direction: row; }
  .get-wrap.big .get { min-width: 104px; }
  .shot .art kbd { font-size: 17px; padding: 9px 13px; min-width: 46px; }
  .shot .art-keys kbd.wide { min-width: 96px; }
  .shot .art-keys.small kbd.wide { min-width: 76px; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
