/* ── Dotiam Resource Filter ── */
.dtmf-author-avatar{
		border: none;
		border-radius: 50% !important;
}
.dtmf-wrap {
    width: 100%;
    max-widthh: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ── Filter Bar ── */
.dtmf-filter-bar {
    margin-bottom: 32px;
}

.dtmf-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 16px;
    justify-content: center;
}

.dtmf-filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1 1 180px;
    max-width: 220px;
}

.dtmf-label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin: 0;
    display: block;
}

.dtmf-label-hidden {
    visibility: hidden;
}

.dtmf-select-wrap {
    position: relative;
}

.dtmf-select {
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    background: #fff;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    padding: 10px 36px 10px 14px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    outline: none;
    transition: border-color .2s;
    line-height: 1.4;
}

.dtmf-select:focus,
.dtmf-select:hover {
    border-color: #15971B;
}

.dtmf-select.dtmf-active {
    border-color: #15971B;
    background: #f0fdf4;
    color: #166534;
    font-weight: 600;
}

.dtmf-chevron {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: #6b7280;
    display: flex;
    align-items: center;
}

/* ── Reset Button ── */
.dtmf-reset-group {
    flex: 0 0 auto;
    max-width: none;
}

.dtmf-reset-btn {
    background: #15971B;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background .2s, transform .1s;
    line-height: 1.4;
	height: 48px;
}

.dtmf-reset-btn:hover {
    background: #009739;
}

.dtmf-reset-btn:active {
    transform: scale(.97);
}

/* ── Loader ── */
.dtmf-products-wrap {
    position: relative;
}

.dtmf-loader {
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 12px;
    min-height: 200px;
}

.dtmf-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #16A34A;
    border-top-color: #15971B;
    border-radius: 50%;
    animation: dtmf-spin .7s linear infinite;
    display: block;
}

@keyframes dtmf-spin {
    to { transform: rotate(360deg); }
}

/* ── Products Grid ── */
.dtmf-products {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(var(--dtmf-cols, 4), 1fr);
}

/* set css var from data attr via JS — fallback here */
.dtmf-products[data-columns="1"] { grid-template-columns: repeat(1, 1fr); }
.dtmf-products[data-columns="2"] { grid-template-columns: repeat(2, 1fr); }
.dtmf-products[data-columns="3"] { grid-template-columns: repeat(3, 1fr); }
.dtmf-products[data-columns="4"] { grid-template-columns: repeat(4, 1fr); }
.dtmf-products[data-columns="5"] { grid-template-columns: repeat(5, 1fr); }

/* ── Product Card ── */
.dtmf-product-card {
    background: #fff;
    border: 1px solid #16A34A;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow .2s, transform .2s;
    display: flex;
    flex-direction: column;
}

.dtmf-product-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,.10);
    transform: translateY(-2px);
}

.dtmf-product-img-link {
    display: block;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    background: #f9fafb;
}

.dtmf-product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s;
    display: block;
}

.dtmf-product-card:hover .dtmf-product-img {
    transform: scale(1.04);
}

.dtmf-no-img {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* ── Card body ── */
.dtmf-product-body {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.dtmf-cat-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #6b7280;
}

.dtmf-product-title {
   font-family: "Poppins", sans-serif !important;
    font-size: 18px !important;
    font-weight: 400;
    line-height: 22px !important;
    margin-top: 0px;
}

.dtmf-product-title a {
    color: inherit;
    text-decoration: none;
}

.dtmf-product-title a:hover {
    color: #15971B;
}

/* ── Author + Rating ── */
.dtmf-product-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.dtmf-author {
    display: flex;
    align-items: center;
    gap: 7px;
}

.dtmf-author-avatar {
    width: 36px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
}

.dtmf-author-name {
    font-size: 15px;
    color: #6b7280;
}

/* ── Stars ── */
.dtmf-rating {
    display: flex;
    gap: 1px;
}

.dtmf-star {
    width: 20px;
    height: 20px;
}

.dtmf-star-full path  { fill: #f4a21e; stroke: none; }
.dtmf-star-empty path { fill: #16A34A; stroke: none; }

/* ── Footer: price + cart ── */
.dtmf-product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 4px;
}

.dtmf-price {
    font-size: 26px;
    font-weight: 700;
    color: #15971b;
}

.dtmf-price .woocommerce-Price-amount {
    color: inherit;
    font-size: inherit;
}

.dtmf-add-to-cart {
    background: #15971B;
    color: #fff !important;
    border: none;
    border-radius: 50px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none !important;
    transition: background .2s;
    white-space: nowrap;
    display: inline-block;
}

.dtmf-add-to-cart:hover {
    background: #009739;
}

/* ── No results ── */
.dtmf-no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: #9ca3af;
}

.dtmf-no-results svg {
    display: block;
    margin: 0 auto 16px;
}

.dtmf-no-results p {
    font-size: 15px;
    margin: 0;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
    .dtmf-products[data-columns="4"],
    .dtmf-products[data-columns="5"] {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .dtmf-filters {
        justify-content: stretch;
    }
    .dtmf-filter-group {
        flex: 1 1 calc(50% - 8px);
        max-width: none;
    }
    .dtmf-reset-group {
        flex: 1 1 100%;
    }
    .dtmf-reset-btn {
        width: 100%;
    }
    .dtmf-label-hidden {
        display: none;
    }
    .dtmf-products[data-columns="3"],
    .dtmf-products[data-columns="4"],
    .dtmf-products[data-columns="5"] {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .dtmf-filter-group {
        flex: 1 1 100%;
		flex: 1 1 calc(50% - 8px);
    }
    .dtmf-products,
    .dtmf-products[data-columns="2"],
    .dtmf-products[data-columns="3"],
    .dtmf-products[data-columns="4"],
    .dtmf-products[data-columns="5"] {
        grid-template-columns: repeat(1, 1fr);
    }
	.dtmf-search-group {
		max-width: 100% !important;
	}
}

/* ── Load More ── */
.dtmf-load-more-wrap {
    text-align: center;
    margin-top: 32px;
}

.dtmf-load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    color: #15971B;
    border: 2px solid #15971B;
    border-radius: 50px;
    padding: 12px 36px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s, color .2s;
}

.dtmf-load-more-btn:hover {
    background: #15971B;
    color: #fff;
}

.dtmf-load-more-btn:disabled {
    opacity: .7;
    cursor: not-allowed;
}

.dtmf-lm-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid currentColor;
    border-top-color: transparent;
    border-radius: 50%;
    animation: dtmf-spin .6s linear infinite;
    display: inline-block;
}

/* ── Custom Searchable Dropdown ── */
.dtmf-dropdown {
    position: relative;
    user-select: none;
}

.dtmf-dropdown-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    border: 1.5px solid #010101;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    transition: border-color .2s;
    gap: 8px;
}

