/* V-SHOP modern responsive layer — overrides legacy vcomp styles */

:root {
  --shop-bg: #d7ebf8;
  --shop-bg-deep: #b9d7ef;
  --shop-panel: #ffffff;
  --shop-ink: #1c2a38;
  --shop-muted: #5a6b7a;
  --shop-line: #c5d8e8;
  --shop-accent: #9a1c28;
  --shop-accent-hot: #c41220;
  --shop-brand: #0d4f8b;
  --shop-brand-soft: #e8f3fc;
  --shop-price: #b01020;
  --shop-ok: #1f7a45;
  --shop-radius: 12px;
  --shop-radius-sm: 8px;
  --shop-shadow: 0 10px 28px rgba(13, 55, 95, 0.08);
  --shop-shadow-soft: 0 2px 10px rgba(13, 55, 95, 0.06);
  --shop-header-h: 0px;
  --shop-font: "Source Sans 3", "Segoe UI", sans-serif;
  --shop-display: "Outfit", "Source Sans 3", sans-serif;
  /* type scale — keep to these four sizes across the shop */
  --shop-fs-xs: 0.8rem;   /* meta, secondary captions, net prices */
  --shop-fs-sm: 0.9rem;   /* UI chrome, labels, buttons, tree, panel titles */
  --shop-fs: 1rem;        /* body, inputs, product titles */
  --shop-fs-lg: 1.2rem;   /* page titles, detail title, primary prices */
  --shop-max: 1280px;
  --shop-sidebar: 260px;
  --shop-aside: 260px;
  --shop-panel-pad: 0.7rem;
  --shop-panel-pad-x: 0.7rem;
  --shop-panel-pad-y: 0.7rem;
  --shop-panel-title-pad: 0.65rem 0.75rem 0.55rem;
  --shop-inset-pad: 0.65rem;
}

html {
  overflow-x: hidden;
  overflow-y: auto;
  font-size: 15px; /* legacy style.css sets *{font-size:8pt} on html; rem must not stay at 8pt */
}

body.shop-modern {
  margin: 0;
  padding: 0;
  color: var(--shop-ink);
  font-family: var(--shop-font);
  font-size: var(--shop-fs) !important;
  line-height: 1.45;
  background:
    radial-gradient(1200px 500px at 10% -10%, #f4fbff 0%, transparent 55%),
    radial-gradient(900px 420px at 100% 0%, #cfe4f5 0%, transparent 50%),
    linear-gradient(180deg, var(--shop-bg) 0%, #eaf4fb 45%, var(--shop-bg-deep) 100%);
  cursor: auto;
  min-height: 100vh;
}

body.shop-modern * {
  font-family: inherit;
  font-size: inherit;
  cursor: inherit;
}

body.shop-modern h1,
body.shop-modern h2,
body.shop-modern h3,
body.shop-modern h4,
body.shop-modern h5,
body.shop-modern h6,
body.shop-modern .H1,
body.shop-modern .H2,
body.shop-modern .H3,
body.shop-modern .H4 {
  font-family: var(--shop-display);
  color: var(--shop-ink);
  display: block;
  line-height: 1.25;
}

body.shop-modern a {
  color: var(--shop-brand);
  font-weight: 600;
  text-decoration: none;
  transition: color .15s ease;
}

body.shop-modern a:hover {
  color: var(--shop-accent-hot);
}

body.shop-modern button,
body.shop-modern .ListButton,
body.shop-modern BUTTON {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 600;
  height: auto;
  min-height: 34px;
  padding: 0.45rem 0.85rem;
  border: 1px solid #8aa8c2;
  border-radius: 8px;
  background: linear-gradient(180deg, #f7fbff 0%, #d7e7f4 100%);
  color: var(--shop-ink);
  cursor: pointer;
  box-shadow: none;
  white-space: nowrap;
}

body.shop-modern button:hover,
body.shop-modern .ListButton:hover {
  border-color: var(--shop-brand);
  background: linear-gradient(180deg, #fff 0%, #cfe0f0 100%);
}

body.shop-modern input,
body.shop-modern select,
body.shop-modern textarea {
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
  height: auto;
  min-height: 34px;
  padding: 0.4rem 0.65rem;
  border: 1px solid #9bb4c8;
  border-radius: 8px;
  background: #fff;
  color: var(--shop-ink);
  box-sizing: border-box;
}

body.shop-modern input:focus,
body.shop-modern select:focus,
body.shop-modern textarea:focus {
  outline: 2px solid rgba(13, 79, 139, 0.25);
  border-color: var(--shop-brand);
}

/* Layout shell */
#PageContent.shop-shell {
  max-width: var(--shop-max);
  margin: 0 auto;
  padding: 12px 14px 40px;
  height: auto;
  text-align: left;
}

.shop-layout {
  display: grid;
  grid-template-columns: var(--shop-sidebar) minmax(0, 1fr) var(--shop-aside);
  gap: 14px;
  align-items: start;
}

.shop-main {
  min-width: 0;
}

.shop-sidebar,
.shop-aside {
  min-width: 0;
}

/* Panels */
.panel.World {
  background: var(--shop-panel);
  border: 0;
  border-radius: var(--shop-radius);
  box-shadow: var(--shop-shadow-soft);
  overflow: hidden;
}

#User.panel.World,
#Advert.panel.World,
#Directory.panel.World,
#ShopContent.panel.World,
#TopBox.panel.World {
  border-radius: var(--shop-radius);
  overflow: hidden;
}

.panel-title {
  padding: var(--shop-panel-title-pad);
  border-bottom: 0;
  background: linear-gradient(180deg, #f4f9fd 0%, #e8f2fa 100%);
  border-radius: calc(var(--shop-radius) - 1px) calc(var(--shop-radius) - 1px) 0 0;
}

.panel-title h2 {
  margin: 0;
  font-size: var(--shop-fs-sm);
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--shop-brand);
}

.panel-body {
  padding: var(--shop-panel-pad-y) var(--shop-panel-pad-x);
  background: #fff;
  box-sizing: border-box;
}

/* unified inset for sidebar/aside panels */
body.shop-modern #Directory .panel-body,
body.shop-modern #User .panel-body,
body.shop-modern #Advert .panel-body {
  padding: var(--shop-panel-pad-y) var(--shop-panel-pad-x) !important;
}

#ShopContent .panel-body {
  padding: 0.85rem 1rem 1.1rem;
}

/* Hide legacy min-width spacers and decorative corner images leftovers */
.DirectoryBoxMinWidth,
.ShopContentBoxMinWidth,
.LoginBoxMinWidth,
.BasketBoxMinWidth,
.LanguageSelectorBoxMinWidth,
.AdvertNewestBoxMinWidth,
.AdvertGoodsBoxMinWidth,
.MenuBoxMinWidth,
.SearchBoxMinWidth,
.LogoBoxMinWidth,
.BannerBoxMinWidth,
.ContentTitleBoxMinWidth,
.ShopNacionaleBoxMinWidth {
  display: none !important;
}

/* Header */
.shop-header {
  margin-bottom: 14px;
}

.shop-header-top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 8px 12px 2px;
}

.shop-brand .LogoBox,
.shop-brand .LogoBoxBody,
.shop-brand .LogoBoxBody table {
  width: auto;
  height: auto;
}

.shop-brand .PageLogo {
  width: 230px;
  max-width: 100%;
  height: 90px;
  background-size: contain;
}

.shop-banner {
  min-width: 0;
  display: flex;
  justify-content: flex-end;
}

.shop-banner .BannerBox,
.shop-banner .PageBanner {
  width: 100%;
  max-width: 595px;
  height: 90px;
  background-size: contain;
  background-position: center right;
}

.shop-nav-toggle,
.shop-aside-toggle {
  display: none;
  width: 42px;
  height: 42px;
  min-height: 42px;
  padding: 0 !important;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: var(--shop-brand);
}

.shop-nav-toggle {
  flex-direction: column;
  gap: 4px;
  background: linear-gradient(180deg, #f7fbff 0%, #d7e7f4 100%) !important;
}

.shop-nav-toggle span {
  display: block;
  flex: 0 0 auto;
  width: 18px;
  height: 2px;
  margin: 0;
  background: currentColor;
  border-radius: 2px;
}

.shop-header-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 12px 6px;
  border-top: 0;
  margin-top: 2px;
  background: #eef5fb;
  border-radius: 0 0 calc(var(--shop-radius) - 1px) calc(var(--shop-radius) - 1px);
}

.shop-menu {
  flex: 1 1 auto;
  min-width: 0;
}

.MenuBox,
.MenuBoxBody {
  width: auto;
  height: auto;
  padding: 0;
}

.MenuBoxBody ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.MenuBoxBody li {
  display: block;
  padding: 0;
  border: 0;
}

.MenuBoxBody li a {
  display: inline-block;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  color: var(--shop-brand);
  background: transparent;
}

.MenuBoxBody li a:hover {
  background: var(--shop-brand-soft);
  color: var(--shop-accent);
}

.shop-search {
  flex: 0 1 260px;
}

.SearchBox {
  width: 100%;
  height: auto;
}

.SearchBoxBody table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

body.shop-modern .SearchBoxBody td:last-child {
  padding-left: 0.65rem;
}

.SearchInput {
  width: 100% !important;
  min-width: 0;
}

body.shop-modern .SearchInput,
body.shop-modern input.SearchInput {
  height: 34px !important;
  min-height: 34px !important;
}

body.shop-modern button.SearchSubmit,
body.shop-modern .SearchSubmit {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 36px !important;
  min-width: 36px;
  height: 34px !important;
  min-height: 34px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 8px;
  background: var(--shop-brand) !important;
  background-image: none !important;
  box-shadow: none;
  color: #fff !important;
  font-size: 0 !important;
  line-height: 0 !important;
}

body.shop-modern button.SearchSubmit .SearchSubmitIcon,
body.shop-modern .SearchSubmit .SearchSubmitIcon {
  display: block;
  width: 20px;
  height: 20px;
  color: #fff;
  stroke: #fff;
  pointer-events: none;
  flex-shrink: 0;
}

body.shop-modern button.SearchSubmit:hover,
body.shop-modern .SearchSubmit:hover {
  background: #1363ad !important;
  background-image: none !important;
  color: #fff !important;
}

body.shop-modern button.BasketShowButton,
body.shop-modern .BasketShowButton {
  width: 36px !important;
  min-width: 36px;
  height: 34px !important;
  min-height: 34px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 8px;
  background-color: var(--shop-brand) !important;
  background-image: url(Images/Shop/ShowBasket.png) !important;
  background-size: 18px 18px !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  box-shadow: none;
  color: transparent;
  font-size: 0 !important;
}

body.shop-modern button.BasketShowButton:hover,
body.shop-modern .BasketShowButton:hover {
  background-color: #1363ad !important;
  background-image: url(Images/Shop/ShowBasket.png) !important;
  background-size: 18px 18px !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
}

/* Sidebar / catalog tree */
body.shop-modern #Directory .DirectoryBox {
  background: transparent;
}

body.shop-modern #Directory .DirectoryBoxBody {
  max-height: calc(100vh - 180px);
  overflow: auto;
  padding: 0;
  scrollbar-width: thin;
}

/* drop legacy tree lines / +− / square markers */
body.shop-modern #Directory [class*="TreeSlim"],
body.shop-modern #Directory td:has(> [class*="TreeSlim"]) {
  display: none !important;
  width: 0 !important;
  min-width: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  border: 0 !important;
  background: none !important;
}

body.shop-modern #Directory .DirectoryBoxMinWidth {
  display: none !important;
}

body.shop-modern #Directory [class^="TreeNode-"] {
  margin: 0.1rem 0;
  background: none !important;
  background-image: none !important;
}

body.shop-modern #Directory [class^="TreeNode-"] * {
  font-style: normal !important;
}

/* open branch groups: soft fill only, no outline */
body.shop-modern #Directory [id^="SHT_B_"]:not(#SHT_B_1) {
  margin: 0.05rem 0 0.35rem;
  padding: 0.15rem 0.15rem 0.2rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.45);
  box-shadow: none;
  border: 0;
}

body.shop-modern #Directory [id^="SHT_B_"]:not(#SHT_B_1) [id^="SHT_B_"] {
  background: rgba(255, 255, 255, 0.55);
  box-shadow: none;
  border: 0;
}

