"use client"
import React, { useState } from 'react'

export default function DeveloperSettings() {
  const [env, setEnv] = useState('')
  const [message, setMessage] = useState('')

  async function handleSave() {
    // Example: Save env to localStorage or send to API
    localStorage.setItem('devEnv', env)
    setMessage('Settings saved!')
  }

  return (
    <div className="p-4 border rounded bg-gray-900">
      <h2 className="text-lg font-bold mb-2">Developer Settings</h2>
      <input
        className="input input-bordered w-full mb-2"
        placeholder="Custom ENV value"
        value={env}
        onChange={e => setEnv(e.target.value)}
      />
      <button className="btn btn-primary w-full" onClick={handleSave}>Save</button>
      {message && <div className="mt-2 text-green-400">{message}</div>}
    </div>
  )
}
