/* Reset et styles de base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

.logo {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Main content */
main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

/* Form sections */
.form-section {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.form-section:hover {
    transform: translateY(-5px);
}

.form-section h2 {
    color: #4a5568;
    margin-bottom: 20px;
    font-size: 1.5rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 10px;
}

.section-note {
    font-style: italic;
    color: #666;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

/* Input groups */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #4a5568;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.input-group small {
    display: block;
    margin-top: 5px;
    color: #718096;
    font-size: 0.85rem;
}

/* Content questions section */
.content-questions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.question-group {
    margin-bottom: 15px;
}

.question-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #4a5568;
    font-size: 0.9rem;
}

.content-selector {
    width: 100%;
    padding: 10px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.content-selector:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Results section */
.results-section {
    grid-column: 1 / -1;
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.results-section h2 {
    color: #4a5568;
    margin-bottom: 25px;
    font-size: 1.8rem;
    text-align: center;
    border-bottom: 3px solid #48bb78;
    padding-bottom: 15px;
}

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

.result-item {
    background: #f7fafc;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    border-left: 4px solid #48bb78;
}

.result-item.total {
    background: linear-gradient(135deg, #48bb78, #38a169);
    color: white;
    border-left: 4px solid #2d7d32;
}

.result-item label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: #4a5568;
}

.result-item.total label {
    color: white;
}

.result-item span {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2d3748;
}

.result-item.total span {
    color: white;
}

.result-item small {
    display: block;
    margin-top: 5px;
    font-size: 0.9rem;
    color: #718096;
}

.result-item.total small {
    color: rgba(255,255,255,0.8);
}

/* Comparator section */
.comparator-section {
    grid-column: 1 / -1;
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.comparator-section h2 {
    color: #4a5568;
    margin-bottom: 25px;
    font-size: 1.8rem;
    text-align: center;
    border-bottom: 3px solid #9f7aea;
    padding-bottom: 15px;
}

.table-container {
    overflow-x: auto;
    margin-top: 20px;
}

.comparator-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.comparator-table thead {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.comparator-table th {
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.comparator-table td {
    padding: 12px;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.9rem;
}

.comparator-table tbody tr:hover {
    background-color: #f7fafc;
}

.comparator-table .mode-name {
    font-weight: 600;
    color: #4a5568;
}

.comparator-table .best-price {
    background-color: #f0fff4 !important;
    border-left: 4px solid #48bb78;
}

.comparator-table .best-price:hover {
    background-color: #e6fffa !important;
}

.status-valid {
    background: #48bb78;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-error {
    background: #f56565;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Error messages */
.error-message {
    background: #fed7d7;
    color: #c53030;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    border-left: 4px solid #f56565;
    font-weight: 600;
}

/* Remarques */
.remarques {
    background: #ebf8ff;
    border: 1px solid #bee3f8;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
}

.remarques h4 {
    color: #2b6cb0;
    margin-bottom: 10px;
}

.remarques p {
    color: #2d3748;
    line-height: 1.5;
    white-space: pre-line;
}

/* Footer */
footer {
    text-align: center;
    color: white;
    margin-top: 40px;
    opacity: 0.8;
}

/* Responsive design */
@media (max-width: 768px) {
    main {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .container {
        padding: 15px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .form-section {
        padding: 20px;
    }
    
    .results-grid {
        grid-template-columns: 1fr;
    }
    
    .content-questions {
        grid-template-columns: 1fr;
    }
    
    .comparator-table {
        font-size: 0.8rem;
    }
    
    .comparator-table th,
    .comparator-table td {
        padding: 8px 6px;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.5rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .form-section h2 {
        font-size: 1.2rem;
    }
    
    .results-section h2,
    .comparator-section h2 {
        font-size: 1.4rem;
    }
}


/* Section Taux de Change du Jour */
.taux-change-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 40px 0;
    margin-top: 40px;
}

.taux-change-section h2 {
    text-align: center;
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.taux-change-content {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.taux-change-image {
    max-width: 100%;
    height: auto;
    max-height: 600px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.taux-change-image:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

/* Responsive pour la section taux de change */
@media (max-width: 768px) {
    .taux-change-section h2 {
        font-size: 2rem;
        margin-bottom: 20px;
    }
    
    .taux-change-content {
        padding: 10px;
    }
    
    .taux-change-image {
        max-height: 400px;
    }
}

@media (max-width: 480px) {
    .taux-change-section h2 {
        font-size: 1.5rem;
    }
    
    .taux-change-image {
        max-height: 300px;
    }
}

