/* Área do cliente. Paleta e dimensões da configuração do orçamento. */
.customer-portal {
  --portal-ivory: #fffbf2;
  --portal-card: #fffefb;
  --portal-ink: #242b39;
  --portal-muted: #535b66;
  --portal-line: #e6ded2;
  --portal-control: #8d8173;
  --portal-orange: #f15f24;
  --portal-orange-ink: #8c3415;
  --portal-orange-light: #fff0e3;
  --portal-blue: #235b8a;
  --portal-blue-light: #eaf3fb;
  --portal-green: #167247;
  --portal-green-dark: #105a39;
  --portal-green-light: #e9f5ed;
  --portal-gap: 16px;
  --portal-pad: clamp(12px, 2.2vw, 24px);
  background: #faf8f6;
  color: var(--portal-ink);
  font-family: Arial, Helvetica, sans-serif;
}

.customer-portal .site-header {
  min-height: 0;
  max-width: none;
  justify-content: space-between;
  gap: 12px;
  padding: 6px max(16px, calc((100% - 1040px) / 2));
}

.customer-portal .site-header img {
  display: block;
  width: clamp(124px, 13vw, 158px);
  height: auto;
}

.customer-portal .site-header > span {
  display: block;
  color: var(--portal-muted);
  font-size: .875rem;
  font-weight: 700;
}

.customer-portal .order-main {
  width: min(1040px, calc(100% - 28px));
  margin: 14px auto 36px;
  padding: 0;
  color: var(--portal-ink);
  font-size: 1rem;
  line-height: 1.5;
}

.customer-portal .portal-workspace {
  padding: var(--portal-pad);
  border: 1px solid var(--portal-line);
  border-radius: 20px;
  background: var(--portal-ivory);
  box-shadow: 0 8px 28px #422d1910;
}

.customer-portal .portal-heading::before {
  content: "";
  display: block;
  width: 34px;
  height: 4px;
  margin-bottom: 10px;
  border-radius: 4px;
  background: var(--portal-blue);
}

.customer-portal #portal-title {
  margin: 0;
  color: var(--portal-ink);
  font: 800 clamp(1.65rem, 3.5vw, 2.25rem)/1.15 Arial, Helvetica, sans-serif !important;
  letter-spacing: -.035em !important;
  text-transform: none !important;
  overflow-wrap: anywhere;
}

.customer-portal .order-main :is(h2, h3, h4, legend) {
  color: var(--portal-ink);
  font-family: inherit;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.015em;
  overflow-wrap: anywhere;
}

.customer-portal .order-main h2 {
  font-size: clamp(1.2rem, 2.8vw, 1.45rem);
  margin: 0 0 10px;
}

.customer-portal .order-main h3 {
  font-size: 1.05rem;
  margin: 0 0 8px;
}

.customer-portal .order-main p {
  margin-block: 0 10px;
}

.customer-portal .order-main .help,
.customer-portal :is(.portal-muted, .portal-help, .registration-reassurance, .payment-choice-note) {
  color: var(--portal-muted);
  font-size: .875rem;
  line-height: 1.5;
}

.customer-portal .portal-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.customer-portal .purchase-steps {
  width: 100%;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 14px 0;
}

.customer-portal .purchase-steps li {
  min-width: 0;
  margin: 0;
}

.customer-portal .purchase-steps button {
  min-height: 100%;
  padding: 8px;
  gap: 8px;
  border: 1px solid var(--portal-line);
  border-radius: 8px;
  background: var(--portal-card);
  color: var(--portal-ink);
}

.customer-portal .purchase-steps strong,
.customer-portal .purchase-steps small {
  display: block;
  font-size: .875rem;
  line-height: 1.35;
}

.customer-portal .purchase-steps small {
  margin-top: 2px;
  color: var(--portal-muted);
  font-size: .75rem;
  font-weight: 400;
}

.customer-portal .portal-step-number {
  display: grid;
  flex: none;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #f1ede6;
  font-size: .8rem;
  font-weight: 700;
}

.customer-portal [data-step][data-step-state="done"] .portal-step-number {
  color: var(--portal-green-dark);
  background: var(--portal-green-light);
}

