/* Reset des marges et des paddings */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Styles pour le body utilisé dans les pages buildings.html, ferme.html, centrale.html, rempart.html */
body {
    font-family: Arial, sans-serif;
    background-image: url('../images/fond.jpg');
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #ffffff; /* Couleur du texte en blanc pour plus de lisibilité */
    background-color: #2c2f33; /* Couleur de fond par défaut */
    display: grid;
	margin: 0;
	min-height: 100vh;
    grid-template-rows: auto 1fr auto;
}

/* Styles pour le container utilisé dans les pages base.html */
.container-base {
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0); /* Fond semi-transparent pour plus de lisibilité */
    border-radius: 10px;
}

/* Styles pour le container utilisé dans les pages base.html */
.container-base2 {
    width: 50%;
    margin: auto;
    padding: 2px;
    background-color: rgba(0, 0, 0, 0); /* Fond semi-transparent pour plus de lisibilité */
    border-radius: 10px;
}

/* Styles pour le container utilisé dans les pages buildings.html, ferme.html, centrale.html, rempart.html */
.container {
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.5); /* Fond semi-transparent pour plus de lisibilité */
    border-radius: 10px;
}

/* Styles pour le container utilisé dans les pages buildings.html, ferme.html, centrale.html, rempart.html */
.container2 {
    width: 100%;
    margin: 0 auto;
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.226); /* Fond semi-transparent pour plus de lisibilité */
    border-radius: 10px;
}

/* Styles pour le header utilisé dans les pages buildings.html, ferme.html, centrale.html, rempart.html */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.8); /* Fond semi-transparent */
    border-bottom: 2px solid #7289da;
}

.header h1 {
    font-size: 24px;
}

.header nav a {
    margin: 0 10px;
    text-decoration: none;
    color: #ffffff;
    font-weight: bold;
}

/* Styles pour les bâtiments utilisé dans la page buildings.html */
.buildings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
}

.building, .countdown {
    background-color: #23272aa8;
    border: 1px solid #99aab5;
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.3s;
    text-align: center;
}

.building h2, .countdown h2 {
    font-size: 20px;
    margin-bottom: 10px;
}

.building img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 10px;
}

.building p, .countdown p {
    margin-bottom: 10px;
}

/* Styles pour les boutons utilisés dans toute l'application */
button, .enter_button {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    background-color: #7289da;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
    text-decoration: none;
    text-align: center;
    display: inline-block;
    font-size: 16px;
}
    
button:hover, .enter_button:hover {
    background-color: #5b6eae; /* Couleur au survol des boutons de buildings */
}

.building:hover {
    transform: translateY(-5px);
}

/* Styles spécifiques à la page usine.html, ferme.html, centrale.html, rempart.html */
.container-usine, .container-ferme, .container-centrale, .container-rempart, .container-commandement {
    display: flex;
    flex-direction: column;
    margin: 20px;
}

.container-explo {
    display: flex;
    flex-direction: column;
}

.top-section {
    display: flex;
}

.left-section {
    flex: 2;
    margin-right: 20px;
}

.right-section {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.right-section-profil {
    flex: 1;
    display: flex;
    flex-direction: row;
}

.right-section-explo {
    flex: 1;
    display: flex;
    flex-direction: column;
    width: 90%;
}

.image-section {
    margin-bottom: 20px;
}

.image-section-explo {
    margin-bottom: 5px;
    margin-right: 50px;

}

.image-section img {
    width: 100%;
    border-radius: 10px;
}

.image-section-robot img {
    width: 50%;
    border-radius: 10px;
}
/* Cadres utilisés dans les pages usine.html, ferme.html, centrale.html, rempart.html */
.resources, .assignments, .other-assignments, .lore, .events {
    background-color: rgba(27, 31, 34, 0.418); /* Couleur de fond avec transparence de 50% */
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    color: white; /* Assurer que le texte est lisible sur le fond */
}

/* Cadres utilisés dans les pages usine.html, ferme.html, centrale.html, rempart.html */
.resources2 {
    background-color: rgba(35, 39, 42, 0); /* Couleur de fond avec transparence de 50% */
    padding: 5px;
    border-radius: 10px;
    color: white; /* Assurer que le texte est lisible sur le fond */
    display: center;
    height: auto;
    margin-top: 5px;

}

.resources3 {
    background-color: rgba(27, 31, 34, 0.418); /* Couleur de fond avec transparence de 50% */
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    color: white; /* Assurer que le texte est lisible sur le fond */
    width: 70%;
}

.title-lore {
    text-decoration: underline;
    font-weight: bold;
}

.resources h3, .assignments h2, .other-assignments h2, .events h2 , .resources3 h3 {
    border-bottom: 2px solid #555;
    padding-bottom: 10px;
    font-weight: bold;
    color: #FFA500; /* Couleur orange moderne */
}

/* Textes des ressources utilisés dans les pages usine.html, ferme.html, centrale.html, rempart.html */
.resource {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-weight: bold;
    color: white; /* Couleur blanche pour les ressources */
}

.production-hour {
    color: red; /* Couleur rouge pour "Production par heure" */
}

/* Liste des personnages utilisés dans les pages usine.html, ferme.html, centrale.html, rempart.html */
.character-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around; /* Aligner les personnages en lignes */
}

.character-list2 {
    display: flex;
    flex-direction: column; /* Assurez-vous que les éléments sont empilés verticalement */
    align-items: center; /* Centre horizontalement les éléments */
    width: 100%;
}

.character-item {
    display: flex;
    align-items: center;
    margin: 10px;
    background-color: rgba(51, 65, 85, 0.8); /* Couleur de fond plus moderne et semi-transparente */
    padding: 10px;
    border-radius: 5px;
    width: 45%;
}

.character-item img {
    width: 40px;
    height: 40px;
    margin-right: 5px;
    border-radius: 50%;
}

/* Boutons d'assignation utilisés dans les pages usine.html, ferme.html, centrale.html, rempart.html */
.assign-buttons {
    display: flex;
    justify-content: space-around;
    margin-bottom: 20px;
}


/* Conteneur pour les graphiques utilisés dans les pages usine.html, ferme.html, centrale.html */
.chart-container {
    width: 100%;
    height: 300px;
    margin-top: 20px;
}

/* Lore utilisé dans les pages usine.html, ferme.html, centrale.html */
.lore {
    font-size: 0.9em;
    text-align: center;
}

/* Evénements utilisés dans rempart.html */
.events {
    max-height: 200px;
    overflow-y: auto;
}

.events ul {
    list-style: none;
    padding: 0;
    font-size :  1.25em;
}

.events li {
    margin-bottom: 10px;
}

/* Boutons de suppression utilisés dans la page rempart.html */
.remove-button {
    background-color: #ff4d4d;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
}

.remove-button:hover {
    background-color: #ff1a1a;
}

.characters-presentation {
    display: flex;
    justify-content: space-between;
}

.character-card {
    width: 30%;
    border: 1px solid #ccc;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.character-card img {
    width: 100%;
    border-radius: 10px;
}

.character-card h3 {
    margin: 10px 0;
}

.character-card p {
    margin: 5px 0;
}

.character-card input {
    width: 100%;
    margin-bottom: 10px;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

/* Map */
.map-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    margin-top: 20px;
    margin-left: 20px;
}

.map-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.map-buttons button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    margin-bottom: 10px;
}

.map-buttons button:hover,
.character-item:hover {
    background-color: #2980b9;
}

.map {
    width: 80vw;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background-size: cover;
    background-position: center;
}

.grid {
    display: grid;
    grid-template-columns: repeat(100, 1fr);
    grid-template-rows: repeat(100, 1fr);
    width: 100%;
    height: 100%;
    position: absolute;
}
.cell {
    width: 100%;
    height: 100%;
    background-color: rgba(35, 39, 42, 0.1);
    border: 0.5px solid rgba(114, 137, 218, 0.3);
    box-sizing: border-box;
    position: relative;
}
.cell-0-0 {
    background-color: red !important;
}
.cell-debris {
    background-color: orange !important;
}
.tooltip {
    display: none;
    position: absolute;
    background-color: rgba(0, 0, 0, 0.712);
    color: white;
    padding: 5px;
    border-radius: 5px;
    z-index: 10;
    font-size: 12px;
    text-align: center;
}
.mission-button {
    display: none;
    position: absolute;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    background-color: #4CAF50;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
}

.debris-list {
    width: 20vw;
    height: 80vh;
    overflow-y: auto;
    padding: 10px;
    border-left: 1px solid #000000;
    background-color: #00000086;
}

.debris-item {
    padding: 10px;
    border: 1px solid #000000;
    border-radius: 5px;
    margin-bottom: 10px;
    background-color: #ffffff13;
}

.debris-item button {
    margin-top: 10px;
    padding: 5px 10px;
    border: none;
    border-radius: 5px;
    background-color: #4CAF50;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
}

.debris-item button:hover {
    background-color: #45a049;
}


.header .user-info {
    float: right;
    margin-right: 20px;
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.table th, .table td {
    border: 1px solid #ddd;
    padding: 8px;
}

.table th {
    background-color: #000000;
    text-align: left;
}

.dropdown {
    margin-bottom: 20px;
}

.dropdown label {
    margin-right: 10px;
}

/* Styles pour les cadres */
.section {
    background-color: rgba(50, 50, 50, 0.5);
    border-radius: 10px;
    margin-bottom: 20px;
    padding: 20px;
    width: 100%;
    box-sizing: border-box;
}

.table-admin {
    border: 1px solid #ddd;
    padding: 8px;
}

.left-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
    border-radius: 5px;
    color: white;
}

/* Commandement page styles */
.container-cmd {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    background-color: rgba(44, 62, 80, 0);
    border-radius: 10px;
    color: #050549;
}

.resources-cmd {
    display: flex;
    justify-content: space-around;
    padding: 20px;
    background-color: rgba(23, 30, 37, 0.381);
    border-radius: 10px;
}

.resource-cmd {
    display: flex;
    align-items: center;
    gap: 10px;
}

.resource-cmd img {
    width: 50px;
    height: 50px;
}

