/* Algemene instellingen */
body {
    font-family: 'Open Sans', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    color: #333;
    height: 100vh;
    overflow: hidden;
    /* Nooit scrollen op de hele pagina */
    display: flex;
    flex-direction: column;
    align-items: center;
}

h1,
h2,
h3 {
    color: #0056b3;
    /* Mooi blauw zoals je origineel wilde */
    margin: 0.5em 0;
    text-align: center;
}

/* Containers */
#user-status-container,
#calls-container {
    background-color: #ffffff;
    padding: 20px;
    margin: 10px 0;
    width: 100%;
    max-width: 1200px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

/* Gebruikersstatus header */
.header-with-help {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 56px;
    background: #ffffff;
    border-bottom: 1px solid #ddd;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
}

.header-with-help h1 {
    font-size: 1.5em;
    margin: 0;
    line-height: 56px;
}

#help-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background-color: #007BFF;
    color: white;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s;
}

#help-icon:hover {
    background-color: #0056b3;
}

/* API key knop centreren */
#user-status-container button {
    display: block;
    margin: 20px auto 0;
    background-color: #0056b3;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 0.9em;
    border-radius: 4px;
    cursor: pointer;
}

#user-status-container button:hover {
    background-color: #004494;
}

/* Gebruikersblokken */
#users {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.user-block {
    height: 60px;
    font-size: 0.9em;
    font-weight: bold;
    border-radius: 6px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.user-block.available {
    background-color: #28a745;
}

.user-block.busy {
    background-color: #dc3545;
}

.user-block.ringing {
    background-color: #ffc107;
    color: #000;
}

.user-block.lightblue {
    background-color: #17a2b8;
}

/* Gesprekken container met scroll */
#calls-container {
    flex: 1 1 auto;
    overflow-y: auto;
    height: calc(100vh - 450px);
    /* Aangepaste hoogte */
}

/* Gesprekken tabel */
#calls-container h1 {
    text-align: center;
    font-size: 1.5em;
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead th {
    background-color: #f8f9fa;
    color: #333;
    padding: 10px;
    border-bottom: 2px solid #ccc;
    text-align: left;
}

tbody td {
    padding: 10px;
    border-bottom: 1px solid #e0e0e0;
    vertical-align: top;
    word-wrap: break-word;
}

tr:nth-child(even) td {
    background-color: #f9f9f9;
}

tr.missed td {
    background-color: #ffe0e0 !important;
}

/* Overlay */
#help-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 10;
}

#help-overlay.show {
    display: block;
}

/* Popup helpballon */
#help-balloon {
    position: fixed;
    top: 50%;
    left: 50%;
    width: 400px;
    max-width: 90%;
    background: white;
    border-radius: 10px;
    padding: 20px;
    transform: translate(-50%, -50%);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    font-family: 'Open Sans', sans-serif;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    z-index: 11;
}

#help-balloon.show {
    opacity: 1;
    pointer-events: auto;
}

#help-balloon h2 {
    margin-top: 0;
    font-size: 20px;
    text-align: center;
    color: #007BFF;
}

#help-balloon p {
    font-size: 14px;
    text-align: center;
    line-height: 1.6;
    margin: 15px 0 0;
}

#help-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 20px;
    color: #aaa;
    cursor: pointer;
}

#help-close:hover {
    color: #000;
}

/* Responsiveness */
@media (max-width: 500px) {
    #help-balloon {
        width: 90%;
        padding: 15px;
    }

    #help-balloon h2 {
        font-size: 18px;
    }

    #help-balloon p {
        font-size: 13px;
    }
}