.page-wrapper.compact-wrapper .page-body-wrapper div.sidebar-wrapper .sidebar-main .sidebar-links .simplebar-wrapper .simplebar-mask .simplebar-content-wrapper .simplebar-content > li .sidebar-link:after
{
    background-color: #E3463B!important;
}

.page-wrapper.compact-wrapper .page-body-wrapper div.sidebar-wrapper .sidebar-main .sidebar-links .simplebar-wrapper .simplebar-mask .simplebar-content-wrapper .simplebar-content > li .sidebar-link.active

 {
    background-color: #F9DAD8!important;

}
.page-wrapper.compact-wrapper .page-body-wrapper div.sidebar-wrapper .sidebar-main .sidebar-links .simplebar-wrapper .simplebar-mask .simplebar-content-wrapper .simplebar-content > li.sidebar-list:hover > a:hover
{
    background-color: #F9DAD8!important;
}
.page-wrapper.compact-wrapper .page-body-wrapper div.sidebar-wrapper .sidebar-main .sidebar-list:hover i.fa-solid.fa-thumbtack
{
    color: #E3463B!important;
}
.nav i  {
    color: #E3463B!important;
}
/* .scope-bottom-wrapper .sidebar-left-icons .nav-item .nav-link.active
{
    background-color: #F9DAD8!important;
} */

/* .scope-bottom-wrapper .sidebar-left-icons .nav-item .nav-link.active {
    background: linear-gradient(90deg, #7366ff -175.57%, rgba(115, 102, 255, 0) 65.16%);
    color: unset;
} */

.projects-wrapper:last-child .card {
margin-bottom: 0 !important;
}
.btn-create-campaign {
    padding: 12px!important;
    font-size: medium;
    font-weight: bold;
}
.header-actions select[name="created_by"] {
    min-width: 150px;
}

.toggle-sidebar {
    display: inline-masonry!important;
}

.btn-outline-custom-red {
    color: #E3463B; /* Text and Border color */
    border-color: #E3463B;
}

.btn-outline-custom-red:hover,
.btn-outline-custom-red:active {
    /* Solid color on hover/active */
    color: #fff;
    background-color: #E3463B;
    border-color: #E3463B;
}

.btn-outline-custom-red:focus {
    /* Add a subtle shadow on focus, similar to Bootstrap's default */
    box-shadow: 0 0 0 0.25rem rgba(227, 70, 59, 0.5); /* #E3463B with 50% opacity */
}



/*      responsive style     */

/* ========================================= */
/* 1. Base Styles (Always Apply)            */
/* ========================================= */

.card-header.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0; /* Adjust padding if needed */
}

.header-actions {
    display: flex;
    flex-wrap: nowrap; /* Prevent wrapping on desktop */
    gap: 0.5rem; /* Space between filter elements */
    align-items: center;
}

.header-actions .form-select,
.header-actions .form-control {
    width: auto; /* Allow items to size based on content */
    min-width: 120px; /* Ensure filters are legible on desktop */
}

.table-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    gap: 1rem;
}

.table-controls .search-input {
    flex-grow: 1; /* Search input takes up available space */
    max-width: 400px; /* Limit search width on large screens */
}


/* ========================================= */
/* 2. Tablet & Phone Layout (Max 992px)     */
/* ========================================= */
/* This targets Laptops/Large Tablets (less than 'lg' breakpoint) */
@media (max-width: 991.98px) {
    .header-actions {
        /* Allow the filter row to wrap */
        flex-wrap: wrap;
        /* Ensure the main button stays on the right */
        justify-content: flex-end;
    }

    .header-actions .form-select,
    .header-actions .form-control {
        /* Filters and inputs will take up half the width on tablets */
        flex-basis: calc(50% - 0.5rem);
        min-width: unset;
    }

    /* Ensure the create button takes full width if wrapping is complex */
    .header-actions .btn-create-campaign {
        width: 100%;
        margin-top: 0.5rem;
    }
}



/* ========================================= */
/* Campaign Creation Wizard Responsiveness   */
/* ========================================= */

