/* p2pcars.in seller kit: calm, phone-first. No inline styles (CSP style-src 'self'). */
:root { --ink: #17212b; --muted: #5a6672; --line: #dfe4ea; --bg: #f5f7f9; --card: #fff; --brand: #1f3a5f;
    --brand-dark: #152a46; --tint: #e7edf4; --wa: #128c4a; --bad: #b42318; --radius: 10px; }
* { box-sizing: border-box; }
body { margin: 0; font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink);
    background: var(--bg); min-height: 100vh; display: flex; flex-direction: column; }
main { width: 100%; max-width: 1000px; margin: 0 auto; padding: 1.5rem 1rem 2.5rem; flex: 1; }
main.narrow { max-width: 40rem; }
h1 { font-size: 1.75rem; line-height: 1.2; margin: 0 0 .75rem; }
h2 { font-size: 1.2rem; margin: 1.75rem 0 .5rem; }
a { color: var(--brand); text-underline-offset: 2px; }
.faint { color: var(--muted); }
.small { font-size: .875rem; }
.top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 1rem;
    background: var(--card); border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: .5rem; font-weight: 800; letter-spacing: .06em;
    text-transform: uppercase; color: var(--brand); text-decoration: none; font-size: 1.15rem; }
.mark { width: 1.4rem; height: 1.4rem; }
.foot { max-width: 1000px; margin: 0 auto; width: 100%; padding: 1.25rem 1rem 2rem; border-top: 1px solid var(--line);
    display: flex; flex-wrap: wrap; gap: .4rem 1.1rem; font-size: .875rem; }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--ink); text-decoration: underline; }
.foot span { color: var(--muted); margin-left: auto; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; padding: .6rem 1.1rem;
    border-radius: 8px; border: 1px solid var(--brand); background: var(--brand); color: #fff; font: inherit;
    font-weight: 600; text-decoration: none; cursor: pointer; min-height: 2.75rem; }