body.shop-modern #Directory .TreeNode-0 { padding-left: 0; }
body.shop-modern #Directory .TreeNode-1 { padding-left: 0.1rem; }
body.shop-modern #Directory .TreeNode-2 { padding-left: 0.35rem; }
body.shop-modern #Directory .TreeNode-3 { padding-left: 0.55rem; }
body.shop-modern #Directory .TreeNode-4 { padding-left: 0.75rem; }
body.shop-modern #Directory .TreeNode-5 { padding-left: 0.95rem; }
body.shop-modern #Directory .TreeNode-6 { padding-left: 1.15rem; }

body.shop-modern #Directory table.TreeNode {
  width: 100% !important;
  height: auto !important;
  min-height: 0;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 8px;
  border-left: 3px solid transparent;
  box-sizing: border-box;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease;
}

body.shop-modern #Directory [class^="TreeNode-"],
body.shop-modern #Directory [class^="TreeNode-"] td {
  cursor: pointer;
}

/* level backgrounds (darker → lighter with depth); !important beats JS inline hover/transparent */
body.shop-modern #Directory .TreeNode-0 > table.TreeNode {
  background: #bfd4ea !important;
  border-left-color: #7a9ab8;
}
body.shop-modern #Directory .TreeNode-0 > table.TreeNode:hover {
  background: #aec8e2 !important;
}
body.shop-modern #Directory .TreeNode-1 > table.TreeNode {
  background: #d0e1f2 !important;
  border-left-color: #9bb6d4;
}
body.shop-modern #Directory .TreeNode-1 > table.TreeNode:hover {
  background: #bfd6ec !important;
}
body.shop-modern #Directory .TreeNode-2 > table.TreeNode {
  background: #e0ecf7 !important;
  border-left-color: #b7cce0;
}
body.shop-modern #Directory .TreeNode-2 > table.TreeNode:hover {
  background: #d0e2f2 !important;
}
body.shop-modern #Directory .TreeNode-3 > table.TreeNode {
  background: #eef5fb !important;
  border-left-color: #d0deed;
}
body.shop-modern #Directory .TreeNode-3 > table.TreeNode:hover {
  background: #e0ecf6 !important;
}
body.shop-modern #Directory .TreeNode-4 > table.TreeNode {
  background: #f5f9fd !important;
  border-left-color: #dde8f3;
}
body.shop-modern #Directory .TreeNode-4 > table.TreeNode:hover {
  background: #e8f1f9 !important;
}
body.shop-modern #Directory .TreeNode-5 > table.TreeNode,
body.shop-modern #Directory .TreeNode-6 > table.TreeNode {
  background: #fafcfe !important;
  border-left-color: #e8eef5;
}
body.shop-modern #Directory .TreeNode-5 > table.TreeNode:hover,
body.shop-modern #Directory .TreeNode-6 > table.TreeNode:hover {
  background: #eef5fb !important;
}

body.shop-modern #Directory table.TreeNode tr,
body.shop-modern #Directory table.TreeNode td {
  white-space: normal !important;
  height: auto !important;
  vertical-align: middle;
}

body.shop-modern #Directory table.TreeNode td {
  padding: 0.38rem 0.55rem 0.38rem 0.5rem !important;
  line-height: 1.3;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 500;
  color: var(--shop-ink);
  word-break: break-word;
  overflow-wrap: anywhere;
  hyphens: auto;
}

body.shop-modern #Directory .TreeNode-0 table.TreeNode td {
  font-weight: 700;
  font-size: var(--shop-fs-sm);
  color: var(--shop-brand);
  letter-spacing: 0.01em;
}

/* open branch parents: weight only, no extra outline */
body.shop-modern #Directory [class^="TreeNode-"]:has([class*="JoinMinus"]) > table.TreeNode td {
  font-weight: 650;
  color: var(--shop-brand);
}

body.shop-modern #Directory [class^="TreeNode-"]:has([class*="JoinMinus"]) > table.TreeNode {
  box-shadow: none;
}

/* selected category — same warm wash as Oddělení box */
body.shop-modern #Directory table.TreeNode[style*="224, 224, 224"],
body.shop-modern #Directory table.TreeNode[style*="215, 235, 248"],
body.shop-modern #Directory table.TreeNode[style*="E0E0E0" i],
body.shop-modern #Directory table.TreeNode[style*="d7ebf8" i] {
  background: linear-gradient(180deg, #fff7ea 0%, #ffe8c4 100%) !important;
  border-left-color: #e0b86a !important;
  box-shadow: none;
}

body.shop-modern #Directory table.TreeNode[style*="224, 224, 224"] td,
body.shop-modern #Directory table.TreeNode[style*="215, 235, 248"] td,
body.shop-modern #Directory table.TreeNode[style*="E0E0E0" i] td,
body.shop-modern #Directory table.TreeNode[style*="d7ebf8" i] td {
  font-weight: 700 !important;
  color: #7a3f0c !important;
}

body.shop-modern #Directory .TreeNodeProgress {
  margin: 0.2rem 0.5rem;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--shop-brand-soft), var(--shop-brand), var(--shop-brand-soft));
  background-size: 200% 100%;
  opacity: 0.7;
}

/* Customer / login / basket */
#User {
  overflow: hidden; /* keep panel border-radius clipping */
}

#User .panel-body {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.LanguageSelectorBoxBody {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0;
  padding: 0 0 0.15rem;
  font-size: var(--shop-fs-sm);
  color: var(--shop-muted);
}

.LanguageSelectorBoxBody table {
  width: 100%;
}

.LanguageSelectorBoxBodyFlagHolder {
  width: 28px;
  height: 20px;
  margin: 0;
  border: 0;
  border-radius: 4px;
  overflow: hidden;
  background: #e8f2fa;
  box-shadow: 0 0 0 1px rgba(13, 79, 139, 0.08);
}

.LanguageSelectorBoxBodyFlag {
  width: 28px !important;
  height: 20px !important;
  background-size: cover;
  background-position: center;
  cursor: pointer;
}

.LoginBox,
.BasketBox {
  background: #f3f8fc;
  border: 0;
  border-radius: 10px;
  padding: var(--shop-inset-pad);
  box-shadow: none;
  box-sizing: border-box;
}

/* Admin: start/stop e-shop */
body.shop-modern .ShopStartStopBox,
body.shop-modern .ShopStartStopBoxBody {
  width: 100%;
  text-align: stretch;
}

body.shop-modern .ShopStartStopBoxLabel {
  display: none;
}

body.shop-modern .ShopStartStopBoxBody button,
body.shop-modern button.shop-start-stop {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 0.85rem !important;
  border: 0 !important;
  border-radius: 8px !important;
  background-image: none !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 650;
  white-space: normal !important;
  line-height: 1.2;
  box-shadow: none !important;
  box-sizing: border-box;
  cursor: pointer;
}

body.shop-modern button.shop-start-stop--stop,
body.shop-modern .ShopStartStopBoxBody button {
  background: var(--shop-accent) !important;
  color: #fff !important;
}

body.shop-modern button.shop-start-stop--stop:hover,
body.shop-modern .ShopStartStopBoxBody button:hover {
  background: var(--shop-accent-hot) !important;
  color: #fff !important;
}

body.shop-modern button.shop-start-stop--start {
  background: var(--shop-ok) !important;
  color: #fff !important;
}

body.shop-modern button.shop-start-stop--start:hover {
  background: #186338 !important;
  color: #fff !important;
}

#User .LoginBoxLabel {
  display: none;
}

.BasketBoxLabel {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--shop-brand);
  border-bottom: 0;
  margin: 0 0 0.65rem;
  padding: 0;
}

.BasketBoxLabel a {
  color: var(--shop-brand);
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
}

.LoginBoxBody,
.BasketBoxBody {
  text-align: left !important;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  width: 100%;
  margin: 0;
}

.login-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  width: 100%;
}

.login-field .LoginLabel {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 600;
  color: var(--shop-ink);
  text-align: left;
}

body.shop-modern .login-field input#LoginName,
body.shop-modern .login-field input#LoginPass,
body.shop-modern .login-form input#LoginName,
body.shop-modern .login-form input#LoginPass {
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  box-sizing: border-box;
  height: 38px !important;
  min-height: 38px !important;
  max-height: 38px;
  padding: 0 0.75rem !important;
  border: 1px solid #9bb4c8;
  border-radius: 8px;
  background: #fff;
  font-size: var(--shop-fs);
  line-height: 38px;
}

body.shop-modern .login-form input.ReadOnlyInput {
  width: 100% !important;
  background: #e8eef4;
  color: var(--shop-muted);
}

.login-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

body.shop-modern .login-form .LoginSubmit,
body.shop-modern .login-form .btn-login,
body.shop-modern .login-form .btn-login-secondary,
body.shop-modern .login-form #LoginRegistration {
  width: 100%;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0;
  padding: 0 0.85rem !important;
  border-radius: 8px;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  cursor: pointer;
  background-image: none !important;
  box-shadow: none;
}

body.shop-modern .login-form .LoginSubmit,
body.shop-modern .login-form .btn-login {
  color: #fff;
  border: 1px solid transparent;
  background: #0d4f8b !important;
  box-shadow: 0 1px 2px rgba(13, 55, 95, 0.18);
}

body.shop-modern .login-form .LoginSubmit:hover,
body.shop-modern .login-form .btn-login:hover {
  background: #1363ad !important;
}

body.shop-modern .login-form .btn-login-secondary,
body.shop-modern .login-form #LoginRegistration {
  color: var(--shop-brand);
  border: 1px solid #9bb4c8;
  background: #fff !important;
}

body.shop-modern .login-form .btn-login-secondary:hover,
body.shop-modern .login-form #LoginRegistration:hover {
  border-color: var(--shop-brand);
  background: #f3f8fc !important;
}

.basket-summary {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.basket-summary-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.BasketBoxBodyLabel {
  color: var(--shop-muted);
  font-weight: 600;
  font-size: var(--shop-fs-sm);
}

.basket-summary-value {
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 700;
  color: var(--shop-ink);
  text-align: right;
}

/* Content title */
.ContentTitleBoxBody h1 {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-lg);
  font-weight: 700;
  text-align: left;
  margin: 0 0 0.85rem;
  padding: 0.55rem 0.65rem;
  border-bottom: 0;
  border-radius: 8px;
  background: #eef5fb;
}

/* Path / category chrome — one outer frame only */
body.shop-modern .DepartmentBox {
  width: 100%;
  background: linear-gradient(180deg, #fff7ea 0%, #ffe8c4 100%) !important;
  border: 0 !important;
  border-radius: 10px !important;
  overflow: hidden;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 0.75rem;
}

body.shop-modern .DepartmentBox .PathBox,
body.shop-modern .DepartmentBox .NodesBox {
  background: transparent !important;
  background-image: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.shop-modern .DepartmentBox .PathBox {
  padding: 0.55rem 0.75rem 0.35rem !important;
}

body.shop-modern .DepartmentBox .NodesBox {
  padding: 0.15rem 0.55rem 0 !important;
}

body.shop-modern .DepartmentBox .MaxPathWidth {
  width: 100% !important;
  max-width: 100% !important;
  display: block;
  white-space: normal;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  line-height: 1.35;
}

/* keep path on one line; wrap only when the whole path no longer fits */
body.shop-modern .DepartmentBox .PathBox h2 {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: inherit !important;
  font-weight: inherit;
  line-height: inherit;
  white-space: nowrap;
}

body.shop-modern .DepartmentBox .PathBox a.ListDir {
  white-space: nowrap;
}

body.shop-modern .DepartmentBox .PathBox a,
body.shop-modern .DepartmentBox .NodesBox a {
  color: var(--shop-brand);
}

body.shop-modern .ListDirNodes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11.5rem, 1fr));
  gap: 0.15rem 0.45rem;
  width: 100%;
}

body.shop-modern .ListDirNodes--expanded {
  padding-bottom: 0.7rem;
}

body.shop-modern .ListDirNode {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  padding: 0.2rem 0.35rem;
  border-radius: 6px;
  cursor: pointer;
}

body.shop-modern .ListDirNode:hover {
  background: rgba(255, 255, 255, 0.55);
}

body.shop-modern .ListDirNode .Directory {
  flex: 0 0 auto;
  margin: 0;
}

body.shop-modern .ListDirNode h3,
body.shop-modern .ListDirNode a.ListDir {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 600;
  line-height: 1.25;
  min-width: 0;
}

body.shop-modern .ListDirNode a.ListDir {
  display: inline;
  width: auto !important;
  white-space: normal;
}

