/* Reprend le vocabulaire visuel de l'application SLA : même Bootstrap, mêmes couleurs. */

html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html { font-size: 16px; }
}

body {
    margin-bottom: 40px;
    background-color: #dcdcdc;
}

a { color: #0077cc; }

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.navbar-brand { font-weight: bold; }

.border-bottom { border-bottom: 1px solid #e5e5e5; }

.box-shadow { box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05); }

.card { border-radius: 10px; }

h1.page-title {
    font-size: 18px;
    font-weight: bold;
}

.mono {
    font-family: ui-monospace, Consolas, "SF Mono", Menlo, monospace;
}

/* Aperçu du nom composé, écran Générer */
.name-segment {
    border-radius: 8px;
    padding: 6px 12px;
    font-family: ui-monospace, Consolas, "SF Mono", Menlo, monospace;
    font-size: 28px;
    font-weight: 600;
}

.name-segment-label {
    font-size: 12px;
    color: #6c757d;
    text-align: center;
    margin-top: 8px;
}

.name-dash {
    font-family: ui-monospace, Consolas, monospace;
    font-size: 28px;
    color: #adb5bd;
    align-self: center;
}

.seg-org { background: #eef1f5; color: #495057; }
.seg-type { background: #e3effb; color: #1861ac; }
.seg-env { background: #f1e8fc; color: #7b3fc4; }
.seg-svc { background: #e2f3ef; color: #146c5a; }
.seg-num { background: #fdf0e3; color: #a15c11; }

/* Grille d'occupation des plages */
.range-grid {
    display: grid;
    grid-template-columns: repeat(16, minmax(0, 1fr));
    gap: 4px;
}

.range-cell {
    font-family: ui-monospace, Consolas, monospace;
    font-size: 12px;
    text-align: center;
    padding: 5px 0;
    border-radius: 4px;
    border: 1px solid transparent;
}

.range-cell-assigned { background: #1b6ec2; color: #fff; border-color: #1b6ec2; }
.range-cell-reserved { background: #ffc107; color: #664d03; border-color: #ffc107; }
.range-cell-free { background: #f8f9fa; color: #adb5bd; border-color: #dee2e6; }
.range-cell-clash { background: #b02a37; color: #fff; border-color: #b02a37; }

/* ---------------------------------------------------------------------------
   Compléments Bootstrap
   Le projet embarque Bootstrap 5.1, comme l'application SLA. Les utilitaires
   ci-dessous n'existent qu'à partir de 5.2 (fw-semibold) et 5.3 (les variantes
   subtle et emphasis). Sans eux, un .badge garde son color:#fff d'origine et
   se retrouve blanc sur blanc. Les valeurs reprennent celles de Bootstrap 5.3.
   À supprimer le jour où la librairie est mise à jour.
   --------------------------------------------------------------------------- */

.fw-semibold { font-weight: 600 !important; }

.bg-primary-subtle { background-color: #cfe2ff !important; }
.bg-secondary-subtle { background-color: #e2e3e5 !important; }
.bg-success-subtle { background-color: #d1e7dd !important; }
.bg-danger-subtle { background-color: #f8d7da !important; }
.bg-warning-subtle { background-color: #fff3cd !important; }
.bg-info-subtle { background-color: #cff4fc !important; }

.text-primary-emphasis { color: #052c65 !important; }
.text-secondary-emphasis { color: #2b2f32 !important; }
.text-success-emphasis { color: #0a3622 !important; }
.text-danger-emphasis { color: #58151c !important; }
.text-warning-emphasis { color: #664d03 !important; }
.text-info-emphasis { color: #055160 !important; }

.border-primary-subtle { border-color: #9ec5fe !important; }
.border-secondary-subtle { border-color: #c4c8cb !important; }
.border-success-subtle { border-color: #a3cfbb !important; }
.border-danger-subtle { border-color: #f1aeb5 !important; }
.border-warning-subtle { border-color: #ffe69c !important; }
.border-info-subtle { border-color: #9eeaf9 !important; }

/* Ligne de saisie d'un nouveau référentiel, en pied de tableau */
.ref-add td { background: #f8f9fa; vertical-align: middle; }
.ref-add .form-control,
.ref-add .form-select { font-size: 14px; padding: 4px 8px; height: 32px; }
