/* Travelling Irrigation Calculator Enhanced v0.0.6 - Styles - Green Theme */

.travelling-irrigation-calculator {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    max-width: 1200px;
    margin: 0 auto;
    background: #fff;
}

.travelling-irrigation-calculator .ti-header {
    background: linear-gradient(135deg, #2c5530, #4a7c59);
    color: white;
    padding: 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    text-align: center;
}

.travelling-irrigation-calculator .ti-header h2 {
    font-size: 2.2em;
    margin: 0 0 10px 0;
    color: white;
}

.travelling-irrigation-calculator .ti-calculator-section {
    background: white;
    border-radius: 10px;
    padding: 0;
    margin-bottom: 25px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border: 1px solid #e0e0e0;
}

.travelling-irrigation-calculator .ti-tabs {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #ddd;
    overflow-x: auto;
    flex-wrap: wrap;
}

.travelling-irrigation-calculator .ti-tab {
    flex: 1;
    min-width: 120px;
    padding: 15px 12px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    color: #666;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.travelling-irrigation-calculator .ti-tab:hover {
    background: #e9ecef;
    color: #2c5530;
}

.travelling-irrigation-calculator .ti-tab.active {
    background: white;
    color: #4a7c59;
    border-bottom-color: #4a7c59;
}

.travelling-irrigation-calculator .ti-tab-content {
    display: none;
    padding: 25px;
    background: white;
}

.travelling-irrigation-calculator .ti-tab-content.active {
    display: block;
}

.travelling-irrigation-calculator .ti-section-title {
    color: #2c5530;
    font-size: 1.4em;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e0e0e0;
}

.travelling-irrigation-calculator .ti-input-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.travelling-irrigation-calculator .ti-input-field {
    display: flex;
    flex-direction: column;
}

.travelling-irrigation-calculator .ti-input-field label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #444;
}

.travelling-irrigation-calculator .ti-input-field input, 
.travelling-irrigation-calculator .ti-input-field select {
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
    width: 100%;
    box-sizing: border-box;
    background: white;
}

.travelling-irrigation-calculator .ti-input-field input:focus, 
.travelling-irrigation-calculator .ti-input-field select:focus {
    outline: none;
    border-color: #4a7c59;
    box-shadow: 0 0 0 2px rgba(74, 124, 89, 0.2);
}

.travelling-irrigation-calculator .ti-help-text {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
    font-style: italic;
}

.travelling-irrigation-calculator .ti-calculate-btn, 
.travelling-irrigation-calculator .ti-action-btn {
    background: linear-gradient(135deg, #4a7c59, #2c5530);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 14px;
    border-radius: 6px;
    cursor: pointer;
    transition: transform 0.2s;
    margin: 5px;
    font-weight: 600;
}

.travelling-irrigation-calculator .ti-calculate-btn:hover, 
.travelling-irrigation-calculator .ti-action-btn:hover {
    transform: translateY(-2px);
}

.travelling-irrigation-calculator .ti-calculate-btn:disabled, 
.travelling-irrigation-calculator .ti-action-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.travelling-irrigation-calculator .ti-tab-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.travelling-irrigation-calculator .ti-nav-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
}

.travelling-irrigation-calculator .ti-prev-btn {
    background: #6c757d;
    color: white;
}

.travelling-irrigation-calculator .ti-next-btn {
    background: #28a745;
    color: white;
}

.travelling-irrigation-calculator .ti-results {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    border: 1px solid #e0e0e0;
}

.travelling-irrigation-calculator .ti-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #e0e0e0;
}

.travelling-irrigation-calculator .ti-result-label {
    font-weight: 600;
    color: #444;
}

.travelling-irrigation-calculator .ti-result-value {
    font-size: 1.1em;
    font-weight: bold;
    color: #2c5530;
}

.travelling-irrigation-calculator .ti-interpretation {
    background: #e8f5e8;
    border-left: 4px solid #4a7c59;
    padding: 15px;
    margin-top: 15px;
    border-radius: 0 6px 6px 0;
}

