/* Weight Limit Monitor Specific Styles */

/* Weight Analysis Display */
.weight-analysis {
    background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
    border-radius: 12px;
    padding: 24px;
    margin: 20px 0;
    border: 2px solid #10b981;
}

.weight-header {
    text-align: center;
    margin-bottom: 20px;
}

.weight-title {
    font-size: 20px;
    font-weight: 600;
    color: #059669;
    margin-bottom: 8px;
}

.weight-subtitle {
    font-size: 14px;
    color: #064e3b;
}

.weight-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.weight-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    border: 2px solid #e2e8f0;
    text-align: center;
    transition: all 0.3s ease;
}

.weight-card:hover {
    border-color: #10b981;
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.15);
    transform: translateY(-2px);
}

.weight-card.safe {
    border-color: #10b981;
    background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
}

.weight-card.warning {
    border-color: #f59e0b;
    background: linear-gradient(135deg, #fefbf3, #fef3c7);
}

.weight-card.danger {
    border-color: #ef4444;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
}

.weight-card.info {
    border-color: #3b82f6;
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
}

.usage-patterns {
    margin-top: 20px;
}

.usage-patterns h4 {
    color: #1e293b;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e2e8f0;
}

.pattern-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 12px;
}

.pattern-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #f8fafc;
}

.pattern-item:hover {
    border-color: #2563eb;
    background: #f1f5f9;
}

.pattern-item input[type="checkbox"] {
    display: none;
}

.pattern-item input[type="checkbox"]:checked + .checkmark {
    background: #2563eb;
    border-color: #2563eb;
}

.pattern-item input[type="checkbox"]:checked + .checkmark::after {
    opacity: 1;
}

.pattern-item:has(input[type="checkbox"]:checked) {
    border-color: #2563eb;
    background: linear-gradient(135deg, #eff6ff, #f1f5f9);
}

.pattern-item .checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.pattern-item .checkmark::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.pattern-details {
    flex: 1;
}

.pattern-details strong {
    display: block;
    color: #1e293b;
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
}

.pattern-details span {
    color: #64748b;
    font-size: 13px;
    line-height: 1.4;
}

.capacity-overview {
    margin-bottom: 32px;
}

.capacity-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.capacity-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    transition: all 0.2s ease;
}