.customer-portal .purchase-steps button[aria-current="step"] {
  border-color: var(--portal-orange-ink);
  background: var(--portal-orange-light);
  box-shadow: inset 0 -2px var(--portal-orange);
}

.customer-portal .purchase-steps button[aria-current="step"] .portal-step-number {
  color: var(--portal-orange-ink);
  background: #ffddc6;
}

.customer-portal .purchase-steps button[data-step-state="future"]:not([aria-current="step"]) {
  background: #f7f4ee;
}

.customer-portal .purchase-steps button:disabled {
  opacity: 1;
  cursor: default;
}

.customer-portal #order-register,
.customer-portal #order-details {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
}

.customer-portal :is(.order-customer-grid, .registration-layout) {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(275px, 1fr);
  align-items: start;
  gap: var(--portal-gap);
}

.customer-portal .order-customer-flow,
.customer-portal #order-form {
  min-width: 0;
}

.customer-portal :is(.registration-panel, .registration-summary, .order-customer-summary, .order-customer-flow > section) {
  min-width: 0;
  padding: var(--portal-pad);
  margin: 0;
  border: 1px solid var(--portal-line);
  border-radius: 14px;
  background: var(--portal-card);
  box-shadow: none;
}

.customer-portal #order-form .registration-panel {
  margin-bottom: var(--portal-gap);
}

.customer-portal .registration-panel legend {
  float: left;
  width: 100%;
  margin: 0 0 10px;
  padding: 0;
  font-size: 1.05rem;
}

.customer-portal .registration-panel > :first-child + * {
  clear: both;
}

.customer-portal :is(.registration-fields, #delivery-fields, .portal-upload-grid, .portal-file-grid) {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.customer-portal :is(.field-name, .field-street, .field-lookup, #delivery-fields > label:first-child) {
  grid-column: 1 / -1;
}

.customer-portal .order-main label {
  min-width: 0;
  gap: 4px;
  margin: 0;
  color: #303541;
  font-size: .875rem;
  font-weight: 700;
}

.customer-portal .order-main :is(input:not([type="checkbox"]):not([type="radio"]), select) {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 8px 10px;
  border: 1px solid var(--portal-control);
  border-radius: 7px;
  background: #fff;
  color: var(--portal-ink);
  font: 1rem/1.5 Arial, Helvetica, sans-serif;
}

.customer-portal input::placeholder {
  color: #69615a;
}

.customer-portal .order-main :is(input[type="checkbox"], input[type="radio"]) {
  flex: none;
  width: 18px;
  height: 18px;
  min-height: 0;
  margin: 2px 0 0;
  padding: 0;
  accent-color: var(--portal-blue);
}

.customer-portal .order-main .check-line {
  align-items: flex-start;
  gap: 10px;
  margin: 10px 0;
  padding: 10px;
  border: 1px solid #bfd5e8;
  border-radius: 8px;
  background: var(--portal-blue-light);
  color: #1c486e;
  font-weight: 400;
}

.customer-portal .order-main .button {
  min-height: 44px;
  max-width: 100%;
  margin: 5px 0;
  padding: 9px 13px;
  border: 1px solid transparent;
  border-radius: 7px;
  box-shadow: none;
  font: 700 .9375rem/1.35 Arial, Helvetica, sans-serif;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  transform: none;
}

.customer-portal .order-main .button.primary {
  border-color: var(--portal-green);
  background: var(--portal-green);
  color: #fff;
}

.customer-portal .order-main .button.primary:hover:not(:disabled) {
  border-color: var(--portal-green-dark);
  background: var(--portal-green-dark);
}

.customer-portal .order-main .button.secondary {
  border-color: var(--portal-control);
  background: #fff;
  color: var(--portal-ink);
}

.customer-portal .order-main .button.secondary:hover:not(:disabled) {
  background: #f4f0e9;
}

