/* =========================
   GOOGLE FONT
========================= */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

body {
    font-family: 'Poppins', sans-serif;
}


/* =========================
   WRAPPER
========================= */
.mbp-wrapper {
    max-width: 1200px;
    margin: auto;
    padding: 30px 15px;
}


/* =========================
   CONTROLS
========================= */
.mbp-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 25px;
}

#mbp-search,
#mbp-category {
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #ddd;
    min-width: 180px;
    font-size: 14px;
}


/* =========================
   GRID
========================= */
.mbp-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    align-items: stretch;
}


/* =========================
   CARD
========================= */
.mbp-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.3s ease;
    box-shadow: 0 5px 25px rgba(0,0,0,0.07);
}

.mbp-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
}


/* =========================
   IMAGE FIX (MAIN SOLUTION)
========================= */
.mbp-img {
    width: 100%;
    aspect-ratio: 16/9;   /* 🔥 SAME SIZE */
    overflow: hidden;
    background: #ddd;
}

.mbp-img img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;    /* 🔥 NO STRETCH */
    display: block;
}


/* =========================
   CONTENT
========================= */
.mbp-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
}


/* =========================
   META BADGES
========================= */
.mbp-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}

.mbp-meta span {
    background: #f1f5f9;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    color: #555;
}


/* =========================
   TITLE
========================= */
.mbp-content h3 {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.4;
}


/* =========================
   TEXT
========================= */
.mbp-content p {
    font-size: 13px;
    color: #666;
    flex: 1;
    line-height: 1.6;
}


/* =========================
   BUTTON
========================= */
.mbp-btn {
    margin-top: 12px;
    padding: 8px 14px;
    font-size: 13px;
    border-radius: 8px;
    background: #2563eb;
    color: #fff;
    text-decoration: none;
    transition: 0.3s;
}

.mbp-btn:hover {
    background: #1e40af;
}


/* =========================
   LOAD MORE BUTTON
========================= */
#mbp-load-more {
    display: block;
    margin: 35px auto;
    padding: 10px 25px;
    border-radius: 10px;
    border: none;
    background: #2563eb;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
}


/* =========================
   DARK MODE
========================= */
.mbp-dark {
    background: #020617;
    color: #e2e8f0;
}

.mbp-dark .mbp-card {
    background: #0f172a;
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.mbp-dark .mbp-meta span {
    background: #1e293b;
    color: #cbd5f5;
}

.mbp-dark .mbp-content p {
    color: #94a3b8;
}

.mbp-dark input,
.mbp-dark select {
    background: #0f172a;
    border: 1px solid #334155;
    color: #fff;
}
/* =========================
   TOP CONTROL BAR (NEW UI)
========================= */
.mbp-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 25px;
    padding: 12px;
    border-radius: 12px;
    background: #f8fafc;
}

/* LEFT SIDE (Search + Category) */
.mbp-controls-left {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* INPUT & SELECT */
#mbp-search,
#mbp-category {
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid #ddd;
    font-size: 14px;
    min-width: 180px;
}

/* DARK MODE BUTTON */
#mbp-dark-toggle {
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    background: #2563eb;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    transition: 0.3s;
}

#mbp-dark-toggle:hover {
    background: #1e40af;
}

/* =========================
   DARK MODE CONTROL BAR
========================= */
.mbp-dark .mbp-controls {
    background: #0f172a;
}

.mbp-dark #mbp-search,
.mbp-dark #mbp-category {
    background: #1e293b;
    border: 1px solid #334155;
    color: #fff;
}

.mbp-dark #mbp-dark-toggle {
    background: #38bdf8;
    color: #000;
}






/* =========================
  singel.php
========================= */


/* ======================
   HERO IMAGE FIXED SIZE
====================== */
.mbp-single-hero {
    width: 100%;
    height: 400px;          /* fixed height */
    overflow: hidden;
    border-radius: 12px;
}

.mbp-single-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;       /* fill container without stretching */
}

/* ======================
   CONTENT IMAGES FIXED
====================== */
.mbp-content img {
    width: 100%;
    height: 300px;           /* fixed height for content images */
    object-fit: cover;
    border-radius: 12px;
    margin: 20px 0;
}

/* ======================
   SIDEBAR RECENT POST THUMBNAILS
====================== */
.mbp-recent-posts img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}

/* ======================
   POST CARD + SIDEBAR LAYOUT
====================== */
.mbp-single-container {
    display: grid;
    grid-template-columns: 2.5fr 1fr;
    gap: 30px;
    max-width: 1100px;
    margin: -100px auto 50px;
    padding: 0 20px;
}

.mbp-post-card {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.mbp-sidebar .mbp-widget {
    background: #fff;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.06);
}

/* ======================
  Product
====================== */




.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.product-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    text-align: center;
    transition: 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
}

.product-image {
    width: 100%;
    height: <?php echo get_option('product_image_height', 300); ?>px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sale-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #a8aa00;
    color: #fff;
    padding: 5px 10px;
    border-radius: 50px;
    font-weight: 600;
}

.product-title {
    font-size: 16px;
    color: #333;
    margin: 10px 0;
}

.product-price .old-price {
    text-decoration: line-through;
    color: #888;
    margin-right: 10px;
}

.product-price .new-price {
    font-weight: 600;
    color: #e60023;
}

.add-to-cart {
    padding: 8px 16px;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    text-decoration: none;
    display: inline-block;
    margin-top: 10px;
}







/* ======================
   DARK MODE
====================== */
body.dark-mode .mbp-post-card,
body.dark-mode .mbp-sidebar {
    background: #1e1e1e;
    color: #ddd;
}

body.dark-mode .mbp-content p {
    color: #ccc;
}

/* ======================
   RESPONSIVE
====================== */
@media(max-width:768px){
    .mbp-single-container {
        grid-template-columns: 1fr;
        margin-top: 20px;
    }
}









/* =========================
   RESPONSIVE FIX
========================= */
@media (max-width: 768px) {

    .mbp-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .mbp-controls-left {
        width: 100%;
    }

    #mbp-search,
    #mbp-category {
        width: 100%;
    }

    #mbp-dark-toggle {
        width: 100%;
    }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 992px) {
    .mbp-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .mbp-grid {
        grid-template-columns: 1fr;
    }
}