/* ShopLentor Template Library - Elementor Editor */
#woolentor-template-library-modal .dialog-widget-content {
    max-width: 1920px;
}

/* Preview */
.woolentor_templateLibrary_preview {
    overflow: hidden;
    margin: auto;
    width: 100%;
    height: 100%;
    -webkit-transition: width .2s, height .2s;
    transition: width .2s, height .2s;
}

.woolentor_templateLibrary_preview > iframe {
    width: 100%;
    height: 100%;
}

/* Logo */
.tmpl-woolentor-template-library-logo-area {
    display: inline-block;
    border-radius: 50%;
    line-height: 1;
    text-align: center;
    width: 25px;
    height: 25px;
    line-height: 25px;
    margin-right: 10px;
}

.tmpl-woolentor-template-library-logo-area img {
    width: 100%;
}

/* Insert Button in Preview Header */
#elementor-template-library-header-preview-insert-wrapper .woolentor-template-library-template-insert.elementor-button {
    background: #6549D5;
    color: #fff;
}

#elementor-template-library-header-preview-insert-wrapper .woolentor-template-library-template-insert.elementor-button:hover {
    background: #5038C0;
}

/* Template List Grid */
#woolentor-template-library-list {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 15px;
}

/* Search Input */
#woolentor-template-library-filter-text {
    border: none;
    border-bottom: 1px solid #d5dadf;
    border-radius: 0;
    font-size: 11px;
    padding: 8px 15px 8px 0;
    transition: border .5s;
}

#woolentor-template-library-filter-text:focus {
    border-bottom-color: #6549D5;
}

/* Template Card */
.woolentor_template_library_template {
    width: calc((100% - 45px) / 4);
    padding-bottom: 0;
    background-color: #fff;
    box-shadow: 0 1px 20px 0 rgba(0, 0, 0, .07);
    border-radius: 3px;
}

.woolentor-template-library-thumbnail {
    width: 100%;
}

/* Template Body */
#woolentor-template-library-list .elementor-template-library-template-body {
    position: relative;
    height: 200px;
    overflow: hidden;
}

#woolentor-template-library-list .elementor-template-library-template-screenshot {
    height: 100%;
    background-size: cover;
    background-position-x: 50%;
    box-shadow: inset 0 -2px 15px -6px rgba(0, 0, 0, .07);
}

/* Hover Preview Overlay */
.woolentor-template-library-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, .5);
    transition: opacity .5s;
    cursor: pointer;
}

.woolentor_template_library_template:not(:hover) .woolentor-template-library-preview {
    opacity: 0;
}

.woolentor-template-library-preview i {
    font-size: 20px;
    color: #d5dadf;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Footer */
.woolentor-template-library-footer {
    padding: 10px 20px;
    position: relative;
    overflow: hidden;
}

.woolentor-template-library-footer .elementor-button {
    color: #6549D5;
    background: transparent;
    padding: 0;
}

.woolentor-template-library-footer .elementor-button:hover {
    color: #5038C0;
}

.woolentor-template-library-footer .elementor-button i {
    margin-right: 5px;
}

/* Template Title & Type */
.woolentor-template-library-template-title {
    font-size: 13px;
    font-weight: 500;
    color: #555;
}

.woolentor-template-library-template-type {
    font-size: 12px;
    font-weight: 400;
    color: #333;
    text-transform: capitalize;
}

/* Action Buttons - slide up on hover */
.woolentor-template-library-template-action-btn {
    position: absolute;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    top: 100%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translateX(-50%);
    background: #fff;
    transition: all .3s ease;
    padding: 0 15px;
}

.woolentor_template_library_template:hover .woolentor-template-library-template-action-btn {
    top: 0%;
}

/* Pro Badge */
span.woolentor-template-library-pro-badge {
    position: absolute;
    right: 5px;
    background: #6549D5;
    padding: 1px 12px;
    color: #fff;
    border-radius: 3px;
    top: 5px;
    font-size: 11px;
    font-weight: 600;
}

/* Responsive Menu Items */
.woolentor-template-library-responsive-menu-item {
    display: inline-block;
    padding: 15px 0;
    width: 40px;
    cursor: pointer;
    text-align: center;
}

.woolentor-template-library-responsive-menu-item.elementor-active {
    border-bottom: 3px solid #6549D5;
    background-image: linear-gradient(to bottom, #f1f3f5, #fff);
}

/* Category Filter */
#woolentor-template-library-filter-area-wrapper .select2-container {
    width: 200px !important;
    text-align: left;
}

#elementor-template-library-filter-category-wrapper .select2-container {
    width: 200px !important;
    text-align: left;
}

/* Add Section Button */
.elementor-add-woolentor-template-button {
    background-color: #6549D5 !important;
    margin-left: 5px;
    vertical-align: top;
}

.elementor-add-woolentor-template-button img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
}

/* Template Library Window */
.woolentor-template-library-window {
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    margin-top: 20px;
}
