/* Partner Disturbance Calculator Specific Styles */

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

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

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

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

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

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

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

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

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

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

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

.behavior-assessment {
    margin-top: 20px;
}

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

.movement-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.movement-category {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
}

.movement-category h5 {
    color: #1e293b;
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 16px;
    text-align: center;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
}

.movement-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    margin-bottom: 8px;
}

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

.movement-item input[type="radio"] {
    display: none;
}

.movement-item input[type="radio"]:checked + .radio-mark {
    background: #2563eb;
    border-color: #2563eb;
}

.movement-item input[type="radio"]:checked + .radio-mark::after {
    opacity: 1;
}

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

.movement-item .radio-mark {
    width: 18px;
    height: 18px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.movement-item .radio-mark::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.movement-details {
    flex: 1;
}

.movement-details strong {
    display: block;
    color: #1e293b;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 2px;
}

.movement-details span {
    color: #64748b;
    font-size: 12px;
    line-height: 1.3;
}

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

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

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

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

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

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

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

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

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

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

.disturbance-card.low .disturbance-value {
    color: #065f46;
}

.disturbance-card.moderate .disturbance-value {
    color: #92400e;
}

.disturbance-card.high .disturbance-value {
    color: #dc2626;
}

.disturbance-card.severe .disturbance-value {
    color: #991b1b;
}

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

.motion-analysis {
    margin: 32px 0;
}

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

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

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

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

.motion-card.good {
    border-color: #2563eb;
    background: linear-gradient(135deg, #eff6ff, #f1f5f9);
}

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

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

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

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

.motion-card.excellent .motion-icon {
    background: #10b981;
}

.motion-card.good .motion-icon {
    background: #2563eb;
}

.motion-card.fair .motion-icon {
    background: #f59e0b;
}

.motion-card.poor .motion-icon {
    background: #ef4444;
}

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

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

.motion-card.excellent .motion-score {
    color: #065f46;
}

.motion-card.good .motion-score {
    color: #1e40af;
}

.motion-card.fair .motion-score {
    color: #92400e;
}

.motion-card.poor .motion-score {
    color: #dc2626;
}

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

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

.impact-assessment {
    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.minimal {
    border-color: #10b981;
    background: linear-gradient(135deg, #ecfdf5, #f0fdf4);
}

.impact-card.mild {
    border-color: #2563eb;
    background: linear-gradient(135deg, #eff6ff, #f1f5f9);
}

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

.impact-card.severe {
    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.minimal .impact-icon {
    background: #10b981;
}

.impact-card.mild .impact-icon {
    background: #2563eb;
}

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

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

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

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

.impact-card.minimal .impact-level {
    color: #065f46;
}

.impact-card.mild .impact-level {
    color: #1e40af;
}

.impact-card.moderate .impact-level {
    color: #92400e;
}

.impact-card.severe .impact-level {
    color: #dc2626;
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

.strategy-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;
}

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

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

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

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

.guideline-item.good {
    background: linear-gradient(135deg, #eff6ff, #f1f5f9);
    border-color: #2563eb;
}

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

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

.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.excellent span {
    color: #065f46;
}

.guideline-item.good span {
    color: #1e40af;
}

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

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

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

.isolation-ratings {
    space-y: 12px;
}

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

.rating-material {
    font-weight: 500;
    color: #374151;
    font-size: 13px;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .movement-grid {
        grid-template-columns: 1fr;
    }
    
    .disturbance-summary {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .motion-breakdown {
        grid-template-columns: 1fr;
    }
    
    .impact-assessment {
        grid-template-columns: 1fr;
    }
}

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

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

.disturbance-card.animate {
    animation: disturbanceReveal 0.6s ease-out;
}

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

.motion-breakdown.loading::after {
    content: "Analyzing motion transfer...";
    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;
}
