.container {
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.header h1 {
  color: #2C3087;
  font-size: 1.875rem;
  font-weight: 600;
  margin: 0;
}

.addButton {
  background-color: #DE751C;
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  font-weight: 500;
  font-size: 1rem;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.addButton:hover {
  background-color: #c66a19;
}

.galleryGrid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  padding: 1rem;
}

.galleryCard {
  background-color: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(44, 48, 135, 0.1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  border: 1px solid rgba(44, 48, 135, 0.1);
  position: relative;
}

.galleryCard:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(44, 48, 135, 0.15);
  border-color: rgba(44, 48, 135, 0.2);
}

.galleryCard::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background-color: #2C3087;
  transition: width 0.3s ease;
}

.galleryCard:hover::before {
  width: 8px;
}

.imageContainer {
  position: relative;
  width: 100%;
  padding-top: 75%; /* 4:3 Aspect Ratio */
  overflow: hidden;
}

.imageContainer img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.galleryCard:hover .imageContainer img {
  transform: scale(1.05);
}

.galleryInfo {
  padding: 1.5rem;
  position: relative;
}

.galleryInfo h3 {
  color: #2C3087;
  margin: 0 0 0.75rem 0;
  font-size: 1.25rem;
  font-weight: 600;
  position: relative;
  padding-left: 1rem;
}

.galleryInfo h3::after {
  content: '';
  position: absolute;
  bottom: -0.25rem;
  left: 1rem;
  width: 40px;
  height: 3px;
  background-color: #DE751C;
  border-radius: 2px;
  transition: width 0.3s ease;
}

.galleryCard:hover .galleryInfo h3::after {
  width: 60px;
}

.galleryActions {
  margin-top: 1rem;
  display: flex;
  gap: 0.75rem;
}

.editButton, 
.deleteButton {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 0.375rem;
  cursor: pointer;
  font-weight: 500;
  font-size: 0.875rem;
  transition: all 0.2s ease;
  flex: 1;
  text-align: center;
}

.editButton {
  background-color: #2C3087;
  color: white;
}

.editButton:hover {
  background-color: #23265f;
}

.deleteButton {
  background-color: #DE751C;
  color: white;
}

.deleteButton:hover {
  background-color: #c66a19;
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modalContent {
  background-color: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 8px 16px rgba(44, 48, 135, 0.15);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid rgba(44, 48, 135, 0.1);
}

.modalContent h2 {
  color: #2C3087;
  margin: 0 0 1.5rem 0;
  font-size: 1.5rem;
  font-weight: 600;
  position: relative;
  padding-bottom: 0.75rem;
}

.modalContent h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background-color: #DE751C;
  border-radius: 2px;
}

.formGroup {
  margin-bottom: 1.5rem;
}

.formGroup label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #2C3087;
}

.formGroup input[type="text"],
.formGroup input[type="file"] {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid rgba(44, 48, 135, 0.2);
  border-radius: 0.375rem;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.formGroup input[type="text"]:focus,
.formGroup input[type="file"]:focus {
  outline: none;
  border-color: #2C3087;
  box-shadow: 0 0 0 2px rgba(44, 48, 135, 0.1);
}

.modalActions {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
}

.submitButton,
.cancelButton {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 0.375rem;
  cursor: pointer;
  font-weight: 500;
  font-size: 1rem;
  transition: all 0.2s ease;
  min-width: 100px;
  text-align: center;
}

.submitButton {
  background-color: #2C3087;
  color: white;
}

.submitButton:hover {
  background-color: #23265f;
}

.submitButton:disabled {
  background-color: #93c5fd;
  cursor: not-allowed;
}

.cancelButton {
  background-color: #f3f4f6;
  color: #374151;
  border: 1px solid #d1d5db;
}

.cancelButton:hover {
  background-color: #e5e7eb;
}

.errorMessage {
  color: #ef4444;
  font-size: 0.875rem;
  margin-top: 0.5rem;
  padding: 0.75rem;
  background-color: #fee2e2;
  border-radius: 0.375rem;
  border: 1px solid #fecaca;
}

.successMessage {
  color: #059669;
  font-size: 0.875rem;
  margin-top: 0.5rem;
  padding: 0.75rem;
  background-color: #d1fae5;
  border-radius: 0.375rem;
  border: 1px solid #a7f3d0;
}

.loadingContainer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-height: 200px;
}

.loadingContainer span {
  color: #2C3087;
  font-size: 0.95rem;
  font-weight: 500;
}

.loadingSpinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(44, 48, 135, 0.1);
  border-top: 3px solid #2C3087;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.fileInfo {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: #666;
}

.uploadProgress {
  margin-top: 1rem;
  background: #f3f4f6;
  border-radius: 0.375rem;
  overflow: hidden;
  position: relative;
  height: 1.5rem;
}

.progressBar {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: #2C3087;
  transition: width 0.3s ease;
}

.uploadProgress span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  z-index: 1;
}

.noData {
  text-align: center;
  padding: 3rem;
  color: #64748b;
  font-size: 1.125rem;
  background-color: #f9fafb;
  border-radius: 0.75rem;
  border: 2px dashed #e5e7eb;
  grid-column: 1 / -1;
  margin: 1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .header h1 {
    font-size: 1.5rem;
  }

  .addButton {
    width: 100%;
    justify-content: center;
  }

  .galleryGrid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 0.5rem;
  }

  .galleryCard {
    padding: 0;
  }

  .galleryInfo {
    padding: 1.25rem;
  }

  .galleryInfo h3 {
    font-size: 1.125rem;
    padding-left: 0.75rem;
  }

  .galleryInfo h3::after {
    left: 0.75rem;
    width: 30px;
  }

  .galleryCard:hover .galleryInfo h3::after {
    width: 45px;
  }

  .galleryCard::before {
    width: 3px;
  }

  .galleryCard:hover::before {
    width: 6px;
  }

  .galleryActions {
    flex-direction: column;
    gap: 0.5rem;
  }

  .editButton,
  .deleteButton {
    width: 100%;
    padding: 0.5rem;
  }

  .modalContent {
    padding: 1.5rem;
    margin: 1rem;
  }

  .modalContent h2 {
    font-size: 1.25rem;
  }

  .modalActions {
    flex-direction: column-reverse;
    gap: 0.75rem;
  }

  .modalActions button {
    width: 100%;
  }

  .formGroup input[type="text"],
  .formGroup input[type="file"] {
    padding: 0.625rem;
  }

  .fileInfo {
    font-size: 0.75rem;
  }

  .uploadProgress {
    height: 1.25rem;
  }

  .uploadProgress span {
    font-size: 0.7rem;
  }

  .noData {
    padding: 2rem 1rem;
    font-size: 1rem;
    margin: 0.5rem;
  }
}

@media (max-width: 480px) {
  .galleryInfo {
    padding: 1rem;
  }

  .galleryInfo h3 {
    font-size: 1rem;
  }

  .modalContent {
    padding: 1.25rem;
  }

  .submitButton,
  .cancelButton {
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
  }
} 