/* Produktseiten-Stile - Bereinigte Version ohne Redundanzen */

/* Produktspezifische Seitenstile */
.products-page {
  padding: 1rem;
}

.products-page-title {
  text-align: center;
  margin-bottom: 30px;
  color: var(--md-sys-color-primary);
}

.search-results-message {
  text-align: center;
  margin-bottom: 20px;
  font-size: 1.1rem;
}

.search-results-message.hidden {
  display: none;
}

.search-results-message .highlight {
  font-weight: bold;
}

/* Verbessertes Produkt-Raster - ersetzt das grundlegende aus style.css */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

/* Verbesserte Produkt-Karte - ersetzt die grundlegende aus style.css */
.product-card {
  border: 1px solid var(--md-sys-color-outline);
  border-radius: 8px;
  padding: 15px;
  background-color: var(--md-sys-color-surface-variant);
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.product-card-title {
  font-size: 1.2rem;
  margin: 10px 0;
  color: var(--md-sys-color-on-surface-variant);
  min-height: 3em;
  line-height: 1.25em;
}

.product-card-price {
  font-size: 1.1rem;
  font-weight: bold;
  color: var(--md-sys-color-primary);
  margin-bottom: 10px;
}

.product-card-button {
  display: inline-block;
  padding: 10px 20px; /* Updated padding */
  background-color: var(--md-sys-color-primary);
  color: var(--md-sys-color-on-primary);
  text-decoration: none;
  border-radius: 6px; /* Updated border-radius */
  margin-top: 10px;
  font-weight: 500; /* Added font-weight for consistency */
  transition: background-color 0.2s ease-in-out, transform 0.1s ease, box-shadow 0.2s ease-in-out; /* Added transition */
}

.product-card-button:hover {
  background-color: var(--md-sys-color-primary-variant);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.product-card-button:active {
  transform: translateY(0);
}

/* Leerzustand */
.empty-state-message {
  text-align: center;
  font-size: 1.2rem;
  margin-top: 30px;
}

.centered {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

/* Produktdetailseiten-Stile */
.product-detail-page {
  display: flex;
  flex-wrap: wrap;
  gap: 100px;
  margin-top: 20px;
  padding: 1rem;
}

/* Produktbildbereich */
.product-image-section {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
}

.product-detail-image {
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid var(--md-sys-color-outline);
  background-color: var(--md-sys-color-surface-container-high);
}

/* Produktinformationsbereich */
.product-info-section {
  flex: 1.5;
  min-width: 300px;
}

.product-detail-title {
  color: var(--md-sys-color-primary);
  margin-top: 0;
  font-size: 2rem;
}

.product-detail-price {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--md-sys-color-secondary);
  margin: 10px 0;
}

.product-detail-description-title {
  margin-top: 20px;
  margin-bottom: 10px;
  font-size: 1.1rem;
  color: var(--md-sys-color-on-surface-variant);
}

.product-detail-description {
  margin-bottom: 20px;
  line-height: 1.6;
  color: var(--md-sys-color-on-surface);
}

/* Produktaktionen */
.product-actions {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-action-form {
  display: inline-block;
}

.product-action-button {
  padding: 12px 20px; /* Padding is already good */
  border: none;
  border-radius: 6px; /* Updated border-radius */
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500; /* Added font-weight for consistency */
  transition: background-color 0.2s ease-in-out, transform 0.1s ease, box-shadow 0.2s ease-in-out; /* Added transition */
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-action-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.product-action-button:active {
  transform: translateY(0);
}

.product-action-button.primary {
  background-color: var(--md-sys-color-primary);
  color: var(--md-sys-color-on-primary);
}

.product-action-button.primary:hover {
  background-color: var(--md-sys-color-primary-variant);
}

.product-action-button.secondary {
  background-color: var(--md-sys-color-secondary-container);
  color: var(--md-sys-color-on-secondary-container);
}

.product-action-button.secondary:hover {
  filter: brightness(0.95); /* Consistent with .btn-secondary-container */
}

.product-action-button .material-icons {
  font-size: inherit;
}

/* Produkt-Meta-Informationen */
.product-meta {
  margin-top: 30px;
  font-size: 0.9rem;
  color: var(--md-sys-color-on-surface-variant);
}

.product-meta p {
  margin: 5px 0;
}

.product-meta .meta-label {
  font-weight: bold;
}