body.shop-modern .DepartmentBox .LDTRHUnhiderRow,
body.shop-modern .DepartmentBox #LDTRHUnhiderRow,
body.shop-modern .DepartmentBox .NodesBox #LDTRHUnhiderRow {
  grid-column: 1 / -1;
  display: flex;
  justify-content: stretch;
  align-items: stretch;
  height: auto !important;
  min-height: 40px;
  background: transparent !important;
  background-image: none !important;
  margin: 0.35rem -0.55rem 0;
  padding: 0;
  overflow: visible;
}

body.shop-modern .DepartmentBox .LDTRHUnhider,
body.shop-modern .DepartmentBox button.LDTRHUnhider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  min-width: 0;
  height: auto;
  min-height: 40px;
  margin: 0;
  padding: 0.55rem 0.85rem;
  border: 0;
  border-radius: 0 0 10px 10px;
  background: linear-gradient(180deg, #fff0d6 0%, #ffe8c4 100%) !important;
  background-image: linear-gradient(180deg, #fff0d6 0%, #ffe8c4 100%) !important;
  color: #9a6a28;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  overflow: visible;
  cursor: pointer;
  box-shadow: none;
}

body.shop-modern .DepartmentBox .LDTRHUnhider:hover,
body.shop-modern .DepartmentBox button.LDTRHUnhider:hover {
  background: linear-gradient(180deg, #ffe7c0 0%, #ffdfa8 100%) !important;
  background-image: linear-gradient(180deg, #ffe7c0 0%, #ffdfa8 100%) !important;
  color: #7a5218;
}

body.shop-modern .DepartmentBox .LDTRHUnhider svg {
  display: block;
  flex: 0 0 auto;
}

body.shop-modern .DepartmentBox .LDTRHUnhider span {
  display: inline-block;
}

/* when there is no "show more" strip at all, keep bottom padding on the nodes area */
body.shop-modern .DepartmentBox .NodesBox:not(:has(.LDTRHUnhiderRow)) {
  padding-bottom: 0.7rem !important;
}

/* Product grids & cards */
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: 100%;
}

.product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #f7fbff;
  border: 1px solid var(--shop-line);
  border-radius: var(--shop-radius-sm);
  overflow: hidden;
  box-shadow: var(--shop-shadow-soft);
  transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease, border-color .15s ease;
}

.product-card:hover {
  transform: translateY(-2px);
  background: #eef5fb;
  border-color: #9ec0dc;
  box-shadow: var(--shop-shadow);
}

.product-card-title {
  padding: 0.65rem 0.75rem 0.4rem;
  min-height: 3.2rem;
  background: linear-gradient(180deg, #eaf3fb, #dfeaf5);
  border-bottom: 0;
}

.product-card-title h4,
.product-card-title .ListElement,
.product-card-title a {
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  line-height: 1.3;
  margin: 0;
  color: var(--shop-ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card-body {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  column-gap: 0.75rem;
  row-gap: 0.45rem;
  padding: 0.65rem;
  flex: 1;
  background: #fff;
  align-items: start;
}

.product-card-media {
  width: 88px;
  max-width: 100%;
  flex: 0 0 88px;
}

.product-card-media > a {
  display: block;
  width: 88px;
  height: 66px;
  line-height: 0;
  overflow: hidden;
  border-radius: 6px;
}

/* empty decomposition placeholder from legacy markup */
.product-card-media > div[style*="height: 17px"],
.product-card-media > div[style*="height:17px"] {
  display: none !important;
}

.product-card-media img,
.product-card-media .ShopImagSpeed,
.product-card-media div.ShopImagSpeed {
  display: block !important;
  box-sizing: border-box;
  width: 88px !important;
  height: 66px !important;
  min-width: 88px;
  min-height: 66px;
  max-width: 88px;
  max-height: 66px;
  object-fit: contain;
  border: 0;
  border-radius: 6px;
  background-color: #eef4f9;
  background-repeat: no-repeat !important;
  background-position: center center !important;
  background-size: contain !important;
  overflow: hidden;
}

.product-card-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.product-card-meta .ArticleCaption {
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

body.shop-modern .product-card-code,
body.shop-modern .product-table-code,
body.shop-modern .product-card-code.Small {
  font-size: var(--shop-fs-xs) !important;
  font-weight: 700;
  line-height: 1.25;
  color: var(--shop-muted);
}

body.shop-modern .product-card-body > .product-card-code {
  grid-column: 1 / -1;
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.product-card-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.55rem 0.65rem 0.7rem;
  margin-top: auto;
  background: #eef5fb;
}

.product-card-footer > div:first-child {
  flex: 0 0 auto;
  min-width: 0;
}

.product-card-footer .Small,
.product-card-avail {
  font-size: var(--shop-fs-xs);
  color: var(--shop-ok);
}

.product-card-price {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  line-height: 1.2;
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
}

.product-card-price .ShopPrice,
.product-card-price span.ShopPrice {
  display: inline;
  white-space: nowrap;
  font-size: var(--shop-fs) !important;
  letter-spacing: -0.015em;
  line-height: 1.15;
}

.product-card-price .Pismo {
  white-space: nowrap;
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
}

.product-card-price .ShopPriceNet,
.product-card-price .ShopPriceWithTax {
  display: block;
  white-space: nowrap;
  font-size: var(--shop-fs-xs) !important;
  font-weight: 500 !important;
  color: var(--shop-muted) !important;
  margin-top: 0.12rem;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-card-price .ShopPriceInfluenceOfConfDef {
  display: block;
  font-size: var(--shop-fs-xs);
  line-height: 1.1;
  margin-bottom: 0.1rem;
}

.ShopPrice,
span.ShopPrice {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-lg) !important;
  font-weight: 700;
  color: var(--shop-price) !important;
}

.ShopPriceNet,
.ShopPriceWithTax {
  font-size: var(--shop-fs-xs) !important;
  font-weight: 500 !important;
  color: var(--shop-muted) !important;
}

/* Legacy ShopElementBox cards (fallback for old markup) */
.ShopElementBox {
  background: #f7fbff !important;
  border: 1px solid var(--shop-line) !important;
  border-radius: var(--shop-radius-sm);
  overflow: hidden;
  box-shadow: var(--shop-shadow-soft);
}

body.shop-modern .product-card.ShopElementBox {
  border: 1px solid var(--shop-line) !important;
}

.ShopContentCaption,
.HighlightedShopContentCaption,
.DisabledShopContentCaption {
  background: linear-gradient(180deg, #f8fbff, #eef5fb) !important;
  background-image: none !important;
}

.ShopContentCaptionLeft,
.ShopContentCaptionRight,
.HighlightedShopContentCaptionLeft,
.HighlightedShopContentCaptionRight,
.DisabledShopContentCaptionLeft,
.DisabledShopContentCaptionRight {
  display: none;
}

.ShopElementBody,
.HighlightedShopElementBody,
.DisabledShopElementBody {
  background: #fff;
  border: 0 !important;
}

/* Dense table list */
.shop-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 0;
  border-radius: var(--shop-radius-sm);
  background: #f3f8fc;
  padding: 0.25rem;
  box-sizing: border-box;
}

.shop-table-wrap > table,
.shop-table-wrap .ShopElementBox {
  width: 100%;
  min-width: 420px;
  max-width: none !important;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  table-layout: auto;
}

.shop-table-wrap .ShopContentCaption td {
  background: #eef5fb;
  font-weight: 700;
  font-size: var(--shop-fs-sm);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--shop-muted);
  padding: 0.55rem 0.4rem;
}

.shop-table-wrap .ShopElementBody td,
.shop-table-wrap .HighlightedShopElementBody td,
.shop-table-wrap .DisabledShopElementBody td {
  padding: 0.55rem 0.4rem;
  vertical-align: middle;
  border-top: 1px solid var(--shop-line);
  background: #fff;
}

.shop-table-wrap tr.ShopElementBody:nth-child(even) td,
.shop-table-wrap tr.HighlightedShopElementBody:nth-child(even) td,
.shop-table-wrap tr.DisabledShopElementBody:nth-child(even) td {
  background: #f7fbff;
}

/* Product detail */
.product-detail {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 1px solid var(--shop-line);
  border-radius: var(--shop-radius);
  overflow: hidden;
  background: #f7fbff;
  box-shadow: var(--shop-shadow-soft);
}

.product-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 0.85rem 1rem;
  background: linear-gradient(180deg, #eaf3fb, #dfeaf5);
  border-bottom: 0;
  min-width: 0;
}

.product-detail-head h4,
.product-detail-head h4 span {
  margin: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-lg);
  font-weight: 700;
  line-height: 1.3;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.product-detail-body {
  padding: 1rem;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  background: #fff;
}

/* legacy style.css locks .EditorContent at 628px — that freezes detail width */
body.shop-modern .EditorContent,
body.shop-modern .product-detail .EditorContent {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box;
  overflow-x: auto !important;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.product-detail .EditorContent > div[style*="float"] {
  float: none !important;
  width: min(240px, 100%) !important;
  max-width: 100% !important;
  height: auto !important;
  margin: 0 0 1rem 0 !important;
}

@media (min-width: 760px) {
  .product-detail .EditorContent > div[style*="float"] {
    float: right !important;
    margin: 0 0 1rem 1rem !important;
  }
}

/* wrapper tables around department + detail must shrink with the column */
body.shop-modern #ShopContent .ShopContentBox,
body.shop-modern #ShopContent .ShopContentBoxBody,
body.shop-modern #ShopContent .panel-body {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .ShopContentBoxBody > table,
body.shop-modern #ShopContent .ShopContentBoxBody > table > tbody,
body.shop-modern #ShopContent .ShopContentBoxBody > table > tbody > tr,
body.shop-modern #ShopContent .ShopContentBoxBody > table > tbody > tr > td {
  width: 100% !important;
  max-width: 100%;
  min-width: 0;
}

body.shop-modern #ShopContent .ShopContentBoxBody > table {
  table-layout: fixed;
}

body.shop-modern .product-detail .EditorContent table {
  max-width: 100%;
}

body.shop-modern .product-detail .EditorContent img {
  max-width: 100%;
  height: auto;
}

.product-detail-media {
  position: relative;
  display: block;
  float: right;
  width: min(240px, 100%);
  max-width: 100%;
  margin: 0 0 1rem 1rem;
  clear: right;
  overflow: hidden;
  border-radius: 10px;
}

@media (max-width: 759px) {
  .product-detail-media {
    float: none;
    margin: 0 0 1rem 0;
    width: min(240px, 100%);
  }
}

.product-detail-media > a {
  display: block;
  width: 100%;
  position: relative;
}

.product-detail .ShopImagSlow,
.product-detail img.ShopImagSlow,
.product-detail-media .ShopImagSlow,
.product-detail-media div.ShopImagSlow {
  display: block !important;
  box-sizing: border-box;
  width: 100% !important;
  max-width: 100% !important;
  height: 180px !important;
  min-height: 180px;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border: 0;
  border-radius: 10px;
  background-color: #eef4f9;
  background-repeat: no-repeat !important;
  background-position: center center !important;
  background-size: contain !important;
  cursor: pointer;
}

.product-detail img.ShopImagSlow {
  height: auto !important;
  min-height: 0;
  max-height: 180px;
}

/* multi-image badge over product photo */
body.shop-modern .product-detail-media .ShopMorePictures,
body.shop-modern .product-detail-media button.ShopMorePictures,
body.shop-modern .product-detail-media span.ShopMorePictures {
  position: absolute !important;
  left: auto !important;
  top: auto !important;
  right: 8px !important;
  bottom: 8px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 34px !important;
  height: 34px !important;
  min-width: 34px !important;
  min-height: 34px !important;
  max-width: 34px;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid rgba(13, 55, 95, 0.16) !important;
  border-radius: 9px !important;
  background: rgba(255, 255, 255, 0.94) !important;
  background-image: none !important;
  box-shadow: 0 1px 5px rgba(13, 55, 95, 0.16);
  opacity: 1 !important;
  filter: none !important;
  color: var(--shop-brand) !important;
  font-size: 0 !important;
  line-height: 0 !important;
  cursor: pointer;
  z-index: 2;
  transform: none !important;
}

body.shop-modern .product-detail-media .ShopMorePictures:hover,
body.shop-modern button.ShopMorePictures:hover {
  background: #fff !important;
  border-color: var(--shop-brand) !important;
  color: var(--shop-brand) !important;
}

body.shop-modern .ShopMorePictures--static {
  pointer-events: none;
  cursor: default;
  opacity: 0.8 !important;
}

/* print action in product detail header */
body.shop-modern .ShopPrintElement,
body.shop-modern button.ShopPrintElement {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 38px !important;
  min-width: 38px !important;
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid #9bb4c8 !important;
  border-radius: 8px !important;
  background: #fff !important;
  background-image: none !important;
  color: var(--shop-brand) !important;
  box-shadow: none !important;
  cursor: pointer;
}

body.shop-modern .ShopPrintElement:hover,
body.shop-modern button.ShopPrintElement:hover {
  border-color: var(--shop-brand) !important;
  background: #f3f8fc !important;
  color: var(--shop-brand) !important;
}

body.shop-modern .ShopActionIcon {
  display: block;
  width: 18px;
  height: 18px;
  color: inherit;
  pointer-events: none;
}

.product-detail-extras,
.product-detail-accessories {
  margin-top: 1rem;
  width: 100%;
}

body.shop-modern .product-detail-extras .shop-appendix-list {
  width: 100%;
  max-width: 100%;
  table-layout: auto;
}

body.shop-modern .product-detail-extras .shop-appendix-list td > div[style*="width: 190px"],
body.shop-modern .product-detail-extras .shop-appendix-list span[style*="width: 190px"] {
  width: auto !important;
  max-width: 100%;
  overflow: hidden;
}

@media (max-width: 820px) {
  body.shop-modern .product-detail-extras .shop-appendix-list,
  body.shop-modern .product-detail-extras .shop-appendix-list > tbody {
    display: block;
    width: 100%;
  }

  body.shop-modern .product-detail-extras .shop-appendix-list tr {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 0.45rem;
    row-gap: 0.55rem;
    width: 100%;
    margin: 0 0 0.55rem;
    align-items: center;
  }

  body.shop-modern .product-detail-extras .shop-appendix-list td {
    display: block;
    width: auto !important;
    max-width: 100%;
    padding: 0;
    white-space: normal !important;
  }

  body.shop-modern .product-detail-extras .shop-appendix-list td:empty,
  body.shop-modern .product-detail-extras .shop-appendix-list td > div[style*="width: 15px"],
  body.shop-modern .product-detail-extras .shop-appendix-list td > div[style*="width: 190px"]:empty {
    display: none;
  }
}

.product-detail-accessories {
  overflow-x: auto;
}

.product-detail-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: end;
  gap: 12px;
  margin-top: 1rem;
  padding: 0.85rem 0.75rem;
  border-top: 0;
  border-radius: 10px;
  background: #eef5fb;
}

.product-detail-actions > div:first-child {
  justify-self: start;
}

.product-detail-actions .product-card-code {
  justify-self: center;
  text-align: center;
  white-space: nowrap;
}

.product-detail-actions .product-card-price {
  justify-self: end;
  text-align: right;
}

/* Print popup — same product-detail look as on-page detail */
body.shop-modern.PrintElement {
  margin: 0;
  padding: 0;
  background: var(--shop-bg);
  min-height: 100vh;
}

body.shop-modern.PrintElement .shop-print-shell {
  width: min(920px, 100%);
  max-width: 100%;
  margin: 0 auto;
  padding: 1rem 1rem 1.5rem;
  box-sizing: border-box;
}

body.shop-modern.PrintElement .product-detail,
body.shop-modern.PrintElement .product-detail--print {
  margin: 0 auto !important;
  width: 100%;
  max-width: 100%;
}

body.shop-modern.PrintElement .product-detail .EditorContent,
body.shop-modern .product-detail--print .EditorContent {
  overflow: visible !important;
  overflow-x: visible !important;
}

body.shop-modern.PrintElement .product-detail-media,
body.shop-modern .product-detail--print .product-detail-media {
  float: right !important;
  display: block !important;
  clear: right;
  width: 240px !important;
  max-width: 42% !important;
  margin: 0 0 1rem 1.1rem !important;
  position: relative;
}

body.shop-modern.PrintElement .product-detail .ShopImagSlow,
body.shop-modern.PrintElement .product-detail img.ShopImagSlow,
body.shop-modern.PrintElement .product-detail-media .ShopImagSlow,
body.shop-modern .product-detail--print .ShopImagSlow,
body.shop-modern .product-detail--print img.ShopImagSlow {
  width: 100% !important;
  max-width: 240px !important;
  height: 180px !important;
  min-height: 180px;
}

body.shop-modern.PrintElement .product-detail-media .ShopMorePictures,
body.shop-modern .product-detail--print .ShopMorePictures {
  display: none !important;
}

body.shop-modern.PrintElement .product-detail .EditorContent::after,
body.shop-modern .product-detail--print .EditorContent::after {
  content: "";
  display: table;
  clear: both;
}

body.shop-modern.PrintElement .shop-print-nacionale {
  margin-top: 0.85rem;
  text-align: center;
  color: var(--shop-muted);
  font-size: var(--shop-fs-xs);
  font-weight: 400;
}

body.shop-modern.PrintElement .shop-print-nacionale table,
body.shop-modern.PrintElement .shop-print-nacionale .ShopNacionaleBoxBody {
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 auto;
}

body.shop-modern.PrintElement .shop-print-nacionale h5,
body.shop-modern.PrintElement .shop-print-nacionale a {
  font-size: 0.78rem !important;
  font-weight: 400 !important;
  white-space: normal !important;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media print {
  body.shop-modern.PrintElement {
    background: #fff !important;
  }

  body.shop-modern.PrintElement .shop-print-shell {
    width: 100%;
    max-width: none;
    padding: 0;
  }

  body.shop-modern.PrintElement .product-detail,
  body.shop-modern.PrintElement .product-detail--print {
    box-shadow: none !important;
    border-color: #ccc !important;
  }

  body.shop-modern.PrintElement .ShopPrintElement {
    display: none !important;
  }
}

/* Modern add-to-basket control */
body.shop-modern .basket-add {
  display: inline-flex;
  align-items: stretch;
  gap: 0.45rem;
  max-width: 100%;
  vertical-align: middle;
}

body.shop-modern .basket-add .BasketInput,
body.shop-modern input.BasketInput {
  width: 3.1rem !important;
  min-width: 3.1rem;
  max-width: 4.5rem;
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 0.4rem !important;
  border: 1px solid var(--shop-line) !important;
  border-radius: 8px !important;
  background: #fff !important;
  background-image: none !important;
  box-shadow: none !important;
  text-align: center;
  font-family: var(--shop-display);
  font-size: var(--shop-fs) !important;
  font-weight: 650;
  color: var(--shop-ink);
  box-sizing: border-box;
}

body.shop-modern .basket-add .BasketInput:focus {
  outline: 2px solid rgba(13, 79, 139, 0.25);
  border-color: var(--shop-brand) !important;
}

body.shop-modern button.AddToBasket,
body.shop-modern .basket-add .AddToBasket {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: auto !important;
  min-width: 0;
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 0.85rem !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: var(--shop-brand) !important;
  background-image: none !important;
  color: #fff !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: none;
  cursor: pointer;
}

body.shop-modern button.AddToBasket:hover:not(:disabled),
body.shop-modern .basket-add .AddToBasket:hover:not(:disabled) {
  background: #1363ad !important;
  color: #fff !important;
}

body.shop-modern button.AddToBasket:disabled,
body.shop-modern .basket-add--disabled .AddToBasket {
  opacity: 0.55;
  cursor: default;
  background: #8aa8c2 !important;
}

body.shop-modern .AddToBasketIcon {
  display: block;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  color: #fff;
}

/* product cards + dense table + detail: icon-only add button */
body.shop-modern .product-card-footer .basket-add .AddToBasket span,
body.shop-modern .product-table .basket-add .AddToBasket span,
body.shop-modern .product-detail-actions .basket-add .AddToBasket span {
  display: none !important;
}

body.shop-modern .product-card-footer .basket-add .AddToBasket,
body.shop-modern .product-table .basket-add .AddToBasket,
body.shop-modern .product-detail-actions .basket-add .AddToBasket {
  width: 38px !important;
  min-width: 38px !important;
  max-width: 38px !important;
  padding: 0 !important;
  gap: 0 !important;
  overflow: hidden;
}

body.shop-modern button.basket-configure,
body.shop-modern .ShopListActionButton.basket-configure {
  height: 38px !important;
  min-height: 38px !important;
  padding: 0 0.85rem !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: var(--shop-brand) !important;
  background-image: none !important;
  color: #fff !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 650;
}

/* basket row: update qty / remove item */
body.shop-modern .basket-row-actions {
  justify-content: center;
}

body.shop-modern button.UpdateBasket,
body.shop-modern button.RemoveFromBasket,
body.shop-modern .UpdateBasket,
body.shop-modern .RemoveFromBasket {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 38px !important;
  min-width: 38px !important;
  max-width: 38px;
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 8px !important;
  background-image: none !important;
  box-shadow: none !important;
  cursor: pointer;
  color: #fff !important;
}

body.shop-modern button.UpdateBasket,
body.shop-modern .UpdateBasket {
  background: var(--shop-brand) !important;
}

body.shop-modern button.UpdateBasket:hover,
body.shop-modern .UpdateBasket:hover {
  background: #1363ad !important;
}

body.shop-modern button.RemoveFromBasket,
body.shop-modern .RemoveFromBasket {
  background: var(--shop-accent) !important;
}

body.shop-modern button.RemoveFromBasket:hover,
body.shop-modern .RemoveFromBasket:hover {
  background: var(--shop-accent-hot) !important;
}

body.shop-modern .BasketActionIcon {
  display: block;
  width: 22px;
  height: 22px;
  color: inherit;
}

/* Override fixed widths inside shop content */
#ShopContent [style*="width: 631px"],
#ShopContent [style*="width: 629px"],
#ShopContent [style*="width: 623px"],
#ShopContent [style*="width: 639px"],
#ShopContent [style*="width: 595px"],
#ShopContent [style*="width: 416px"],
#ShopContent [style*="width: 206px"],
.ShopNacionaleBoxBody {
  width: 100% !important;
  max-width: 100% !important;
}

/* Info documents list */
body.shop-modern #ShopContent .shop-infodoc-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  width: 100%;
  max-width: 40rem;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-infodoc-list-head h3 {
  margin: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-lg);
  font-weight: 700;
  color: var(--shop-brand);
  line-height: 1.3;
}

body.shop-modern #ShopContent .shop-infodoc-items {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

body.shop-modern #ShopContent .shop-infodoc-item {
  display: flex !important;
  align-items: center;
  gap: 0.7rem;
  width: 100% !important;
  min-height: 2.75rem;
  margin: 0 !important;
  padding: 0.65rem 0.85rem !important;
  border: 1px solid var(--shop-line) !important;
  border-radius: 10px !important;
  background: #fff !important;
  background-image: none !important;
  color: var(--shop-ink) !important;
  text-align: left;
  box-shadow: none !important;
  cursor: pointer;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-infodoc-item:hover {
  border-color: var(--shop-brand) !important;
  background: #f3f8fc !important;
}

body.shop-modern #ShopContent .shop-infodoc-item-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  background: #e8f3fc;
  color: var(--shop-brand);
}

body.shop-modern #ShopContent .shop-infodoc-icon {
  display: block;
  width: 20px;
  height: 20px;
}

