/* styles.css */

body {
    background: #303030;
}

.popup-window {
    position: fixed;
    left: 0;
    top: 0;
  
    width: 550px;
    background: #111111;
    border: 1px solid var(--theme-border-color);
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: none;
    z-index: 1000;
    overflow: auto;
    max-height: 70vh; /* Maximum height of 80% viewport height */
    height: auto; /* Allow height to adjust based on content */
}

.window-header {
    background: #303236;
    padding: 10px; /* Reduced padding */
    border-bottom: 1px solid #000000;
    cursor: move;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.window-title {
    color: #ffffff;
    font-weight: bold;
    font-size: 14px;
    margin: 0;
    line-height: 1; /* Added to help with vertical centering */
}

.close-button {
    background: none;
    border: none;
    cursor: pointer;
    color: #ffffff;
    padding: 2px 6px; /* Reduced padding */
    font-size: 12px; /* Reduced from default */
    line-height: 1;
}

.window-content-outer {
    padding: 8px;
    overflow: auto;
    height: calc(100% - 53px);
}

.category {
    margin-bottom: 2px;
    border: 1px solid #555a5d;
    background: #242628;
}

.category-header {
    background: #1e252a;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    user-select: none;
    padding: 8px 10px;
}

    .category-header:hover {
        background: #161c1f;
    }

.category-name {
    color: #ffffff;
    font-weight: bold;
    font-size: 14px;
}

.chevron {
    transition: transform 0.2s;
    font-family: monospace;
}

.property-row {
    display: flex;
    align-items: center;
    padding: 2px 10px;
    transition: background-color 0.2s;
    justify-content: space-between;
    cursors: pointer;
    border-bottom: 1px solid #555a5d;
}

    .property-row:last-child {
        border-bottom: 0 none;
    }

    .property-row:first-child {
        border-top: 1px solid #555a5d;
    }

.property-name {
    color: #ffffff;
    font-weight: normal;
    font-size: 12px;
    line-height: 1.2;
}

.property-value-container {
    display: flex;
    align-items: center;
    gap: 4px;
    justify-content: flex-end;
    flex: 1;
    margin-left: 8px;
}

.property-value {
    background: white;
    border: 1px solid #ccc;
    padding: 3px 8px;
    border-radius: 2px;
    width: 100px;
    font-size: 12px;
    text-align: right;
}

.property-unit {
    width: 24px;
    font-size: 12px;
    text-align: left;
    color: #ffffff;
}

.icon-group {
    display: none;
    gap: 4px;
    margin-left: 8px;
}

.icon {
    cursor: pointer;
    width: 12px;
    height: 34px;
    color: #666;
}

    .icon:hover {
        color: #0066cc;
    }

.resize-handle {
    position: absolute;
    background: transparent;
}

    .resize-handle.right {
        right: 0;
        top: 0;
        width: 4px;
        height: 100%;
        cursor: ew-resize;
    }

    .resize-handle.bottom {
        left: 0;
        bottom: 0;
        width: 100%;
        height: 4px;
        cursor: ns-resize;
    }

    .resize-handle.corner {
        right: 0;
        bottom: 0;
        width: 8px;
        height: 8px;
        cursor: nwse-resize;
    }

    .resize-handle:hover {
        background: #0066cc;
    }

:root {
    /* tweak these to match your palette */
    --accent: var(--theme-left-menu-active); /* your maroon */
    --hover-tint: var(--theme-left-menu-active);
    --active-tint: var(--theme-left-menu-active);
    --focus-ring: rgba(139,30,43,.35); /* maroon focus ring */
}
/* 1) Style only settable value cells */
.property-row.is-settable .property-value.editable {
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

    /* 2) Hover/active colors with fallback (prevents "black") */
    .property-row.is-settable .property-value.editable:hover {
        background: var(--theme-left-menu-active);
        color: var(--theme-text-color);
    }

    .property-row.is-settable .property-value.editable:active {
        background: var(--theme-left-menu-active);
        color: var(--theme-text-color);
    }

    .property-row.is-settable .property-value.editable:focus {
        outline: none;
        box-shadow: 0 0 0 2px var(--theme-left-menu-active);
    }

/* 3) If your theme adds a black hover to the whole row, neutralize it */
.property-row:hover {
    background: transparent !important;
}
