/* Gazab Deals. Mobile first, one stylesheet, no framework. */
:root{
  --bg:#f6f5f2; --panel:#fff; --ink:#141210; --muted:#6d675f; --line:#e7e3dc;
  --brand:#e0480f; --brand-dark:#bf3b09; --green:#0f7a3d; --gold:#a86a00;
  --radius:16px;
  --shadow:0 1px 2px rgba(20,18,16,.05), 0 10px 26px -20px rgba(20,18,16,.5);
  --shadow-up:0 2px 6px rgba(20,18,16,.07), 0 18px 36px -22px rgba(20,18,16,.55);
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{
  margin:0; background:var(--bg); color:var(--ink);
  font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,Helvetica,Arial,sans-serif;
  font-size:15px; line-height:1.45;
}
a{color:var(--brand); text-decoration:none}
.wrap{max-width:1240px; margin:0 auto; padding:0 16px}
.muted{color:var(--muted)} .small{font-size:12.5px} .dim{color:#9a938a}
.good{color:var(--green)}

/* ------------------------------------------------------------------ header */
header.site{
  background:linear-gradient(160deg,#1b1712,#2b2118 55%,#3a2a1b);
  color:#f8f6f2; padding:14px 0 0;
}
.top-row{display:flex; align-items:center; gap:16px; flex-wrap:wrap}
.brand{display:flex; align-items:center; gap:11px; color:#fff}
.brand-mark{
  width:38px; height:38px; border-radius:12px;
  background:linear-gradient(150deg,var(--brand),#f59e0b); color:#fff;
  display:grid; place-items:center; font-weight:900; font-size:20px; letter-spacing:-.5px; flex:none;
  box-shadow:0 4px 14px -6px rgba(224,72,15,.9);
}
.brand-text{display:flex; flex-direction:column; line-height:1.15}
.brand-text b{font-size:20px; letter-spacing:-.4px}
.brand-text em{font-style:normal; font-size:11.5px; color:#c9bfb2; margin-top:2px}

.search{display:flex; flex:1 1 320px; max-width:520px; margin-left:auto; gap:8px}
.search input[type=search]{
  flex:1; min-width:0; padding:11px 14px; font-size:15px; color:var(--ink);
  background:#fff; border:1px solid transparent; border-radius:11px; outline:none;
  -webkit-appearance:none; appearance:none;
}
.search input[type=search]:focus{border-color:var(--brand); box-shadow:0 0 0 3px rgba(224,72,15,.22)}
.search button{
  padding:0 16px; border:0; border-radius:11px; cursor:pointer;
  background:var(--brand); color:#fff; display:grid; place-items:center;
  transition:background .15s ease;
}
.search button:hover{background:var(--brand-dark)}
.search button svg{width:19px; height:19px; fill:none; stroke:#fff; stroke-width:2.1;
  stroke-linecap:round}

.ticker{display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; margin:15px 0 13px}
@media (min-width:700px){.ticker{grid-template-columns:repeat(4,minmax(0,1fr))}}
.stat{background:rgba(255,255,255,.07); border:1px solid rgba(255,255,255,.10);
  border-radius:12px; padding:9px 13px; min-width:0}
.stat b{display:block; font-size:19px; letter-spacing:-.4px; color:#fff;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
.stat span{display:block; font-size:11.5px; color:#c9bfb2; margin-top:1px;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis}

.tabs{display:flex; gap:4px; overflow-x:auto; scrollbar-width:none}
.tabs::-webkit-scrollbar{display:none}
.tab{
  padding:11px 15px; font-size:14px; font-weight:600; color:#c9bfb2; white-space:nowrap;
  border-bottom:2.5px solid transparent; transition:color .15s ease;
}
.tab:hover{color:#fff}
.tab.on{color:#fff; border-bottom-color:var(--brand)}
.pill{display:inline-block; margin-left:6px; padding:1px 7px; border-radius:999px;
  background:rgba(255,255,255,.14); font-size:11px; font-weight:700}

/* ------------------------------------------------------- layout + sidebar */
.layout{display:grid; grid-template-columns:minmax(0,1fr); gap:20px; padding-top:6px; align-items:start}
@media (min-width:1000px){.layout{grid-template-columns:232px minmax(0,1fr); gap:26px}}

/* the button only exists on phones, where the sidebar becomes a drawer */
.filter-open{
  display:none; align-items:center; gap:8px; width:100%; margin:14px 0 0; padding:11px 14px;
  background:var(--panel); border:1px solid var(--line); border-radius:11px;
  font:inherit; font-size:14px; font-weight:700; color:var(--ink); cursor:pointer;
}
.filter-open svg{width:17px; height:17px; fill:none; stroke:currentColor; stroke-width:2.1; stroke-linecap:round}
.fbadge{margin-left:auto; min-width:20px; padding:1px 6px; border-radius:999px; background:var(--brand);
  color:#fff; font-size:11.5px; font-weight:800; text-align:center}
@media (max-width:999px){.filter-open{display:flex}}

.sidebar{background:var(--panel); border:1px solid var(--line); border-radius:var(--radius);
  padding:4px 14px 12px}
@media (min-width:1000px){.sidebar{position:sticky; top:16px; max-height:calc(100vh - 32px);
  overflow:auto; scrollbar-width:thin}}
.sidebar-head{display:none; align-items:center; justify-content:space-between;
  padding-bottom:10px; border-bottom:1px solid var(--line); margin-bottom:4px}
.sidebar-head b{font-size:16px}
.sidebar-x{border:0; background:none; font-size:26px; line-height:1; color:var(--muted);
  cursor:pointer; padding:0 4px}

.fgroup{padding:13px 0; border-bottom:1px solid var(--line)}
.fgroup:last-of-type{border-bottom:0}
.fgroup h4{margin:0 0 7px; font-size:11px; font-weight:800; text-transform:uppercase;
  letter-spacing:.7px; color:var(--muted)}
.fopt{display:flex; align-items:center; justify-content:space-between; gap:10px;
  padding:6px 8px; margin:0 -8px; border-radius:8px; font-size:13.5px; color:#4a453e}
.fopt:hover{background:#f5f3ef; color:var(--ink)}
.fopt.on{background:#fdece4; color:var(--brand-dark); font-weight:700}
.fopt i{font-style:normal; font-size:11.5px; color:var(--muted); flex:none}
.fopt.on i{color:var(--brand-dark)}
/* long category lists scroll instead of pushing everything down the sidebar */
.fscroll{max-height:290px; overflow:auto; scrollbar-width:thin; margin:0 -8px; padding:0 8px}
.clear-filters{display:block; margin-top:12px; font-size:13px; font-weight:700}

/* phone drawer */
.scrim{position:fixed; inset:0; z-index:55; background:rgba(20,18,16,.5)}
@media (max-width:999px){
  .sidebar{
    position:fixed; top:0; left:0; bottom:0; z-index:56; width:min(320px,86vw);
    max-height:none; border-radius:0; border:0; border-right:1px solid var(--line);
    padding:14px 16px 26px; overflow:auto;
    transform:translateX(-102%); transition:transform .22s ease;
    box-shadow:0 10px 40px -10px rgba(0,0,0,.4);
  }
  body.filters-open .sidebar{transform:none}
  .sidebar-head{display:flex}
  body.filters-open{overflow:hidden}
}

.content{min-width:0}
.count-line{margin:14px 0 0; font-size:13.5px; color:var(--muted)}
.count-line b{color:var(--ink)}

/* -------------------------------------------------------------------- grid */
.grid{
  display:grid; gap:14px; padding:12px 0 8px;
  grid-template-columns:repeat(auto-fill,minmax(196px,1fr));
}
@media (min-width:1000px){.grid{grid-template-columns:repeat(auto-fill,minmax(206px,1fr))}}
@media (max-width:459px){.grid{grid-template-columns:repeat(auto-fill,minmax(158px,1fr)); gap:10px}}

.card{
  position:relative; display:flex; flex-direction:column; background:var(--panel);
  border:1px solid var(--line); border-radius:var(--radius); overflow:hidden; cursor:pointer;
  box-shadow:var(--shadow); transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.card:hover{transform:translateY(-3px); box-shadow:var(--shadow-up); border-color:#d9d2c7}
.card:focus-visible{outline:2.5px solid var(--brand); outline-offset:2px}

.thumb{position:relative; aspect-ratio:1/1; background:#fff; border-bottom:1px solid var(--line); flex:none}
.thumb-init{position:absolute; inset:0; display:grid; place-items:center;
  font-weight:800; font-size:38px; letter-spacing:-1px}
.thumb-img{position:absolute; inset:0; width:100%; height:100%; object-fit:contain;
  padding:9px; background:#fff}
.thumb.noimg .thumb-img{display:none}
.thumb.big{width:132px; aspect-ratio:1/1; border-radius:13px; border:1px solid var(--line)}
@media (max-width:620px){.thumb.big{width:104px} .thumb.big .thumb-init{font-size:30px}}

.off{
  position:absolute; top:9px; left:9px; z-index:2; background:var(--brand); color:#fff;
  padding:4px 9px; border-radius:9px; font-weight:900; font-size:14px; line-height:1.1;
  box-shadow:0 3px 10px -4px rgba(0,0,0,.5); text-align:center;
}
.off span{display:block; font-size:9px; font-weight:700; letter-spacing:.6px; opacity:.9}
.flame{
  position:absolute; top:9px; right:9px; z-index:2; background:#111; color:#ffd76a;
  padding:3px 8px; border-radius:8px; font-size:10px; font-weight:800; text-transform:uppercase;
  letter-spacing:.5px;
}

.card-body{display:flex; flex-direction:column; gap:5px; padding:11px 12px 12px; flex:1}
.cat{font-size:10.5px; text-transform:uppercase; letter-spacing:.5px; color:var(--muted);
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap}
.title{
  margin:0; font-size:13.8px; font-weight:600; line-height:1.35; color:var(--ink);
  display:-webkit-box; -webkit-line-clamp:3; line-clamp:3; -webkit-box-orient:vertical; overflow:hidden;
}
.prices{display:flex; align-items:baseline; gap:8px; flex-wrap:wrap; margin-top:3px}
.now{font-size:24px; font-weight:900; letter-spacing:-.7px; color:var(--ink)}
.save-amt{font-size:12.5px; font-weight:800; color:#fff; background:var(--green);
  padding:2px 7px; border-radius:6px; white-space:nowrap}

/* the reference prices, one per line so they scan as a list rather than a
   sentence - the number you pay above them stays the loudest thing on the card */
.ref-prices{display:flex; flex-direction:column; gap:1px; margin-top:2px}
.ref{display:flex; align-items:baseline; gap:6px; font-size:12.5px; color:var(--muted)}
.ref b{font-weight:600; font-size:11px; color:#9a938a; text-transform:uppercase;
  letter-spacing:.3px; flex:none}
.ref s{text-decoration:line-through; text-decoration-color:#bdb5a9}
.was{font-size:14px; color:var(--muted); text-decoration:line-through;
  text-decoration-color:#bdb5a9}

.offers{display:flex; flex-wrap:wrap; gap:4px}
.tag{font-size:10.5px; font-weight:700; padding:2.5px 7px; border-radius:6px;
  border:1px solid transparent}
.tag.coupon{background:#eafaef; color:var(--green); border-color:#c6ecd4}
.tag.buyfor{background:#fff5e6; color:var(--gold); border-color:#f4dfb8}
.tag.both{background:#f3edfd; color:#5b3fb5; border-color:#e0d4f7}
.tag.bank{background:#eef2fb; color:#35508f; border-color:#d6e0f5}

.foot{display:flex; align-items:center; gap:7px; margin-top:auto; padding-top:4px;
  min-height:22px; overflow:hidden}
.foot .small{white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
.badge{font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.5px;
  padding:2.5px 7px; border-radius:6px; white-space:nowrap; flex:none}
.badge.hot{background:#fdece4; color:var(--brand-dark)}
.badge.warn{background:#fff5e6; color:var(--gold)}
.badge.info{background:#eef2fb; color:#35508f}
.badge.off{background:#f0eee9; color:var(--muted)}

.cta{display:flex; gap:7px; margin-top:7px}
.buy{
  width:100%; display:flex; align-items:center; justify-content:center; gap:6px;
  padding:11px 10px; border-radius:11px; background:var(--ink); color:#fff;
  font-size:14px; font-weight:700; white-space:nowrap; transition:background .15s ease;
}
.buy:hover{background:#000}
.buy i{font-style:normal; font-size:12px; opacity:.75}
.buy.wide{width:100%; padding:12px}


.empty{background:var(--panel); border:1px solid var(--line); border-radius:var(--radius);
  padding:44px 22px; text-align:center; margin:18px 0}
.empty h3{margin:0 0 6px; font-size:17px}
.empty p{margin:0; color:var(--muted)}

/* the endless scroll: a spinner while the next page arrives, then a line that
   says so when there is nothing left. No next button to hunt for. */
.feed{padding:6px 0 4px; min-height:30px}
#sentinel{height:1px}
.feed-more{display:flex; align-items:center; justify-content:center; gap:10px;
  padding:20px 0; font-size:13.5px; color:var(--muted)}
.feed-end{text-align:center; padding:22px 0; font-size:13.5px; color:var(--muted); margin:0}
.spinner{width:17px; height:17px; border:2px solid var(--line); border-top-color:var(--brand);
  border-radius:50%; animation:spin .7s linear infinite; flex:none}
@keyframes spin{to{transform:rotate(360deg)}}
.retry{font:inherit; font-size:13.5px; font-weight:700; color:var(--ink); cursor:pointer;
  padding:9px 18px; background:var(--panel); border:1px solid var(--line); border-radius:10px}
.retry:hover{border-color:#c9c1b6}
.pager{text-align:center; padding:18px 0}
.pager a{padding:9px 16px; background:var(--panel); border:1px solid var(--line); border-radius:10px;
  font-weight:600}
.card.new{animation:fadein .35s ease-out}
@keyframes fadein{from{opacity:0; transform:translateY(8px)}}

.site-foot{padding:26px 0 40px; color:#4a453e; font-size:13px; max-width:78ch}
.site-foot p{margin:0 0 8px}

/* ------------------------------------------------------------------- modal */
.modal{position:fixed; inset:0; z-index:60; display:grid; place-items:center; padding:16px}
.modal[hidden]{display:none}
.modal-back{position:absolute; inset:0; background:rgba(20,18,16,.55); backdrop-filter:blur(2px)}
.modal-box{
  position:relative; width:min(880px,100%); max-height:min(90vh,880px); overflow:auto;
  background:var(--panel); border-radius:18px; box-shadow:0 24px 60px -20px rgba(0,0,0,.5);
  animation:pop .16s ease-out;
}
@keyframes pop{from{transform:translateY(10px) scale(.985); opacity:0}}
.modal-x{position:absolute; top:10px; right:12px; z-index:3; width:32px; height:32px;
  border:0; border-radius:9px; background:rgba(255,255,255,.9); font-size:22px; line-height:1;
  cursor:pointer; color:var(--muted)}
.modal-x:hover{background:#f0eee9; color:var(--ink)}
.modal-body{padding:22px}

.detail-top{display:flex; gap:18px; align-items:flex-start; padding-bottom:16px;
  border-bottom:1px solid var(--line)}
.detail-head{flex:1; min-width:0}
.detail-head h2{margin:4px 0 9px; font-size:18px; line-height:1.35; font-weight:650}
.detail-price-line{display:flex; align-items:baseline; gap:9px; flex-wrap:wrap}
.now.big{font-size:27px}
.offpill{background:#fdece4; color:var(--brand-dark); font-size:12px; font-weight:800;
  padding:3px 8px; border-radius:7px}
.why{margin:11px 0 14px; padding:9px 12px; background:#f7f5f1; border-left:3px solid var(--brand);
  border-radius:0 9px 9px 0; font-size:13.5px; color:#4a453e}

.detail-grid{display:grid; gap:22px; padding-top:16px}
@media (min-width:680px){.detail-grid{grid-template-columns:1fr 1fr}}
.detail-col h4{margin:0 0 9px; font-size:12px; text-transform:uppercase; letter-spacing:.6px;
  color:var(--muted)}
.detail-col h4:not(:first-child){margin-top:22px}

.kv{width:100%; border-collapse:collapse; font-size:13.5px}
.kv td{padding:7px 0; border-bottom:1px solid var(--line); vertical-align:top}
.kv td:first-child{color:var(--muted); width:44%}
.kv td:last-child{text-align:right; font-weight:650}
.kv td:last-child s{font-weight:500; color:var(--muted);
  text-decoration-color:#bdb5a9}
.kv tr.strong td{font-size:15px; font-weight:800}
.kv tr.strong td:first-child{color:var(--ink)}
.kv.alerts td{font-weight:500; white-space:normal}
.kv.alerts tr.head td{font-size:10.5px; text-transform:uppercase; letter-spacing:.4px; color:var(--muted)}
.kv.alerts td:last-child{text-align:right; font-weight:500}

.chart-svg{display:block; width:100%; height:auto}
.chart-svg .lbl{font-size:12px; fill:#8c857b}
.chart-svg .lbl.right{text-anchor:end}
.chart-svg .lbl.mid{text-anchor:middle}
.crash-note{margin-top:10px; font-size:12px; color:var(--muted); line-height:1.5}
.crash-dot{display:inline-block; width:7px; height:7px; border-radius:50%; background:var(--brand);
  vertical-align:middle; margin:0 2px}
.detail-foot{margin:20px 0 0; padding-top:14px; border-top:1px solid var(--line)}
.loading,.detail-error{padding:44px; text-align:center; color:var(--muted)}
body.modal-open{overflow:hidden}

/* -------------------------------------------------------- phone refinements */
@media (max-width:459px){
  .wrap{padding:0 11px}
  .card-body{padding:9px 10px 10px; gap:4px}
  .title{font-size:13px; -webkit-line-clamp:2; line-clamp:2}
  .now{font-size:20px}
  .save-amt{font-size:11.5px; padding:2px 6px}
  .ref{font-size:11.5px; gap:5px}
  .ref b{font-size:10px}
  .tag{font-size:10px; padding:2px 6px}
  .buy{font-size:13.5px; padding:10px}
  .off{font-size:13px; padding:3px 7px}
  .flame{font-size:9px; padding:2.5px 6px}
  .ref-prices{gap:2px}
  .cat{font-size:10px}
  .top-row{gap:10px}
  .search{margin-left:0; order:3; width:100%; flex-basis:100%}
  .stat b{font-size:17px}
  .stat{padding:8px 11px}
  .modal{padding:0; align-items:flex-end}
  .modal-box{max-height:92vh; border-radius:16px 16px 0 0; width:100%}
  .modal-body{padding:16px 14px 20px}
  .detail-top{gap:12px}
  .detail-head h2{font-size:16px}
  .now.big{font-size:24px}
}

