/*===============================================
    RESET
===============================================*/
*,
*:before,
*:after {
  box-sizing: border-box;
}

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}

/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
  display: block;
}

body {
  line-height: 1;
}

ol, ul {
  list-style: none;
}

blockquote, q {
  quotes: none;
}

blockquote:before, blockquote:after,
q:before, q:after {
  content: '';
  content: none;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

/*===============================================
    VARIABLES
===============================================*/
:root {
    --primary-color-dark: #0F0F1A; /* Un bleu très sombre, presque noir */
    --primary-color-medium: #1C1C2E; /* Un bleu nuit pour les cartes et sections */
    --primary-color-light: #f5f5f5;
    --accent-color: #00BFFF; /* Un bleu ciel vibrant pour l'accentuation */
    --accent-color-hover: #009ACD; /* Un bleu plus soutenu au survol */
    --text-color: #EAEAEA; /* Un blanc cassé pour le confort de lecture */
    --text-color-secondary: #B0B0C0; /* Un gris-bleu pour le texte secondaire */
    --text-color-dark: #111;
    --card-border-color: rgba(255, 255, 255, 0.1);
    --shadow-color: rgba(0, 191, 255, 0.1);
}


/*===============================================
    GENERAL
===============================================*/
body {
    background-color: var(--primary-color-dark);
    background-image: radial-gradient(circle at 50% 0%, rgba(0, 191, 255, 0.05) 0%, var(--primary-color-dark) 40%);
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    font-weight: 400;
    line-height: 1.6;
    padding-top: 80px;
    overflow-x: hidden; /* Empêche le débordement horizontal des animations */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

h1, h2, h3 {
  font-weight: 600;
}

/*===============================================
    HEADER
===============================================*/
.navbar {
    background-color: rgba(15, 15, 26, 0.8); /* Fond plus sombre et transparent */
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    padding: 1rem 2rem;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--card-border-color); /* Ligne de séparation subtile */
    transition: background-color 0.3s ease;
}

.navbar-brand {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--text-color);
  text-decoration: none;
}

.navbar-links a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 1.1rem;
  margin-left: 20px;
  transition: all 0.3s ease;
  position: relative;
  padding: 5px 0;
}

.navbar-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--accent-color);
    transition: all 0.3s ease-in-out;
    transform: translateX(-50%);
}

.navbar-links a:hover::after {
    width: 100%;
}

.navbar-links a:hover {
  color: var(--accent-color);
}

/* Dropdown Menu */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--primary-color-medium);
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 5px;
    border-top: 2px solid var(--accent-color);
}

.dropdown-content a {
    color: var(--text-color);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
    margin-left: 0; /* Override margin from .navbar-links a */
}

.dropdown-content a:hover {
    background-color: var(--accent-color);
    color: var(--primary-color-dark);
}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-header {
    padding: 12px 16px;
    font-weight: bold;
    color: var(--accent-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/*===============================================
    FOOTER
===============================================*/
.footer {
  background-color: var(--primary-color-medium);
  border-top: 2px solid var(--accent-color);
  padding: 1.5rem 2rem;
  text-align: center;
}

.footer-content p {
  font-size: 1rem;
  color: var(--text-color);
}

/*===============================================
    HOME
===============================================*/
.hero {
  text-align: center;
  padding: 6rem 0;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  color: var(--text-color-secondary);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.cta-button {
    background-color: var(--accent-color);
    color: var(--primary-color-dark);
    padding: 1rem 2.5rem;
    text-decoration: none;
    border-radius: 50px;
    font-size: 1.2rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid var(--accent-color);
    box-shadow: 0 4px 20px var(--shadow-color);
}

.cta-button:hover {
    background-color: var(--accent-color-hover);
    color: var(--primary-color-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 25px var(--shadow-color);
}

.modern-button, .back-button {
    border: 2px solid var(--accent-color);
    background-color: var(--accent-color);
    color: var(--primary-color-dark);
    position: relative;
    overflow: hidden;
    z-index: 1;
    border-radius: 50px;
    padding: 1rem 2.5rem;
    font-size: 1.2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.modern-button:hover, .back-button:hover {
    background-color: transparent;
    color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(0, 123, 255, 0.4);
}

.features {
  padding: 6rem 0;
}

.features h2 {
  text-align: center;
  font-size: 2.8rem;
  margin-bottom: 4rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
}

.feature-item {
    background-color: var(--primary-color-medium);
    padding: 2.5rem;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--card-border-color);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.feature-item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0, 191, 255, 0.1) 0%, transparent 40%);
    transition: opacity 0.5s ease;
    opacity: 0;
    transform: rotate(0deg);
}

.feature-item:hover::before {
    opacity: 1;
    animation: rotateGlow 10s linear infinite;
}

@keyframes rotateGlow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.feature-item .cta-button {
    margin-top: 1.5rem;
}

.feature-item:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 50px var(--shadow-color);
    border-color: var(--accent-color);
}

.feature-item i {
  font-size: 2.5rem;
  color: var(--accent-color);
  margin-bottom: 1.5rem;
}

.feature-item h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.feature-item p {
  color: var(--text-color-secondary);
}

.section-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    border: 0;
    width: 80%;
    margin: 6rem auto;
    opacity: 0.3;
}

