:root {
  --stx-primary: #0b5cad;
  --stx-primary-dark: #084584;
  --stx-accent: #ff7a00;
  --stx-dark: #15202b;
  --stx-muted: #64748b;
  --stx-bg: #f4f6f9;
}

html { font-size: 15px; position: relative; min-height: 100%; }
@media (min-width: 768px) { html { font-size: 16px; } }

body {
  background: var(--stx-bg);
  color: #1f2937;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1 0 auto; }

a { color: var(--stx-primary); }
.btn-primary {
  --bs-btn-bg: var(--stx-primary);
  --bs-btn-border-color: var(--stx-primary);
  --bs-btn-hover-bg: var(--stx-primary-dark);
  --bs-btn-hover-border-color: var(--stx-primary-dark);
  --bs-btn-active-bg: var(--stx-primary-dark);
}
.btn-outline-primary {
  --bs-btn-color: var(--stx-primary);
  --bs-btn-border-color: var(--stx-primary);
  --bs-btn-hover-bg: var(--stx-primary);
  --bs-btn-hover-border-color: var(--stx-primary);
}
.text-primary { color: var(--stx-primary) !important; }
.badge.bg-primary { background-color: var(--stx-primary) !important; }

/* ---- navbar ---- */
.stx-navbar {
  background: #fff;
  box-shadow: 0 1px 10px rgba(15, 23, 42, .06);
}
.stx-brand { font-weight: 800; letter-spacing: .5px; font-size: 1.35rem; color: var(--stx-dark) !important; }
.stx-brand span { color: var(--stx-accent); }
.navbar .nav-link { font-weight: 500; }
.navbar .nav-link:hover { color: var(--stx-primary) !important; }

/* ---- hero ---- */
.hero {
  background: linear-gradient(120deg, var(--stx-primary) 0%, var(--stx-primary-dark) 100%);
  color: #fff;
  border-radius: 1rem;
  padding: 3.5rem 2rem;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  right: -60px; top: -60px;
  width: 260px; height: 260px;
  background: rgba(255, 255, 255, .08);
  border-radius: 50%;
}
.hero h1 { font-weight: 800; font-size: clamp(1.8rem, 4vw, 2.8rem); }
.hero .lead { opacity: .92; }

/* ---- cards ---- */
.card { border: 1px solid #e8edf3; border-radius: .75rem; }
.product-card { transition: transform .15s ease, box-shadow .15s ease; }
.product-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(15, 23, 42, .1); }

.category-tile {
  display: flex; align-items: center; gap: .6rem;
  padding: 1rem 1.1rem;
  background: #fff; border: 1px solid #e8edf3; border-radius: .75rem;
  text-decoration: none; color: var(--stx-dark); font-weight: 600;
  transition: all .15s ease;
}
.category-tile:hover { border-color: var(--stx-primary); color: var(--stx-primary); transform: translateY(-2px); }
.category-tile .bi { color: var(--stx-accent); font-size: 1.2rem; }

.section-title { font-weight: 700; color: var(--stx-dark); }
.section-title .bar { display: inline-block; width: 34px; height: 3px; background: var(--stx-accent); vertical-align: middle; margin-right: .5rem; border-radius: 2px; }

/* ---- home: about summary block ---- */
.home-about-eyebrow {
  display: inline-block; letter-spacing: .12em; font-size: .72rem; font-weight: 700;
  color: var(--stx-accent); margin-bottom: .35rem;
}
.home-about-img {
  width: 100%; height: 320px; object-fit: cover;
  border-radius: 1rem; box-shadow: 0 10px 30px rgba(11, 31, 56, .12);
}
.home-about-text { color: #4a5568; line-height: 1.75; margin-bottom: 1.25rem; }

/* ---- home: stats strip ---- */
.stats-strip {
  background: linear-gradient(120deg, var(--stx-navy, #0b1f38) 0%, var(--stx-primary-dark) 100%);
  border-radius: 1rem; padding: 2rem 1rem; color: #fff;
}
.stats-strip .stat-item { padding: .5rem 0; }
.stats-strip .stat-num {
  font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; line-height: 1;
}
.stats-strip .stat-num span { color: var(--stx-accent); }
.stats-strip .stat-label {
  margin-top: .4rem; font-size: .85rem; font-weight: 500; opacity: .85; letter-spacing: .02em;
}
@media (min-width: 992px) {
  .stats-strip .col-lg-3:not(:last-child) .stat-item { border-right: 1px solid rgba(255, 255, 255, .15); }
}

/* ---- stat cards (dashboard) ---- */
.stat-card { border-radius: .75rem; border: 1px solid #e8edf3; background: #fff; }
.stat-card .stat-icon {
  width: 48px; height: 48px; border-radius: .6rem;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; color: #fff;
}
.stat-card .stat-num { font-size: 1.9rem; font-weight: 800; line-height: 1; }
.stat-card .stat-label { color: var(--stx-muted); font-size: .9rem; }

/* ---- footer ---- */
.stx-footer {
  background: var(--stx-dark);
  color: #cbd5e1;
  margin-top: 3rem;
  padding: 2.5rem 0 1rem;
}
.footer-grid {
  display: grid; gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  max-width: 1140px; margin: 0 auto; padding: 0 1rem;
}
.stx-footer h6 { color: #fff; text-transform: uppercase; font-size: .8rem; letter-spacing: 1px; margin-bottom: .75rem; }
.footer-muted { color: #94a3b8; font-size: .9rem; margin-bottom: .4rem; }
.footer-muted a { color: #94a3b8; text-decoration: none; }
.footer-muted a:hover { color: #fff; }
.footer-brand { font-weight: 800; font-size: 1.5rem; color: #fff; }
.footer-brand span { color: var(--stx-accent); }
.footer-copy { text-align: center; color: #64748b; font-size: .82rem; margin-top: 1.75rem; border-top: 1px solid rgba(255,255,255,.08); padding-top: 1rem; }

.lang-switch a { padding: 0 .35rem !important; color: var(--stx-muted) !important; }
.lang-switch a.active { color: var(--stx-primary) !important; font-weight: 700; }

/* ===== catalog / products page ===== */
.breadcrumb-stx { font-size: .85rem; margin-bottom: 1rem; }
.breadcrumb-stx a { color: var(--stx-muted); text-decoration: none; }
.breadcrumb-stx a:hover { color: var(--stx-primary); }

.catalog-sidebar {
  background: #fff; border: 1px solid #e8edf3; border-radius: .75rem; overflow: hidden;
  box-shadow: 0 1px 6px rgba(15,23,42,.04);
}
.catalog-sidebar .cs-head {
  background: var(--stx-dark); color: #fff; font-weight: 600;
  padding: .85rem 1rem; display: flex; align-items: center; justify-content: space-between;
}
.catalog-sidebar .cs-head .bi { color: var(--stx-accent); margin-right: .4rem; }
.cs-count {
  background: var(--stx-accent); color: #fff; font-size: .75rem; font-weight: 700;
  border-radius: 999px; min-width: 22px; height: 22px; display: inline-flex;
  align-items: center; justify-content: center; padding: 0 .4rem;
}

.cat-check-list { padding: .4rem; max-height: 62vh; overflow-y: auto; }
.cat-check {
  display: flex; align-items: center; gap: .6rem; cursor: pointer;
  padding: .5rem .6rem; border-radius: .5rem; margin: 0;
  color: #334155; font-size: .9rem; font-weight: 500; user-select: none;
}
.cat-check:hover { background: #f1f5f9; }
.cat-check input { position: absolute; opacity: 0; width: 0; height: 0; }
.cat-check .cc-box {
  flex: 0 0 18px; width: 18px; height: 18px; border: 1.5px solid #cbd5e1;
  border-radius: .35rem; display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-size: .8rem; transition: all .12s ease;
}
.cat-check .cc-box .bi { opacity: 0; }
.cat-check.on { background: #eef4fb; color: var(--stx-primary); font-weight: 600; }
.cat-check.on .cc-box { background: var(--stx-primary); border-color: var(--stx-primary); }
.cat-check.on .cc-box .bi { opacity: 1; }
.cs-foot { padding: .5rem .7rem .7rem; border-top: 1px solid #f1f5f9; }

.cs-cta {
  margin-top: 1rem; background: linear-gradient(135deg, var(--stx-primary), var(--stx-primary-dark));
  color: #fff; border-radius: .75rem; padding: 1.25rem; text-align: center;
}
.cs-cta .bi { font-size: 1.9rem; }
.cs-cta p { margin: .5rem 0 .9rem; font-size: .9rem; opacity: .92; }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--stx-muted); }
.empty-state .bi { font-size: 2.6rem; opacity: .5; }
.empty-state p { margin: .75rem 0 1rem; }

.btn-add {
  --bs-btn-color: var(--stx-primary); --bs-btn-border-color: #cfe0f3;
  --bs-btn-bg: #f4f9ff;
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--stx-primary); --bs-btn-hover-border-color: var(--stx-primary);
  font-weight: 600;
}

.catalog-toolbar {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .5rem;
  margin-bottom: 1.1rem; padding-bottom: .75rem; border-bottom: 2px solid #e8edf3;
}
.catalog-toolbar h1 { font-size: 1.5rem; font-weight: 700; color: var(--stx-dark); margin: 0; }
.catalog-toolbar .count { color: var(--stx-muted); font-weight: 600; font-size: .9rem; }

.p-card {
  background: #fff; border: 1px solid #e8edf3; border-radius: .75rem; overflow: hidden;
  height: 100%; display: flex; flex-direction: column;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.p-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(15,23,42,.12); border-color: #cbd5e1; }
.p-thumb { position: relative; display: block; height: 180px; background: #f8fafc; overflow: hidden; }
.p-thumb img { width: 100%; height: 100%; object-fit: contain; padding: .6rem; transition: transform .25s ease; }
.p-card:hover .p-thumb img { transform: scale(1.07); }
.p-noimg { display: flex; align-items: center; justify-content: center; height: 100%; color: #cbd5e1; font-size: 2.2rem; }
.p-body { padding: .85rem .9rem .4rem; flex: 1 1 auto; text-decoration: none; display: block; }
.p-title { font-size: .95rem; font-weight: 600; color: #1f2937; margin: 0 0 .4rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.5em; }
.p-code { display: inline-block; font-size: .76rem; color: var(--stx-primary);
  background: #eef4fb; border-radius: .35rem; padding: .1rem .45rem; font-family: ui-monospace, monospace; }
.p-foot { padding: .65rem .9rem .85rem; }

.pagination { --bs-pagination-color: var(--stx-primary); --bs-pagination-hover-color: var(--stx-primary-dark);
  --bs-pagination-active-bg: var(--stx-primary); --bs-pagination-active-border-color: var(--stx-primary);
  --bs-pagination-focus-box-shadow: 0 0 0 .2rem rgba(11,92,173,.2); gap: .15rem; }
.pagination .page-link { border-radius: .45rem; border-color: #e2e8f0; }

/* ========== premium polish ========== */
body { font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; letter-spacing: -0.006em; }
h1, h2, h3, h4, h5, h6, .stat-num, .stx-brand { letter-spacing: -0.02em; }

/* top contact bar */
.top-bar { background: #0f1824; color: #cbd5e1; font-size: .82rem; padding: .45rem 0; }
.top-bar a { color: #cbd5e1; text-decoration: none; transition: color .12s ease; }
.top-bar a:hover { color: #fff; }
.top-bar .bi { color: var(--stx-accent); margin-right: .3rem; }
.top-bar .tb-badge { color: #e2e8f0; font-weight: 500; }
.top-bar .tb-badge .bi { color: #22c55e; }

/* sticky, glassy navbar */
.stx-navbar {
  position: sticky; top: 0; z-index: 1020;
  background: rgba(255,255,255,.9); backdrop-filter: saturate(180%) blur(8px);
  box-shadow: 0 1px 0 rgba(15,23,42,.06), 0 6px 20px rgba(15,23,42,.05);
}
.stx-brand { font-size: 1.45rem; }

/* softer, layered shadows on surfaces */
.card, .catalog-sidebar, .stat-card, .p-card {
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 8px 24px rgba(15,23,42,.05);
}
.btn { border-radius: .55rem; font-weight: 600; }
.btn-lg { border-radius: .7rem; }
.btn-primary { box-shadow: 0 8px 18px rgba(11,92,173,.22); }
.btn-primary:hover { box-shadow: 0 10px 22px rgba(11,92,173,.3); }

/* hero refinement */
.hero { box-shadow: 0 24px 48px rgba(11,92,173,.28); }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.08) 1px, transparent 1px);
  background-size: 22px 22px; opacity: .5; pointer-events: none;
}

/* refined stat cards */
.stat-card { transition: transform .15s ease, box-shadow .15s ease; }
.stat-card:hover { transform: translateY(-2px); }
.stat-card .stat-icon { box-shadow: 0 6px 14px rgba(15,23,42,.18); }

/* category tiles on home */
.category-tile { box-shadow: 0 1px 2px rgba(15,23,42,.04); }

/* badges / chips polish */
.p-code { font-weight: 600; letter-spacing: .01em; }

/* section titles */
.section-title .bar { height: 4px; border-radius: 3px; }

/* ========== premium hero (navy) ========== */
:root { --stx-navy: #0b1f38; --stx-navy-2: #123257; }
.hero {
  background: linear-gradient(130deg, var(--stx-navy) 0%, var(--stx-navy-2) 55%, #0b5cad 120%);
  padding: 4rem 2.5rem;
  box-shadow: 0 24px 50px rgba(11,31,56,.35);
}
.hero::after { width: 420px; height: 420px; right: -120px; top: -140px; background: rgba(255,122,0,.10); }
.hero-inner { position: relative; z-index: 1; max-width: 760px; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: .45rem;
  font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: #ffd9b3; background: rgba(255,122,0,.14); border: 1px solid rgba(255,122,0,.3);
  padding: .35rem .75rem; border-radius: 999px; margin-bottom: 1.1rem;
}
.hero h1 { font-weight: 800; font-size: clamp(2rem, 5vw, 3.1rem); line-height: 1.1; margin: 0; color: #fff; }
.hero .u-accent { color: #ff9a3c; position: relative; white-space: nowrap; }
.hero .u-accent::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -.08em; height: .14em;
  background: var(--stx-accent); border-radius: 3px; opacity: .85;
}
.hero .lead { color: #c7d6ea; font-size: 1.12rem; margin: 1.1rem 0 1.8rem; max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 1.8rem; }
.btn-accent {
  --bs-btn-color: #fff; --bs-btn-bg: var(--stx-accent); --bs-btn-border-color: var(--stx-accent);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: #e86f00; --bs-btn-hover-border-color: #e86f00;
  --bs-btn-active-bg: #d96700; font-weight: 700; box-shadow: 0 10px 24px rgba(255,122,0,.35);
}
.hero .btn-outline-light { --bs-btn-border-color: rgba(255,255,255,.4); font-weight: 600; }
.hero-trust { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; color: #9fb4ce; font-size: .92rem; }
.hero-trust strong { color: #fff; }
.hero-trust .dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(255,255,255,.3); }
.hero-trust .bi { color: var(--stx-accent); }

/* ========== compact product cards + zoom + buttons ========== */
.p-thumb { height: 150px; }
.p-thumb img { padding: .5rem; }
.p-noimg { font-size: 1.9rem; }
.p-body { padding: .65rem .7rem .3rem; }
.p-title { font-size: .85rem; margin-bottom: .35rem; min-height: 2.3em; }
.p-code { font-size: .72rem; padding: .08rem .4rem; }

/* zoom hint on image hover */
.p-thumb { cursor: zoom-in; }
.p-zoom {
  position: absolute; top: .4rem; right: .4rem; width: 30px; height: 30px; border-radius: 50%;
  background: rgba(15,23,42,.62); color: #fff; display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: scale(.8); transition: all .15s ease; font-size: .9rem;
}
.p-card:hover .p-zoom { opacity: 1; transform: scale(1); }

/* footer: detail (eye) + add-to-basket */
.p-foot { display: flex; align-items: stretch; gap: .4rem; padding: .5rem .6rem .65rem; border-top: 1px solid #f1f5f9; }
.p-detail {
  flex: 0 0 auto; width: 36px; display: flex; align-items: center; justify-content: center;
  border: 1px solid #e2e8f0; border-radius: .5rem; color: var(--stx-primary); text-decoration: none;
  transition: all .12s ease;
}
.p-detail:hover { background: var(--stx-primary); color: #fff; border-color: var(--stx-primary); }

/* clear, filled "add to basket" button */
.btn-add {
  --bs-btn-color: #fff; --bs-btn-bg: var(--stx-primary); --bs-btn-border-color: var(--stx-primary);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--stx-primary-dark); --bs-btn-hover-border-color: var(--stx-primary-dark);
  --bs-btn-active-bg: var(--stx-primary-dark); font-weight: 600;
}

/* glightbox: keep it clean */
.glightbox-clean .gslide-description { background: #fff; }

/* ========== button fixes (explicit, cache/variant-proof) ========== */
/* product "add to basket": solid, prominent */
.p-foot { display: block; padding: .55rem .6rem .7rem; border-top: 1px solid #f1f5f9; }
.btn-add {
  background-color: var(--stx-primary) !important;
  border-color: var(--stx-primary) !important;
  color: #fff !important;
  font-weight: 600; padding: .5rem .75rem; border-radius: .55rem;
  box-shadow: 0 2px 8px rgba(11,92,173,.25);
}
.btn-add:hover, .btn-add:focus {
  background-color: var(--stx-primary-dark) !important;
  border-color: var(--stx-primary-dark) !important;
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(11,92,173,.35);
}
.btn-add .bi { margin-right: .3rem; }

/* hero primary CTA: readable orange */
.btn-accent {
  background-color: var(--stx-accent) !important;
  border-color: var(--stx-accent) !important;
  color: #fff !important;
  font-weight: 700;
}
.btn-accent:hover, .btn-accent:focus {
  background-color: #e86f00 !important;
  border-color: #e86f00 !important;
  color: #fff !important;
}

/* ===== search ===== */
.nav-search { max-width: 340px; width: 100%; }
.nav-search .form-control { background: #f1f5f9; border-color: #e2e8f0; }
.nav-search .form-control:focus { background: #fff; }
.search-chip {
  display: inline-flex; align-items: center; gap: .4rem; margin-top: .35rem;
  background: #eef4fb; color: var(--stx-primary); font-size: .82rem; font-weight: 600;
  padding: .15rem .6rem; border-radius: 999px;
}
.search-chip a { color: var(--stx-primary); text-decoration: none; font-size: 1.05rem; line-height: 1; }
.search-chip a:hover { color: #b91c1c; }
@media (max-width: 767px) { .nav-search { max-width: 100%; margin: .5rem 0; } }

/* ===== content pages ===== */
.catalog-card .catalog-cover {
  height: 220px; display: flex; align-items: center; justify-content: center;
  background: #f8fafc; overflow: hidden; border-bottom: 1px solid #eef2f7;
}
.catalog-card .catalog-cover img { max-width: 100%; max-height: 100%; object-fit: contain; }
.cms-content { line-height: 1.75; color: #334155; }
.cms-content img { max-width: 100%; height: auto; border-radius: .5rem; }
.cms-content h2, .cms-content h3 { margin-top: 1.5rem; font-weight: 700; color: var(--stx-dark); }

/* ===== home carousel ===== */
.home-carousel { border-radius: 1rem; overflow: hidden; box-shadow: 0 20px 40px rgba(11,31,56,.18); }
.home-carousel .carousel-item img { height: 360px; width: 100%; object-fit: contain; background: #f4f6f9; }
.home-carousel .carousel-caption {
  text-align: left; left: 6%; right: auto; bottom: 14%; max-width: 560px;
  background: linear-gradient(90deg, rgba(11,31,56,.82), rgba(11,31,56,.1));
  padding: 1.1rem 1.4rem; border-radius: .75rem;
}
.home-carousel .carousel-caption h2 { font-weight: 800; }
.home-carousel .cc-eyebrow { display: inline-block; color: #ffd9b3; font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin-bottom: .35rem; }
.home-carousel .carousel-control-prev, .home-carousel .carousel-control-next { width: 6%; }
.home-carousel .carousel-control-prev-icon, .home-carousel .carousel-control-next-icon {
  background-color: rgba(11,31,56,.55); border-radius: 50%; padding: 1.1rem; background-size: 45% 45%;
}
@media (max-width: 767px) { .home-carousel .carousel-item img { height: 240px; } .home-carousel .carousel-caption { bottom: 6%; padding: .7rem .9rem; } }

/* ===== product files ===== */
.product-files .file-row {
  display: flex; align-items: center; gap: .6rem; padding: .6rem .8rem; border: 1px solid #e8edf3;
  border-radius: .55rem; text-decoration: none; color: #334155; margin-bottom: .5rem; transition: all .12s ease;
}
.product-files .file-row:hover { border-color: var(--stx-primary); background: #f8fbff; }
.product-files .file-row .bi { color: #dc2626; font-size: 1.4rem; }
