/* assets/css/bpmp-style.css */
h3 {
    padding: 0 0 12px 0;
}

.bpmp-my-listings-list {
    list-style: none;
    padding-left: 0;
}
.bpmp-listing-item-my {
    display: flex;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}
.bpmp-listing-thumbnail-my {
    margin-right: 15px;
    flex-shrink: 0;
}
.bpmp-listing-thumbnail-my img {
    width: 80px; /* Adjust size */
    height: 80px;
    object-fit: cover;
}
.bpmp-listing-details-my h4 {
    margin-top: 0;
}
.bpmp-listing-item-my .item-button {
	margin-right: 5px;
	font-size: 0.9em;
	padding: 6px 12px;
	margin-top: 12px;
}

.bpmp-edit-button:hover {
	background-color: #fe5dab !important;
	box-shadow: var(--bpmp-box-shadow, 0 2px 5px rgba(0, 0, 0, 0.2));
}

.bpmp-listings-shortcode-wrap {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}
.bpmp-listing-item-shortcode {
    border: 1px solid #ddd;
    padding: 10px;
}
.bpmp-listing-item-shortcode img {
    max-width: 100%;
    height: auto;
    margin-bottom: 10px;
}
.bpmp-listing-item-shortcode h4 {
    margin-top: 0;
    font-size: 1.1em;
}
.bpmp-price {
    font-weight: bold;
    color: green;
}
span.bpmp-status-text-dynamic {
    font-weight: normal;
    font-size: 0.9em;
    color: #777;
}

/* --- CSS Variables (Optional Base Palette) --- */
:root {
    --bpmp-primary-color: #ff037e; /* Facebook Blue */
    --bpmp-secondary-color: #42B72A; /* Facebook Green (can be used for "Available") */
    --bpmp-background-color: #F0F2F5; /* Light Gray Page Background */
    --bpmp-card-background-color: #FFFFFF; /* White Card Background */
    --bpmp-text-primary-color: #050505; /* Dark Text */
    --bpmp-text-secondary-color: #65676B; /* Gray Text */
    --bpmp-border-color: #CED0D4;
    --bpmp-border-radius: 8px;
    --bpmp-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Apply a background to the body if these pages are full-width and not using Elementor Theme Builder for the page background */
/* You might need to target a more specific Elementor wrapper if using Theme Builder for the page template */
body.post-type-archive-bpmp_listing,
body.single-bpmp_listing {
    background-color: var(--bpmp-background-color);
}

/* --- General Helper for Buttons (if not already styled by theme) --- */
.bpmp-button,
.button.bpmp-view-details-button, /* Targeting existing button class + new class */
.button.bpmp-contact-seller-button {
    width: 250px;
    display: inline-block;
    padding: 10px 18px;
    border-radius: var(--bpmp-border-radius);
    font-weight: bold;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: background-color 0.2s ease;
}

.bpmp-button-primary,
.button.bpmp-view-details-button { /* Example for primary action */
    background-color: var(--bpmp-primary-color);
    color: #fff;
}
.bpmp-button-primary:hover,
.button.bpmp-view-details-button:hover {
    background-color: #fe5dab; /* Darker blue */
    color: #fff;
}

.button.bpmp-contact-seller-button { /* Example for secondary or different action */
    width: 250px;
    background-color: #ff037e;
    color: white;
    align-self: center;
}
.button.bpmp-contact-seller-button:hover {
    background-color: #f765ac;
}

/* Consistent container for content within Hello Elementor if templates are full width */
/* This assumes your template files use a main#content.site-main structure */
main#content.site-main {
    max-width: 1100px; /* Or your preferred max width */
    margin: 20px auto; /* Center it and add some top/bottom margin */
    padding: 0 15px; /* Add some side padding */
}

/* --- Archive Page: Marketplace Listing Grid --- */
.post-type-archive-bpmp_listing .page-header {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--bpmp-border-color);
}

.post-type-archive-bpmp_listing .page-header .entry-title {
    font-size: 2em;
    color: var(--bpmp-text-primary-color);
}

.bpmp-archive-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); /* Default: min 200px width */
    gap: 16px; /* Space between cards */
}