/* 1. Page Title and Breadcrumb Stacking */
@media (max-width: 767.98px) {
    /* Target the row containing the title and breadcrumb */
    .page-title .row {
        /* Ensure columns stack if they were somehow side-by-side */
        flex-direction: column;
    }

    /* Target the column holding the breadcrumbs */
    .page-title .col-sm-6:last-child {
        /* Remove top padding/margin and add spacing below title if necessary */
        padding-top: 0.5rem;
    }

    /* Ensure the title is always left-aligned */
    .page-title .col-sm-6 h3 {
        text-align: left !important;
        font-size: 1.5rem; /* Shrink title size for mobile */
    }

    /* Center/stack the breadcrumbs nicely */
    .page-title .breadcrumb {
        justify-content: flex-start !important; /* Align to the left on mobile */
        margin-bottom: 0;
    }

    /* Ensure the main wizard container takes up full width cleanly */
    .container-fluid.basic_table {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
}


/* 2. Wizard Progress Bar Adjustments (if needed) */
@media (max-width: 575.98px) {
    .wizard-progress-bar {
        /* If the progress bar components are too wide, adjust padding */
        padding: 0 0.5rem;
    }

    .wizard-progress-bar .progress-step-label {
        font-size: 0.8rem; /* Smaller font for step count */
    }
}


/* 3. Minor aesthetic tweaks for the stacked cards on mobile */
@media (max-width: 991.98px) {
    /* Add vertical space between the two stacked columns (Campaign Setup & Brief Upload) */
    .campaign-wizard-step-one .col-lg-4 {
        margin-top: 1.5rem;
    }
}

/* ========================================= */
/* Campaign Wizard Step 2 Responsiveness     */
/* ========================================= */

@media (max-width: 767.98px) {
    /* 1. Card Header Stacking (Deliverables, Assign Creators, PR Package) */
    .campaign-widget .card-header .d-flex {
        /* Change the flex container from horizontal to vertical stacking */
        flex-direction: column;
        align-items: flex-start !important; /* Align content to the left */
        text-align: left;
    }

    .campaign-widget .card-header .campaign-icon-wrapper {
        /* Separate the icon from the title/subtitle when stacked */
        margin-right: 0 !important;
        margin-bottom: 10px; /* Add space below the icon */
    }

    /* Adjust the text wrapper padding/margin after icon stacks */
    .campaign-widget .card-header .d-flex > div:last-child {
        margin-left: 0 !important;
    }

    .campaign-widget .card-header h5 {
        font-size: 1.1rem; /* Slightly reduce font size for compactness */
    }

    .campaign-widget .card-header p {
        font-size: 0.8rem; /* Make subtitle text smaller */
    }

    /* 2. Deliverables Rows (Dynamic Form) */
    .deliverable-row .row.g-3 > div {
        /* Ensure the Deliverable Type and Quantity inputs stack instead of side-by-side */
        width: 100% !important;
        max-width: 100% !important;
        /* The col-md-6 is overridden by default on mobile, but this ensures it */
    }

    .deliverable-row .row.g-3 {
        --bs-gutter-y: 1rem; /* Increase vertical spacing for better separation */
    }

    /* Clean up spacing for the 'Remove' button */
    .deliverable-row + .text-end {
        padding-top: 0.5rem;
    }

    /* 3. Products Table (PR Package Products) */
    /* Although wrapped in .table-responsive, we ensure the table has a minimum width */
    .products-table {
        min-width: 600px; /* Force table wide enough to scroll horizontally */
        width: 100%;
    }

    .products-table th,
    .products-table td {
        padding: 0.5rem 0.75rem; /* Condense table cell padding */
        font-size: 0.85rem;      /* Reduce font size */
        white-space: nowrap;     /* Prevent text wrapping in cells */
    }

    /* Make the action column very narrow */
    .products-table td:last-child {
        width: 10px;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }

    /* Adjust the 'Add Product' footer layout */
    .campaign-widget .d-flex.justify-content-between {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.5rem;
    }
    .campaign-widget .d-flex.justify-content-between .text-end {
        align-self: flex-end; /* Keep the count aligned right */
    }
}

/* ========================================= */
/* Campaign Wizard Step 3: Responsiveness    */
/* ========================================= */

@media (max-width: 767.98px) {

    /* 1. Card Header Stacking (Same fix as Step 2) */
    .campaign-wizard-step-three .card-header .d-flex {
        /* Change the flex container from horizontal to vertical stacking */
        flex-direction: column;
        align-items: flex-start !important; /* Align content to the left */
        text-align: left;
    }

    .campaign-wizard-step-three .card-header .campaign-icon-wrapper {
        /* Separate the icon from the title/subtitle when stacked */
        margin-right: 0 !important;
        margin-bottom: 10px; /* Add space below the icon */
    }

    .campaign-wizard-step-three .card-header h5 {
        font-size: 1.1rem; /* Slightly reduce font size for compactness */
    }

    .campaign-wizard-step-three .card-header p {
        font-size: 0.8rem; /* Make subtitle text smaller */
    }

    /* 2. Creator Budget Assignment Table Responsiveness */

    /* Ensure the table is wide enough to trigger horizontal scrolling */
    .campaign-wizard-step-three .table-responsive table {
        min-width: 700px; /* Force table wide enough to scroll horizontally */
        width: 100%;
    }

    /* Condense table cell padding and font size */
    .campaign-wizard-step-three .table th,
    .campaign-wizard-step-three .table td {
        padding: 0.5rem 0.6rem;
        font-size: 0.85rem;
        white-space: nowrap; /* Prevent text wrapping in cells */
    }

    /* Condense header text using CSS (like the Campaign Index Table) */
    .campaign-wizard-step-three .table thead th:nth-child(2):before { content: 'Rate'; } /* Rate Card (EGP) */
    .campaign-wizard-step-three .table thead th:nth-child(2) { font-size: 0; }

    .campaign-wizard-step-three .table thead th:nth-child(3):before { content: 'Budget*'; } /* Budget (EGP) */
    .campaign-wizard-step-three .table thead th:nth-child(3) { font-size: 0; }

    .campaign-wizard-step-three .table thead th:nth-child(4):before { content: 'Deposit'; } /* Deposit (EGP) */
    .campaign-wizard-step-three .table thead th:nth-child(4) { font-size: 0; }

    /* Ensure text inputs are compact */
    .campaign-wizard-step-three .table input.form-control {
        padding: 0.3rem 0.5rem;
        height: auto;
        font-size: 0.85rem;
        min-width: 80px; /* Give inputs a minimum width */
    }

    /* Reduce font size in the table footer */
    .campaign-wizard-step-three .table tfoot th {
        font-size: 0.85rem;
        padding: 0.75rem 0.6rem;
    }

    /* Creator Name column adjustments */
    .campaign-wizard-step-three .table tbody td:first-child {
        min-width: 120px; /* Ensure creator name column has enough space */
    }

    /* 3. Scheduling & Management Section */
    .campaign-wizard-step-three .row.g-3 > .col-md-6 {
        /* Force the campaign manager select to take full width if the other column is removed */
        width: 100% !important;
        max-width: 100% !important;
    }
}






/* ========================================= */
/* Campaign Filter Form Responsiveness       */
/* ========================================= */

@media (max-width: 767.98px) {

    /* 1. Stack columns and remove padding on very small devices */
    #filter-form .row.g-3 {
        /* Reduce the gutter spacing between form elements */
        --bs-gutter-x: 1rem;
        --bs-gutter-y: 1rem;
    }

    /* Force all columns to take full width on mobile */
    #filter-form .col-md-3 {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100%;
    }

    /* 2. Condense form elements */
    #filter-form .form-label {
        /* Reduce space above the input/select */
        margin-bottom: 0.25rem;
        font-size: 0.9rem; /* Slightly smaller label text */
    }

    #filter-form .form-control,
    #filter-form .form-select {
        padding: 0.5rem 0.75rem; /* Reduce input padding */
        height: auto;
        min-height: 38px;
        font-size: 0.95rem;
    }

    /* 3. Button Row Adjustment */
    #filter-form .row.mt-3 {
        /* Remove top margin if the row is stacked */
        margin-top: 1rem !important;
    }

    #filter-form .text-end {
        /* Ensure button remains right-aligned or centers if preferred */
        text-align: right !important;
    }

    #clear-filters {
        padding: 0.5rem 1rem; /* Standardize button padding */
        font-size: 0.95rem;
    }
}