.centered-section {
    min-height: calc(80vh - 160px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/*===============================================
    MONITORING
===============================================*/
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  padding: 2rem 0;
}

.metric-box {
  background-color: var(--primary-color-medium);
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid var(--accent-color);
  transition: all 0.3s ease;
}

.metric-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.metric-box h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.metric-box p {
  font-size: 1.5rem;
  font-weight: bold;
}

.sub-info {
  font-size: 0.9rem;
  color: var(--accent-color);
}

/*===============================================
    HEBERGEMENT
===============================================*/
.button-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 160px); /* 100vh - header - footer */
}

.modern-button {
  background-color: var(--accent-color);
  color: var(--primary-color-dark);
  padding: 1.5rem 3rem;
  text-decoration: none;
  border-radius: 5px;
  font-size: 1.5rem;
  margin: 1rem 0;
  transition: all 0.3s ease;
}

.modern-button:hover {
  background-color: var(--primary-color-light);
}

.content-container {
    margin: 100px auto 0; /* Center horizontally */
    padding: 20px;
    text-align: center;
    background-color: var(--primary-color-medium);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    max-width: 1200px; /* Augmenté pour accueillir plus de métriques */
    width: 90%;
    display: flex; /* Utilise flexbox pour organiser le contenu */
    flex-direction: column;
    align-items: center;
}

h1 {
    color: var(--accent-color); /* Reprend la couleur de votre bouton */
    margin-bottom: 20px;
}

p {
    font-size: 1.1em;
    line-height: 1.6;
}

/* Style pour un bouton de retour optionnel */
.back-button {
    display: inline-block;
    margin-top: 30px;
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: var(--primary-color-dark);
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.back-button:hover {
    background-color: var(--primary-color-light);
}

/* Nouveaux styles pour les boîtes de métriques */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* 3 colonnes, s'adapte */
    gap: 20px;
    width: 100%;
    margin-top: 30px;
    margin-bottom: 30px;
}

.metric-box {
    background-color: var(--primary-color-medium);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    text-align: left; /* Alignement du texte à gauche dans la boîte */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 120px; /* Hauteur minimale pour l'uniformité */
}

.metric-box h3 {
    color: var(--accent-color); /* Couleur verte pour les titres de métriques */
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.metric-box p {
    font-size: 1.2em;
    font-weight: bold;
    color: var(--text-color);
    margin-bottom: 5px;
}

.metric-box .sub-info {
    font-size: 0.9em;
    color: var(--accent-color);
}

/* Media queries pour la réactivité sur petits écrans */
@media (max-width: 768px) { /* Ajusté le breakpoint pour mieux s'adapter */
    .content-container {
        margin-top: 120px; /* Ajuste la marge pour la navbar empilée */
        width: 95%; /* Utilise plus de largeur sur petits écrans */
        padding: 15px;
    }

    .metrics-grid {
        grid-template-columns: 1fr; /* Une seule colonne sur très petits écrans */
    }
}

/* Styles pour les grands écrans pour corriger le problème de hauteur du hero */
@media (min-height: 700px) and (min-width: 1200px) {
    .hero {
        min-height: calc(100vh - 80px); /* 100vh pour remplir l'écran, 80px = padding-top du body */
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }
}

.header-info {
    display: flex;
    justify-content: space-between;
    padding: 10px 20px;
    background-color: var(--primary-color-medium);
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.9em;
}

.header-info p {
    margin: 0;
}

.metric-box-services {
    grid-column: span 1; /* Default span */
}

@media (min-width: 992px) { /* On larger screens, make services box wider */
    .metric-box-services {
        grid-column: span 2;
    }
}

.services-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.services-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--card-border-color);
}

.services-list li:last-child {
    border-bottom: none;
}

.status-indicator {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: bold;
    text-transform: capitalize;
}

.status-ok {
    background-color: #28a745; /* Vert */
    color: white;
}

.status-error {
    background-color: #dc3545; /* Rouge */
    color: white;
}