/* ============================================
   HISTORY - ULTRA MINIMALISTE (AUCUNE BORDURE VERTICALE)
   ============================================ */

/* Layout sidebar */
.ib-page-wrapper {
    display: flex;
    min-height: 100vh;
    background: #F3F6FB;
}

.ib-sidebar-container {
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    width: 280px;
    z-index: 1000;
 
}

body.sidebar-collapsed .ib-sidebar-container {
    width: 70px;
}

.ib-main-content {
    flex: 1;
    margin-left: 280px;
    min-height: 100vh;
    overflow: hidden; /* PAS DE SCROLL */
}

body.sidebar-collapsed .ib-main-content {
    margin-left: 70px;
}

.ib-content-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 32px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0; 
    height: 100%; 
    overflow-y: auto;
    overflow-x: hidden;
}

/* History content */
.ib-history-container {
    width: 100%;
    background: transparent;
    overflow: visible; /* PAS DE SCROLL */
}

.ib-history-main {
    width: 100%;
 	
	padding-left:40px;
	padding-right:40px; 
	padding-top:88px;
}


table caption+thead tr:first-child td, table caption+thead tr:first-child th, table colgroup+thead tr:first-child td, table colgroup+thead tr:first-child th, table thead:first-child tr:first-child td, table thead:first-child tr:first-child th {
	border-block-start: none!important;
}

/* Header */
.ib-history-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 50px;
    border-bottom: 1px solid #9ca3af2b;
}