/* ========================================= */
/* Campaign Index Table - **REVISED** CSS      */
/* ========================================= */

/* 1. Ensure Horizontal Scrolling on All Mobile/Tablet Devices */
@media (max-width: 991.98px) {

    /* Target the table directly inside your scrolling container */
    #table-display .table {
        /* Force a strong minimum width so the table columns can breathe.
           This is the key to activating the horizontal scroll of the parent .table-responsive. */
        min-width: 1000px;
        width: 100%;
        margin-bottom: 0;
    }

    /* Ensure the wrapper respects the minimum width and scrolls.
       You already have .table-responsive, but this ensures its properties are strong. */
    .table-responsive {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch; /* Better scrolling experience on iOS */
    }

    /* Condense columns that contain long text */
    #table-display .table thead th,
    #table-display .table tbody td {
        padding: 0.5rem 0.6rem; /* Reduced padding */
        font-size: 0.85rem;      /* Reduced font size */
        white-space: nowrap;     /* Prevent text from wrapping and breaking cells */
    }

    /* Narrower columns for non-essential data */
    #table-display .table td:nth-child(2), /* Brand */
    #table-display .table td:nth-child(3), /* PR Owner */
    #table-display .table td:nth-child(5), /* Status */
    #table-display .table td:nth-child(6), /* Budget */
    #table-display .table td:nth-child(8)  /* Actions */
    {
        width: 10%;
    }
}

/* 2. Content Condensation for Mobile Readability */
@media (max-width: 767.98px) {

    /* Shorten column headers for the smallest screens */
    #table-display .table thead th {
        font-size: 0; /* Hide original header text */
        text-transform: uppercase;
        position: relative; /* Needed for :before to position correctly */
        padding-top: 0.75rem; /* Re-add padding for new content */
        padding-bottom: 0.75rem;
    }

    /* Override hidden text with condensed versions */
    #table-display .table thead th:nth-child(3):before { content: 'OWNER'; font-size: 0.75rem; }
    #table-display .table thead th:nth-child(4):before { content: 'DATES'; font-size: 0.75rem; }
    #table-display .table thead th:nth-child(6):before { content: 'BUDG.'; font-size: 0.75rem; }
    #table-display .table thead th:nth-child(7):before { content: 'PROG.'; font-size: 0.75rem; }
    #table-display .table thead th:nth-child(8):before { content: 'ACT.'; font-size: 0.75rem; }

    /* Campaign Name column should remain wider for better clarity */
    #table-display .table td:first-child {
        min-width: 180px;
    }

    /* Ensure the progress percentage text is visible and the bar is compact */
    #table-display .progress-bar-container {
        height: 8px;
    }
    #table-display .progress-bar-fill {
        height: 8px;
    }
    #table-display .d-flex.align-items-center span {
        font-size: 0.7rem;
    }

    /* Actions button simplification */
    #table-display .action-view {
        font-size: 0.7rem;
        padding: 0.2rem 0.4rem;
    }
}

