/**
 * UM Elementor Editor Styles
 * Applied only inside the Elementor panel - never on the frontend.
 */

/* -- Layout chooser: lock visual on Pro options -------------------------- */

/*
 * Elementor CHOOSE controls render as:
 *   <input type="radio" id="elementor-choose-user_layout-table_pro" value="table_pro">
 *   <label for="elementor-choose-user_layout-table_pro" title="...">...</label>
 *
 * We target the label that follows each locked input.
 */
.elementor-control-user_layout input[value="table_pro"] + label,
.elementor-control-user_layout input[value="carousel_pro"] + label {
    opacity: 0.55;
    position: relative;
    cursor: pointer; /* JS handles click - still allow it for tooltip trigger */
}

/* Lock badge in the top-right corner of each locked button */
.elementor-control-user_layout input[value="table_pro"] + label::after,
.elementor-control-user_layout input[value="carousel_pro"] + label::after {
    content: "🔒";
    position: absolute;
    top: 2px;
    right: 3px;
    font-size: 7px;
    line-height: 1;
    pointer-events: none;
}

/* Restore full opacity when hovered (invites interaction / tooltip) */
.elementor-control-user_layout input[value="table_pro"] + label:hover,
.elementor-control-user_layout input[value="carousel_pro"] + label:hover {
    opacity: 0.85;
}

/* Prevent Elementor from showing the option as "selected" if JS reversion
   ever races - checked state stays visually unselected for pro values */
.elementor-control-user_layout input[value="table_pro"]:checked + label,
.elementor-control-user_layout input[value="carousel_pro"]:checked + label {
    background-color: transparent;
    color: inherit;
    border-color: transparent;
}

/* -- Upgrade tooltip ------------------------------------------------------ */

.um-pro-tooltip {
    position: fixed;
    z-index: 99999;
    width: 240px;
    background: #1a1a2e;
    border: 1px solid #3a3a5c;
    border-radius: 8px;
    padding: 14px 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    pointer-events: all;
}

/* Arrow pointing down toward the clicked button */
.um-pro-tooltip::after {
    content: "";
    position: absolute;
    bottom: -7px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 7px 7px 0;
    border-style: solid;
    border-color: #1a1a2e transparent transparent;
}

.um-pro-tooltip-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.um-pro-tooltip-title {
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
    letter-spacing: 0.02em;
}

.um-pro-tooltip-close {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 13px;
    line-height: 1;
    padding: 0 2px;
    margin: 0;
    box-shadow: none;
    outline: none;
}

.um-pro-tooltip-close:hover {
    color: #e2e8f0;
}

.um-pro-tooltip-body {
    font-size: 11.5px;
    color: #94a3b8;
    line-height: 1.55;
    margin-bottom: 12px;
}

.um-pro-tooltip-body strong {
    color: #cbd5e1;
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
}

.um-pro-features {
    list-style: none;
    margin: 0 0 12px;
    padding: 0;
}

.um-pro-features li {
    font-size: 11px;
    color: #94a3b8;
    padding: 2px 0;
}

.um-pro-features li::before {
    content: "✓ ";
    color: #4ade80;
}

.um-pro-tooltip-btn {
    display: block;
    text-align: center;
    background: #4f46e5;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 12px;
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 5px;
    transition: background 0.15s;
    letter-spacing: 0.01em;
}

.um-pro-tooltip-btn:hover {
    background: #4338ca;
    color: #fff !important;
}

/* -- RAW_HTML inline upgrade notice (shown via Elementor condition) ------- */

.um-elementor-pro-notice {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #1a1a2e;
    border: 1px solid #3a3a5c;
    border-radius: 7px;
    padding: 12px 14px;
    margin: 4px 0 6px;
}

.um-pro-notice-icon {
    font-size: 18px;
    flex-shrink: 0;
    margin-top: 1px;
}

.um-pro-notice-content {
    flex: 1;
}

.um-pro-notice-content strong {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
    margin-bottom: 4px;
}

.um-pro-notice-content p {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.5;
    margin: 0 0 10px;
}

.um-pro-notice-btn {
    display: inline-block;
    background: #4f46e5;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 11px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 4px;
    transition: background 0.15s;
}

.um-pro-notice-btn:hover {
    background: #4338ca;
    color: #fff !important;
}

/* -- Pro placeholder widget card (rendered on Elementor canvas) ----------- */

.umwfe-pro-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 180px;
    padding: 24px 16px;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a38 100%);
    border: 1.5px dashed #4f46e5;
    border-radius: 10px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.umwfe-pro-placeholder-inner {
    text-align: center;
    max-width: 340px;
}

.umwfe-pro-lock-icon {
    display: block;
    font-size: 28px;
    margin-bottom: 10px;
    line-height: 1;
}

.umwfe-pro-placeholder-title {
    font-size: 15px;
    font-weight: 700;
    color: #e2e8f0;
    margin: 0 0 8px;
    line-height: 1.3;
}

.umwfe-pro-badge {
    display: inline-block;
    background: #4f46e5;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 3px;
    vertical-align: middle;
    margin-left: 4px;
}

.umwfe-pro-placeholder-desc {
    font-size: 12px;
    color: #94a3b8;
    line-height: 1.55;
    margin: 0 0 16px;
}

.umwfe-pro-placeholder-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
}

.umwfe-pro-btn {
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    padding: 7px 14px;
    border-radius: 5px;
    text-decoration: none !important;
    transition: all 0.15s ease;
    cursor: pointer;
    white-space: nowrap;
}

.umwfe-pro-btn--ghost {
    background: transparent;
    color: #818cf8 !important;
    border: 1.5px solid #4f46e5;
}

.umwfe-pro-btn--ghost:hover {
    background: rgba(79, 70, 229, 0.12);
    color: #a5b4fc !important;
}

.umwfe-pro-btn--primary {
    background: #4f46e5;
    color: #fff !important;
    border: 1.5px solid transparent;
}

.umwfe-pro-btn--primary:hover {
    background: #4338ca;
    color: #fff !important;
}
