:root { --ink:#10231d; --muted:#64756f; --line:#dce8e3; --paper:#fbfdfc; --mint:#10b981; --mint-dark:#047857; --soft:#edf9f4; --white:#fff; --shadow:0 18px 45px rgba(20,55,43,.09); }
* { box-sizing:border-box; }
html { scroll-behavior:smooth; }
body { margin:0; color:var(--ink); background:var(--paper); font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; line-height:1.5; }
button,input,textarea,select { font:inherit; }
.market-nav { min-height:72px; display:flex; align-items:center; justify-content:space-between; gap:24px; padding:0 max(24px,calc((100vw - 1180px)/2)); background:rgba(255,255,255,.92); border-bottom:1px solid var(--line); position:sticky; top:0; z-index:20; backdrop-filter:blur(12px); }
.market-brand { display:flex; align-items:center; gap:10px; color:var(--ink); text-decoration:none; font-weight:800; letter-spacing:-.02em; }
.brand-mark { width:34px; height:34px; display:grid; place-items:center; color:#fff; background:var(--ink); border-radius:10px; }
.market-nav nav { display:flex; align-items:center; gap:6px; }
.market-nav nav a { color:#51635d; text-decoration:none; padding:9px 13px; border-radius:10px; font-size:14px; font-weight:650; }
.market-nav nav a:hover,.market-nav nav a.active { color:var(--mint-dark); background:var(--soft); }
.market-nav .owner-link { border:1px solid var(--line); background:#fff; }
main { overflow:hidden; }
.market-hero { min-height:480px; display:grid; grid-template-columns:1.2fr .8fr; align-items:center; gap:50px; padding:74px max(24px,calc((100vw - 1180px)/2)); background:radial-gradient(circle at 88% 30%,#c9f7e4 0,transparent 28%),linear-gradient(135deg,#f7fcf9,#eef9f4); border-bottom:1px solid var(--line); }
.kicker { color:var(--mint-dark); font-size:12px; font-weight:850; letter-spacing:.16em; }
.market-hero h1 { margin:12px 0 22px; font-size:clamp(48px,7vw,82px); line-height:.98; letter-spacing:-.065em; max-width:760px; }
.market-hero h1 span { color:var(--mint); }
.market-hero p { max-width:620px; margin:0; color:var(--muted); font-size:18px; }
.hero-trust { display:flex; flex-wrap:wrap; gap:20px; margin-top:28px; color:#385049; font-size:13px; font-weight:650; }
.hero-orbit { height:320px; position:relative; }
.hero-orbit::before { content:""; position:absolute; inset:15% 10%; border:1px dashed #80d9b5; border-radius:50%; transform:rotate(-12deg); }
.orbit-card { position:absolute; width:150px; aspect-ratio:4/3; display:grid; place-items:center; border-radius:22px; color:#fff; font-weight:800; letter-spacing:-.02em; box-shadow:var(--shadow); }
.orbit-one { left:3%; top:34%; background:#123c31; transform:rotate(-8deg); }
.orbit-two { right:7%; top:8%; background:#10b981; transform:rotate(9deg); }
.orbit-three { right:2%; bottom:3%; color:#146c50; background:#d8f7e9; transform:rotate(-4deg); }
.catalog { max-width:1180px; margin:0 auto; padding:72px 24px 90px; }
.catalog-head { display:flex; justify-content:space-between; align-items:end; gap:24px; margin-bottom:30px; }
.catalog h2 { margin:6px 0 0; font-size:clamp(28px,4vw,42px); letter-spacing:-.045em; }
.search-box { min-width:280px; display:flex; align-items:center; gap:8px; padding:0 14px; background:#fff; border:1px solid var(--line); border-radius:14px; box-shadow:0 8px 26px rgba(22,55,44,.05); }
.search-box input { width:100%; padding:12px 0; border:0; outline:0; color:var(--ink); background:transparent; }
.market-status { min-height:20px; color:var(--muted); }
.market-status.error { color:#b42318; }
.marketplace-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(290px,1fr)); gap:24px; margin-top:18px; }
.listing-card { min-width:0; overflow:hidden; background:#fff; border:1px solid var(--line); border-radius:22px; box-shadow:0 10px 34px rgba(22,55,44,.055); transition:transform .2s ease,box-shadow .2s ease; display:flex; flex-direction:column; }
.listing-card:hover { transform:translateY(-4px); box-shadow:var(--shadow); }
.listing-media { position:relative; aspect-ratio:16/10; overflow:hidden; background:linear-gradient(145deg,#d8f7e9,#effbf6); }
.listing-media img { width:100%; height:100%; object-fit:cover; display:block; }
.listing-media.no-image::after { content:"PROMPT COLLECTION"; position:absolute; inset:0; display:grid; place-items:center; color:#0d7053; font-size:13px; font-weight:850; letter-spacing:.16em; }
.listing-badge { position:absolute; left:14px; top:14px; padding:7px 10px; border-radius:999px; color:#fff; background:rgba(16,35,29,.84); font-size:11px; font-weight:800; backdrop-filter:blur(8px); }
.listing-body { padding:22px; display:flex; flex-direction:column; gap:12px; flex:1; }
.listing-meta { display:flex; justify-content:space-between; gap:12px; color:var(--mint-dark); font-size:12px; font-weight:750; text-transform:uppercase; letter-spacing:.07em; }
.listing-card h3 { margin:0; font-size:22px; line-height:1.2; letter-spacing:-.03em; }
.listing-description { margin:0; color:var(--muted); font-size:14px; flex:1; }
.prompt-preview { display:flex; flex-direction:column; gap:7px; padding:12px; background:#f7fbf9; border-radius:12px; }
.prompt-preview span { display:flex; gap:7px; color:#49605a; font-size:12px; }
.prompt-preview span::before { content:"✓"; color:var(--mint); font-weight:900; }
.listing-footer { display:flex; align-items:center; justify-content:space-between; gap:16px; padding-top:4px; }
.listing-price { font-size:24px; font-weight:850; letter-spacing:-.035em; }
.buy-button,.button { cursor:pointer; border:0; border-radius:12px; padding:11px 16px; color:#fff; background:var(--ink); font-weight:750; transition:background .2s,transform .2s; text-decoration:none; }
.buy-button:hover,.button:hover { background:var(--mint-dark); }
.buy-button:disabled { cursor:wait; opacity:.65; }
.watch-button { width:100%; cursor:pointer; padding:10px 12px; display:flex; justify-content:center; align-items:center; gap:8px; color:var(--mint-dark); background:var(--soft); border:1px solid #c7eadc; border-radius:11px; font-weight:750; }
.watch-button:hover { background:#dff7ec; }
.empty-state { grid-column:1/-1; padding:70px 24px; text-align:center; color:var(--muted); background:#fff; border:1px dashed #b9cdc5; border-radius:20px; }
.video-dialog { width:min(900px,calc(100vw - 32px)); padding:0; overflow:hidden; color:var(--ink); background:#fff; border:1px solid var(--line); border-radius:22px; box-shadow:0 28px 90px rgba(7,31,23,.28); }
.video-dialog::backdrop { background:rgba(8,29,23,.72); backdrop-filter:blur(5px); }
.video-dialog-head { padding:18px 20px; display:flex; justify-content:space-between; align-items:center; gap:20px; }
.video-dialog-head h2 { margin:3px 0 0; font-size:24px; letter-spacing:-.03em; }
.video-close { width:40px; height:40px; cursor:pointer; display:grid; place-items:center; border:1px solid var(--line); border-radius:50%; color:var(--ink); background:#fff; font-size:26px; line-height:1; }
.video-player { width:100%; aspect-ratio:16/9; background:#07110e; }
.video-player iframe,.video-player video { width:100%; height:100%; display:block; border:0; object-fit:contain; }
.video-note { margin:0; padding:12px 20px 16px; color:var(--muted); font-size:12px; }
.market-footer { max-width:1180px; margin:0 auto; padding:26px 24px; display:flex; justify-content:space-between; gap:20px; color:var(--muted); border-top:1px solid var(--line); font-size:13px; }

/* Owner studio */
.owner-main { max-width:1180px; margin:0 auto; padding:54px 24px 90px; }
.owner-intro { max-width:720px; margin-bottom:28px; }
.owner-intro h1 { margin:8px 0; font-size:48px; letter-spacing:-.05em; }
.owner-intro p { color:var(--muted); }
.owner-card { padding:26px; background:#fff; border:1px solid var(--line); border-radius:20px; box-shadow:0 10px 34px rgba(22,55,44,.05); margin-bottom:24px; }
.owner-card h2 { margin-top:0; letter-spacing:-.03em; }
.form-grid { display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.field { display:flex; flex-direction:column; gap:7px; }
.field.full { grid-column:1/-1; }
.field label,.prompt-block label { font-size:13px; font-weight:750; }
.field input,.field textarea,.field select,.prompt-block input,.prompt-block textarea { width:100%; padding:12px 13px; color:var(--ink); background:#fbfdfc; border:1px solid #cddcd6; border-radius:11px; outline:0; }
.field input:focus,.field textarea:focus,.field select:focus,.prompt-block input:focus,.prompt-block textarea:focus { border-color:var(--mint); box-shadow:0 0 0 3px rgba(16,185,129,.12); }
.prompt-builder-head { display:flex; justify-content:space-between; align-items:center; margin:28px 0 12px; }
.prompt-block { padding:18px; margin-bottom:12px; background:#f7fbf9; border:1px solid var(--line); border-radius:15px; }
.prompt-block-head { display:flex; align-items:center; justify-content:space-between; margin-bottom:12px; }
.prompt-fields { display:grid; grid-template-columns:1fr 150px; gap:12px; }
.prompt-fields .wide { grid-column:1/-1; }
.ghost-button { cursor:pointer; color:var(--mint-dark); background:#fff; border:1px solid #b9dace; border-radius:10px; padding:9px 13px; font-weight:700; }
.danger-link { cursor:pointer; color:#b42318; background:transparent; border:0; font-weight:700; }
.cover-editor { display:flex; gap:24px; flex-wrap:wrap; align-items:flex-start; margin-top:16px; }
.cover-editor canvas { border-radius:16px; border:1px solid var(--line); max-width:320px; width:100%; height:auto; background:#edf9f4; }
.cover-controls { flex:1; min-width:240px; display:flex; flex-direction:column; gap:12px; }
.status { min-height:22px; margin-top:10px; color:var(--muted); }
.status.error { color:#b42318; }
.status.success { color:var(--mint-dark); }
.listing-row { display:flex; align-items:center; gap:10px; flex-wrap:wrap; padding:14px 0; border-bottom:1px solid var(--line); }

/* Delivery library */
.delivery-shell { max-width:900px; margin:0 auto; padding:60px 24px 90px; }
.delivery-shell h1 { font-size:44px; letter-spacing:-.05em; }
.delivery-library { display:grid; gap:16px; margin-top:26px; }
.sync-card { margin:24px 0; padding:18px; display:grid; grid-template-columns:1fr auto; gap:14px 20px; align-items:center; background:#edf9f4; border:1px solid #bfe8d7; border-radius:16px; }
.sync-card p { margin:3px 0 0; color:var(--muted); font-size:13px; }
.sync-card .status { grid-column:1/-1; margin:0; }
.delivery-prompt { padding:22px; background:#fff; border:1px solid var(--line); border-radius:18px; }
.delivery-prompt.locked { background:#f5f8f7; }
.delivery-prompt h3 { margin:0 0 5px; }
.delivery-prompt p { margin:0 0 14px; color:var(--muted); }
.lock-note { display:inline-flex; padding:7px 10px; border-radius:999px; color:#5d6e68; background:#e4ebe8; font-size:12px; font-weight:750; }
.delivery-content { white-space:pre-wrap; word-break:break-word; background:#f7fbf9; border:1px solid var(--line); border-radius:12px; padding:18px; max-height:65vh; overflow:auto; }

@media (max-width:760px) { .market-nav { align-items:flex-start; padding:14px 18px; } .market-nav nav { flex-wrap:wrap; justify-content:flex-end; } .market-nav nav a { padding:7px 8px; } .market-hero { grid-template-columns:1fr; padding-top:52px; } .hero-orbit { display:none; } .catalog-head { align-items:stretch; flex-direction:column; } .search-box { min-width:0; } .form-grid,.prompt-fields { grid-template-columns:1fr; } .field.full,.prompt-fields .wide { grid-column:auto; } .market-footer { flex-direction:column; } }
.offer-brief{padding:1rem 1.1rem;border:1px solid #dbeafe;border-radius:14px;background:linear-gradient(135deg,#f8fbff,#f5f3ff)}.offer-brief h3{margin:.25rem 0}.offer-brief p{margin:0;color:#64748b}.buyer-brief{margin:1rem 0;border:1px solid #e2e8f0;border-radius:12px;background:#f8fafc}.buyer-brief summary{cursor:pointer;padding:.8rem 1rem;font-weight:800;color:#312e81}.buyer-brief>p,.buyer-brief>div{padding:0 1rem .75rem;margin:0;color:#475569}.buyer-brief strong{display:block;color:#0f172a;margin-bottom:.25rem}.buyer-brief ul{margin:.25rem 0 0;padding-left:1.15rem}.buyer-brief li{margin:.25rem 0}