/* ========================================= */
/* Index Page Header/Filter Stacking         */
/* ========================================= */
@media (max-width: 767.98px) {

    /* Reformat the main header to stack properly */
    .card-header.main-header {
        flex-direction: column;
        align-items: flex-start !important;
    }
    .card-header.main-header h1 {
        margin-bottom: 0.5rem;
    }

    /* Make the filter/action row wrap into a grid */
    .header-actions {
        display: grid;
        grid-template-columns: repeat(2, 1fr); /* Two columns for filters */
        gap: 0.5rem;
        width: 100%;
        margin-top: 0.5rem;
    }

    /* Filters should take up a grid column */
    .header-actions select,
    .header-actions input,
    .header-actions .form-control {
        grid-column: span 1;
        width: 100% !important;
        max-width: 100% !important;
        font-size: 0.85rem;
        padding: 0.375rem 0.5rem;
    }

    /* The "Create" button should span the full width or be placed strategically */
    .header-actions .btn-create-campaign {
        grid-column: 1 / -1; /* Span across all columns */
        font-size: 0.9rem;
    }

    /* Reformat Table Controls for stacking */
    .table-controls {
        flex-direction: column;
        gap: 0.5rem;
        padding: 1rem;
    }
    .table-controls .search-input,
    .table-controls .btn-export {
        width: 100%;
    }
}



/* ========================================= */
/* Stacked Country Phone Input Group Styling */
/* ========================================= */

.country-phone-group {
    /* 1. Force vertical stacking for the main components */
    display: flex !important;
    flex-direction: column !important; /* Forces the select and input to stack */
    align-items: stretch !important; /* Elements will take full width */
    gap: 0.5rem !important; /* Add some space between the stacked fields */
    width: 100% !important;
}

/* 2. Country Selector (Top Field) */
.country-phone-group #country-select {
    width: 100% !important; /* Ensure it takes full width */
    max-width: 100% !important;
    border-radius: 0.375rem !important; /* Restore standard border-radius */

    /* Style overrides for visual clarity */
    background-color: #f8f9fa !important;
    border: 1px solid #ced4da !important; /* Restore border */
    border-right: 1px solid #ced4da !important;
    color: #495057 !important;
    font-weight: 500 !important;
    font-size: 1rem !important;
    padding: 0.375rem 0.75rem !important;
}

/* 3. Phone Input Section (Bottom Field) */
.country-phone-group .flex-grow-1 {
    width: 100% !important; /* Ensure the wrapper takes full width */
}

.country-phone-group .input-group {
    width: 100% !important;
    flex-wrap: nowrap !important;
}

/* Fix Dial Code Display positioning */
.country-phone-group #dial-code-display {
    background-color: #e9ecef !important;
    color: #495057 !important;
    font-weight: 600 !important;

    /* Ensure the dial code input-group-text connects properly */
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
    border-right: 1px solid #ced4da !important;
    padding: 0.375rem 0.5rem !important;
}

/* Fix Phone Input Field positioning */
.country-phone-group input#phone {
    /* Ensure the phone field connects properly to the dial code text */
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    padding-left: 0.75rem !important;
}

/* Ensure consistent height */
.country-phone-group .form-select,
.country-phone-group .input-group-text,
.country-phone-group input.form-control {
    /* height: calc(1.5em + 0.75rem + 2px) !important; */
    box-sizing: border-box !important;
}


/* ======================================================== */
/* Table Alignment Fix for Name/Image/Icon Column           */
/* Targets the second <td> in the <tbody> (the Name column) */
/* ======================================================== */

/* Target the parent <td> of the Name column */
/* #product-list-view tbody tr > td:nth-child(2) {
    text-align: right !important;
} */

/* Target the flex container inside the <td> that holds the icon, image, and name */
/* #product-list-view tbody tr > td:nth-child(2) .d-flex {
    justify-content: flex-start !important;
    align-items: center !important;
    padding-left: 0px !important;
    margin-left: -24px !important;
} */

/* Optional: Adjust table header padding to align better with the content */
#product-list-view thead th:nth-child(2) {
    text-align: left !important;
    padding-left: 1.5rem !important; /* Adjust padding to match the content's new left position */
}

/* Ensure the expand button doesn't have excess margin pushing the content away */
#product-list-view .expand-brands {
    margin-right: 0.5rem !important; /* Keep the desired small gap */
    margin-left: 0 !important; /* Ensure no extra left margin */
}

/* Ensure the placeholder span is positioned correctly when the button is missing */
/* #product-list-view tbody tr > td:nth-child(2) .d-flex > span.me-2 {
    margin-right: 0.5rem !important;
    margin-left: 0 !important;
} */

/* ======================================================== */
/* CSS to move the brand expand button to the far right     */
/* ======================================================== */

/* Target the specific expand button using its class */
.expand-brands {
    /* Set the order to a high value (like 10) to visually place it last */
    order: 10 !important;

    /* Push the element to the far right edge of the flex container */
    margin-left: auto !important;

    /* Ensure it doesn't take up extra unnecessary space */
    margin-right: 0 !important;
}

/* Ensure the placeholder span (when no brands exist) is also pushed right for consistency */
/* The placeholder span is: <span class="me-2" style="width: 24px;"></span> */
/* #product-list-view tbody tr > td:nth-child(2) .d-flex > span[style="width: 24px;"] {
    order: 10 !important;
    margin-left: auto !important;
    margin-right: 0 !important;
} */

/* Ensure the parent d-flex container is setup correctly (if not already) */
/* #product-list-view tbody tr > td:nth-child(2) .d-flex {
    width: 100% !important;
    justify-content: flex-start !important;
}
 */

/* ======================================================== */
/* Left Alignment for ONLY the "Package Name" Column        */
/* ======================================================== */

/* 1. Target the header for "Package Name" (the second <th>) */
#product-list-view thead th:nth-child(2) {
    /* Set the column header text alignment to the left/start */
    text-align: left !important;
}

