/* ===================================
   STYLES SPÉCIFIQUES - CALCULATEUR TVA
   =================================== */

/* Grille des taux */
.tva-rates {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

/* Option de taux */
.rate-option {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s;
}

.rate-option:hover {
    border-color: #667eea;
    background: #f0f4ff;
}

.rate-option.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
}

.rate-option.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: transparent;
    transform: scale(1.05);
}

.rate-option.active .rate-description {
    color: rgba(255,255,255,0.9);
}

.rate-option input[type="radio"] {
    margin-right: 8px;
}

.rate-option label {
    margin: 0;
    cursor: pointer;
    font-weight: 500;
}

.rate-value {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.rate-description {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Taux personnalisé */
.custom-rate {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 25px;
}

/* Montants */
.amount-input {
    position: relative;
}

.amount-input input {
    padding-right: 40px;
    font-size: 1.2rem;
    font-weight: 600;
}

.amount-input .input-group-text {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    background: transparent;
    border: none;
    padding-right: 15px;
    color: #667eea;
    font-weight: 600;
}

/* Flèches de conversion */
.conversion-arrows {
    text-align: center;
    margin: 20px 0;
    font-size: 2rem;
    color: #667eea;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Section résultats */
.results-section {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
    border-radius: 15px;
    padding: 30px;
    margin-top: 30px;
}

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

.result-item {
    background: white;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.result-label {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 5px;
}

.result-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
}

.result-value.primary {
    color: #667eea;
}

.result-value.secondary {
    color: #764ba2;
}

/* Tableau de calcul */
.calculation-table {
    margin-top: 20px;
}

.calculation-table table {
    width: 100%;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.calculation-table th {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 12px;
    font-weight: 600;
}

.calculation-table td {
    padding: 10px;
    border-bottom: 1px solid #f0f0f0;
}

.calculation-table tr:last-child td {
    border-bottom: none;
}

/* Boutons de conversion */
.btn-convert {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s;
    width: 100%;
    margin-bottom: 10px;
}

.btn-convert:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-convert i {
    margin-right: 8px;
}

/* Grille de calcul */
.calculation-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: center;
    margin: 30px 0;
}

/* Sections input */
.input-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
}

.input-section h3 {
    font-size: 1.1rem;
    color: #495057;
    margin-bottom: 15px;
}

.input-section.ht {
    border: 2px solid #667eea;
}

.input-section.ttc {
    border: 2px solid #764ba2;
}

/* Flèche de conversion */
.conversion-arrow {
    font-size: 2rem;
    color: #667eea;
    text-align: center;
}

/* Groupe d'input */
.input-group {
    margin-bottom: 10px;
}

.input-group-text {
    background: #667eea;
    color: white;
    border: 1px solid #667eea;
    font-weight: 600;
}

/* Grille de résultats */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

/* Valeurs de résultat par type */
.result-value.ht {
    color: #667eea;
}

.result-value.tva {
    color: #dc3545;
}

.result-value.ttc {
    color: #28a745;
}

/* Section info */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.info-item {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.info-item h4 {
    color: #667eea;
    font-size: 1.1rem;
    margin-bottom: 10px;
}

/* Input taux personnalisé */
.custom-rate-input {
    margin-top: 10px;
    padding: 10px;
    background: #fff;
    border-radius: 8px;
}

/* Responsive mobile */
@media (max-width: 768px) {
    .tva-rates {
        grid-template-columns: 1fr;
    }
    
    .result-grid {
        grid-template-columns: 1fr;
    }
    
    .calculation-grid {
        grid-template-columns: 1fr;
    }
    
    .conversion-arrow {
        transform: rotate(90deg);
        margin: 20px 0;
    }
    
    .amount-input input {
        font-size: 1rem;
    }
    
    .result-value {
        font-size: 1.5rem;
    }
}