/**
 * MLWindow2 Core - Frontend Styles
 *
 * @package MLWindow2_Core
 */

/* ========================================
   Product Badges
   ======================================== */
.mlw-product-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mlw-badge {
    display: inline-block;
    padding: 4px 10px;
    font-family: 'DM Sans', -apple-system, sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 3px;
}

.mlw-badge-sale {
    background-color: #e74c3c;
    color: #ffffff;
}

.mlw-badge-new {
    background-color: #27ae60;
    color: #ffffff;
}

.mlw-badge-featured {
    background-color: #f39c12;
    color: #ffffff;
}

/* ========================================
   Price Wrapper
   ======================================== */
.mlw-price-wrapper {
    display: inline-block;
}

.mlw-price-wrapper del {
    color: #999999;
    font-size: 0.9em;
    margin-right: 8px;
}

.mlw-price-wrapper ins {
    text-decoration: none;
    color: #e74c3c;
    font-weight: 600;
}

/* ========================================
   Product Grid Wrapper
   ======================================== */
.mlw-product-grid-wrapper {
    position: relative;
}

/* ========================================
   Single Product Wrapper
   ======================================== */
.mlw-single-product-wrapper {
    position: relative;
}

/* ========================================
   Menu Featured Products
   ======================================== */
.mlw-menu-product {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 10px;
}

.mlw-menu-product a {
    text-decoration: none;
    color: inherit;
}

.mlw-menu-product img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}

.mlw-menu-product-title {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 4px;
    color: #333333;
}

.mlw-menu-product-price {
    font-size: 12px;
    color: #666666;
}

/* ========================================
   Cart Count Badge
   ======================================== */
.mlw-cart-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    font-size: 11px;
    font-weight: 600;
    color: #ffffff;
    background-color: #000000;
    border-radius: 9px;
}

.mlw-cart-count:empty {
    display: none;
}

/* ========================================
   Category Archive Page
   ======================================== */
.lw-category-archive {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
}

.lw-category-header {
    text-align: center;
    margin-bottom: 40px;
}

.lw-category-eyebrow {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #888;
}

.lw-category-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2.5rem;
    font-weight: 500;
    margin: 12px 0;
    color: #1a1a1a;
}

.lw-category-underline {
    width: 60px;
    height: 2px;
    background: #e85a4f;
    margin: 0 auto 12px;
}

.lw-category-count {
    font-size: 14px;
    color: #666;
}

/* Category Grid */
.lw-category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

@media (max-width: 1024px) {
    .lw-category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .lw-category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .lw-category-grid {
        grid-template-columns: 1fr;
    }
}

/* Category Item */
.lw-category-item {
    text-align: center;
}

.lw-category-image {
    display: block;
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 12px;
    background: #f5f5f5;
}

.lw-category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.lw-category-item:hover .lw-category-image img {
    transform: scale(1.05);
}

/* Hover Icons for Category Archive */
.lw-category-image .mlw-hover-icons {
    position: absolute;
    top: 50%;
    right: -50px;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: right 0.3s ease;
    z-index: 3;
}

.lw-category-item:hover .mlw-hover-icons {
    right: 10px;
}

/* Category Product Title */
.lw-category-product-title {
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    line-height: 1.4;
}

.lw-category-product-title a {
    color: #1a1a1a;
    text-decoration: none;
    transition: color 0.2s;
}

.lw-category-product-title a:hover {
    color: #e85a4f;
}

/* Category Pagination */
.lw-category-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.lw-category-pagination a,
.lw-category-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
}

.lw-category-pagination a:hover {
    border-color: #1a1a1a;
    background: #1a1a1a;
    color: #fff;
}

.lw-category-pagination .current {
    background: #1a1a1a;
    border-color: #1a1a1a;
    color: #fff;
}

/* Category Empty State */
.lw-category-empty {
    text-align: center;
    padding: 60px 20px;
}

.lw-category-empty svg {
    color: #ddd;
    margin-bottom: 20px;
}

.lw-category-empty h2 {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 1.8rem;
    font-weight: 500;
    margin: 0 0 12px;
}

.lw-category-empty p {
    color: #666;
    margin: 0 0 24px;
}

.lw-category-empty .btn-primary {
    display: inline-block;
    padding: 14px 32px;
    background: #1a1a1a;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 4px;
    transition: background 0.3s;
}

.lw-category-empty .btn-primary:hover {
    background: #333;
}

/* ========================================
   Category Showcase (Grid of Categories)
   ======================================== */
.lw-showcase-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px;
}

.lw-showcase-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2rem;
    font-weight: 500;
    text-align: center;
    margin-bottom: 30px;
}

.lw-showcase-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

@media (max-width: 1024px) {
    .lw-showcase-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .lw-showcase-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

.lw-showcase-item {
    text-align: center;
}

.lw-showcase-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.lw-showcase-image-wrap {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 12px;
    background: #f5f5f5;
}

.lw-showcase-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.lw-showcase-item:hover .lw-showcase-image-wrap img {
    transform: scale(1.05);
}

/* Hover Icons for Category Showcase */
.lw-showcase-image-wrap .mlw-hover-icons {
    position: absolute;
    top: 50%;
    right: -50px;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: right 0.3s ease;
    z-index: 3;
}

.lw-showcase-item:hover .mlw-hover-icons {
    right: 10px;
}

.lw-showcase-name {
    font-size: 16px;
    font-weight: 500;
    margin: 0 0 4px;
}

.lw-showcase-count {
    font-size: 13px;
    color: #888;
}