/* Container for the login page */
.login-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 100vh;
    background-image: url('../images/background.jpg');
    background-size: cover;
    padding: 20px;
}

/* Box for the login form */
.login-box {
    background-color: rgba(0, 0, 0, 0.507);
    padding: 20px;
    border-radius: 10px;
    width: 40%;
}

.login-box h2 {
    color: #fff;
    margin-bottom: 20px;
}

.login-box .form-group {
    margin-bottom: 15px;
}

.login-box .form-group label {
    color: #fff;
    display: block;
    margin-bottom: 5px;
}

.login-box .form-group input {
    width: 100%;
    padding: 10px;
    border: none;
    border-radius: 5px;
}

.login-box .btn {
    width: 100%;
    padding: 10px;
    background-color: #007BFF;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.login-box .btn:hover {
    background-color: #0056b3;
}

.login-box p {
    color: #fff;
    margin-top: 10px;
}

.login-box .forgot-password {
    color: #007BFF;
    display: block;
    margin-top: 10px;
    text-align: right;
}

.lore-box {

        background-color: rgba(0, 0, 0, 0.507);
        padding: 20px;
        border-radius: 10px;
        width: 55%;
    color: #fff;
}

.lore-box h2 {
    margin-bottom: 20px;
}

.lore-box p {
    line-height: 1.5;
}

.discovery-message {
    padding: 10px;
    text-align: center;
    border-radius: 5px;
    color: #fff;
    font-size: 1.2em;

}

/* Style pour le cadre du niveau technologique */
.tech-level-cmd {
    background-color: rgba(0, 0, 0, 0.5);
    padding: 5px;
    text-align: center;
    border-radius: 5px;
    color: #fff;
}

.tech-level-cmd h2, .tech-level-cmd h3 {
    margin: 0;
    padding: 5px;
}

/* Style pour les ressources et la construction en cours */
.resources-and-construction {
    display: flex;
    justify-content: space-between;
}

.resources-cmd, .construction-in-progress {
    width: 48%;
}

.resources-cmd {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.resource-cmd {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.resource-cmd img {
    width: 30px;
    height: 30px;
    margin-right: 10px;
}

.construction-in-progress {
    background-color: rgba(84, 142, 207, 0.822);
    padding: 8px;
    border-radius: 5px;
    color: #fff;
    text-align: center;
}

.construction-in-progress h2 {
    text-align: center;
}

/* Research page styles */
.research-cards-container {
    display: -webkit-box;
    flex-wrap: nowrap;
    justify-content: space-between;
    padding: 10px;
    overflow: auto;
}

.research-card {
    width: 20%;
    height: 400px;
    margin: 10px;
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.vehicule-card {
    width: 95%;
    height: 400px;
    margin: 10px;
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.116);
}

.vehicule-card img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Pour que l'image remplisse l'espace tout en restant proportionnée */
    position: absolute;
    top: 0;
    left: 0;
}

.vehicule-card-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.5); /* Fond légèrement grisé avec transparence */
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    border-radius: 8px;
    font-size: 1.2em
}

.vehicule-card h3 {
    margin-top: 0;
    font-size: 20px;
    text-decoration: underline;
    text-align: center;
}

.vehicule-card p {
    font-size: 20px;
}

.research-card-content {
    background-size: cover;
    background-position: center;
    color: rgb(255, 255, 255);
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-color: rgba(0, 0, 0, 0.7); /* Darkens the background image */
}

.research-card h3 {
    margin-top: 0;
    font-size: 20px;
    text-decoration: underline;
    text-align: center;
}

.research-card p {
    font-size: 16px;
}

.research-card button.rechercher-btn {
    background-color: #008CBA;
    border: none;
    color: white;
    padding: 10px 5px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    cursor: pointer;
    border-radius: 5px;
}

.research-card button.rechercher-btn:hover {
    background-color: #005f6a;
}

.progress-container {
    margin-top: 20px;
    text-align: center;
}
.progress-bar {
    width: 100%;
    background-color: #f3f3f3;
    border-radius: 5px;
    overflow: hidden;
    position: relative;
    height: 25px;
}
.progress {
    height: 100%;
    background-color: #4caf50;
    width: 0;
}

.progress-characters {
    height: 100%;
    background-color: #ad2f2f;
    width: 0;
}

.prototype-fabrication-container {
    margin-top: 40px;
}
.prototype-fabrication-container h2 {
    text-align: center;
    margin-bottom: 20px;
}
.prototype-cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
}

.character-card {
    width: 30%;
    border: 1px solid #ccc;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Assure que les éléments sont espacés */
}

.character-card img {
    max-width: 100%;  /* Taille maximale en fonction du conteneur */
    height: auto;     /* Hauteur automatique pour conserver les proportions */
    border-radius: 10px;
}

.character-card h3 {
    margin: 10px 0;
}

.character-card p {
    margin: 5px 0;
}

.character-card .buttons {
    margin-top: auto; /* Pousse les boutons vers le bas */
}

.character-card button {
    margin-top: 10px;
    width: 100%;
    padding: 10px;
    border: none;
    border-radius: 5px;
    background-color: #7289da;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
    text-decoration: none;
    text-align: center;
    display: inline-block;
    font-size: 14px;
}

.character-card button:hover {
    background-color: #5b6eae;
}

.map-container {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    margin-top: 20px;
    margin-left: 20px;
}

.map {
    width: 80vw;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background-size: cover;
    background-position: center;
}

.grid {
    display: grid;
    grid-template-columns: repeat(100, 1fr);
    grid-template-rows: repeat(100, 1fr);
    width: 100%;
    height: 100%;
    position: absolute;
}

.cell {
    width: 100%;
    height: 100%;
    background-color: rgba(35, 39, 42, 0.1);
    border: 0.5px solid rgba(114, 137, 218, 0.3);
    box-sizing: border-box;
    position: relative;
}

.cell-0-0 {
    background-color: red !important;
}

.cell-debris {
    background-color: orange !important;
}

.tooltip {
    display: none;
    position: absolute;
    background-color: rgba(0, 0, 0, 0.712);
    color: white;
    padding: 5px;
    border-radius: 5px;
    z-index: 10;
    font-size: 12px;
    text-align: center;
}

.mission-button {
    display: none;
    position: absolute;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    background-color: #4CAF50;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
}

.debris-list {
    width: 20vw;
    height: 80vh;
    overflow-y: auto;
    padding: 10px;
    border-left: 1px solid #000000;
    background-color: #00000086;
}

.debris-item {
    padding: 10px;
    border: 1px solid #000000;
    border-radius: 5px;
    margin-bottom: 10px;
    background-color: #ffffff13;
}

.debris-item button {
    margin-top: 10px;
    padding: 5px 10px;
    border: none;
    border-radius: 5px;
    background-color: #4CAF50;
    color: #ffffff;
    cursor: pointer;
    font-weight: bold;
}

.debris-item button:hover {
    background-color: #45a049;
}

.character-list-map {
    width: 20vw;
    height: 80vh;
    overflow-y: auto;
    padding: 10px;
    border-left: 1px solid #000000;
    background-color: #00000086;
    display: none;
}

.character-item-map {
    display: flex;
    align-items: center;
    margin: 10px;
    background-color: rgba(51, 65, 85, 0.8); /* Couleur de fond plus moderne et semi-transparente */
    padding: 10px;
    border-radius: 5px;
    width: 45%;
    color: white; /* Assurez-vous que le texte est visible */
}

.character-item-map img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 50%;
}

.hidden {
    display: none !important;
}

.map-left-column, .map-right-column {
    width: 15%;
    background-color: #00000086;
    padding: 10px;
    border-radius: 5px;
}

.map-center-column {
    width: 70%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.map-debris-list {
    height: 80vh;
    overflow-y: auto;
    padding: 10px;
    border-left: 1px solid #000000;
    background-color: #00000086;
}

.map-debris-left {
    height: 80vh;
    padding: 10px;
    border-left: 1px solid #000000;
    background-color: #00000086;
}

#map {
    position: relative;
}

#path-canvas {
    width: 100%;
    height: 100%;
}

/* Ensure footer sticks to the bottom */
.footer {
    position: flex;
    width: 100%;
    bottom: 0;
}

.inventory-bar {
    display: flex;
    gap: 10px;
    background-color: #33333300;
    padding: 10px;
    border-radius: 8px;
    border: 2px solid #555;
}

.item {
    position: relative;
    width: 85px;
    height: 80px;
}

.item img {
    width: 100%;
    height: 100%;
    border-radius: 5px;
}

.quantity {
    position: absolute;
    bottom: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 2px 5px;
    border-radius: 5px 0 0 0;
    font-size: 12px;
    font-weight: bold;
}

.specialisation-cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 10px;
}

.specialisation-card {
    width: 12%;
    height: 400px;
    margin: 10px;
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.specialisation-card.large-card {
    width: 25%;
    height: 500px;
}

.specialisation-card-content {
    background-size: cover;
    background-position: center;
    color: rgb(255, 255, 255);
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-color: rgba(0, 0, 0, 0.7);
}

.specialisation-card h3 {
    margin-top: 0;
    font-size: 20px;
    text-decoration: underline;
    text-align: center;
}

.specialisation-card p {
    font-size: 16px;
}

.resource-card {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    background-color: rgba(35, 39, 42, 0.8);
}

.resource-card img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
}

.resource-info {
    flex-grow: 1;
}

.resource-bar {
    height: 10px;
    background-color: #4caf50;
    border-radius: 5px;
    margin-top: 5px;
}

.resource-container-inline {
    display: flex;
    justify-content: space-around;
    padding: 10px;
    background-color: rgba(23, 30, 37, 0);
    border-radius: 10px;
}

.resource-item {
    display: flex;
    align-items: center;
    margin: 5px;
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.7);
    border-radius: 5px;
}

.resource-item img {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}

.resource-details {
    flex-grow: 1;
    
}

.resource-details p {
    margin: 0;
    color: white;
}

.resource-details2 {
    flex-grow: 1;
    font-size: 0.9em;
}