.customer-portal :is(a:not(.button), .text-button) {
  color: var(--portal-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.customer-portal .site-header a { display: block; }

.customer-portal .order-main .text-button {
  min-height: 44px;
  padding: 6px 0;
  text-align: left;
}

.customer-portal :is(a, button, input, select, summary, [tabindex]):focus-visible {
  outline: 3px solid var(--portal-blue);
  outline-offset: 3px;
}

.customer-portal .order-desk-heading {
  margin: 0 0 var(--portal-gap);
}

.customer-portal .order-desk-heading :is(#order-number, #order-spec) {
  margin: 0;
  color: var(--portal-muted);
  font-size: .875rem;
}

.customer-portal .order-desk-heading .order-summary {
  gap: 5px 12px;
  margin-bottom: 3px;
}

.customer-portal .order-main .status-chip,
.customer-portal .portal-badge {
  display: inline-block;
  margin: 0;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--portal-orange-light);
  color: var(--portal-orange-ink);
  font-size: .8rem;
  font-weight: 700;
}

.customer-portal .portal-badge.is-confirmed {
  background: var(--portal-green-light);
  color: var(--portal-green-dark);
}

.customer-portal .portal-metrics,
.customer-portal .order-main .order-metrics {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  margin: 0 0 10px;
}

.customer-portal :is(.portal-metrics, .order-metrics, .order-charge-breakdown) > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 2px 10px;
  padding: 6px 0;
  border-radius: 0;
  background: transparent;
}

.customer-portal :is(.portal-metrics, .order-metrics, .order-charge-breakdown) :is(dt, dd) {
  margin: 0;
  color: var(--portal-muted);
  font-size: .875rem;
}

.customer-portal :is(.portal-metrics, .order-metrics, .order-charge-breakdown) dd {
  color: var(--portal-ink);
  font-weight: 700;
  white-space: normal;
  overflow-wrap: anywhere;
}

.customer-portal :is(#registration-values, #portal-quote-values) .portal-metrics {
  padding-top: 5px;
  border-top: 1px solid var(--portal-line);
}

.customer-portal :is(#registration-values, #portal-quote-values) .portal-metrics > div:last-child {
  margin-top: 4px;
  border-top: 1px solid var(--portal-line);
  font-weight: 700;
}

.customer-portal :is(#registration-values, #portal-quote-values) .portal-metrics > div:last-child dd {
  color: var(--portal-orange-ink);
}

.customer-portal .registration-summary > .button {
  display: flex;
  width: 100%;
  margin-top: 12px;
}

.customer-portal .registration-summary > a {
  display: inline-block;
  padding-block: 8px;
}

.customer-portal .registration-summary .registration-back {
  display: block;
  text-align: center;
}

.customer-portal #registration-pix {
  margin: 10px 0;
  padding: 10px;
  border-radius: 8px;
  background: var(--portal-orange-light);
  font-size: .875rem;
}

.customer-portal #registration-pix small {
  color: var(--portal-muted);
}

.customer-portal .order-main :is(.portal-summary-section, .order-customer-summary > details) {
  margin: 14px 0 0;
  padding: 12px 0 0;
  border: 0;
  border-top: 1px solid var(--portal-line);
  background: transparent;
}

.customer-portal :is(.portal-status, .payment-layout-info, #files-gate) {
  padding: 8px 11px;
  border-left: 3px solid var(--portal-blue);
  border-radius: 6px;
  background: var(--portal-blue-light);
  color: #1c486e;
  font-size: .875rem;
}

.customer-portal .portal-status:empty,
.customer-portal :is(#registration-pix, #portal-files, #portal-tracking-files, #order-file-list, #portal-receipt, #order-charges):empty {
  display: none;
}

.customer-portal #order-error {
  padding: 10px 12px;
  border-left: 3px solid #a62e2e;
  background: #fff1ee;
  color: #842424;
  font-size: .9375rem;
}

.customer-portal .order-main .order-feedback {
  margin: 8px 0 0;
  padding: 8px 10px;
  border-radius: 6px;
  background: var(--portal-green-light);
  color: var(--portal-green-dark);
  font-size: .875rem;
}

.customer-portal #pro-offers {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.customer-portal #pro-offers:has(article:only-child) {
  grid-template-columns: minmax(0, 1fr);
}

.customer-portal #pro-offers > article {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 12px;
  border-color: var(--portal-line);
  border-radius: 9px;
}

.customer-portal .order-main .payment-choice-heading {
  flex-direction: row;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  cursor: pointer;
}

.customer-portal .payment-choice-heading h3 { margin: 0; }

.customer-portal :is(.pix-first, .pix-second, .pix-order-total, .payment-choice-highlight) {
  padding: 8px;
  margin: 0 0 7px;
  border-radius: 6px;
  background: var(--portal-orange-light);
  color: var(--portal-orange-ink);
  font-size: .875rem;
}