body.shop-modern #ShopContent .shop-infodoc-item-label {
  flex: 1 1 auto;
  min-width: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  line-height: 1.3;
}

/* Users list */
body.shop-modern #ShopContent .shop-user-list {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-user-list-head,
body.shop-modern #ShopContent .shop-user-item {
  display: grid;
  grid-template-columns: 1.5rem minmax(0, 1.1fr) minmax(0, 1.3fr) 5.5rem 3rem 3.2rem 5.6rem;
  align-items: center;
  column-gap: 0.5rem;
  width: 100%;
  min-width: 40rem;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-user-list-head {
  padding: 0.3rem 0.55rem;
  background: #eef5fb;
  border-radius: var(--shop-radius-sm);
  font-weight: 700;
  font-size: var(--shop-fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--shop-muted);
}

body.shop-modern #ShopContent .shop-user-item {
  padding: 0.25rem 0.55rem;
  min-height: 2.1rem;
  background: #fff;
  border: 1px solid var(--shop-line);
  border-radius: var(--shop-radius-sm);
}

body.shop-modern #ShopContent .shop-user-section {
  height: 0.45rem;
}

body.shop-modern #ShopContent .shop-user-active {
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  justify-self: center;
}

body.shop-modern #ShopContent .shop-user-active.is-on {
  background: var(--shop-ok);
}