.travelling-irrigation-calculator .ti-excellent { color: #28a745; }
.travelling-irrigation-calculator .ti-very-good { color: #6f42c1; }
.travelling-irrigation-calculator .ti-good { color: #007bff; }
.travelling-irrigation-calculator .ti-fair { color: #fd7e14; }
.travelling-irrigation-calculator .ti-poor { color: #dc3545; }
.travelling-irrigation-calculator .ti-unacceptable { color: #6c757d; }

.travelling-irrigation-calculator .ti-collector-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.travelling-irrigation-calculator .ti-transect-section {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.travelling-irrigation-calculator .ti-transect-header {
    font-weight: bold;
    color: #2c5530;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.travelling-irrigation-calculator .ti-collector-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 12px;
}

.travelling-irrigation-calculator .ti-collector-item h5 {
    margin: 0 0 10px 0;
    color: #2c5530;
    font-size: 0.9em;
    font-weight: 600;
}

.travelling-irrigation-calculator .ti-collector-item label {
    font-weight: 600;
    margin-bottom: 4px;
    color: #444;
    font-size: 0.85em;
    display: block;
}

.travelling-irrigation-calculator .ti-collector-item input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 8px;
    font-size: 14px;
    box-sizing: border-box;
}

.travelling-irrigation-calculator .ti-action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin: 20px 0;
}

.travelling-irrigation-calculator .ti-file-upload {
    margin-bottom: 20px;
    padding: 20px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    text-align: center;
}

.travelling-irrigation-calculator .ti-file-upload input[type="file"] {
    margin: 10px 0;
}

.travelling-irrigation-calculator .ti-custom-collectors {
    display: none;
}

.travelling-irrigation-calculator .ti-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.travelling-irrigation-calculator .ti-stats-item {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    text-align: center;
}

.travelling-irrigation-calculator .ti-stats-value {
    font-size: 1.5em;
    font-weight: bold;
    color: #2c5530;
}

.travelling-irrigation-calculator .ti-stats-label {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
}

.travelling-irrigation-calculator .ti-chart-container {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
}

.travelling-irrigation-calculator .ti-chart-dual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}

.travelling-irrigation-calculator .ti-chart-single {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
}

.travelling-irrigation-calculator .ti-transect-results-section {
    background: #f1f8ff;
    border: 1px solid #b3d9ff;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.travelling-irrigation-calculator .ti-transect-results-header {
    font-weight: bold;
    color: #2c5530;
    margin-bottom: 10px;
    font-size: 1.1em;
}

.travelling-irrigation-calculator .ti-transect-result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
}

.travelling-irrigation-calculator .ti-transect-result-item {
    text-align: center;
    padding: 8px;
    background: white;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.travelling-irrigation-calculator .ti-transect-result-value {
    font-size: 1.2em;
    font-weight: bold;
    color: #2c5530;
}

.travelling-irrigation-calculator .ti-transect-result-label {
    font-size: 0.85em;
    color: #666;
    margin-top: 2px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .travelling-irrigation-calculator .ti-input-group {
        grid-template-columns: 1fr;
    }
    .travelling-irrigation-calculator .ti-tabs {
        flex-direction: column;
    }
    .travelling-irrigation-calculator .ti-collector-grid {
        grid-template-columns: 1fr;
    }
    .travelling-irrigation-calculator .ti-stats-grid {
        grid-template-columns: 1fr;
    }
    .travelling-irrigation-calculator .ti-chart-dual {
        grid-template-columns: 1fr;
    }
    .travelling-irrigation-calculator .ti-transect-result-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Loading and disabled states */
.travelling-irrigation-calculator .ti-loading {
    opacity: 0.6;
    pointer-events: none;
}

.travelling-irrigation-calculator .ti-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #4a7c59;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error states */
.travelling-irrigation-calculator .ti-error {
    background-color: #ffeaea;
    border: 1px solid #ffcdd2;
    color: #d32f2f;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
}

/* Success states */
.travelling-irrigation-calculator .ti-success {
    background-color: #e8f5e8;
    border: 1px solid #c8e6c9;
    color: #2e7d32;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
}
/* Additional CSS for multiple transect speed tests */
/* Add this to your travelling-irrigation-calculator.css file */

.ti-speed-test-note {
    background: #e3f2fd;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #1e3a8a;
}

.ti-speed-test-note p {
    margin: 0 0 10px 0;
    color: #1565c0;
}

.ti-speed-test-note p:last-child {
    margin-bottom: 0;
}

.ti-speed-test-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
}

.ti-transect-speed-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.ti-transect-speed-section {
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 8px;
    background: #f9f9f9;
    transition: box-shadow 0.2s ease;
}

.ti-transect-speed-section:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.ti-transect-speed-header {
    font-weight: bold;
    color: #1e3a8a;
    margin-bottom: 15px;
    text-align: center;
    font-size: 1.1em;
    padding-bottom: 8px;
    border-bottom: 2px solid #e3f2fd;
}

.ti-transect-speed-section .ti-input-field {
    margin-bottom: 12px;
}

.ti-transect-speed-section .ti-input-field label {
    font-size: 0.9em;
    font-weight: 600;
    color: #555;
    margin-bottom: 4px;
    display: block;
}

.ti-transect-speed-section input[type="number"],
.ti-transect-speed-section input[type="text"] {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9em;
}

.ti-transect-speed-actions {
    margin-top: 12px;
    text-align: center;
}

.ti-small-btn {
    padding: 8px 16px;
    font-size: 0.9em;
    background: #1e3a8a;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    min-width: 100px;
}

.ti-small-btn:hover {
    background: #1e40af;
}

.ti-small-btn:active {
    background: #1d4ed8;
}

/* Responsive design for smaller screens */
@media (max-width: 768px) {
    .ti-transect-speed-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .ti-transect-speed-section {
        padding: 12px;
    }
    
    .ti-transect-speed-header {
        font-size: 1em;
    }
}

/* Summary section styling */
.ti-tab-content #ti-averageSpeed {
    font-weight: bold;
    color: #1e3a8a;
}

.ti-tab-content #ti-traverseTime,
.ti-tab-content #ti-fullRotationTime {
    color: #059669;
    font-weight: 500;
}


/* ========================================= */
/* Multiple Transect Speed Test Styles v0.0.8 */
/* ========================================= */

/* Multiple transect speed test styles */
.ti-speed-test-note {
    background: #e3f2fd;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #1e3a8a;
}

.ti-speed-test-note p {
    margin: 0 0 10px 0;
    color: #1565c0;
}

.ti-speed-test-note p:last-child {
    margin-bottom: 0;
}

.ti-speed-test-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
}

.ti-transect-speed-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.ti-transect-speed-section {
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 8px;
    background: #f9f9f9;
    transition: box-shadow 0.2s ease;
}

.ti-transect-speed-section:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.ti-transect-speed-header {
    font-weight: bold;
    color: #1e3a8a;
    margin-bottom: 15px;
    text-align: center;
    font-size: 1.1em;
    padding-bottom: 8px;
    border-bottom: 2px solid #e3f2fd;
}

.ti-transect-speed-section .ti-input-field {
    margin-bottom: 12px;
}

.ti-transect-speed-section .ti-input-field label {
    font-size: 0.9em;
    font-weight: 600;
    color: #555;
    margin-bottom: 4px;
    display: block;
}

.ti-transect-speed-section input[type="number"],
.ti-transect-speed-section input[type="text"] {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9em;
}

.ti-transect-speed-actions {
    margin-top: 12px;
    text-align: center;
}

.ti-small-btn {
    padding: 8px 16px;
    font-size: 0.9em;
    background: #1e3a8a;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    min-width: 100px;
}

.ti-small-btn:hover {
    background: #1e40af;
}

.ti-small-btn:active {
    background: #1d4ed8;
}

/* Collector setup note styling */
.ti-collector-setup-note {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.ti-collector-setup-note p {
    margin: 0 0 8px 0;
    color: #856404;
}

.ti-collector-setup-note p:last-child {
    margin-bottom: 0;
}

/* Summary section styling for speed test */
.ti-tab-content #ti-averageSpeed {
    font-weight: bold;
    color: #1e3a8a;
}

.ti-tab-content #ti-traverseTime,
.ti-tab-content #ti-fullRotationTime {
    color: #059669;
    font-weight: 500;
}

/* Responsive design for smaller screens */
@media (max-width: 768px) {
    .ti-transect-speed-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .ti-transect-speed-section {
        padding: 12px;
    }
    
    .ti-transect-speed-header {
        font-size: 1em;
    }
}