/* 2. Target the data cells for "Package Name" (the second <td>) */
/* #product-list-view tbody tr > td:nth-child(2) {
    text-align: left !important;
    padding-left: 1rem !important; 
} */

/* 3. Target the <p> tag inside the data cell to ensure it doesn't have conflicting centering styles */
/* #product-list-view tbody tr > td:nth-child(2) p.c-o-light {
    text-align: left !important;
    margin-left: 5px !important;
} */

/* ======================================================== */
/* FINAL OPTIMIZED CSS: Fixes Size, Icon Position, and Spacing */
/* ======================================================== */

/* Ensure the wrapper behaves correctly (Bootstrap default) */
.input-group {
    display: flex !important;
    width: 100% !important;
}

/* 1. FORCE the Country Code Selector to a SMALL fixed size */
.input-group .country-code {
    /* Critical Sizing: Prevents growth, sets fixed width */
    flex: 0 0 75px !important;
    width: 75px !important;
    max-width: 75px !important;

        /* === BORDER VISIBILITY FIX === */
    /* Added: Make the right border visible to separate it from the input */
    border-right: 1px solid #050000 !important;

    /* === ICON/TEXT SPACING FIXES === */
    /* 1a. Adjust padding: Use minimal right padding to save space for the arrow. */
    padding-right: 0.35rem !important;

    /* 1b. Move the dropdown arrow (background image) closer to the right edge.
       0.15rem is a small offset from the edge, moving it "more right". */
    background-position: right 0.15rem center !important;
    /* =============================== */

    /* Ensure content stays on one line and is clipped if necessary */
    white-space: nowrap !important;
    overflow: hidden !important;

    /* Correct border radius for the left element in an input group */
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;

    /* Optional: Smaller text to fit better */
    font-size: 0.9em !important;
}

/* 2. Ensure the Phone Number Input takes ALL the remaining space */
.input-group #phone_number {
    /* Allow it to grow and consume the rest of the available width */
    flex: 1 1 auto !important;
    width: auto !important;

    /* Correct border radius for the right element in an input group */
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

/* 3. Media Query for very small screens (phones) */
@media (max-width: 576px) {
    .input-group .country-code {
        /* Reduce the width slightly more for limited mobile space */
        flex: 0 0 65px !important;
        width: 65px !important;
        max-width: 65px !important;

        /* Tighter padding/positioning for mobile */
        padding-right: 0.2rem !important;
        background-position: right 0.1rem center !important;
    }
}


canvas#budgetVsSpendChart {
    padding-right: 50px;
    padding-top: 50px;
    padding-left: 50px;
}
/*
|--------------------------------------------------------------------------
| Responsive Table Styling (Forcing Horizontal Scroll)
|--------------------------------------------------------------------------
| This CSS ensures all columns remain visible on mobile devices by allowing
| the user to scroll horizontally within the table container.
*/

/* 1. Ensure the container enables horizontal scrolling when content overflows */
.recent-table.table-responsive, #clients-table-container {
    /* Explicitly enable horizontal scrolling */
    overflow-x: auto !important;
    /* Optional: Improves touch scrolling experience on mobile browsers */
    -webkit-overflow-scrolling: touch;
}

/* 2. Prevent content inside cells from wrapping, which helps keep columns compact */


/* 3. Ensure the main table is wide enough to force a scroll on small screens */
@media (max-width: 767px) {
    #product-list-view {
        /* Set a minimum width (adjust this value based on your content width) */
        min-width: 900px;
        width: max-content;
        table-layout: fixed; /* Ensures column widths are respected */
    }

    /* Ensure the Action column (last column) is compact */
    #product-list-view th:last-child,
    #product-list-view td:last-child {
        width: 120px; /* Fixed width for button group */
    }

    /* Ensure the Name column (second column) has enough space */
    /* #product-list-view th:nth-child(2),
    #product-list-view td:nth-child(2) {
        min-width: 180px;
    } */
}

/* 4. Ensure the collapsible brand table (nested table) also supports scrolling */
#product-list-view tr.collapse table {
    width: 100%;
    min-width: 800px; /* Adjust min-width for the nested table if it also gets too wide */
}
/*
|--------------------------------------------------------------------------
| OFF CANVAS RESPONSIVENESS
|--------------------------------------------------------------------------
| Overrides default Bootstrap offcanvas width to optimize usability on mobile.
*/

/* 1. Default width for medium/large screens (Adjust as necessary) */
.offcanvas.offcanvas-end {
    width: 450px; /* Standard width for desktop and tablet screens */
}

/* 2. Full Width on Small Screens (Mobile - less than 576px) */
@media (max-width: 575.98px) {
    .offcanvas.offcanvas-end {
        width: 100vw !important; /* Forces full screen width on mobile */
        max-width: 100vw !important;
    }
}

/*
|--------------------------------------------------------------------------
| FORM ELEMENT STYLES (Focus on Mobile Layout)
|--------------------------------------------------------------------------
*/

/* 3. Phone Input Group Layout Adjustment */
.country-phone-group {
    display: flex;
    gap: 0.5rem; /* Space between the country select and the phone input */
    align-items: flex-start; /* Aligns items to the top if height differs */
}

