/* ============================================================
   STYLE GLOBAL (Comparaison + Alertes)
   ============================================================ */
body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background-color: #f7f8fa;
    color: #333;
}

h3 {
    margin-bottom: 10px;
}

.table-container {
    margin: 20px 50px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    padding: 20px;
}

/* ============================================================
   TABLEAUX
   ============================================================ */
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

th, td {
    padding: 8px 10px;
    text-align: center;
}

/* En-têtes colorés selon contexte */
th {
    color: white;
    position: sticky;
    top: 0;
}

.table-comparison th {
    background-color: #0078D7; /* bleu comparaison */
}

.table-alerts th {
    background-color: #c0392b; /* rouge alertes */
}

tr:nth-child(even) {
    background-color: #f2f6f9;
}

tr:hover {
    background-color: #e5f1ff;
}

.table-alerts tr:hover {
    background-color: #fdecea;
}
#priceTable th:first-child,
#priceTable td:first-child {
    width: 35px;
    text-align: center;
}

.row-check {
    transform: scale(1.1);
    cursor: pointer;
}

#updateSelectedBtn {
    padding: 8px 16px;
    font-weight: 600;
}

/* ============================================================
   STATUTS ET ALERTES
   ============================================================ */
.status {
    font-weight: bold;
}

.status[data-status="⚠️ Différence de prix"] {
    color: #e67e22;
}

.status[data-status="❌ Absente de SAGE"] {
    color: #c0392b;
}

.status[data-status="❌ Absente de PRESTA"] {
    color: #8e44ad;
}

.status[data-status="✅ Identique"] {
    color: #27ae60;
}

.status-critical {
    color: #e74c3c;
    font-weight: bold;
}

.status-warning {
    color: #f39c12;
    font-weight: bold;
}
/* ============================================================
   CONTEXTE SELECTOR
   ============================================================ */
.menu {
	width:50%;
}
.console {
	width:50%;
}
.context-handler {
	display:flex;
	margin:10px 50px;
}
.shopSelectorHandler {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: center;
}
.context-selector {
	
}
#shopSelector {
	padding: 10px 15px;
    border-radius: 5px;
}
/* ============================================================
   CONSOLE
   ============================================================ */
.sub-title {
	text-align:center;
	font-weight:500;
}

#console {
	font-family: monospace;
    background: #fff;
    border: 1px solid;
    padding: 5px;
    height: 150px;
    margin: 5px 50px;
    overflow: auto;	  
}
/* ============================================================
   FILTRES
   ============================================================ */
.filters {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px;
}

.filters label {
    margin-right: 10px;
    font-weight: 600;
}

.filters select,
.filters input {
    padding: 5px;
    font-size: 13px;
}

/* ============================================================
   BOUTONS
   ============================================================ */
.details-btn,
.update-btn {
    border: none;
    color: white;
    padding: 6px 12px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
    font-weight: 500;
}

.details-btn {
    background-color: #0078D7;
}
.details-btn:hover {
    background-color: #005ea3;
}

.update-btn.active {
    background-color: #ff9800;
}
.update-btn.active:hover {
    background-color: #f57c00;
}
.update-btn.disabled,
.update-btn[disabled] {
    background-color: #ddd;
    color: #888;
    cursor: not-allowed;
    opacity: 0.6;
}
.update-btn.updated {
    background-color: #4aae27 !important;
    color: white !important;
    cursor: not-allowed;
    opacity: 0.8;
}
.btn {
	color: white;
	border: none;
	padding: 10px 20px;
    border-radius: 25px;
	cursor: pointer;
	font-weight: 600;
	transition: 0.2s ease;
}
.btn:active {
	transform: scale(0.97);
}
.validate-btn {
	background-color: #4aae27;
}
.validate-btn:hover {
	background-color: #1e8449;
}
.alert-btn {
	background-color: #ae2727;
}
.alert-btn:hover {
	background-color: #df2424;
}

/* ============================================================
   POPUP
   ============================================================ */
#popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    z-index: 9999;
    padding: 20px;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
}

.popup-content {
	display: flex;
    flex-direction: column;
    align-items: center;	
}

.popup-close {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 18px;
    cursor: pointer;
}

#disableScreenMask {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);
    z-index: 9998;
}

/* ============================================================
   COULEURS THÉMATIQUES
   ============================================================ */
:root {
    --color-blue: #0078D7;
    --color-orange: #ff9800;
    --color-green: #27ae60;
    --color-red: #c0392b;
    --color-warning: #f39c12;
    --color-light-bg: #f7f8fa;
}