.capacity-card:hover {
    border-color: #2563eb;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.capacity-card.safe {
    border-color: #10b981;
    background: linear-gradient(135deg, #ecfdf5, #f0fdf4);
}

.capacity-card.caution {
    border-color: #f59e0b;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
}

.capacity-card.warning {
    border-color: #ef4444;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
}

.capacity-card.danger {
    border-color: #dc2626;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
}

.capacity-title {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.capacity-value {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    font-family: 'Roboto Mono', monospace;
}

.capacity-card.safe .capacity-value {
    color: #065f46;
}

.capacity-card.caution .capacity-value {
    color: #92400e;
}

.capacity-card.warning .capacity-value {
    color: #dc2626;
}

.capacity-card.danger .capacity-value {
    color: #991b1b;
}

.capacity-description {
    font-size: 12px;
    color: #64748b;
    line-height: 1.3;
}

.weight-distribution {
    margin: 32px 0;
}

.distribution-chart {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 24px;
    margin-top: 16px;
}

.weight-gauge {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 20px 0;
}

.gauge-container {
    position: relative;
    width: 250px;
    height: 125px;
}

.gauge-arc {
    width: 100%;
    height: 100%;
}

.gauge-needle {
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 3px;
    height: 100px;
    background: #2563eb;
    transform-origin: bottom center;
    transition: transform 0.8s ease;
    border-radius: 2px;
}

.gauge-value {
    position: absolute;
    bottom: -25px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    font-weight: 700;
    color: #2563eb;
    font-family: 'Roboto Mono', monospace;
}

.distribution-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.distribution-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
}

.distribution-label {
    font-weight: 500;
    color: #374151;
    font-size: 14px;
}

.distribution-value {
    font-weight: 600;
    color: #2563eb;
    font-size: 14px;
    font-family: 'Roboto Mono', monospace;
}

.impact-assessment {
    margin: 32px 0;
}

.impact-factors {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.impact-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.2s ease;
}

.impact-card:hover {
    border-color: #2563eb;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.impact-card.positive {
    border-color: #10b981;
    background: linear-gradient(135deg, #ecfdf5, #f0fdf4);
}

.impact-card.neutral {
    border-color: #f59e0b;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
}

.impact-card.negative {
    border-color: #ef4444;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
}

.impact-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.impact-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: white;
}

.impact-card.positive .impact-icon {
    background: #10b981;
}

.impact-card.neutral .impact-icon {
    background: #f59e0b;
}

.impact-card.negative .impact-icon {
    background: #ef4444;
}

.impact-title {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
}

.impact-score {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    font-family: 'Roboto Mono', monospace;
}

.impact-card.positive .impact-score {
    color: #065f46;
}

.impact-card.neutral .impact-score {
    color: #92400e;
}

.impact-card.negative .impact-score {
    color: #dc2626;
}

.impact-description {
    color: #64748b;
    font-size: 13px;
    line-height: 1.4;
}

.monitoring-recommendations {
    margin: 32px 0;
}

.recommendation-list {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.recommendation-item {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.2s ease;
}

.recommendation-item:hover {
    border-color: #2563eb;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.recommendation-item.priority-high {
    border-color: #ef4444;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
}

.recommendation-item.priority-medium {
    border-color: #f59e0b;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
}

.recommendation-item.priority-low {
    border-color: #10b981;
    background: linear-gradient(135deg, #ecfdf5, #f0fdf4);
}

.recommendation-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.recommendation-priority {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.recommendation-item.priority-high .recommendation-priority {
    background: #ef4444;
    color: white;
}

.recommendation-item.priority-medium .recommendation-priority {
    background: #f59e0b;
    color: white;
}

.recommendation-item.priority-low .recommendation-priority {
    background: #10b981;
    color: white;
}

.recommendation-title {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    flex: 1;
}

.recommendation-description {
    color: #64748b;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 12px;
}

.recommendation-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.recommendation-action {
    padding: 6px 12px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 12px;
    color: #374151;
    text-decoration: none;
    transition: all 0.2s ease;
}

.recommendation-action:hover {
    background: #e2e8f0;
    border-color: #2563eb;
    color: #2563eb;
}

.capacity-guidelines {
    space-y: 12px;
}

.guideline-item {
    padding: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    margin-bottom: 12px;
}

.guideline-item.safe {
    background: linear-gradient(135deg, #ecfdf5, #f0fdf4);
    border-color: #10b981;
}

.guideline-item.caution {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #f59e0b;
}

.guideline-item.warning {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border-color: #ef4444;
}

.guideline-item.danger {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border-color: #dc2626;
}

.guideline-item strong {
    display: block;
    color: #1e293b;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.guideline-item span {
    display: block;
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 4px;
    font-family: 'Roboto Mono', monospace;
}

.guideline-item.safe span {
    color: #065f46;
}

.guideline-item.caution span {
    color: #92400e;
}

.guideline-item.warning span {
    color: #dc2626;
}

.guideline-item.danger span {
    color: #991b1b;
}

.guideline-item small {
    color: #64748b;
    font-size: 12px;
}

.capacity-types {
    space-y: 12px;
}

.type-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    margin-bottom: 8px;
}

.type-name {
    font-weight: 500;
    color: #374151;
    font-size: 13px;
}

.type-capacity {
    font-weight: 600;
    color: #2563eb;
    font-size: 12px;
    font-family: 'Roboto Mono', monospace;
}

/* Responsive Design */
@media (max-width: 768px) {
    .pattern-grid {
        grid-template-columns: 1fr;
    }
    
    .capacity-summary {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .distribution-details {
        grid-template-columns: 1fr;
    }
    
    .impact-factors {
        grid-template-columns: 1fr;
    }
    
    .gauge-container {
        width: 200px;
        height: 100px;
    }
    
    .gauge-needle {
        height: 80px;
    }
}

@media (max-width: 480px) {
    .capacity-summary {
        grid-template-columns: 1fr;
    }
    
    .recommendation-actions {
        flex-direction: column;
    }
    
    .type-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}

/* Animation for capacity reveal */
@keyframes capacityReveal {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.capacity-card.animate {
    animation: capacityReveal 0.6s ease-out;
}

/* Loading states */
.distribution-chart.loading {
    opacity: 0.6;
    pointer-events: none;
}

.distribution-chart.loading::after {
    content: "Analyzing weight distribution...";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.9);
    padding: 16px 24px;
    border-radius: 8px;
    font-weight: 500;
    color: #374151;
}
