.gallery-description {
    text-align: center;
    font-size: 1.1em;
    color: var(--color-text-dark-grey);
    margin-bottom: 50px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    justify-content: center;
}

.gallery-card {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-main);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.gallery-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.gallery-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.gallery-card:hover img {
    transform: scale(1.05);
}
.card-content {
  padding: 15px;
  background-color: var(--color-white);
  text-align: center;
  border-top: 1px solid var(--color-border-light);
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}

.card-content h3 {
  margin: 0 0 5px 0;
  font-size: 1.3em;
  color: var(--color-text-darker-grey);
}

.card-content p {
  margin: 0;
  font-size: 0.9em;
  opacity: 0.9;
  color: var(--color-text-dark-grey);
}

.password-form-wrapper {
    display: flex;
    justify-content: center;
    padding: 30px;
    background-color: var(--color-pale-grey);
    border-radius: 10px;
    max-width: 500px;
    margin: 30px auto;
    box-shadow: var(--shadow-main);
}

.gallery-password-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.gallery-password-form .form-group label {
    font-size: 1.1em;
    font-weight: bold;
    color: var(--color-text-darker-grey);
}

.gallery-password-form input[type="text"] {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--color-border-light);
    border-radius: 8px;
    font-size: 1em;
    color: var(--color-text-darker-grey);
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.gallery-password-form input[type="text"]:focus {
    border-color: var(--color-primary-button);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
    outline: none;
}

.gallery-password-form{
    background-color: var(--color-primary-button);
    color: var(--color-white);
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background-color 0.3s ease;
    align-self: center;
}

.gallery-password-form{
    background-color: var(--color-primary-button-hover);
}

  #passwordModal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0; top: 0; width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.6);
    justify-content: center;
    align-items: center;
  }
  #passwordModalContent {
    background: var(--color-pale-grey);
    padding: 20px 30px;
    border-radius: 8px;
    max-width: 300px;
    width: 100%;
    text-align: center;
    box-shadow: 0 0 10px rgba(0,0,0,0.3);
  }
  #passwordModalContent input[type="password"] {
    width: 100%;
    padding: 8px 10px;
    margin: 10px 0 15px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
  }
  #passwordModalContent button {
    padding: 8px 15px;
    font-size: 16px;
    border: none;
    border-radius: 4px;
    background-color: #007bff;
    color: white;
    cursor: pointer;
  }
  #passwordModalContent button:hover {
    background-color: #0056b3;
  }