/* Base styles that might be needed beyond Tailwind */
/* Color scheme variables */
:root {
    --primary-color: #bf9e55;      /* Golden */
    --secondary-color: #a68a49;    /* Darker golden */
    --explore: #ffd700;            /* Gold */
    --accent-color: #f15b42;       /* Coral red */
    --accent-color-hover: #d14b32; /* Darker coral red */
    --accent-color-faint: #ffb3a7; /* Medium-light coral red */
    --text-primary: #000000;       /* Black */
    --text-secondary: #333333;     /* Dark gray */ 
    --label-primary: #ffffff;      /* White */
    --label-secondary: #aaaaaa;    /* Light gray */
    --page-background: #1c2849;    /* Dark navy blue */
    --background: #2c3d73;         /* Navy blue */
    --background-alt: #4a5c92;     /* Lighter navy blue */
    --background-alt-2: #6b79a3;   /* Lighter navy blue */
    --error: #ef4444;              /* Red */
    --error-hover: #ff3333;        /* Bright red */
    --success: #22c55e;            /* Green */
    --proceed: #228b22;            /* Dark green */
    --proceed-hover: #22c55e;      /* Light green */
    --caution: #ff8800;            /* Orange */
    --regress: #8b0000;            /* Dark red */
    --information: #0000ff;        /* Blue */
    --panel-background: #bfbfff;     /* Light gray */
}

html, body {
    height: 100%;
    overflow: auto;
}

/* Base page styling */
body {
    background-color: var(--page-background);
}

/* Custom styles that extend Tailwind */
.card {
    background: var(--background);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1rem;
    margin-bottom: 1rem;
}
.status {
    margin: 15px 0;
    padding: 10px;
}

.response-area {
    margin-top: 20px;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 5px;
    min-height: 100px;
    background-color: white;
}

/* Error state styling */
.response-area div[style*="color: red"] {
    background-color: #fff2f2;
    padding: 10px;
    border-radius: 4px;
    border-left: 4px solid #ff4444;
}

/* Success message styling */
.response-area div[style*="margin-bottom: 10px"] {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    line-height: 1.6;
}

/* Text overflow handling for UI elements */

/* For elements that should truncate with ellipsis */
.text-ellipsis {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* For elements that should show a tooltip on hover when truncated */
.text-ellipsis-hover {
    position: relative;
}

.text-ellipsis-hover:hover::after {
    content: attr(data-full-text);
    position: absolute;
    left: 0;
    top: 100%;
    z-index: 100;
    background: var(--primary-color);
    border: 1px solid var(--accent-color);
    padding: 0.5rem;
    border-radius: 0.25rem;
    white-space: normal;
    max-width: 300px; /* Reasonable max width for tooltip */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* For scrollable content areas */
.text-scroll {
    overflow-y: auto;
    max-height: 400px; /* Adjust based on your needs */
    padding-right: 0.5rem; /* Space for scrollbar */
}

/* Custom scrollbar styling */
.text-scroll::-webkit-scrollbar {
    width: 8px;
}

.text-scroll::-webkit-scrollbar-track {
    background: var(--background-alt);
    border-radius: 4px;
}

.text-scroll::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    border-radius: 4px;
}

/* RTL language support */
[dir="rtl"] .text-ellipsis-hover::after {
    left: auto;
    right: 0;
}

/* Ensure proper text wrapping for all languages */
.text-wrap-all {
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* RTL Support */
[dir="rtl"] {
    /* Text alignment */
    .text-start {
        text-align: right;
    }
    .text-end {
        text-align: left;
    }

    /* Margins and Paddings */
    .me-auto {
        margin-left: auto !important;
        margin-right: 0 !important;
    }
    .ms-auto {
        margin-right: auto !important;
        margin-left: 0 !important;
    }

    /* Flexbox direction */
    .flex-row {
        flex-direction: row-reverse;
    }
    
    /* Border radiuses */
    .rounded-s {
        border-radius: 0 0.25rem 0.25rem 0;
    }
    .rounded-e {
        border-radius: 0.25rem 0 0 0.25rem;
    }

    /* Positioning */
    .start-0 {
        right: 0;
        left: auto;
    }
    .end-0 {
        left: 0;
        right: auto;
    }
}

/* Logical properties for bi-directional support */
.logical-padding {
    padding-inline-start: 1rem;
    padding-inline-end: 1rem;
}

.logical-margin {
    margin-inline-start: 1rem;
    margin-inline-end: 1rem;
}

/* LED Status Indicator sizing */
.status-led {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Clusterflux Settings Checkbox sizing */
.clusterflux-setting-checkbox {
    width: 20px;
    height: 20px;
}

/* Clusterflux Settings Slider sizing */
.clusterflux-setting-slider {
    width: 125px;
    /* height: 20px; */
} 