/* style.css */
:root {
    --primary-color: #1a237e;
    --secondary-color: #303f9f;
    --accent-color: #536dfe;
    --danger-color: #f44336;
    --success-color: #4caf50;
    --warning-color: #ff9800;
    --light-color: #f5f5f5;
    --dark-color: #121212;
    --gray-color: #757575;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a237e 0%, #303f9f 100%);
    color: var(--light-color);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

/* En-tête */
.weather-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.location-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.2rem;
}

.location-info i {
    color: var(--accent-color);
}

.time-date {
    text-align: right;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

#current-time {
    font-size: 1.4rem;
    font-weight: bold;
    display: block;
}

/* Météo actuelle */
.current-weather {
    text-align: center;
    padding: 30px 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    margin-bottom: 30px;
}

.weather-icon {
    font-size: 5rem;
    margin-bottom: 10px;
    color: #ffd54f;
}

.temperature {
    font-size: 4rem;
    font-weight: 300;
    margin-bottom: 10px;
}

.unit {
    font-size: 2rem;
    vertical-align: super;
}

.weather-description {
    font-size: 1.5rem;
    margin-bottom: 20px;
    text-transform: capitalize;
}

.weather-details {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 20px;
}

.detail {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    padding: 10px 20px;
    border-radius: 50px;
}

.detail i {
    color: var(--accent-color);
}

/* Prévisions */
.forecast-section {
    margin-bottom: 30px;
}

.forecast-section h2 {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--accent-color);
}

.forecast-container {
    display: flex;
    overflow-x: auto;
    gap: 15px;
    padding-bottom: 10px;
}

.forecast-day {
    min-width: 120px;
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: var(--border-radius);
    text-align: center;
    flex-shrink: 0;
}

.forecast-date {
    font-weight: bold;
    margin-bottom: 10px;
}

.forecast-icon {
    font-size: 2rem;
    margin: 10px 0;
    color: #ffd54f;
}

.forecast-temp {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.temp-max {
    color: #ff7043;
}

.temp-min {
    color: #29b6f6;
}

/* Recherche */
.search-section {
    margin-bottom: 30px;
}

.search-box {
    display: flex;
    gap: 10px;
}

#city-search {
    flex: 1;
    padding: 15px;
    border: none;
    border-radius: var(--border-radius);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1rem;
}

#city-search::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-results {
    margin-top: 15px;
    display: none;
}

/* Boutons */
.btn-primary, .btn-secondary, .btn-icon {
    border: none;
    border-radius: var(--border-radius);
    padding: 12px 24px;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: var(--accent-color);
    color: white;
}

.btn-primary:hover {
    background: #3d5afe;
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-icon {
    background: transparent;
    color: white;
    padding: 10px;
    width: 40px;
    height: 40px;
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

/* Chat overlay */
.chat-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: var(--primary-color);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.chat-container {
    flex: 1;
    background: white;
    display: flex;
    flex-direction: column;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    overflow: hidden;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #f0f0f0;
    color: var(--dark-color);
}

.message {
    margin-bottom: 15px;
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 18px;
    word-wrap: break-word;
}

.message.sent {
    background: var(--accent-color);
    color: white;
    margin-left: auto;
    border-bottom-right-radius: 4px;
}

.message.received {
    background: #e0e0e0;
    color: var(--dark-color);
    border-bottom-left-radius: 4px;
}

.message-header {
    font-size: 0.8rem;
    opacity: 0.7;
    margin-bottom: 4px;
}

.chat-input-area {
    padding: 20px;
    background: white;
    border-top: 1px solid #e0e0e0;
}

.input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

#chat-input {
    flex: 1;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 1rem;
}

.chat-tools {
    display: flex;
    gap: 10px;
}

/* Biométrie */
.biometric-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.biometric-modal {
    background: white;
    color: var(--dark-color);
    padding: 40px;
    border-radius: var(--border-radius);
    text-align: center;
    max-width: 400px;
    width: 90%;
}

.biometric-icon {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.biometric-progress {
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    margin: 30px 0;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--accent-color);
    width: 0%;
    animation: progress 2s infinite linear;
}

@keyframes progress {
    0% { width: 0%; }
    100% { width: 100%; }
}

/* Notifications */
.notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--success-color);
    color: white;
    padding: 15px 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    z-index: 3000;
    display: flex;
    align-items: center;
    gap: 15px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Utilitaires */
.hidden {
    display: none !important;
}

/* Responsive */
@media (max-width: 768px) {
    .weather-details {
        flex-direction: column;
        gap: 15px;
    }
    
    .action-buttons {
        flex-wrap: wrap;
    }
    
    .forecast-container {
        flex-wrap: wrap;
    }
    
    .forecast-day {
        min-width: calc(50% - 15px);
    }
}

@media (max-width: 480px) {
    .container {
        padding: 15px;
    }
    
    .weather-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .time-date {
        align-self: flex-end;
    }
    
    .forecast-day {
        min-width: 100%;
    }
}