/* brand */
h1, .brand { font-family: var(--brand-font); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 16px; color: var(--ink); letter-spacing: -.01em; margin: 0; }
.brand img { width: 28px; height: 28px; }
.tile-from { font-size: 11px; font-weight: 700; color: var(--leaf); text-transform: uppercase; letter-spacing: .05em; }

/* tab bar */
#home, #store { padding-bottom: 96px; }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; justify-content: center; gap: 8px;
  padding: 8px 16px max(10px, env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--surface) 92%, transparent);
  border-top: 1px solid var(--line); backdrop-filter: blur(10px);
}
.tabbar a {
  flex: 1; max-width: 200px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px;
  border-radius: 14px; text-decoration: none; color: var(--muted); font-size: 12.5px; font-weight: 700;
}
.tabbar a span { font-size: 21px; filter: grayscale(1); opacity: .7; }
.tabbar a.on { color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
.tabbar a.on span { filter: none; opacity: 1; }

/* store */
.store { max-width: 860px; margin: 0 auto; padding: 24px 16px; }
.store h1 { margin: 2px 0 0; font-size: 30px; }
.store h2 { font-size: 19px; margin: 26px 0 10px; font-family: var(--brand-font); }
.store-head { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin-bottom: 14px; }
.wallet { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 8px 14px; font-weight: 700; }
.search { width: 100%; font: inherit; font-size: 16px; padding: 12px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 12px 0 4px; scrollbar-width: none; }
.chip { flex: none; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 7px 13px; font-size: 14px; font-weight: 600; }
.chip.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.cards { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(190px, 46%); gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; scrollbar-width: none; }
@media (min-width: 700px) { .cards { grid-auto-columns: minmax(200px, 30%); } }
.scard {
  scroll-snap-align: start; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow); min-height: 176px;
}
.scard-icon { font-size: 30px; line-height: 1; width: 52px; height: 52px; display: grid; place-items: center; border-radius: 14px; background: color-mix(in srgb, var(--accent) 12%, var(--surface)); flex: none; }
.scard-title { font-weight: 750; font-size: 15.5px; }
.scard-tag { font-size: 13px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.scard-foot { margin-top: auto; width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 13px; }
.price { font-weight: 800; color: var(--accent); white-space: nowrap; }
.stars { color: var(--star); display: inline-flex; gap: 1px; vertical-align: -2px; }
.list { display: grid; gap: 8px; }
.srow { display: flex; gap: 12px; align-items: center; width: 100%; text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px; }
.srow-main { flex: 1; min-width: 0; display: grid; gap: 2px; }
.srow-main .muted { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty-note { text-align: center; padding: 32px 8px; }
.sell {
  display: grid; gap: 4px; margin-top: 28px; padding: 18px; border-radius: var(--radius); text-decoration: none; color: var(--ink);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 18%, var(--surface)), color-mix(in srgb, var(--leaf) 14%, var(--surface)));
  border: 1px solid var(--line);
}
.sell span { color: var(--muted); font-size: 14px; }
.sell .go { color: var(--accent); font-weight: 700; }
.back-link { border: 0; background: transparent; color: var(--accent); font-weight: 700; padding: 4px 0 12px; }
.status-note { background: var(--warn-bg); color: var(--warn-ink); padding: 8px 12px; border-radius: 10px; font-size: 14px; }
.lp-head { display: flex; gap: 16px; align-items: center; }
.lp-head h1 { font-size: 26px; margin: 0; }
.lp-head p { margin: 4px 0; }
.lp-icon { font-size: 48px; width: 88px; height: 88px; display: grid; place-items: center; border-radius: 22px; background: color-mix(in srgb, var(--accent) 12%, var(--surface)); flex: none; }
.lp-actions { display: flex; gap: 10px; margin: 18px 0; }
.lp-tagline { font-size: 18px; font-weight: 650; margin: 0 0 8px; }
.lp-desc { line-height: 1.55; }
.perks { list-style: none; padding: 0; display: grid; gap: 8px; margin: 18px 0; }
.perks li { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 14.5px; }
.rating-sum { display: flex; gap: 20px; align-items: center; margin-bottom: 12px; }
.rating-big { font-size: 44px; font-weight: 800; display: grid; line-height: 1; font-family: var(--brand-font); }
.bars { flex: 1; display: grid; gap: 3px; }
.bar-row { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); }
.bar { flex: 1; height: 6px; background: var(--line); border-radius: 6px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); }
.review-form { display: grid; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; margin-bottom: 14px; }
.review-form textarea, .sheet-input, .publish input:not([type=radio]), .publish textarea, .publish select {
  font: inherit; width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--ink);
}
.review-form textarea, .sheet-input { min-height: 80px; }
.star-pick { display: flex; gap: 4px; }
.star-pick button { border: 0; background: transparent; font-size: 30px; color: var(--line); padding: 0 2px; line-height: 1; }
.star-pick button.on { color: var(--star); }
.reviews { display: grid; gap: 10px; }
.review { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.review p { margin: 6px 0; }
.review-top { display: flex; justify-content: space-between; gap: 8px; }
.reply { background: var(--bg); border-left: 3px solid var(--accent); border-radius: 8px; padding: 8px 10px; margin-top: 8px; font-size: 14px; }
.reply p { margin: 4px 0 0; }
.link-btn { border: 0; background: transparent; color: var(--muted); text-decoration: underline; padding: 8px 0; font-size: 14px; }
.publish { display: grid; gap: 12px; }
.publish label { display: grid; gap: 4px; font-weight: 600; font-size: 14px; }
.publish textarea { min-height: 90px; }
.prices { border: 0; padding: 0; margin: 0; display: flex; gap: 8px; }
.prices legend { font-weight: 600; font-size: 14px; margin-bottom: 4px; }
.publish .price-opt { flex: 1; display: block; position: relative; }
.price-opt input { position: absolute; opacity: 0; }
.price-opt span { display: block; text-align: center; padding: 10px; border: 1px solid var(--line); border-radius: 12px; font-weight: 700; }
.price-opt input:checked + span { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); color: var(--accent); }
.price-opt input:focus-visible + span { outline: 2px solid var(--accent); }
.earn { display: flex; gap: 12px; margin: 12px 0; }
.earn div { flex: 1; display: grid; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.earn b { font-size: 24px; font-family: var(--brand-font); }
.mine-row { display: grid; gap: 2px; }
.mod { display: flex; gap: 8px; padding: 6px 0; }
.badge-status { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.badge-status.live { color: var(--leaf); }
.badge-status.pending { color: var(--warn-ink); }
.big-money { font-size: 40px; font-weight: 800; margin: 0; font-family: var(--brand-font); }
.try { position: fixed; inset: 0; z-index: 30; background: var(--bg); display: flex; flex-direction: column; }
.try iframe { flex: 1; border: 0; width: 100%; background: var(--bg); }
.try-note { font-size: 12px; font-weight: 700; color: var(--accent); padding-right: 8px; white-space: nowrap; }

/* payments */
.packs { display: flex; gap: 8px; margin: 12px 0 4px; }
.packs .btn { flex: 1; }
.payout-ok { color: var(--leaf); font-weight: 600; font-size: 14px; }
.plus-box { background: color-mix(in srgb, var(--accent) 10%, var(--surface)); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin: 8px 0; }
.plus-box p { margin: 0 0 10px; }

/* install banner, account, legal */
.install-banner { display: flex; gap: 12px; align-items: center; background: color-mix(in srgb, var(--accent) 10%, var(--surface)); border: 1px solid var(--line); border-radius: 16px; padding: 12px; margin-bottom: 14px; }
.install-banner img { width: 40px; height: 40px; border-radius: 10px; }
.install-banner div { flex: 1; display: grid; font-size: 14px; }
.install-banner span { color: var(--muted); font-size: 13px; }
.install-x { border: 0; background: transparent; font-size: 22px; color: var(--muted); padding: 0 4px; }
.kbd { display: inline-block; border: 1px solid var(--line); border-radius: 6px; padding: 0 6px; background: var(--bg); }
.legal-links { text-align: center; font-size: 13px; color: var(--muted); margin: 18px 0 4px; }
.legal-links a { color: var(--muted); }
.btn.danger { background: var(--danger); color: #fff; }
.lp-links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-top: 8px; }
.browse-link { display: block; text-align: center; margin-top: 22px; color: var(--accent); font-weight: 700; text-decoration: none; }

/* plans and sharing */
.plans { display: grid; gap: 8px; margin: 8px 0; }
.plan-card { display: flex; gap: 10px; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: var(--surface); }
.plan-card.current { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.plan-card p { margin: 2px 0 0; }
.members { display: grid; gap: 8px; }
.member { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--surface); }
.member-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.chips-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.mchip { font-size: 12.5px; background: color-mix(in srgb, var(--leaf) 12%, var(--surface)); border-radius: 999px; padding: 3px 9px; }
.join-card { display: flex; gap: 14px; align-items: center; margin: 18px 0 8px; }
.join-card h1 { margin: 0; font-size: 24px; }
.join-card p { margin: 4px 0 0; }
.publish label.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.publish label.consent input { width: auto; margin-top: 4px; }
