/* Laboratory CSS - Underground Farmer */

/* Laboratory Section */
#lab-section {
    padding: 20px;
    background: linear-gradient(135deg, #2a2a3a 0%, #1a1a2a 100%);
    border-radius: 12px;
    margin: 10px;
    min-height: 400px;
    max-height: 600px;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Custom Scrollbar */
#lab-section::-webkit-scrollbar {
    width: 12px;
}

#lab-section::-webkit-scrollbar-track {
    background: linear-gradient(135deg, #1a1a2a 0%, #2a2a3a 100%);
    border-radius: 6px;
}

#lab-section::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #4a4a6a 0%, #3a3a5a 100%);
    border-radius: 6px;
    border: 2px solid #2a2a3a;
}

#lab-section::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5a5a7a 0%, #4a4a6a 100%);
}

#lab-area {
    max-width: 100%;
    margin: 0 auto;
}

/* Laboratory Header */
.lab-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #4a4a6a 0%, #3a3a5a 100%);
    border-radius: 12px;
    border: 2px solid #6a6a8a;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.lab-title {
    font-size: 24px;
    font-weight: bold;
    color: #e6e6ff;
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.lab-subtitle {
    font-size: 14px;
    color: #b8b8d8;
    opacity: 0.9;
}

/* Laboratory Categories */
.lab-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.lab-category {
    background: linear-gradient(135deg, #3a3a4a 0%, #2a2a3a 100%);
    border: 2px solid #5a5a7a;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.lab-category:hover {
    transform: translateY(-4px);
    border-color: #7a7a9a;
    box-shadow: 0 8px 16px rgba(0,0,0,0.4);
}

.lab-category:active {
    transform: translateY(-2px);
}

.lab-category.selected {
    border-color: #5a5a7a;
    background: linear-gradient(135deg, #3a3a4a 0%, #2a2a3a 100%);
    box-shadow: none;
    animation: none !important;
}

/* Category Icon */
.category-icon {
    font-size: 48px;
    text-align: center;
    margin-bottom: 15px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
    border-radius: 8px;
    margin: 0 auto 15px;
    width: 80px;
}

/* Category Info */
.category-name {
    font-size: 18px;
    font-weight: bold;
    color: #e6e6ff;
    text-align: center;
    margin-bottom: 8px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.category-description {
    font-size: 12px;
    color: #b8b8d8;
    text-align: center;
    line-height: 1.4;
    opacity: 0.9;
}

.category-stats {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-level {
    font-size: 12px;
    color: #87ceeb;
    background: rgba(135, 206, 235, 0.2);
    padding: 4px 8px;
    border-radius: 4px;
}

.category-progress {
    font-size: 12px;
    color: #daa520;
    background: rgba(218, 165, 32, 0.2);
    padding: 4px 8px;
    border-radius: 4px;
}

/* Laboratory Content Area */
.lab-content {
    margin-top: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #3a3a4a 0%, #2a2a3a 100%);
    border-radius: 12px;
    border: 2px solid #5a5a7a;
    min-height: 200px;
}

.lab-content-header {
    text-align: center;
    margin-bottom: 20px;
}

.lab-content-title {
    font-size: 20px;
    font-weight: bold;
    color: #e6e6ff;
    margin-bottom: 8px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.lab-content-subtitle {
    font-size: 14px;
    color: #b8b8d8;
    opacity: 0.9;
}

/* Coming Soon Placeholder */
.coming-soon {
    text-align: center;
    padding: 40px 20px;
    color: #888;
    font-style: italic;
}

.coming-soon-icon {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.coming-soon-text {
    font-size: 18px;
    margin-bottom: 10px;
}

.coming-soon-subtitle {
    font-size: 14px;
    opacity: 0.7;
}

/* Laboratory Selector in Top UI */
#lab-selector {
    display: flex;
    gap: 10px;
    align-items: center;
}

#lab-selector .upgrade-btn {
    background: linear-gradient(135deg, #4a4a6a 0%, #3a3a5a 100%);
    border: 2px solid #6a6a8a;
    color: #e6e6ff;
}

#lab-selector .upgrade-btn:hover {
    border-color: #8a8aaa;
    background: linear-gradient(135deg, #5a5a7a 0%, #4a4a6a 100%);
}

/* Responsive Design */
@media (max-width: 768px) {
    .lab-categories {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .category-icon {
        font-size: 40px;
        height: 50px;
        width: 70px;
    }
    
    .category-name {
        font-size: 16px;
    }
    
    .lab-title {
        font-size: 20px;
    }
}

/* Animation Effects */
@keyframes labGlow {
    0%, 100% { box-shadow: 0 0 10px rgba(218, 165, 32, 0.3); }
    50% { box-shadow: 0 0 20px rgba(218, 165, 32, 0.5); }
}

.lab-category.selected {
    animation: none !important;
}

/* Particle Effect Background */
.lab-category::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at random, rgba(255,255,255,0.1) 1px, transparent 1px);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.lab-category:hover::before {
    opacity: 1;
}

/* Research Modal */
.research-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    backdrop-filter: blur(5px);
}

.research-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.research-modal-content {
    background: linear-gradient(135deg, #2a2a3a 0%, #1a1a2a 100%);
    border: 3px solid #6a6a8a;
    border-radius: 16px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    animation: modalSlideIn 0.3s ease;
    position: relative;
}

@keyframes modalSlideIn {
    from { 
        transform: translateY(-50px);
        opacity: 0;
    }
    to { 
        transform: translateY(0);
        opacity: 1;
    }
}

/* Research Modal Header */
.research-modal-header {
    padding: 25px 30px 20px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(135deg, #4a4a6a 0%, #3a3a5a 100%);
    border-radius: 13px 13px 0 0;
    position: relative;
}

.research-modal-title {
    font-size: 28px;
    font-weight: bold;
    color: #e6e6ff;
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 15px;
}

.research-modal-subtitle {
    font-size: 16px;
    color: #b8b8d8;
    opacity: 0.9;
}

.research-modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    color: #e6e6ff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.research-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

/* Research Modal Body */
.research-modal-body {
    padding: 30px;
}

.research-coming-soon {
    text-align: center;
    padding: 60px 20px;
    color: #888;
}

.research-coming-soon-icon {
    font-size: 80px;
    margin-bottom: 30px;
    opacity: 0.6;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.research-coming-soon-title {
    font-size: 24px;
    font-weight: bold;
    color: #b8b8d8;
    margin-bottom: 15px;
}

.research-coming-soon-text {
    font-size: 16px;
    color: #888;
    margin-bottom: 10px;
    line-height: 1.5;
}

.research-coming-soon-subtitle {
    font-size: 14px;
    color: #666;
    opacity: 0.8;
    font-style: italic;
}

/* Research Categories in Modal */
.research-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.research-category-placeholder {
    background: linear-gradient(135deg, #3a3a4a 0%, #2a2a3a 100%);
    border: 2px solid #5a5a7a;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.research-category-placeholder:hover {
    opacity: 0.8;
    border-color: #7a7a9a;
}

.research-placeholder-icon {
    font-size: 32px;
    margin-bottom: 10px;
    display: block;
}

.research-placeholder-text {
    font-size: 14px;
    color: #888;
}

/* Modal Scrollbar */
.research-modal-content::-webkit-scrollbar {
    width: 10px;
}

.research-modal-content::-webkit-scrollbar-track {
    background: linear-gradient(135deg, #1a1a2a 0%, #2a2a3a 100%);
    border-radius: 5px;
}

.research-modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #4a4a6a 0%, #3a3a5a 100%);
    border-radius: 5px;
    border: 1px solid #2a2a3a;
}

.research-modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5a5a7a 0%, #4a4a6a 100%);
}

/* Responsive Design for Modal */
@media (max-width: 768px) {
    .research-modal-content {
        width: 95%;
        max-height: 90vh;
        margin: 20px;
    }
    
    .research-modal-header {
        padding: 20px 25px 15px;
    }
    
    .research-modal-title {
        font-size: 22px;
        gap: 10px;
    }
    
    .research-modal-body {
        padding: 20px;
    }
    
    .research-coming-soon {
        padding: 40px 15px;
    }
    
    .research-coming-soon-icon {
        font-size: 60px;
    }
    
    .research-coming-soon-title {
        font-size: 20px;
    }
} 