/* ============================================================
   St-Bat — Location engin BTP / Payment UI
   Palette: dark #1a1a1a, gold #d4a853, grey #f5f5f5
   ============================================================ */

.rental-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 15px 80px;
}

.rental-intro {
  text-align: center;
  margin-bottom: 32px;
}
.rental-intro h2 {
  color: #1a1a1a;
  font-size: 22px;
  margin: 0 0 8px;
}
.rental-intro p {
  color: #666;
  font-size: 14px;
  margin: 0;
}

/* ===== Step badges ===== */
.rental-steps {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.rental-step {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  color: #999;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 20px;
  letter-spacing: 0.3px;
}
.rental-step.active {
  color: #1a1a1a;
  border-color: #d4a853;
  background: #fff8e8;
}
.rental-step.done {
  color: #d4a853;
  border-color: #d4a853;
}
.rental-step .num {
  display: inline-block;
  width: 18px;
  height: 18px;
  background: #ddd;
  color: #fff;
  border-radius: 50%;
  text-align: center;
  line-height: 18px;
  font-size: 11px;
  margin-right: 6px;
}
.rental-step.active .num,
.rental-step.done .num { background: #d4a853; }

/* ===== Engin card grid ===== */
.engin-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 991px) { .engin-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .engin-grid { grid-template-columns: 1fr; } }

.engin-card {
  background: #fff;
  border: 2px solid #eaeaea;
  border-radius: 8px;
  padding: 0;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.engin-card-body { padding: 16px 18px 20px; display: flex; flex-direction: column; flex: 1; }
.engin-image {
  position: relative;
  width: 100%;
  height: 160px;
  background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.engin-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(212,168,83,0.18), transparent 60%);
}
.engin-image .placeholder-icon {
  position: relative;
  font-size: 54px;
  color: #d4a853;
  opacity: 0.85;
  z-index: 1;
}
.engin-image .placeholder-label {
  position: absolute;
  bottom: 10px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: rgba(255,255,255,0.5);
  font-weight: 600;
  z-index: 1;
}
.engin-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}
.engin-card:hover {
  border-color: #d4a853;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}
.engin-card.selected {
  border-color: #d4a853;
  background: #fffdf6;
  box-shadow: 0 4px 18px rgba(212,168,83,0.25);
}
.engin-card.selected::after {
  content: "✓";
  position: absolute;
  top: 10px;
  right: 12px;
  width: 24px;
  height: 24px;
  background: #d4a853;
  color: #fff;
  border-radius: 50%;
  text-align: center;
  line-height: 24px;
  font-weight: 700;
  font-size: 14px;
}
.engin-card .cat {
  font-size: 11px;
  color: #d4a853;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.6px;
  margin-bottom: 6px;
}
.engin-card .name {
  font-size: 16px;
  color: #1a1a1a;
  font-weight: 700;
  margin: 0 0 6px;
  line-height: 1.3;
}
.engin-card .desc {
  font-size: 13px;
  color: #666;
  line-height: 1.5;
  margin: 0 0 14px;
  flex: 1;
}
.engin-card .price {
  font-size: 20px;
  color: #1a1a1a;
  font-weight: 700;
  border-top: 1px solid #eaeaea;
  padding-top: 12px;
}
.engin-card .price small {
  font-size: 12px;
  font-weight: 400;
  color: #888;
}

/* ===== Config panel (appears after selection) ===== */
.rental-config {
  display: none;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
  padding: 32px;
  margin-top: 32px;
}
.rental-config.visible { display: block; }

.rental-config h3 {
  font-size: 18px;
  color: #1a1a1a;
  margin: 0 0 4px;
}
.rental-config .sub {
  color: #888;
  font-size: 13px;
  margin: 0 0 24px;
}

.cfg-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 600px) { .cfg-row { grid-template-columns: 1fr; } }

.cfg-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.cfg-field input,
.cfg-field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  transition: border-color 0.15s;
}
.cfg-field input:focus,
.cfg-field select:focus {
  outline: none;
  border-color: #d4a853;
  box-shadow: 0 0 0 3px rgba(212,168,83,0.15);
}

.cfg-field-error input,
.cfg-field-error select {
  border-color: #c0392b;
}
.cfg-field-error .err-msg {
  display: block;
  color: #c0392b;
  font-size: 12px;
  margin-top: 4px;
}
.err-msg { display: none; }

.days-helper {
  font-size: 12px;
  color: #888;
  margin-top: 6px;
}

/* ===== Totals ===== */
.rental-totals {
  background: #f5f5f5;
  border-radius: 6px;
  padding: 18px 20px;
  margin: 24px 0 20px;
}
.rental-totals .line {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: #555;
  margin-bottom: 6px;
}
.rental-totals .line.total {
  font-size: 18px;
  color: #1a1a1a;
  font-weight: 700;
  border-top: 1px solid #ddd;
  padding-top: 10px;
  margin-top: 10px;
}

/* ===== Buttons ===== */
.btn-rental {
  display: inline-block;
  background: #1a1a1a;
  color: #fff;
  border: none;
  padding: 14px 32px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.5px;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.15s;
  text-transform: uppercase;
}
.btn-rental:hover { background: #d4a853; }
.btn-rental:disabled {
  background: #ccc;
  cursor: not-allowed;
}
.btn-rental-secondary {
  background: transparent;
  color: #888;
  border: 1px solid #ddd;
}
.btn-rental-secondary:hover {
  background: transparent;
  color: #1a1a1a;
  border-color: #1a1a1a;
}

.actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.actions-row .left { font-size: 13px; color: #888; }

/* ===== Confirmation overlay ===== */
.rental-confirm {
  display: none;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
  padding: 32px;
  margin-top: 32px;
}
.rental-confirm.visible { display: block; }

.confirm-recap {
  background: #f5f5f5;
  border-radius: 6px;
  padding: 20px;
  margin-bottom: 20px;
}
.confirm-recap .recap-line {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: #555;
  padding: 4px 0;
}
.confirm-recap .recap-line strong { color: #1a1a1a; }
.confirm-recap .recap-section {
  font-size: 11px;
  font-weight: 700;
  color: #d4a853;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin: 14px 0 6px;
  padding-bottom: 6px;
  border-bottom: 1px solid #e5e5e5;
}
.confirm-recap .recap-section:first-child { margin-top: 0; }

.secured-badge {
  text-align: center;
  font-size: 12px;
  color: #888;
  margin-top: 16px;
}
.secured-badge i { color: #d4a853; margin-right: 4px; }
