:root {
/* 1. Base Colors */
    --bs-white: #ffffff;
    
    /* 2. Theme Colors (Hex) */
    --bs-dark:      #27150f;
    --bs-primary:   #74130a;
    --bs-secondary: #385eb6;
    --bs-info:      #c84745;
    --bs-success:   #549312;
    --bs-warning:   #feba51;
    --bs-danger:    #e90a62;

    /* 3. Theme Colors (RGB) 
       Required for utilities like .bg-primary.bg-opacity-25 to work. 
       These must be comma-separated integers without 'rgb()'. */
    --bs-dark-rgb:      39, 21, 15;
    --bs-primary-rgb:   116, 19, 10;
    --bs-secondary-rgb: 56, 94, 182;
    --bs-info-rgb:      200, 71, 69;
    --bs-success-rgb:   84, 147, 18;
    --bs-warning-rgb:   254, 186, 81;
    --bs-danger-rgb:    233, 10, 98;
    --bg-color: #74140b;
    --active-color: #a31c0f;
}

.staging {
    --bg-color: #000000;
    --active-color: #111111;
}

.btn-primary, .btn-primary:visited {
    background-color: var(--bg-color) !important;
}

.btn-primary:hover, .btn-primary:active {
    background-color: var(--active-color) !important;
}

.bg-dark 
{
    background-color: var(--bg-color) !important;
}

select.ballot-selection
{
    text-overflow: ellipsis;
    width: 100%;
}

label.form-check-label, label.form-label
{
    font-weight: bold;
}

@media(min-width:576px) {
    .w-sm-25 {
        width:25% !important;
    }
    .w-sm-50 {
        width:50% !important;
    }
    .w-sm-75 {
        width:75% !important;
    }
    .w-sm-100 {
        width:100% !important;
    }
}
@media(min-width:768px) {
    .w-md-25 {
        width:25% !important;
    }
    .w-md-50 {
        width:50% !important;
    }
    .w-md-75 {
        width:75% !important;
    }
    .w-md-100 {
        width:100% !important;
    }
}
@media(min-width:992px) {
    .w-lg-25 {
        width:25% !important;
    }
    .w-lg-50 {
        width:50% !important;
    }
    .w-lg-75 {
        width:75% !important;
    }
    .w-lg-100 {
        width:100% !important;
    }
}
@media(min-width:1200px) {
    .w-xl-25 {
        width:25% !important;
    }
    .w-xl-50 {
        width:50% !important;
    }
    .w-xl-75 {
        width:75% !important;
    }
    .w-xl-100 {
        width:100% !important;
    }
}

   @keyframes fade-in {
     from { opacity: 0; }
   }

   @keyframes fade-out {
     to { opacity: 0; }
   }

   @keyframes slide-from-right {
     from { transform: translateX(90px); }
   }

   @keyframes slide-to-left {
     to { transform: translateX(-90px); }
   }

   .slide-it {
     view-transition-name: slide-it;
   }

   ::view-transition-old(slide-it) {
     animation: 180ms cubic-bezier(0.4, 0, 1, 1) both fade-out,
     600ms cubic-bezier(0.4, 0, 0.2, 1) both slide-to-left;
   }
   ::view-transition-new(slide-it) {
     animation: 420ms cubic-bezier(0, 0, 0.2, 1) 90ms both fade-in,
     600ms cubic-bezier(0.4, 0, 0.2, 1) both slide-from-right;
   }


.expand-icon {
  display: inline-block; /* Ensures transform works consistently */
  transition: transform 0.25s ease-in-out;
}

tr[data-bs-toggle="collapse"][aria-expanded="true"] .expand-icon {
  transform: rotate(90deg);
}

.details-row td {
 max-width: 500px;
}

.spinner-border-sm {
  display: none;
}

.htmx-request .spinner-border-sm {
  display: inline-block
}

.htmx-request .button-text {
  display: none;
}

/* /static/ui-improvements.css */

/* Make the accordion buttons a bit smaller and add a pointer */
.accordion-button {
    cursor: pointer;
    padding: 0.75rem 1.25rem;
}

/* Remove the default icon rotation for a cleaner look if desired */
.accordion-button::after {
    transition: transform 0.2s ease-in-out;
}

/* Style for the container of pay periods */
.pay-periods-container {
    margin-top: 1rem;
}

/* Make pay period rows more compact */
.pay-period-row {
    background-color: #f8f9fa; /* A slightly different background to distinguish it */
}

/* Adjust layout for form rows inside the accordion for better alignment */
.accordion-body .row {
    align-items: flex-end; /* Vertically align items to the bottom */
    margin-bottom: 1rem;
}

/* Tweak labels in compact rows */
.accordion-body .form-label {
    margin-bottom: 0.25rem;
    font-size: 0.875em; /* Make label text slightly smaller */
}

/* Ensure action buttons have some space */
.action-buttons {
    margin-top: 1.5rem;
}

        /* Custom styles to mimic original look and handle detail rows */
        .tabulator-row.combined-row-style {
            background-color: #f8f9fa; /* Light grey for combined rows */
            font-style: italic;
        }
        .tabulator-row .tabulator-cell {
             border-right: none; /* Cleaner look */
        }
        .detail-row-container .tabulator-cell {
            padding: 0;
            border-bottom: 1px solid #dee2e6;
        }
        .detail-row-container .tabulator-cell > div{
             padding: 1rem; /* Padding for the loaded htmx content */
             width: 100%;
        }

.negate-filter label.btn {
  border-top-left-radius: var(--bs-btn-border-radius) !important;
    border-bottom-left-radius: var(--bs-btn-border-radius) !important;
}

.negate-filter label.btn {
  --bs-btn-disabled-color: var(--bs-btn-disabled-color) !important;
  --bs-btn-disabled-border-color: var(--bs-btn-disabled-border-color) !important;
}

.inline-input {
  display: inline-block;
  width: 75%;
}

.original-row-data {
  width: 50vw;
}