/* quote.css — quote (devis) UI: product-modal add-to-quote controls,
   header cart button + badge, right-side drawer, form, success state. */

/* ---- Header quote button ---- */
.site-header .quote-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border: 1px solid #000;
  background: #fff;
  color: #000;
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  cursor: pointer;
  line-height: 1;
}
.site-header .quote-btn:hover { background: #000; color: #fff; }
.site-header .quote-btn:hover .quote-badge { background: #fff; color: #000; }
.quote-badge {
  min-width: 1.125rem;
  height: 1.125rem;
  padding: 0 0.25rem;
  border-radius: 999px;
  background: #000;
  color: #fff;
  font-size: 0.625rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ---- Product-modal "Add to quote" controls ---- */
.quote-actions {
  display: flex;
  gap: 0.75rem;
  align-items: flex-end;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}
.quote-actions label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.quote-actions input[type="number"] {
  width: 4.5rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--color-border);
  font-size: 0.9375rem;
  text-transform: none;
  letter-spacing: normal;
  color: #000;
  background: #fff;
}
.quote-actions .btn-primary {
  padding: 0.625rem 1.25rem;
  background: #000;
  color: #fff;
  border: 1px solid #000;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}
.quote-actions .btn-primary:hover { background: #222; }
.quote-actions .added-feedback {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #0a3622;
}

/* ---- Drawer ---- */
body.drawer-open { overflow: hidden; }

.quote-drawer {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: none;
}
.quote-drawer[aria-hidden="false"] { display: block; }
.quote-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}
.quote-drawer-panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 100%;
  max-width: 30rem;
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: -2px 0 20px rgba(0, 0, 0, 0.15);
  animation: quoteDrawerIn 0.25s ease;
}
@keyframes quoteDrawerIn {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}

.quote-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--color-border-soft);
}
.quote-drawer-header h2 {
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
}
.quote-drawer-header .modal-close {
  position: static;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: #f4f4f4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
}
.quote-drawer-header .modal-close img { width: 0.75rem; height: 0.75rem; }

.quote-drawer-body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.quote-empty {
  padding: 2rem 0;
  text-align: center;
  color: var(--color-muted);
}

/* ---- Item list ---- */
.quote-items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.quote-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 5rem auto 1.75rem;
  gap: 0.75rem;
  align-items: center;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--color-border-soft);
}
.quote-item-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.quote-item-title {
  font-size: 0.9375rem;
  font-weight: 500;
  color: #000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.quote-item-price {
  font-size: 0.75rem;
  color: var(--color-muted);
}
.quote-item-qty {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--color-border);
  background: #fff;
}
.quote-item-qty .qty-btn {
  width: 1.75rem;
  height: 1.75rem;
  background: #fff;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
}
.quote-item-qty .qty-btn:hover { background: #f4f4f4; }
.quote-item-qty input {
  width: 2.25rem;
  border: none;
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  text-align: center;
  font-size: 0.875rem;
  padding: 0;
  background: #fff;
  -moz-appearance: textfield;
}
.quote-item-qty input::-webkit-outer-spin-button,
.quote-item-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.quote-item-line {
  font-size: 0.9375rem;
  font-weight: 500;
  white-space: nowrap;
  text-align: right;
}
.quote-item-remove {
  width: 1.75rem;
  height: 1.75rem;
  background: transparent;
  color: var(--color-muted);
  border: none;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
}
.quote-item-remove:hover { color: #000; }

/* ---- Totals + validate ---- */
.quote-totals {
  border-top: 1px solid var(--color-border);
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.quote-total-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 1rem;
}
.quote-total-row strong { font-size: 1.25rem; font-weight: 500; }
.quote-validate-btn {
  width: 100%;
  padding: 0.875rem 1rem;
  background: #000;
  color: #fff;
  border: 1px solid #000;
  font-size: 0.8125rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}
.quote-validate-btn:hover { background: #222; }

/* ---- Submit form ---- */
.quote-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-border-soft);
}
.quote-form h3 {
  font-size: 0.875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
}
.quote-form-intro {
  font-size: 0.8125rem;
  color: var(--color-muted);
  margin: 0;
}
.quote-form label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.quote-form input[type="text"],
.quote-form input[type="email"],
.quote-form input[type="tel"],
.quote-form textarea {
  padding: 0.625rem 0.75rem;
  border: 1px solid var(--color-border);
  background: #fff;
  font-size: 0.9375rem;
  letter-spacing: normal;
  text-transform: none;
  color: #000;
  font-family: inherit;
}
.quote-form textarea { resize: vertical; min-height: 4rem; }
.quote-honeypot {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.quote-form-error {
  padding: 0.625rem 0.75rem;
  background: #f8d7da;
  border: 1px solid #f1aeb5;
  color: #58151c;
  font-size: 0.8125rem;
}
.quote-form-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}
.quote-form-actions .btn {
  padding: 0.625rem 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}
.quote-form-actions .btn-ghost {
  background: #fff;
  color: #000;
  border: 1px solid var(--color-border);
}
.quote-form-actions .btn-primary {
  background: #000;
  color: #fff;
  border: 1px solid #000;
}

/* ---- Success ---- */
.quote-success {
  text-align: center;
  padding: 2rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: center;
}
.quote-success h3 {
  font-size: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0;
}
.quote-success p {
  margin: 0;
  font-size: 0.9375rem;
  color: var(--color-muted);
}
.quote-success .btn-ghost {
  padding: 0.625rem 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: #fff;
  color: #000;
  border: 1px solid var(--color-border);
  cursor: pointer;
}