/* Individual Listing Card in Archive */
.bpmp-archive-item {
    background-color: var(--bpmp-card-background-color);
    border-radius: var(--bpmp-border-radius);
    box-shadow: var(--bpmp-box-shadow);
    display: flex;
    flex-direction: column;
    overflow: hidden; /* Ensures border-radius applies to images */
    transition: box-shadow 0.2s ease;
}

.bpmp-archive-item:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.15), 0 8px 16px rgba(0,0,0,0.1);
}

.bpmp-archive-item .bpmp-item-thumbnail {
    width: 100%;
    padding-top: 100%; /* Creates a 1:1 aspect ratio for the image container */
    position: relative;
    background-color: #f0f0f0; /* Placeholder background */
}

.bpmp-archive-item .bpmp-item-thumbnail a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.bpmp-archive-item .bpmp-item-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image covers the area without distortion */
    display: block;
}

.bpmp-archive-item .bpmp-item-content {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* Allows content to fill space, pushing button to bottom */
}

.bpmp-archive-item .entry-header {
    margin-bottom: 8px;
}

.bpmp-archive-item .entry-title {
    font-size: 1.4em;
    margin: 0 0 4px 0;
    padding-top: 12px;
    color: var(--bpmp-text-primary-color);
    line-height: 1.3;
    /* Limit title to 2 lines with ellipsis */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.6em; /* approx 2 lines */
}

.bpmp-archive-item .entry-title a {
    text-decoration: none;
    color: inherit;
}

.bpmp-archive-item .entry-title a:hover {
    text-decoration: underline;
}

.bpmp-archive-item .bpmp-item-price {
    font-size: 1.2em;
    font-weight: bold;
    color: var(--bpmp-text-primary-color);
    margin-bottom: 6px;
}

.bpmp-archive-item .bpmp-item-status {
    display: flex;
    flex-direction: column;
    font-size: 1em;
    margin-bottom: 8px;
}

.bpmp-item-seller {
    display: flex;
    flex-direction: column;
}

.bpmp-item-date-published {
    display: flex;
    flex-direction: column;
    margin-bottom: 32px;
}

.bpmp-archive-item .bpmp-item-status .status-available {
    color: var(--bpmp-secondary-color); /* Green */
    font-weight: bold;
}

.bpmp-archive-item .bpmp-item-status .status-sold {
    color: #E02828; /* Red-ish */
    font-weight: bold;
}

