:root{
  --bg:#0b0f15; --card:#0f1622; --line:#203042; --ink:#e6eef1; --muted:#9aa6b4;
  --accent:#9ad7ff; --pill:#0d1421;
}

/* Base */
*{box-sizing:border-box}
html,body{height:100%}
body{
  font:16px/1.6 system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
  background:var(--bg); color:var(--ink); margin:0;
}
img{max-width:100%; height:auto; display:block}
a{color:var(--accent);text-decoration:none}
header,main,footer{max-width:1180px;margin:0 auto;padding:20px}
nav.tiny a{margin-right:10px}
h1{margin:0 0 8px}
.tiny{font-size:.9rem;opacity:.85}
.muted{opacity:.7}

/* Hero */
.hero{display:flex;gap:14px;align-items:flex-start;flex-wrap:wrap}
.hero .media{flex:0 0 480px; max-width:100%}
.hero .media picture,.hero .media img{
  width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:12px
}
.hero .txt{flex:1;min-width:260px}

/* Pills + search */
.pills{display:flex;gap:8px;flex-wrap:wrap;margin:6px 0}
.pill{
  display:inline-block;border:1px solid #29435c;border-radius:999px;
  background:var(--pill);color:var(--accent);padding:6px 10px;font-size:.9rem
}
form.search{display:flex;gap:8px;margin-top:6px}
form.search input,form.search button{
  padding:10px 12px;border-radius:8px;border:1px solid #29435c;background:#0d1421;color:var(--ink)
}

/* Generic grid & card (used by web/blog lists) */
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:18px;margin-top:12px}
.card{
  background:var(--card);border:1px solid var(--line);border-radius:12px;
  padding:12px;display:flex;flex-direction:column;gap:10px;
  transition:transform .15s,box-shadow .15s
}
.card:hover{transform:translateY(-3px);box-shadow:0 4px 8px rgba(0,0,0,.3)}
.card h3{font-size:1rem;margin:4px 0 0}
.card .tiny{font-size:.9rem;opacity:.85;line-height:1.35}
.card .pill{
  display:block;text-align:center;margin-top:6px;
  padding:8px 12px;border-radius:999px;background:var(--pill);
  border:1px solid #29435c;color:var(--accent);font-size:.9rem
}
.empty{border:1px dashed #27425a;border-radius:12px;padding:12px;text-align:center;opacity:.7}
.section{margin-top:24px}

/* --- Product grid image sizing --- */
.grid img {
  width: 100%;
  height: auto;
  max-width: 400px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  margin: 0 auto;
  display: block;
}
.card.product .thumb{
  aspect-ratio:1/1;                 /* perfect square */
  border:1px solid var(--line);
  border-radius:10px;
  background:#0a1018;
  display:grid;
  place-items:center;               /* centers any logo/packshot */
  overflow:hidden;
}
.card.product .thumb img{
  max-width:86%;
  max-height:86%;
  object-fit:contain;               /* keep whole image visible */
}

/* ---------- Blog cards (homepage & /blog) ---------- */
.card.blog .thumb{
  aspect-ratio:16/9;
  border-radius:10px;
  background:#0a1018;
  overflow:hidden;
  border:1px solid var(--line);
}
.card.blog .thumb img{width:100%;height:100%;object-fit:cover}
.cards.blog{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:18px}
/* --- Uniform, centered covers for product + blog cards --- */
#topPicks .card img,
#latestWeb .card img,
#latestBlog .card img{
  width:100%;
  height:170px;              /* tune: 150–180px */
  object-fit:contain;        /* no crop; keep entire image */
  background:#0a1018;        /* dark mat behind transparent PNGs */
  border-radius:10px;
  display:block;
  padding:6px;               /* small breathing room */
}

/* If you’re using a “thumb” wrapper anywhere, this keeps it tidy */
.card .thumb{
  aspect-ratio:4/3;          /* consistent box even before image loads */
  display:grid;
  place-items:center;
  overflow:hidden;
  background:#0a1018;
  border-radius:10px;
}
.card .thumb > img{
  max-width:100%;
  max-height:100%;
  object-fit:contain;
}
.mobile-sticky-cta{
  display:none;
}

@media (max-width: 768px){
  .mobile-sticky-cta{
    display:block;
    position:fixed;
    bottom:0;
    left:0;
    width:100%;
    background:#0f2b46;
    padding:12px;
    text-align:center;
    box-shadow:0 -3px 12px rgba(0,0,0,0.3);
    z-index:9999;
  }

  .mobile-sticky-cta a{
    color:#fff;
    font-weight:600;
    text-decoration:none;
  }

  body{
    padding-bottom:70px;
  }
}
