/* ================================================================
   Industry Synapse – Auktions-Styles
   ================================================================ */

/* ── Section ── */
.auction-section {
  background: linear-gradient(135deg, #1a1200 0%, #2c1f00 100%);
  padding: 3rem 0;
  border-top: 3px solid var(--color-yellow, #f59e0b);
  border-bottom: 3px solid var(--color-yellow, #f59e0b);
}
.auction-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.75rem;
}
.auction-section-title {
  font-family: 'Rajdhani', 'Inter', sans-serif;
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: .6rem;
}
.auction-section-title .hammer-icon { font-size: 1.6rem; }
.auction-live-pill {
  display: flex;
  align-items: center;
  gap: .4rem;
  background: rgba(220, 38, 38, .15);
  border: 1px solid rgba(220, 38, 38, .4);
  color: #fca5a5;
  font-size: .72rem;
  font-weight: 700;
  padding: .2rem .65rem;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: .08em;
  animation: pulse-live 2s ease infinite;
}
.auction-live-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #ef4444;
  animation: pulse-live 1.5s ease infinite;
}
@keyframes pulse-live {
  0%, 100% { opacity: 1; }
  50%       { opacity: .5; }
}
.auction-view-all {
  color: var(--color-yellow, #f59e0b);
  text-decoration: none;
  font-size: .85rem;
  font-weight: 600;
  border: 1.5px solid rgba(245, 158, 11, .4);
  padding: .4rem .9rem;
  border-radius: 6px;
  transition: all .2s;
}
.auction-view-all:hover {
  background: rgba(245, 158, 11, .15);
  border-color: var(--color-yellow, #f59e0b);
}

/* ── Sortier-Leiste ── */
.auction-sort-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .65rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.auction-sort-tabs {
  display: flex;
  gap: .4rem;
  flex-wrap: wrap;
}
.auc-tab {
  background: rgba(255,255,255,.08);
  border: 1.5px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.65);
  padding: .4rem .9rem;
  border-radius: 99px;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  white-space: nowrap;
}
.auc-tab:hover {
  background: rgba(255,255,255,.15);
  color: #fff;
  border-color: rgba(255,255,255,.3);
}
.auc-tab.active {
  background: var(--color-yellow, #f59e0b);
  color: #1a1200;
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(245,158,11,.4);
}
@media (max-width: 560px) {
  .auc-tab { font-size: .72rem; padding: .35rem .75rem; }
}

/* ── Grid ── */
.auction-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}
.auction-grid-ended { opacity: .75; }

/* ── Card ── */
.auction-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid transparent;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
  transition: transform .2s, box-shadow .2s, border-color .2s;
  display: flex;
  flex-direction: column;
}
.auction-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(245, 158, 11, .25);
  border-color: var(--color-yellow, #f59e0b);
}
.auction-card.auction-ended {
  border-color: #cbd5e1;
  opacity: .8;
}
.auction-card-compact { max-width: 320px; }

/* Image */
.auction-img-wrap {
  position: relative;
  background: #f8f8f6;
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.auction-img-wrap img {
  width: 100%; height: 100%;
  object-fit: contain;
  padding: .75rem;
  transition: transform .2s;
}
.auction-card:hover .auction-img-wrap img { transform: scale(1.04); }
.auction-img-placeholder {
  width: 80px; height: 80px;
  background: var(--color-yellow, #f59e0b);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
}

/* Badges on image */
.auction-badge-status {
  position: absolute; top: .6rem; left: .6rem;
  font-size: .7rem; font-weight: 700;
  padding: .2rem .6rem; border-radius: 99px;
}
.badge-live { background: rgba(220,38,38,.9); color: #fff; }
.badge-ended { background: rgba(100,116,139,.9); color: #fff; }
.auction-badge-buy {
  position: absolute; top: .6rem; right: .6rem;
  font-size: .68rem; font-weight: 700;
  background: rgba(22, 163, 74, .9); color: #fff;
  padding: .2rem .55rem; border-radius: 99px;
}

/* Body */
.auction-body { padding: 1rem; display: flex; flex-direction: column; flex: 1; gap: .5rem; }
.auction-meta { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.auction-cat { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--color-yellow, #a07800); }
.auction-sku { font-family: monospace; font-size: .68rem; color: #94a3b8; }
.auction-title { font-size: .95rem; font-weight: 700; line-height: 1.35; color: #1a1f2e; }

/* Bid row */
.auction-bid-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem;
  background: #fafafa;
  border-radius: 8px;
  padding: .75rem;
  border: 1px solid #e2e8f0;
}
.auction-bid-label, .auction-timer-label {
  font-size: .68rem; color: #64748b; text-transform: uppercase;
  letter-spacing: .06em; display: block; margin-bottom: .15rem;
}
.auction-current-bid {
  font-size: 1.15rem; font-weight: 700; color: #1a1f2e; display: block;
}
.auction-bid-count { font-size: .72rem; color: #64748b; }

/* Timer */
.auction-timer-block { text-align: right; }
.auction-countdown { font-size: .82rem; font-weight: 600; color: #1a1f2e; display: block; }
.auction-timer-bars {
  display: flex; gap: .25rem; justify-content: flex-end; margin-top: .3rem;
}
.timer-seg {
  display: flex; flex-direction: column; align-items: center;
  background: #1a1f2e; border-radius: 4px;
  padding: .2rem .35rem; min-width: 28px;
}
.timer-val { font-size: .75rem; font-weight: 700; color: #f59e0b; font-family: monospace; }
.timer-lbl { font-size: .55rem; color: rgba(255,255,255,.5); }

/* Urgency – Letzte Stunde: Orange */
.urgent-orange .timer-seg          { background: #d97706; }
.urgent-orange .auction-countdown  { color: #d97706; }
.urgent-orange .auction-timer-block { animation: pulseOrange 2s ease-in-out infinite; }

/* KRITISCH – Letzte 5 Minuten: Rot + Pulsieren */
.urgent-red .timer-seg             { background: #dc2626; }
.urgent-red .auction-countdown     { color: #dc2626; font-weight: 900; }
.urgent-red .auction-timer-block   { animation: pulseRed 1s ease-in-out infinite; }
.urgent-red .auction-timer-bars    { animation: flashBlink .5s step-end infinite; }

/* KRITISCH – Auktionskarte Rahmen blinkt */
.auction-card.urgent-red {
  border-color: #dc2626;
  box-shadow: 0 0 0 0 rgba(220,38,38,.7);
  animation: cardPulse 1s ease-out infinite;
}

/* Banner – Letzte 5 Minuten! */
.last-five-banner {
  background: linear-gradient(90deg, #dc2626, #ef4444, #dc2626);
  background-size: 200% 100%;
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  text-align: center;
  padding: .35rem;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  animation: bannerSlide 1.5s linear infinite;
  letter-spacing: .06em;
}

/* Animationen */
@keyframes pulseOrange {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: .85; transform: scale(1.02); }
}
@keyframes pulseRed {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: .8; transform: scale(1.05); }
}
@keyframes flashBlink {
  0%, 100% { opacity: 1; }
  50%       { opacity: .3; }
}
@keyframes cardPulse {
  0%   { box-shadow: 0 0 0 0 rgba(220,38,38,.7); }
  70%  { box-shadow: 0 0 0 10px rgba(220,38,38,0); }
  100% { box-shadow: 0 0 0 0 rgba(220,38,38,0); }
}
@keyframes bannerSlide {
  0%   { background-position: 0% center; }
  100% { background-position: 200% center; }
}

/* Shipping */
.auction-shipping { font-size: .75rem; color: #64748b; }

/* Actions */
.auction-actions { display: flex; flex-direction: column; gap: .5rem; margin-top: .25rem; }
.btn-bid {
  display: flex; align-items: center; justify-content: center; gap: .4rem;
  background: var(--color-yellow, #f59e0b); color: #1a1f2e;
  font-size: .875rem; font-weight: 700;
  border: none; border-radius: 8px; padding: .7rem 1rem;
  cursor: pointer; width: 100%;
  transition: background .2s, box-shadow .2s;
}
.btn-bid:hover { background: #d97706; box-shadow: 0 4px 12px rgba(245,158,11,.4); }
.btn-buynow {
  display: flex; align-items: center; justify-content: center;
  background: #16a34a; color: #fff;
  font-size: .8rem; font-weight: 700;
  border: none; border-radius: 8px; padding: .55rem 1rem;
  cursor: pointer; width: 100%;
  transition: background .2s;
}
.btn-buynow:hover { background: #15803d; }
.btn-ebay-link {
  display: block; text-align: center;
  font-size: .78rem; font-weight: 600; color: #0064d2;
  text-decoration: none;
  border: 1.5px solid #0064d2; border-radius: 8px;
  padding: .45rem;
  transition: all .2s;
}
.btn-ebay-link:hover { background: #eff6ff; }
.auction-ended-info {
  font-size: .82rem; color: #64748b;
  background: #f8fafc; border-radius: 6px;
  padding: .6rem; text-align: center;
}

/* Empty */
.auction-empty {
  text-align: center;
  padding: 3rem 2rem;
  color: rgba(255,255,255,.6);
}
.auction-empty p { font-size: .9rem; margin: .75rem 0; }

/* ── Beendete Angebote ── */
.auction-ended-section {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,.08);
}
.auction-ended-title {
  font-size: .85rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: rgba(255,255,255,.5);
  margin-bottom: 1rem;
}
/* Beendete Karten: ausgegraut */
.auction-grid-ended .auction-card {
  opacity: .7;
  filter: grayscale(.3);
  border-color: rgba(255,255,255,.08);
}
.auction-grid-ended .auction-card:hover {
  opacity: .9;
  filter: grayscale(0);
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
}
/* Gewinner-Badge auf beendeten Karten */
.auction-grid-ended .winner-info {
  background: linear-gradient(90deg, #1a1200, #2c1f00);
  border-top: 1px solid rgba(245,158,11,.3);
  padding: .6rem .85rem;
  font-size: .75rem;
  color: rgba(255,255,255,.6);
  display: flex; justify-content: space-between; align-items: center;
}
.auction-grid-ended .winner-info .winner-price {
  font-weight: 700; color: #f59e0b; font-size: .9rem;
}

/* ── Bid Modal ── */
.auction-modal-overlay {
  position: fixed; inset: 0; z-index: 10000;
  background: rgba(0,0,0,.7);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  animation: fadeIn .2s ease;
}
@keyframes fadeIn { from { opacity:0 } to { opacity:1 } }
.auction-modal {
  background: #fff;
  border-radius: 16px;
  padding: 2rem;
  width: 100%; max-width: 440px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
  animation: slideUp .25s ease;
}
@keyframes slideUp { from { transform:translateY(20px); opacity:0 } to { transform:translateY(0); opacity:1 } }
.modal-close {
  position: absolute; top: 1rem; right: 1rem;
  width: 32px; height: 32px; border-radius: 50%;
  background: #f1f5f9; border: none; cursor: pointer;
  font-size: 1.2rem; color: #64748b; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.modal-close:hover { background: #fee2e2; color: #dc2626; }
.modal-title { font-size: 1.25rem; font-weight: 700; margin-bottom: .25rem; }
.modal-subtitle { font-size: .82rem; color: #64748b; margin-bottom: 1rem; }
.modal-current {
  background: #fffbeb; border: 1px solid #fde68a;
  border-radius: 8px; padding: .65rem .9rem;
  font-size: .85rem; margin-bottom: 1rem;
}
.modal-alert {
  border-radius: 6px; padding: .65rem .9rem;
  font-size: .82rem; margin-bottom: .75rem;
}
.modal-alert-success { background: #f0fdf4; border: 1px solid #bbf7d0; color: #15803d; }
.modal-alert-error   { background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; }
.modal-form { display: flex; flex-direction: column; gap: .75rem; }
.modal-field { display: flex; flex-direction: column; gap: .25rem; }
.modal-field label { font-size: .78rem; font-weight: 600; }
.modal-input {
  border: 1.5px solid #e2e8f0; border-radius: 8px;
  padding: .6rem .8rem; font-size: .9rem;
  transition: border-color .2s;
}
.modal-input:focus { border-color: #f59e0b; outline: none; box-shadow: 0 0 0 3px rgba(245,158,11,.15); }
.modal-hint { font-size: .72rem; color: #94a3b8; }
.btn-submit-bid {
  background: #f59e0b; color: #1a1f2e;
  border: none; border-radius: 8px;
  padding: .8rem; font-size: .95rem; font-weight: 700;
  cursor: pointer; width: 100%;
  transition: background .2s, box-shadow .2s;
}
.btn-submit-bid:hover { background: #d97706; box-shadow: 0 4px 12px rgba(245,158,11,.4); }

/* ── Responsive ── */
@media (max-width: 640px) {
  .auction-grid { grid-template-columns: 1fr; }
  .auction-bid-row { grid-template-columns: 1fr; }
  .auction-timer-block { text-align: left; }
  .auction-timer-bars { justify-content: flex-start; }
}
