body {
  font-family: 'Segoe UI', sans-serif;
  background: #fdfdfd;
  margin: 0;
  padding: 0;
  color: #333;
}
.container {
  max-width: 900px;
  margin: auto;
  padding: 30px;
  text-align: center;
}
form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: 20px;
}
input[type="text"], textarea, input[type="file"] {
  padding: 10px;
  font-size: 1em;
  border: 1px solid #FFCE1B;
  border-radius: 8px;
}
button {
  background: #FFCE1B;
  color: white;
  border: none;
  padding: 12px;
  font-size: 1em;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.3s ease;
}
button:hover {
  background: #e14040;
}
.view-memories, .back-link {
  margin-top: 20px;
  display: inline-block;
  color: #555;
  text-decoration: none;
}
.gallery {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  margin-top: 40px;
}
.memory-card {
  background: #fff;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.memory-card img, .memory-card video {
  max-width: 100%;
  border-radius: 8px;
}
.caption {
  margin-top: 10px;
  font-size: 0.95em;
}


/* Shared styles already exist, we extend for the gallery page below */

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 2rem;
}

.memory-card {
  background: #fff;
  border: 2px solid var(--primary);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0,0,0,0.07);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
}

.memory-card:hover {
  transform: translateY(-5px);
}

.memory-card img,
.memory-card video {
  width: 100%;
  height: auto;
  display: block;
}

.caption {
  padding: 1rem;
  font-size: 0.95rem;
  color: #444;
  background: var(--bg);
  border-top: 1px solid #eee;
}

.back-link {
  display: inline-block;
  margin-bottom: 1.5rem;
  text-decoration: none;
  color: #FFCE1B;
  font-weight: bold;
  transition: color 0.3s ease;
}

.back-link:hover {
  color: #d4443c;
}