.resource-details2 p {
    margin: 0;
    color: white;
    font-size: 1.0em;
}

.resource-bar-container {
    background-color: #555;
    border-radius: 5px;
    overflow: hidden;
    height: 8px;
    margin-top: 5px;
}

.resource-bar-no {
    background-color: #bb1a1a;
    height: 10px;
    border-radius: 5px;
    margin-top: 5px;
}

.resource-bar {
    height: 10px;
    background-color: #4caf50;
    border-radius: 5px;
    margin-top: 5px;
}

.research-card-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.5); /* Fond légèrement grisé avec transparence */
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: 8px;
}

.footer-custom {
    height: 80px; /* Réduire la hauteur de la bande */
    padding: 5px 10px;
    border-top: 2px solid rgba(0, 198, 255, .35);
    /* Grille plutôt que le flex hérité de .header : avec un simple
       `justify-content` flex, le bloc ressources restait collé à côté du
       libellé "Productions par heure" au lieu d'être centré dans la
       bande -- toute la place libre partait dans l'unique espace avant
       "Mentions légales" à droite. Trois colonnes (libellé / ressources
       centrées / histoire+liens) donnent un vrai centrage horizontal
       indépendant de la largeur des voisins. */
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: 16px;
}

.footer-heure-label {
    white-space: nowrap;
}

.footer-custom .inventory {
    grid-column: 2;
    justify-self: center;
}

.footer-custom .story-space-inventory {
    /* Redondant avec le column-gap de la grille : cet espaceur ne sert
       plus à rien mais reste dans le gabarit pour ne pas toucher au
       balisage plus que nécessaire. */
    display: none;
}

.footer-custom .story.centered-text {
    grid-column: 3;
}

/* Bandeau "Productions par heure" -- même palette cyan/sombre que les
   cartes de /commandement (.cmd-stat-card / .cmd-production-card) et le
   reste de l'interface récemment restylée (chat, panneau de tutoriel),
   plutôt que les boîtes noires génériques d'origine. */
