#products { --product-accent:#4f6600; --product-surface:#fff; --product-soft:#f2f3f0; --product-muted:#626775; max-width:1400px; }
body.dark #products { --product-accent:#c6f432; --product-surface:#192132; --product-soft:#222b40; --product-muted:#a8ada3; }
body.products-page { background:#f2f3f0; }
body.dark.products-page { background:#101522; }
#products [hidden] { display:none !important; }
#products h2,#products h3,#products p { margin:0; overflow-wrap:anywhere; }
#products .card { background:var(--product-surface); padding:24px; border-radius:16px; box-shadow:0 4px 18px rgba(32,20,64,.045); display:flex; flex-direction:column; gap:20px; min-width:0; }
#products .products-intro { display:grid; gap:8px; margin-bottom:24px; color:var(--product-muted); line-height:1.6; }
#products .products-eyebrow { color:var(--product-accent); font-size:.7rem; font-weight:700; letter-spacing:.12em; }
#products .products-heading { display:flex; align-items:start; justify-content:space-between; flex-wrap:wrap; gap:16px; }
#products h2 { font-size:1.1rem; line-height:1.4; font-weight:700; }
#products h3 { font-size:.95rem; color:var(--product-accent); line-height:1.5; }
#products .products-heading p { margin-top:6px; font-size:.85rem; color:var(--product-muted); line-height:1.6; }
#products form { display:flex; flex-direction:column; gap:18px; }
#products .product-fields { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:18px; }
#products .product-pricing-inputs { padding:18px; border:1px solid var(--border); border-radius:12px; background:var(--product-soft); }
#products label { display:flex; flex-direction:column; gap:8px; font-size:.8rem; font-weight:600; min-width:0; line-height:1.5; }
#products input:not([type="checkbox"]):not([type="radio"]),#products select { min-width:0; margin:0; min-height:44px; background:var(--product-surface); font:inherit; }
#products input[readonly] { background:var(--product-soft); font-weight:700; color:var(--product-accent); }
#products .product-name-field { grid-column:span 2; }
#products .product-help,#products .product-source,#products .product-rules p { font-size:.8rem; line-height:1.65; color:var(--product-muted); }
#products .product-source { border-left:3px solid var(--primary-light); padding-left:12px; }
#products .product-submit { display:flex; align-items:center; flex-wrap:wrap; gap:14px; }
#products .product-submit .product-help { flex:1 1 220px; }
#products .btn { display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:44px; padding:10px 14px; max-width:100%; border:1px solid transparent; border-radius:9px; font:600 .8rem/1.5 'Inter',system-ui,sans-serif; white-space:normal; overflow-wrap:anywhere; transform:none; text-align:center; }
#products .btn-outline { color:var(--product-accent); border-color:var(--border); background:transparent; }
#products .btn-outline:hover:not(:disabled) { background:var(--product-soft); border-color:var(--product-accent); }
#products .btn:disabled { background:var(--product-soft); color:var(--product-muted); border-color:var(--border); opacity:1; }
#products .product-delete { background:transparent; color:#b91c1c; border-color:var(--border); }
body.dark #products .product-delete { color:#fda4af; }
#products :is(button,input,select,summary):focus-visible { outline:3px solid var(--primary-light); outline-offset:3px; }
#products .card.product-pricing { container-type:inline-size; gap:14px; }
#products .marketplace-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; align-items:start; }
#products .marketplace-card { display:flex; flex-direction:column; gap:10px; padding:14px; min-width:0; border:1px solid var(--border); border-radius:10px; background:var(--product-surface); }
#products .marketplace-card.selected { border-color:var(--product-accent); background:var(--product-soft); }
#products .marketplace-card h3 { color:var(--text); }
#products .marketplace-price { font-size:1.4rem; font-weight:700; color:var(--product-accent); letter-spacing:-.03em; line-height:1.2; font-variant-numeric:tabular-nums; }
#products .marketplace-placeholder { font-size:.8rem; line-height:1.5; color:var(--product-muted); }
#products dl { display:grid; gap:8px; margin:0; }
#products dl > div { display:flex; align-items:start; justify-content:space-between; gap:8px; font-size:.75rem; line-height:1.45; }
#products dt { color:var(--product-muted); min-width:0; overflow-wrap:anywhere; }
#products dd { text-align:right; font-weight:600; min-width:0; overflow-wrap:anywhere; margin:0; }
#products .marketplace-totals { grid-template-columns:1fr 1fr; gap:10px; margin-block:10px; }
#products .marketplace-totals > div { display:grid; gap:2px; }
#products .marketplace-totals dd { text-align:start; font-variant-numeric:tabular-nums; }
#products .marketplace-breakdown dl { margin-block:8px 0; }
#products .marketplace-use[aria-pressed="true"]::before {
  content:""; width:12px; height:12px; flex:none; background:currentColor;
  mask:url('/brand/symbol-dark.svg') center / contain no-repeat;
}
#products .marketplace-parameters { border-top:1px solid var(--border); padding-top:8px; }
@container (max-width: 760px) {
  #products .marketplace-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@container (max-width: 430px) {
  #products .marketplace-grid { grid-template-columns:minmax(0,1fr); }
}
#products .marketplace-parameters label { margin-top:14px; font-size:.75rem; }
#products summary { cursor:pointer; font-size:.8rem; color:var(--product-accent); line-height:1.6; font-weight:600; }
#products details p { margin-top:12px; }
#products .product-rules { border-top:1px solid var(--border); padding-top:16px; }
#products .product-message { padding:12px; background:var(--product-soft); color:var(--product-accent); border-radius:8px; line-height:1.6; font-size:.85rem; }
#products .product-message[data-state="error"] { color:#b91c1c; }
body.dark #products .product-message[data-state="error"] { color:#fda4af; }
#products .search-bar { margin:0; }
#products .product-table { table-layout:fixed; }
#products .product-table th,#products .product-table td { padding:12px 10px; overflow-wrap:anywhere; }
#products .product-table th:nth-child(2) { width:22%; }
#products .product-table th:last-child { width:20%; }
#products .product-table th button { background:none; border:0; color:inherit; font:inherit; cursor:pointer; text-align:left; }
#products .product-table-caption { display:block; color:var(--product-muted); font-size:.7rem; line-height:1.6; margin-top:4px; }
#products .product-row-actions { display:flex; flex-wrap:wrap; gap:8px; }
#products textarea{width:100%;min-width:0;font:inherit;background:var(--product-surface);color:var(--text);resize:vertical}
#products .product-ai-panel{padding:16px;border:1px solid var(--border);border-radius:10px;background:var(--product-soft)}
#products .product-ai-panel>summary{font-size:.85rem}#product-ai-body{display:grid;gap:16px;margin-top:16px}
#products .product-ai-actions{display:flex;align-items:end;gap:10px;flex-wrap:wrap}#products .product-ai-actions label{flex:1 1 200px}
#products .product-ai-suggestion{display:grid;gap:12px;background:var(--product-surface);padding:16px;border:1px solid var(--border);border-radius:8px}
#products .product-ai-suggestion>p{white-space:pre-wrap;font-size:.85rem;line-height:1.7}
#products .product-ai-gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(120px,1fr));gap:12px;margin-top:12px}
#products .product-ai-gallery img{width:100%;aspect-ratio:1;object-fit:contain;border:1px solid var(--border);border-radius:8px;background:var(--product-surface)}
#products .product-ai-gallery figcaption{font-size:.7rem;color:var(--product-muted);margin-top:6px}
@media(max-width:1250px) { #products .product-fields { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:850px) {
  #products .product-table thead { display:none; }
  #products .product-table,#products .product-table tbody,#products .product-table tr,#products .product-table td { display:block; width:100%; }
  #products .product-table tr { padding:12px 0; border-bottom:1px solid var(--border); }
  #products .product-table td { border:0; padding:8px 0; }
  #products .product-table td[data-label]::before { content:attr(data-label); display:block; font-size:.7rem; font-weight:600; color:var(--product-muted); margin-bottom:5px; }
}
@media(max-width:560px) { #products .product-fields { grid-template-columns:minmax(0,1fr); } #products .product-name-field { grid-column:auto; } #products .card { padding:18px; } #products .product-submit .btn { width:100%; } }