.dtmf-dropdown-trigger:hover,
.dtmf-dd-open .dtmf-dropdown-trigger {
    border-color: #15971B;
}

.dtmf-dd-selected .dtmf-dropdown-trigger {
    border-color: #15971B;
    background: #f0fdf4;
    color: #166534;
    font-weight: 600;
}

.dtmf-dropdown-selected {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dtmf-dd-open .dtmf-chevron svg {
    transform: rotate(180deg);
}

.dtmf-chevron svg {
    transition: transform .2s;
    flex-shrink: 0;
}

/* Panel */
.dtmf-dropdown-panel {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 100%;
    background: #fff;
    border: 1.5px solid #16A34A;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    z-index: 999;
    overflow: hidden;
}

.dtmf-dd-open .dtmf-dropdown-panel {
    display: block;
}

/* Search inside dropdown */
.dtmf-dd-search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-bottom: 1px solid #f3f4f6;
    background: #fafafa;
}

.dtmf-dd-search {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-size: 13px;
    color: #374151;
    padding: 0;
}

.dtmf-dd-search::placeholder { color: #9ca3af; }

/* Options */
.dtmf-dd-options {
    list-style: none;
    margin: 0;
    padding: 4px 0;
    max-height: 220px;
    overflow-y: auto;
}

.dtmf-dd-option {
    padding: 9px 14px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    transition: background .15s;
}

.dtmf-dd-option:hover {
    background: #f0fdf4;
    color: #166534;
}

.dtmf-dd-option.dtmf-dd-active {
    background: #f0fdf4;
    color: #166534;
    font-weight: 600;
}

/* Scrollbar styling */
.dtmf-dd-options::-webkit-scrollbar { width: 4px; }
.dtmf-dd-options::-webkit-scrollbar-track { background: #f9fafb; }
.dtmf-dd-options::-webkit-scrollbar-thumb { background: #d1d5db; border-radius: 4px; }












/* Search box fix */
.dtmf-search-group {
    flex: 1 1 180px;
    max-width: 220px;
}

.dtmf-search-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.dtmf-search-input {
    width: 100%;
    border: 1.5px solid #000000 !important;
    border-radius: 8px !important;
    padding: 10px 36px 10px 14px !important;
    font-size: 14px;
    color: #374151 !important;
    outline: none;
    transition: border-color .2s !important;
    line-height: 1.4;
    background: #fff !important;
    height: 48px !important;
}

.dtmf-search-input:focus {
    border-color: #15971B !important;
}

.dtmf-search-icon {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #000000;
    pointer-events: none;
    display: flex;
    align-items: center;
}

/* ── Hierarchy indent ── */
.dtmf-dd-child {
    padding-left: 26px !important;
    font-size: 13px !important;
    color: #4b5563 !important;
}

.dtmf-dd-child::before {
    content: "↳ ";
    color: #9ca3af;
}

.dtmf-dd-grandchild {
    padding-left: 42px !important;
    font-size: 13px !important;
    color: #6b7280 !important;
}

.dtmf-dd-grandchild::before {
    content: "↳ ";
    color: #d1d5db;
}
