-- Ajout de la table app_config pour la configuration globale
CREATE TABLE IF NOT EXISTS app_config (
  config_key VARCHAR(40) PRIMARY KEY,
  config_value TEXT NOT NULL,
  updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- Insertion de la musique par défaut
INSERT INTO app_config (config_key, config_value) VALUES ('ambient_music', 'accueil')
ON DUPLICATE KEY UPDATE config_key = config_key;

-- Vérification
SELECT * FROM app_config WHERE config_key = 'ambient_music';
