/* ================= MODAL BASE ================= */
.df-modal{display:none;position:fixed;inset:0;z-index:99999}
.df-modal.active{display:block}
.df-modal-overlay{position:absolute;inset:0;background:rgba(0,0,0,.65)}
.df-modal-box{
    position:absolute;
    top:50%;left:50%;
    transform:translate(-50%,-50%);
    background:#fff;
    width:95%;max-width:900px;
    border-radius:18px;
    overflow:hidden;
}
#product-filter-form h4 {
		font-size:20px !important;
		font-weight:600 !important;
	}
.df-modal-header{padding:22px 28px;border-bottom:1px solid #eee}
.df-modal-body{padding:24px;max-height:65vh;overflow:auto}
.df-modal-close {
    position: absolute;
    top: 12px;
    inset-inline-end: 14px; /* RTL + LTR safe */

    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    background: #d94948;
    color: #fff;
    border: none;
    border-radius: 50%;

    font-size: 22px;
    line-height: 1;

    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.15s ease;
}

/* Hover */
.df-modal-close:hover {
    background: #c53e3d;
    transform: scale(1.05);
}

/* Active (click) */
.df-modal-close:active {
    transform: scale(0.95);
}

/* Keyboard accessibility */
.df-modal-close:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* Hide raw filter layout inside modal, but keep data */
/* Hide raw layout ONLY on child categories */
#desktopFilterModal[data-is-parent="0"] #product-filter-form > div:not(.df-dropdown) {
    display: none !important;
}
/* ================= PARENT POPUP: FLAT CATEGORY LIST ================= */

/* Hide nested sub-filters (Size, Brand, etc.) on parent category popup */
#desktopFilterModal[data-is-parent="1"] ul ul {
    display: none !important;
}

/* Remove extra indentation / bullets */
#desktopFilterModal[data-is-parent="1"] ul {
    padding-left: 0 !important;
    margin-left: 0 !important;
    list-style: none !important;
}

#desktopFilterModal[data-is-parent="1"] li {
    margin-bottom: 10px;
}
/* ================= HIDE SHORTCODE ACTION BUTTONS INSIDE POPUP ================= */
	#product-filter-form h4 {
		font-size:20px !important;
		font-weight:600;
	}
/* Hide shortcode Apply / Clear buttons ONLY inside modal body */
#desktopFilterModal #product-filter-form #apply-filter-btn,
#desktopFilterModal #product-filter-form #clear-filter-btn {
    display: none !important;
}

/* Also hide their wrapper if exists */
#desktopFilterModal #product-filter-form .filter-actions,
#desktopFilterModal #product-filter-form .actions {
    display: none !important;
}

/* ================= FIX: SHOW FILTERS IN POPUP ON PARENT CATEGORY ================= */
#desktopFilterModal[data-is-parent="1"] ul {
    display: block !important;
}

#desktopFilterModal[data-is-parent="1"] li {
    display: list-item !important;
}

.df-dropdown {
    transition: background .2s ease, box-shadow .2s ease;
}
.df-dropdown-title {
    font-size: 15px;
    letter-spacing: .2px;
}

.df-dropdown-options {
    border-top: 1px solid #eee;
}
.df-dropdown-options li {
    border-radius: 6px;
    transition: background .15s ease;
}

.df-dropdown-options li:hover {
    background: #fafafa;
}

.df-dropdown:hover {
    background: #f2f2f2;
}

.df-dropdown.open {
    box-shadow: 0 6px 18px rgba(0,0,0,.06);
}


/* ================= DROPDOWNS ================= */
.df-dropdown{
    background:#f7f7f7;
    border-radius:14px;
    padding:16px;
    cursor:pointer;
}
.df-dropdown + .df-dropdown{margin-top:16px}

.df-dropdown-title{
    font-weight:700;
    position:relative;
    padding-right:28px;
}
.df-dropdown-title::after{
    content:"▾";
    position:absolute;
    right:0;
    color:#d94948;
    transition:.2s;
}
.df-dropdown.open .df-dropdown-title::after{
    transform:rotate(180deg);
}

/* OPTIONS */
.df-dropdown-options{
    display:none;
    margin-top:14px;
    background:#fff;
    border-radius:12px;
    padding:10px 0;
}
.df-dropdown.open .df-dropdown-options{display:block}

/* REMOVE BULLETS */
.df-dropdown-options ul{
    list-style:none !important;
    padding:0 !important;
    margin:0 !important;
}

/* OPTION ROW */
.df-dropdown-options li{
    padding:8px 16px;
}
.df-dropdown-options label{
    display:flex;
    align-items:center;
    gap:10px;
    cursor:pointer;
}

/* HIDE DEFAULT INPUT */
.df-dropdown-options input{
    accent-color:#d94948;
}

/* ================= ACTIONS ================= */
.df-modal-actions{
    display:flex;
    gap:14px;
    justify-content:center;
    padding:20px;
    border-top:1px solid #eee;
}
.df-btn{
    padding:12px 26px;
    border-radius:10px;
    border:none;
    cursor:pointer;
    font-weight:600;
}
.df-apply{
    background:#d94948;
    color:#fff;
}
.df-clear{
    background:#011627 !important;
    color:#fff;
}
	/* ================= HEADING-ONLY DROPDOWNS ================= */
.df-heading-only {
    cursor: default;
}

.df-heading-only .df-dropdown-title::after {
    display: none; /* remove arrow */
}

.df-heading-only .df-dropdown-title {
    color: #555;
    cursor: default;
}
html[dir="rtl"] .df-modal-close {
    right: auto;
    left: 18px;
}
html[dir="rtl"] .df-dropdown-title {
    padding-left: 28px;
    padding-right: 0;
}

html[dir="rtl"] .df-dropdown-title::after {
    left: 0;
    right: auto;
}
html[dir="rtl"] .df-modal-actions {
    flex-direction: row-reverse;
}
html[dir="rtl"] .df-dropdown-options label {
 
    justify-content: flex-start;
}