.btn:hover { background: var(--brand-dark); }
.btn.small { padding: .35rem .8rem; min-height: 2.25rem; font-size: .9rem; }
.btn.big { padding: .8rem 1.4rem; font-size: 1.05rem; min-height: 3.1rem; }
.btn.ghost { background: var(--card); color: var(--brand); }
.btn.ghost:hover { background: var(--tint); }
.btn.wa { background: var(--wa); border-color: var(--wa); }
.btn.wa:hover { background: #0e723c; }
.btn[disabled] { opacity: .6; cursor: progress; }
button.link { background: none; border: 0; padding: 0; color: var(--brand); text-decoration: underline; font: inherit; cursor: pointer; }
button.link.danger { color: var(--bad); }
.hero { padding: 2rem 0 1rem; max-width: 44rem; }
.hero h1 { font-size: 2.1rem; }
.lead { font-size: 1.1rem; color: #33404c; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1rem; margin: 1.5rem 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; margin: 1rem 0; }
.card h2 { margin-top: 0; }
.note { background: var(--tint); border-radius: 8px; padding: .7rem .9rem; }
.error { background: #fdecea; color: var(--bad); border-radius: 8px; padding: .7rem .9rem; margin: .5rem 0; }
.ok { color: #0e723c; }
.form fieldset { border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); margin: 0 0 1rem; padding: .9rem 1rem 1rem; }
.form legend { font-weight: 700; padding: 0 .3rem; }
.form label, .stack label { display: flex; flex-direction: column; gap: .25rem; font-weight: 500; margin: 0 0 .8rem; flex: 1; min-width: 0; }
.row { display: flex; gap: .8rem; flex-wrap: wrap; }
.row > label { min-width: 9rem; }
input, select, textarea { font: inherit; padding: .55rem .65rem; border: 1px solid #c2cad3; border-radius: 8px; background: #fff;
    color: var(--ink); width: 100%; font-weight: 400; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand); outline-offset: 0; }
.agency-name { font-size: 1.35rem; font-weight: 800; color: var(--ink); text-decoration: none; }
.top nav { display: flex; gap: .6rem; align-items: center; }
.top form { margin: 0; }
.linkbar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; background: var(--card); border: 1px solid var(--line);
    border-radius: var(--radius); padding: .55rem .8rem; margin: 0 0 1rem; }
.linkbar code { font-size: .95rem; word-break: break-all; flex: 1; min-width: 12rem; }
.tabs { display: flex; gap: .3rem; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin: 0 0 1rem; }
.tabs a { padding: .5rem .8rem; text-decoration: none; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; font-weight: 600; }
.tabs a.on { color: var(--ink); border-color: var(--brand); }
.badge { display: inline-block; min-width: 1.4rem; padding: 0 .4rem; border-radius: 999px; background: var(--tint); color: var(--ink);
    font-size: .8rem; text-align: center; margin-left: .2rem; }
.badge.hot { background: var(--brand); color: #fff; }
.toolbar { display: flex; gap: .6rem; flex-wrap: wrap; margin: 0 0 1rem; align-items: center; }
.toolbar form { display: flex; gap: .4rem; flex: 1; min-width: 14rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: .9rem; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: inherit; display: flex; flex-direction: column; }
.tile:hover { border-color: #b7c2ce; }
.tile .cover { aspect-ratio: 4 / 3; background: #dde3e9; width: 100%; object-fit: cover; display: block; }
.tile .cover.none { display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: .9rem; }
.tile .body { padding: .6rem .75rem .75rem; display: flex; flex-direction: column; gap: .15rem; }
.tile .name { font-weight: 700; }
.tile .price { font-weight: 800; font-size: 1.05rem; }
.chips { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .3rem; }
.chip { font-size: .78rem; border: 1px solid var(--line); border-radius: 999px; padding: .05rem .5rem; color: var(--muted); }
.chip.warn { border-color: #e3b341; color: #7a5600; background: #fff8e6; }
.chip.good { border-color: #9bd3ae; color: #0e723c; background: #eef9f1; }
.empty { text-align: center; padding: 2.5rem 1rem; color: var(--muted); }
.empty .actions { justify-content: center; }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; }
.actions form { margin: 0; }
.btn.danger { background: var(--card); color: var(--bad); border-color: #e7b4ae; }
.btn.danger:hover { background: #fdecea; }
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(7.5rem, 1fr)); gap: .5rem; margin: .6rem 0; }
.photos figure { margin: 0; position: relative; }
.photos img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; display: block; cursor: zoom-in; background: #dde3e9; }
.photos figure.is-cover img { outline: 3px solid var(--brand); outline-offset: -3px; }
.photos .ph-actions { position: absolute; top: .25rem; right: .25rem; display: flex; gap: .25rem; }
.photos .ph-actions form { margin: 0; }
.photos .ph-actions button { background: rgba(23, 33, 43, .75); color: #fff; border: 0; border-radius: 6px; padding: .1rem .45rem; font: inherit; font-size: .8rem; cursor: pointer; }
.photos .cover-tag { position: absolute; left: .25rem; bottom: .25rem; background: var(--brand); color: #fff; font-size: .72rem; border-radius: 4px; padding: 0 .35rem; }
.pick { display: flex; align-items: center; justify-content: center; border: 2px dashed #c2cad3; border-radius: var(--radius); padding: 1rem;
    cursor: pointer; font-weight: 600; color: var(--brand); background: var(--card); }
.pick input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.status-line { min-height: 1.4rem; font-size: .9rem; color: var(--muted); }
.saved { font-size: .85rem; color: var(--muted); }
.layout2 { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1.25rem; align-items: start; }
.facts { list-style: none; padding: 0; margin: .4rem 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .3rem .8rem; }
.facts li span { display: block; font-size: .8rem; color: var(--muted); }
.big-price { font-size: 1.5rem; font-weight: 800; margin: .2rem 0; }
dialog { border: 0; border-radius: var(--radius); padding: 1.1rem 1.2rem; max-width: 28rem; width: calc(100% - 2rem); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
dialog::backdrop { background: rgba(23, 33, 43, .45); }
dialog h2 { margin-top: 0; }
dialog.viewer { max-width: 96vw; width: auto; padding: .4rem; background: #111; }
dialog.viewer img { max-width: 92vw; max-height: 86vh; display: block; }
video.reel { width: 100%; max-width: 22rem; aspect-ratio: 9 / 16; background: #000; border-radius: var(--radius); display: block; }
.hero { padding: 1.5rem 0 .5rem; max-width: 44rem; }
.hero h1 { font-size: 2rem; }
.lead { font-size: 1.1rem; color: #33404c; }
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); gap: 1rem; }
.hint { font-size: .88rem; color: var(--muted); min-height: 1.3rem; margin: -.4rem 0 .6rem; }
.hint.bad { color: var(--bad); }
.sticky-submit { position: sticky; bottom: 0; background: var(--bg); padding: .7rem 0; border-top: 1px solid var(--line); }
.sticky-submit .btn { width: 100%; }
table.list { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
table.list th, table.list td { text-align: left; padding: .55rem .7rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.list th { font-size: .85rem; color: var(--muted); font-weight: 600; }
.toast { position: fixed; left: 50%; bottom: 1.2rem; transform: translateX(-50%); background: var(--ink); color: #fff; padding: .5rem 1rem; border-radius: 8px; font-size: .92rem; }
[hidden] { display: none !important; }
@media (max-width: 760px) {
    .layout2 { grid-template-columns: 1fr; }
    .hero h1 { font-size: 1.6rem; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); }
}
