.maderas-quote-page [hidden] { display: none !important; }
.maderas-quote-page.quote-open { overflow: hidden; }
.maderas-quote-page .quote-intro-cta { margin-top: 28px; cursor: pointer; }
.maderas-quote-page .quote-dialog {
  width: min(900px, calc(100% - 28px));
  max-width: none;
  max-height: min(90dvh, 900px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 28px 100px rgba(20, 28, 20, .24);
}
.maderas-quote-page .quote-dialog::backdrop { background: rgba(24, 32, 25, .55); }
.maderas-quote-page .quote-dialog[open] { display: flex; }
.maderas-quote-page .quote-form { display: flex; flex-direction: column; min-height: 0; width: 100%; max-height: min(90dvh, 900px); }
.maderas-quote-page .quote-dialog-header { display: flex; flex: 0 0 auto; align-items: start; justify-content: space-between; gap: 20px; padding: 24px 28px 22px; border-bottom: 1px solid var(--line); }
.maderas-quote-page .quote-dialog-header .eyebrow { margin-bottom: 10px; font-size: .65rem; }
.maderas-quote-page .quote-dialog-header h2 { margin: 0; font-size: clamp(1.5rem, 3.4vw, 2rem); line-height: 1.13; letter-spacing: -.04em; }
.maderas-quote-page .quote-close { display: grid; place-items: center; flex: 0 0 38px; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 50%; background: #fff; color: var(--ink); font-size: 1.7rem; line-height: 1; cursor: pointer; }
.maderas-quote-page .quote-close:hover { border-color: var(--ink); }
.maderas-quote-page .quote-dialog-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 22px 28px 28px; }
.maderas-quote-page .quote-help { margin: 0 0 20px; color: var(--ink-soft); font-size: .88rem; line-height: 1.65; }
.maderas-quote-page .quote-rows { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.maderas-quote-page .quote-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 190px); gap: 24px; align-items: start; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--mist); }
.maderas-quote-page .quote-reference { min-width: 0; }
.maderas-quote-page .quote-reference-name { display: block; font-family: Rubik, 'Noto Sans', sans-serif; font-weight: 700; font-size: 1rem; line-height: 1.4; cursor: pointer; }
.maderas-quote-page .quote-reference-detail { margin: 5px 0 0; color: var(--ink-soft); font-size: .82rem; line-height: 1.5; }
.maderas-quote-page .quote-measures { margin-top: 14px; max-width: 330px; }
.maderas-quote-page .quote-measures label,
.maderas-quote-page .quote-notes label { display: block; margin-bottom: 7px; font-size: .78rem; font-weight: 700; line-height: 1.5; }
.maderas-quote-page .quote-measures label span,
.maderas-quote-page .quote-notes label span { color: var(--ink-soft); font-weight: 400; }
.maderas-quote-page .quote-measures input,
.maderas-quote-page .quote-notes textarea { display: block; width: 100%; min-width: 0; padding: 10px 12px; border: 1px solid #bac4b8; border-radius: 9px; background: #fff; color: var(--ink); font: inherit; font-size: .85rem; line-height: 1.5; }
.maderas-quote-page .quote-measures input::placeholder,
.maderas-quote-page .quote-notes textarea::placeholder { color: #6f786e; }
.maderas-quote-page .quote-quantity { min-width: 0; }
.maderas-quote-page .quote-quantity-label { display: block; margin-bottom: 7px; color: var(--ink-soft); font-size: .75rem; font-weight: 700; }
.maderas-quote-page .quote-quantity-control { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px; }
.maderas-quote-page .quote-quantity-control input { width: 100%; min-width: 0; min-height: 44px; padding: 9px 10px; border: 1px solid #bac4b8; border-radius: 9px; background: #fff; color: var(--ink); font: inherit; font-size: 1rem; }
.maderas-quote-page .quote-quantity-control input[aria-invalid="true"] { border-color: #aa3327; box-shadow: 0 0 0 1px #aa3327; }
.maderas-quote-page .quote-quantity-control > span { color: var(--ink-soft); font-size: .78rem; }
.maderas-quote-page .quote-row-error { margin: 7px 0 0; color: #9d2d24; font-size: .75rem; line-height: 1.45; }
.maderas-quote-page .quote-notes { margin-top: 22px; }
.maderas-quote-page .quote-notes textarea { min-height: 90px; resize: vertical; }
.maderas-quote-page .quote-dialog-footer { flex: 0 0 auto; padding: 18px 28px 22px; border-top: 1px solid var(--line); background: #fff; }
.maderas-quote-page .quote-summary { margin: 0; font-family: Rubik, 'Noto Sans', sans-serif; font-size: .95rem; font-weight: 700; line-height: 1.45; }
.maderas-quote-page .quote-status { margin: 5px 0 16px; color: var(--ink-soft); font-size: .78rem; line-height: 1.5; }
.maderas-quote-page .quote-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.maderas-quote-page .quote-actions .button { min-height: 46px; padding: 11px 17px; font-size: .8rem; line-height: 1.4; text-align: center; cursor: pointer; }
.maderas-quote-page .quote-reset { margin-right: auto; padding: 10px 0; border: 0; background: none; color: var(--ink-soft); font: inherit; font-size: .76rem; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.maderas-quote-page .quote-accept[aria-disabled="true"] { opacity: .45; cursor: default; }
.maderas-quote-page .quote-accept[aria-disabled="true"]:hover { transform: none; box-shadow: none; }
@media (max-width: 640px) {
  .maderas-quote-page .quote-dialog { width: calc(100% - 16px); border-radius: 18px; }
  .maderas-quote-page .quote-dialog-header { gap: 12px; padding: 20px 18px 17px; }
  .maderas-quote-page .quote-dialog-body { padding: 18px; }
  .maderas-quote-page .quote-row { grid-template-columns: minmax(0, 1fr); gap: 15px; padding: 17px; }
  .maderas-quote-page .quote-reference-name { font-size: .95rem; }
  .maderas-quote-page .quote-quantity-control { grid-template-columns: minmax(0, 120px) auto; justify-content: start; gap: 10px; }
  .maderas-quote-page .quote-measures { max-width: none; }
  .maderas-quote-page .quote-dialog-footer { padding: 15px 18px 17px; }
  .maderas-quote-page .quote-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
  .maderas-quote-page .quote-accept { grid-column: 1 / -1; grid-row: 1; }
  .maderas-quote-page .quote-actions [data-quote-close] { grid-column: 2; grid-row: 2; }
  .maderas-quote-page .quote-reset { grid-column: 1; grid-row: 2; margin: 0; text-align: left; }
  .maderas-quote-page .quote-intro-cta { width: 100%; min-height: 52px; height: auto; padding-block: 12px; text-align: center; line-height: 1.4; }
}
@media (max-height: 560px) {
  .maderas-quote-page .quote-dialog-header { padding-block: 12px; }
  .maderas-quote-page .quote-dialog-header .eyebrow { display: none; }
  .maderas-quote-page .quote-dialog-footer { padding-block: 10px; }
  .maderas-quote-page .quote-status { margin-bottom: 10px; }
}