.customer-portal .pix-second {
  background: var(--portal-blue-light);
  color: #1c486e;
}

.customer-portal :is(.pix-second, .payment-choice-highlight) span {
  display: block;
  margin-top: 2px;
  color: var(--portal-ink);
}

.customer-portal .payment-choice-note,
.customer-portal .payment-choice-hint {
  font-size: .875rem;
  color: var(--portal-muted);
}

.customer-portal #pro-offers > article > .button { margin-top: auto; }

.customer-portal .order-main :is(.order-templates, .portal-file-card, .portal-upload-grid > form, .portal-link-upload) {
  min-width: 0;
  margin: 10px 0;
  padding: 12px;
  border: 1px solid var(--portal-line);
  border-radius: 9px;
  background: #fff;
}

.customer-portal .portal-upload-grid > form {
  margin: 0;
}

.customer-portal .portal-upload-grid .help { margin-top: 6px; }
.customer-portal .portal-upload-grid + .help { margin-top: 10px; }

.customer-portal input[type="file"]::file-selector-button {
  margin-right: 8px;
  padding: 4px 7px;
  border: 1px solid var(--portal-control);
  border-radius: 5px;
  background: #f4f0e9;
  color: var(--portal-ink);
  font: inherit;
  font-size: .875rem;
}

.customer-portal progress {
  max-width: 100%;
  accent-color: var(--portal-green);
}

.customer-portal .order-main summary { cursor: pointer; }

.customer-portal .portal-file-card h4 { margin: 4px 0; }
.customer-portal .portal-file-card p { overflow-wrap: anywhere; }

.customer-portal .portal-pdf {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--portal-orange-light);
  color: var(--portal-orange-ink);
  font-size: .75rem;
  font-weight: 700;
}

.customer-portal .portal-success { color: var(--portal-green-dark); }

.customer-portal .portal-notice {
  margin-bottom: var(--portal-gap);
  padding: 12px;
  border-left: 3px solid var(--portal-orange);
  border-radius: 8px;
  background: var(--portal-orange-light);
}

.customer-portal .portal-notice .portal-notice-label {
  margin-bottom: 4px;
  color: var(--portal-orange-ink);
  font-size: .8125rem;
  font-weight: 700;
}

.customer-portal #order-tracking-step {
  font-size: 1rem;
  line-height: 1.5;
}

.customer-portal #order-tracking-step h2 {
  font-size: clamp(1.2rem, 2.8vw, 1.45rem);
  line-height: 1.25;
  margin: 0 0 10px;
}

.customer-portal .production-timeline {
  margin: 0 0 12px;
}

.customer-portal #order-tracking-step .production-timeline li {
  margin: 4px 0;
  padding: 7px 10px;
}

.customer-portal .portal-timeline-item small {
  display: inline-block;
  margin-right: 8px;
  font-size: .8125rem;
}

.customer-portal .portal-timeline-item strong {
  display: block;
  font-size: .9375rem;
}

.customer-portal .step-actions {
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

.customer-portal[data-portal-step="4"] .step-actions {
  display: none;
}

.customer-portal .portal-return {
  margin-top: 10px;
  font-size: .875rem;
}

@media (max-width: 940px) {
  .customer-portal #pro-offers {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .customer-portal :is(.registration-layout, .order-customer-grid) {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-portal .purchase-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-portal .order-main :is(input:not([type="checkbox"]):not([type="radio"]), select) {
    min-height: 48px;
  }
}

@media (max-width: 480px) {
  .customer-portal .portal-workspace {
    border-radius: 14px;
  }

  .customer-portal :is(.registration-fields, #delivery-fields, .portal-upload-grid, .portal-file-grid) {
    grid-template-columns: minmax(0, 1fr);
  }

  .customer-portal .purchase-steps .portal-step-number {
    display: none;
  }
}

.customer-portal .payment-offer-help:has(+ #pro-offers:empty) { display: none; }

.customer-portal #order-file-title { margin: 10px 0; }
.customer-portal #title-files-form { margin: 12px 0; }
.customer-portal #title-file-choices { margin-bottom: 10px; }
.customer-portal #title-file-choices fieldset p { clear: both; }
