/* ================= GENERAL BODY ================= */
body {
  margin: 0;
  font-family: 'Segoe UI', sans-serif;
  background: #0d1117;
  color: #e2e8f0;
  min-height: 100vh;
}

/* ================= HEADER ================= */
header {
  text-align: center;
  padding: 40px 20px;
  background: #111827;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

header h1 {
  font-size: 2.5em;
  margin: 0;
  font-weight: bold;
  color: #22c55e;
}

#search {
  padding: 12px 20px;
  width: 80%;
  max-width: 450px;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 30px;
  font-size: 16px;
  outline: none;
  margin-top: 20px;
  background: #1e293b;
  color: #e2e8f0;
  transition: all 0.3s;
}

#search:focus {
  border-color: #22c55e;
  box-shadow: 0 0 12px rgba(34,197,94,0.3);
}

/* ================= MAIN CONTAINER ================= */
#codes-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
  padding: 40px;
  max-width: 1200px;
  margin: auto;
}

/* ================= CODE CARDS ================= */
.code-card {
  border-radius: 16px;
  padding: 25px;
  position: relative;
  cursor: pointer;
  background: #161b22;
  border: 1px solid rgba(255,255,255,0.05);
  transition: all 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
  opacity: 0;
  transform: translateY(20px);
}

.code-card.show {
  opacity: 1;
  transform: translateY(0);
}

.code-title {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 10px;
  color: #e2e8f0;
}

.code-desc {
  font-size: 14px;
  opacity: 0.8;
  margin-bottom: 15px;
}

.share-btn {
  background: #22c55e;
  color: white;
  padding: 6px 14px;
  border-radius: 12px;
  font-size: 12px;
  position: absolute;
  bottom: 15px;
  right: 15px;
  cursor: pointer;
  border: none;
  transition: background 0.3s;
}

.share-btn:hover {
  background: #16a34a;
}

/* ================= DYNAMIC HOVER GLOW (UPDATED) ================= */
.code-card:hover {
  /* remove hardcoded green, JS sets box-shadow dynamically */
  box-shadow: 0 0 0 transparent;
}

/* ================= SUB-PAGE ================= */
#code-details {
  max-width: 800px;
  margin: 50px auto;
  padding: 40px;
  background: #161b22;
  border-radius: 20px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.5);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.5s ease;
}

#code-details.show {
  opacity: 1;
  transform: translateY(0);
}

#code-details h1 {
  font-size: 2.2em;
  color: #22c55e;
  margin-bottom: 15px;
}

#code-details p {
  font-size: 16px;
  line-height: 1.5;
  opacity: 0.85;
  margin-bottom: 25px;
}

pre {
  background: #0d1117;
  color: #00ff9d;
  padding: 20px;
  border-radius: 16px;
  overflow-x: auto;
  font-family: Consolas, Monaco, monospace;
  font-size: 15px;
  margin-bottom: 20px;
  transition: all 0.3s;
}

pre:hover {
  box-shadow: 0 0 0 transparent; /* JS handles glow dynamically now */
}

button {
  background: #22c55e;
  color: #fff;
  border: none;
  padding: 10px 20px;
  font-size: 14px;
  border-radius: 12px;
  cursor: pointer;
  margin-right: 10px;
  transition: 0.3s;
}

button:hover {
  background: #16a34a;
}

/* ================= MODERN CLEAN NOTIFICATIONS ================= */
#notification-container {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

.notification {
  background-color: #2b2b2b;      /* solid dark background */
  color: #f0f0f0;                 /* light text */
  padding: 12px 22px;
  border-radius: 12px;            /* smooth rounded edges */
  font-size: 14px;
  font-weight: 500;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  pointer-events: none;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);  /* subtle shadow only */
}

.notification.show {
  opacity: 1;
  transform: translateY(0);
}

#disclaimer {
  background-color: #111827;
  color: #9ca3af;
  text-align: center;
  padding: 12px;
  font-size: 14px;
  border-top: 1px solid rgba(255,255,255,0.05);
}
#disclaimer p {
  margin: 0;
}

