/* Select Series Estimator Styles */

.select-series-estimator-modal-container {
    position: fixed;
    top: 0;
    right: -700px;
    width: 100%;
    height: 100vh;
    z-index: 999999;
    transition: right 0.3s ease;
    overflow-y: auto;
    pointer-events: none; /* Don't block interactions when hidden */
}

.select-series-estimator-modal-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

/* When modal is visible, enable pointer events */
.select-series-estimator-modal-container[style*="right: 0"],
.select-series-estimator-modal-container[style*="right:0"] {
    pointer-events: auto;
}

.select-series-estimator-modal-container[style*="right: 0"]::before,
.select-series-estimator-modal-container[style*="right:0"]::before {
    opacity: 1;
    pointer-events: auto;
}

.select-series-estimator-modal-content {
    position: absolute;
    right: 0;
    top: 0;
    width: 700px;
    max-width: 100%;
    height: 100%;
    background: #fff;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
}

.select-series-estimator-modal-close-btn {
    position: absolute;
    top: 0px;
    right: 0px;
    background: #002b45;
    color: #fff;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    padding:0px;
    font-size: 20px;
    line-height: 1;
    z-index: 10;
}

.select-series-estimator-modal-close-btn:hover {
    background: #6b5d4f;
}
button.select-series-estimator-modal-close-btn {
    padding: 0;
}
.select-series-estimator-label-heading {
    margin-bottom: 20px;
}

.select-series-estimator-label-heading h3 {
    font-size: 24px;
    font-weight: bold;
    color: #8c7969;
    margin: 0 0 20px 0;
}

.select-series-estimator-form-container {
    margin-bottom: 30px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 4px;
}

.select-series-estimator-sqft-hint {
    margin: 8px 0 0 0;
    font-size: 0.9rem;
    color: #666;
}

.select-series-estimator-form-container .form-row {
    margin-bottom: 15px;
}

.select-series-estimator-form-container .form-row.full {
    width: 100%;
}

.select-series-estimator-form-container .form-row.half {
    width: 48%;
    display: inline-block;
    margin-right: 2%;
}

.select-series-estimator-form-container label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.select-series-estimator-form-container input[type="text"],
.select-series-estimator-form-container input[type="email"],
.select-series-estimator-form-container input[type="number"],
.select-series-estimator-form-container select,
.select-series-estimator-form-container textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}

.select-series-estimator-form-container textarea {
    resize: vertical;
    min-height: 80px;
}

.add-to-estimate-btn {
    background: #8c7969;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    width: 100%;
}

.add-to-estimate-btn:hover {
    background: #6b5d4f;
}

.select-series-estimator-table-container {
    margin: 20px 0;
}

.select-series-estimator-table {
    width: 100%;
    border-collapse: collapse;
}

.select-series-estimator-table table {
    width: 100%;
    border-collapse: collapse;
}

.select-series-estimator-table thead {
    background: #8c7969;
    color: #fff;
}

.select-series-estimator-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.select-series-estimator-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
    font-size: 14px;
}

.select-series-estimator-table tbody tr:hover {
    background: #f9f9f9;
}

.select-series-estimator-table tbody tr:nth-child(even) {
    background: #fcfcfc;
}

.delete-estimate-item {
    background: #d63638;
    color: #fff;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 0;
}

.delete-estimate-item:hover {
    background: #b32d2e;
}

.product-image-cell img {
    max-width: 50px;
    height: auto;
    border-radius: 4px;
}

.select-series-estimator-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.clear-all-btn,
.next-step-btn,
.prev-step-btn,
.create-pdf-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
}

.clear-all-btn {
    background: #EEECE9;
    color: #002b45;
}button#select-series-clear-all, button#select-series-next-step, button.add-to-estimate-btn{    font-size: 1rem !important;
    border: none !important;}
.clear-all-btn:hover {
    background: #002b45;
    color:#fff;
}

.next-step-btn,
.create-pdf-btn {
    background: #8c7969;
    color: #fff;
}

.next-step-btn:hover,
.create-pdf-btn:hover {
    background: #6b5d4f;
}

.prev-step-btn {
    background: #666;
    color: #fff;
}

.prev-step-btn:hover {
    background: #555;
}

.step.hidden {
    display: none;
}

.form-section {
    margin-bottom: 30px;
}

.form-section h4 {
    font-size: 18px;
    font-weight: 600;
    color: #8c7969;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #8c7969;
}

.required-text {
    color: #d63638;
    font-size: 12px;
    margin-bottom: 15px;
}

#open-select-series-estimator,
.open-select-series-estimator {
    cursor: pointer !important;
    pointer-events: auto !important;
    z-index: 999 !important;
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    margin: 20px 0;
}

/* When button has position: fixed, ensure it's clickable and on top */
#open-select-series-estimator[style*="position: fixed"],
.open-select-series-estimator[style*="position: fixed"],
.elementor-element[data-settings*="fixed"]#open-select-series-estimator,
.elementor-element[data-settings*="fixed"].open-select-series-estimator {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 9999999 !important;
}

/* Also handle Elementor fixed positioning via classes */
.elementor-element.elementor-fixed#open-select-series-estimator,
.elementor-element.elementor-fixed.open-select-series-estimator {
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 9999999 !important;
}

/* Ensure all children are clickable */
#open-select-series-estimator *,
.open-select-series-estimator * {
    pointer-events: auto !important;
    cursor: pointer !important;
}

/* When parent is fixed, ensure children inherit clickability */
#open-select-series-estimator[style*="position: fixed"] *,
.open-select-series-estimator[style*="position: fixed"] *,
.elementor-element[data-settings*="fixed"]#open-select-series-estimator *,
.elementor-element[data-settings*="fixed"].open-select-series-estimator * {
    pointer-events: auto !important;
    cursor: pointer !important;
}

.open-select-series-estimator:hover {
    background: #6b5d4f;
}

/* Responsive */
@media (max-width: 768px) {
    .select-series-estimator-modal-container {
        width: 100%;
        right: -100%;
    }
    
    .select-series-estimator-form-container .form-row.half {
        width: 100%;
        margin-right: 0;
    }
}

