/* ...existing code... */

/* Base layout */
:root {
  --bg: #000;
  --card-border: rgba(255,255,255,0.06);
  --card-radius: 10px;
  --text: #fff;
}

html,body {
  height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}

.hero {
  text-align: center;
  margin-bottom: 20px;
}
.logo { height: 36px; display: inline-block; margin-bottom: 12px; opacity: .95; }
.site-title { font-size: 20px; margin: 6px 0 4px; }
.tagline { margin: 0 0 12px; color: rgba(255,255,255,0.7); font-size: 14px; }

/* Grid */
.grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 16px;
  align-items: start;
  margin-bottom: 28px;
}

/* Responsive breakpoints */
@media (min-width: 480px) {
  .grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
}
@media (min-width: 768px) {
  .grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}
@media (min-width: 1024px) {
  .grid { grid-template-columns: repeat(4, 1fr); gap: 22px; }
}

/* Card */
.card {
  display: block;
  background: transparent;
  border-radius: var(--card-radius);
  border: 1px solid var(--card-border);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
  will-change: transform;
  outline: none;
  box-shadow: 0 4px 14px rgba(0,0,0,0.4);
}

/* Focus and hover */
.card:focus,
.card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 8px 28px rgba(0,0,0,0.6);
  opacity: 1;
}
.card:focus { box-shadow: 0 8px 28px rgba(255,255,255,0.04); }
.card:focus-visible {
  outline: 3px solid rgba(255,255,255,0.06);
  outline-offset: 3px;
}

/* Image wrapper: enforce square aspect ratio */
.card-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  display: block;
  position: relative;
  overflow: hidden;
}

/* image styles */
.cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Title */
.card-title {
  padding: 10px 12px;
  font-weight: 500;
  font-size: 14px;
  color: var(--text);
  line-height: 1.2;
  min-height: 3.0em; /* reserve approx 2 lines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Empty state */
.empty-state {
  text-align: center;
  color: rgba(255,255,255,0.7);
  margin: 30px 0;
}

/* Footer */
.footer { text-align: center; color: rgba(255,255,255,0.6); font-size: 13px; margin-top: 14px; }

/* End of file */