.footer-resources {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.footer-resource {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 9px;
    border-radius: 10px;
    border: 1px solid rgba(130, 178, 255, .18);
    background: rgba(255, 255, 255, .04);
}

.footer-resource.is-positive {
    border-color: rgba(67, 201, 140, .28);
    background: rgba(45, 110, 75, .18);
}

.footer-resource.is-negative {
    border-color: rgba(221, 87, 116, .28);
    background: rgba(123, 47, 66, .2);
}

.footer-resource img {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    flex-shrink: 0;
    object-fit: cover;
}

.footer-resource-body {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.footer-resource-label {
    font-size: .68rem;
    color: #b8caea;
}

.footer-resource-flow {
    font-size: .8rem;
    font-weight: 700;
    color: #d3ddf3;
}

.footer-resource.is-positive .footer-resource-flow { color: #6fdba3; }
.footer-resource.is-negative .footer-resource-flow { color: #f08fa4; }

.footer-resource-stock {
    font-size: .68rem;
    color: #8ea2c0;
}

.centered-text {
    display: flex;
    justify-content: right;
    align-items: center;
    height: 100%; /* Assurez-vous que l'élément prend toute la hauteur de la bande */
}

.inventory-container-inventory {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    padding: 20px;
}

.production-header-inventory {
    margin-bottom: 10px;
}

.resource-container-inline-inventory {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    width: 100%;
    margin-bottom: 20px; /* Ajuster pour l'espace entre ressources et histoires */
}

.story-space-inventory {
    height: 30px; /* Espace vide entre les ressources et les histoires */
    width: 300px;
}

.container2-map2 {
    width: 100%;
    margin: 0 auto;
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.226); /* Fond semi-transparent pour plus de lisibilité */
    border-radius: 10px;
}

.top-section-map2 {
    display: flex;
}

.left-section-map2 {
    flex: 2;
    margin-right: 20px;
}

.right-section-map2 {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.resources2-map2 {
    background-color: rgba(35, 39, 42, 0); /* Couleur de fond avec transparence de 50% */
    padding: 5px;
    border-radius: 10px;
    color: white; /* Assurer que le texte est lisible sur le fond */
    display: center;
    height: auto;
    margin-top: 5px;
}

.map-container-map2 {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    margin-top: 20px;
    overflow: auto; /* Ajoute des barres de défilement */
}

.map-left-column-map2 {
    display: block;
    width: 15%;
    background-color: #00000086;
    padding: 10px;
    border-radius: 5px;
    overflow: auto; /* Ajoute des barres de défilement */
}

.map-right-column-map2 {
    width: 15%;
    background-color: #00000086;
    padding: 10px;
    border-radius: 5px;
    overflow: auto; /* Ajoute des barres de défilement */
}

.scroller {
    height: 600px;
    overflow-y: scroll;
    scrollbar-color: rgba(124, 124, 129, 0.932) rgba(33, 34, 33, 0.685);
    scrollbar-width: thin;
  }

.map-center-column-map2 {
    width: 70%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.map-map2 {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    position: relative;
    background-size: contain;
    background-position: center;
    height: 800px; /* Hauteur fixe pour la carte */
    width: auto;
}

.character-list2-map2 {
    display: flex;
    flex-direction: column; /* Assurez-vous que les éléments sont empilés verticalement */
    align-items: center; /* Centre horizontalement les éléments */
    width: 100%;
    text-align: center;
}

.character-item-map2 {
    display: flex;
    align-items: center;
    margin: 5px;
    background-color: rgba(51, 65, 85, 0.8); /* Couleur de fond plus moderne et semi-transparente */
    padding: 5px;
    border-radius: 5px;
    width: 100%;
    color: white; /* Assurez-vous que le texte est visible */
    flex-direction: column;
    align-items: center;
    text-align: center;
    font-size: 0.85em;
}

.character-item-map2 img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 50%;
}

.section-map2 {
    background-color: rgba(50, 50, 50, 0);
    border-radius: 10px;
    margin-bottom: 20px;
    padding: 0px;
    width: 100%;
    box-sizing: border-box;
    text-align: center;

}

.dropdown-map2 {
    margin-bottom: 20px;
}

.coordinate-inputs-map2 label {
    margin-right: 10px;
}

.map-debris-list-map2 {
    margin-top: 20px;
}

.debris-item-map2 {
    background-color: rgba(51, 65, 85, 0.8);
    margin-bottom: 10px;
    padding: 10px;
    border-radius: 5px;
    color: white;
    border: 1px solid #ccc; /* Bordure pour séparer les cadres */
    overflow-y: auto;
    display: block;
}

/* Le chat (#chat-popup, #chat-window, #chat-form, .timestamp, ...) est
   entièrement stylé dans templates/base.html au plus près du markup --
   les anciennes règles génériques d'ici (notamment `#chat-window div`,
   qui ajoutait un fond + une marge à CHAQUE message) le sont retirées le
   24/08/2026 : elles s'empilaient avec le nouveau style et produisaient
   des messages en "bulles" trop espacées plutôt qu'un fil dense.
   `.chat-section` n'est référencée dans aucun template ; laissée telle
   quelle, hors-sujet ici. */
.chat-section {
    background-color: rgba(0, 0, 0, 0.7); /* Fond semi-transparent */
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
    color: white;
    max-height: 400px; /* Limite la hauteur pour ajouter une barre de défilement */
}

.container-base-raid {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.top-section-raid {
    display: flex;
    width: 100%;
    justify-content: space-between;
}

.left-section-raid, .right-section-raid {
    flex: 1;
    margin: 10px;
}

.image-section-raid {
    text-align: center;
    position: relative;
    height: auto;
    width: 100%
}

.animal-image-raid {
    width: 100%;
    max-width: 500px;
    height: auto;
}

.combat-buttons-raid {
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
}

.combat-buttons-raid button {
    margin: 0 10px;
    padding: 10px 20px;
}

.resources-raid {
    text-align: left;
}

.resource-raid {
    margin-bottom: 15px;
}

.add-vehicle {
    margin-top: 10px;
}

.add-vehicle button {
    background-color: #4CAF50;
    border: none;
    color: white;
    padding: 10px 24px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 12px;
}

.create-vehicle-container {
    display: flex;
    justify-content: space-between;
}

.create-vehicle-container .left-section img {
    max-width: 100%;
}

.create-vehicle-container .right-section {
    padding: 20px;
}

.create-vehicle-container .module-list {
    display: flex;
    flex-direction: column;
}

.create-vehicle-container .module-list label {
    margin-bottom: 10px;
}

.module-block {
    padding: 5px;
    width: 100px;
    height: 100px;
    background-size: cover;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    color: white;
    font-weight: bold;
    margin: 10px;
    border: 2px solid #fff;
    border-radius: 10px;
    flex-direction: row;
    text-decoration: underline;
    text-shadow: 0 0 20px black;
    font-size: 0.8em;
}

.resource-modules {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-weight: bold;
    color: white; /* Couleur blanche pour les ressources */
    overflow: auto;
}

.story-centered-text {
    padding: 5px;
    display: flex;
    color: white;
    border-radius: 10px;
    flex-direction: row;
    font-size: 0.9em;
    text-shadow: 0 0 20px black;
}

.story-text {
    display: center;
    color: white;
    flex-direction: row;
    font-size: 1em;
    text-shadow: 0 0 20px black;
    border: 1px #fff;
    padding: 5px;
}

.resources-net-production {
    height: 25vh;
    width: 100%;
    margin: 20px 0;
    padding: 30px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    color: white;
}

#netProductionChart {
    max-width: 100%;
    height: 20vh;
}

/* Style des lignes construites */
.built-row {
    background-color: #75c9872c; /* Vert clair */
    border-left: 4px solid #28a745; /* Bordure verte  */
    
}

/* Style des lignes non construites */
.not-built-row {
    background-color: #634b4763; /* Rouge clair */
    border-left: 4px solid #dc3545; /* Bordure rouge */
}

/* Interaction au survol */
.built-row:hover, .not-built-row:hover {
    background-color: rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Cadre doré pour le bâtiment avec le plus de votes */
tr[data-votes].gold-border {
    border: 3px solid gold;
    box-shadow: 0 0 10px gold;
}

/* Style pour l'affichage des votes */
.vote-count .votes {
    font-weight: bold;
    color: #ffa500; /* Couleur orange moderne */
    display: inline-block;
    margin-left: 10px;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 5px;
    border-radius: 5px;
}

.army-management {
    background-color: rgba(27, 31, 34, 0.7);
    padding: 20px;
    border-radius: 10px;
    color: white;
    margin-top: 20px;
}

.robot-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
}

.robot-item {
    background-color: rgba(51, 65, 85, 0.8);
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    width: 45%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.robot-item img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
}

/* Image en overlay avec deux colonnes */
.usine-image-overlay {
    display: flex;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.5); /* Utilisation de transparence */
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.usine-column {
    width: 98%;
    color: white;
    background-color: rgba(0, 0, 0, 0.7); /* Reutilisation du fond semi-transparent */
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); /* Même style de box-shadow utilisé ailleurs */
}

/* Liste des cartes (pour véhicules et robots) */
.usine-card {
    text-align: center;
    background-color: rgba(51, 65, 85, 0.8); /* Fond semi-transparent */
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    color: white;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.usine-card img {
    width: 100%;
    height: auto;
    border-radius: 5px;
}

/* Section gestion de l'atelier */
.usine-management {
    margin-top: 20px;
    padding: 20px;
    background-color: rgba(27, 31, 34, 0.8); /* Fond semi-transparent */
    border-radius: 10px;
    color: white;
}

/* Onglets dynamiques */
.usine-tabs {
    display: flex;
    justify-content: space-around;
    margin-bottom: 20px;
}

.usine-tab-button {
    padding: 10px 20px;
    background-color: rgba(51, 65, 85, 0.8); /* Boutons similaires au style existant */
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

.usine-tab-button.active {
    background-color: #7289da;
}

.usine-tab-content {
    display: none; /* Caché par défaut */
}

.usine-tab-content.active {
    display: block; /* Visible quand actif */
}

.hidden {
    display: none;
}

.create-vehicle-container {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 20px;
}

.vehicle-left-section, .vehicle-right-section {
    width: 48%;
    background-color: rgba(27, 31, 34, 0.8);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    color: white;
}

.vehicle-image img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 20px;
}

.vehicle-stats ul {
    list-style: none;
    padding: 0;
}

.module-list {
    margin-top: 20px;
}

.modules-table {
    width: 100%;
    border-collapse: collapse;
}

.modules-table th, .modules-table td {
    border: 1px solid #555;
    padding: 10px;
    text-align: left;
}

.build-module-button {
    background-color: #4CAF50;
    color: white;
    padding: 10px 15px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.build-module-button:hover {
    background-color: #45a049;
}

.main-container {
    display: flex;
    gap: 20px;
    padding: 20px;
}

.left-section-usine, .right-section-usine {
    width: 48%;
    background-color: rgba(27, 31, 34, 0.548);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    color: white;
}

.left-section-taverne, .right-section-taverne {
    width: 48%;
    background-color: rgba(59, 96, 124, 0);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    color: white;
}

.left-section-taverne, .right-section-taverne h3 {
    margin-bottom: 10px;
    font-size: 20px;
    color: #af1e1e;
}

/* Ressources */
.resources-section-usine {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.image-section-usine img {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 15px;
}

.resources-usine ul {
    list-style: none;
    padding: 0;
}

.resources-usine li {
    font-size: 14px;
    margin-bottom: 5px;
}

/* Entités (Véhicules et Armée) */
.entities-section {
    margin-top: 20px;
}

.entities-section h3 {
    margin-bottom: 10px;
    font-size: 16px;
    color: #fff;
}

.entities-section button {
    display: block;
    margin-bottom: 10px;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.entities-section button:hover {
    background-color: #45a049;
}

/* Section Construction */
.construction-section-usine {
    text-align: center;
    margin-bottom: 20px;
}

.construction-section-usine .buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.construction-section-usine button {
    padding: 10px 20px;
    background-color: #7289da;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.construction-section-usine button:hover {
    background-color: #5b6fba;
}

/* Sections dynamiques */
.content-section {
    display: none;
}

.content-section.active {
    display: block;
}

.hidden {
    display: none;
}

.dynamic-content {
    margin-top: 20px;
    padding: 20px;
    background-color: rgba(51, 65, 85, 0.8);
    color: white;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

/* Par exemple, ajoute ceci dans ton fichier CSS */

.next-attack-alert {
    /* Couleur de fond rouge sombre */
    background-color: #B71C1C;
    
    /* Couleur de texte en contraste clair */
    color: #FFFFFF;
    
    /* Mette un peu de marge interne */
    padding: 1rem;
    
    /* Style de police plus imposant */
    font-weight: bold;
    font-size: 1.2rem;
    text-transform: uppercase;
    
    /* Un effet de contour sombre pour donner un côté menaçant */
    text-shadow: 2px 2px 4px rgba(0,0,0,0.6);
    
    /* Petite bordure rouge plus foncée */
    border: 2px solid #7F0000;
    border-radius: 10px;
    
    /* Ombre externe pour effet « alerte » */
    box-shadow: 
      0 0 10px rgba(255, 0, 0, 0.7), 
      inset 0 0 10px rgba(255, 0, 0, 0.5);
  
    /* Transition pour un léger effet "zoom" au survol */
    transition: transform 0.3s ease;
  }
  
  /* Au survol, agrandir légèrement la zone */
  .next-attack-alert:hover {
    transform: scale(1.05);
  }
  
  /* Optionnel : faire clignoter quelque chose (texte ou icône) à l’intérieur */
  .blinking {
    animation: blinkingText 1s infinite;
  }
  
  @keyframes blinkingText {
    0%   { opacity: 1; }
    50%  { opacity: 0; }
    100% { opacity: 1; }
  }

/* Styles pour les quêtes */
.quests-section {
    margin-top: 30px;
    background: rgba(27, 31, 34, 0.418);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.quests-section h2 {
    color: #FFA500;
    margin-bottom: 20px;
}

.quest-card {
    background: rgba(27, 31, 34, 0.418);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.quest-card:hover {
    transform: translateY(-2px);
}

.quest-card.active {
    border: 2px solid #4CAF50;
}

.quest-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.quest-difficulty {
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8em;
    text-transform: uppercase;
}

.quest-difficulty.easy { background: #4CAF50; color: white; }
.quest-difficulty.medium { background: #FFC107; color: black; }
.quest-difficulty.hard { background: #F44336; color: white; }

.quest-progress {
    margin: 15px 0;
}

.progress-bar {
    background: #f0f0f0;
    height: 20px;
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    background: #4CAF50;
    height: 100%;
    transition: width 0.3s ease;
}

.quest-reward {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: #94802e;
    border-radius: 5px;
    margin-top: 15px;
}

.accept-quest {
    width: 100%;
    padding: 10px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 15px;
    transition: background 0.3s;
}

.accept-quest:hover {
    background: #45a049;
}

.proposed-quests {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.characters-card {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    margin-top: 20px;
}

.characters-card .character-card {
    background-color: #f4f4f4;
    border: 2px solid #ccc;
    border-radius: 10px;
    width: 200px;
    margin: 10px;
    padding: 10px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.characters-card .character-card img {
    width: 100%;
    border-radius: 50%;
}

.characters-card .stats {
    margin-top: 10px;
}

.characters-card .inventory {
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
}

.characters-card .character-inventory {
    margin: 10px;
}

.characters-card .inventory-slots {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
}

.characters-card .inventory-slot {
    width: 50px;
    height: 50px;
    background-color: #e0e0e0;
    border: 1px solid #ccc;
    border-radius: 5px;
    cursor: pointer;
}

.characters-card .progress-bar {
    background-color: #e0e0e0;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 10px;
}

.characters-card .progress {
    background-color: #007bff;
    height: 10px;
    border-radius: 5px;
}

.high-scores {
    background-color: rgba(5, 20, 48, 0.801);
    border: 2px solid #ffcc00;
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 0 20px rgba(255, 204, 0, 0.5);
}

.high-scores h3 {
    color: #ffcc00;
    text-align: center;
    font-family: 'Press Start 2P', cursive; /* Assurez-vous d'avoir cette police */
    font-size: 24px;
    margin-bottom: 20px;
}

.high-scores table {
    width: 100%;
    border-collapse: collapse;
}

.high-scores th, .high-scores td {
    border: 1px solid #ffcc00;
    padding: 10px;
    text-align: center;
    color: #fff;
    font-family: 'Press Start 2P', cursive; /* Assurez-vous d'avoir cette police */
}

.high-scores th {
    background-color: #ffcc00;
    color: #000;
}

.high-scores tr:nth-child(even) {
    background-color: rgba(255, 204, 0, 0.2);
}

.high-scores tr:hover {
    background-color: rgba(255, 204, 0, 0.5);
}


.buildings-cmd {
    background-color: #1e1e2f52; /* Couleur de fond sombre */
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.buildings-cmd h2 {
    text-align: center;
    color: #ffffff;
    font-family: 'Roboto', sans-serif; /* Police moderne */
    margin-bottom: 15px;
    font-size: 1.5em;
}

.buildings-table-cmd {
    width: 100%;
    border-collapse: collapse;
    background-size: cover; /* Pour couvrir tout le fond */
    background-position: center; /* Centrer l'image */
    color: #ffffff; /* Couleur du texte pour contraster avec l'image */
    min-height: 200px; /* Assurez-vous que le tableau a une hauteur minimale */
}

.buildings-table-cmd th, .buildings-table-cmd td {
    padding: 12px;
    text-align: left;
    color: #ffffff;
    font-family: 'Roboto', sans-serif;
    border: none; /* Supprimez la bordure */
    font-size: 1.1em;
    font-weight: bold;
}

.buildings-table-cmd th {
    background-color: #2a2a3b;
    color: #ffffff;
    font-weight: normal;
    font-size: 1.1em;
}

.buildings-table-cmd tr {
    border-bottom: 1px solid #2a2a3b;
}

.buildings-table-cmd tr:hover {
    background-color: #33334d;
}

.build-button-cmd, .vote-button {
    background-color: #3a3a5c;
    color: #ffffff;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
    font-family: 'Roboto', sans-serif;
}

.build-button-cmd:hover, .vote-button:hover {
    background-color: #4a4a6d;
}

.vote-count {
    font-weight: bold;
    color: #ffffff;
}

.resources-cmd {
    display: flex;
    justify-content: space-around;
    padding: 20px;
    background-color: rgba(23, 30, 37, 0.381);
    border-radius: 10px;
    background-image: url('./../images/chantiers.webp'); /* Chemin vers l'image */
}


.character-sections {
    display: flex;
    justify-content: space-between;
}

.character-section {
    flex: 1;
    padding: 10px;
    margin: 5px;
    text-align: center;
}

.character-section.disponible {
    background-color: lightgreen;
}

.character-section.en-exploration {
    background-color: lightblue;
}

.character-section.en-trajet {
    background-color: lightcoral;
}

.character-section.en-retour {
    background-color: lightgoldenrodyellow;
}

.character-item-map3.disponible {
    background-image: url('../images/rempart.webp');
    background-size: cover;
    margin-right: 7px;
    margin-left: 7px;
    border: 1px solid #000000;
    border-radius: 5px
}

.character-item-map3.on-debris {
    background-image: url('../images/debris.webp');
    background-size: cover;
    margin-right: 7px;
    margin-left: 7px;
    border: 1px solid #bd943c;
    border-radius: 5px
}

.character-item-map3.exploring {
    background-image: url('../images/fond.jpg');
    background-size: cover;
    margin-right: 7px;
    margin-left: 7px;
    border: 1px solid #bd943c;
    border-radius: 5px
}

.character-item-map3 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-size: cover;
    background-position: center;
    width: 100%;
    height: 150px; /* Set a fixed height */
    padding: 0;
}
.character-item-map3 img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 50%;
}

.left-section-map3, .right-section-usine {
    padding: 10px;
}

.left-section-map3 {
    width: 48%;
    background-color: rgba(27, 31, 34, 0.548);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    color: white;
}

.left-section-map3 {
    text-align: left;
}

.left-section-map3 img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 50%;
}

.right-section-usine {
    text-align: right;
}

.resource-container-inline-map {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 10px;
    background-color: rgba(23, 30, 37, 0);
    border-radius: 10px;
}

.resource-container-inline-inventory-map {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    margin-bottom: 15px; 
    margin-bottom: 15px; 
}

.resource-item-construction {
    display: flex;
    align-items: center;
    margin: 5px;
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.356);
    border-radius: 5px;
    border: 1px solid #000000;
}

.resource-item-construction img {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}

/* Commandement redesign */
.command-center-page {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 12px 8px 28px;
}

.cmd-hero-panel,
.cmd-panel,
.cmd-building-card {
    background: rgba(8, 14, 24, 0.82);
    border: 1px solid rgba(91, 155, 213, 0.28);
    border-radius: 18px;
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(4px);
}

.cmd-hero-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 24px 28px;
    color: #f3f7ff;
}

.cmd-kicker,
.cmd-section-kicker {
    margin: 0 0 6px;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #7bc7ff;
}

.cmd-subtitle {
    margin: 6px 0 0;
    color: #d2dcf5;
    font-size: 1rem;
}

.cmd-hero-panel h2,
.cmd-panel h3,
.cmd-building-card h4 {
    margin: 0;
    color: #ffffff;
}

.cmd-hero-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.cmd-hero-pill {
    min-width: 140px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

.cmd-hero-pill-label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.8rem;
    color: #bfd5ff;
}

.cmd-overview-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.cmd-panel {
    padding: 20px;
    color: #f7f9ff;
}

.cmd-panel-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 18px;
}

.cmd-resource-grid,
.cmd-production-grid,
.cmd-buildings-grid {
    display: grid;
    gap: 16px;
}

.cmd-resource-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cmd-production-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cmd-stat-card,
.cmd-production-card,
.cmd-construction-item {
    border-radius: 16px;
    border: 1px solid rgba(130, 178, 255, 0.18);
    background: rgba(255, 255, 255, 0.04);
}

.cmd-stat-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
}

.cmd-stat-icon {
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.cmd-stat-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cmd-stat-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cmd-stat-label,
.cmd-production-label,
.cmd-info-label {
    font-size: 0.86rem;
    color: #b8caea;
}

.cmd-stat-value,
.cmd-production-value {
    font-size: 1.45rem;
    color: #ffffff;
}

.cmd-production-card {
    padding: 14px 16px;
}

.cmd-production-card.positive {
    border-color: rgba(67, 201, 140, 0.28);
    background: rgba(45, 110, 75, 0.18);
}

.cmd-production-card.negative {
    border-color: rgba(221, 87, 116, 0.28);
    background: rgba(123, 47, 66, 0.2);
}

.cmd-construction-list {
    display: grid;
    gap: 12px;
}

.cmd-construction-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
}

.cmd-construction-item h4 {
    margin: 0 0 6px;
}

.cmd-construction-item p {
    margin: 0;
    color: #d3ddf3;
}

.cmd-empty-state {
    padding: 18px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
    color: #d3ddf3;
}

.cmd-buildings-header {
    margin-bottom: 16px;
}

.cmd-buildings-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cmd-building-card {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 20px;
    color: #f5f8ff;
}

.cmd-building-card.is-built {
    border-color: rgba(76, 188, 142, 0.35);
}

.cmd-building-card.is-top-voted {
    box-shadow: 0 0 0 1px rgba(255, 214, 102, 0.55), 0 14px 32px rgba(0, 0, 0, 0.28);
}

.cmd-building-card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
}

.cmd-building-desc {
    margin: 8px 0 0;
    color: #c6d4ee;
    line-height: 1.5;
}

.cmd-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.cmd-tag {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: #edf4ff;
    font-size: 0.8rem;
    white-space: nowrap;
}

.cmd-tag-success {
    background: rgba(46, 143, 91, 0.24);
}

.cmd-tag-info {
    background: rgba(44, 111, 187, 0.26);
}

.cmd-tag-warning {
    background: rgba(191, 138, 37, 0.25);
}

.cmd-card-columns {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 18px;
}

.cmd-info-block {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.cmd-cost-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.cmd-cost-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
}

.cmd-cost-item img {
    width: 22px;
    height: 22px;
    border-radius: 4px;
}

.cmd-effect-text {
    margin: 0;
    color: #d5e0f5;
    line-height: 1.5;
}

.cmd-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: auto;
}

.cmd-actions-left,
.cmd-actions-right {
    display: flex;
    gap: 10px;
}

.cmd-primary-btn,
.cmd-secondary-btn {
    border: none;
    border-radius: 12px;
    padding: 11px 16px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}

.cmd-primary-btn {
    background: linear-gradient(135deg, #2d7ff9, #41c3ff);
    color: #ffffff;
}

.cmd-secondary-btn {
    background: rgba(255, 255, 255, 0.09);
    color: #f0f5ff;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-secondary-btn.danger {
    background: rgba(164, 57, 81, 0.35);
    border-color: rgba(222, 108, 136, 0.35);
}

.cmd-primary-btn:hover,
.cmd-secondary-btn:hover {
    transform: translateY(-1px);
}

.cmd-primary-btn:disabled,
.cmd-secondary-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

@media (max-width: 1100px) {
    .cmd-overview-grid,
    .cmd-buildings-grid,
    .cmd-card-columns,
    .cmd-resource-grid,
    .cmd-production-grid {
        grid-template-columns: 1fr;
    }

    .cmd-building-card-top,
    .cmd-actions,
    .cmd-construction-item,
    .cmd-hero-panel {
        flex-direction: column;
        align-items: stretch;
    }

    .cmd-badges,
    .cmd-actions-right {
        justify-content: flex-start;
    }
}


.cmd-buildings-tools {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.cmd-filter-toggle,
.cmd-sort-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(130, 178, 255, 0.18);
    color: #d9e6ff;
    font-size: 0.92rem;
}

.cmd-filter-toggle input {
    accent-color: #42c59c;
}

.cmd-sort-select {
    min-width: 220px;
    border: 1px solid rgba(130, 178, 255, 0.2);
    border-radius: 10px;
    padding: 8px 10px;
    background: rgba(7, 15, 29, 0.95);
    color: #f2f6ff;
}

.cmd-building-main {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cmd-building-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cmd-inline-count {
    color: #8fd3ff;
    font-size: 0.92em;
    font-weight: 600;
}

.cmd-building-meta-line {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    color: #a8bddf;
    font-size: 0.9rem;
}

.cmd-separator {
    opacity: 0.55;
}

.cmd-type-label {
    font-weight: 600;
    color: #eef4ff;
}

.cmd-type-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    display: inline-block;
    flex: 0 0 12px;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.06);
}

.cmd-type-dot.type-production {
    background: #50d890;
}

.cmd-type-dot.type-defense {
    background: #ff6b6b;
}

.cmd-type-dot.type-research {
    background: #9b7cff;
}

.cmd-type-dot.type-industry {
    background: #f6c453;
}

.cmd-type-dot.type-logistics {
    background: #4cc9f0;
}

.cmd-type-dot.type-habitat {
    background: #ff9f68;
}

.cmd-type-dot.type-social {
    background: #f472d0;
}

.cmd-type-dot.type-special {
    background: #7fffd4;
}

.cmd-type-dot.type-unknown {
    background: #8d99ae;
}

@media (max-width: 1100px) {
    .cmd-buildings-tools {
        justify-content: flex-start;
    }
}

@media (max-width: 768px) {
    .cmd-buildings-tools {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }

    .cmd-filter-toggle,
    .cmd-sort-wrap {
        width: 100%;
        justify-content: space-between;
    }

    .cmd-sort-select {
        min-width: 0;
        width: 100%;
    }
}

.building-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    margin-top: 10px;
}

.building-metric {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.building-metric__label {
    font-size: 0.9rem;
    opacity: 0.85;
}

.building-metric__value {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    text-align: right;
}

.building-metric__value--projection {
    color: #9ee37d;
}

.building-metric__delta {
    font-size: 0.85rem;
    opacity: 0.9;
}

.building-metric__icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.building-inline-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.building-inline-stat {
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.85rem;
}

.cmd-metric-list {
    display: grid;
    gap: 10px;
}

.cmd-metric-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.cmd-metric-label {
    font-size: 0.92rem;
    opacity: 0.88;
}

.cmd-metric-value {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}

.cmd-metric-value img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.cmd-metric-value-projected {
    color: #9ee37d;
}

.cmd-metric-delta {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* ===== Centre de recherche / Atelier mécanique ===== */

.research-lab-page {
    display: grid;
    gap: 24px;
}

.research-hero-panel {
    background:
        linear-gradient(135deg, rgba(8, 14, 24, 0.88), rgba(15, 42, 68, 0.74)),
        url("../images/centre_recherche.webp") center/cover;
}

.research-hero-meta {
    align-items: stretch;
}

.research-progress-panel {
    padding: 24px 28px;
}

.research-progress-copy {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 14px;
    color: #d8e7ff;
}

.cmd-tech-progress {
    width: 100%;
    height: 14px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(123, 199, 255, 0.18);
}

.cmd-tech-progress-bar {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #2d7ff9, #41c3ff);
    box-shadow: 0 0 18px rgba(65, 195, 255, 0.35);
}

.research-overview-grid {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
}

.research-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.research-assignment-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.research-assignment-column h4 {
    margin: 0 0 12px;
    color: #f3f7ff;
}

.research-character-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.research-character-chip {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(130, 178, 255, 0.14);
}

.research-character-chip.is-muted {
    opacity: 0.88;
}

.research-character-chip img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(123, 199, 255, 0.35);
}

.research-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.research-summary-card {
    padding: 18px;
    border-radius: 16px;
    border: 1px solid rgba(130, 178, 255, 0.16);
    background: rgba(255, 255, 255, 0.04);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.research-summary-label {
    font-size: 0.9rem;
    color: #9bb8dd;
}

.research-summary-card strong {
    font-size: 1.5rem;
    color: #f3f7ff;
}

.research-catalog-panel {
    padding: 24px 28px;
}

.research-two-columns,
.atelier-prototype-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.research-carousel {
    --carousel-spread: clamp(280px, 28vw, 490px);
    --carousel-far-spread: clamp(460px, 47vw, 790px);
    position: relative;
    margin: 4px -10px 0;
    padding: 8px 58px 0;
}

.research-carousel-viewport {
    position: relative;
    height: 500px;
    overflow: hidden;
    perspective: 1500px;
    perspective-origin: 50% 46%;
    touch-action: pan-y;
    cursor: grab;
    outline: none;
}

.research-carousel-viewport:active {
    cursor: grabbing;
}

.research-carousel-viewport:focus-visible {
    border-radius: 20px;
    box-shadow: inset 0 0 0 2px rgba(116, 205, 255, 0.48);
}

.research-carousel-track {
    position: relative;
    height: 100%;
    transform-style: preserve-3d;
}

.research-carousel-card {
    position: absolute;
    top: 18px;
    left: 50%;
    width: min(560px, calc(100% - 150px));
    min-height: 440px;
    backface-visibility: hidden;
    transform-style: preserve-3d;
    transform-origin: center center;
    opacity: 0;
    pointer-events: none;
    filter: saturate(0.65) brightness(0.65);
    transition:
        transform 520ms cubic-bezier(0.2, 0.72, 0.18, 1),
        opacity 360ms ease,
        filter 360ms ease,
        border-color 360ms ease,
        box-shadow 360ms ease;
    will-change: transform, opacity;
}

.research-carousel-card .research-card-overlay {
    min-height: 440px;
    box-sizing: border-box;
}

.research-carousel-card.is-active {
    z-index: 5;
    opacity: 1;
    pointer-events: auto;
    filter: none;
    transform: translateX(-50%) translateZ(0) rotateY(0) scale(1);
    border-color: rgba(93, 202, 255, 0.54);
    box-shadow:
        0 24px 58px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(83, 181, 255, 0.12),
        0 0 42px rgba(35, 136, 224, 0.15);
}

.research-carousel-card.is-previous,
.research-carousel-card.is-next {
    z-index: 3;
    opacity: 0.58;
    pointer-events: auto;
}

.research-carousel-card.is-previous {
    transform: translateX(calc(-50% - var(--carousel-spread))) translateZ(-190px) rotateY(48deg) scale(0.82);
}

.research-carousel-card.is-next {
    transform: translateX(calc(-50% + var(--carousel-spread))) translateZ(-190px) rotateY(-48deg) scale(0.82);
}

.research-carousel-card.is-far-previous,
.research-carousel-card.is-far-next {
    z-index: 1;
    opacity: 0.18;
}

.research-carousel-card.is-far-previous {
    transform: translateX(calc(-50% - var(--carousel-far-spread))) translateZ(-360px) rotateY(60deg) scale(0.68);
}

.research-carousel-card.is-far-next {
    transform: translateX(calc(-50% + var(--carousel-far-spread))) translateZ(-360px) rotateY(-60deg) scale(0.68);
}

.research-carousel-card.is-offstage {
    z-index: 0;
    opacity: 0;
    transform: translateX(-50%) translateZ(-520px) scale(0.55);
}

.research-carousel-card:not(.is-active) .research-card-overlay {
    pointer-events: none;
}

.research-carousel-card.is-complete.is-active {
    border-color: rgba(82, 222, 151, 0.55);
    box-shadow:
        0 24px 58px rgba(0, 0, 0, 0.4),
        0 0 38px rgba(43, 185, 116, 0.15);
}

.research-carousel-card.is-in-progress.is-active {
    border-color: rgba(255, 198, 72, 0.58);
    box-shadow:
        0 24px 58px rgba(0, 0, 0, 0.4),
        0 0 42px rgba(255, 181, 49, 0.16);
}

.research-carousel-arrow {
    position: absolute;
    top: 226px;
    z-index: 8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 50%;
    border: 1px solid rgba(112, 205, 255, 0.32);
    background: rgba(7, 18, 35, 0.88);
    color: #dff5ff;
    font-size: 2rem;
    line-height: 1;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3), 0 0 20px rgba(45, 161, 235, 0.1);
    backdrop-filter: blur(8px);
    transform: translateY(-50%);
    transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.research-carousel-arrow:hover {
    background: rgba(19, 65, 104, 0.94);
    border-color: rgba(112, 205, 255, 0.62);
    transform: translateY(-50%) scale(1.05);
}

.research-carousel-arrow:focus-visible {
    outline: 2px solid #7bd6ff;
    outline-offset: 3px;
}

.research-carousel-arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.research-carousel-arrow.is-previous {
    left: 14px;
}

.research-carousel-arrow.is-next {
    right: 14px;
}

.research-carousel-footer {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 18px;
    max-width: 760px;
    margin: 4px auto 0;
    color: rgba(196, 216, 244, 0.64);
    font-size: 0.78rem;
}

.research-carousel-counter {
    min-width: 48px;
    font-variant-numeric: tabular-nums;
}

.research-carousel-counter strong {
    color: #7edaff;
    font-size: 1rem;
}

.research-carousel-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}

.research-carousel-dot {
    width: 7px;
    height: 7px;
    min-width: 7px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(155, 189, 224, 0.28);
    transition: width 0.25s, background 0.25s, box-shadow 0.25s;
}

.research-carousel-dot:hover {
    background: rgba(126, 218, 255, 0.58);
}

.research-carousel-dot.is-active {
    width: 24px;
    background: linear-gradient(90deg, #3a9dff, #70e1ff);
    box-shadow: 0 0 12px rgba(72, 191, 255, 0.45);
}

.research-carousel-dot:focus-visible {
    outline: 2px solid #8edfff;
    outline-offset: 3px;
}

.research-carousel-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.research-grid-card,
.prototype-card {
    min-height: 360px;
    border-radius: 18px;
    overflow: hidden;
    background-position: center;
    background-size: cover;
    border: 1px solid rgba(123, 199, 255, 0.2);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.22);
}

.research-card-overlay,
.prototype-card-body {
    min-height: 100%;
    padding: 22px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    color: #f4f8ff;
}

.research-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.research-card-header h4 {
    margin: 0;
    font-size: 1.2rem;
    color: #ffffff;
}

.research-status-badge {
    padding: 8px 10px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.1);
    color: #f3f7ff;
    white-space: nowrap;
}

.research-status-badge.is-success {
    background: rgba(52, 175, 120, 0.2);
    color: #96ffca;
}

.research-status-badge.is-warning {
    background: rgba(255, 191, 71, 0.2);
    color: #ffd98b;
}

.research-card-effect {
    padding-left: 13px;
    border-left: 2px solid rgba(85, 199, 255, 0.46);
}

.research-card-effect p {
    margin: 5px 0 0;
    color: #d9e8ff;
    line-height: 1.5;
}

.research-card-meta {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 11px 0;
    border-top: 1px solid rgba(123, 199, 255, 0.14);
    border-bottom: 1px solid rgba(123, 199, 255, 0.14);
}

.research-card-meta span {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    padding: 0 12px;
}

.research-card-meta span:first-child {
    padding-left: 0;
}

.research-card-meta span + span {
    border-left: 1px solid rgba(142, 192, 230, 0.14);
}

.research-card-meta small {
    color: rgba(169, 197, 228, 0.66);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.research-card-meta strong {
    overflow: hidden;
    color: #f1f7ff;
    font-size: 0.86rem;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-cost-strip {
    display: flex;
    align-items: center;
    gap: 13px;
    min-height: 36px;
}

.research-cost-heading {
    flex: 0 0 auto;
    color: rgba(191, 208, 241, 0.68);
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.085em;
    text-transform: uppercase;
}

.research-cost-items {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.research-cost-item {
    position: relative;
    display: grid;
    grid-template-columns: 23px auto;
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 7px;
    min-width: 0;
}

.research-cost-item + .research-cost-item {
    margin-left: 2px;
    padding-left: 13px;
}

.research-cost-item + .research-cost-item::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 1px;
    background: linear-gradient(to bottom, transparent, rgba(139, 182, 226, 0.35), transparent);
}

.research-cost-item img {
    grid-row: 1 / 3;
    width: 23px;
    height: 23px;
    border-radius: 6px;
    object-fit: cover;
}

.research-cost-item strong {
    color: #f0f6ff;
    font-size: 0.9rem;
    font-variant-numeric: tabular-nums;
    line-height: 1.05;
}

.research-cost-item > span {
    color: rgba(194, 208, 237, 0.64);
    font-size: 0.61rem;
    line-height: 1.05;
    white-space: nowrap;
}

.research-cost-item.is-insufficient strong {
    color: #ff8a7e;
}

.research-cost-free {
    color: rgba(190, 211, 239, 0.7);
    font-size: 0.78rem;
}

.research-card-actions {
    margin-top: auto;
    display: flex;
    justify-content: flex-start;
}

.atelier-overview-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.atelier-tabs {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.atelier-tab-button {
    border: 1px solid rgba(123, 199, 255, 0.18);
    background: rgba(255, 255, 255, 0.06);
    color: #f0f5ff;
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.atelier-tab-button:hover,
.atelier-tab-button.is-active {
    transform: translateY(-1px);
    background: linear-gradient(135deg, #2d7ff9, #41c3ff);
    color: #ffffff;
}

.atelier-dynamic-content {
    min-height: 280px;
}

.atelier-dynamic-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 18px;
}

.atelier-vehicle-hero,
.atelier-prototype-intro {
    min-height: 220px;
    border-radius: 16px;
    overflow: hidden;
    background-position: center;
    background-size: cover;
    border: 1px solid rgba(123, 199, 255, 0.16);
    padding: 20px;
    display: flex;
    align-items: flex-end;
}

.atelier-prototype-intro p {
    margin: 0;
    color: #f3f7ff;
    line-height: 1.6;
    max-width: 760px;
}

.atelier-stat-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.atelier-stat-pill {
    min-width: 140px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(10, 17, 28, 0.72);
    border: 1px solid rgba(123, 199, 255, 0.18);
    color: #d9e8ff;
}

.atelier-stat-pill span {
    display: block;
    font-size: 0.82rem;
    margin-bottom: 6px;
}

.atelier-stat-pill strong {
    font-size: 1.15rem;
    color: #ffffff;
}

.atelier-module-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.atelier-module-chip {
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(123, 199, 255, 0.12);
    color: #e7f1ff;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.atelier-table-wrap {
    overflow-x: auto;
}

.atelier-table th,
.atelier-table td {
    vertical-align: top;
}

.atelier-empty-panel .atelier-empty-state,
.cmd-empty-state {
    line-height: 1.6;
}

@media (max-width: 1100px) {
    .research-overview-grid,
    .atelier-dynamic-grid,
    .research-two-columns,
    .atelier-prototype-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    .research-assignment-grid,
    .research-summary-grid,
    .atelier-overview-cards {
        grid-template-columns: 1fr;
    }

    .research-card-header,
    .cmd-panel-header {
        flex-direction: column;
    }

    .research-actions {
        width: 100%;
    }

    .research-carousel {
        --carousel-spread: 66vw;
        --carousel-far-spread: 108vw;
        margin-inline: -20px;
        padding-inline: 42px;
    }

    .research-carousel-viewport {
        height: 540px;
    }

    .research-carousel-card {
        top: 14px;
        width: min(540px, calc(100% - 24px));
        min-height: 480px;
    }

    .research-carousel-card .research-card-overlay {
        min-height: 480px;
    }

    .research-carousel-card.is-previous,
    .research-carousel-card.is-next {
        opacity: 0.24;
    }

    .research-carousel-arrow {
        top: 250px;
        width: 40px;
        height: 40px;
    }

    .research-carousel-arrow.is-previous {
        left: 10px;
    }

    .research-carousel-arrow.is-next {
        right: 10px;
    }

    .research-carousel-footer {
        grid-template-columns: auto minmax(0, 1fr);
        gap: 12px;
    }

    .research-carousel-hint {
        grid-column: 1 / -1;
        justify-self: center;
    }

    .research-cost-strip {
        align-items: flex-start;
    }

    .research-cost-items {
        flex-wrap: wrap;
    }
}

@media (max-width: 520px) {
    .research-catalog-panel {
        padding-inline: 18px;
    }

    .research-carousel {
        margin-inline: -14px;
        padding-inline: 34px;
    }

    .research-carousel-viewport {
        height: 590px;
    }

    .research-carousel-card {
        min-height: 530px;
    }

    .research-carousel-card .research-card-overlay {
        min-height: 530px;
        padding: 18px;
    }

    .research-carousel-arrow {
        top: 272px;
        width: 36px;
        height: 36px;
    }

    .research-card-meta span {
        padding-inline: 8px;
    }

    .research-card-meta strong {
        font-size: 0.78rem;
    }

    .research-cost-strip {
        flex-direction: column;
        gap: 8px;
    }

    .research-carousel-dots {
        gap: 5px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .research-carousel-card,
    .research-carousel-dot,
    .research-carousel-arrow {
        transition-duration: 1ms !important;
    }
}

.territory-view-switch {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.territory-view-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(14, 28, 48, 0.78);
    border: 1px solid rgba(135, 168, 220, 0.16);
    color: rgba(235, 245, 255, 0.82);
    font-size: 0.82rem;
    text-decoration: none;
    transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.territory-view-link:hover {
    transform: translateY(-1px);
    border-color: rgba(120, 200, 255, 0.45);
    box-shadow: 0 0 16px rgba(80, 170, 255, 0.14);
}

.territory-view-link.is-active {
    background: linear-gradient(135deg, rgba(40, 110, 200, 0.9), rgba(100, 70, 190, 0.9));
    border-color: rgba(170, 220, 255, 0.5);
    color: #ffffff;
}

.manual-exploration-panel {
    margin-bottom: 18px;
    border: 1px solid rgba(0, 212, 255, 0.25);
    box-shadow: 0 0 14px rgba(0, 212, 255, 0.08);
}

.manual-exploration-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.manual-exploration-card {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 14px;
    padding: 10px 12px;
    border: 1px solid rgba(0, 212, 255, 0.18);
    border-radius: 8px;
    background: rgba(5, 20, 30, 0.45);
}

.manual-exploration-type {
    display: block;
    opacity: 0.8;
    font-size: 0.86rem;
    margin-top: 3px;
}

.manual-exploration-position {
    font-size: 0.86rem;
    opacity: 0.85;
    white-space: nowrap;
}

.manual-exploration-enter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 10px;
    border-radius: 6px;
    background: rgba(0, 212, 255, 0.14);
    border: 1px solid rgba(0, 212, 255, 0.45);
    color: #9feeff;
    text-decoration: none;
    font-weight: 700;
    white-space: nowrap;
}

.manual-exploration-enter:hover {
    background: rgba(0, 212, 255, 0.25);
}

.interior-exploration-wrapper {
    margin: 18px 0;
    padding: 16px;
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 10px;
    background: rgba(5, 15, 25, 0.82);
}

.interior-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 14px;
    opacity: 0.85;
    font-size: 0.9rem;
}

.interior-map {
    display: grid;
    gap: 2px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 8px;
    width: max-content;
    max-width: 100%;
    overflow: auto;
}

.interior-tile {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    background: #050b10;
    color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: monospace;
    font-weight: 800;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.interior-tile.is-discovered {
    color: rgba(220, 240, 255, 0.55);
    background: rgba(30, 40, 50, 0.7);
}

.interior-tile.is-visible {
    color: #dff8ff;
    background: rgba(35, 70, 90, 0.9);
    border-color: rgba(0, 212, 255, 0.25);
}

.interior-tile.is-current {
    background: #00d4ff;
    color: #001018;
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.85);
}

.tile-wall.is-discovered,
.tile-wall.is-visible {
    background: #111;
    color: #555;
}

.tile-container.is-visible,
.tile-loot.is-visible {
    background: rgba(255, 184, 0, 0.25);
    color: #ffdd77;
}

.tile-trap.is-visible {
    background: rgba(255, 60, 50, 0.28);
    color: #ff6b5a;
}

.tile-monster.is-visible {
    background: rgba(255, 0, 120, 0.28);
    color: #ff75c8;
}

.tile-exit.is-visible {
    background: rgba(0, 240, 160, 0.25);
    color: #00f0a0;
}

.interior-controls {
    margin-top: 14px;
    display: grid;
    grid-template-columns: repeat(3, 46px);
    grid-template-rows: repeat(3, 38px);
    gap: 6px;
    width: max-content;
}

.interior-controls button {
    border: 1px solid rgba(0, 212, 255, 0.6);
    background: rgba(0, 212, 255, 0.12);
    color: #9feeff;
    border-radius: 6px;
    font-weight: 800;
    cursor: pointer;
}

.interior-controls button:nth-child(1) {
    grid-column: 2;
    grid-row: 1;
}

.interior-controls button:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
}

.interior-controls button:nth-child(3) {
    grid-column: 3;
    grid-row: 2;
}

.interior-controls button:nth-child(4) {
    grid-column: 2;
    grid-row: 3;
}

.interior-actions {
    margin-top: 12px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.interior-leave {
    border-color: rgba(255, 100, 80, 0.7);
    color: #ff9a86;
}

.equipment-panel {
    margin-top: 12px;
    padding: 10px;
    border: 1px solid rgba(0, 212, 255, 0.22);
    border-radius: 8px;
    background: rgba(0, 20, 30, 0.35);
}

.equipment-panel h4 {
    margin: 0 0 8px 0;
}

.equipment-slots {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.88rem;
}

.equipment-slots button,
.equipment-actions button {
    margin-left: 8px;
    cursor: pointer;
}

.equipment-actions {
    margin-top: 10px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.equipment-actions select {
    min-width: 180px;
}

.combat-status-panel {
    margin-top: 12px;
    padding: 10px;
    border: 1px solid rgba(255, 80, 80, 0.25);
    border-radius: 8px;
    background: rgba(50, 10, 10, 0.28);
}

/* ── Section header commun ── */
.usine-section-header {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 12px; margin-bottom: 14px;
}
.usine-section-title { display: flex; flex-direction: column; gap: 3px; }
.usine-section-kicker {
    font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em;
    color: #30d8f0; font-weight: 700;
}
.usine-section-title h3 { margin: 0; font-size: 1.15rem; color: #e8f6ff; }

/* ── Status badge ── */
.usine-status-badge {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 5px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 700;
    background: rgba(40,220,120,0.12); border: 1px solid rgba(40,220,120,0.35);
    color: #50e898; white-space: nowrap; margin-top: 4px;
}
.usine-status-dot {
    width: 7px; height: 7px; border-radius: 50%;
    background: #50e898; box-shadow: 0 0 8px #50e898;
    animation: blink-dot 2s ease-in-out infinite;
}
@keyframes blink-dot { 0%,100%{opacity:1} 50%{opacity:0.3} }

/* ── Hero banners partagés ── */
.usine-vehicle-hero-banner,
.usine-robot-hero-banner,
.usine-proto-hero-banner,
.usine-craft-hero-banner,
.usine-lab-hero-banner {
    position: relative; border-radius: 16px; overflow: hidden;
    background-size: cover; background-position: center;
    padding: 26px 18px 20px;
    border: 1px solid rgba(0, 190, 220, 0.15);
    margin-bottom: 20px;
}
.uvh-glow-line {
    position: absolute; top: 0; left: 0; right: 0; height: 2px;
    background: linear-gradient(90deg, transparent, rgba(0,210,255,0.8), rgba(100,255,220,0.5), transparent);
}
.uvh-stats {
    display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
}
.uvh-stat {
    flex: 1; min-width: 100px;
    display: flex; flex-direction: column; align-items: center; gap: 5px;
    padding: 14px 10px; border-radius: 14px;
    background: rgba(4, 14, 28, 0.72); border: 1px solid rgba(0, 190, 220, 0.16);
    backdrop-filter: blur(6px); text-align: center;
    transition: border-color 0.2s, transform 0.2s;
}
.uvh-stat:hover { border-color: rgba(0, 210, 240, 0.4); transform: translateY(-2px); }
.uvh-stat-icon { font-size: 1.2rem; }
.uvh-stat-lbl { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.07em; color: #6899b8; }
.uvh-stat-val { font-size: 1.3rem; font-weight: 800; color: #60e8ff; }

/* ── Proto hero text ── */
.uproto-hero-text {
    margin: 0; color: rgba(220, 230, 250, 0.82); font-size: 0.88rem;
    line-height: 1.6; max-width: 520px;
}

/* ── Subsection ── */
.usine-subsection { margin-bottom: 18px; }
.usine-subsection-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 2px 8px; margin-bottom: 10px;
    border-bottom: 1px solid rgba(0, 190, 220, 0.12);
    font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em;
    color: rgba(160, 200, 230, 0.65); font-weight: 700;
}
.usine-count-badge {
    padding: 2px 8px; border-radius: 999px;
    background: rgba(0, 190, 220, 0.12); border: 1px solid rgba(0, 190, 220, 0.22);
    color: #40d0f0; font-size: 0.78rem; font-weight: 700;
}

/* ── Modules installés ── */
.usine-modules-installed-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.usine-module-chip {
    display: flex; align-items: center; gap: 8px;
    padding: 7px 12px; border-radius: 10px;
    background: rgba(0, 200, 120, 0.08); border: 1px solid rgba(0, 200, 120, 0.2);
}
.umc-dot { width: 7px; height: 7px; border-radius: 50%; background: #40e890; flex-shrink: 0; }
.usine-module-chip div { display: flex; flex-direction: column; }
.usine-module-chip strong { font-size: 0.83rem; color: #b8f0d4; line-height: 1.2; }
.usine-module-chip span { font-size: 0.73rem; color: rgba(140,210,170,0.55); }

/* ══ CARDS LIST — structure partagée par toutes les sections ══ */
.usine-cards-list { display: flex; flex-direction: column; gap: 8px; }
.usine-item-card {
    display: flex; align-items: center; gap: 14px; justify-content: space-between;
    padding: 13px 14px; border-radius: 14px;
    background: rgba(6, 14, 28, 0.85); border: 1px solid rgba(0, 190, 220, 0.10);
    transition: border-color 0.18s, background 0.18s;
}
.usine-item-card:hover { border-color: rgba(0, 210, 240, 0.26); background: rgba(0, 28, 48, 0.75); }
.usine-item-card.is-done { border-color: rgba(60, 220, 120, 0.18); opacity: 0.75; }
.usine-item-card.is-wip  { border-color: rgba(255, 200, 60, 0.22); }

.uic-left { display: flex; align-items: flex-start; gap: 12px; flex: 1; min-width: 0; }
.uic-icon {
    width: 40px; height: 40px; border-radius: 11px; flex-shrink: 0;
    background: rgba(0, 190, 220, 0.09); border: 1px solid rgba(0, 190, 220, 0.16);
    display: flex; align-items: center; justify-content: center; font-size: 1.15rem;
}
.uic-icon--robot { background: rgba(0,180,255,0.10) !important; border-color: rgba(0,180,255,0.20) !important; }
.uic-icon--proto { background: rgba(140,60,255,0.10) !important; border-color: rgba(140,60,255,0.20) !important; }

.uic-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.uic-info strong { font-size: 0.9rem; color: #d8f0ff; }
.uic-desc { font-size: 0.78rem; color: rgba(180, 210, 235, 0.58); line-height: 1.4; }
.uic-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 3px; }

.uic-tech-tag {
    padding: 2px 7px; border-radius: 6px; font-size: 0.7rem; font-weight: 700;
    background: rgba(255,200,60,0.10); border: 1px solid rgba(255,200,60,0.20); color: #ffd060;
}
.uic-qty-tag {
    padding: 2px 7px; border-radius: 6px; font-size: 0.7rem; font-weight: 600;
    background: rgba(100,180,255,0.10); border: 1px solid rgba(100,180,255,0.18); color: #90c8ff;
}
.uic-meta-pill {
    padding: 2px 8px; border-radius: 6px; font-size: 0.72rem;
    background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.08);
    color: rgba(200,225,255,0.65);
}
.uic-proto-title-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.uic-proto-meta { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 3px; }

.uic-right { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex-shrink: 0; }
.uic-cost { display: flex; flex-direction: column; gap: 2px; text-align: right; }
.uic-cost-row { display: flex; gap: 6px; font-size: 0.75rem; justify-content: flex-end; }
.uic-cost-row span { color: rgba(180,200,220,0.52); }
.uic-cost-row strong { color: rgba(220,240,255,0.85); }
.uic-cost-single {
    display: flex; align-items: center; gap: 5px;
    font-size: 0.82rem; color: rgba(200,220,240,0.8);
}
.uic-cost-single strong { font-size: 1rem; color: #d8f0ff; }
.uic-cost-icon { font-size: 0.9rem; }

/* ── Proto badges ── */
.usine-proto-badge {
    padding: 3px 9px; border-radius: 999px; font-size: 0.72rem; font-weight: 700;
    background: rgba(0,190,220,0.10); border: 1px solid rgba(0,190,220,0.25); color: #60d8f0;
    white-space: nowrap;
}
.usine-proto-badge.is-success { background: rgba(40,220,100,0.10); border-color: rgba(40,220,100,0.3); color: #50e880; }
.usine-proto-badge.is-wip     { background: rgba(255,190,30,0.10); border-color: rgba(255,190,30,0.3); color: #ffc030; }

/* ── Robot card accent ── */
.usine-item-card--robot { border-color: rgba(0,180,255,0.10); }
.usine-item-card--robot:hover { border-color: rgba(0,200,255,0.28); }
.usine-build-btn--robot {
    background: linear-gradient(135deg, rgba(0,140,200,0.85), rgba(0,100,170,0.9)) !important;
}

/* ── Empty states ── */
.usine-empty-inline {
    padding: 14px 16px; border-radius: 12px; font-size: 0.86rem; font-style: italic;
    color: rgba(160,190,220,0.5); border: 1px dashed rgba(0,190,220,0.14); text-align: center;
}
.usine-empty-state-card {
    display: flex; flex-direction: column; align-items: center;
    gap: 12px; padding: 40px 24px; border-radius: 18px;
    background: rgba(6,14,28,0.7); border: 1px dashed rgba(0,190,220,0.2); text-align: center;
}
.uesc-icon { font-size: 2.8rem; }
.usine-empty-state-card h4 { margin: 0; color: #d0eeff; font-size: 1.05rem; }
.usine-empty-state-card p { margin: 0; color: rgba(180,210,235,0.6); font-size: 0.88rem; max-width: 320px; }

.magnetic-storm-panel {
    margin-bottom: 18px;
    padding: 12px;
    border: 1px solid rgba(120, 180, 255, 0.45);
    border-radius: 8px;
    background: rgba(25, 40, 80, 0.35);
    box-shadow: 0 0 16px rgba(120, 180, 255, 0.12);
}

.magnetic-storm-panel strong {
    color: #b8d8ff;
}

.magnetic-storm-warning {
    margin-top: 8px;
    color: #ffb0a0;
}

.magnetic-storm-friendly {
    margin-top: 8px;
    color: #9fffc7;
}

.magnetic-storm-panel {
    margin-bottom: 18px;
    padding: 12px;
    border: 1px solid rgba(120, 180, 255, 0.45);
    border-radius: 8px;
    background: rgba(25, 40, 80, 0.35);
}

.magnetic-storm-friendly {
    color: #9fffc7;
}

.magnetic-storm-warning {
    color: #ffb0a0;
}

.storm-current-position {
    margin-top: 10px;
    padding: 10px;
    border: 1px solid rgba(120, 180, 255, 0.35);
    border-radius: 6px;
}
