* {
    font-family: 'Open Sans', sans-serif;
}

.header {
    background-color: #0a1e3c; 
    color: white;
    padding: 0 20px;
    display: flex;
    align-items: center;
    height: 74px;
    position: relative;
    min-width: 0;
}

.logo {
    display: flex;
    align-items: center;
    margin-left: 18px;
    flex-shrink: 0;
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 54px;
    width: 54px;
}

.logo-image {
    width: 150px;
    height: 48px;
    object-fit: contain;
    border-radius: 6px;
    margin-left: 35px;
}

.header-title {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 74px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 1;
}

.header-title-text {
    font-size: 28px;
    font-weight: 400;
    color: white;
    letter-spacing: 1px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: calc(100vw - 450px);
}

.header-button {
    margin-left: auto;
    z-index: 10;
    flex-shrink: 0;
}

.header-logout-link {
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 4px;
    transition: background-color 0.2s;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    text-decoration: none;
    font-size: 14px;
    white-space: nowrap;
    display: inline-block;
}

.header-logout-link:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Sidebar styles */
.sidebar {
    width: 200px;
    background-color: white;
    border-right: 1px solid rgb(111, 118, 130);
    display: flex;
    flex-direction: column;
}

.sidebar-item {
    padding: 12px 20px;
    font-weight: 600;
    color: rgb(111, 118, 130);
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}

.sidebar-item:hover {
    background-color: rgb(75, 175, 210);
    color: white;
}

.sidebar-item.active {
    background-color: rgb(27, 48, 71);
    color: white;
}

/* Container for help button at bottom of sidebar */
.sidebar-help-container {
    margin-top: auto;
    padding: 20px 16px;
}

/* Help button container */
.help-button-container {
    position: relative;
    display: inline-block;
}

/* Help button styles */
.help-button {
    background: #394a65;
    color: white;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    transition: background 0.2s ease;
}

.help-button:hover {
    background: #4a5d7a;
}

.help-button:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(57, 74, 101, 0.3);
}

/* Popup styles - Centered in viewport */
.help-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: white;
    border: 1px solid #e8ecef;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
    padding: 30px;
    width: 400px;
    max-width: 90vw;
    max-height: 80vh;
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 14px;
    line-height: 1.6;
    color: rgb(27, 48, 71);
    overflow-y: auto;
    cursor: default;
    pointer-events: none;
}

.help-popup.show {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.help-popup-title {
    font-weight: 600;
    color: #394a65;
    margin-bottom: 8px;
    font-size: 15px;
    cursor: text;
}

/* Overlay for closing popups */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: none;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease;
}

.popup-overlay.show {
    display: block;
}

/* Responsive design for smaller screens */
@media (max-width: 768px) {
    .header {
        padding: 0 15px;
        height: 64px;
    }
    
    .logo {
        margin-left: 10px;
    }
    
    .logo-image {
        width: 120px;
        height: 38px;
        margin-left: 15px;
    }
    
    .header-title {
        height: 64px;
    }
    
    .header-title-text {
        font-size: 20px;
        max-width: calc(100vw - 350px);
    }
    
    .header-logout-link {
        font-size: 13px;
        padding: 5px 10px;
    }

    /* Adjust popup for mobile */
    .help-popup {
        width: 90vw;
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 0 10px;
        height: 56px;
        flex-wrap: nowrap;
    }
    
    .logo {
        margin-left: 5px;
    }
    
    .logo-image {
        width: 100px;
        height: 32px;
        margin-left: 5px;
    }
    
    .header-title {
        height: 56px;
        display: flex;
    }
    
    .header-title-text {
        font-size: 16px;
        max-width: calc(100vw - 220px);
    }
    
    .header-logout-link {
        font-size: 11px;
        padding: 3px 6px;
        max-width: 80px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Further adjust popup for very small screens */
    .help-popup {
        width: 90vw;
        padding: 20px;
        max-height: 70vh;
    }
}

.footer {
    background-color: #0a1e3c; 
    color: white;
    text-align: right;
    padding: 15px 20px;
    font-size: 12px;
}

.footer a {
    color: white;
    text-decoration: none;
}

.heart {
    color: red;
}

/* Responsive footer */
@media (max-width: 480px) {
    .footer {
        text-align: center;
        padding: 10px 15px;
        font-size: 11px;
    }
}