

:root {
  color-scheme: light;
  --bg: #f3f6fc;  --surface: #ffffff;  --text: #1b2236;  --muted: #566079;  --line: #d9e1f0;
  --bar: #1b2744;                         
  --grid: rgba(29, 78, 216, .07);
  --accent: #1d4ed8;  --accent-hover: #1e40af;  --on-accent: #fff;   
  --accent-text: #1d4ed8;
  --radius: 12px;   --cell: 32px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0e1424;  --surface: #161e33;  --text: #e6ebf7;  --muted: #97a3bd;  --line: #26324f;
  --bar: #0a0f1c;
  --grid: rgba(120, 160, 255, .07);
  --accent: #2f62e8;  --accent-hover: #4a78f0;
  --accent-text: #8db4ff;
}

html[data-theme] {
  & body {
    font-family: 'Open Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    color: var(--text);
    background-color: var(--bg);
    background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
    background-size: var(--cell) var(--cell);
    background-attachment: fixed;
  }
  & #top, & .menu-row, & footer { background-color: var(--bar); }


  & header a, & .us-cart-text, & .top-phone-btn { color: var(--text); }
  & .us-cart-link, & .us-phone-link { color: var(--accent-text); }


  & .modal-content, & .nav-dropdown-menu, & .dropdown-menu, & #us_livesearch,
  & #oct-menu-dropdown-menu, & .oct-menu-child-ul, & .oct-mm-dropdown, & .oct-menu-li {
    background-color: var(--surface);
    color: var(--text);
  }
  & .modal-content, & .nav-dropdown-menu, & .dropdown-menu, & #us_livesearch { border-radius: var(--radius); }
  & .oct-menu-li { border-color: var(--line); }
  & .oct-menu-li a, & .dropdown-item, & .nav-dropdown-menu a { color: var(--text); }
  & .oct-menu-li a:hover, & .dropdown-item:hover { color: var(--accent-text); }


  & .btn, & button, & input[type="submit"], & .us-module-btn, & .oct-ultra-menu { border-radius: var(--radius); }
  & .us-module-btn-green, & .us-footer-form-top-buttton, & .header-btn-search,
  & #back-top, & #us_fixed_contact_button, & .us-fixed-contact-pulsation {
    background-color: var(--accent);
    color: var(--on-accent);
  }
  & .us-module-btn-green:hover, & .us-footer-form-top-buttton:hover, & .header-btn-search:hover { background-color: var(--accent-hover); }
  & .oct-ultra-menu { background-color: var(--accent); }

  & .form-control, & .us-footer-form-top-input { border-radius: var(--radius); }
  & .form-control { background-color: var(--surface); color: var(--text); border: 1px solid var(--line); }
  & .header-input { background-color: var(--surface); color: var(--text); border: 1px solid var(--line); border-right: 0; border-radius: var(--radius) 0 0 var(--radius); }
  & .header-btn-search { border: 0 !important; border-radius: 0 var(--radius) var(--radius) 0; }
  & .us-footer-form-top-input { border-radius: var(--radius) 0 0 var(--radius); }
  & .us-footer-form-top-buttton { border-radius: 0 var(--radius) var(--radius) 0; }
  & ::placeholder { color: var(--muted); }

  & :focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
}
html[data-theme="dark"] .us-logo-img { background: #fff; padding: 6px 10px; border-radius: var(--radius); }



html[data-theme] {
  & .oct-fixed-bar-quantity, & .oct-fixed-bar-link:hover, & .pagination li.active span, & .pagination li a:hover,
  & .us-product-btn-active, & .us-product-btn:hover, & .us-product-quantity-btn:hover, & #us_livesearch_close,
  & button.us-close, & .oct-mm-link:hover > a, & .oct-mm-simple-link:hover > a, & .us-module-item:hover .us-module-cart-btn,
  & .us-module-btn:hover, & .compare-wishlist-btn:hover, & .image-additional-box .slick-arrow:hover {
    background-color: var(--accent); color: var(--on-accent);
  }
  & .oct-menu-li:hover > a, & .oct-menu-li:hover > div > a, & .oct-mm-child a:hover, & .oct-mm-parent-link:hover .oct-mm-parent-title,
  & .us-categories-item.active > span a, & .us-categories-item a:hover { color: var(--accent-text); }
  & .us-footer-link:hover, & .us-footer-phone-btn:hover, & .us-footer-mail:hover { color: #8db4ff; }
  & .us-carousel-brands-box, & .us-product-nav-item-active a:after, & .us-product-nav-item a:hover:after, & .us-page-main { border-color: var(--accent); }
  & .us-footer-form-top-input::placeholder { color: rgba(255, 255, 255, .75); }
}


.theme-toggle {
  display: inline-flex; align-items: center; align-self: center; gap: .5rem;
  margin-left: 12px; padding: 5px 14px;
  font: inherit; font-size: 12px; line-height: 1.2; color: #e5e5e5;
  background: transparent; border: 1px solid rgba(255, 255, 255, .35); border-radius: 999px; cursor: pointer;
  transition: border-color .15s, color .15s;
}
.theme-toggle:hover { border-color: #fff; color: #fff; }


.home-hero { padding: 72px 0 56px; text-align: center; }
.home-hero h1 { font-size: 36px; font-weight: 700; margin: 0 0 12px; }
.home-hero p { color: var(--muted); font-size: 18px; margin: 0 0 28px; }
.home-hero-btn { display: inline-block; padding: 12px 32px; text-decoration: none; }
.catalog-page { padding: 24px 0 24px; }
.catalog-breadcrumb { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.catalog-breadcrumb a { color: var(--accent-text); }
.catalog-title { font-size: 30px; font-weight: 700; margin: 0 0 24px; }
.catalog-empty { padding: 64px 24px; text-align: center; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.catalog-empty-title { font-size: 20px; font-weight: 600; margin: 0 0 8px; }
.catalog-empty p:last-child { color: var(--muted); margin: 0; }
.catalog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 20px; }
.catalog-grid:empty { display: none; }
.product-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.product-card img { width: 100%; height: auto; border-radius: 8px; }
.product-card-title { font-size: 15px; margin: 12px 0 6px; }
.product-card-price { font-weight: 700; margin-bottom: 12px; }

html[data-theme] .us-menu-mobile { background-color: var(--accent); }
.theme-toggle-float { display: none; }
@media (max-width: 991.98px) {
  .theme-toggle-top { display: none !important; }
  .theme-toggle-float {
    display: inline-flex; position: fixed; left: 14px; bottom: 18px; z-index: 1040; margin: 0; padding: 13px;
    color: #e5e5e5; background: var(--bar); border: 1px solid rgba(255, 255, 255, .3); box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
  }
  .theme-toggle-float span { display: none; }
}
@media (max-width: 575px) {
  .home-hero { padding: 40px 0; }
  .home-hero h1 { font-size: 26px; }
}


[hidden] { display: none !important; }
.product-card { position: relative; cursor: pointer; transition: border-color .15s, transform .15s; }
.product-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.product-card-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: var(--bg); }
.product-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-card-noimg { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 120px; color: var(--muted); font-size: 13px; background: var(--bg); border-radius: 8px; }
.product-card-title { font-size: 16px; font-weight: 600; margin: 12px 0 4px; overflow-wrap: anywhere; }
.product-card-price { font-weight: 700; color: var(--accent-text); }
.product-card-desc { color: var(--muted); font-size: 13px; margin: 8px 0 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.wish-btn { position: absolute; top: 8px; right: 8px; width: 36px; height: 36px; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  color: var(--muted); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; cursor: pointer; }
.wish-btn.on { color: #e11d48; border-color: #e11d48; }
.wish-btn-text { position: static; width: auto; height: auto; padding: 8px 16px; margin-top: 12px; gap: 6px; font: inherit; }

dialog.shop-dialog { width: min(520px, 94vw); max-height: 90vh; padding: 0; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 20px 60px rgba(0, 0, 0, .35); overflow: auto; }
dialog.shop-dialog-wide { width: min(900px, 94vw); }
dialog.shop-dialog::backdrop { background: rgba(8, 14, 32, .65); }
.shop-dialog-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.shop-dialog-head h2 { margin: 0; font-size: 18px; font-weight: 700; overflow-wrap: anywhere; }
.shop-dialog-x { width: 36px; height: 36px; padding: 0; font-size: 22px; line-height: 1; color: var(--text); background: transparent; border: 0; cursor: pointer; }
.shop-dialog-body { padding: 20px; }
.shop-form { display: flex; flex-direction: column; gap: 12px; }
.shop-field { display: flex; flex-direction: column; gap: 4px; margin: 0; font-size: 14px; }
.shop-field span { font-weight: 600; }
.shop-field textarea { resize: vertical; }
.shop-hint { color: var(--muted); font-size: 13px; margin: 0; }
.shop-msg { min-height: 20px; margin: 0; font-size: 14px; }
.shop-msg.ok { color: #15803d; }  .shop-msg.err { color: #dc2626; }
.shop-submit { padding: 11px 24px; border: 0; cursor: pointer; }
.shop-link { align-self: flex-start; padding: 6px 0; color: var(--accent-text); background: none; border: 0; text-decoration: underline; cursor: pointer; }
.shop-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.shop-tabs button { padding: 8px 16px; font: inherit; font-size: 14px; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; cursor: pointer; }
.shop-tabs button.on { color: #fff; background: var(--accent); border-color: var(--accent); }
.shop-tabs .adm-exit { margin-left: auto; }
.shop-empty { text-align: center; padding: 24px 0; }
.shop-empty-title { font-size: 18px; font-weight: 600; margin: 0 0 6px; }

.cd { display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; }
.cd-main { width: 100%; border-radius: 8px; display: block; }
.cd-thumbs { display: flex; gap: 8px; margin-top: 8px; }
.cd-thumbs img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); cursor: pointer; }
.cd-info .product-card-price { font-size: 24px; }
.cd-desc { white-space: pre-wrap; overflow-wrap: anywhere; margin: 12px 0 0; }
.wl-row, .adm-row { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.wl-row img, .adm-row img, .wl-noimg { width: 64px; height: 64px; flex: none; object-fit: cover; border-radius: 8px; background: var(--bg); }
.wl-title { flex: 1; text-align: left; padding: 0; font: inherit; font-weight: 600; color: var(--text); background: none; border: 0; cursor: pointer; overflow-wrap: anywhere; }
.adm-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; overflow-wrap: anywhere; }
.adm-info span, .adm-info p { color: var(--muted); font-size: 13px; margin: 0; }
.adm-actions { display: flex; gap: 8px; flex: none; }
.adm-actions button { padding: 8px 16px; border: 0; cursor: pointer; }
.adm-del { color: #fff; background: #dc2626; }
.adm-view { min-height: 160px; }


footer { position: relative; }
.shop-secret { position: absolute; right: 10px; bottom: 4px; padding: 4px 6px; font: 12px/1 monospace; color: rgba(255, 255, 255, .09); background: none; border: 0; cursor: default; }
.shop-secret:hover, .shop-secret:focus-visible { color: rgba(255, 255, 255, .4); }


a[href*="checkout"], .us-cart-link { display: none !important; }
@media (max-width: 700px) { .cd { grid-template-columns: 1fr; } .adm-row { flex-wrap: wrap; } }


html[data-theme] {
  & .us-main-shop-title, & .us-content-title { color: var(--text); }
  & .us-category-content { background: var(--surface); border-radius: var(--radius); box-shadow: none; border: 1px solid var(--line); }
  & .us-manufacturer-title, & .us-manufacturer-card, & .us-breadcrumb-item:last-child { color: var(--accent-text); }
  & .us-manufacturer-item { border-bottom-color: var(--line); }
  & .us-manufacturer-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg); box-shadow: none; }
  & .us-manufacturer-card:hover { border-color: var(--accent); box-shadow: none; }
  & .us-manufacturer-card img { object-fit: cover; border-radius: 8px; }
  & .us-breadcrumb-item a { color: var(--accent-text); }
}
.brand-count { color: var(--muted); font-weight: 400; margin-top: 4px; }
.brand-empty { padding: 32px; text-align: center; color: var(--muted); }
.brand-products { margin: 24px 0; }
.us-manufacturer-title { scroll-margin-top: 80px; }
.product-card-brand { color: var(--muted); font-size: 13px; margin-bottom: 4px; }
.cd-brand { margin: 8px 0 0; color: var(--muted); }
.cd-brand a { color: var(--accent-text); }
.page-text { max-width: 860px; min-height: 160px; line-height: 1.7; overflow-wrap: anywhere; }
.page-text h2 { font-size: 22px; margin: 28px 0 12px; }
.page-text p { margin: 0 0 14px; }
.page-text ul, .page-text ol { margin: 0 0 14px 20px; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }


.us-phone-box .phoneclick, .us-phone-box .us-phone-content a { white-space: nowrap; font-size: 13px; line-height: 1.55; }
.us-footer-box .phoneclick { white-space: nowrap; }

html[data-theme] .us-main-shop-title:after { background: var(--line); }


.sys-page, .sys-page * { box-sizing: border-box; }
.sys-page { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 32px 20px; text-align: center; }
.sys-logo { margin-bottom: 8px; }
.sys-logo img { max-width: 100%; height: auto; }
.sys-code { font-size: clamp(88px, 18vw, 160px); font-weight: 800; line-height: 1; letter-spacing: -.04em; color: var(--accent-text); }
.sys-icon { color: var(--accent-text); }
.sys-page h1 { margin: 0; font-size: clamp(26px, 4vw, 36px); font-weight: 700; color: var(--text); }
.sys-page p { max-width: 520px; margin: 0; color: var(--muted); }
.sys-note { font-weight: 600; color: var(--text) !important; }
.sys-link { color: var(--accent-text); }
.sys-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 18px; }
.sys-btn { display: inline-block; padding: 12px 28px; color: var(--text); text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .15s; }
.sys-btn:hover { border-color: var(--accent); }
.sys-btn-primary { color: var(--on-accent); background: var(--accent); border-color: var(--accent); }
.sys-btn-primary:hover { background: var(--accent-hover); }

.shop-kept { display: flex; flex-wrap: wrap; gap: 10px; }
.shop-kept-item { position: relative; }
.shop-kept-item img { width: 76px; height: 76px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); display: block; }
.shop-kept-item button { position: absolute; top: -7px; right: -7px; width: 22px; height: 22px; padding: 0; font-size: 15px; line-height: 1; color: #fff; background: #dc2626; border: 0; border-radius: 999px; cursor: pointer; }
.adm-h { margin: 0 0 8px; font-size: 17px; font-weight: 700; }
.adm-section { margin-bottom: 28px; }
.adm-section .form-control { margin-bottom: 10px; }
.adm-search { margin-bottom: 12px; }
.adm-secondary { color: var(--text); background: var(--bg); border: 1px solid var(--line) !important; }
.adm-import-actions { flex-wrap: wrap; margin-bottom: 8px; }
