sanqiang-client-cart-ui-demo.html 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. <!DOCTYPE html>
  2. <html lang="zh-CN">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
  6. <title>陇耘鲜达 - 客户端购物车UI Demo</title>
  7. <style>
  8. :root {
  9. --green: #0a9f6d; --green-soft: #e9f9f2; --yellow: #d6a343; --bg: #f5f8f7;
  10. --card: #fff; --text: #1f2a26; --muted: #6b7b74; --border: #dcebe4; --danger: #d14343;
  11. }
  12. * { box-sizing: border-box; margin: 0; padding: 0; }
  13. body { font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif; background: var(--bg); color: var(--text); }
  14. .phone { max-width: 420px; margin: 0 auto; min-height: 100vh; padding-bottom: 90px; }
  15. .top { background: linear-gradient(145deg, #0a9f6d, #11b37a); color: #fff; padding: 16px; border-bottom-left-radius: 18px; border-bottom-right-radius: 18px; }
  16. .title { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
  17. .sub { font-size: 12px; opacity: 0.9; }
  18. .section { margin: 12px 16px; }
  19. .store { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 12px; }
  20. .store-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
  21. .store-name { font-size: 14px; font-weight: 600; }
  22. .tag { min-height: 24px; padding: 0 10px; border-radius: 12px; background: var(--green-soft); color: var(--green); font-size: 11px; display: inline-flex; align-items: center; }
  23. .item { display: grid; grid-template-columns: 84px 1fr; gap: 10px; padding: 10px 0; border-top: 1px solid #edf5f1; }
  24. .thumb { display: block; height: 84px; border-radius: 10px; background: linear-gradient(145deg, #f4fbf8, #e4f6ef); text-decoration: none; }
  25. .name { display: inline-flex; font-size: 13px; line-height: 1.35; min-height: 34px; color: var(--text); text-decoration: none; }
  26. .spec { margin-top: 4px; color: var(--muted); font-size: 11px; }
  27. .line { margin-top: 8px; display: flex; align-items: center; justify-content: space-between; }
  28. .price { font-size: 16px; color: var(--danger); font-weight: 700; }
  29. .qty { display: inline-flex; align-items: center; gap: 8px; }
  30. .qbtn { width: 30px; height: 30px; border-radius: 15px; border: 1px solid #b9decf; color: var(--green); display: flex; align-items: center; justify-content: center; }
  31. .qnum { min-width: 18px; text-align: center; font-size: 13px; }
  32. .coupon { margin-top: 10px; background: #fff7e8; border: 1px solid #f2dfb8; border-radius: 12px; padding: 10px; display: flex; justify-content: space-between; font-size: 12px; color: #8c6b2d; }
  33. .hint { margin-top: 8px; color: var(--muted); font-size: 11px; text-align: right; }
  34. .bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 0; width: min(420px, 100%); background: #fff; border-top: 1px solid var(--border); padding: 10px 14px 14px; display: flex; justify-content: space-between; align-items: center; }
  35. .total { font-size: 12px; color: var(--muted); }
  36. .total strong { display: block; color: var(--danger); font-size: 20px; margin-top: 2px; }
  37. .btn { min-height: 44px; padding: 0 18px; border-radius: 22px; background: var(--yellow); color: #fff; display: inline-flex; align-items: center; font-size: 14px; font-weight: 600; }
  38. </style>
  39. </head>
  40. <body>
  41. <main class="phone">
  42. <header class="top">
  43. <div class="title">购物车</div>
  44. <div class="sub">按供应站分组,支持一键结算</div>
  45. </header>
  46. <section class="section">
  47. <article class="store">
  48. <div class="store-head"><span class="store-name">陇耘鲜达 · 南山供应站</span><span class="tag">满 99 包邮</span></div>
  49. <div class="item">
  50. <a class="thumb" href="./sanqiang-client-product-detail-ui-demo.html" aria-label="查看商品详情"></a>
  51. <div>
  52. <a class="name" href="./sanqiang-client-product-detail-ui-demo.html">云南有机小青菜 500g</a>
  53. <div class="spec">规格:500g/份</div>
  54. <div class="line"><span class="price">¥8.80</span><span class="qty"><span class="qbtn">-</span><span class="qnum">2</span><span class="qbtn">+</span></span></div>
  55. </div>
  56. </div>
  57. <div class="item">
  58. <a class="thumb" href="./sanqiang-client-product-detail-ui-demo.html" aria-label="查看商品详情"></a>
  59. <div>
  60. <a class="name" href="./sanqiang-client-product-detail-ui-demo.html">散养土鸡蛋 30 枚装</a>
  61. <div class="spec">规格:30 枚/盒</div>
  62. <div class="line"><span class="price">¥29.80</span><span class="qty"><span class="qbtn">-</span><span class="qnum">1</span><span class="qbtn">+</span></span></div>
  63. </div>
  64. </div>
  65. <div class="coupon"><span>可用优惠券:满 120 减 15</span><span>去使用</span></div>
  66. <div class="hint">点击商品可预览详情页设计</div>
  67. </article>
  68. </section>
  69. </main>
  70. <footer class="bar">
  71. <div class="total">已选 3 件商品<strong>¥47.40</strong></div>
  72. <span class="btn">去结算</span>
  73. </footer>
  74. </body>
  75. </html>