import React from "react";
import { View, Text, Button, StyleSheet, TouchableOpacity } from "react-native";
import { MaterialCommunityIcons } from "@expo/vector-icons"; // Menggunakan ikon ceklis

const PengaduanBerhasil = ({ navigation }) => {
  return (
    <View style={styles.container}>
      <View style={styles.content}>
        <MaterialCommunityIcons name="cloud-check" size={140} color="white" />
        <Text style={styles.title}>PENGADUAN BERHASIL !</Text>
        <Text style={styles.message}>
          Mohon pastikan informasi yang diberikan sudah sesuai, agar kami dapat
          segera menindaklanjuti.
        </Text>
        <Text style={styles.subMessage}>
          Laporan anda telah diterima dan sedang menunggu verifikasi
        </Text>
        <TouchableOpacity
          style={styles.button}
          // onPress={() => console.log("Daftar Submit")}
          onPress={() => navigation.navigate("BerandaPengaduan")}
        >
          <Text style={styles.buttonText}>LIHAT PENGADUAN</Text>
        </TouchableOpacity>
      </View>
    </View>
  );
};

const styles = StyleSheet.create({
  container: {
    flex: 1,
    justifyContent: "center",
    alignItems: "center",
    backgroundColor: "#435739", // Warna hijau gelap
  },
  content: {
    justifyContent: "center",
    alignItems: "center",
    backgroundColor: "#435739", // Transparansi gelap untuk efek overlay
    padding: 30,
    borderRadius: 15,
    width: "80%",
    alignItems: "center",
  },
  title: {
    fontSize: 24,
    fontWeight: "bold",
    color: "#ffea00",
    marginTop: 0,
  },
  message: {
    fontSize: 16,
    color: "#fff",
    textAlign: "center",
    marginTop: 10,
  },
  subMessage: {
    fontSize: 14,
    color: "#ffea00",
    textAlign: "center",
    marginTop: 10,
    padding: 3,
  },
  button: {
    backgroundColor: "#fff",
    paddingVertical: 10,
    paddingHorizontal: 50,
    borderRadius: 5,
    marginTop: 20,
    borderRadius: 25,
    fontWeight: "bold",
  },
  buttonText: {
    fontWeight: "bold",
    fontSize: 15,
  },
});

export default PengaduanBerhasil;
