/* PowerToolSpeedTorqueConverter.css
 * Calculator-specific styles for Power Tool Speed/Torque Converter
 *
 * ⚠️ IMPORTANT: DO NOT redefine global classes!
 * - Global classes (.glass-card, .form-input, .btn-custom, etc.) are defined in layout.css
 * - See GLOBAL_CSS_CLASSES.md for complete list
 * - Only add calculator-specific styles here
 */

/* ============================================
   Torque Gauge Visualization
   ============================================ */
.torque-gauge {
    position: relative;
    width: 100%;
    height: 80px;
    background: linear-gradient(90deg, #48bb78 0%, #f59e0b 50%, #ef4444 100%);
    border-radius: 12px;
    overflow: hidden;
    margin: 20px 0;
}

.torque-gauge-indicator {
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: #1a202c;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    transition: left 0.3s ease;
}

.torque-gauge-label {
    position: absolute;
    bottom: 5px;
    font-size: 0.75rem;
    color: white;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.torque-gauge-label.light { left: 10px; }
.torque-gauge-label.medium { left: 35%; }
.torque-gauge-label.heavy { left: 65%; }
.torque-gauge-label.industrial { right: 10px; }

/* ============================================
   Tool Preset Cards
   ============================================ */
.tool-preset-card {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 15px;
    margin: 10px 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tool-preset-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    transform: translateY(-2px);
}

.tool-preset-card.active {
    border-color: #667eea;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

.tool-preset-icon {
    font-size: 2rem;
    color: #667eea;
    margin-bottom: 10px;
}

.tool-preset-name {
    font-weight: 700;
    font-size: 1.1rem;
    color: #4a5568;
    margin-bottom: 5px;
}

.tool-preset-description {
    font-size: 0.85rem;
    color: #718096;
    font-style: italic;
}

/* ============================================
   Scenario Recommendation Badges
   ============================================ */
.scenario-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin: 5px;
    transition: transform 0.2s ease;
}

.scenario-badge:hover {
    transform: scale(1.05);
}

.scenario-badge.light {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    color: white;
}

.scenario-badge.medium {
    background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%);
    color: white;
}

.scenario-badge.heavy {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.scenario-badge.industrial {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

/* ============================================
   RPM-Torque Comparison Chart
   ============================================ */
.rpm-torque-comparison {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(102, 126, 234, 0.05);
    border-radius: 12px;
    margin: 15px 0;
}

.comparison-item {
    flex: 1;
    text-align: center;
}

.comparison-label {
    font-size: 0.85rem;
    color: #718096;
    margin-bottom: 5px;
}

.comparison-value {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'Roboto Mono', monospace;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ============================================
   Warning Alerts
   ============================================ */
.warning-alert {
    background: rgba(245, 158, 11, 0.1);
    border-left: 4px solid #f59e0b;
    border-radius: 8px;
    padding: 12px 15px;
    margin: 15px 0;
    font-size: 0.9rem;
    color: #92400e;
}

.warning-alert i {
    color: #f59e0b;
    margin-right: 8px;
}

.error-alert {
    background: rgba(239, 68, 68, 0.1);
    border-left: 4px solid #ef4444;
    border-radius: 8px;
    padding: 12px 15px;
    margin: 15px 0;
    font-size: 0.9rem;
    color: #991b1b;
}

.error-alert i {
    color: #ef4444;
    margin-right: 8px;
}

.info-alert {
    background: rgba(66, 153, 225, 0.1);
    border-left: 4px solid #4299e1;
    border-radius: 8px;
    padding: 12px 15px;
    margin: 15px 0;
    font-size: 0.9rem;
    color: #1e40af;
}

.info-alert i {
    color: #4299e1;
    margin-right: 8px;
}

/* ============================================
   Result Display Enhancements
   ============================================ */
.result-item .result-value {
    font-size: 1.8rem;
    font-weight: 700;
    font-family: 'Roboto Mono', monospace;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.result-item .sub-value {
    font-size: 0.9rem;
    color: #a0aec0;
    margin-top: 5px;
    font-weight: 400;
}

/* Calculated value highlight (red) */
.result-item .calculated-highlight {
    color: #ef4444 !important;
    background: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: #ef4444 !important;
}

.result-item .sub-value.calculated-highlight {
    color: #ef4444 !important;
}

/* ============================================
   Calculation Mode Selection (Radio Buttons)
   ============================================ */
.calc-mode-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.calc-mode-option {
    position: relative;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px 15px 15px 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.calc-mode-option:hover {
    border-color: #667eea;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
}

.calc-mode-option:has(input:checked) {
    border-color: #667eea;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
}

.calc-mode-option .form-check-input {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.calc-mode-option .form-check-input:checked {
    background-color: #667eea;
    border-color: #667eea;
}

.calc-mode-option .form-check-label {
    display: flex;
    flex-direction: column;
    cursor: pointer;
    margin-left: 0;
}

.calc-mode-option .mode-title {
    font-weight: 600;
    font-size: 1rem;
    color: #2d3748;
    margin-bottom: 4px;
}

.calc-mode-option .mode-desc {
    font-size: 0.85rem;
    color: #718096;
}

.calc-mode-option i {
    font-size: 1.1rem;
    margin-right: 8px;
}

/* Input Group for torque unit selector */
.input-group {
    display: flex;
    flex-direction: row;
    gap: 10px;
    align-items: center;
}

.input-group .form-input:first-child {
    flex: 1;
    min-width: 0;
}

.input-group select.form-input {
    flex: 0 0 auto;
    width: auto;
    max-width: 140px;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 767px) {
    .torque-gauge {
        height: 60px;
    }

    .tool-preset-card {
        padding: 12px;
    }

    .tool-preset-icon {
        font-size: 1.5rem;
    }

    .comparison-value {
        font-size: 1.2rem;
    }

    .scenario-badge {
        font-size: 0.8rem;
        padding: 6px 12px;
    }

    .calc-mode-option {
        padding: 12px 12px 12px 45px;
    }

    .calc-mode-option .mode-title {
        font-size: 0.9rem;
    }

    .calc-mode-option .mode-desc {
        font-size: 0.8rem;
    }

    .calc-mode-option i {
        font-size: 1rem;
    }
}