/* Ensure the country select box is compact and doesn't take unnecessary space */
.country-phone-group .form-select {
    flex-shrink: 0;
    width: 110px; /* Fixed width for country code selection */
}

/* 4. Scrollbar and Input Customization (Assumes custom-scrollbar is for offcanvas-body) */
.offcanvas-body.custom-scrollbar {
    /* If you have a custom scrollbar style, this ensures it applies to the body */
    overflow-y: auto;
    padding-bottom: 6rem; /* Ensures space at the bottom for fixed buttons */
}


/*
|--------------------------------------------------------------------------
| ACTIVITY TIMELINE BASE STYLES
|--------------------------------------------------------------------------
*/

/* General container styling */
.activity-tab-content {
    padding: 1.5rem 0;
}

/* Activity Header (Filters and Actions container) */
.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    padding: 0 1rem;
}

/* Filter Pills Group */
.filter-pills {
    flex-wrap: wrap; /* Allows filters to wrap to the next line if needed */
}

.filter-pills .btn {
    /* Base style for pill buttons */
    border-radius: 9999px;
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid #e2e8f0;
    color: #475569;
    transition: all 0.2s;
}

.filter-pills .btn.active {
    background-color: #0d6efd;
    color: white;
    border-color: #0d6efd;
}

/* Action Buttons Group (Add Note, Export Log) */
.action-buttons .btn {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
}


/*
|--------------------------------------------------------------------------
| MOBILE RESPONSIVENESS (Screens less than 768px wide)
|--------------------------------------------------------------------------
*/
@media (max-width: 768px) {
    .activity-header {
        /* Stack the filter pills and action buttons vertically on mobile */
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
        padding: 0 0.5rem;
    }

    .action-buttons {
        /* Use a grid to ensure action buttons are side-by-side and equal width */
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .filter-pills {
        /* Ensure filters start from the left */
        justify-content: flex-start;
    }
}


/*
|--------------------------------------------------------------------------
| TIMELINE CARD STYLING
|--------------------------------------------------------------------------
*/

.timeline-card {
    background: #ffffff;
    padding: 1.5rem 1rem;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.06);
}

.timeline {
    position: relative;
    padding-left: 2rem; /* Space for the vertical line and icons */
}

.timeline::before {
    /* The vertical timeline line */
    content: '';
    position: absolute;
    top: 0;
    left: 0.75rem;
    width: 2px;
    height: 100%;
    background-color: #e2e8f0;
}

.timeline-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 2rem;
    position: relative;
}

.timeline-icon {
    /* The circle icon container positioned over the vertical line */
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    z-index: 10;
    position: absolute;
    left: -0.25rem; /* Aligns the center of the icon to the vertical line */
    top: 0;
    border: 3px solid #ffffff;
}

.timeline-icon .fa {
    font-size: 0.75rem;
}

