/* 🚀 CI/CD Dashboard Styles - LA CRÈME DE LA CRÈME */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Status Overview */
.status-overview {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.status-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 15px;
    transition: transform 0.2s ease;
}

.status-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.status-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    border-radius: 50%;
}

.status-info h3 {
    margin: 0 0 5px 0;
    color: #2c3e50;
    font-size: 1.1rem;
}

.status-info p {
    margin: 0 0 5px 0;
    font-size: 1.5rem;
    font-weight: bold;
    color: #27ae60;
}

.status-info small {
    color: #7f8c8d;
    font-size: 0.9rem;
}

/* Dashboard Sections */
.dashboard-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ecf0f1;
}

.section-header h2 {
    margin: 0;
    color: #2c3e50;
    font-size: 1.5rem;
}

.section-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* Deployment Management */
.deployment-status {
    margin-bottom: 25px;
}

.current-deployment {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.current-deployment h3 {
    margin: 0 0 15px 0;
    color: #2c3e50;
}

.deployment-progress {
    display: flex;
    align-items: center;
    gap: 15px;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: #ecf0f1;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #27ae60, #2ecc71);
    transition: width 0.3s ease;
}

.deployment-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.deployment-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #27ae60;
}

.deployment-item.failed {
    border-left-color: #e74c3c;
}

.deployment-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.deployment-meta {
    display: flex;
    gap: 15px;
    align-items: center;
    font-size: 0.9rem;
    color: #7f8c8d;
}

/* Monitoring Grid */
.monitoring-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.monitoring-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.monitoring-card h4 {
    margin: 0 0 15px 0;
    color: #2c3e50;
}

.monitoring-card canvas {
    width: 100% !important;
    height: 200px !important;
}

/* Resource Meters */
.resource-meters {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.resource-meter {
    display: flex;
    align-items: center;
    gap: 15px;
}

.resource-meter label {
    min-width: 100px;
    font-weight: 500;
    color: #2c3e50;
}

.meter {
    flex: 1;
    height: 8px;
    background: #ecf0f1;
    border-radius: 4px;
    overflow: hidden;
}

.meter-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db, #2980b9);
    transition: width 0.3s ease;
}

.resource-meter span {
    min-width: 40px;
    text-align: right;
    font-weight: bold;
    color: #2c3e50;
}

/* Developer Tools */
.developer-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.tool-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.tool-card h4 {
    margin: 0 0 15px 0;
    color: #2c3e50;
}

/* Feature Flags */
.feature-flags {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feature-flag {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.feature-flag label {
    font-weight: 500;
    color: #2c3e50;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    width: 50px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #27ae60;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

/* API Testing */
.api-testing {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.api-result {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 15px;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    max-height: 200px;
    overflow-y: auto;
    white-space: pre-wrap;
}

/* Database Tools */
.database-tools {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Notification Settings */
.notification-settings {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.notification-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-option label {
    font-weight: 500;
    color: #2c3e50;
}

/* Logs Viewer */
.logs-container {
    background: #2c3e50;
    border-radius: 8px;
    overflow: hidden;
}

.logs-viewer {
    height: 400px;
    overflow-y: auto;
    padding: 20px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: #ecf0f1;
    line-height: 1.4;
}

.log-entry {
    margin-bottom: 5px;
    padding: 5px 0;
}

.log-entry.error {
    color: #e74c3c;
}

.log-entry.warning {
    color: #f39c12;
}

.log-entry.info {
    color: #3498db;
}

.log-entry.success {
    color: #27ae60;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #ecf0f1;
}

.modal-header h3 {
    margin: 0;
    color: #2c3e50;
}

.close {
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #7f8c8d;
}

.close:hover {
    color: #2c3e50;
}

.modal-body {
    padding: 25px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px 25px;
    border-top: 1px solid #ecf0f1;
}

.deployment-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-top: 15px;
}

.deployment-info p {
    margin: 5px 0;
    color: #2c3e50;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .status-overview {
        grid-template-columns: 1fr;
    }
    
    .monitoring-grid {
        grid-template-columns: 1fr;
    }
    
    .developer-tools-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .section-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Animations */
@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

.deploying {
    animation: pulse 2s infinite;
}

.success-flash {
    animation: successFlash 0.5s ease-in-out;
}

@keyframes successFlash {
    0% { background-color: transparent; }
    50% { background-color: rgba(39, 174, 96, 0.2); }
    100% { background-color: transparent; }
}

.error-flash {
    animation: errorFlash 0.5s ease-in-out;
}

@keyframes errorFlash {
    0% { background-color: transparent; }
    50% { background-color: rgba(231, 76, 60, 0.2); }
    100% { background-color: transparent; }
}