* { box-sizing: border-box; margin: 0; padding: 0; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

body {
  background: #0e0e0c;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.x {
  background: rgb(150, 29, 29);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
  max-width: 1100px;
  max-height: 1100px;
  width: 100%;
  margin: 0 auto;
  padding: 3rem 2rem;
}

/* gallery grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem 1.5rem;
}

/* cards */
.card {
  border: 1px solid #2a2a25;
  transition: border-color 0.2s, transform 0.2s;
}

.card:hover {
  border-color: #e77500;
  transform: translateY(-5px);
}

.card a { display: block; }

.card-img {
  background: #1e1e1a;
  overflow: hidden;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.9;
  transition: opacity 0.3s, transform 0.4s;
}

/* index */
.init_img {
  border: 1px solid #2a2a25;
  transition: border-color 0.2s;
}

.init_img:hover {
  border-color: #e77500;
}


.init_img-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.9;
  transition: opacity 0.3s, transform 0.4s;
}