/* General Page Setup */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: #f7f7f7;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  animation: fadeIn 0.5s ease-in;
}

main {
  flex: 1;
  padding-bottom: 160px; /* space for footer and cookie bar */
}

/* Page Animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page-animate {
  animation: slideFadeIn 0.6s ease-out forwards;
}

/* Navbar */
.navbar {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease-in-out;
}

/* Product Cards */
.product-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 10px;
  background: white;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.05);
  height: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.product-img-container {
  width: 100%;
  height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-color: #fff;
  border-radius: 10px;
}

.product-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.product-card:hover .product-img {
  transform: scale(1.05);
}

/* Badges */
.badge-new {
  background-color: #28a745;
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 500;
}

.badge-used {
  background-color: #ffc107;
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 500;
}

/* Footer */
.footer {
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  background: #222;
  color: #fff;
  padding: 20px 0;
  text-align: center;
  box-shadow: 0px -1px 3px rgba(0, 0, 0, 0.1);
  z-index: 998;
}

.footer a {
  color: #ddd;
  margin: 0 10px;
  transition: color 0.2s ease;
}

.footer a:hover {
  color: #fff;
}

.social-media-bar {
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 10px 0;
}

/* Footer Toggle Button */
#toggle-footer {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 1060;
  white-space: nowrap;
}

@media (max-width: 576px) {
  #toggle-footer {
    bottom: 10px;
    left: 10px;
    font-size: 12px;
    padding: 4px 8px;
  }
}

/* Buttons */
.btn-outline-primary,
.btn-outline-success,
.btn-outline-warning {
  transition: all 0.3s ease;
}

.btn-outline-primary:hover,
.btn-outline-success:hover,
.btn-outline-warning:hover {
  transform: scale(1.05);
}

/* Imprint Link */
.imprint-link {
  text-decoration: none;
  font-weight: bold;
  color: #ccc;
}

.imprint-link:hover {
  color: #fff;
}

/* Cookie Consent */
.cookie-consent {
  position: fixed;
  bottom: 80px;
  left: 0;
  width: 100%;
  background: #333;
  color: #fff;
  padding: 15px 20px;
  text-align: center;
  z-index: 999;
  display: none;
}

.cookie-consent.show {
  display: block;
}

.cookie-consent a {
  color: yellow;
  text-decoration: underline;
}

#accept-cookies {
  background-color: #28a745;
  color: #fff;
  border: none;
  padding: 8px 20px;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

/* Offcanvas Cart */
.offcanvas-body ul {
  padding: 0;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid #eee;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 10px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  animation: fadeSlideUp 0.3s ease-out;
}

.cart-item span {
  font-weight: 500;
}

.cart-item .btn-danger {
  font-size: 14px;
  padding: 2px 8px;
  border-radius: 5px;
}

@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.offcanvas {
  width: 360px !important;
}

.offcanvas-header {
  border-bottom: 1px solid #ddd;
}

.offcanvas-title {
  font-weight: bold;
}

.offcanvas-body .btn-success {
  font-size: 16px;
  padding: 12px;
  font-weight: 600;
  border-radius: 10px;
}

.btn.btn-primary[data-bs-toggle="offcanvas"] {
  border-radius: 8px;
  font-weight: 600;
  padding: 8px 14px;
}