/* Harvest Modal Styles */
#harvest-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

#harvest-modal .modal-content {
    background-color: #ffffff;
    margin: 2% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 700px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease;
}

#harvest-modal .modal-header {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
    padding: 20px 30px;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#harvest-modal .modal-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

#harvest-modal .modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

#harvest-modal .modal-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

#harvest-modal .modal-body {
    padding: 30px;
    max-height: 70vh;
    overflow-y: auto;
}

/* Form Sections */
#harvest-modal .form-section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}

#harvest-modal .form-section:last-child {
    border-bottom: none;
}

#harvest-modal .form-section h3 {
    color: #333;
    font-size: 18px;
    margin-bottom: 15px;
    font-weight: 600;
}

/* Form Elements */
#harvest-modal .form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

#harvest-modal .form-group {
    margin-bottom: 15px;
}

#harvest-modal label {
    display: block;
    margin-bottom: 5px;
    color: #555;
    font-size: 14px;
    font-weight: 500;
}

#harvest-modal .form-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#harvest-modal .form-control:focus {
    outline: none;
    border-color: #f39c12;
    box-shadow: 0 0 0 3px rgba(243, 156, 18, 0.1);
}

#harvest-modal textarea.form-control {
    resize: vertical;
    min-height: 60px;
}

#harvest-modal .form-text {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #888;
}

/* Score Sliders */
.score-sliders {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-top: 10px;
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.score-slider {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: #ddd;
    border-radius: 3px;
    outline: none;
    transition: background 0.2s;
}

.score-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: #f39c12;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.score-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.score-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #f39c12;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.score-value {
    min-width: 30px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    color: #f39c12;
    background: white;
    padding: 5px 10px;
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Weight Conversion Display */
#weight-conversion {
    color: #e67e22;
    font-weight: 500;
    margin-top: 5px;
}

/* Form Actions */
#harvest-modal .form-actions {
    display: flex;
    gap: 10px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

#harvest-modal .btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

#harvest-modal .btn-primary {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
    flex: 1;
}

#harvest-modal .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.3);
}

#harvest-modal .btn-secondary {
    background: #f1f3f5;
    color: #495057;
    min-width: 100px;
}

#harvest-modal .btn-secondary:hover {
    background: #e9ecef;
}

#harvest-modal .btn-icon {
    font-size: 18px;
}

/* History Section */
#harvest-modal .modal-history {
    background: #f8f9fa;
    padding: 20px 30px;
    border-top: 1px solid #e0e0e0;
    border-radius: 0 0 12px 12px;
}

#harvest-modal .modal-history h3 {
    color: #333;
    font-size: 18px;
    margin-bottom: 15px;
    font-weight: 600;
}

#harvest-history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.history-item {
    background: white;
    padding: 12px 15px;
    border-radius: 8px;
    border-left: 4px solid #f39c12;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.history-date {
    color: #666;
    font-size: 13px;
    margin-bottom: 5px;
}

.history-details {
    color: #333;
    font-size: 14px;
}

.history-quality {
    color: #e67e22;
    font-weight: 500;
    margin-top: 3px;
}

.history-notes {
    color: #777;
    font-style: italic;
    margin-top: 5px;
    font-size: 13px;
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-size: 14px;
    z-index: 10001;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.toast-show {
    opacity: 1;
    transform: translateY(0);
}

.toast-success {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
}

.toast-error {
    background: linear-gradient(135deg, #c0392b, #e74c3c);
}

.toast-info {
    background: linear-gradient(135deg, #2980b9, #3498db);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    #harvest-modal .modal-content {
        width: 95%;
        margin: 10px auto;
    }
    
    #harvest-modal .modal-body {
        padding: 20px;
        max-height: 80vh;
    }
    
    #harvest-modal .form-row {
        grid-template-columns: 1fr;
    }
    
    #harvest-modal .form-actions {
        flex-direction: column;
    }
    
    #harvest-modal .btn {
        width: 100%;
    }
    
    .toast {
        left: 20px;
        right: 20px;
        max-width: none;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    #harvest-modal .modal-content {
        background-color: #1a1a1a;
        color: #e0e0e0;
    }
    
    #harvest-modal .form-control {
        background-color: #2a2a2a;
        border-color: #444;
        color: #e0e0e0;
    }
    
    #harvest-modal .form-control:focus {
        border-color: #f39c12;
        background-color: #333;
    }
    
    #harvest-modal .form-section {
        border-bottom-color: #444;
    }
    
    #harvest-modal .modal-history {
        background: #222;
    }
    
    .history-item {
        background: #2a2a2a;
    }
    
    .score-sliders {
        background: #2a2a2a;
    }
    
    #harvest-modal label {
        color: #ccc;
    }
    
    #harvest-modal .form-section h3 {
        color: #e0e0e0;
    }
}