/* Icon Colors */
.icon-note { background-color: #6366f1; }
.icon-creation { background-color: #22c55e; }
.icon-approval { background-color: #f59e0b; }

.timeline-content {
    flex-grow: 1;
    padding-left: 1.5rem; /* Space past the icon for content */
}

.timeline-content .description {
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
}

.timeline-content .meta {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.25rem;
}
/*
|--------------------------------------------------------------------------
| CAMPAIGN BUDGET SECTION STYLES
|--------------------------------------------------------------------------
*/

.budget-tab-content {
    padding: 1.5rem 0;
}

/* --- Summary Cards --- */

.summary-card-budget {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%; /* Ensures all cards in the row have the same height */
}

.summary-card-budget .title {
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b; /* text-slate-500 */
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.summary-card-budget .value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b; /* text-slate-800 */
    line-height: 1.2;
}

/* --- Charts Section --- */

.chart-card {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    height: 100%;
}

.chart-card h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 0.75rem;
}


/* --- Details Table --- */

.details-card {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-top: 0.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.details-card h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.details-table thead th {
    font-size: 0.75rem; /* Smaller, uppercase headers */
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 0.75rem;
    padding-top: 0.25rem;
}

.details-table tbody td {
    font-size: 0.875rem;
    color: #334155;
    vertical-align: middle;
}

/* Status Badges for table clarity */
.status-badge {
    display: inline-block;
    padding: 0.3rem 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-in-progress {
    background-color: #fef3c7; /* light yellow */
    color: #d97706; /* dark yellow/orange */
}

.status-paid {
    background-color: #d1fae5; /* light green */
    color: #059669; /* dark green */
}

.status-pending {
    background-color: #bfdbfe; /* light blue */
    color: #1d4ed8; /* dark blue */
}

.status-not-started {
    background-color: #fee2e2; /* light red */
    color: #b91c1c; /* dark red */
}


/*
|--------------------------------------------------------------------------
| MOBILE OPTIMIZATION
|--------------------------------------------------------------------------
| Adjusts padding and font sizes for a cleaner look on very small screens.
*/

@media (max-width: 576px) {
    /* Reduce card padding and margins on extra small screens for better space use */
    .summary-card-budget,
    .chart-card,
    .details-card {
        padding: 1rem;
        margin-bottom: 1rem;
    }

    .summary-card-budget .value {
        font-size: 1.5rem; /* Slightly smaller value text */
    }

    /* Reduce table header padding and size on mobile */
    .details-table thead th {
        font-size: 0.65rem;
        padding: 0.5rem;
    }
}


/*
|--------------------------------------------------------------------------
| CAMPAIGN BUDGET SECTION STYLES
|--------------------------------------------------------------------------
*/

.budget-tab-content {
    padding: 1.5rem 0;
}

/* --- Summary Cards --- */

.summary-card-budget {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%; /* Ensures all cards in the row have the same height */
}

.summary-card-budget .title {
    font-size: 0.875rem;
    font-weight: 500;
    color: #64748b; /* text-slate-500 */
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.summary-card-budget .value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b; /* text-slate-800 */
    line-height: 1.2;
}

/* --- Charts Section --- */

.chart-card {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    height: 100%;
}

.chart-card h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 0.75rem;
}


/* --- Details Table --- */

.details-card {
    background-color: #ffffff;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-top: 0.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

.details-card h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.details-table thead th {
    font-size: 0.75rem; /* Smaller, uppercase headers */
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 0.75rem;
    padding-top: 0.25rem;
}

.details-table tbody td {
    font-size: 0.875rem;
    color: #334155;
    vertical-align: middle;
}

/* Status Badges for table clarity */
.status-badge {
    display: inline-block;
    padding: 0.3rem 0.6rem;
    border-radius: 0.5rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-in-progress {
    background-color: #fef3c7; /* light yellow */
    color: #d97706; /* dark yellow/orange */
}

.status-paid {
    background-color: #d1fae5; /* light green */
    color: #059669; /* dark green */
}

.status-pending {
    background-color: #bfdbfe; /* light blue */
    color: #1d4ed8; /* dark blue */
}

.status-not-started {
    background-color: #fee2e2; /* light red */
    color: #b91c1c; /* dark red */
}


/*
|--------------------------------------------------------------------------
| CREATOR LIST STYLES (Used for dynamic table-like layouts)
|--------------------------------------------------------------------------
*/

.creator-row {
    display: grid;
    /* Define 7 columns for desktop view: Creator (1.5x), 5 standard columns, Actions (1.5x) */
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr 1fr 1.5fr;
    gap: 1rem;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f5f9; /* Subtle divider */
}

.creator-row:last-child {
    border-bottom: none;
}

.data-cell {
    font-size: 0.875rem;
    color: #334155;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
}

/* Creator cell specific styling */
.creator-row .creator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.creator-info img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e2e8f0;
}

.creator-details .name {
    font-weight: 600;
    color: #1e293b;
    line-height: 1.2;
}

.creator-details .handle {
    font-size: 0.75rem;
    color: #64748b;
}

/* Status Badge - Reusing existing styles but adding 'active' color */
.status-badge.status-active {
    background-color: #dbeafe; /* light blue */
    color: #1d4ed8; /* dark blue */
}

/* Action Buttons */
.creator-row .data-cell:last-child {
    gap: 0.5rem;
    justify-content: flex-end; /* Push buttons to the right */
}

.creator-row .btn {
    font-size: 0.75rem;
    padding: 0.3rem 0.6rem;
    border-radius: 0.4rem;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
    line-height: 1; /* Tighter button text */
}

/* --- Responsive Adaptations for Mobile --- */

@media (max-width: 768px) {
    .creator-row {
        /* On small screens, stack the items and use the remaining space efficiently */
        display: flex;
        flex-direction: column;
        padding: 1rem 0;
        gap: 0.5rem;
        align-items: flex-start;
    }

    .data-cell {
        /* Make each data cell full width, except for actions which are handled separately */
        width: 100%;
        display: flex;
        justify-content: space-between;
        padding-left: 0.5rem;
        border-left: 3px solid #f1f5f9;
        
        /* Visually hide the data on mobile and use the data-cell's implicit order */
        /* To make this truly table-like on mobile, you'd need the column header,
           but for simplicity, we'll format key info first. */
    }
    
    /* Ensure the creator cell (which has the avatar) stays at the top and is full width */
    .creator-row .creator {
        order: -1; /* Puts it at the very top */
        width: 100%;
        padding-left: 0;
        border-left: none;
    }

    /* Actions cell remains at the bottom */
    .creator-row .data-cell:last-child {
        order: 99; /* Puts it at the very bottom */
        justify-content: flex-start;
        padding-left: 0.5rem;
    }

    /* To improve readability on mobile, we can slightly darken data cells and prefix them
       using a pseudo-element if we were to add structure, but sticking to
       just layout changes for simplicity. */
}


/*
|--------------------------------------------------------------------------
| MOBILE OPTIMIZATION (Existing styles)
|--------------------------------------------------------------------------
*/

@media (max-width: 576px) {
    /* Reduce card padding and margins on extra small screens for better space use */
    .summary-card-budget,
    .chart-card,
    .details-card {
        padding: 1rem;
        margin-bottom: 1rem;
    }

    .summary-card-budget .value {
        font-size: 1.5rem; /* Slightly smaller value text */
    }

    /* Reduce table header padding and size on mobile */
    .details-table thead th {
        font-size: 0.65rem;
        padding: 0.5rem;
    }
}
/* ------------------------------------------------------------------- */
/* GENERAL LAYOUT & CARDS */
/* ------------------------------------------------------------------- */
.creators-tab-content {
    padding: 10px 0;
}

/* Ensure summary cards have consistent look and spacing */
.summary-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s;
    height: 100%; /* Ensure all cards in a row have the same height */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.summary-card .title {
    font-size: 14px;
    color: #6c757d;
    text-transform: uppercase;
    margin-bottom: 8px;
    font-weight: 600;
}

.summary-card .value {
    font-size: 32px;
    font-weight: 800;
    color: #343a40;
}

.creators-main-card {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    margin-top: 20px;
}

/* ------------------------------------------------------------------- */
/* FILTER BAR RESPONSIVENESS */
/* ------------------------------------------------------------------- */
.filters-bar {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #e9ecef;
}

.search-input-wrapper {
    position: relative;
    flex-grow: 1;
    max-width: 450px; /* Limit max width on desktop */
}

.search-input-wrapper .form-control {
    padding-left: 35px;
    border-radius: 8px;
}

.search-input-wrapper .fa-search {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #ced4da;
    font-size: 14px;
}

/* Mobile adjustments for Filters Bar */
@media (max-width: 768px) {
    .filters-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 15px;
    }

    .search-input-wrapper {
        max-width: none; /* Full width search on mobile */
    }

    .filters-bar .btn-primary {
        width: 100%; /* Full width button on mobile */
    }
}

/* ------------------------------------------------------------------- */
/* CREATORS LIST (TABLE TO CARD VIEW) RESPONSIVENESS */
/* ------------------------------------------------------------------- */

/* Desktop/Tablet Grid View (default) */
.creators-list-header,
.creator-row {
    display: grid;
    /* Define 7 columns with responsive weighting */
    grid-template-columns: 1.5fr 1fr 1fr 0.8fr 1.2fr 1fr 0.7fr;
    gap: 15px;
    padding: 12px 20px;
    align-items: center;
}

.creators-list-header {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
    font-size: 12px;
    text-transform: uppercase;
    border-bottom: 1px solid #e9ecef;
}

.creator-row {
    font-size: 14px;
    color: #495057;
    border-bottom: 1px solid #f1f1f1;
    transition: background-color 0.2s;
}

.creator-row:last-child {
    border-bottom: none;
}

.creator-row:hover {
    background-color: #f8f9fa;
}

/* Mobile adjustments - Stacking table cells into a card view */
@media (max-width: 992px) {
    /* Hide the traditional desktop header */
    .creators-list-header {
        display: none;
    }

    .creator-row {
        /* Reset to flex/block for card structure */
        display: flex;
        flex-direction: column;
        padding: 15px;
        margin: 10px; /* Add margin between rows */
        border: 1px solid #e9ecef;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    }
    
    /* Apply a distinct style to each data cell */
    .creator-row > div {
        display: flex;
        justify-content: space-between;
        padding: 8px 0;
        border-bottom: 1px dotted #e9ecef;
    }

    .creator-row > div:last-child {
        border-bottom: none;
        padding-bottom: 0;
        padding-top: 15px; /* Separate actions */
    }

    /* Key: Add mobile labels using pseudo-elements */
    .creator-row .creator::before { content: "Creator:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .platform::before { content: "Platform:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .deliverables::before { content: "Deliverables:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .status::before { content: "Status:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .budget::before { content: "Budget:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .engagement-rate::before { content: "Engagement:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }
    .creator-row .actions::before { content: "Actions:"; font-weight: 600; color: #343a40; flex-shrink: 0; margin-right: 10px; }

    /* Fix for the actions column to be centered/left aligned */
    .creator-row .actions {
        display: block; /* Actions typically need to stack */
        text-align: center;
    }
    .creator-row .actions::before {
        display: none; /* Hide action label on top of buttons */
    }
}


/* ------------------------------------------------------------------- */
/* INSTAGRAM REELS GRID RESPONSIVENESS (Existing, slightly refined) */
/* ------------------------------------------------------------------- */
.reels-grid {
    display: grid;
    /* Large screens: 6 columns, minimum 180px wide */
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

/* Tablet: 4 columns */
@media (max-width: 992px) {
    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }
}

/* Mobile: 2 columns */
@media (max-width: 480px) {
    .reels-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}
#creators-invite-table {
    width: 100%;
    table-layout: fixed; /* Ensures both thead & tbody share same column widths */
  }
  
  #creators-invite-table th,
  #creators-invite-table td {
    width: 50%; /* 2 equal columns — adjust if needed */
    vertical-align: middle;
  }
  
  #creators-invite-table thead th:first-child,
  #creators-invite-table tbody td:first-child {
    text-align: left;
  }
  
  #creators-invite-table thead th:last-child,
  #creators-invite-table tbody td:last-child {
    text-align: center!important;
  }
  

      .btn-top-red {
        background-color: #fff !important;
        border: 1px solid #E3463B !important;
        color: #E3463B !important;
    }
    .btn-top-red:hover,
    .btn-top-red:focus {
        background-color: #E3463B !important;
        color: #fff !important;
        border-color: #E3463B !important;
        box-shadow: none !important;
    }

.rating-stars .fa-star,
.rating-stars .fa-star-half-alt,
.rating-stars .fa-star-o {
color: #ffc107;
}

.rating-input .rating-star {
    font-size: 1.5rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s ease;
}

.rating-input .rating-star.fas,
.rating-input .rating-star.active {
    color: #ffc107;
}

.rating-input .rating-star.hover {
    color: #ffdd44 !important;
}

.rating-input .rating-star:hover {
    color: #ffdd44;
}

.rating-stars-input {
    display: flex;
    gap: 2px;
}