:root{
  --bg:#f6f7f9;
  --card:#fff;
  --text:#0f172a;
  --muted:#64748b;
  --line:#e5e7eb;

  --shadow: 0 20px 60px rgba(0,0,0,.06);
  --shadow-sm: 0 10px 30px rgba(0,0,0,.06);
  --ring: 0 0 0 4px rgba(17,24,39,.10);

  --radius:16px;
  --radius-lg:20px;
}

*{box-sizing:border-box}
html,body{
    height:100%;
    margin: 0;
    padding: 0;
}

body{
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:var(--text);
  background:
    radial-gradient(1200px 800px at 20% 10%, rgba(56,189,248,.10), transparent 60%),
    radial-gradient(1000px 700px at 90% 20%, rgba(99,102,241,.08), transparent 60%),
    radial-gradient(800px 600px at 50% 100%, rgba(16,185,129,.06), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-size: cover;
    min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* layout */
.container{max-width:1380px;margin:0 auto;padding:0 16px;}
main{flex:1 0 auto;}
a{color:inherit}
main {
  padding-top: 0;
}

/* cards */
.card{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow: var(--shadow-sm);
}
.card.pad{padding:12px}

/* muted */
.muted{color:var(--muted);font-size:12px;}

/* badges */
.badge{
  display:inline-flex;gap:6px;align-items:center;
  padding:4px 10px;border-radius:999px;border:1px solid #ddd;background:#fff;font-size:12px;
}
.badge.ok{background:#dcfce7;border-color:#16a34a;color:#166534;}
.badge.warn{background:#ffedd5;border-color:#f59e0b;color:#92400e;}
.badge.off{background:#f3f4f6;border-color:#cbd5e1;color:#334155;}

/* buttons */
.btnpro{
  display:inline-flex;gap:8px;align-items:center;justify-content:center;
  padding:10px 12px;border-radius:14px;border:1px solid #111;background:#111;color:#fff;
  cursor:pointer;text-decoration:none;
  transition: opacity .12s ease, transform .05s ease, background .12s ease;
}
.btnpro:hover{opacity:.92;}
.btnpro:active{transform:translateY(1px);}
.btnpro.ghost{background:#fff;color:#111;border:1px solid var(--line);}
.btnpro.ghost:hover{background:#fafafa;}
.btnpro.danger{background:#b91c1c;border-color:#b91c1c;}

/* inputs (global pro) */
input[type="text"], input[type="email"], input[type="password"], input[type="number"], textarea, select{
  appearance:none;
  background:#fff;
  border:1px solid #d1d5db;
  border-radius:14px;
  padding:10px 12px;
  font-size:14px;
  line-height:18px;
}
input:focus, textarea:focus, select:focus{
  outline:none;
  border-color:#111827;
  box-shadow: var(--ring);
}

/* select arrow wrapper */
.selectwrap{position:relative;display:flex;align-items:center;}
.selectwrap select{padding-right:38px;}
.selectwrap::after{
  content:"";
  position:absolute;
  right:12px;
  width:10px;
  height:10px;
  border-right:2px solid #64748b;
  border-bottom:2px solid #64748b;
  transform: rotate(45deg);
  pointer-events:none;
  opacity:.9;
}

/* tables */
table{
  width:100%;
  border-collapse:collapse;
  background:#fff;
  border:1px solid var(--line);
  border-radius:var(--radius);
  overflow:hidden;
}
th,td{
  padding:10px;
  border-bottom:1px solid #eee;
  text-align:left;
  font-size:14px;
  vertical-align:top;
}
th{background:#fafafa;}
:not(.products-table) tbody tr:hover{
  background:#fafafa;
}

/* small code chips */
code{
  background:#f3f4f6;
  padding:2px 6px;
  border-radius:8px;
}

/* probar helper (many pages use it) */
.probar{
  width: 100%;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  position:sticky;
  top: var(--topbar-offset, 66px);
  z-index:1900;
  box-shadow: 0 10px 30px rgba(0,0,0,.04);
  border-radius: 0px 0px 16px 16px;
}
.probar .inner{
  padding:10px 0;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.divider{height:1px;background:var(--line);}

/* =========================
   TOPBAR / HEADER (global)
========================= */
.topbar{
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom:1px solid var(--line);
  position:sticky;
  top:0;
  z-index:2000;
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
}

#topbar-spacer{
  display:none !important;
  height:0 !important;
}

.topbar .row{
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  padding:12px 0;
}

.topbar .left{
  display:flex;
  gap:12px;
  align-items:center;
  min-width:0;
}
.topbar .brand{display:flex;align-items:center;gap:10px;white-space:nowrap;text-decoration:none;}
.topbar .brand .name{font-weight:950;letter-spacing:-.02em;}
.topbar .brand img{height:40px;width:auto;display:block;border-radius:10px;}

.header-left-pro{
  flex:1 1 auto;
  min-width:0 !important;
}

.header-search-pro{
  flex:1 1 520px;
  max-width:620px;
  min-width:320px;
  height:44px;
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid #dbe3ee;
  border-radius:999px;
  background:#fff;
  padding:0 12px 0 16px;
  color:#64748b;
  cursor:text;
  box-shadow:0 1px 0 rgba(15,23,42,.02);
  transition:border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.header-search-pro:hover{
  border-color:#cbd5e1;
  background:#fbfdff;
  box-shadow:0 10px 28px rgba(15,23,42,.06);
}

.header-search-pro:focus{
  outline:none;
  border-color:#111827;
  box-shadow:0 0 0 4px rgba(17,24,39,.08);
}

.header-search-pro i{
  font-size:17px;
  color:#0f172a;
  flex:0 0 auto;
}

.header-search-placeholder{
  flex:1;
  min-width:0;
  text-align:left;
  font-size:14px;
  font-weight:700;
  color:#64748b;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.header-search-kbd{
  flex:0 0 auto;
  min-width:26px;
  height:26px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid #e5e7eb;
  border-radius:9px;
  background:#f8fafc;
  color:#64748b;
  font-size:13px;
  font-weight:900;
}

@media (max-width:1100px){
  .topbar .row{
    flex-wrap:wrap;
  }

  .header-left-pro{
    flex:1 1 100%;
    width:100%;
  }

  .header-search-pro{
    max-width:none;
    min-width:0;
  }

  .nav{
    width:100%;
    justify-content:flex-start;
    overflow-x:auto;
    padding-bottom:4px;
  }
}

@media (max-width:640px){
  .header-left-pro{
    flex-wrap:wrap;
  }

  .topbar .brand{
    width:100%;
  }

  .header-search-pro{
    flex-basis:100%;
    height:42px;
  }

  .header-search-placeholder{
    font-size:13px;
  }

  .header-search-kbd{
    display:none;
  }
}

.searchbox{flex:1; min-width:260px; max-width:520px;}
.searchwrap{
  display:flex; align-items:center; gap:10px;
  background:#fff;
  border:1px solid #d1d5db;
  border-radius:999px;
  padding:8px 12px;
}
.searchwrap i{color:var(--muted);}
.searchwrap input{
  flex:1;
  border:0;
  outline:none;
  font-size:14px;
  padding:2px 0;
  background:transparent;
}

/* icon nav */
.nav{display:flex; gap:8px; align-items:center; white-space:nowrap;}
.iconbtn{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:42px;
  height:42px;
  border-radius:14px;
  border:1px solid var(--line);
  background:#fff;
  text-decoration:none;
  transition: background .15s ease, transform .05s ease;
}
.iconbtn i{font-size:18px;color:#0f172a;}
.iconbtn:hover{background:#fafafa}
.iconbtn:active{transform:translateY(1px)}
.badgecount{
  position:absolute; top:-6px; right:-6px;
  display:inline-flex; align-items:center; justify-content:center;
  min-width:18px; height:18px; padding:0 6px;
  border-radius:999px; background:#111; color:#fff;
  font-size:11px; font-weight:900; line-height:18px;
  border:2px solid #fff;
}

/* tooltips */
.iconbtn[data-tip]::after{
  content: attr(data-tip);
  position:absolute;
  bottom:-38px;
  left:50%;
  transform:translateX(-50%) translateY(-4px);
  background:#111;
  color:#fff;
  padding:6px 10px;
  border-radius:10px;
  font-size:12px;
  white-space:nowrap;
  opacity:0;
  pointer-events:none;
  transition:opacity .15s ease, transform .15s ease;
}
.iconbtn[data-tip]::before{
  content:"";
  position:absolute;
  bottom:-14px;
  left:50%;
  transform:translateX(-50%);
  border:6px solid transparent;
  border-bottom-color:#111;
  opacity:0;
  transition:opacity .15s ease;
  pointer-events:none;
}
.iconbtn:hover::after,.iconbtn:hover::before{opacity:1;}

.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:7px 10px;
  border:1px solid var(--line);
  border-radius:999px;
  background:#fff;
  font-size:12px;
  color:var(--muted);
  margin-left:6px;
}

/* =========================
   CATEGORY MEGA MENU - PRO
========================= */

.catbar{
  position:relative;
  border-top:1px solid #eef2f7;
  padding:10px 0 0 0;
}

.catbar-scroll{
  display:flex;
  gap:6px;
  align-items:center;
  overflow-x:auto;
  overflow-y:visible;
  padding-bottom:10px;
}

.catnav-item{
  position:static;
  flex:0 0 auto;
}

.catnav-trigger{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-height:40px;
  padding:0 14px;
  border:1px solid transparent;
  border-radius:999px;
  background:transparent;
  color:#334155;
  font-size:14px;
  font-weight:800;
  cursor:pointer;
  white-space:nowrap;
}

.catnav-trigger i{
  font-size:16px;
  color:#2563eb;
}

.catnav-item:hover .catnav-trigger,
.catnav-item.is-open .catnav-trigger,
.catnav-item.is-active .catnav-trigger{
  background:#f8fafc;
  border-color:#e5e7eb;
  color:#111827;
}

.catnav-item.is-active .catnav-trigger{
  color:#2563eb;
}

.catnav-mega{
  display:none;
  position:absolute;
  left:0;
  right:0;
  top:100%;
  width:100%;
  max-width:100%;
  min-width:0;
  margin-top:0;
  background:rgba(255,255,255,.98);
  backdrop-filter:blur(14px);
  border:1px solid #e5e7eb;
  border-top:0;
  border-radius:0 0 22px 22px;
  box-shadow:0 30px 80px rgba(15,23,42,.16);
  z-index:2600;
  overflow:hidden;
}

.catnav-mega-inner{
  display:grid;
  grid-template-columns:repeat(5, minmax(0, 1fr));
  gap:0;
  max-height:min(750px, calc(100vh - 170px));
}

.catnav-col{
  min-width:0;
  padding:16px 18px;
  border-right:1px solid #eef2f7;
  overflow-y:auto;
  overflow-x:hidden;
  max-height:min(750px, calc(100vh - 170px));
}

.catnav-col:nth-child(5n){
  border-right:0;
}

.catnav-col::-webkit-scrollbar{
  width:6px;
}

.catnav-col::-webkit-scrollbar-thumb{
  background:#dbe3ee;
  border-radius:999px;
}

.catnav-col-title{
  display:inline-flex;
  align-items:center;
  min-height:30px;
  padding:0 12px;
  border-radius:999px;
  background:#eef2f7;
  color:#334155;
  font-size:13px;
  font-weight:900;
  margin-bottom:12px;
}

.catnav-links{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.catnav-link{
  display:block;
  text-decoration:none;
  color:#64748b;
  font-size:14px;
  line-height:1.35;
  font-weight:600;
  padding:5px 0;
}

.catnav-link:hover{
  color:#0f172a;
}

.catnav-link.is-current{
  color:#2563eb;
  font-weight:900;
}

.catnav-mega--single{
  width:320px;
  right:auto;
  border-top:1px solid #e5e7eb;
  border-radius:18px;
}

.catnav-mega--single .catnav-mega-inner{
  display:block;
  max-height:none;
}

.catnav-mega--single .catnav-col{
  max-height:none;
  border-right:0;
}

@media (min-width:1101px){
  .catnav-item:hover .catnav-mega,
  .catnav-item:focus-within .catnav-mega,
  .catnav-item.is-open .catnav-mega{
    display:block;
  }
}

@media (max-width:1100px){
  .catnav-item{
    position:relative;
  }

  .catnav-mega{
    left:0;
    right:auto;
    top:100%;
    width:min(92vw, 520px);
    border-top:1px solid #e5e7eb;
    border-radius:18px;
  }

  .catnav-item.is-open .catnav-mega{
    display:block;
  }

  .catnav-mega-inner{
    grid-template-columns:1fr;
    max-height:min(70vh, 560px);
    overflow:auto;
  }

  .catnav-col{
    max-height:none;
    overflow:visible;
    border-right:0;
    border-bottom:1px solid #eef2f7;
  }

  .catnav-col:last-child{
    border-bottom:0;
  }
}

.catnav-item{
  padding-bottom:12px;
  margin-bottom:-12px;
}

.catnav-mega{
  top:calc(100% - 1px);
}

.catnav-mega::before{
  content:"";
  position:absolute;
  left:0;
  right:0;
  top:-16px;
  height:16px;
  background:transparent;
}

.topbar,
.topbar .container,
.catbar,
.catbar-scroll{
  overflow:visible;
}

.catnav-group{
  padding-bottom:18px;
  margin-bottom:18px;
  border-bottom:1px solid #eef2f7;
}

.catnav-group:last-child{
  padding-bottom:0;
  margin-bottom:0;
  border-bottom:0;
}

/* =========================
   SEARCH PRO DRAWER (global)
========================= */
.sp-drawer{position:fixed;inset:0;z-index:3500;display:none;}
.sp-drawer.is-open{display:block;}
.sp-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.55);}
.sp-panel{
  position:absolute;
  top:0;
  right:0;
  height:100%;
  width:min(980px,96vw);

  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);

  border-left:1px solid var(--line);
  display:flex;
  flex-direction:column;
  transform:translateX(105%);
  transition:transform .18s ease;
}
.sp-drawer.is-open .sp-panel{transform:translateX(0);}

.sp-head{padding:14px;border-bottom:1px solid #e5e7eb;display:flex;justify-content:space-between;gap:12px;align-items:flex-start;}
.sp-title{font-weight:950;font-size:18px;}
.sp-sub{color:#64748b;font-size:12px;margin-top:4px;}
.sp-x{border:1px solid #e5e7eb;background:#fff;border-radius:12px;width:42px;height:42px;cursor:pointer;}
.sp-x:hover{background:#fafafa}

.sp-form{padding:12px;border-bottom:1px solid #e5e7eb;background:#fff;}
.sp-row{display:flex;gap:10px;flex-wrap:wrap;align-items:end;}
.sp-field{min-width:160px;flex:0 0 auto;}
.sp-grow{flex:1 1 360px;min-width:260px;}
.sp-label{color:#64748b;font-size:12px;margin-bottom:6px;}
.sp-input{
  display:flex;
  gap:8px;
  align-items:center;

  border:1px solid var(--line);
  border-radius:14px;

  height:40px;
  padding:0 12px;

  background:#fff;
}

.sp-input input{
  font-size:14px;
}

/* Search drawer controls */
.sp-form select{
  height:40px;
  padding:0 12px;
  border:1px solid var(--line);
}

.sp-btn,
.sp-link{
  height:40px;
  padding:0 12px;
  border-radius:14px;
  display:inline-flex;
  align-items:center;
  gap:8px;
}

.sp-input i{color:#64748b;}
.sp-input input{border:0;outline:none;flex:1;font-size:14px;background:transparent;}
.sp-form select{padding:10px 12px;border:1px solid #d1d5db;border-radius:14px;background:#fff;width:100%;}
.sp-actions{margin-top:10px;justify-content:space-between;}
.sp-muted{color:#64748b;font-size:12px;}
.sp-right{display:flex;gap:10px;flex-wrap:wrap;align-items:center;}
.sp-link{display:inline-flex;gap:8px;align-items:center;text-decoration:none;padding:10px 12px;border:1px solid #e5e7eb;border-radius:14px;background:#fff;}
.sp-link:hover{background:#fafafa}
.sp-table .sp-link{
  padding:8px 10px;
  border-radius:12px;
  font-size:12px;
}
.sp-table th:nth-child(3), .sp-table td:nth-child(3){ text-align:right; }
.sp-table th:nth-child(4), .sp-table td:nth-child(4){ text-align:right; }
.sp-btn{padding:10px 12px;border-radius:14px;border:1px solid #111;background:#111;color:#fff;cursor:pointer;display:inline-flex;gap:8px;align-items:center;}
.sp-btn.sp-ghost{background:#fff;color:#111;border:1px solid #e5e7eb;}
.sp-btn.sp-ghost:hover{background:#fafafa}

.sp-body{padding:12px;overflow:auto;flex:1 1 auto;background:#f8fafc;}
.sp-loading{display:flex;gap:10px;align-items:center;color:#334155;background:#fff;border:1px solid #e5e7eb;border-radius:16px;padding:12px;}
.sp-spinner{width:18px;height:18px;border:2px solid #e5e7eb;border-top-color:#111;border-radius:50%;animation:spin 0.8s linear infinite;}
@keyframes spin{to{transform:rotate(360deg)}}

.sp-empty{background:#fff;border:1px solid #e5e7eb;border-radius:16px;padding:20px;text-align:center;color:#334155;}
.sp-empty-ico{font-size:22px;color:#64748b;}
.sp-empty-title{font-weight:950;margin-top:6px;}
.sp-empty-sub{color:#64748b;font-size:12px;margin-top:6px;}

.sp-table{width:100%;border-collapse:collapse;background:#fff;border:1px solid #e5e7eb;border-radius:16px;overflow:hidden;}
.sp-table th,.sp-table td{padding:10px;border-bottom:1px solid #eee;font-size:14px;vertical-align:top;text-align:left;}
.sp-table th{background:#fafafa;}
.sp-table tbody tr:hover{background:#fafafa}
.sp-badge{padding:3px 8px;border-radius:999px;font-size:12px;border:1px solid #ddd;display:inline-block;background:#fff;}
.sp-qty{font-weight:900;text-align:right;}
.sp-price{text-align:right;font-variant-numeric:tabular-nums;}
.sp-mini{display:inline-flex;gap:8px;align-items:center;flex-wrap:wrap;}
.sp-mini input{width:70px;padding:9px 10px;border:1px solid #d1d5db;border-radius:12px;}
.sp-mini button{padding:9px 10px;border-radius:12px;border:1px solid #111;background:#111;color:#fff;cursor:pointer;}
.sp-mini .ghost{background:#fff;color:#111;border:1px solid #e5e7eb;}
.sp-mini .ghost:hover{background:#fafafa}

/* =========================
   HEADER polish
========================= */

.iconbtn{
  box-shadow: 0 1px 0 rgba(0,0,0,.02);
}
.iconbtn:hover{
  transform: translateY(-1px);
}
.iconbtn:active{
  transform: translateY(0px);
}

/* brand text a bit cleaner when no logo */
.topbar .brand .name{
  font-size:16px;
}

/* =========================
   FOOTER (no inline CSS)
========================= */
.site-footer{
  margin-top:auto;
  width: 100%;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-top:1px solid var(--line);
}
.site-footer__inner{
width: 100%;
  box-sizing: border-box;
  padding:14px 0;
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
}
.site-footer__title{
  font-weight:950;
}
.site-footer__sub{
  color:var(--muted);
  font-size:12px;
  margin-top:4px;
}
.site-footer__nav{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  align-items:center;
}
.site-footer__nav a{
  color:var(--muted);
  font-size:12px;
  text-decoration:none;
  font-weight:800;
}
.site-footer__nav a:hover{
  text-decoration:underline;
}
.site-footer__copy{
  color:var(--muted);
  font-size:12px;
}

.site-footer__content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
}


/* =========================
   PRODUCTS UI (global)
========================= */

/* page spacing helpers */
.page-wrap{padding:18px 0 14px 0;}

/* tabs */
.tabs{display:inline-flex;border:1px solid var(--line);border-radius:14px;overflow:hidden;background:#fff;height:40px;}
.tabs button{border:0;background:#fff;padding:0 12px;cursor:pointer;height:40px;}
.tabs button.active{background:#111;color:#fff;}

/* chips */
.chipsbar{display:flex;gap:8px;align-items:center;overflow:auto;padding-bottom:2px;}
.chip{
  display:inline-flex;gap:8px;align-items:center;
  padding:7px 10px;border-radius:999px;border:1px solid var(--line);background:#fff;
  text-decoration:none;font-size:13px;color:#111;white-space:nowrap;
}
.chip:hover{background:#fafafa}

/* Save filter dropdown */
.details-save{position:relative;}
.details-save summary{
  list-style:none; cursor:pointer;
  display:inline-flex;gap:8px;align-items:center;
  padding:9px 10px;border-radius:14px;border:1px solid var(--line);background:#fff;
  height:40px;
}
.details-save summary::-webkit-details-marker{display:none;}
.details-save[open] summary{border-color:#111;box-shadow:var(--ring);}

.save-pop{
  position:absolute; right:0; top:48px;
  width:min(420px, 92vw);
  background:#fff;border:1px solid var(--line);border-radius:16px;
  padding:12px; z-index:2500;
  box-shadow:0 10px 30px rgba(0,0,0,.12);
}

/* table helpers */
.qty{font-weight:900;text-align:right;font-variant-numeric:tabular-nums;}
.price{text-align:right;font-variant-numeric:tabular-nums;}
.price .val{font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;}
.price .eur{color:var(--muted);font-size:12px;margin-left:4px;}
.reserved{color:#b45309;font-weight:900;}

/* cards */
.cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:12px;}
@media (max-width: 1100px){ .cards{grid-template-columns:repeat(2,minmax(0,1fr));} }
@media (max-width: 640px){ .cards{grid-template-columns:repeat(1,minmax(0,1fr));} }

.p-card{border:1px solid var(--line);border-radius:16px;background:#fff;padding:12px;display:flex;flex-direction:column;gap:10px;}
.p-title{font-weight:950;}
.p-meta{display:flex;gap:8px;flex-wrap:wrap;align-items:center;color:var(--muted);font-size:12px;}
.p-row{display:flex;justify-content:space-between;gap:10px;align-items:center;}
.p-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center;}
.p-actions input{width:70px;}
.p-actions button{height:40px;}
.p-actions .ghost{background:#fff;color:#111;border:1px solid var(--line);}
.p-actions .ghost:hover{background:#fafafa}


/* Full-width container only where we want it */
.container-wide{
  width: 100%;
  max-width: none;
  padding-left: 16px;
  padding-right: 16px;
}
@media (min-width: 1200px){
  .container-wide{ padding-left: 24px; padding-right: 24px; }
}


/* ===== PRODUCTS: FINAL (keep only this version) ===== */

.page-wrap{padding:18px 0 14px 0;}
.page-wrap--under-probar{padding-top:0;}

.probar .inner{padding:10px 0;}


/* actions row */
.probar-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
  justify-content:flex-end;
}
.probar-actions .btnpro,
.probar-actions .tabs,
.probar-actions details.details-save > summary{
  height:40px;
}
@media (min-width: 900px){
  .probar-actions{flex-wrap:nowrap;}
}

/* ===== PROBAR FILTERS: GRID (FINAL) ===== */

.probar .inner{ padding:10px 0; }

.probar .proform{
  display:grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap:10px;
  align-items:end;
}

/* generic field wrapper */
.probar .f{
  min-width:0; /* important for grid */
}

/* label */
.probar .f .lbl{
  display:block;
  font-size:11px;
  font-weight:800;
  color:var(--muted);
  margin:0 0 4px 0;
}

/* controls height consistent */
.probar .f input,
.probar .f select{
  height:40px;
  width:100%;
}

/* spans */
.probar .span-6{ grid-column: span 6; }
.probar .span-4{ grid-column: span 4; }
.probar .span-3{ grid-column: span 3; }
.probar .span-2{ grid-column: span 2; }
.probar .span-1{ grid-column: span 1; }

/* Apply button aligns */
.probar .apply-btn{
  height:40px;
  width:100%;
  justify-content:center;
}

/* responsive: stack nicer */
@media (max-width: 1100px){
  .probar .span-6{ grid-column: span 12; }
  .probar .span-4{ grid-column: span 6; }
  .probar .span-3{ grid-column: span 6; }
  .probar .span-2{ grid-column: span 6; }
  .probar .span-1{ grid-column: span 6; }
}
@media (max-width: 640px){
  .probar .span-4,
  .probar .span-3,
  .probar .span-2,
  .probar .span-1{ grid-column: span 12; }
}

/* =========================
   DASHBOARD (index.php)
========================= */

.dash-wrap{padding:18px 0 14px 0;}
.dash-wrap--under-probar{padding-top:20px;}

.dash-hero{
  display:flex;
  gap:12px;
  align-items:flex-start;
  justify-content:space-between;
  flex-wrap:wrap;
}

.dash-title{
  font-weight:950;
  font-size:18px;
  letter-spacing:-.02em;
}

.dash-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
}

.grid-4{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}
@media (max-width: 980px){ .grid-4{grid-template-columns:repeat(2,minmax(0,1fr));} }
@media (max-width: 560px){ .grid-4{grid-template-columns:1fr;} }

.grid-2{
  display:grid;
  grid-template-columns: 1.2fr .8fr;
  gap:12px;
  align-items:start;
}
@media (max-width: 980px){ .grid-2{grid-template-columns:1fr;} }

.kpi-title{font-size:12px;color:var(--muted);font-weight:900;}
.kpi-val{font-size:22px;font-weight:950;letter-spacing:-.02em;margin-top:6px;}
.kpi-sub{margin-top:6px;color:var(--muted);font-size:12px;}

.catgrid{
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:10px;
}
@media (max-width: 980px){ .catgrid{grid-template-columns:repeat(3,minmax(0,1fr));} }
@media (max-width: 560px){ .catgrid{grid-template-columns:repeat(2,minmax(0,1fr));} }

.cat{
  padding:12px;
  border-radius:16px;
  border:1px solid var(--line);
  background:#fff;
  text-decoration:none;
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:center;
}
.cat:hover{background:#fafafa;}
.cat b{font-size:13px;}

.flash{padding:10px;border-radius:12px;margin-bottom:12px;}
.flash.err{background:#fee2e2;border:1px solid #fecaca;color:#991b1b;}
.flash.ok{background:#dcfce7;border:1px solid #bbf7d0;color:#166534;}

/* =========================================
   SEARCH DRAWER - FINAL POLISH + MOBILE UI
========================================= */

/* glass panel like .probar */
.sp-panel{
  position:absolute;
  top:0;
  right:0;
  height:100%;
  width:min(980px,96vw);

  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);

  border-left:1px solid var(--line);
  display:flex;
  flex-direction:column;

  transform:translateX(105%);
  transition:transform .18s ease;
}

/* header spacing */
.sp-head{
  padding:14px 16px;
  border-bottom:1px solid var(--line);
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
}

/* form glass */
.sp-form{
  padding:12px 16px;
  border-bottom:1px solid var(--line);
  background:transparent;
}

/* query input same height as selects */
.sp-input{
  display:flex;
  gap:8px;
  align-items:center;

  border:1px solid var(--line);
  border-radius:14px;

  height:40px;
  padding:0 12px;

  background:#fff;
}
.sp-input i{color:var(--muted);}
.sp-input input{
  border:0;
  outline:none;
  flex:1;
  font-size:14px;
  background:transparent;
}

/* selects + buttons same height */
.sp-form select{
  height:40px;
  padding:0 12px;
  border:1px solid var(--line);
  border-radius:14px;
  background:#fff;
  width:100%;
}

.sp-btn,
.sp-link{
  height:40px;
  padding:0 12px;
  border-radius:14px;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.sp-link{
  border:1px solid var(--line);
  background:#fff;
}
.sp-link:hover{background:#fafafa;}

/* highlight */
.sp-mark{
  background:#fff7ed;
  border:1px solid #fed7aa;
  border-radius:6px;
  padding:0 4px;
}

/* ===== Mobile: table -> cards feel ===== */
@media (max-width: 680px){
  .sp-table{
    border:0;
    background:transparent;
  }
  .sp-table thead{display:none;}
  .sp-table tbody{display:block;}
  .sp-table tr{
    display:block;
    background:#fff;
    border:1px solid var(--line);
    border-radius:16px;
    margin-bottom:10px;
    overflow:hidden;
  }
  .sp-table td{
    display:block;
    border-bottom:1px solid #eee;
    padding:10px 12px;
  }
  .sp-table td:last-child{border-bottom:0;}

  /* tighten mini actions */
  .sp-mini{
    width:100%;
  }
}

/* =========================
   SAVED FILTERS PAGE
========================= */

.sf-wrap{padding:18px 0 14px 0;}
.sf-wrap--under-probar{padding-top:22px;}

.sf-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}
@media (max-width: 980px){ .sf-grid{grid-template-columns:repeat(2,minmax(0,1fr));} }
@media (max-width: 640px){ .sf-grid{grid-template-columns:1fr;} }

.sf-card{
  border:1px solid var(--line);
  border-radius:16px;
  background:#fff;
  padding:12px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.sf-title{font-weight:950;}
.sf-meta{color:var(--muted);font-size:12px;line-height:1.4;}

.sf-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
}
.sf-actions form{margin:0;}

.sf-input{width:100%;}

.sf-mini{
  display:flex;
  gap:8px;
  align-items:center;
  flex-wrap:wrap;
}

.sf-copy-btn{white-space:nowrap;}

.tag.mono{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Courier New", monospace;
}

.tag.clickable{
  cursor:pointer;
}

.tag.clickable:hover{
  background:#fafafa;
}
/* =========================
   TOAST (fade in/out)
========================= */
.toastwrap{
  position:fixed;
  right:16px;
  bottom:16px;
  z-index:5000;
  display:flex;
  flex-direction:column;
  gap:10px;
  pointer-events:none;
}

.toast{
  pointer-events:none;
  min-width:min(360px, 92vw);
  background:rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border:1px solid var(--line);
  border-radius:16px;
  box-shadow: 0 20px 60px rgba(0,0,0,.12);
  padding:12px;
  display:flex;
  gap:10px;
  align-items:flex-start;

  opacity:0;
  transform: translateY(10px);
  transition: opacity .18s ease, transform .18s ease;
}

.toast.is-in{
  opacity:1;
  transform: translateY(0);
}

.toast .ico{
  width:34px;
  height:34px;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid var(--line);
  background:#fff;
  flex:0 0 auto;
}

.toast.ok .ico{background:#dcfce7;border-color:#16a34a;color:#166534;}
.toast.err .ico{background:#fee2e2;border-color:#ef4444;color:#991b1b;}
.toast.warn .ico{background:#ffedd5;border-color:#f59e0b;color:#92400e;}

.toast .t-title{font-weight:950;line-height:1.2;}
.toast .t-sub{color:var(--muted);font-size:12px;margin-top:3px;line-height:1.3;}
/* =========================
   ICON PULSE (cart/wishlist)
========================= */
@keyframes uiPulse {
  0%   { transform: translateY(0) scale(1); box-shadow: 0 1px 0 rgba(0,0,0,.02); }
  30%  { transform: translateY(-2px) scale(1.03); box-shadow: 0 12px 28px rgba(0,0,0,.10); }
  70%  { transform: translateY(0) scale(1); box-shadow: 0 8px 18px rgba(0,0,0,.08); }
  100% { transform: translateY(0) scale(1); box-shadow: 0 1px 0 rgba(0,0,0,.02); }
}

.iconbtn.ui-pulse{
  animation: uiPulse .38s ease;
}

/* =========================
   GRADE BADGE (pro)
========================= */
.grade-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  font-size:12px;
  font-weight:950;
  letter-spacing:.02em;
  line-height:1;
  white-space:nowrap;
  user-select:none;
}
.grade-badge i{
  font-size:13px;
  opacity:.92;
}
.grade-badge .g{
  display:inline-block;
  min-width:12px;
  text-align:center;
}
/* =========================
   TOOLTIP (adaptive + clamp ready)
========================= */
[data-tip]{ position:relative; }

[data-tip]::after{
  content: attr(data-tip);
  position: fixed;                 /* IMPORTANT: fixed -> JS can place */
  left: -9999px;
  top: -9999px;
  transform: translateY(-4px);
  background:#111;
  color:#fff;
  padding:7px 10px;
  border-radius:10px;
  font-size:12px;
  line-height:1.25;
  white-space:nowrap;             /* default compact */
  max-width: min(360px, 88vw);    /* but can grow */
  overflow:hidden;
  text-overflow: ellipsis;
  opacity:0;
  pointer-events:none;
  transition:opacity .12s ease, transform .12s ease;
  z-index:4000;
}

[data-tip].tip-multiline::after{
  white-space:normal;             /* long tooltips */
  overflow:visible;
  text-overflow:unset;
}

[data-tip]:hover::after{
  opacity:1;
  transform: translateY(0);
}

/* =========================
   CONDITION BADGE
========================= */

.condition-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:900;
  border:1px solid var(--line);
  letter-spacing:.03em;
}

.condition-badge.refurb{
  background:#e0f2fe;
  border-color:#0284c7;
  color:#075985;
}

.condition-badge.new{
  background:#dcfce7;
  border-color:#16a34a;
  color:#166534;
}

.condition-badge.scrap{
  background:#fee2e2;
  border-color:#ef4444;
  color:#991b1b;
}
/* =========================
   CONDITION BADGE
========================= */

.condition-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:900;
  border:1px solid var(--line);
  letter-spacing:.03em;
  margin-right:6px;
}

.condition-badge.refurb{
  background:#e0f2fe;
  border-color:#0284c7;
  color:#075985;
}

.condition-badge.new{
  background:#dcfce7;
  border-color:#16a34a;
  color:#166534;
}

.condition-badge.scrap{
  background:#fee2e2;
  border-color:#ef4444;
  color:#991b1b;
}
/* =========================
   PRODUCTS LEGEND
========================= */

.grade-legend{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
  margin-top:6px;
}

.legend-title{
  font-size:12px;
  font-weight:900;
  color:var(--muted);
}
/* =========================
   PRODUCTS: TABLE AS CARDS
========================= */
.products-table{
  width:100%;
  border:0;
  background:transparent;
  border-collapse:separate;
  border-spacing:0 10px; /* spacing between rows */
}

.products-table thead{ display:none; }

.products-table tbody tr{
  display:block;
  background:#fff;
  border:1px solid var(--line);
  border-radius:16px;
  box-shadow: var(--shadow-sm);
  overflow:hidden;
}

.products-table tbody td{
  display:block;
  border:0;
  padding:12px;
}

.products-table tbody td + td{
  border-top:1px solid #eee;
}

.products-table .row-top{
  display:flex;
  gap:12px;
  align-items:flex-start;
  justify-content:space-between;
  flex-wrap:wrap;
}

.products-table .row-left{
  min-width:260px;
  flex: 1 1 520px;
}

.products-table .row-right{
  display:flex;
  gap:10px;
  align-items:flex-start;
  justify-content:flex-end;
  flex-wrap:wrap;
}

.products-table .meta-line{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
  margin-top:8px;
}

.products-table .status-line{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
  margin-top:8px;
}

.products-table .actions-line{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
  justify-content:flex-end;
}

.products-table .price-big{
  font-weight:950;
  font-variant-numeric:tabular-nums;
  white-space:nowrap;
}

.products-table .price-big .eur{
  color:var(--muted);
  font-weight:800;
  font-size:12px;
  margin-left:4px;
}
/* Disable CSS pseudo tooltips (we use JS tooltip) */
[data-tip]::after,
[data-tip]::before{
  content: none !important;
  display: none !important;
}
/* =========================
   PRODUCTS – remove card bg
========================= */

.products-page .card{
  background: transparent;
  border: none;
  box-shadow: var(--shadow-sm);
}

/* =========================
   PRODUCTS row hover
========================= */

.products-page .products-table tbody tr{
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
}

.products-page .products-table tbody tr:hover{
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
  background: rgba(255,255,255,.65);
}
/* =========================
   PRODUCTS: skeleton loading
========================= */

.products-loading{
  position:fixed;
  inset:0;
  z-index:2600;                 /* peste .probar (1900) și topbar (2000) */
  display:none;
  background: rgba(246,247,249,.96);
}

.products-loading.is-open{ display:block; }

.products-loading__panel{
  position:absolute;
  left:0; right:0;
  top: var(--products-overlay-top, calc(var(--topbar-offset, 66px) + 64px)); /* fallback sigur */
  bottom:0;
  overflow:auto;
  padding:18px 16px;
}

.products-loading__grid{
  max-width:1320px;
  margin:0 auto;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.skel-row{
  border-radius:16px;
  border:1px solid rgba(15,23,42,.10);
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(10px);
  padding:12px;
}

.skel-line{
  height:12px;
  border-radius:999px;
  background: rgba(15,23,42,.08);
  position:relative;
  overflow:hidden;
}

.skel-line.sm{ height:10px; opacity:.9; }
.skel-line.lg{ height:16px; opacity:.95; }

.skel-w-20{ width:20%; }
.skel-w-35{ width:35%; }
.skel-w-55{ width:55%; }
.skel-w-70{ width:70%; }
.skel-w-90{ width:90%; }

.skel-row .skel-stack{ display:flex; flex-direction:column; gap:10px; }

.skel-badges{ display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.skel-badge{
  width:90px; height:26px;
  border-radius:999px;
  background: rgba(15,23,42,.08);
  position:relative;
  overflow:hidden;
}

@keyframes shimmer {
  0%   { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

.skel-line::after,
.skel-badge::after{
  content:"";
  position:absolute;
  inset:-40% -60%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent);
  transform: translateX(-120%);
  animation: shimmer 1.1s linear infinite;
}
/* Cards skeleton grid */
.skel-cards{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}
@media (max-width: 1100px){ .skel-cards{grid-template-columns:repeat(2,minmax(0,1fr));} }
@media (max-width: 640px){ .skel-cards{grid-template-columns:repeat(1,minmax(0,1fr));} }

.skel-card{
  border-radius:16px;
  border:1px solid rgba(15,23,42,.10);
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(10px);
  padding:12px;
}


.probar-filters-smart{
  display:block;
}



.tier-inline-msg{
  margin-top:6px;
  font-size:12px;
  color:#64748b;
  line-height:1.35;
}

.front-modal-backdrop{
  position:fixed;
  inset:0;
  background:rgba(15,23,42,.48);
  z-index:5000;
}

.front-modal-shell{
  position:fixed;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  z-index:5001;
}

.front-modal-card{
  width:760px;
  max-width:96vw;
  max-height:88vh;
  overflow:auto;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:20px;
  box-shadow:0 30px 80px rgba(0,0,0,.18);
  padding:18px;
}

.probar-compact{
  background:#fff;
  border-bottom:1px solid #e5e7eb;
  position:sticky;
  top:var(--topbar-offset,66px);
  z-index:1900;
}

.probar-shell{
  padding:10px 0;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.probar-top{
  display:grid;
  grid-template-columns:auto minmax(260px,1fr) auto;
  gap:12px;
  align-items:center;
}

.probar-title-line{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.probar-title{
  font-size:18px;
  font-weight:950;
  line-height:1.1;
}

.probar-meta{
  color:#64748b;
  font-size:12px;
  margin-top:4px;
}

.legend-btn{
  display:inline-flex;
  align-items:center;
  gap:6px;
  border:1px solid #e5e7eb;
  background:#fff;
  color:#111827;
  border-radius:999px;
  height:34px;
  padding:0 12px;
  cursor:pointer;
  font-size:13px;
  font-weight:700;
}

.legend-btn:hover{background:#fafafa;}

.probar-search-form{margin:0;}

.probar-search-box{
  display:flex;
  align-items:center;
  gap:10px;
  height:42px;
  border:1px solid #e5e7eb;
  border-radius:14px;
  background:#fff;
  padding:0 12px;
}

.probar-search-box i{
  color:#64748b;
  font-size:14px;
}

.probar-search-box input{
  border:0;
  outline:0;
  width:100%;
  font-size:14px;
  background:transparent;
}

.filter-pills-row{
  display:flex;
  gap:8px;
  align-items:center;
  flex-wrap:wrap;
}

.filter-pill{
  position:relative;
}

.filter-pill-btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-height:38px;
  border:1px solid #e5e7eb;
  border-radius:999px;
  background:#fff;
  padding:0 12px;
  cursor:pointer;
  color:#111827;
}

.filter-pill-btn .k{
  font-size:11px;
  font-weight:800;
  color:#64748b;
}

.filter-pill-btn .v{
  font-size:13px;
  font-weight:800;
  color:#111827;
  max-width:140px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.filter-pill-btn i{
  color:#64748b;
  font-size:12px;
}

.filter-pill.is-open .filter-pill-btn{
  border-color:#111827;
  box-shadow:0 0 0 4px rgba(17,24,39,.08);
}

.filter-pill-pop{
  display:none;
  position:absolute;
  top:calc(100% + 8px);
  left:0;
  min-width:220px;
  max-width:280px;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:16px;
  box-shadow:0 20px 50px rgba(0,0,0,.12);
  z-index:2100;
  overflow:hidden;
}

.filter-pill.is-open .filter-pill-pop{
  display:block;
}

.filter-pill-head{
  padding:10px 12px;
  border-bottom:1px solid #e5e7eb;
  font-size:13px;
  font-weight:900;
  background:#fafafa;
}

.filter-pill-body{
  padding:12px;
}

.filter-pill-body input{
  width:100%;
  border:1px solid #d1d5db;
  border-radius:12px;
  background:#fff;
  padding:10px 12px;
  font-size:14px;
  outline:none;
}

.filter-pill-body input:focus{
  border-color:#111827;
  box-shadow:0 0 0 4px rgba(17,24,39,.08);
}

.filter-pill-list{
  padding:8px;
  display:flex;
  flex-direction:column;
  gap:6px;
  max-height:280px;
  overflow:auto;
}

.filter-opt{
  display:flex;
  align-items:center;
  justify-content:space-between;
  width:100%;
  text-align:left;
  padding:10px 12px;
  border:1px solid #e5e7eb;
  background:#fff;
  border-radius:12px;
  cursor:pointer;
  font-size:13px;
  font-weight:700;
  color:#111827;
}

.filter-opt:hover{
  background:#fafafa;
}

.filter-opt.active{
  border-color:#111827;
  background:#111827;
  color:#fff;
}

.probar-bottom{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:flex-start;
  flex-wrap:wrap;
}

.chipsbar-compact{
  display:flex;
  gap:6px;
  flex-wrap:wrap;
  align-items:center;
  flex:1 1 420px;
}

.tier-inline{
  flex:1 1 360px;
  min-width:320px;
  max-width:520px;
  border:1px solid #e5e7eb;
  border-radius:14px;
  background:#fafafa;
  padding:8px 10px;
}

.tier-inline-top{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:center;
  flex-wrap:wrap;
}

.tier-inline-title{
  font-size:13px;
  font-weight:900;
  color:#111827;
  display:flex;
  align-items:center;
  gap:6px;
}

.tier-inline-next{
  font-size:12px;
  color:#64748b;
  font-weight:700;
}

.tier-inline-bar{
  margin-top:8px;
  height:7px;
  background:#e5e7eb;
  border-radius:999px;
  overflow:hidden;
}

.tier-inline-bar-fill{
  height:100%;
  background:#111827;
  border-radius:999px;
}

.tier-inline-msg{
  margin-top:6px;
  font-size:12px;
  color:#64748b;
  line-height:1.35;
}

@media (max-width:1100px){
  .probar-top{
    grid-template-columns:1fr;
  }
}

@media (max-width:768px){
  .filter-pills-row{
    overflow-x:auto;
    flex-wrap:nowrap;
    padding-bottom:4px;
  }

  .filter-pill{
    flex:0 0 auto;
  }

  .tier-inline{
    min-width:100%;
    max-width:none;
  }

  .front-modal-card{
    width:96vw;
    padding:14px;
  }
}

.products-table td,
.products-table th{
  vertical-align:middle;
}

.actions-line{
  display:flex;
  gap:8px;
  align-items:center;
  flex-wrap:wrap;
}

.status-line{
  display:flex;
  gap:8px;
  align-items:center;
  flex-wrap:wrap;
}

.clickable{
  cursor:pointer;
}

.clickable.copied{
  outline:2px solid #111827;
  outline-offset:2px;
}

.p-card{
  display:flex;
  flex-direction:column;
  gap:12px;
  padding:16px;
  border:1px solid #e5e7eb;
  border-radius:16px;
  background:#fff;
}

.cards{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(260px, 1fr));
  gap:14px;
  padding:16px;
}

.p-title{
  font-size:16px;
  font-weight:900;
  line-height:1.3;
}

.p-meta{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
}

.p-row{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:center;
}

.p-actions{
  display:flex;
  gap:8px;
  align-items:center;
  flex-wrap:wrap;
}

.price-big{
  font-size:18px;
  font-weight:950;
}

.price-big .eur{
  margin-left:2px;
  font-size:.9em;
}

.products-loading{
  position:fixed;
  inset:0;
  z-index:4000;
  display:none;
  background:rgba(255,255,255,.7);
  backdrop-filter:blur(2px);
}

.products-loading.is-open{
  display:block;
}

.products-loading__panel{
  position:absolute;
  top:var(--products-overlay-top, 0);
  left:0;
  right:0;
  bottom:0;
  overflow:auto;
  padding:16px;
}

.skel-cards{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(260px,1fr));
  gap:14px;
}

.skel-card,
.skel-row{
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:16px;
  padding:16px;
}

.skel-stack{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.skel-line{
  height:12px;
  border-radius:999px;
  background:linear-gradient(90deg,#f1f5f9 25%,#e2e8f0 37%,#f1f5f9 63%);
  background-size:400% 100%;
  animation:skel 1.2s ease infinite;
}

.skel-line.lg{ height:16px; }
.skel-line.sm{ height:10px; }
.skel-w-70{ width:70%; }
.skel-w-55{ width:55%; }
.skel-w-35{ width:35%; }

.skel-badges{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

.skel-badge{
  width:72px;
  height:28px;
  border-radius:999px;
  background:linear-gradient(90deg,#f1f5f9 25%,#e2e8f0 37%,#f1f5f9 63%);
  background-size:400% 100%;
  animation:skel 1.2s ease infinite;
}

@keyframes skel{
  0%{ background-position:100% 50%; }
  100%{ background-position:0 50%; }
}

.legend-close-btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-height:40px;
  padding:0 14px;
  border-radius:12px;
  font-weight:800;
}

.legend-close-btn i{
  font-size:14px;
  line-height:1;
}

.legend-open-btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-height:34px;
  padding:0 12px;
  border-radius:999px;
  font-size:13px;
  font-weight:700;
}

.filter-opt-main{
  display:inline-flex;
  align-items:center;
  gap:8px;
}

.filter-opt-main i{
  font-size:14px;
  line-height:1;
  flex:0 0 auto;
}

.filter-pill-btn .v.with-icon{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-width:0;
}

.filter-pill-btn .v.with-icon i{
  font-size:14px;
  line-height:1;
  flex:0 0 auto;
}

.filter-pill-btn .v.with-icon span{
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

/* FIX products cards jumping under header */
.products-page,
.products-page .shop-page{
  position: relative;
  padding-top: 18px !important;
}

.products-page .shop-layout{
  align-items: start;
}

.products-page [data-view-block="cards"]{
  position: static !important;
  transform: none !important;
  margin-top: 0 !important;
}

.products-page .cards{
  align-items: start;
}

.products-page .p-card{
  position: relative;
  overflow: hidden;
}

.front-switch{
  display:inline-flex;
  align-items:center;
  gap:2px;
  border:1px solid var(--line);
  background:#fff;
  border-radius:999px;
  padding:3px;
  height:42px;
}

.front-switch a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:38px;
  height:34px;
  padding:0 9px;
  border-radius:999px;
  text-decoration:none;
  font-size:12px;
  font-weight:900;
  color:#64748b;
}

.front-switch a.active{
  background:#111827;
  color:#fff;
}

.tier-pill{
  display:inline-flex;
  align-items:center;
  gap:6px;
  height:42px;
  padding:3px 6px 3px 10px;
  border:1px solid #bbf7d0;
  background:#ecfdf5;
  color:#166534;
  border-radius:999px;
  font-size:12px;
  font-weight:900;
  white-space:nowrap;
}

.tier-pill i{
  font-size:14px;
  color:#16a34a;
}

.tier-pill span{
  max-width:86px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.tier-pill strong{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height:34px;
  padding:0 10px;
  border-radius:999px;
  background:#16a34a;
  color:#fff;
  font-size:12px;
  font-weight:950;
}

.sp-category-field{
  min-width:220px;
}

.sp-category-field input[data-sp-category-search]{
  width:100%;
  margin-bottom:6px;
  border:1px solid var(--line);
  border-radius:12px;
  padding:8px 10px;
  font-size:13px;
  background:#fff;
}

.sp-input input:focus,
.sp-combo input:focus,
.sp-field select:focus{
  outline:none;
  box-shadow:none;
  border-color:var(--line);
}

.sp-input:focus-within,
.sp-combo:focus-within{
  border-color:#cbd5e1;
  box-shadow:0 0 0 3px rgba(15,23,42,.06);
}

.sp-category-combo{
  min-width:260px;
}

.sp-combo{
  position:relative;
}

.sp-combo input{
  width:100%;
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px 12px;
  font-size:13px;
  background:#fff;
  font-weight:800;
}

.sp-combo-menu{
  display:none;
  position:absolute;
  z-index:50;
  left:0;
  right:0;
  top:calc(100% + 6px);
  max-height:320px;
  overflow:auto;
  background:#fff;
  border:1px solid var(--line);
  border-radius:14px;
  box-shadow:0 18px 45px rgba(15,23,42,.16);
  padding:6px;
}

.sp-combo-menu.is-open{
  display:block;
}

.sp-combo-menu button{
  width:100%;
  border:0;
  background:transparent;
  text-align:left;
  padding:9px 10px;
  border-radius:10px;
  font-size:13px;
  cursor:pointer;
  color:#111827;
}

.sp-combo-menu button:hover{
  background:#f8fafc;
}

.sp-results-list{
  display:grid;
  gap:8px;
}

.sp-product{
  display:grid;
  grid-template-columns:72px minmax(0,1fr) auto;
  gap:12px;
  align-items:center;
  padding:10px;
  border:1px solid var(--line);
  border-radius:16px;
  background:#fff;
}

.sp-product-img{
  width:72px;
  height:72px;
  border:1px solid var(--line);
  border-radius:14px;
  background:#f8fafc;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  color:#94a3b8;
  text-decoration:none;
}

.sp-product-img img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
}

.sp-product-main{
  min-width:0;
}

.sp-product-title{
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  font-weight:950;
  color:#111827;
  text-decoration:none;
  line-height:1.25;
}

.sp-product-title:hover{
  text-decoration:underline;
}

.sp-product-meta{
  margin-top:6px;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  color:var(--muted);
  font-size:12px;
}

.sp-product-stock{
  margin-top:7px;
  font-size:12px;
  font-weight:900;
}

.sp-product-stock.ok{
  color:#16a34a;
}

.sp-product-stock.off{
  color:#991b1b;
}

.sp-product-side{
  min-width:150px;
  display:grid;
  gap:8px;
  justify-items:end;
}

.sp-product-price{
  font-size:15px;
  font-weight:950;
  color:#111827;
}

.sp-mini{
  display:flex;
  gap:8px;
  align-items:center;
}

.sp-mini input[type="number"]{
  width:62px;
  height:36px;
  border:1px solid var(--line);
  border-radius:10px;
  padding:0 8px;
}

.sp-mini button{
  width:36px;
  height:36px;
  border-radius:10px;
  border:1px solid var(--line);
  background:#111827;
  color:#fff;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
}

.sp-mini button.ghost{
  background:#fff;
  color:#111827;
}

@media (max-width: 720px){
  .sp-product{
    grid-template-columns:64px minmax(0,1fr);
  }

  .sp-product-side{
    grid-column:1 / -1;
    min-width:0;
    justify-items:stretch;
    display:flex;
    justify-content:space-between;
    align-items:center;
  }
}