body.shop-modern #ShopContent .shop-user-active.is-off {
  background: #c5d0da;
}

body.shop-modern #ShopContent .shop-user-name,
body.shop-modern #ShopContent .shop-user-mail {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: var(--shop-fs-sm);
}

body.shop-modern #ShopContent .shop-user-name {
  font-weight: 650;
}

body.shop-modern #ShopContent .shop-user-role,
body.shop-modern #ShopContent .shop-user-lang,
body.shop-modern #ShopContent .shop-user-currency {
  white-space: nowrap;
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
  overflow: hidden;
  text-overflow: ellipsis;
}

body.shop-modern #ShopContent .shop-user-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.25rem;
}

body.shop-modern #ShopContent .shop-user-action {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 7px !important;
  background-image: none !important;
  box-shadow: none !important;
  color: #fff !important;
  cursor: pointer;
}

body.shop-modern #ShopContent .shop-user-action .BasketActionIcon {
  display: block;
  width: 15px;
  height: 15px;
  color: inherit;
  pointer-events: none;
}

body.shop-modern #ShopContent .shop-user-action--switch {
  background: #0d4f8b !important;
}

body.shop-modern #ShopContent .shop-user-action--switch:hover {
  background: #1363ad !important;
}

body.shop-modern #ShopContent .shop-user-action--edit {
  background: #3d6f95 !important;
}

body.shop-modern #ShopContent .shop-user-action--edit:hover {
  background: #2f5a7a !important;
}

body.shop-modern #ShopContent .shop-user-action--kill {
  background: #c62828 !important;
}

body.shop-modern #ShopContent .shop-user-action--kill:hover {
  background: #a31f1f !important;
}

body.shop-modern #ShopContent .shop-user-action--disabled {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
  background: #9bb4c8 !important;
}

body.shop-modern #ShopContent .shop-user-list-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.65rem;
}

body.shop-modern #ShopContent .shop-user-list-footer .FormButton {
  min-width: 8.5rem;
}

/* Orders index list (basket-like cards) */
body.shop-modern #ShopContent .shop-order-index {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}


body.shop-modern #ShopContent .shop-order-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  width: 100%;
}

body.shop-modern #ShopContent .shop-order-filters .FormButton,
body.shop-modern #ShopContent .shop-order-filters button.FormButton {
  min-width: 0;
  width: auto !important;
  height: 36px !important;
  min-height: 36px !important;
  padding: 0 0.85rem !important;
}

body.shop-modern #ShopContent .shop-order-filters .ButtonHighlight,
body.shop-modern #ShopContent .shop-order-filters button.ButtonHighlight {
  color: #fff !important;
  border-color: transparent !important;
  background: #0d4f8b !important;
}

body.shop-modern #ShopContent .shop-order-list {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

body.shop-modern #ShopContent .shop-order-list-head,
body.shop-modern #ShopContent .shop-order-item {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) 7.1rem 7.1rem 2rem;
  align-items: center;
  column-gap: 0.55rem;
  width: 100%;
  min-width: 28rem;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-list--owner .shop-order-list-head,
body.shop-modern #ShopContent .shop-order-item--owner {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.85fr) 7.1rem 7.1rem 2rem;
  min-width: 34rem;
}

body.shop-modern #ShopContent .shop-order-list-head {
  padding: 0.3rem 0.55rem;
  background: #eef5fb;
  border-radius: var(--shop-radius-sm);
  font-weight: 700;
  font-size: var(--shop-fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--shop-muted);
}

body.shop-modern #ShopContent .shop-order-item {
  padding: 0.25rem 0.55rem;
  min-height: 2.1rem;
  border: 1px solid var(--shop-line);
  border-radius: var(--shop-radius-sm);
}

body.shop-modern #ShopContent .shop-order-item.OpenedOrder {
  background: #ffffff;
}

body.shop-modern #ShopContent .shop-order-item.ClosedOrder {
  background: #ffeedd;
}

body.shop-modern #ShopContent .shop-order-item.ExpededOrder {
  background: #ddeeff;
}

body.shop-modern #ShopContent .shop-order-item.CanceledOrder {
  background: #ffffdd;
}

body.shop-modern #ShopContent .shop-order-item--empty {
  min-height: 2.1rem;
  background: #f7fbff;
}

body.shop-modern #ShopContent .shop-order-name {
  min-width: 0;
  font-weight: 650;
  font-size: var(--shop-fs-sm);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
}

body.shop-modern #ShopContent .shop-order-owner,
body.shop-modern #ShopContent .shop-order-stamp,
body.shop-modern #ShopContent .shop-order-expeded {
  white-space: nowrap;
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
  overflow: hidden;
  text-overflow: ellipsis;
}

body.shop-modern #ShopContent .shop-order-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

body.shop-modern #ShopContent .shop-order-remove {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 7px !important;
  background: #c62828 !important;
  background-image: none !important;
  color: #fff !important;
  box-shadow: none !important;
  cursor: pointer;
}

body.shop-modern #ShopContent .shop-order-remove:hover {
  background: #a31f1f !important;
}

body.shop-modern #ShopContent .shop-order-remove .BasketActionIcon {
  display: block;
  width: 15px;
  height: 15px;
  color: inherit;
  pointer-events: none;
}

body.shop-modern #ShopContent .shop-order-remove--disabled {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
  background: #9bb4c8 !important;
}

body.shop-modern #ShopContent .shop-order-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.85rem;
  margin-top: 0.55rem;
  width: 100%;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: var(--shop-fs-xs);
  color: var(--shop-muted);
  white-space: nowrap;
}

body.shop-modern #ShopContent .shop-order-legend-swatch {
  display: inline-block;
  width: 1rem;
  height: 0.7rem;
  border: 1px solid #9bb4c8;
  border-radius: 3px;
  box-sizing: border-box;
}

/* Select order to add from basket */
body.shop-modern #ShopContent .shop-order-select {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
  max-width: 36rem;
  margin: 0 auto;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-select-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  width: 100%;
}

body.shop-modern #ShopContent .shop-order-select-option {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0;
  padding: 0.7rem 0.85rem;
  background: #f3f8fc;
  border-radius: 10px;
  cursor: pointer;
  box-sizing: border-box;
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
  line-height: 1.35;
}

body.shop-modern #ShopContent .shop-order-select-option:hover {
  background: #e8f1f8;
}

body.shop-modern #ShopContent .shop-order-select-option input.Radio {
  margin: 0.15rem 0 0;
  flex: 0 0 auto;
}

body.shop-modern #ShopContent .shop-order-select-actions {
  justify-content: flex-end;
}

/* Order dispatch / content view */
body.shop-modern #ShopContent .shop-order-view,
body.shop-modern #ShopContent .shop-order-form {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-addresses,
body.shop-modern #ShopContent .shop-order-section,
body.shop-modern #ShopContent .shop-order-remark,
body.shop-modern #ShopContent .shop-order-form .ShopElementBox,
body.shop-modern #ShopContent .shop-order-view .shop-order-form .ShopElementBox {
  width: 100% !important;
  max-width: 100% !important;
  table-layout: fixed;
  box-sizing: border-box;
  border: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
  overflow: visible;
}

body.shop-modern #ShopContent .shop-order-addresses,
body.shop-modern #ShopContent .shop-order-addresses > tbody {
  display: block;
  width: 100%;
}

body.shop-modern #ShopContent .shop-order-addresses {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.35rem 0.85rem;
}

body.shop-modern #ShopContent .shop-order-addresses > tbody,
body.shop-modern #ShopContent .shop-order-addresses-captions,
body.shop-modern #ShopContent .shop-order-addresses-body {
  display: contents;
}

body.shop-modern #ShopContent .shop-order-addresses-captions > td,
body.shop-modern #ShopContent .shop-order-addresses-body > td,
body.shop-modern #ShopContent .shop-order-address-col {
  display: block;
  width: 100% !important;
  max-width: 100%;
  box-sizing: border-box;
  padding: 0.55rem 0.65rem;
}

body.shop-modern #ShopContent .shop-order-addresses-captions > td:first-child {
  order: 1;
}

body.shop-modern #ShopContent .shop-order-addresses-body > td:first-child {
  order: 2;
}

body.shop-modern #ShopContent .shop-order-addresses-captions > td:last-child {
  order: 3;
}

body.shop-modern #ShopContent .shop-order-addresses-body > td:last-child {
  order: 4;
}

body.shop-modern #ShopContent .shop-order-addresses-captions > td.BasketContentCaption {
  background: #e8f1f8 !important;
  padding: 0.55rem 0.8rem !important;
  border: 0;
  border-radius: 10px 10px 0 0;
  margin: 0;
}

body.shop-modern #ShopContent .shop-order-addresses-captions > td.BasketContentCaption:last-child {
  background: #e7f0ea !important;
}

body.shop-modern #ShopContent .shop-order-address-col {
  background: #f3f8fc;
  border: 0;
  border-radius: 0 0 10px 10px;
  margin: 0 0 0.85rem;
  padding: 0.75rem 0.8rem !important;
}

body.shop-modern #ShopContent .shop-order-addresses-body > td.shop-order-address-col:last-child {
  background: #f2f7f3;
}

body.shop-modern #ShopContent .shop-order-section .BasketContentCaption,
body.shop-modern #ShopContent .shop-order-remark .BasketContentCaption {
  background: transparent !important;
  padding: 0.35rem 0 !important;
  border: 0;
  border-bottom: 1px solid #d7e4ef;
}

body.shop-modern #ShopContent .shop-order-section .ShopBody > td,
body.shop-modern #ShopContent .shop-order-remark .ShopBody > td,
body.shop-modern #ShopContent .shop-order-remark-cell {
  background: transparent !important;
  border: 0 !important;
  padding: 0.45rem 0 !important;
}

body.shop-modern #ShopContent .shop-order-options,
body.shop-modern #ShopContent .shop-order-choice {
  width: 100% !important;
  max-width: 100%;
  table-layout: auto;
}

body.shop-modern #ShopContent .shop-order-options td[nowrap],
body.shop-modern #ShopContent .shop-order-choice-price {
  white-space: normal !important;
}

body.shop-modern #ShopContent .shop-order-totals {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  width: 100%;
  max-width: 100%;
  padding: 0.65rem 0 0.2rem;
  background: transparent;
  border: 0;
  border-top: 1px solid #d7e4ef;
  border-radius: 0;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-total-row {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: baseline;
  gap: 0.85rem;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-total-label {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  white-space: nowrap;
  font-size: var(--shop-fs);
  color: var(--shop-ink);
}

body.shop-modern #ShopContent .shop-order-total-value {
  flex: 0 0 auto;
  min-width: 8.5rem;
  text-align: right;
  white-space: nowrap !important;
  font-variant-numeric: tabular-nums;
  font-size: var(--shop-fs);
}

body.shop-modern #ShopContent .shop-order-total-row--pay .shop-order-total-label,
body.shop-modern #ShopContent .shop-order-total-row--pay .shop-order-total-value,
body.shop-modern #ShopContent .shop-order-total-row--pay .ShopPrice {
  font-weight: 700;
  white-space: nowrap !important;
}

body.shop-modern #ShopContent .shop-order-totals table {
  width: auto !important;
  max-width: 100%;
}

body.shop-modern #ShopContent .shop-order-remark-body,
body.shop-modern #ShopContent .shop-order-remark-cell {
  width: 100% !important;
  max-width: 100%;
  box-sizing: border-box;
  overflow: visible !important;
}

body.shop-modern #ShopContent .shop-order-remark-input,
body.shop-modern #ShopContent textarea.shop-order-remark-input {
  display: block;
  width: 100% !important;
  max-width: 100% !important;
  min-height: 5.5rem;
  height: auto !important;
  margin: 0;
  padding: 0.65rem 0.75rem !important;
  border: 1px solid #c5d6e4 !important;
  border-radius: 8px !important;
  background: #fff;
  box-sizing: border-box;
  resize: vertical;
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
}

body.shop-modern #ShopContent .shop-order-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  width: 100%;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-roster-options {
  width: min(100%, 18rem);
  max-width: 100%;
}

