/* =========================================
   1. МЕГА-МЕНЮ (HEADER)
   ========================================= */
.glory-catalog-wrapper { position: relative; display: inline-block; }
.glory-btn-catalog {
    background: #333; color: #fff; text-decoration: none; padding: 10px 22px;
    font-size: 14px; font-weight: 600; text-transform: uppercase; cursor: pointer;
    display: flex; align-items: center; gap: 12px; border-radius: 4px; transition: 0.3s;
}
.glory-btn-catalog:hover { background: #444; color: #fff; }
.glory-burger i { display: block; width: 18px; height: 2px; background: #fff; margin: 3px 0; }

.glory-mega-dropdown {
    width: 280px; transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden; display: none; position: absolute; top: 100%; left: 0;
    background: #fff; z-index: 9999; border-top: 3px solid #7b6a96;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1); margin-top: 5px; border-radius: 0 0 4px 4px;
}
.glory-mega-inner { display: flex; min-height: 400px; }

/* Сайдбар (завжди 280px) */
.glory-mega-sidebar {
    width: 280px; min-width: 280px; background: #f8f8f8; list-style: none !important;
    padding: 10px 0 !important; margin: 0 !important; border-right: 1px solid #eee;
}
.glory-parent-item { margin: 0 !important; }
.glory-parent-item a {
    display: block; padding: 12px 25px; color: #333; text-decoration: none; font-size: 15px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: 0.2s;
}
.glory-parent-item.active, .glory-parent-item:hover { background: #fff; }
.glory-parent-item.active a, .glory-parent-item:hover a { color: #7b6a96 !important; font-weight: 700; }

/* Права панель (ховається, якщо меню вузьке) */
.glory-mega-content { display: none; flex-grow: 1; padding: 30px; opacity: 0; transition: opacity 0.2s ease; }
.glory-mega-dropdown.is-wide { width: 950px; }
.glory-mega-dropdown.is-wide .glory-mega-content { display: block; opacity: 1; }

.glory-subcat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 25px; }
.glory-subcat-card { text-align: center; text-decoration: none; color: #333; transition: 0.3s; display: block; }
.subcat-img-wrap { height: 90px; margin-bottom: 12px; display: flex; align-items: center; justify-content: center; }
.subcat-img-wrap img { max-width: 80px; max-height: 80px; object-fit: contain; transition: 0.3s; }
.subcat-title { font-size: 13px; font-weight: 600; color: #444; display: block; }
.glory-subcat-card:hover .subcat-title { color: #7b6a96; }
.glory-subcat-card:hover img { transform: scale(1.05); }
/********************page term tax***************************/
/* =========================================
   КАТАЛОГ ТА КАРТКИ ТОВАРІВ / КАТЕГОРІЙ
   ========================================= */
.glory-archive-page { padding: 30px 0 60px; background: #fff; font-family: 'Open Sans', sans-serif; }

/* Хлібні крихти та заголовки */
.glory-breadcrumbs { margin-bottom: 30px; font-size: 14px; color: #999; }
.glory-breadcrumbs a { color: #666; text-decoration: none; transition: 0.2s; }
.glory-breadcrumbs a:hover { color: #7b6a96; }
.glory-breadcrumbs .sep { margin: 0 8px; color: #ccc; }
.glory-breadcrumbs .current { color: #333; }
.glory-main-title { font-size: 36px; font-weight: 700; margin: 0 0 40px 0; color: #222; }


.glory-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px 20px; }


.glory-item-card a { text-decoration: none; display: block; text-align: left; }


.glory-item-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    margin-bottom: 15px;
    background: #f8f8f8;
}

.glory-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    transition: transform 0.5s ease;
}

/* Заголовок під картинкою */
.glory-item-title {
    font-size: 18px;
    font-weight: 700;
    color: #222;
    margin: 0 0 8px 0;
    line-height: 1.3;
    transition: color 0.2s;
}

/* Посилання "Більше фото ->" */
.glory-item-more {
    font-size: 16px;
    color: #482880; 
    font-weight: 400;
    display: inline-flex;
    align-items: center;
}

.glory-item-more::after {
    content: '→';
    margin-left: 8px;
    font-size: 16px;
    transition: transform 0.3s ease;
}

/* Ефекти при наведенні мишкою */
.glory-item-card:hover .glory-item-img img { transform: scale(1.05); }
.glory-item-card:hover .glory-item-title { color: #7b6a96; }
.glory-item-card:hover .glory-item-more::after { transform: translateX(5px); } 

.glory-cat-description { margin-top: 60px; padding-top: 30px; border-top: 1px solid #eee; color: #555; line-height: 1.6; }

/* Адаптивність */
@media (max-width: 1100px) { .glory-grid { grid-template-columns: repeat(3, 1fr); gap: 30px 20px; } }
@media (max-width: 768px) { 
    .glory-grid { grid-template-columns: repeat(2, 1fr); gap: 25px 15px; } 
    .glory-main-title { font-size: 26px; margin-bottom: 30px; } 
    .glory-item-title { font-size: 16px; }
}
@media (max-width: 480px) {
    .glory-grid { grid-template-columns: 1fr; } 
}



.main-footer {
    margin-top: 15px;
}