/* The Shelf (feature: shelf). Light surfaces only; every class is prefixed shelf-. */

/* ---------- catalog hero and ingredients ---------- */
.shelf-hero { background: linear-gradient(120deg, #e6f3f3 0%, #eef6f7 55%, #f3f5f7 100%); color: var(--slate); border: 1px solid #d5e8e8; border-radius: 16px; padding: 32px 36px; }
.shelf-hero h1 { color: var(--navy); font-size: 32px; } .shelf-hero p { color: var(--slate); font-size: 16px; max-width: 680px; }
.shelf-ingredients { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 20px; }
.shelf-ingredient { background: #fff; border: 1px solid #d5e8e8; border-radius: 12px; padding: 14px 16px; font-size: 14px; color: var(--slate); }
.shelf-ingredient b { display: block; color: var(--navy); font-size: 15px; margin-bottom: 3px; }
.shelf-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }

/* ---------- filter rail ---------- */
.shelf-filters fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.shelf-filters legend { font-size: 14px; text-transform: uppercase; letter-spacing: .04em; color: var(--slate); font-weight: 700; padding: 0; margin-bottom: 6px; }
.shelf-filters label { display: flex; gap: 8px; align-items: center; font-size: 13.5px; padding: 3px 0; }
.shelf-filters input[type=checkbox] { width: auto; }
.shelf-toolbar { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.shelf-toolbar input[type=search] { max-width: 300px; } .shelf-toolbar select { width: auto; }
.shelf-toolbar .shelf-spacer { flex: 1; }

/* ---------- product cards ---------- */
.shelf-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.shelf-card { background: #fff; border: 1px solid var(--g1); border-radius: 12px; padding: 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; }
.shelf-card.shelf-service { border-left: 4px solid var(--teal); }
.shelf-card-top { display: flex; gap: 12px; align-items: center; }
.shelf-card-name { font-size: 16px; font-weight: 700; color: var(--navy); line-height: 1.2; margin: 0; } .shelf-card-name a { color: inherit; }
.shelf-card-kind { font-size: 12.5px; color: var(--muted); }
.shelf-card-summary { font-size: 13.5px; margin: 0; }
.shelf-card-price { font-size: 14px; } .shelf-card-price b { color: var(--navy); font-size: 17px; }
.shelf-card-use { font-size: 12.5px; color: var(--muted); }
.shelf-card-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: auto; } .shelf-card-foot small { margin-right: auto; }
.shelf-card-foot.has-demo small { flex-basis: 100%; }   /* Buy, Demo and View together on one row (DR-638) */
.shelf-lock { display: inline-flex; gap: 5px; align-items: center; font-size: 13px; color: var(--info); font-weight: 600; }
.shelf-saving { color: var(--ok); font-weight: 600; }

/* ---------- product page ---------- */
.shelf-prod-hero { display: grid; grid-template-columns: 1fr 360px; gap: 24px; align-items: start; }
.shelf-ident { display: flex; gap: 18px; align-items: center; } .shelf-ident h1 { margin-bottom: 2px; }
.shelf-ident .ph-logo { width: 72px; height: 72px; font-size: 18px; font-weight: 700; }
.shelf-price-panel { border-left: 5px solid var(--teal); }
.shelf-price-panel .shelf-retail { color: var(--muted); font-size: 15px; } .shelf-price-panel .shelf-retail.shelf-struck { text-decoration: line-through; }
.shelf-price-panel .shelf-member { font-size: 34px; font-weight: 800; color: var(--navy); line-height: 1.1; } .shelf-price-panel .shelf-member small { font-size: 13px; font-weight: 500; color: var(--muted); }
.shelf-domains { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.shelf-domain { border: 1px solid var(--g1); border-radius: 8px; padding: 10px 12px; font-size: 13.5px; background: #fff; } .shelf-domain b { color: var(--navy); display: block; }
.shelf-domain .shelf-ok { color: var(--ok); font-weight: 700; } .shelf-domain .shelf-no { color: var(--bad); font-weight: 700; }
.shelf-quote { border-left: 3px solid var(--teal); padding: 6px 12px; font-size: 14px; margin: 0 0 12px; } .shelf-quote footer { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); }
.shelf-clause { background: var(--g2); border-radius: 8px; padding: 12px 14px; font-size: 13.5px; font-family: Georgia, serif; color: var(--navy); }
.shelf-shot { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border: 1px solid var(--g1); border-radius: var(--radius-sm); display: block; }
.shelf-gallery figure { margin: 0; }

/* ---------- evaluation ---------- */
.shelf-dom { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 13.5px; padding: 6px 0; border-top: 1px solid var(--g1); }
.shelf-dom:first-child { border-top: 0; }
.shelf-score { display: grid; grid-template-columns: 150px 130px 1fr; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--g1); } .shelf-score:first-of-type { border-top: 0; }
.shelf-note { background: var(--g2); border-radius: 8px; padding: 10px 12px; font-size: 13.5px; margin-top: 8px; } .shelf-note p { margin: 4px 0 0; }
.shelf-note.shelf-mine { background: #eef6f7; }
.shelf-kmeta { font-size: 12px; color: var(--muted); margin-top: 3px; }
.shelf-kcard { display: block; color: inherit; } .shelf-kcard:hover { text-decoration: none; border-color: var(--teal); }
.shelf-agree dt { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-top: 8px; } .shelf-agree dd { margin: 0; color: var(--navy); font-weight: 600; }
.shelf-actions li { margin: 4px 0; }

/* ---------- earnings split bar (teal = builder, cyan = selling hub, grey = ICAA) ---------- */
.shelf-split { display: flex; height: 12px; border-radius: 6px; overflow: hidden; min-width: 140px; background: var(--g1); }
.shelf-split i { display: block; height: 100%; } .shelf-split .shelf-b { background: var(--teal); } .shelf-split .shelf-s { background: var(--cyan); } .shelf-split .shelf-v { background: var(--gold); }
.shelf-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.shelf-headline { font-size: 34px; font-weight: 800; color: var(--navy); line-height: 1.1; }
.shelf-inline { display: inline; }
.shelf-stack-sm > * + * { margin-top: 8px; }
.shelf-narrow { max-width: 760px; }

@media (max-width: 900px) {
  .shelf-grid, .shelf-ingredients, .shelf-strip, .shelf-prod-hero, .shelf-domains { grid-template-columns: 1fr; }
  .shelf-score { grid-template-columns: 1fr; }
}

/* Services typed on the product form (DR-640) */
.shelf-svc-row { border: 1px solid var(--g1); border-radius: 10px; padding: 10px 14px 4px; margin: 0 0 12px; } .shelf-svc-row legend { font-weight: 600; padding: 0 6px; }
.shelf-svc-price { border-top: 1px solid var(--g1); padding-top: 8px; margin-top: 8px; } .shelf-svc-price-name { margin: 0 0 4px; font-size: 14px; }

/* Get on the App Store: the fees as a stacked list that reads at any width (DR-642) */
.listing-items { list-style: none; margin: 0; padding: 0; }
.listing-items > li { border-top: 1px solid var(--g1); padding: 10px 0; }
.listing-items > li:first-child { border-top: 0; }
.listing-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; align-items: baseline; }
.listing-price { white-space: nowrap; }
.listing-purpose { margin: 4px 0 6px; font-size: 13px; color: var(--muted); }
.listing-state { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.listing-optional { background: var(--g3, #f6f8fa); margin: 0 -16px; padding: 10px 16px !important; }

/* The product page (the owner, 2026-10-16): the status and the steps first, the product information folds; a step not
   done reads in red, and the reader's own step is marked "Your step" (views/shelf/_todo.ejs, _listing.ejs). */
.listing-items > li.step-open { border-left: 4px solid var(--bad); padding-left: 10px; }
.listing-items > li.step-open .listing-head > b { color: var(--bad); }
.listing-items > li.step-open.mine { background: var(--bad-bg); }
dt.step-open, dd.step-open { color: var(--bad); }
dd.step-open.mine { font-weight: 600; }
.todo-list { margin: 4px 0 0; padding-left: 18px; color: var(--bad); }
.todo-list li { margin: 2px 0; }
.todo-list li.mine { font-weight: 700; }
.todo-list li small { color: var(--muted); font-weight: 400; }
.todo-list.compact { list-style: none; padding-left: 0; font-size: 13px; margin-top: 6px; }
.todo-text { color: var(--bad); } .todo-text.mine { font-weight: 700; }
.todo-badge { display: inline-block; background: var(--bad); color: #fff; font-size: 11px; font-weight: 700; line-height: 1.6; border-radius: 999px; padding: 0 8px; margin-right: 2px; }
.todo-badge.icaa { background: var(--slate); }
.product-info > summary { cursor: pointer; list-style: none; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 0; }
.product-info > summary::-webkit-details-marker { display: none; }
.product-info > summary h2 { margin: 0; }
.product-info > summary::after { content: "Show \25BE"; margin-left: auto; font-size: 13px; font-weight: 600; color: var(--teal-darker); }
.product-info[open] > summary::after { content: "Hide \25B4"; }