body.shop-modern #ShopContent .shop-order-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-order-footer .FormButton,
body.shop-modern #ShopContent .shop-order-footer button.FormButton,
body.shop-modern #ShopContent .shop-order-footer .ListButton {
  width: auto !important;
  min-width: 8.5rem;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0;
  padding: 0 1.15rem !important;
  border-radius: 8px !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  background-image: none !important;
}

body.shop-modern #ShopContent .shop-order-footer div[style*="width: 110px"] {
  width: auto !important;
}

@media (min-width: 1100px) {
  body.shop-modern #ShopContent .shop-order-addresses {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  body.shop-modern #ShopContent .shop-order-addresses-captions > td:first-child {
    order: 1;
  }

  body.shop-modern #ShopContent .shop-order-addresses-captions > td:last-child {
    order: 2;
  }

  body.shop-modern #ShopContent .shop-order-addresses-body > td:first-child {
    order: 3;
  }

  body.shop-modern #ShopContent .shop-order-addresses-body > td:last-child {
    order: 4;
  }

  body.shop-modern #ShopContent .shop-order-address-col {
    margin-bottom: 0;
  }
}

@media (max-width: 520px) {
  body.shop-modern #ShopContent .shop-order-footer {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  body.shop-modern #ShopContent .shop-order-footer .FormButton,
  body.shop-modern #ShopContent .shop-order-footer button.FormButton {
    width: 100% !important;
    min-width: 0;
  }

  body.shop-modern #ShopContent .shop-order-totals {
    align-items: stretch;
  }

  body.shop-modern #ShopContent .shop-order-total-row {
    gap: 0.55rem;
  }

  body.shop-modern #ShopContent .shop-order-total-value {
    min-width: 7rem;
  }
}

#ShopContent [style*="overflow: hidden"] {
  overflow: visible !important;
}

#ShopContent .EditorContent [style*="width: 111px"],
#ShopContent [style*="width: 197px"],
#ShopContent [style*="width: 200px"],
#ShopContent [style*="width: 203px"],
#ShopContent [style*="width: 21em"] {
  width: auto !important;
  max-width: 100% !important;
}

/* Homepage / page articles in EditorContent — responsive images & tables */
body.shop-modern #ShopContent .EditorContent,
body.shop-modern #ShopContent .EditorContent table {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .EditorContent td {
  max-width: 100%;
}

body.shop-modern #ShopContent .EditorContent img {
  display: block;
  max-width: 100% !important;
  width: auto !important;
  height: auto !important;
}

/* Basket / order / offer data tables */
.Pismo.ShopElementBox,
TABLE.ShopElementBox {
  width: 100% !important;
  max-width: 100%;
}

body.shop-modern #ShopContent .shop-table-wrap.shop-data-table,
body.shop-modern #ShopContent .shop-data-table {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-table-wrap > table.shop-data-grid,
body.shop-modern #ShopContent .shop-data-table > table.shop-data-grid,
body.shop-modern #ShopContent .shop-data-table > table.Pismo.ShopElementBox,
body.shop-modern #ShopContent .shop-data-table > table.ShopElementBox {
  width: 100% !important;
  min-width: 420px !important;
  max-width: none !important;
  table-layout: auto !important;
}

body.shop-modern #ShopContent .shop-data-table > table > tbody > tr > td,
body.shop-modern #ShopContent .shop-data-table > table > tr > td {
  vertical-align: middle;
}

/* Keep compact columns from wrapping into neighbors */
body.shop-modern #ShopContent .shop-data-table td[align="center"],
body.shop-modern #ShopContent .shop-data-table td[align="right"],
body.shop-modern #ShopContent .shop-data-table td[nowrap],
body.shop-modern #ShopContent .shop-data-table .BasketContentCaption {
  white-space: nowrap;
}

/* Product name: wrap and grow row height instead of overlapping */
body.shop-modern #ShopContent .shop-data-table td.shop-basket-name-cell,
body.shop-modern #ShopContent .shop-data-table .shop-basket-name-cell {
  width: 50%;
  max-width: 0; /* force wrap within flexible column */
  white-space: normal !important;
  vertical-align: middle;
}

body.shop-modern #ShopContent .shop-basket-name,
body.shop-modern #ShopContent .shop-data-table td > div[style*="overflow"] {
  display: block;
  width: 100% !important;
  max-width: 100%;
  height: auto !important;
  min-height: 1.25em;
  overflow: visible !important;
  white-space: normal !important;
  word-wrap: break-word;
  overflow-wrap: anywhere;
  line-height: 1.35;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-basket-name .ListElement,
body.shop-modern #ShopContent .shop-basket-name a {
  display: inline;
  white-space: normal !important;
  word-wrap: break-word;
  overflow-wrap: anywhere;
}

body.shop-modern #ShopContent .shop-basket-row {
  height: auto !important;
}

/* Basket stacked / responsive list */
body.shop-modern #ShopContent .shop-basket-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-basket-head {
  display: none;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.7rem;
  background: #eef5fb;
  border-radius: var(--shop-radius-sm);
  font-weight: 700;
  font-size: var(--shop-fs-sm);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--shop-muted);
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-basket-item {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 0.55rem 0.85rem;
  align-items: center;
  padding: 0.7rem 0.75rem;
  background: #fff;
  border: 1px solid var(--shop-line);
  border-radius: var(--shop-radius-sm);
  box-sizing: border-box;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-basket-item--empty {
  min-height: 2.5rem;
  background: #f7fbff;
}

body.shop-modern #ShopContent .shop-basket-item-head {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-basket-item-head .shop-basket-name {
  font-weight: 600;
  font-size: var(--shop-fs);
}

body.shop-modern #ShopContent .shop-basket-code {
  font-size: var(--shop-fs-sm);
  color: var(--shop-muted);
  font-family: ui-monospace, "Cascadia Mono", "Segoe UI Mono", Consolas, monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.shop-modern #ShopContent .shop-basket-item-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem 0.85rem;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-basket-unit,
body.shop-modern #ShopContent .shop-basket-total {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

body.shop-modern #ShopContent .shop-basket-total {
  font-weight: 700;
}

body.shop-modern #ShopContent .shop-basket-qty {
  display: flex;
  align-items: center;
  margin-left: 1.35rem;
}

body.shop-modern #ShopContent .shop-basket-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem;
}

body.shop-modern #ShopContent .shop-basket-sum {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0.8rem;
  margin-top: 0.15rem;
  background: #eef5fb;
  border-radius: var(--shop-radius-sm);
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-basket-sum-label {
  font-weight: 700;
}

body.shop-modern #ShopContent .shop-basket-sum-value {
  text-align: right;
  font-weight: 700;
}

body.shop-modern #ShopContent .shop-basket-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.85rem;
  width: 100%;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton {
  width: auto !important;
  min-width: 9.5rem;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0;
  padding: 0 1.15rem !important;
  border-radius: 8px !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  cursor: pointer;
  background-image: none !important;
  box-shadow: none;
  white-space: nowrap;
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton--primary,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--primary {
  color: #fff !important;
  border: 1px solid transparent !important;
  background: #0d4f8b !important;
  box-shadow: 0 1px 2px rgba(13, 55, 95, 0.18);
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton--primary:hover,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--primary:hover {
  background: #1363ad !important;
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton--primary:disabled,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--primary:disabled,
body.shop-modern #ShopContent .shop-basket-footer .FormButton--secondary:disabled,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--secondary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton--secondary,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--secondary {
  color: var(--shop-brand) !important;
  border: 1px solid #9bb4c8 !important;
  background: #fff !important;
}

body.shop-modern #ShopContent .shop-basket-footer .FormButton--secondary:hover,
body.shop-modern #ShopContent .shop-basket-footer button.FormButton--secondary:hover {
  border-color: var(--shop-brand) !important;
  background: #f3f8fc !important;
}

@media (max-width: 520px) {
  body.shop-modern #ShopContent .shop-basket-footer {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  body.shop-modern #ShopContent .shop-basket-footer .FormButton,
  body.shop-modern #ShopContent .shop-basket-footer button.FormButton {
    width: 100% !important;
    min-width: 0;
  }
}

@media (max-width: 820px) {
  body.shop-modern #ShopContent .shop-basket-head {
    display: none !important;
  }

  body.shop-modern #ShopContent .shop-basket-item {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  body.shop-modern #ShopContent .shop-basket-item-head {
    width: 100%;
    padding-bottom: 0.45rem;
    border-bottom: 1px solid var(--shop-line);
  }

  body.shop-modern #ShopContent .shop-basket-item-meta {
    width: 100%;
    justify-content: space-between;
    align-items: center;
  }

  body.shop-modern #ShopContent .shop-basket-unit::before,
  body.shop-modern #ShopContent .shop-basket-total::before {
    content: attr(data-label) ": ";
    font-weight: 600;
    color: var(--shop-muted);
    font-size: var(--shop-fs-sm);
    text-transform: none;
    margin-right: 0.2rem;
  }

  body.shop-modern #ShopContent .shop-basket-actions {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (min-width: 1100px) {
  body.shop-modern #ShopContent .shop-basket-head {
    display: grid;
    grid-template-columns: 5.5rem minmax(0, 1.6fr) 6.5rem 1.75rem 7.5rem 6.5rem auto;
  }

  body.shop-modern #ShopContent .shop-basket-item {
    grid-template-columns: 5.5rem minmax(0, 1.6fr) 6.5rem 1.75rem 7.5rem 6.5rem auto;
    align-items: center;
  }

  body.shop-modern #ShopContent .shop-basket-item-head {
    display: contents;
  }

  body.shop-modern #ShopContent .shop-basket-item-meta {
    display: contents;
  }

  body.shop-modern #ShopContent .shop-basket-code {
    order: 1;
    grid-column: 1;
  }

  body.shop-modern #ShopContent .shop-basket-name {
    order: 2;
    grid-column: 2;
  }

  body.shop-modern #ShopContent .shop-basket-unit {
    order: 3;
    grid-column: 3;
  }

  body.shop-modern #ShopContent .shop-basket-qty {
    order: 4;
    grid-column: 5;
    justify-content: center;
    margin-left: 0;
  }

  body.shop-modern #ShopContent .shop-basket-total {
    order: 5;
    grid-column: 6;
  }

  body.shop-modern #ShopContent .shop-basket-actions {
    order: 6;
    grid-column: 7;
  }

  body.shop-modern #ShopContent .shop-basket-col-unit {
    grid-column: 3;
  }

  body.shop-modern #ShopContent .shop-basket-col-qty {
    grid-column: 5;
  }

  body.shop-modern #ShopContent .shop-basket-col-total {
    grid-column: 6;
  }

  body.shop-modern #ShopContent .shop-basket-col-actions {
    grid-column: 7;
  }
}

.BasketContentCaption {
  background: #eef5fb !important;
  font-weight: 700;
}

/* Forms — change password / registration / address */
body.shop-modern #ShopContent .shop-user-form,
body.shop-modern #ShopContent form.shop-user-form {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-form-intro {
  margin: 0 0 1rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  background: #eef5fb;
  color: var(--shop-ink);
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
  line-height: 1.45;
}

body.shop-modern #ShopContent table.FormBody,
body.shop-modern #ShopContent table.shop-form-grid {
  width: 100% !important;
  max-width: 100% !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
  background: transparent !important;
  color: inherit;
}

body.shop-modern #ShopContent .shop-form-grid > tbody > tr,
body.shop-modern #ShopContent .shop-form-grid > tr {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.22rem;
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 0.65rem;
}

body.shop-modern #ShopContent .shop-form-grid > tbody > tr > td,
body.shop-modern #ShopContent .shop-form-grid > tr > td {
  display: block;
  width: 100% !important;
  max-width: 100%;
  padding: 0;
  vertical-align: top;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-form-grid > tbody > tr > td.FormLabel,
body.shop-modern #ShopContent .shop-form-grid > tr > td.FormLabel,
body.shop-modern #ShopContent td.FormLabel {
  width: 100% !important;
  padding: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  color: var(--shop-ink);
  text-align: left !important;
  white-space: normal;
  line-height: 1.3;
}

body.shop-modern #ShopContent td.FormLabel label {
  cursor: pointer;
}

body.shop-modern #ShopContent td.FormLabel div[style*="width: 90px"] {
  width: auto !important;
}

body.shop-modern #ShopContent .shop-form-field,
body.shop-modern #ShopContent .shop-form-address {
  width: 100% !important;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-form-section {
  padding: 0.85rem 0 0.15rem !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 700;
  color: var(--shop-brand);
  border-top: 1px solid #d7e4ef;
}

