/* ===== GLOBAL RESET ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

html, body {
  height: 100%;
}

body {
  /* ===== BACKGROUND FULL ===== */
  background-image: url("https://tr.rbxcdn.com/180DAY-600081d81c133f2c6dc8bb52522f2845/768/432/Image/Webp/noFilter");
  background-repeat: no-repeat;
  background-position: center;
  background-attachment: fixed;
  background-size: cover; /* FULL BACKGROUND, nutup semua layar */
  background-color: #000; /* fallback kalau image gagal load */

  color: #fff;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 20px;
  position: relative;
}

/* ===== Overlay Semi Transparan ===== */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3); /* gelap semi transparan */
  z-index: 1;
  pointer-events: none;
}

/* ===== CONTAINER UTAMA ===== */
.container {
  width: 100%;
  max-width: 700px;
  position: relative;
  z-index: 2;
}

h2 {
  text-align: center;
  margin-bottom: 15px;
  font-size: 22px;
  font-weight: 600;
  color: #fff;
}

/* ===== FORM INPUT ===== */
.form-box {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

input {
  flex: 1;
  min-width: 140px;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 16px;
  background: rgba(255,255,255,0.9);
  color: #000;
}

button {
  padding: 10px 18px;
  background: #007bff;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: 0.2s;
}

button:hover {
  opacity: 0.8;
  transform: scale(0.98);
}

/* ===== FRAME PEMBUNGKUS LIST LINK ===== */
#list {
  margin-top: 10px;
  border: 2px solid rgba(0, 123, 255, 0.6);
  background: rgba(255,255,255,0.15); /* semi transparan */
  padding: 15px;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  backdrop-filter: blur(4px);
}

/* ===== ITEM LINK DI DALAM FRAME ===== */
.link-item {
  background: rgba(255,255,255,0.95);
  padding: 12px;
  border-radius: 6px;
  margin-bottom: 12px;
  border-left: 4px solid #007bff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.title {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 4px;
  color: #0056b3;
}

.url {
  font-size: 14px;
  background: #f1f1f1;
  padding: 8px;
  border-radius: 6px;
  word-break: break-all;
  color: #000;
  margin-bottom: 8px;
}

/* ===== TOMBOL ACTION ===== */
.action {
  display: flex;
  gap: 8px;
  justify-content: flex-start;
}

a {
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 5px;
  transition: 0.2s;
  color: #fff;
}

.btn-open {
  background: #28a745; /* HIJAU */
}

.btn-delete {
  background: #dc3545; /* MERAH */
}

.btn-open:hover, .btn-delete:hover {
  opacity: 0.8;
  transform: scale(0.97);
}

/* ===== EMPTY TEXT ===== */
.empty {
  text-align: center;
  margin-top: 10px;
  color: #ddd;
  font-size: 14px;
  font-weight: 500;
}

/* ===== TOAST NOTIF ===== */
.toast {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 12px 18px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  transform: translateX(20px);
  pointer-events: none;
  transition: 0.3s;
  z-index: 999;
  color: white;
  font-weight: 500;
}

.toast.show {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.toast.success {
  background: #28a745;
}

.toast.error {
  background: #dc3545;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .form-box {
    flex-direction: column;
  }
  button, input {
    width: 100%;
  }
  .action {
    flex-direction: column;
  }
  .btn-open, .btn-delete {
    width: 100%;
    text-align: center;
  }
}
