* {
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top, #1e1b4b, #020617 65%),
    linear-gradient(135deg, #0f172a, #020617);
  color: #e5e7eb;
}

/* ======================
   HEADER
====================== */
.site-header {
  text-align: center;
  margin-bottom: 28px;
}

.header-link {
  text-decoration: none;
  color: inherit;
  display: inline-block;
}

.header-link h1 {
  font-size: 28px;
  letter-spacing: 0.6px;
  text-shadow: 0 0 12px rgba(124,58,237,0.6);
}

/* ======================
   CONTAINER
====================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 20px 64px;
}

/* ======================
   SEARCH
====================== */
.store-search {
  display: flex;
  align-items: center;
  gap: 12px;

  max-width: 420px;
  margin: 0 auto 40px;

  padding: 14px 18px;
  border-radius: 16px;

  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(124,58,237,0.25);
  backdrop-filter: blur(12px);

  box-shadow: 0 0 28px rgba(124,58,237,0.25);
}

.store-search i {
  color: #22d3ee;
  font-size: 14px;
}

.store-search input {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  color: #e5e7eb;
  font-size: 14px;
}

.store-search input::placeholder {
  color: rgba(229,231,235,0.55);
}

/* ======================
   GRID (ANTI STRETCH FIX)
====================== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 28px;

  align-items: start;          /* ⬅️ PENTING */
  grid-auto-rows: max-content; /* ⬅️ PENTING */
}

/* ======================
   CARD
====================== */
.card {
  display: flex;
  flex-direction: column;

  width: 100%;
  max-width: 100%;   /* ⬅️ ANTI MELEBAR */
  min-width: 0;      /* ⬅️ ANTI OVERFLOW */

  background: rgba(255,255,255,0.06);
  border-radius: 20px;
  overflow: hidden;

  border: 1px solid rgba(124,58,237,0.25);
  backdrop-filter: blur(14px);

  box-shadow:
    0 0 0 1px rgba(124,58,237,0.15),
    0 20px 60px rgba(0,0,0,0.6);

  transition:
    opacity 0.25s ease,
    transform 0.25s ease;

  will-change: transform, opacity;
}

/* hover */
.card:hover {
  transform: translateY(-6px);
}

/* ======================
   PREVIEW
====================== */
.preview {
  height: 180px;
  background: #020617;
  overflow: hidden;
}

.preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ======================
   CONTENT
====================== */
.content {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  flex: 1;
}

.content h3 {
  margin: 0;
  font-size: 17px;
}

/* ======================
   TAGS
====================== */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(124,58,237,0.18);
  border: 1px solid rgba(124,58,237,0.35);
}

/* ======================
   SEARCH STATES
====================== */
.card.hide {
  opacity: 0;
  transform: scale(0.95);
  pointer-events: none;
}

/* ======================
   BUTTON
====================== */
.download {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;

  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;

  background: linear-gradient(135deg, #7c3aed, #22d3ee);
  color: #fff;
  text-decoration: none;
  font-weight: 600;

  box-shadow: 0 0 22px rgba(124,58,237,0.55);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.download:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 36px rgba(34,211,238,0.8);
}

.download:active {
  transform: scale(0.98);
  box-shadow:
    0 0 18px rgba(124,58,237,0.75),
    0 0 36px rgba(34,211,238,0.55);
}

.download.disabled {
  background: linear-gradient(135deg, #334155, #475569);
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.75;
}

/* ======================
   FOOTER
====================== */
footer {
  margin-top: 50px;
  text-align: center;
  font-size: 12px;
  opacity: 0.45;
}

/* ======================
   RESPONSIVE
====================== */
@media (max-width: 540px) {
  .container {
    padding: 36px 16px 56px;
  }

  .preview {
    height: 160px;
  }

  .header-link h1 {
    font-size: 24px;
  }
}

.file-info {
  font-size: 11px;
  opacity: 0.55;
  margin-top: 8px;
  text-align: center;
  line-height: 1.4;
}