body.shop-modern #ShopContent .FormInput,
body.shop-modern #ShopContent .FormSelect,
body.shop-modern #ShopContent .FormTextarea,
body.shop-modern #ShopContent .FormTextareaElementCaption,
body.shop-modern #ShopContent select.FormInput {
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  box-sizing: border-box;
  min-height: 40px;
  height: 40px;
  padding: 0 0.8rem !important;
  border: 1px solid #9bb4c8 !important;
  border-radius: 8px !important;
  background: #fff !important;
  color: var(--shop-ink);
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
  line-height: 1.3;
}

body.shop-modern #ShopContent textarea.FormTextarea,
body.shop-modern #ShopContent textarea.FormTextareaElementCaption {
  height: auto;
  min-height: 100px;
  padding: 0.65rem 0.8rem !important;
  line-height: 1.4;
}

body.shop-modern #ShopContent .FormInput.ReadOnlyInput,
body.shop-modern #ShopContent input.ReadOnlyInput {
  background: #e8eef4 !important;
  color: var(--shop-muted);
}

body.shop-modern #ShopContent .FormInput--narrow,
body.shop-modern #ShopContent .FormInput--zip,
body.shop-modern #ShopContent input.FormInput[style*="4.5em"],
body.shop-modern #ShopContent input.FormInput[style*="Width: 4.5em"] {
  width: 5.5rem !important;
  max-width: 5.5rem !important;
  min-width: 5.5rem;
}

body.shop-modern #ShopContent .shop-form-zipcity {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-form-zipcity-label {
  flex: 0 0 auto;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  color: var(--shop-ink);
  white-space: nowrap;
}

body.shop-modern #ShopContent .FormInput--city,
body.shop-modern #ShopContent .shop-form-zipcity .FormInput--city {
  flex: 1 1 auto;
  width: auto !important;
  min-width: 0 !important;
  max-width: none !important;
}

/* Readonly address values (logged-in order form) */
body.shop-modern #ShopContent .shop-address-readonly > tbody > tr,
body.shop-modern #ShopContent .shop-address-readonly > tr,
body.shop-modern #ShopContent .shop-order-address-col .shop-form-grid > tbody > tr,
body.shop-modern #ShopContent .shop-order-address-col .shop-form-grid > tr {
  margin: 0 0 0.7rem;
  gap: 0.2rem;
}

body.shop-modern #ShopContent .shop-address-readonly .FormInputDiv {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 0 0.8rem;
  border: 1px solid #c5d6e4;
  border-radius: 8px;
  background: #eef3f7;
  color: var(--shop-ink);
  font-family: var(--shop-font);
  font-size: var(--shop-fs);
  line-height: 1.3;
  box-sizing: border-box;
}

body.shop-modern #ShopContent .shop-address-readonly .FormInputDiv--zip {
  flex: 0 0 auto;
  width: 5.5rem;
  min-width: 5.5rem;
  max-width: 5.5rem;
}

body.shop-modern #ShopContent .shop-address-readonly .FormInputDiv--city {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
}

body.shop-modern #ShopContent .shop-form-radios,
body.shop-modern #ShopContent .shop-form-check {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 1rem;
  font-family: var(--shop-font);
  font-size: var(--shop-fs-sm);
  color: var(--shop-ink);
  line-height: 1.35;
}

body.shop-modern #ShopContent .shop-form-check {
  display: inline-flex;
  gap: 0.45rem;
  cursor: pointer;
}

body.shop-modern #ShopContent .shop-form-check input.FormChBX,
body.shop-modern #ShopContent .shop-form-check input.Radio,
body.shop-modern #ShopContent input.FormChBX,
body.shop-modern #ShopContent input.Radio {
  width: 16px !important;
  height: 16px !important;
  min-height: 0 !important;
  margin: 0;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  accent-color: var(--shop-brand);
  cursor: pointer;
}

body.shop-modern #ShopContent .shop-form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  box-sizing: border-box;
  padding-top: 0.85rem;
  margin: 0;
}

body.shop-modern #ShopContent .shop-form-actions > table,
body.shop-modern #ShopContent td > div[style*="width: 100px"] {
  width: auto !important;
  min-width: 0;
}

body.shop-modern #ShopContent button.FormButton,
body.shop-modern #ShopContent .FormButton {
  width: auto !important;
  min-width: 8.25rem;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0;
  padding: 0 1.15rem !important;
  border-radius: 8px !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs);
  font-weight: 650;
  cursor: pointer;
  background-image: none !important;
  box-shadow: none;
  white-space: nowrap;
}

body.shop-modern #ShopContent .FormButton--primary,
body.shop-modern #ShopContent button.FormButton--primary {
  color: #fff !important;
  border: 1px solid transparent !important;
  background: #0d4f8b !important;
  box-shadow: 0 1px 2px rgba(13, 55, 95, 0.18);
}

body.shop-modern #ShopContent .FormButton--primary:hover,
body.shop-modern #ShopContent button.FormButton--primary:hover {
  background: #1363ad !important;
}

body.shop-modern #ShopContent .FormButton--primary:disabled,
body.shop-modern #ShopContent button.FormButton--primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

body.shop-modern #ShopContent .FormButton--secondary,
body.shop-modern #ShopContent button.FormButton--secondary,
body.shop-modern #ShopContent button.FormButton:not(.FormButton--primary) {
  color: var(--shop-brand) !important;
  border: 1px solid #9bb4c8 !important;
  background: #fff !important;
}

body.shop-modern #ShopContent .FormButton--secondary:hover,
body.shop-modern #ShopContent button.FormButton--secondary:hover,
body.shop-modern #ShopContent button.FormButton:not(.FormButton--primary):hover {
  border-color: var(--shop-brand) !important;
  background: #f3f8fc !important;
}

body.shop-modern #ShopContent .shop-form-address {
  padding-top: 0.15rem !important;
}

body.shop-modern #ShopContent .shop-address-grid {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent !important;
}

body.shop-modern #ShopContent .shop-order-form .shop-form-grid,
body.shop-modern #ShopContent .shop-order-form table.FormBody {
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.shop-modern #ShopContent .shop-form-grid > tbody,
body.shop-modern #ShopContent .shop-address-grid > tbody {
  display: block;
  width: 100%;
}

body.shop-modern #ShopContent .shop-form-grid td.FormLabel:empty,
body.shop-modern #ShopContent .shop-address-grid td.FormLabel:empty {
  display: none;
}

@media (max-width: 720px) {
  body.shop-modern #ShopContent .shop-form-actions {
    justify-content: stretch;
  }

  body.shop-modern #ShopContent .shop-form-actions .FormButton,
  body.shop-modern #ShopContent .shop-form-actions button.FormButton {
    flex: 1 1 auto;
    width: 100% !important;
  }

  body.shop-modern #ShopContent .shop-form-zipcity {
    flex-wrap: wrap;
  }

  body.shop-modern #ShopContent .FormInput--city {
    flex: 1 1 100%;
  }
}

/* Paging */
body.shop-modern .PagingBar,
body.shop-modern .PagingBarLight {
  height: auto !important;
  min-height: 44px;
  padding: 0.4rem 0.55rem;
  background: #eef5fb !important;
  background-image: none !important;
  border: 0;
  border-radius: 10px;
  margin: 0.55rem 0;
  box-sizing: border-box;
}

body.shop-modern .PagingBar.shop-paging,
body.shop-modern .PagingBarLight.shop-paging {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  column-gap: 1rem;
  row-gap: 0.45rem;
  width: 100%;
}

body.shop-modern .PagingBarLight.shop-paging--lite {
  justify-content: flex-end;
  width: auto;
  max-width: 100%;
  margin-left: auto;
}

body.shop-modern .shop-paging-pages {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.15rem;
  flex: 0 0 auto;
  max-width: 100%;
  white-space: nowrap;
}

body.shop-modern .shop-paging-ellipsis {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  color: var(--shop-muted);
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
}

body.shop-modern .shop-paging-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.7rem;
  flex: 0 0 auto;
  margin-left: auto;
  justify-content: flex-end;
  white-space: nowrap;
}

body.shop-modern .shop-paging-field {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.25rem 0.2rem;
  flex: 0 0 auto;
  margin: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  color: var(--shop-ink);
  cursor: default;
}

body.shop-modern .shop-paging-field .PagingSelect {
  margin-right: 0 !important;
}

body.shop-modern .shop-paging-field .PagingSelect + #SortOrderSwitch,
body.shop-modern .shop-paging-field .PagingSelect + .SortOrderASC,
body.shop-modern .shop-paging-field .PagingSelect + .SortOrderDESC,
body.shop-modern .shop-paging-field .PagingSelect + .SortOrderDisable,
body.shop-modern .shop-paging #SortOrderSwitch {
  margin-left: 0 !important;
}

body.shop-modern .shop-paging-label {
  white-space: nowrap;
}

body.shop-modern .shop-paging-field .PagingSelect,
body.shop-modern .shop-paging-field select.PagingSelect {
  width: auto;
  max-width: 11rem;
}

body.shop-modern .shop-paging #SortOrderSwitch.SortOrderASC,
body.shop-modern .shop-paging #SortOrderSwitch.SortOrderDESC,
body.shop-modern .shop-paging #SortOrderSwitch.SortOrderDisable,
body.shop-modern .shop-paging .SortOrderASC,
body.shop-modern .shop-paging .SortOrderDESC,
body.shop-modern .shop-paging .SortOrderDisable {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 2rem !important;
  height: 2rem !important;
  min-width: 2rem;
  min-height: 2rem;
  margin: 0 !important;
  padding: 0;
  border: 1px solid var(--shop-line);
  border-radius: 8px;
  background: #fff !important;
  background-image: none !important;
  color: var(--shop-brand);
  box-sizing: border-box;
  cursor: pointer;
}

body.shop-modern .shop-paging .SortOrderASC::before,
body.shop-modern .shop-paging .SortOrderDESC::before,
body.shop-modern .shop-paging .SortOrderDisable::before {
  content: "";
  display: block;
  width: 1.15rem;
  height: 1.15rem;
  background: currentColor;
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M12 4.5 19.2 14.2H4.8L12 4.5z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23000' d='M12 4.5 19.2 14.2H4.8L12 4.5z'/%3E%3C/svg%3E");
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-position: center;
  mask-size: contain;
  -webkit-mask-size: contain;
}

body.shop-modern .shop-paging .SortOrderDESC::before {
  transform: rotate(180deg);
}

body.shop-modern .shop-paging .SortOrderASC:hover,
body.shop-modern .shop-paging .SortOrderDESC:hover {
  background: var(--shop-brand-soft) !important;
  border-color: #9bb4c8;
}

body.shop-modern .shop-paging .SortOrderDisable {
  color: #9aa8b5;
  cursor: default;
  opacity: 0.7;
}

@media (max-width: 1100px) {
  body.shop-modern .shop-paging-pages,
  body.shop-modern .shop-paging-controls {
    flex: 1 1 100%;
  }

  body.shop-modern .shop-paging-controls {
    margin-left: 0;
    justify-content: flex-start;
  }
}

body.shop-modern .PagingBar table,
body.shop-modern .PagingBarLight table {
  border-collapse: separate;
  border-spacing: 0.15rem;
}

body.shop-modern a.ListPages,
body.shop-modern a.ListActualPage {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.85rem;
  min-height: 1.85rem;
  padding: 0.15rem 0.45rem !important;
  margin: 0;
  border-radius: 8px;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none !important;
  white-space: nowrap;
  box-sizing: border-box;
  transition: background-color .15s ease, color .15s ease, box-shadow .15s ease;
}

body.shop-modern a.ListPages {
  color: var(--shop-brand) !important;
  background: transparent !important;
}

body.shop-modern a.ListPages:hover {
  color: var(--shop-brand) !important;
  background: var(--shop-brand-soft) !important;
}

body.shop-modern a.ListActualPage,
body.shop-modern a:hover.ListActualPage {
  color: #fff !important;
  background: var(--shop-brand) !important;
  box-shadow: 0 1px 0 rgba(13, 55, 95, 0.12);
  cursor: default;
}

