/* ============================================
   INTERNET MAGAZINE - MiniShop2 + Bootstrap 5
   Author: Custom Design
   Version: 1.0
============================================ */

/* --- Root Variables --- */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #507eaf;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --info-color: #3498db;
    --dark-color: #2c3e50;
    --light-color: #ecf0f1;
    --gray-color: #95a5a6;
    --transition: all 0.3s ease;

    --apple-text:#1d1d1f;
    --apple-text-secondary:#6e6e73;
    --apple-blue:#0a84ff;
    --apple-indigo:#5e5ce6;
    --apple-purple:#bf5af2;
    --apple-bg:#ffffff;
    --apple-hairline:rgba(0,0,0,.06);
    --btn-color: #ffff;
    --btn-bg: #507eaf;
    --btn-border-color: #2d4762;
    --btn-hover-color: #ffff;
    --btn-hover-bg: black;
    --btn-hover-border-color: #2d4762;
    --btn-focus-shadow-rgb: 49, 132, 253;
    --btn-active-color: #ffff;
    --btn-active-bg: #0a58ca;
    --btn-active-border-color: #0a53be;
    --btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
    --btn-disabled-color: #ffff;
    --btn-disabled-bg: #0d6efd;
    --btn-disabled-border-color: #0d6efd;
}
/* --- Global Styles --- */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #333;
    background-color: white;
}
main.container-fluid.p-0 {background:transparent;}
/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* --- Header Styles --- */
.main-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #1a252f 100%);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: white;
    text-decoration: none;
    transition: var(--transition);
}

.logo:hover {
    color: var(--secondary-color);
    transform: scale(1.05);
}

/* --- Search Form --- */
.search-form {
    position: relative;
}

.search-form input {
    border-radius: 50px;
    padding: 12px 20px;
    border: none;
    background: rgba(255,255,255,0.95);
    transition: var(--transition);
}

.search-form input:focus {
    box-shadow: 0 0 0 3px rgba(231,76,60,0.3);
    background: white;
}

.search-form button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 50px;
    background: var(--secondary-color);
    color: white;
    border: none;
    padding: 8px 20px;
}