.bpmp-archive-item .entry-summary {
    font-size: 0.9em;
    color: var(--bpmp-text-secondary-color);
    line-height: 1.4;
    margin-bottom: 12px;
    flex-grow: 1; /* Pushes button down */
    /* Limit excerpt to a few lines if desired */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bpmp-archive-item .bpmp-view-details-button {
    margin-top: auto; /* Pushes button to the bottom of the card content */
    margin-bottom: 12px;
    width: 90%;
    padding: 8px 12px;
    font-size: 0.95em;
}

/* Responsive Grid for Archive */
@media (min-width: 600px) {
    .bpmp-archive-container {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }
}
@media (min-width: 900px) {
    .bpmp-archive-container {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

/* Pagination styling (basic, your theme might have its own) */
.navigation.pagination {
    margin-top: 30px;
    text-align: center;
}
.navigation.pagination .nav-links .page-numbers {
    padding: 5px 10px;
    border: 1px solid var(--bpmp-border-color);
    margin: 0 2px;
    text-decoration: none;
    border-radius: 4px;
}
.navigation.pagination .nav-links .page-numbers.current,
.navigation.pagination .nav-links .page-numbers:hover {
    background-color: var(--bpmp-primary-color);
    color: #fff;
    border-color: var(--bpmp-primary-color);
}



.bpmp-archive-item .bpmp-item-excerpt {
    font-size: 0.9em;
    color: var(--bpmp-text-secondary-color, #555); /* Use variable or fallback */
    line-height: 1.4;
    margin-top: 6px; /* Space below price */
    margin-bottom: 32px; /* Space above meta info or button */
    /* Optional: Limit lines if wp_trim_words isn't enough or for visual consistency */
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Show max 2 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.8em; /* Approx 2 lines height, adjust based on font-size and line-height */
}

/* --- Styles for Shortcode Header Navigation Buttons --- */
.bpmp-shortcode-header-nav {
    display: flex; /* Use flexbox for alignment */
    justify-content: flex-end; /* Align buttons to the right */
    gap: 10px; /* Space between buttons */
    margin-bottom: 32px !important; /* Space below the buttons, before the listings grid */
}

.bpmp-nav-button {
    background-color: #ff037e;
    color: #ffffff;
    padding: 12px 24px;
    margin-bottom: 12px;
    font-size: 1.1em;
    font-weight: normal;
    text-decoration: none;
    border-radius: 12px;
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
}

h2.mis-publicaciones-title {
    font-weight: bold !important;
}

hr.listings-separator{
    margin-bottom: 28px !important;
}

.new-listing-button {
    background-color: #ff037e;
    color: #ffffff;
    padding: 12px 24px;
    font-size: 1.1em;
    font-weight: normal;
    text-decoration: none;
    border-radius: 12px;
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
}

.new-listing-button:hover {
    background-color: #ff6eb4;
    color: #ffffff;
}

input.acf-button{
	background-color: #ff037e;
    color: #ffffff;
    padding: 12px 24px;
    font-size: 1.1em;
    font-weight: normal;
    text-decoration: none;
    border-radius: 12px;
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
}

input.acf-button:hover {
    background-color: #ff6eb4;
    color: #ffffff;
}

.bpmp-nav-button:hover {
    background-color: #f96cb0; /* Slightly lighter on hover */
    color: #ffffff !important;
}

/* Responsive adjustments for the buttons if needed */
@media (max-width: 600px) {
    .bpmp-shortcode-header-nav {
        flex-direction: column; /* Stack buttons on small screens */
        align-items: stretch; /* Make buttons full width of their container */
    }
    .bpmp-nav-button {
        text-align: center; /* Center text in stacked buttons */
        margin-bottom: 5px; /* Add space if they stack */
    }
    .bpmp-nav-button:last-child {
        margin-bottom: 0;
    }
}

/*
ACF Frontend Form Styles - Specifically for Marketplace Listing Edit/Create
*/

/* Target the main wrapper of your specific ACF Gallery field on any acf_form.
   Make sure 'bpmp_media_gallery' is the exact "Field Name" of your gallery field. */
.acf-form .acf-field-gallery[data-name="bpmp_media_gallery"] {
    margin-bottom: 30px; /* << ADJUST THIS VALUE AS NEEDED. Try 20px, 30px, 40px, etc. */
    clear: both; /* Good practice if elements inside might be floated */
    padding-bottom: 10px; /* Adds a little space within the field's bottom border before the margin starts */
}

/* The area that contains the image thumbnails */
.acf-form .acf-field-gallery[data-name="bpmp_media_gallery"] .acf-gallery-attachments {
    margin-bottom: 15px; /* Add some space below the thumbnails, before the "Add to gallery" link */
}

/* The uploader area (where the "Add to Gallery" button/link resides) */
.acf-form .acf-field-gallery[data-name="bpmp_media_gallery"] .acf-gallery-uploader {
    border: 2px dashed #ccc;
    padding: 30px;
    text-align: center;
}


/* Specifically target the submit button wrapper of the acf_form if it's too close */
.acf-form .acf-form-submit {
    margin-top: 25px; /* Add space ABOVE the submit button section */
    clear: both; /* Ensure it clears any floated elements above it */
}


/*
==========================================================================
Marketplace Filter Bar Styles
==========================================================================
*/
/*
==========================================================================
Marketplace Filter Bar Styles (Updated for Search)
==========================================================================
*/
.bpmp-filter-bar {
    margin-bottom: 48px;
    background-color: #f9f9f9;
    padding: 20px 25px;
    border-radius: var(--bpmp-border-radius, 8px);
    border: 1px solid var(--bpmp-border-color, #e0e0e0);
}

.bpmp-filters-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end; /* Aligns items to the bottom, useful for labels */
    gap: 20px;
}

.bpmp-filter-item {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.bpmp-filter-item label {
    margin-bottom: 8px;
    font-weight: bold;
    font-size: 0.9em;
    color: var(--bpmp-text-secondary-color, #555);
}

.bpmp-filter-item input[type="search"],
.bpmp-filter-item select {
    padding: 10px 12px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 1em;
    width: 100%;
    box-sizing: border-box;
    min-height: 46px;
}

.bpmp-filter-search {
    flex-basis: 40%; /* Give search input more width */
}

.bpmp-filter-category {
    flex-basis: 30%; /* Give category select a bit less */
}

.bpmp-filter-submit {
    flex-grow: 0; /* Prevent the submit button from growing */
    flex-shrink: 0;
}

.bpmp-filter-submit .button {
    padding: 10px 25px;
    font-size: 1em;
    font-weight: bold;
    background-color: var(--bpmp-primary-color, #ff037e);
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}
.bpmp-filter-submit .button:hover {
    background-color: #fe5dab;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
    .bpmp-filters-form {
        flex-direction: column;
        align-items: stretch; /* Make all items full-width */
    }
    .bpmp-filter-item {
        flex-basis: auto; /* Reset basis on smaller screens */
    }
}

.bpmp-category-filter-form label {
    margin-right: 10px;
    font-weight: bold;
    color: var(--bpmp-text-secondary-color, #555);
}

.bpmp-category-filter-form select {
    min-width: 200px;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ccc;
}

/* Hide the submit button if JavaScript is enabled */
.bpmp-category-filter-form button {
    display: none;
}
/* Show the button only if JavaScript is disabled */
.no-js .bpmp-category-filter-form button {
    display: inline-block;
}

.bpmp-item-actions {
    text-align: center;
}

/*
==========================================================================
SINGLE LISTING PAGE STYLES
==========================================================================
*/
.bpmp-single-listing-article {
    background-color: var(--bpmp-card-background-color);
    padding: 0;
    border-radius: var(--bpmp-border-radius);
    box-shadow: var(--bpmp-box-shadow);
    overflow: hidden;
    margin-top: 75px;
    max-width: 80%;
}

.bpmp-single-listing-page {
    display: flex;
    justify-content: center;
}

.bpmp-single-listing-content-wrapper {
    padding: 20px 25px;
}
.listing-title-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
}
.listing-title-header .entry-title {
    font-size: 2em;
}
.bpmp-listing-meta {
    margin-bottom: 25px;
    padding: 15px;
    background-color: #f7f7f7;
    border-radius: var(--bpmp-border-radius);
}
.bpmp-listing-meta > div {
    margin-bottom: 10px;
}
.bpmp-listing-meta .bpmp-price {
    font-size: 1em;
    font-weight: bold;
}
.bpmp-listing-description h3 {
    font-size: 1.8em;
    margin-bottom: 10px;
    border-bottom: 1px solid var(--bpmp-border-color);
    padding-bottom: 5px;
}
.entry-footer {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--bpmp-border-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* --- Single Listing Gallery, Featured Image, and Placeholder --- */
.bpmp-single-gallery-wrapper {
    width: 100%;
    margin: 0; /* Remove margin so it's flush with article edges */
    background-color: #000;
}
.bpmp-single-listing-swiper,
.bpmp-featured-image-wrapper,
.bpmp-placeholder-image-wrapper {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    max-height: 70vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #111;
}
.bpmp-single-listing-swiper img,
.bpmp-featured-image-wrapper img,
.bpmp-placeholder-image-wrapper img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.bpmp-single-listing-swiper .swiper-slide {
    background: #fff;
}

/* --- Swiper Navigation --- */
.bpmp-single-listing-swiper .swiper-button-next,
.bpmp-single-listing-swiper .swiper-button-prev {
    color: #ff037e;
    --swiper-navigation-size: 40px;
}
.bpmp-single-listing-swiper .swiper-pagination-bullet-active {
    background: var(--bpmp-primary-color);
}

/* SINGLE LISTING IMAGE LIGHTBOX */
.basicLightbox {
    top: 30px !important; 
}

/*
==========================================================================
Frontend Listing Edit/Create Form (ACF Form) Styles
==========================================================================
*/

/* Main wrapper for the ACF form */
.acf-form {
    background-color: var(--bpmp-card-background-color, #FFFFFF);
    padding: 30px; /* Internal padding for the form container */
    border-radius: var(--bpmp-border-radius, 8px);
    box-shadow: var(--bpmp-box-shadow, 0 1px 2px rgba(0, 0, 0, 0.1));
    margin-top: 30px; /* Space above the form */
    max-width: 800px; /* Max width for the form container */
    margin-left: auto;
    margin-right: auto; /* Center the form */
    box-sizing: border-box; /* Include padding/border in width */
}

.acf-form h3 { /* Style for "Create New Marketplace Listing" / "Edit Marketplace Listing" heading */
    font-size: 1.8em;
    color: var(--bpmp-text-primary-color, #050505);
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--bpmp-border-color, #ddd);
    text-align: center; /* Center the form heading */
}

h3.new_listing_title {
	font-size: 2em;
	font-weight: bold;
	color: #ff037e;
	margin-bottom: 32px;
}

h1.new_listing_images {
	margin-bottom: 12px;
	font-size: 1.2em;
}


/* Individual ACF field wrappers */
.acf-form .acf-field {
    margin-bottom: 20px; /* Space between fields */
    padding: 0; /* Remove default ACF field padding if present */
    clear: both; /* Ensure fields clear any floats */
}

/* Labels for each field */
.acf-form .acf-label {
    margin-bottom: 8px;
}
.acf-form .acf-label label {
    font-weight: bold;
    color: var(--bpmp-text-primary-color, #050505);
    font-size: 1.1em;
}
.acf-form .acf-label label .acf-required { /* Style for the required asterisk */
    color: #e02828; /* Red color */
    margin-left: 4px;
}


/* Input fields (text, number, textarea, select) */
.acf-form .acf-input input[type="text"],
.acf-form .acf-input input[type="number"],
.acf-form .acf-input input[type="email"],
.acf-form .acf-input input[type="password"],
.acf-form .acf-input textarea,
.acf-form .acf-input select {
    width: 100%; /* Full width inputs */
    padding: 10px 12px;
    border: 1px solid var(--bpmp-border-color, #ccc);
    border-radius: 4px;
    font-size: 1em;
    color: var(--bpmp-text-primary-color, #050505);
    background-color: var(--bpmp-card-background-color, #fff);
    box-sizing: border-box; /* Include padding and border in width */
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.acf-form .acf-input input:focus,
.acf-form .acf-input textarea:focus,
.acf-form .acf-input select:focus {
    border-color: var(--bpmp-primary-color, #ff037e);
    box-shadow: 0 0 0 2px rgba(var(--bpmp-primary-color-rgb), 0.2); /* Adjust based on your primary color variable */
    outline: none;
}

/* Specific styling for the 'Taxonomy' field (Category dropdown/checkboxes) */
.acf-form .acf-field[data-type="taxonomy"] .acf-input {
    /* Adjust specific layout for taxonomy if needed */
}
.acf-form .acf-field[data-type="taxonomy"] .acf-input ul { /* List of checkboxes */
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex; /* Display checkboxes in a row if desired */
    flex-wrap: wrap;
    gap: 10px;
}
.acf-form .acf-field[data-type="taxonomy"] .acf-input ul li {
    margin: 0;
    padding: 0;
}

/* Styling for the ACF Submit Button */
.acf-form .acf-form-submit {
    text-align: center;
    margin-top: 30px; /* Space above the submit button */
}
.acf-form .acf-form-submit .acf-button {
    background-color: var(--bpmp-primary-color, #ff037e);
    color: #fff;
    padding: 12px 25px;
    font-size: 1.1em;
    font-weight: bold;
    border-radius: var(--bpmp-border-radius, 8px);
    border: none;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
}
.acf-form .acf-form-submit .acf-button:hover {
    background-color: #fe5dab; /* Darker shade on hover */
    box-shadow: var(--bpmp-box-shadow, 0 2px 5px rgba(0, 0, 0, 0.2));
}

/* Styles for success/error messages displayed by ACF */
.acf-form .acf-notice {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-weight: bold;
}
.acf-form .acf-notice.-success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}
.acf-form .acf-notice.-error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

/*
==========================================================================
DROPZONE UPLOADER STYLES
==========================================================================
*/

/* Hide the original ACF Gallery field wrapper. 
   We target it by its data-name attribute. This is the most crucial part. */
.acf-form .acf-field[data-name="bpmp_media_gallery"] {
    display: none !important;
}

/* Style the Dropzone container */
#bpmp-dropzone-uploader.dropzone {
    border: 2px dashed #ccc;
    border-radius: var(--bpmp-border-radius, 8px);
    background: #f9f9f9;
    padding: 20px;
    margin-bottom: 28px;
    transition: border-color 0.3s;
    align-content: center;
}

#bpmp-dropzone-uploader.dropzone.dz-drag-hover {
    border-color: var(--bpmp-primary-color, #ff037e);
}

/* Style the message inside Dropzone */
#bpmp-dropzone-uploader.dropzone .dz-message {
    font-weight: bold;
    color: #555;
    font-size: 1.1em;
}

/* Style the file previews */
#bpmp-dropzone-uploader.dropzone .dz-preview {
    background: var(--bpmp-card-background-color, #fff);
    border-radius: var(--bpmp-border-radius, 8px);
    box-shadow: var(--bpmp-box-shadow, 0 1px 2px rgba(0,0,0,0.1));
    padding: 10px;
    margin: 10px;
}

/* Style the remove link */
#bpmp-dropzone-uploader.dropzone .dz-preview .dz-remove {
    color: #e02828;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9em;
    margin-top: 10px;
    display: inline-block;
    border: 1px solid #e02828;
    padding: 3px 8px;
    border-radius: 4px;
    transition: background-color 0.2s, color 0.2s;
}

#bpmp-dropzone-uploader.dropzone .dz-preview .dz-remove:hover {
    background-color: #e02828;
    color: #fff;
}

/* Style for error messages below the uploader */
.bpmp-uploader-errors {
    color: #e02828;
    font-weight: bold;
    margin-top: -15px;
    margin-bottom: 15px;
}

/*
==========================================================================
DELETE CONFIRMATION MODAL STYLES
==========================================================================
*/
#bpmp-delete-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

#bpmp-delete-modal-content {
    background-color: #fff;
    padding: 25px 30px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 450px;
    text-align: center;
}

#bpmp-delete-modal-content h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.5em;
}

#bpmp-delete-modal-content p {
    margin-bottom: 25px;
    font-size: 1.1em;
    line-height: 1.5;
}

#bpmp-delete-modal-content .modal-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

#bpmp-delete-modal-content .modal-buttons .button {
    padding: 10px 20px;
    font-size: 1em;
    font-weight: bold;
    border-radius: 5px;
    cursor: pointer;
}

#bpmp-modal-btn-cancel {
    background-color: #f0f0f0;
    border: 1px solid #ccc;
    color: #333;
}
#bpmp-modal-btn-cancel:hover {
    background-color: #e0e0e0;
}

#bpmp-modal-btn-confirm {
    background-color: #ff037e;
    border: 1px solid #d43f3a;
    color: white;
}
#bpmp-modal-btn-confirm:hover {
    background-color: #ff84bf;
}

/*
==========================================================================
Youzify/BuddyPress Icon Fix
==========================================================================
*/
/*
 * This CSS targets the list items in the BuddyPress sub-navigation by their ID,
 * then selects the direct anchor tag (<a>), and finally targets only the
 * FIRST <i> tag inside it, which is the one added by Youzify.
 * We use `display: none` to hide it completely.
 */
#browse-marketplace > i:nth-child(1),
#my-listings > i:nth-child(1),
#create-listing > i:nth-child(1) {
    display: none !important;
}


/* Responsive adjustments for the form */
@media (max-width: 768px) {
    .acf-form {
        padding: 20px;
        margin-top: 20px;
    }
    .acf-form h3 {
        font-size: 1.5em;
    }
    .acf-form .acf-field {
        margin-bottom: 15px;
    }
}
@media (max-width: 480px) {
    .acf-form {
        padding: 15px;
    }
    .acf-form h3 {
        font-size: 1.3em;
    }
}

/* Responsive adjustments for single page */
@media (min-width: 768px) {
    /* Example: If you had PHP wrappers for a two-column layout */
    /*
    .bpmp-single-listing-article {
        display: flex;
        gap: 30px;
    }
    .bpmp-listing-gallery-column { // Assuming you create this div in PHP
        flex: 0 0 55%; // Takes up 55% of width
    }
    .bpmp-listing-details-column { // Assuming you create this div in PHP
        flex: 1;
    }
    */
}
