/* TFT Mart — shop / category page */

.shop { max-width: var(--page-w); margin: 0 auto; padding: 0 var(--page-pad) 64px; }
.shop-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 14px; }
.shop-head .page-h { margin: 0; }
.shop-sub { display: none; }
.shop-tools { display: flex; align-items: center; gap: 10px; }
.sort-sel { height: 44px; padding: 0 40px 0 14px; border: 1px solid var(--line-2); border-radius: 6px; background: #fff; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.fbtn { height: 44px; padding: 0 16px; border: 1px solid var(--line-2); border-radius: 6px; background: #fff; color: var(--ink-2); display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; transition: border-color .2s; }
.fbtn:hover { border-color: var(--navy); }
.fbtn-n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--navy); color: #fff; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }

/* Filter drawer */
.fd { position: fixed; inset: 0; z-index: 120; }
.fd-scrim { position: absolute; inset: 0; border: 0; background: rgba(8,22,47,.45); animation: fadeIn .25s ease both; }
.fd-panel { position: absolute; top: 0; right: 0; bottom: 0; width: 400px; max-width: 100%; background: #fff; display: flex; flex-direction: column; box-shadow: -20px 0 50px rgba(8,22,47,.18); animation: drawerIn .36s var(--ease-out) both; }
.fd.closing .fd-panel { animation: drawerOut .26s ease-in both; }
.fd.closing .fd-scrim { animation: fadeOut .26s ease-in both; }
.fd-head { height: 64px; flex-shrink: 0; display: flex; align-items: center; justify-content: space-between; padding: 0 12px 0 24px; border-bottom: 1px solid var(--line); }
.fd-x { width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; color: var(--ink-2); display: flex; align-items: center; justify-content: center; }
.fd-scroll { flex: 1; overflow-y: auto; padding: 0 24px; }
.fgroup { padding: 18px 0; border-top: 1px solid var(--line); }
.fgroup:first-child, .fsort + .fgroup { border-top: 0; }
/* Sorting lives in the sheet on phones only (the dropdown is used above 640px). */
.fsort, .fsort-lb { display: none; }
.fpills { display: flex; flex-wrap: wrap; gap: 8px; }
.fgroup.last { border-bottom: 1px solid var(--line); padding: 16px 0; }
.fh { font-size: 15px; font-weight: 600; margin-bottom: 10px; }
.fsizes { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 6px; }
.fopt { height: 40px; border-radius: 6px; font-size: 13px; font-weight: 600; transition: all .2s; border: 1.5px solid var(--line-2); background: #fff; color: var(--ink-2); }
.fopt:hover { border-color: var(--navy); }
.fopt[aria-pressed="true"] { border-color: var(--navy); background: var(--navy); color: #fff; }
.fradios { display: flex; flex-direction: column; }
.radio { display: flex; align-items: center; gap: 10px; height: 40px; border: 0; background: none; padding: 0; font-size: 14px; color: var(--ink-2); text-align: left; }
.radio .ring { width: 18px; height: 18px; flex-shrink: 0; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all .2s; border: 1.5px solid #7D6F85; background: #fff; }
.radio .ring::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: #fff; opacity: 0; }
.radio[aria-checked="true"] .ring { border-color: var(--navy); background: var(--navy); }
.radio[aria-checked="true"] .ring::after { opacity: 1; }
.radio .lb { flex: 1; }
.radio[data-cat] .lb { font-family: var(--font-head); font-style: normal; font-weight: 600; }
.radio small { font-size: 13px; color: #7D6F85; }
.fcolors { display: flex; flex-wrap: wrap; gap: 10px; }
.swatch { width: 34px; height: 34px; border-radius: 50%; padding: 3px; background: #fff; border: 2px solid transparent; transition: border-color .2s; }
.swatch[aria-pressed="true"] { border-color: var(--navy); }
.swatch span { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.stock { width: 100%; display: flex; align-items: center; justify-content: space-between; border: 0; background: none; padding: 0; font-size: 15px; font-weight: 600; color: var(--ink-2); }
.track { width: 40px; height: 24px; border-radius: 999px; position: relative; transition: background .25s; background: #DCD2E3; }
.knob { position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .25s var(--ease-out); }
.stock[aria-checked="true"] .track { background: var(--navy); }
.stock[aria-checked="true"] .knob { transform: translateX(16px); }
.fd-foot { flex-shrink: 0; display: flex; gap: 10px; padding: 16px 24px 20px; border-top: 1px solid var(--line); }
.fd-foot .clear { flex: 0 0 120px; height: 48px; border: 1.5px solid var(--line-2); border-radius: 4px; background: #fff; color: var(--ink-2); font-size: 15px; font-weight: 600; }
.fd-foot .show { flex: 1; height: 48px; border: 0; border-radius: 4px; background: var(--navy); color: #fff; font-size: 15px; font-weight: 600; }

/* Results */
.results { margin-top: 24px; }
.active-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: -6px 0 20px; }
.achip { height: 32px; padding: 0 10px 0 12px; border: 0; border-radius: 999px; background: var(--navy-tint); color: var(--navy); font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.empty { padding: 72px 24px; text-align: center; border: 1px dashed var(--line-2); border-radius: 12px; }
.empty .ic { width: 64px; height: 64px; border-radius: 50%; background: var(--navy-tint); margin: 0 auto 16px; display: flex; align-items: center; justify-content: center; }
.empty p { margin: 6px 0 20px; font-size: 15px; color: var(--slate); }
.empty button { height: 44px; padding: 0 22px; border: 0; border-radius: 4px; background: var(--navy); color: #fff; font-size: 15px; font-weight: 600; }
.more { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 40px; font-size: 14px; color: var(--muted); }
.more .bar { width: 220px; height: 3px; border-radius: 999px; background: var(--line); overflow: hidden; }
.more .bar div { height: 100%; background: var(--navy); border-radius: 999px; transition: width .3s var(--ease-out); }
.lm { margin-top: 6px; height: 46px; padding: 0 28px; border: 1.5px solid var(--navy); border-radius: 4px; background: #fff; color: var(--navy); font-size: 14px; font-weight: 700; letter-spacing: .12em; transition: all .2s; }
.lm:hover { background: var(--navy); color: #fff; }

@media (max-width: 1180px) { .shop .grid4 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1024px) { .shop .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .shop { padding-bottom: 48px; }
  /* Phones: title on the left, a square filter button in the right corner (design: ShopMobile). */
  .shop-head { flex-wrap: nowrap; gap: 12px; }
  .shop-head .page-h { min-width: 0; }
  .shop-tools .sel-wrap { display: none; }
  .fbtn { position: relative; flex-shrink: 0; width: 44px; padding: 0; justify-content: center; border-radius: 8px; }
  .fbtn-lb { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .fbtn-n { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; padding: 0 5px; font-size: 10px; border: 2px solid var(--bg); }
  .fsort { display: block; }
  .fsort-lb { display: inline; }
  /* Phones: hope71.com's collection layout — 16px sides, breadcrumbs 32px under the header, a 30px bold title with
     a "Showing all products in …" line, 32px to the grid, two columns 8px apart. Cards stay New Arrivals cards. */
  .shop { padding-left: 16px; padding-right: 16px; }
  .shop .crumbs { padding-top: 32px; font-size: 14px; line-height: 20px; }
  .shop-head { margin-top: 24px; align-items: flex-start; }
  .shop-head .page-h { font-size: 30px; font-weight: 700; line-height: 36px; }
  .shop-sub { display: block; margin: 4px 0 0; font-size: 14px; line-height: 20px; color: var(--muted); }
  .results { margin-top: 32px; }
  .active-chips { margin: -14px 0 16px; }
  /* The category chip repeats the title on phones; other filter chips (size, price…) still show. */
  .shop-tools { margin-bottom: -8px; }
  .shop .grid4 { column-gap: 8px; row-gap: 8px; }
  .fsort-no { display: none; }
  .fsort + .fgroup { border-top: 1px solid var(--line); }
  .fd-panel { width: 100%; }
}

/* Offer banner (Admin → Settings → Combo offers): one slim strip under the title, bold enough to be noticed; several
   offers take turns. Each colour sets --ob-a → --ob-b (its gradient) and --ob (its deep shade, for the white parts' text). */
.offer-bar { position: relative; margin: 4px 0 20px; }
.offer-bar[hidden] { display: none; }
.ob-purple { --ob: #3C0F62; --ob-a: #5A1D8C; --ob-b: #7A33B5; }
.ob-orchid { --ob: #6E1A68; --ob-a: #6522A3; --ob-b: #C04BB3; }
.ob-rose { --ob: #6B2C3E; --ob-a: #923E55; --ob-b: #B8566F; }
.ob-green { --ob: #065F46; --ob-a: #047857; --ob-b: #10B981; }
.ob-gold { --ob: #713F12; --ob-a: #A16207; --ob-b: #D69E2E; }
.ob-slide { position: relative; display: flex; align-items: center; gap: 14px; min-height: 70px; padding: 12px 54px 12px 14px; overflow: hidden; color: #FFFFFF; border-radius: 16px;
  background: linear-gradient(100deg, var(--ob-a) 0%, var(--ob-b) 100%);
  box-shadow: 0 10px 24px -14px var(--ob-a), 0 2px 6px -2px rgba(15,23,42,.18); animation: obIn .45s cubic-bezier(.22,1,.36,1) both; }
.ob-slide[hidden] { display: none; }
/* Depth: soft rings on the right; and a band of light sweeping across every few seconds. */
.ob-slide::before { content: ''; position: absolute; right: -40px; top: -60px; width: 190px; height: 190px; border-radius: 50%; box-shadow: 0 0 0 22px rgba(255,255,255,.07), 0 0 0 48px rgba(255,255,255,.04); pointer-events: none; }
.ob-slide::after { content: ''; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.28), transparent); transform: skewX(-18deg); animation: obSweep 5s ease-in-out 1s infinite; pointer-events: none; }
.ob-ic { position: relative; flex-shrink: 0; width: 46px; height: 46px; border-radius: 14px; background: #FFFFFF; color: var(--ob-a); display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 14px -6px rgba(0,0,0,.35); animation: obPop 5s ease-in-out 1s infinite; }
.ob-tx { position: relative; flex: 1; min-width: 0; }
.ob-tag { display: inline-flex; align-items: center; height: 18px; margin-bottom: 4px; padding: 0 8px; border-radius: 999px; background: rgba(255,255,255,.2); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ob-h { display: block; font-size: 16px; font-weight: 800; line-height: 1.22; letter-spacing: -.005em; text-shadow: 0 1px 1px rgba(0,0,0,.12); }
.ob-s { display: block; margin-top: 2px; font-size: 12.5px; font-weight: 500; line-height: 1.4; color: rgba(255,255,255,.9); }
.ob-s b { font-weight: 800; color: #FFFFFF; }
/* Progress towards the offer: "1/3", filling up; full and shining once unlocked. */
.ob-prog { display: flex; align-items: center; gap: 8px; margin-top: 6px; max-width: 280px; }
.ob-bar { position: relative; flex: 1; height: 6px; border-radius: 999px; background: rgba(255,255,255,.28); overflow: hidden; }
.ob-bar i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 999px; background: #FFFFFF; transition: width .5s cubic-bezier(.22,1,.36,1); }
.ob-done .ob-bar i { background: #F4ECFC; }
.ob-n { font-size: 11.5px; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ob-go { position: relative; flex-shrink: 0; height: 40px; padding: 0 18px; border-radius: 999px; background: #FFFFFF; color: var(--ob); font-size: 13.5px; font-weight: 800; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; white-space: nowrap; box-shadow: 0 8px 16px -10px rgba(0,0,0,.45); transition: transform .15s, box-shadow .15s; }
.ob-go:hover { transform: translateY(-1px); box-shadow: 0 12px 20px -12px rgba(0,0,0,.5); }
.ob-x { position: absolute; z-index: 1; top: 10px; right: 10px; width: 30px; height: 30px; border: 0; border-radius: 50%; background: rgba(255,255,255,.18); color: #FFFFFF; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background .15s; }
.ob-x:hover, .ob-x:focus-visible { background: rgba(255,255,255,.32); }
.ob-dots { position: absolute; z-index: 1; right: 14px; bottom: 9px; display: flex; gap: 2px; }
.ob-dot { width: 16px; height: 12px; padding: 0; border: 0; background: none; cursor: pointer; display: flex; align-items: center; justify-content: center; color: #FFFFFF; }
.ob-dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .45; transition: opacity .2s, width .25s; }
.ob-dot[aria-current="true"]::before { width: 14px; border-radius: 3px; opacity: 1; }
@keyframes obIn { from { opacity: 0; transform: translateY(6px) scale(.99); } to { opacity: 1; transform: none; } }
@keyframes obSweep { 0%, 55% { left: -40%; } 85%, 100% { left: 130%; } }
@keyframes obPop { 0%, 60%, 100% { transform: none; } 66% { transform: rotate(-9deg) scale(1.06); } 72% { transform: rotate(7deg) scale(1.06); } 78% { transform: none; } }
@media (max-width: 640px) {
  .offer-bar { margin: 12px 0 16px; }
  .ob-slide { gap: 12px; min-height: 66px; padding: 11px 44px 11px 12px; border-radius: 14px; }
  .ob-ic { width: 40px; height: 40px; border-radius: 12px; }
  .ob-ic svg { width: 19px; height: 19px; }
  .ob-h { font-size: 15px; }
  .ob-s { font-size: 12px; }
  .ob-prog { max-width: none; }
  .ob-go { display: none; }
  .ob-x { top: 8px; right: 8px; width: 28px; height: 28px; }
  .ob-dots { right: 10px; bottom: 7px; }
}
@media (prefers-reduced-motion: reduce) { .ob-slide, .ob-ic { animation: none; } .ob-slide::after { display: none; } }

/* ---------- Category page (marketplace layout): title with the breadcrumb on the right; filters in a sidebar on
   desktop (the same filters open as a sheet on phones); a sort bar; cards with an outline Add to Cart. ---------- */
@media (min-width: 1025px) {
  .shop-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 24px 0 16px; }
  .shop-top .page-h { margin: 0; font-size: 30px; color: var(--brand-deep); }
  .shop-top .crumbs { margin: 0; font-size: 14px; color: var(--text-soft); }
  .shop-top .crumbs [aria-current] { color: var(--brand); font-weight: 600; }
  .shop-bar { margin: 0; padding: 12px 16px; background: var(--white); border: 1px solid var(--border); border-radius: 12px; }
  .shop-bar .shop-sub { display: block; margin: 0; color: var(--text-soft); font-size: 14px; }
  .sort-lb { font-size: 15px; font-weight: 600; color: var(--brand-deep); }
  .sort-sel { border-color: var(--border); border-radius: 8px; }
  .shop-main { min-width: 0; }
  .shop-main .results { margin-top: 18px; }
}

/* Price range: two handles on one track. */
.prange { padding: 2px 4px 6px; }
.pr-vals { display: flex; justify-content: space-between; font-size: 14px; font-weight: 600; color: var(--brand-deep); margin-bottom: 12px; }
.pr-track { position: relative; height: 22px; }
.pr-track::before { content: ""; position: absolute; left: 0; right: 0; top: 9px; height: 4px; border-radius: 4px; background: #E4D9F0; }
.pr-fill { position: absolute; top: 9px; height: 4px; border-radius: 4px; background: var(--brand); }
.pr-track input { position: absolute; left: -9px; width: calc(100% + 18px); top: 0; height: 22px; margin: 0; background: none; pointer-events: none; -webkit-appearance: none; appearance: none; }
.pr-track input::-webkit-slider-runnable-track { background: none; border: 0; }
.pr-track input::-moz-range-track { background: none; border: 0; }
.pr-track input::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; pointer-events: auto; width: 20px; height: 20px; border-radius: 50%; background: var(--brand); border: 3px solid var(--white); box-shadow: 0 1px 4px rgba(60,15,98,.35); cursor: grab; }
.pr-track input::-moz-range-thumb { pointer-events: auto; width: 16px; height: 16px; border-radius: 50%; background: var(--brand); border: 3px solid var(--white); box-shadow: 0 1px 4px rgba(60,15,98,.35); cursor: grab; }
.pr-track input:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--brand); outline-offset: 2px; }

/* Product flags: checkboxes with a count. */
.fchecks { display: flex; flex-direction: column; }
.fcheck { display: flex; align-items: center; gap: 10px; height: 38px; border: 0; background: none; padding: 0; font-size: 15px; color: var(--text); text-align: left; }
.fcheck .box { width: 18px; height: 18px; flex-shrink: 0; border: 1.5px solid #B9A9CC; border-radius: 4px; display: flex; align-items: center; justify-content: center; background: var(--white); transition: all .2s; }
.fcheck[aria-checked="true"] .box { background: var(--brand); border-color: var(--brand); }
.fcheck .lb { flex: 1; }
.fcheck small { font-size: 13px; color: var(--text-soft); }

@media (min-width: 1025px) {
  .shop-body { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 24px; align-items: start; }
  .fd.fd-side { position: static; inset: auto; z-index: auto; }
  .fd-side .fd-scrim, .fd-side .fd-head, .fd-side .fd-foot, .fd-side .fsort { display: none; }
  .fd-side .fd-panel { position: sticky; top: 156px; width: auto; max-height: calc(100vh - 172px); background: none; box-shadow: none; animation: none; }
  .fd-side .fd-scroll { padding: 0 2px 4px 0; scrollbar-width: thin; }
  .fd-side .fgroup { padding: 18px 18px 16px; margin-bottom: 12px; background: var(--white); border: 1px solid var(--border); border-radius: 12px; }
  .fd-side .fgroup.last { padding: 16px 18px; }
  .fd-side .fh { position: relative; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 1px solid var(--border); font-size: 13.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--brand-deep); }
  .fd-side .fh::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 96px; height: 2px; background: var(--brand); }
  .fd-side .radio { height: 36px; font-size: 15px; }
  .shop-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: nowrap; }
  .shop-bar .fbtn { display: none; }
  .shop-main .grid4 { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 16px; row-gap: 18px; }
}
@media (min-width: 1300px) { .shop-main .grid4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
/* Phones and tablets keep the earlier layout: breadcrumbs, then the title with Sort / Filter beside it, the offer
   strip, the "Showing all products in …" line and the grid. The desktop wrappers step aside (display: contents) and a
   grid puts the pieces back in that order. */
@media (max-width: 1024px) {
  .shop { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 16px; grid-template-areas: "crumbs crumbs" "title tools" "offers offers" "sub sub" "results results" "about about"; }
  .shop-top, .shop-body, .shop-main, .shop-bar { display: contents; }
  .shop-top .crumbs { grid-area: crumbs; }
  .shop .page-h { grid-area: title; align-self: center; margin: 14px 0 0; }
  .shop-bar .shop-tools { grid-area: tools; align-self: center; margin-top: 14px; }
  .shop .offer-bar { grid-area: offers; }
  .shop .shop-sub { grid-area: sub; }
  .shop-main .results { grid-area: results; }
  .sort-lb { display: none; }
}
@media (max-width: 640px) {
  .shop .page-h { align-self: start; margin-top: 24px; font-size: 30px; font-weight: 700; line-height: 36px; }
  .shop-bar .shop-tools { align-self: start; margin-top: 24px; }
}

/* Category page cards: name, price in brand purple with the old price struck through, a full-width outline
   Add to Cart (the round cart button, now labelled). Buy Now and the Save chip give way to the badges. */
@media (min-width: 1025px) {
  .shop .pc { border-radius: 12px; border-color: var(--border); transition: box-shadow .25s, border-color .25s; }
  .shop .pc:hover { border-color: #D8C7EC; box-shadow: 0 10px 26px rgba(60,15,98,.10); }
  .shop .pc .pc-body { padding: 14px; flex: 1; }
  .shop .pc .pname { font-size: 16.5px; font-weight: 500; line-height: 1.35; }
  .shop .pc .save, .shop .pc .buy { display: none; }
  .shop .pc .pc-row { flex-direction: column; align-items: stretch; gap: 12px; margin-top: auto; padding-top: 10px; }
  .shop .pc .pc-prices b { font-size: 20px; color: var(--brand); }
  .shop .pc .pc-prices s { color: #9A8DA6; }
  .shop .pc .cart-wrap { width: 100%; }
  .shop .pc .cart-btn { width: 100%; height: 44px; border-radius: 8px; gap: 8px; border: 1.5px solid var(--brand); background: var(--white); color: var(--brand); font-size: 15px; font-weight: 600; transition: background .2s, color .2s; }
  .shop .pc .cart-btn svg { width: 18px; height: 18px; }
  .shop .pc .cart-btn:hover, .shop .pc .cart-btn.open { background: var(--brand); color: var(--white); }
  .shop .pc .cart-btn.added { background: var(--ok); border-color: var(--ok); color: var(--white); }
  .shop .pc .cart-btn:disabled { background: #F3EEF8; border-color: #DCD2E3; color: #9A8DA6; }
  .shop .pc .cart-lb { position: static; width: auto; height: auto; overflow: visible; clip: auto; }
  .shop .pc .notify { height: 44px; border-radius: 8px; font-size: 14px; }
}

/* The category's short introduction under the products. */
.cat-about { grid-column: 1 / -1; max-width: 860px; margin: 48px auto 0; padding: 28px 0 0; border-top: 1px solid var(--border); color: var(--text-soft); font-size: 15px; line-height: 1.7; }
.cat-about h2 { margin: 0 0 8px; font-size: 20px; font-weight: 600; color: var(--brand-deep); }
.cat-about p { margin: 0 0 6px; }
@media (max-width: 1024px) { .cat-about { grid-area: about; margin-top: 36px; } }
