.modal.hidden {
    display: none !important;
}

/* Rest of your existing CSS */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    z-index: 100;
    overflow-y: auto;
    padding: 1rem;
}

.modal > div {
    margin-top: 2rem;
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
    width: 100%;
}

/* Hide scrollbar when modal is open */
body.modal-open {
    overflow: hidden;
}

/* Image hover effects */
.image-hover {
    transition: transform 0.3s ease;
}

.image-hover:hover {
    transform: scale(1.05);
}

/* Custom scrollbar for modals */
.modal-content {
    scrollbar-width: thin;
    scrollbar-color: #CBD5E0 #EDF2F7;
}

.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: #EDF2F7;
}

.modal-content::-webkit-scrollbar-thumb {
    background-color: #CBD5E0;
    border-radius: 4px;
}

/* Button hover transitions */
.btn-transition {
    transition: all 0.2s ease;
}

/* Form input focus styles */
.form-input:focus {
    outline: none;
    ring: 2px;
    ring-color: #3B82F6;
}

/* Grid item hover effects */
.grid-item {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.grid-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Add these styles to prevent logo flashing */
.logo-container {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-container img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
}

@media (max-width: 767px) {
    #mainNav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        z-index: 50;
        padding: 1rem;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    }
}

/* Mobile Navigation Styles */
#mobileNav {
    transition: all 0.3s ease-in-out;
    max-height: calc(100vh - 70px);
    overflow-y: auto;
}

#mobileNav a {
    transition: background-color 0.2s ease;
}

/* Header Styles */
header {
    position: relative;
    z-index: 40;
}

/* User Section Styles */
#userSection, #userSectionDesktop {
    white-space: nowrap;
}

#userSectionDesktop .text-gray-700 {
    display: inline-block !important;
}

/* Ensure buttons don't wrap */
.whitespace-nowrap {
    white-space: nowrap;
}

/* Fix modal z-index */
.modal {
    z-index: 50;
}

/* Ensure desktop nav stays visible */
@media (min-width: 768px) {
    .md\:flex {
        display: flex !important;
    }
}

/* Mobile Navigation */
#mobileNav {
    transition: all 0.2s ease-in-out;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

@media (max-width: 767px) {
    .container {
        width: 100%;
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    #mainInterface {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* Ensure welcome message is visible on desktop */
@media (min-width: 768px) {
    .md\:inline {
        display: inline !important;
    }
}