.ib-history-header h1 {
    color: #000;
    font-size: 2.25rem;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.ib-history-header p {
    color: #6B7280;
   font-size: 1rem;
   
    font-weight: 400;
}

/* Empty state */
.ib-history-empty {
    text-align: center;
    padding-top: 100px;
}

.ib-history-empty h3 {
    color: #000;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.ib-history-empty p {
    color: #6B7280;
    font-size: 14px;
    margin: 0 0 24px 0;
}

.ib-btn-primary {
    padding: 10px 20px;
    background: #000;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
	border-radius:50px;
}
.ib-btn-primary:hover{
	color:white!important;
	background-color:#0047FF!important;
}
/* ============================================
   TABLE - AUCUNE BORDURE VERTICALE
   ============================================ */

.ib-history-table-wrapper {
    background: transparent;
    border: none;
    overflow: visible; /* PAS DE SCROLL */
    margin-top: 0; /* PAS d'espace qui crée un trait supplémentaire */
}

.ib-history-table {
    width: 100%;
    border-collapse: collapse;
    background: transparent;
}

/* Headers */
.ib-history-table thead {
    background: transparent;
    border-top: none; /* PAS de trait avant les headers */
}

.ib-history-table thead th {
    text-align: left;
    padding: 12px 16px;
    font-weight: 500;
    font-size: 13px;
    color: #6B7280;
    border: none;
    border-top: none; /* PAS de trait avant */
    border-bottom: 1px solid #E5E7EB; /* TRAIT UN PEU VISIBLE après les headers */
}

.ib-history-table thead th:last-child {
    text-align: center;
}

/* Rows */
.ib-history-table tbody tr {
    background: transparent;
    border: none;
    border-bottom: 1px solid #9ca3af2b; 
}

.ib-history-table tbody tr:last-child {
    border-bottom: none;
}

/* AUCUN HOVER */
.ib-history-table tbody tr:hover {
    background: transparent !important;
}

/* Cells */
.ib-history-table tbody td {
    padding: 16px;
    font-size: 14px;
    color: #374151;
    font-weight: 400;
    border: none;
    background: transparent;
}

/* Customer column */
.ib-history-customer {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ib-history-customer::before {
    content: '';
    width: 18px;
    height: 18px;
    background-image: url('https://invoicebrokers.com/wp-content/uploads/2025/10/Frame-3-1.png');
    background-size: contain;
    background-repeat: no-repeat;
    flex-shrink: 0;
}

.ib-history-customer svg {
    display: none;
}

/* Type column */
.ib-history-type {
    color: #374151;
    font-size: 14px;
}

/* Date column */
.ib-history-date {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #6B7280;
    font-size: 14px;
}


table tbody>tr:nth-child(odd)>td, table tbody>tr:nth-child(odd)>th {
	background-color:#F3F6FB!important;
}

.ib-history-date::before {
    content: '';
    width: 16px;
    height: 16px;
    background-image: url('https://invoicebrokers.com/wp-content/uploads/2025/10/Vector.png');
    background-size: contain;
    background-repeat: no-repeat;
    flex-shrink: 0;
}

.ib-history-date svg {
    display: none;
}

/* Action column */
.ib-history-action {
    text-align: center;
}

.ib-history-view-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.ib-history-view-btn:hover {
    background: transparent !important;
}

.ib-history-view-btn svg {
    display: none;
}

.ib-history-view-btn::after {
    content: '';
    width: 18px;
    height: 18px;
    background-image: url('https://invoicebrokers.com/wp-content/uploads/2025/10/Frame-4-1.png');
    background-size: contain;
    background-repeat: no-repeat;
    display: block;
}

/* ============================================
   PAGINATION
   ============================================ */

.ib-history-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 20px 0;
    background: transparent;
}

.ib-pagination-btn {
    padding: 8px 14px;
    background: transparent;
    border: 1px solid #D1D5DB;
    border-radius: 12px;
    color: #374151;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
}

.ib-pagination-btn:disabled {
    opacity: 0.4;
}

.ib-pagination-btn.active {
    background: #000;
    color: #fff;
    border-color: #000;
}

.ib-pagination-info {
    color: #6B7280;
    font-size: 14px;
    padding: 0 12px;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
    .ib-main-content {
        margin-left: 0;
        overflow-y: auto; /* Scroll autorisé sur mobile */
    }
    
    .ib-sidebar-container {
        transform: translateX(-100%);
    }
	.ib-content-inner{
		padding:60px 0px 0px 0px;	

	}
	.ib-history-table tbody tr:last-child{
		border-bottom:1px solid #e5e7eb;
	}
	 
    .ib-history-header p {
        /*font-size: 14px;*/
    }
    
}

/* @media (max-width: 768px) {
    .ib-content-inner {
        padding: 24px 16px;
    }
    
    .ib-history-table thead th,
    .ib-history-table tbody td {
        padding: 12px 8px;
    }
} */




/* ============================================
   RESPONSIVE MOBILE - TABLE SCROLL HORIZONTAL
   ============================================ */

/* @media (max-width: 768px) {
    .ib-history-main {
        padding: 24px 16px;
    }
    
    .ib-history-header {
        padding-bottom: 24px;
        margin-bottom: 24px;
    }
    
    .ib-history-header h1 {
        font-size: 24px;
    }
    
    .ib-history-header p {
        font-size: 14px;
    }
    
   
    .ib-history-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -16px;
        padding: 0 16px;
    }
    
    .ib-history-table {
        min-width: 600px; 
    }
    
    .ib-history-table thead th {
        padding: 12px 12px;
        font-size: 12px;
        white-space: nowrap;
    }
    
    .ib-history-table tbody td {
        padding: 14px 12px;
        font-size: 13px;
    }
    
   
    .ib-history-customer {
        gap: 8px;
        font-size: 13px;
    }
    
    .ib-history-customer::before {
        width: 16px;
        height: 16px;
    }
    
    
    .ib-history-date {
        gap: 6px;
        font-size: 13px;
    }
    
    .ib-history-date::before {
        width: 14px;
        height: 14px;
    }
    
  
    .ib-history-type {
        font-size: 13px;
    } */
    
/*
    .ib-history-view-btn::after {
        width: 16px;
        height: 16px;
    }
    
    .ib-history-pagination {
        flex-wrap: wrap;
        padding: 16px 0;
    }
    
    .ib-pagination-btn {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .ib-pagination-info {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .ib-history-main {
        padding: 16px 12px;
    }
    
    .ib-history-header h1 {
        font-size: 20px;
    }
    
    .ib-history-table {
        min-width: 500px; 
    }
}
 */

/* ============================================
   RESPONSIVE MOBILE - (NO SCROLL)
   ============================================ */

@media (max-width: 768px) {
    .ib-history-main {
        padding: 24px 16px;
    }
    
    .ib-history-header {
        padding-bottom: 20px;
        margin-bottom: 20px;
    }
    
    .ib-history-header h1 {
        font-size: 24px;
    }
   
    /* Cacher la table, afficher en liste */
    .ib-history-table thead {
        display: none;
    }
    
    .ib-history-table,
    .ib-history-table tbody,
    .ib-history-table tr {
        display: block;
        width: 100%;
    }
    
    .ib-history-table tbody tr {
        background: white;
        border: 1px solid #e5e7eb;
        border-radius: 12px;
        padding: 16px;
        margin-bottom: 12px;
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    
    .ib-history-table tbody td {
        display: block;
        padding: 0;
        border: none;
    }
    
    /* Customer name - en gros */
    .ib-history-customer {
        font-size: 16px;
        font-weight: 600;
        color: #111827;
        order: 1;
    }
    
    /* Type et Date sur la même ligne */
    .ib-history-table tbody td:nth-child(2),
    .ib-history-table tbody td:nth-child(3) {
        display: inline-block;
        width: auto;
    }
    
    .ib-history-table tbody td:nth-child(2) {
        order: 2;
    }
    
    .ib-history-table tbody td:nth-child(3) {
        order: 3;
        margin-left: 12px;
    }
    
    /* Bouton à droite */
    .ib-history-action {
        order: 4;
        text-align: right;
        position: absolute;
        top: 16px;
        right: 16px;
    }
    
    .ib-history-table tbody tr {
        position: relative;
    }
    
    .ib-pagination-btn {
        padding: 10px 16px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .ib-history-main {
        padding: 16px 12px;
    }
    
 
    
    .ib-history-table tbody tr {
        padding: 14px;
    }
}


.preload * {
    transition: none !important;
}