:root { --ink:#14231b; --muted:#627067; --green:#173c2b; --cream:#f5f1e8; --orange:#ec7a2c; --line:#dce2dc; --white:#fff; }
* { box-sizing:border-box; }
body { margin:0; color:var(--ink); background:var(--cream); font:15px/1.5 Inter, ui-sans-serif, system-ui, sans-serif; }
.hero { display:flex; justify-content:space-between; align-items:center; gap:24px; padding:30px max(22px,calc((100vw - 1280px)/2)); color:white; background:var(--green); }
.eyebrow { margin:0 0 4px; color:#b8d9c5; font-size:.75rem; font-weight:800; letter-spacing:.13em; text-transform:uppercase; }
h1 { margin:0; font:700 clamp(2rem,5vw,3.5rem)/1.05 Georgia,serif; }
.freshness { margin:10px 0 0; color:#dcebe1; }.freshness.stale { color:#ffd39f; font-weight:800; }
.hero-mark { display:grid; place-items:center; width:68px; height:68px; border:2px solid #78a88a; border-radius:50%; font:700 2.2rem Georgia,serif; }
main { width:min(1280px,calc(100% - 32px)); margin:24px auto 60px; }
.filters { position:sticky; top:0; z-index:5; display:grid; grid-template-columns:minmax(220px,2fr) repeat(4,minmax(140px,1fr)); gap:12px; padding:16px; background:rgba(255,255,255,.96); border:1px solid var(--line); border-radius:16px; box-shadow:0 8px 30px #173c2b12; backdrop-filter:blur(10px); }
label { color:var(--muted); font-size:.72rem; font-weight:800; letter-spacing:.04em; text-transform:uppercase; }
input,select { width:100%; margin-top:6px; padding:11px 12px; color:var(--ink); background:white; border:1px solid #cbd4cd; border-radius:9px; font:500 .92rem system-ui; text-transform:none; }
:focus-visible { outline:3px solid #efa26e; outline-offset:2px; }
.results-line { min-height:48px; color:var(--muted); }
.product-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(245px,1fr)); gap:16px; }
.product-card { overflow:hidden; background:white; border:1px solid var(--line); border-radius:15px; box-shadow:0 5px 18px #173c2b0b; }
.product-image { aspect-ratio:4/3; overflow:hidden; background:#ece9df; }.product-image img { width:100%; height:100%; object-fit:cover; }
.product-image.placeholder { display:grid; place-items:center; color:#9ca99f; font:700 4rem Georgia,serif; }
.product-body { padding:16px; }.product-body h2 { min-height:2.6em; margin:5px 0 2px; font-size:1.05rem; line-height:1.3; }
.category { display:inline-block; margin:0; padding:3px 8px; color:#854116; background:#fff0e5; border-radius:999px; font-size:.67rem; font-weight:800; }
.part-no,.sales,.matches { margin:4px 0; color:var(--muted); font-size:.78rem; }.sales { margin-top:12px; }
.stock-box { position:relative; display:grid; gap:2px; margin-top:14px; padding:12px; background:#f7f9f7; border-radius:10px; }
.shop-label { color:var(--muted); font-size:.75rem; }.stock-box strong { font-size:1.25rem; }
.tier { position:absolute; top:10px; right:10px; padding:3px 7px; border-radius:999px; font-size:.65rem; font-weight:900; text-transform:uppercase; }
.tier-low { color:#9c251e; background:#ffe2df; }.tier-medium { color:#8a5700; background:#fff0bd; }.tier-normal { color:#17653b; background:#daf3e4; }
.branch-controls { display:flex; gap:6px; margin-top:8px; }.branch-controls button { width:34px; height:30px; border:1px solid #cbd4cd; border-radius:8px; background:white; font-size:1.2rem; cursor:pointer; }
.empty-state { padding:60px 20px; text-align:center; background:white; border:1px dashed #b9c5bc; border-radius:15px; }.empty-state h2 { margin:0; }
.load-more { display:block; margin:28px auto; padding:12px 24px; color:white; background:var(--green); border:0; border-radius:10px; font-weight:800; cursor:pointer; }.load-more[hidden] { display:none; }
@media (max-width:900px) { .filters { position:static; grid-template-columns:repeat(2,1fr); }.filters label:first-child { grid-column:1/-1; } }
@media (max-width:540px) { .hero { padding:24px 18px; }.hero-mark { display:none; } main { width:min(100% - 20px,1280px); margin-top:10px; }.filters { grid-template-columns:1fr 1fr; padding:12px; gap:9px; }.product-grid { grid-template-columns:1fr 1fr; gap:9px; }.product-body { padding:11px; }.product-body h2 { font-size:.92rem; }.stock-box strong { font-size:1rem; } }
@media (max-width:380px) { .product-grid { grid-template-columns:1fr; } }

/* login */
.login-body { display:grid; place-items:center; min-height:100vh; background:var(--green); }
.login-card { width:min(360px,90vw); padding:32px; background:white; border-radius:16px; box-shadow:0 12px 40px #0004; }
.login-card h1 { margin:0 0 20px; font:700 1.5rem Georgia,serif; }
.login-card form { display:grid; gap:14px; }
.login-card label { display:grid; gap:6px; }
.login-card button { margin-top:6px; padding:12px; color:white; background:var(--green); border:0; border-radius:9px; font:700 .95rem system-ui; cursor:pointer; }
.login-card button:hover { background:#0f2c1f; }
.login-card .err { margin:0; padding:10px 12px; color:#7a1c1c; background:#fdecec; border:1px solid #f4c9c9; border-radius:8px; font-size:.88rem; }
