/* =========================================================
   1. GLOBAL COLORS & BASE STYLES
   ========================================================= */
body {
  background-color: var(--site-bgcolor);
  color: var(--site-fontcolor);
  line-height: 1.6;
}

/* Logo */
.navbar-brand .site-logo {
  max-height: 50px;
}

/* =========================================================
   2. NAVBAR & DROPDOWN
   ========================================================= */
.navbar {
  background-color: var(--site-bgcolor) !important;
  color: var(--site-fontcolor) !important;
}

.navbar .nav-link,
.navbar-brand,
.dropdown-item {
  background-color: transparent !important;
  color: var(--site-fontcolor) !important;
  text-decoration: none !important;
}

.navbar .nav-link:hover,
.dropdown-item:hover {
  color: var(--site-fontcolor) !important;
  text-decoration: underline;
}

.navbar .nav-link:focus,
.navbar .nav-link:active {
  background-color: transparent !important;
  box-shadow: none !important;
  color: var(--site-fontcolor) !important;
  outline: none !important;
  text-decoration: none !important;
}

.dropdown-menu {
  background-color: var(--site-bgcolor) !important;
  border-color: #f5f5f5 !important;
  margin-top: 0;
}

/* Hover-open behavior for desktop */
@media (hover: hover) and (pointer: fine) {
  .navbar-nav .dropdown:hover .dropdown-menu {
    display: block;
  }
}

/* Small buttons */
.btn.btn-sm {
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
  border-radius: 4px;
}

/* =========================================================
   3. CARDS & AUCTION STATUS
   ========================================================= */
.card {
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.auction-status {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 10px;
  border-radius: 12px;
  color: #fff;
  font-weight: bold;
  z-index: 10;
}

.status-active       { background-color: #28a745; }
.status-successful   { background-color: #17a2b8; }
.status-unsuccessful { background-color: #dc3545; }
.status-upcoming     { background-color: #ffc107; color: #212529; }

/* =========================================================
   4. IMAGES (Card, Auction, Modal, Seller)
   ========================================================= */
img.card-img-top {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 300px;
  margin: auto;
  display: block;
}

.auction-image {
  max-width: 200px;
}

/* Seller logo */
.seller-logo {
  max-width: 150px;
  max-height: 150px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

/* Image thumbnail grids (auction & product detail) */
.auction-images,
.product-images {
  text-align: center;
}

.auction-images img,
.product-images img {
  width: 100px;
  height: auto;
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  margin: 5px;
}

@media (min-width: 768px) {
  .auction-images img,
  .product-images img {
    width: 150px;
  }
}

/* Modal images */
.modal-image {
  width: 100%;
  height: auto;
  max-width: 100%;
  max-height: 80vh;
  display: block;
  margin: 0 auto;
}

.modal img {
  width: 100%;
  height: auto;
  max-height: 80vh;
}

/* =========================================================
   5. COUNTDOWN STYLES (Neutral, shared sitewide)
   ========================================================= */
.countdown-timer {
  margin: 15px 0;
  display: inline-block;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--site-fontcolor);
  background: transparent;
  padding: 0;
  border-radius: 0;
}

.countdown-box {
  display: inline-block;
  background-color: #f8f9fa;
  padding: 6px 10px;
  border-radius: 4px;
  text-align: center;
  min-width: 50px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.countdown-number {
  font-weight: 700;
  color: #212529;
  font-size: 1.1rem;
}

.countdown-label {
  font-size: 0.7rem;
  color: #6c757d;
}

.countdown-timer.expired {
  background-color: #6c757d;
}

/* =========================================================
   6. RESERVE STATUS LABEL
   ========================================================= */
.reserve-status {
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  text-align: center;
  margin: 20px 0;
}

.reserve-met     { background-color: #28a745; }
.reserve-not-met { background-color: #dc3545; }

/* =========================================================
   7. BUTTONS (Bootstrap harmonization)
   ========================================================= */
.btn-primary,
.btn-danger {
  font-weight: 600;
  border-radius: 6px;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn-primary {
  background-color: #007bff;
  border: none;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #0056b3;
  transform: translateY(-1px);
}

.btn-danger {
  background-color: #dc3545;
  border: none;
}

.btn-danger:hover,
.btn-danger:focus {
  background-color: #b02a37;
  transform: translateY(-1px);
}

/* =========================================================
   8. STRIPE / PAYMENT FORMS
   ========================================================= */
.card-container {
  max-width: 500px;
  margin: 50px auto;
  padding: 20px;
  background: #fff;
  border: 1px solid #e3e6ea;
  border-radius: 8px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.2s ease-in-out, transform 0.2s ease;
}

.card-container:hover {
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

#card-element {
  border: 1px solid #ccc;
  padding: 10px;
  border-radius: 5px;
  background: #fff;
  width: 100%;
}

#payment-form button {
  background-color: #007bff;
  color: #fff;
  padding: 10px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  width: 100%;
  font-size: 16px;
  font-weight: bold;
  margin-top: 10px;
}

#payment-form button:hover {
  background-color: #0056b3;
}

/* Keep payment buttons vertically consistent inside cards */
.card .mt-auto form + form {
  margin-top: 0.5rem !important;
}

.card .mt-auto form {
  margin-bottom: 0 !important;
}

.card .mt-auto button {
  width: 100%;
  display: block;
}

.card .mt-auto {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  justify-content: flex-end;
}

/* =========================================================
   9. SELLER HUB & PRODUCT EDIT PREVIEWS
   ========================================================= */
.sellerhub-logo-preview {
  max-width: 200px;
  height: auto;
  display: block;
  margin-top: 0.5rem;
}

/* =========================================================
   10. PRODUCT DETAIL PAGE STYLES
   ========================================================= */
/* (image styles merged with auction-images above) */

/* Optional: for consistent text styling in pages like Privacy Policy, Terms, etc. */
.content {
  line-height: 1.8;
  font-size: 1.05rem;
  color: var(--site-fontcolor);
  white-space: pre-wrap;
}

/* Optional: Payment settings wrapper (used in paypal.php and stripe pages) */
.payment-settings {
  max-width: 500px;
  margin: 40px auto;
  background: #fff;
  padding: 25px 30px;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