body.shop-modern .PagingSelect,
body.shop-modern select.PagingSelect {
  height: 2rem !important;
  min-height: 2rem;
  margin: 0 0.15rem 0 0 !important;
  padding: 0 0.45rem !important;
  border: 1px solid var(--shop-line) !important;
  border-radius: 8px !important;
  background: #fff !important;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  color: var(--shop-ink);
  box-sizing: border-box;
}

/* Advert / Novinky */
body.shop-modern #Advert.panel.World,
body.shop-modern .world#Advert {
  margin-top: 14px;
}

#Advert .panel-body {
  width: 100%;
  box-sizing: border-box;
}

#Advert .panel-body,
.AdvertNewestBox,
.AdvertGoodsBox,
.AdvertNewestBoxBody,
.AdvertGoodsBoxBody {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.AdvertNewestBoxBody,
.AdvertGoodsBoxBody {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.AdvertGoodContentHolder {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box;
}

.AdvertElementCard {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  grid-template-areas:
    "media name"
    "media price";
  column-gap: 8px;
  row-gap: 2px;
  width: 100%;
  max-width: 100%;
  padding: var(--shop-inset-pad);
  border: 0;
  border-radius: 8px;
  background: #f3f8fc;
  box-sizing: border-box;
  align-items: center;
}

.AdvertElementName {
  grid-area: name;
  width: 100% !important;
  min-width: 0;
  margin: 0 !important;
  padding: 0;
  border-bottom: 0;
  background: none !important;
}

.AdvertElementName h6,
.AdvertElementName a,
.AdvertElementName .ElementNameLengthLimiter {
  display: block;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0;
  font-family: var(--shop-display);
  font-size: var(--shop-fs-xs) !important;
  font-weight: 650;
  line-height: 1.25;
  color: var(--shop-ink);
  overflow: hidden;
}

.AdvertElementName .ElementNameLengthLimiter {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  white-space: normal;
}

.AdvertElementMediaWrap {
  grid-area: media;
  display: block;
  width: 56px;
}

.AdvertElementMedia {
  display: block;
  width: 100%;
}

.AdvertElementImage,
img.AdvertElementImage,
div.AdvertElementImage {
  display: block;
  width: 56px !important;
  max-width: 56px !important;
  height: 42px !important;
  min-height: 0;
  aspect-ratio: auto;
  object-fit: contain;
  margin: 0;
  border: 1px solid var(--shop-line) !important;
  border-radius: 5px;
  background: #f7fafc center / contain no-repeat;
}

/* long captions do not fit the narrow aside — keep cards to name + price */
.AdvertElementCaption {
  display: none !important;
}

.AdvertElementPrice {
  grid-area: price;
  width: 100%;
  min-width: 0;
  text-align: left;
  line-height: 1.2;
  overflow: hidden;
}

.AdvertGoodContentHolder td,
.AdvertGoodContentHolder td *,
.AdvertElementCard .ShopPrice,
.AdvertElementCard .ShopPriceWithTax,
.AdvertElementCard .Pismo {
  font-size: var(--shop-fs-xs) !important;
}

.AdvertElementCard .ShopPrice {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm) !important;
  font-weight: 700;
  color: var(--shop-price) !important;
}

.AdvertElementCard .ShopPriceInfluenceOfConfDef,
.AdvertElementCard .ShopPriceInfluenceOfConfDef + br,
.AdvertElementCard .ShopPriceNet,
.AdvertElementCard .ShopPriceNet + br,
.AdvertElementCard .ShopPriceWithTax,
.AdvertElementCard .ShopPriceWithTax br {
  display: none !important;
}

.AdvertLinksContentHolder,
.AdvertLink {
  width: 100% !important;
  max-width: 100% !important;
  background-size: contain;
}

/* Footer meta */
.shop-footer-meta {
  margin-top: 18px;
}

.ShopNacionaleBoxBody {
  width: 100% !important;
  text-align: center;
}

.ShopNacionaleBoxBody h5,
.ShopNacionaleBoxBody a {
  font-size: var(--shop-fs-xs);
  font-weight: 400 !important;
  color: var(--shop-muted);
  line-height: 1.35;
}

.ShopNacionaleBoxBody h5 {
  margin: 0;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
  word-break: break-word;
  font-family: var(--shop-font);
}

/* Drawers / mobile */
.shop-drawer-scrim {
  display: none;
}

.shop-drawer-toolbar {
  display: none;
}

body.shop-drawer-open {
  overflow: hidden;
}

/* Mid widths: don't drop Zákazník/Novinky under content —
   login goes behind account button, Novinky stay hidden. */
@media (max-width: 1100px) {
  .shop-aside-toggle {
    display: inline-flex;
  }

  .shop-layout {
    grid-template-columns: var(--shop-sidebar) minmax(0, 1fr);
  }

  .shop-aside {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    width: min(320px, 88vw);
    z-index: 40;
    padding: 0;
    overflow: auto;
    background: rgba(215, 235, 248, 0.96);
    backdrop-filter: blur(6px);
    transition: transform .22s ease;
    transform: translateX(105%);
    display: block;
  }

  .shop-aside.is-open {
    transform: translateX(0);
  }

  .shop-aside .shop-drawer-scrim {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(16, 35, 55, 0.45);
    z-index: -1;
  }

  .shop-aside .shop-drawer-panel {
    position: relative;
    z-index: 1;
    padding: 12px;
    min-height: 100%;
    box-sizing: border-box;
  }

  .shop-aside .shop-drawer-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 10px;
  }

  body.shop-modern button.shop-drawer-close {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    height: 36px !important;
    min-height: 36px !important;
    margin: 0 !important;
    padding: 0 0.7rem !important;
    border: 1px solid var(--shop-line) !important;
    border-radius: 8px !important;
    background: #fff !important;
    background-image: none !important;
    color: var(--shop-ink) !important;
    font-family: var(--shop-display);
    font-size: var(--shop-fs-sm) !important;
    font-weight: 650;
    box-shadow: none;
    cursor: pointer;
  }

  body.shop-modern button.shop-drawer-close:hover {
    border-color: var(--shop-brand) !important;
    color: var(--shop-brand) !important;
    background: #f3f8fc !important;
  }

  .shop-aside #Advert {
    display: none !important;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .shop-nav-toggle {
    display: inline-flex;
  }

  .shop-header-top {
    grid-template-columns: auto 1fr auto;
  }

  .shop-banner {
    display: none;
  }

  .shop-layout {
    grid-template-columns: 1fr;
  }

  .shop-sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: min(320px, 88vw);
    z-index: 40;
    padding: 0;
    overflow: auto;
    background: rgba(215, 235, 248, 0.96);
    backdrop-filter: blur(6px);
    transition: transform .22s ease;
    transform: translateX(-105%);
  }

  .shop-sidebar.is-open {
    transform: translateX(0);
  }

  .shop-sidebar .shop-drawer-scrim {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(16, 35, 55, 0.45);
    z-index: -1;
  }

  .shop-sidebar .shop-drawer-panel {
    position: relative;
    z-index: 1;
    padding: 12px;
    min-height: 100%;
    box-sizing: border-box;
  }

  .shop-sidebar .shop-drawer-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 10px;
  }

  #Directory .DirectoryBoxBody {
    max-height: none;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .shop-header-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .shop-search {
    flex: 1 1 auto;
    width: 100%;
  }

  .MenuBoxBody ul {
    gap: 2px;
  }

  .MenuBoxBody li a {
    padding: 0.4rem 0.55rem;
  }
}

@media (max-width: 520px) {
  #PageContent.shop-shell {
    padding: 8px 8px 28px;
  }

  .shop-brand .PageLogo {
    width: 180px;
    height: 70px;
  }

  .product-card-body {
    grid-template-columns: 72px minmax(0, 1fr);
    column-gap: 0.85rem;
    padding: 0.6rem;
  }

  .product-card-media,
  .product-card-media > a,
  .product-card-media img,
  .product-card-media .ShopImagSpeed,
  .product-card-media div.ShopImagSpeed {
    width: 72px !important;
    min-width: 72px;
    max-width: 72px;
  }

  .product-card-media > a,
  .product-card-media img,
  .product-card-media .ShopImagSpeed,
  .product-card-media div.ShopImagSpeed {
    height: 54px !important;
    min-height: 54px;
    max-height: 54px;
  }

  .product-card-meta {
    padding-left: 0;
    gap: 0.4rem;
  }
}

/* Soften global * cursor override leftover for interactive bits */
body.shop-modern a,
body.shop-modern button,
body.shop-modern input,
body.shop-modern select,
body.shop-modern textarea,
body.shop-modern .ShopPrintElement,
body.shop-modern .ShopMorePictures {
  cursor: pointer;
}

body.shop-modern input[type="text"],
body.shop-modern input[type="password"],
body.shop-modern textarea {
  cursor: text;
}

/* In-page product picture lightbox */
body.shop-lightbox-open {
  overflow: hidden;
}

.shop-lightbox[hidden] {
  display: none !important;
}

.shop-lightbox {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
}

.shop-lightbox-scrim {
  position: absolute;
  inset: 0;
  background: rgba(12, 28, 44, 0.72);
  backdrop-filter: blur(3px);
  cursor: pointer;
}

.shop-lightbox-dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(960px, 100%);
  max-height: min(92vh, 900px);
  margin: 0 auto;
  padding: 0.75rem 0.75rem 0.65rem;
  border-radius: 16px;
  background: #0f2436;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
  box-sizing: border-box;
}

.shop-lightbox-close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  z-index: 3;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 40px !important;
  min-width: 40px !important;
  height: 40px !important;
  min-height: 40px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.12) !important;
  background-image: none !important;
  color: #fff !important;
  box-shadow: none !important;
  cursor: pointer;
}

.shop-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.22) !important;
}

.shop-lightbox-nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  transform: translateY(-70%);
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 44px !important;
  min-width: 44px !important;
  height: 44px !important;
  min-height: 44px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.14) !important;
  background-image: none !important;
  color: #fff !important;
  box-shadow: none !important;
  cursor: pointer;
}

.shop-lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.26) !important;
}

.shop-lightbox-prev {
  left: 0.75rem;
}

.shop-lightbox-next {
  right: 0.75rem;
}

.shop-lightbox-nav[hidden] {
  display: none !important;
}

.shop-lightbox-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  min-height: 220px;
  max-height: calc(92vh - 9rem);
  padding: 2.4rem 3.5rem 0.75rem;
  box-sizing: border-box;
}

.shop-lightbox-image {
  display: block;
  max-width: 100%;
  max-height: calc(92vh - 11rem);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 10px;
  background: #163149;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}

.shop-lightbox-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  padding: 0.35rem 0.25rem 0.15rem;
}

.shop-lightbox-count {
  font-family: var(--shop-display);
  font-size: var(--shop-fs-sm);
  font-weight: 650;
  color: rgba(255, 255, 255, 0.82);
  letter-spacing: 0.04em;
}

.shop-lightbox-count[hidden] {
  display: none !important;
}

.shop-lightbox-thumbs {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 0.4rem;
  max-width: 100%;
  overflow-x: auto;
  padding: 0.15rem 0.2rem 0.35rem;
  box-sizing: border-box;
  scrollbar-width: thin;
}

.shop-lightbox-thumbs[hidden] {
  display: none !important;
}

.shop-lightbox-thumb {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 64px !important;
  min-width: 64px !important;
  height: 48px !important;
  min-height: 48px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 2px solid transparent !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, 0.08) !important;
  background-image: none !important;
  overflow: hidden;
  cursor: pointer;
  box-shadow: none !important;
}

.shop-lightbox-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shop-lightbox-thumb:hover {
  border-color: rgba(255, 255, 255, 0.35) !important;
}

.shop-lightbox-thumb.is-active {
  border-color: #7eb7e8 !important;
  box-shadow: 0 0 0 1px rgba(126, 183, 232, 0.35);
}

@media (max-width: 720px) {
  .shop-lightbox {
    padding: 0.5rem;
  }

  .shop-lightbox-dialog {
    max-height: 96vh;
    padding: 0.55rem;
    border-radius: 12px;
  }

  .shop-lightbox-stage {
    padding: 2.6rem 0.35rem 0.5rem;
  }

  .shop-lightbox-nav {
    top: auto;
    bottom: 5.5rem;
    transform: none;
  }

  .shop-lightbox-prev {
    left: 0.55rem;
  }

  .shop-lightbox-next {
    right: 0.55rem;
  }

  .shop-lightbox-thumb {
    width: 56px !important;
    min-width: 56px !important;
    height: 42px !important;
    min-height: 42px !important;
  }
}