/* --- Cart Icon --- */
.cart-icon {
    position: relative;
    display: inline-block;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -12px;
    background: var(--secondary-color);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* --- Product Card --- */
.product-card {
    background: white;
    border-radius: 65px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 30px;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.product-image {
    position: relative;
    overflow: hidden;
    height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
}

.badge-new {
    background: var(--success-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-sale {
    background: var(--secondary-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.product-info {
    padding: 20px;
}

.product-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 10px;
    min-height: 50px;
}

.product-title a {
    color: #333;
    text-decoration: none;
    transition: var(--transition);
}

.product-title a:hover {
    color: var(--secondary-color);
}

.product-price {
    margin: 15px 0;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.old-price {
    font-size: 0.9rem;
    color: var(--gray-color);
    text-decoration: line-through;
    margin-left: 10px;
    font-weight: normal;
}

.product-actions {
    display: flex;
    gap: 10px;
}

.btn-cart {
    flex: 1;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    transition: var(--transition);
    font-weight: 500;
}

.btn-cart:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.btn-wishlist {
    width: 40px;
    background: var(--light-color);
    border: none;
    border-radius: 8px;
    transition: var(--transition);
}

.btn-wishlist:hover {
    background: var(--secondary-color);
    color: white;
}

/* --- Product Gallery --- */
.product-gallery {
    background: white;
    border-radius: 12px;
    padding: 20px;
}

.main-image {
    width: 100%;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
}

.main-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.thumbnail-list {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.thumbnail {
    width: 80px;
    height: 80px;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 8px;
    transition: var(--transition);
}

.thumbnail:hover,
.thumbnail.active {
    border-color: var(--secondary-color);
}

/* --- Product Info Section --- */
.product-info-section {
    background: white;
    border-radius: 12px;
    padding: 30px;
}

.product-name {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.product-rating {
    margin-bottom: 20px;
}

.stars {
    color: var(--warning-color);
}

.review-count {
    color: var(--gray-color);
    margin-left: 10px;
}

.prices {
    margin-bottom: 20px;
}

.current-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.old-price-large {
    font-size: 1.2rem;
    color: var(--gray-color);
    text-decoration: line-through;
    margin-left: 15px;
}

.discount-badge {
    background: var(--secondary-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-left: 15px;
}

.product-description {
    margin: 25px 0;
    padding: 20px 0;
    border-top: 1px solid #dee2e6;
    border-bottom: 1px solid #dee2e6;
}

.product-meta {
    margin: 20px 0;
}

.meta-item {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.meta-label {
    width: 100px;
    font-weight: 600;
    color: #666;
}

.meta-value {
    color: #333;
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 25px 0;
}

.quantity-input {
    width: 100px;
    text-align: center;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 8px;
}

.btn-add-to-cart-large {
    background: var(--secondary-color);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
}

.btn-add-to-cart-large:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(231,76,60,0.3);
}

/* --- Characteristics Table --- */
.characteristics-table {
    background: white;
    border-radius: 12px;
    padding: 20px;
}

.characteristics-table table {
    width: 100%;
}

.characteristics-table tr {
    border-bottom: 1px solid #dee2e6;
}

.characteristics-table td {
    padding: 12px;
}

.characteristics-table td:first-child {
    font-weight: 600;
    width: 200px;
    background: var(--light-color);
}

/* --- Sidebar Filters --- */
.sidebar-widget {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.widget-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--secondary-color);
    display: inline-block;
}

.filter-group {
    margin-bottom: 20px;
}

.filter-label {
    font-weight: 500;
    margin-bottom: 10px;
    display: block;
}

.price-slider {
    margin: 20px 0;
}

.filter-checkbox {
    margin-bottom: 10px;
}

.filter-checkbox label {
    margin-left: 8px;
    cursor: pointer;
}

.btn-filter {
    width: 100%;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    transition: var(--transition);
}

.btn-filter:hover {
    background: var(--secondary-color);
}

/* --- Cart Page --- */
.cart-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
}

.cart-item {
    border-bottom: 1px solid #dee2e6;
    padding: 20px;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.cart-item-title {
    font-weight: 600;
    color: #333;
    text-decoration: none;
}

.cart-item-price,
.cart-item-total {
    font-weight: 600;
    color: var(--secondary-color);
}

.cart-quantity {
    width: 80px;
    text-align: center;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 5px;
}

.btn-remove {
    background: none;
    border: none;
    color: var(--secondary-color);
    transition: var(--transition);
}

.btn-remove:hover {
    transform: scale(1.1);
}

.cart-summary {
    background: white;
    border-radius: 12px;
    padding: 25px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.summary-total {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.btn-checkout {
    width: 100%;
    background: var(--success-color);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 8px;
    font-weight: 600;
    margin-top: 20px;
}

/* --- Pagination --- */
.pagination-wrapper {
    margin: 40px 0;
}

.pagination {
    justify-content: center;
}

.page-link {
    color: var(--primary-color);
    border: none;
    margin: 0 5px;
    border-radius: 8px;
    transition: var(--transition);
}

.page-link:hover {
    background: var(--secondary-color);
    color: white;
}

.active .page-link {
    background: var(--secondary-color);
    color: white;
}

/* --- Footer --- */
.main-footer {
    background: #f5f5f7;
    color: #000000e0;
    padding: 50px 0 20px;
    margin-top: 60px;
}

.footer-title {
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
    font-family: arial;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: #00000029;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
    font-size: 12px;
    color: #000000b8;
    font-family: Arial;
}

.footer-links a {
    color: #0000008f;
    text-decoration: none;
    transition: var(--transition);
    font-size: 12px;
    font-family: Arial;
}

.footer-links a:hover {
    color: #0000008f;
    padding-left: 5px;
    border-bottom:1px solid #0000008f ;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    margin-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* --- Breadcrumbs --- */
.breadcrumb-wrapper {
    background: white;
    padding: 15px 0;
    margin-bottom: 30px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.breadcrumb {
    margin: 0;
    background: transparent;
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb-item.active {
    color: var(--secondary-color);
}

/* --- Animations --- */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card {
    animation: fadeIn 0.5s ease-out;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .product-image {
        height: 200px;
    }
    
    .product-title {
        font-size: 1rem;
        min-height: auto;
    }
    
    .current-price {
        font-size: 1.5rem;
    }
    
    .cart-item-image {
        width: 60px;
        height: 60px;
    }
    
    .main-image {
        height: 250px;
    }
    
    .characteristics-table td:first-child {
        width: 120px;
    }
}

@media (max-width: 576px) {
    .product-card {
        margin-bottom: 20px;
    }
    
    .cart-item {
        flex-direction: column;
        text-align: center;
    }
    
    .thumbnail {
        width: 60px;
        height: 60px;
    }
}

/* ============================================
   Ð”Ð˜ÐÐÐœÐ˜Ð§Ð•Ð¡ÐšÐ˜Ð• Ð¡Ð¢Ð˜Ð›Ð˜ Ð”Ð›Ð¯ JS ÐšÐžÐœÐŸÐžÐÐ•ÐÐ¢ÐžÐ’
============================================ */

/* Loader */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-loader .spinner-border {
    width: 60px;
    height: 60px;
    color: var(--secondary-color);
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1100;
}

.toast {
    min-width: 300px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Scroll to Top */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.scroll-to-top:hover {
    background: var(--secondary-color);
    transform: translateY(-3px);
}

/* Form Validation */
.is-invalid {
    border-color: #dc3545 !important;
}

.invalid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #dc3545;
}

.has-error .form-control,
.has-error .form-select {
    border-color: #dc3545;
}

/* Loading Button */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #fff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}

/* Wishlist Active */
.btn-wishlist.active {
    background: var(--secondary-color);
    color: white;
}

.btn-wishlist.active i {
    color: white;
}

/* Cart Icon Animation */
.cart-icon {
    position: relative;
}

.cart-icon.animate {
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Lazy Load Images */
img.lazy {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img.lazy-loaded {
    opacity: 1;
}

/* Quantity Controls */
.quantity-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-qty {
    width: 32px;
    height: 32px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--light-color);
    border: 1px solid #dee2e6;
    transition: all 0.2s ease;
}

.btn-qty:hover {
    background: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* Sticky Sidebar */
.sticky-sidebar {
    position: sticky;
    top: 100px;
}

/* Animations on Scroll */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .toast-container {
        bottom: 70px;
        right: 10px;
        left: 10px;
    }
    
    .toast {
        width: auto;
        min-width: auto;
    }
    
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
    }
    
    .sticky-sidebar {
        position: static;
    }
}

/* Price Slider Customization */
.noUi-connect {
    background: var(--secondary-color);
}

.noUi-handle {
    border-radius: 50%;
    background: var(--secondary-color);
    border: 2px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.noUi-handle:before,
.noUi-handle:after {
    display: none;
}

/* Quick View Modal */
.quick-view-modal .modal-dialog {
    max-width: 900px;
}

.quick-view-modal .modal-content {
    border-radius: 12px;
}

/* Compare Products */
.compare-table {
    background: white;
    border-radius: 12px;
    overflow-x: auto;
}

.compare-table table {
    width: 100%;
    min-width: 600px;
}

.compare-table td {
    padding: 15px;
    border-bottom: 1px solid #dee2e6;
}

.compare-table tr:last-child td {
    border-bottom: none;
}

main {
    background: white;
}


footer.main-footer p.text-muted {font-size:12px;}

.category-card {
    color:black;
    font-weight:300;
    display:block;
    height:150px;
    border-radius:4px;
   
    transition: all 1s ease;
}
.category-card:hover{
    background-color:#f5f5f7;
    padding:2em;
    border-radius:50vh;
    transition: all 1s ease;
}

a.category-card {
 font-weight:300;
 text-decoration: none;
}

.category-title {
 font-weight:300;
 text-decoration: blink;
 font-size: 1rem;
}
 
 
.product-card img {
    width:100%;
    text-align:center;
    align-content:center;
}

.card-title {
    color:black;
    text-decoration:none;
    font-weight:300;
    font-size:medium;
    text-align: center;
}

/* Категория товаров  */ 

.category-banner{
    position:relative;

    height:120px;
    overflow:hidden;
    display:flex;
    align-items:center;
    background:var(--apple-bg);
    border:1px solid var(--apple-hairline);
    border-radius: 84px;
    box-shadow:0 2px 8px rgba(0,0,0,.05), 0 14px 28px rgba(0,0,0,.045);
    cursor:pointer;
    transition:box-shadow .3s ease, transform .3s ease;
  }
  .category-banner:hover{
    box-shadow:0 4px 12px rgba(0,0,0,.07), 0 18px 36px rgba(0,0,0,.06);
    transform:translateY(-1px);
  }

  .text-block{
    position:relative;
    z-index:1;
    padding-left:32px;
  }
  .text-block h1{
    color:var(--apple-text);
    font-size:28px;
    font-weight:600;
    letter-spacing:-.4px;
    line-height:1.2;
    margin-bottom:4px;
  }
  .text-block p{
    color:var(--apple-text-secondary);
    font-size:14px;
    font-weight:400;
    letter-spacing:-.1px;
  }

  .icon-wrap{
    position:absolute;
    z-index:1;
    right:36px;
    top:50%;
    transform:translateY(-50%);
  }
  .badge{
    position:relative;
    width:66px;
    height:66px;
    border-radius:18px;
    background:linear-gradient(135deg, var(--apple-blue) 0%, var(--apple-indigo) 55%, var(--apple-purple) 100%);
    display:flex;
    align-items:center;
    justify-content:center;
    box-shadow:0 6px 14px rgba(94,92,230,.35);
    transition:transform .3s ease;
  }
  .category-banner:hover .badge{
    transform:scale(1.05);
  }
  .badge .bi-cpu{
    font-size:30px;
    color:#ffffff;
  }
  .pill-badge{
    position:absolute;
    right:-8px;
    bottom:-8px;
    width:28px;
    height:28px;
    border-radius:50%;
    background:#ffffff;
    border:1px solid var(--apple-hairline);
    display:flex;
    align-items:center;
    justify-content:center;
    box-shadow:0 2px 6px rgba(0,0,0,.12);
  }
  .pill-badge .bi-capsule-pill{
    font-size:13px;
    color:var(--apple-indigo);
    transform:rotate(-25deg);
  }
  
  .main-back {
    /* position: sticky; */
    background-image: linear-gradient(to left, rgba(255, 255, 255, 0.85), rgb(255 255 255 / 100%), rgba(255, 255, 255, 0.85)), url(/assets/images/pattern.png);
    /* background-repeat:no-repeat; */
}
@media (max-width: 767.98px) {
    .category-banner {
        height: auto; /* Позволяем баннеру растягиваться под контент */
        min-height: 100px;
        padding: 20px 15px;
        flex-direction: row; /* Оставляем в ряд, но с правильным распределением */
        justify-content: space-between;
    }

    .text-block {
        padding-left: 10px; /* Уменьшаем отступ слева */
        padding-right: 70px; /* Резервируем место под иконку, чтобы текст не наезжал */
        flex: 1;
    }

    .text-block h1 {
        font-size: 20px; /* Уменьшаем заголовок */
        margin-bottom: 2px;
    }

    .text-block p {
        font-size: 13px; /* Чуть меньше шрифт описания */
        line-height: 1.3;
        display: -webkit-box; /* Ограничиваем описание 2 строками, чтобы не раздувать баннер */
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .icon-wrap {
        right: 15px; /* Прижимаем иконку ближе к краю */
        /* Позиционирование остается абсолютным, но за счет padding-right в text-block наезда нет */
    }

    .badge {
        width: 50px; /* Уменьшаем размер иконки */
        height: 50px;
        border-radius: 12px;
    }

    .badge .bi-cpu {
        font-size: 22px; /* Уменьшаем саму иконку процессора */
    }

    .pill-badge {
        width: 22px;
        height: 22px;
        right: -5px;
        bottom: -5px;
    }

    .pill-badge .bi-capsule-pill {
        font-size: 10px;
    }
}

/* Для совсем маленьких экранов (меньше 360px) */
@media (max-width: 359px) {
    .text-block h1 {
        font-size: 18px;
    }
    .icon-wrap {
        display: none; /* На экстремально узких экранах лучше скрыть иконку, чтобы текст читался */
    }
    .text-block {
        padding-right: 10px;
    }
}

/* Теперь применяем переменные в стилях */
.btn-primary {
    color: var(--btn-color);
    background-color: var(--btn-bg);
    border-color: var(--btn-border-color);
    /* базовые отступы и прочее — по желанию */
    border-width: 1px;
    border-style: solid;
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    border-radius: 1.25rem;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s, box-shadow 0.15s;
}

.btn-primary:hover {
    color: var(--btn-hover-color);
    background-color: var(--btn-hover-bg);
    border-color: var(--btn-hover-border-color);
}

.btn-primary:focus {
    box-shadow: 0 0 0 0.25rem rgba(var(--btn-focus-shadow-rgb), 0.5);
    outline: 0;
}

.btn-primary:active,
.btn-primary.active {
    color: var(--btn-active-color);
    background-color: var(--btn-active-bg);
    border-color: var(--btn-active-border-color);
    box-shadow: var(--btn-active-shadow);
}

.btn-primary:disabled,
.btn-primary.disabled {
    color: var(--btn-disabled-color);
    background-color: var(--btn-disabled-bg);
    border-color: var(--btn-disabled-border-color);
    pointer-events: none;
    opacity: 0.65;
}

.text-primary {
    color: #507eaf !important; /* тот же цвет */
}
html, body {
    height: 100%;
    margin: 0;
}
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
.wrapper {
    flex: 1 0 auto;   /* растягивается, чтобы занять всё свободное место */
    display: flex;
    flex-direction: column;
}
.wrapper > main {
    flex: 1 0 auto;   /* контент внутри тоже растягивается, если нужно */
}
.main-footer {
    flex-shrink: 0;   /* футер не сжимается */
}

a.category-row {text-decoration:none;}
strong {    word-wrap: anywhere; }