/* ============================================
   header.css — шапка внутри экрана

   СТРУКТУРА — одна строка:
   [УСЛУГИ][РЕШЕНИЯ][КЕЙСЫ][О НАС]  →пружина→  ●СИСТЕМА В НОРМЕ  00:00:00
   ============================================ */

/* Шапка — один flex-ряд */
.hmi-header {
    width: 100%;
    flex-shrink: 0;
    background: #1a1a1a;
    padding: 1vh 2vh;
    border-bottom: 0.2vh solid #333;
    box-sizing: border-box;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.5vh;
}

/* Кнопки меню — слева */
.nav-links {
    display: flex;
    gap: 0.5vh;
    flex-shrink: 0;
}

.nav-links a {
    background: linear-gradient(180deg, #333, #111);
    color: #888;
    text-decoration: none;
    font-size: 1.1vh;
    padding: 0.6vh 1.5vh;
    border: 0.1vh solid #444;
    border-radius: 0.3vh;
    text-transform: uppercase;
    letter-spacing: 0.1vh;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    white-space: nowrap;
    cursor: pointer;
}

/* Кнопка ГЛАВНАЯ — чуть выделена от остальных */
.nav-links a.nav-home {
    color: #666;
    border-color: #333;
    border-right: 0.2vh solid #444; /* разделитель справа */
    margin-right: 0.5vh;
}

.nav-links a.nav-home:hover {
    color: #00ff00;
    border-color: #00ff00;
}

.nav-links a.active,
.nav-links a:hover {
    background: #444;
    color: #00ff00;
    border-color: #00ff00;
    box-shadow: inset 0 0 0.5vh rgba(0,255,0,0.2);
}

/* Пружина — занимает всё свободное место между меню и статусом */
.hmi-header-spacer {
    flex: 1;
}

/* Блок статуса — справа */
.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.8vh;
    color: #00ff00;
    font-size: 1.2vh;
    letter-spacing: 0.1vh;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Светодиод */
.led {
    width: 0.8vh;
    height: 0.8vh;
    background: #00ff00;
    border-radius: 50%;
    box-shadow: 0 0 0.8vh #00ff00;
    flex-shrink: 0;
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; box-shadow: 0 0 0.8vh #00ff00; }
    50%       { opacity: 0.4; box-shadow: 0 0 0.2vh #00ff00; }
}

/* Часы — справа от статуса */
.system-time {
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 2.5vh;
    font-weight: bold;
    letter-spacing: 0.3vh;
    text-shadow: 0 0 1vh #00ff00, 0 0 2vh rgba(0,255,0,0.5);
    background: rgba(0,255,0,0.05);
    border: 0.1vh solid rgba(0,255,0,0.2);
    padding: 0.3vh 1vh;
    border-radius: 0.3vh;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Старые обёртки — оставляем для совместимости но прозрачными */
.header-top-row { display: contents; }
.hmi-nav        { display: contents; }
.hmi-label      { display: none; }
