/* The review surface is always mobile-sized, including desktop browsers. */
html { background: #e8eae2; }
body {
  display: grid;
  grid-template-columns: minmax(0, 430px);
  justify-content: center;
  align-content: center;
  min-height: var(--app-viewport-height, 100dvh);
  padding: 24px 16px;
}
.sidebar, .context-panel { display: none; }
main {
  height: min(880px, calc(var(--app-viewport-height, 100dvh) - 48px));
  min-height: 0;
  width: 100%;
  border: 7px solid #30372e;
  border-radius: 35px;
  overflow: hidden;
  box-shadow: 0 28px 80px #26311d26, 0 3px 10px #26311d14;
}
header {
  flex-shrink: 0;
  min-height: 52px;
  height: auto;
  padding: 6px 14px;
  gap: 8px;
}
.header-title { display: none; }
.mobile-brand {
  display: inline;
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -1px;
}
.header-sub { font-size: 10px; }
.quiet { min-height: 44px; font-size: 11px; }
.preview-note {
  flex-shrink: 0;
  padding: 10px 20px;
  font-size: 9px;
}
#conversation {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #d9ddcf transparent;
  padding: 25px 20px 10px;
  scroll-padding: 18px;
}
#messages { width: 100%; }
.message { margin-bottom: 23px; overflow-wrap: anywhere; }
.message.is-pending { animation: pending-appear .16s ease-out; }
@keyframes pending-appear { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .message.is-pending { animation: none; } }
.typing-indicator { color: #777d70; }
.typing-indicator span { display: inline-block; animation: typing-pulse 1s steps(3, end) infinite; }
.message h1 { font-size: 37px; line-height: 1.12; }
.message p { font-size: 14px; }
.welcome-meta { gap: 12px; flex-wrap: wrap; line-height: 1.6; }
.start { width: 100%; min-height: 50px; }
.choice { min-height: 52px; padding: 15px 13px; }
.choices.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.choice small { flex-shrink: 0; }
.proposal { padding: 18px 16px; }
.proposal h3 { margin: 0 0 8px; font-size: 16px; line-height: 1.3; letter-spacing: -.2px; }
.proposal .part { padding: 4px 0; gap: 1px 6px; align-items: baseline; font-size: 12px; line-height: 1.25; }
.proposal .part > span:first-child { color: var(--muted); font-size: 10px; }
.proposal .part-name, .proposal .part small { grid-column: 1 / -1; min-width: 0; overflow-wrap: anywhere; }
.proposal .part small { color: var(--muted); font-size: 10px; line-height: 1.3; }
.proposal .part a, .editor-part-name a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 2px; }
.proposal .total { padding: 12px 0; margin-bottom: 4px; border-bottom: 1px solid var(--line); font-size: 16px; }
.proposal .note { font-size: 12px; line-height: 1.65; margin: 12px 0; }
.proposal .build-advantages { margin: 12px 0 16px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; background: color-mix(in srgb, var(--accent) 5%, #fff); }
.proposal .build-advantages h4 { margin: 0 0 6px; font-size: 13px; line-height: 1.4; font-weight: 700; letter-spacing: -.2px; }
.proposal .build-advantages ul { margin: 0; padding-left: 16px; }
.proposal .build-advantages li { margin: 0 0 6px; padding-left: 2px; font-size: 12px; line-height: 1.45; overflow-wrap: anywhere; }
.proposal .build-advantages li:last-child { margin-bottom: 0; }
.proposal .build-advantages li::marker { color: var(--accent); }
.proposal .build-advantages :is(.benefit-comparison,.benefit-detail) { margin-inline-start: -16px; padding: 8px 0 0; border-top: 1px solid var(--line); list-style: none; }
.benefit-comparison strong { display: block; margin-bottom: 2px; }
.proposal .benefit-detail :is(summary, p) { font-size: 12px; line-height: 1.45; }
.benefit-detail summary { cursor: pointer; }
.proposal .benefit-detail p { margin: 5px 0 0; }
.budget-alert { color: #9a3412; background: #fff7ed; border: 1px solid #fed7aa; border-radius: 9px; padding: 10px 12px; font-size: 12px !important; }
.part { grid-template-columns: minmax(0, 1fr) auto; }
.part strong, .total span:last-child { white-space: nowrap; }
.total { gap: 10px; font-size: 14px; }
footer {
  position: static;
  flex-shrink: 0;
  padding: 6px 12px max(8px, env(safe-area-inset-bottom));
}
input { font-size: 16px; } /* Prevent input-focus zoom in mobile Safari. */
.send:disabled { opacity: .55; }
.start { align-items: center; gap: 16px; }
.primary.start, #reset-dialog .primary { background: transparent; border-color: var(--accent); color: var(--accent-strong); }
.primary.start:hover:not(:disabled), #reset-dialog .primary:hover:not(:disabled) { background: var(--accent-soft); color: var(--accent-strong); filter: none; }
#reset-dialog .dialog-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
#reset-dialog .dialog-actions button { min-height: 44px; padding: 7px 10px; line-height: 1.25; }
#reset-dialog .reset-keep { background: var(--paper, #fff); border-color: #a9b2a7; color: var(--ink, #30382e); }
#reset-dialog .reset-keep:hover:not(:disabled) { background: #eef1ec; border-color: #7f8d7d; color: var(--ink, #30382e); }
.start > .app-icon { width: 20px; height: 20px; }
#welcome-heading { overflow-wrap: anywhere; }
.message:has(#welcome-heading:empty) .assistant-name { visibility: hidden; }
#welcome-heading:empty::before {
  content: "";
  display: block;
  width: min(100%, 11em);
  height: 3lh;
  background:
    linear-gradient(#dddeda, #dddeda) left .32lh / 78% .35lh no-repeat,
    linear-gradient(#dddeda, #dddeda) left 1.32lh / 93% .35lh no-repeat,
    linear-gradient(#dddeda, #dddeda) left 2.32lh / 72% .35lh no-repeat;
  animation: icon-loading-pulse 1.4s ease-in-out infinite alternate;
}
@media (prefers-reduced-motion: reduce) {
  .message:has(#welcome-heading:empty) .assistant-name { visibility: hidden; }
#welcome-heading:empty::before { animation: none; }
}

.send { width: 40px; height: 40px; }
#composer { align-items: center; padding: 3px 4px 3px 12px; gap: 8px; }
#answer {
  display: block;
  flex: 1;
  min-width: 0;
  height: 20px;
  max-height: 40px;
  padding: 0;
  border: 0;
  resize: none;
  overflow-y: auto;
  background: transparent;
  color: #30382b;
  font: inherit;
  font-size: 16px;
  line-height: 20px;
}
#answer::placeholder, #order-contact::placeholder {
  font-size: 13px;
  color: #646e64;
  opacity: 1;
}
@supports (field-sizing: content) {
  #answer { field-sizing: content; height: auto; min-height: 20px; }
}
#input-hint {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 4px auto 0;
  font-size: 10px;
  line-height: 1.35;
}
dialog { max-width: 390px; }
.dialog-actions { flex-wrap: wrap; }
@media (max-width: 500px), (hover: none) and (pointer: coarse) {
  html { background: #fcfcf9; overflow: hidden; }
  body {
    display: block;
    position: fixed;
    top: var(--app-viewport-top, 0px);
    left: 0;
    right: 0;
    height: var(--app-viewport-height, 100dvh);
    min-height: 0;
    padding: 0 env(safe-area-inset-right) 0 env(safe-area-inset-left);
    overflow: hidden;
  }
  main {
    height: 100%;
    min-height: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
  header { padding-top: max(6px, env(safe-area-inset-top)); }
  .keyboard-open header { min-height: 44px; padding-top: max(3px, env(safe-area-inset-top)); padding-bottom: 3px; }
  .keyboard-open #connection-status { padding-top: 4px; padding-bottom: 4px; }
  .keyboard-open footer { padding-top: 4px; padding-bottom: 4px; }
  .keyboard-open #input-hint { display: none; }
  .keyboard-open.compact-viewport header, .keyboard-open.compact-viewport #connection-status { display: none; }
  .keyboard-open.compact-viewport #conversation { padding-top: max(12px, env(safe-area-inset-top)); }
}

.brand { display: inline-flex; width: 84px; height: 84px; }
.brand-logo { display: block; width: 100%; height: 100%; border-radius: 12px; object-fit: contain; }
.mobile-brand { display: inline-flex; align-items: center; gap: 6px; width: auto; min-height: 32px; vertical-align: middle; letter-spacing: 0; }
.mobile-brand .brand-logo { flex: 0 0 26px; width: 26px; height: 26px; border-radius: 6px; }
.mobile-brand .brand-name { line-height: 1; }
@media (max-width: 360px) {
  #conversation { padding-right: 16px; padding-left: 16px; }
  .message h1 { font-size: 33px; }
  .choices.grid { grid-template-columns: 1fr; }
  .preview-note { padding: 8px 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .typing-indicator span { animation: none; }
}
@keyframes typing-pulse {
  0%, 100% { opacity: .35; }
  50% { opacity: 1; }
}

/* Inline waiting indicator: components travel from right to the case. */
.pc-loading { margin: 7px 0; min-height: 1.7em; display: grid; grid-template-columns: 9em minmax(0, 1fr); align-items: center; gap: 4px 12px; font-size: 14px; line-height: 1; }
.pc-loading-label { font-size: 12px; line-height: 1.5; color: #626e66; }
.pc-loading > .pc-loading-label:not(.pc-loading-elapsed) { min-height: 3em; display: flex; align-items: center; }
.pc-loading-elapsed { grid-column: 1 / -1; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pc-loading-scene { position: relative; width: 9em; max-width: 100%; height: 1em; overflow: hidden; }
.pc-loading-case { position: absolute; inset: 0 auto 0 0; width: 1em; height: 1em; color: #62666b; }
.pc-loading-case .app-icon, .pc-loading-part .app-icon { display: block; width: 1em; height: 1em; }
.pc-loading-part { position: absolute; top: 0; left: 0; width: 1em; height: 1em; color: #92969c; opacity: 0; animation: assembly-flight 3.5s linear infinite; animation-delay: var(--delay); }
.pc-loading-part > span { display: block; animation: assembly-blink 1.2s ease-in-out infinite; animation-delay: var(--delay); }
.pc-loading-part-0 { --delay: 0s; --slot: 2em; }
.pc-loading-part-1 { --delay: -.7s; --slot: 3.5em; }
.pc-loading-part-2 { --delay: -1.4s; --slot: 5em; }
.pc-loading-part-3 { --delay: -2.1s; --slot: 6.5em; }
.pc-loading-part-4 { --delay: -2.8s; --slot: 8em; }
@keyframes assembly-flight {
  0% { transform: translateX(8em); opacity: 0; }
  12% { opacity: .9; }
  72% { opacity: .9; }
  91%, 100% { transform: translateX(1em); opacity: 0; }
}
@keyframes assembly-blink { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .pc-loading-part, .pc-loading-part > span { animation: none; }
  .pc-loading-part { transform: translateX(var(--slot)); opacity: .65; }
}

/* Welcome actions and service status: fixed readable text, tenant accent as detail. */
.primary.start{display:flex;align-items:center;justify-content:space-between;gap:20px;width:100%;min-height:80px;padding:18px 20px;border:1px solid color-mix(in srgb,var(--accent) 35%,#d9ded8);border-radius:20px;background:#fff;color:#252d29;box-shadow:0 5px 18px #25312908;transition:border-color .2s,box-shadow .2s,transform .2s}
.primary.start .start-copy{display:flex;flex-direction:column;align-items:flex-start;gap:5px;text-align:left}
.primary.start strong{font-size:19px;line-height:1.2;font-weight:650;letter-spacing:-.3px}
.primary.start small{font-size:12px;font-weight:400;color:#69736d;line-height:1.4}
.primary.start .start-arrow{display:grid;place-items:center;width:42px;height:42px;flex-shrink:0;border-radius:50%;border:1px solid color-mix(in srgb,var(--accent) 25%,#dce1dc);background:color-mix(in srgb,var(--accent) 7%,white);color:#29342e}
.primary.start .app-icon{width:20px;height:20px}
.primary.start:hover:not(:disabled){background:#fff;color:#252d29;filter:none;border-color:color-mix(in srgb,var(--accent) 65%,#cbd3ce);box-shadow:0 7px 24px #25312912;transform:translateY(-1px)}
.primary.start:disabled{opacity:.55}
#restart.quiet{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:32px;padding:5px 8px;border:1px solid #dde2dc;border-radius:8px;background:#ffffffb3;color:#58635c;font-size:11px;font-weight:500;white-space:nowrap}
#restart.quiet:hover{background:#edf1ed;color:#26352b;border-color:#bcc9bf}
#restart .app-icon{width:15px;height:15px;flex-shrink:0}
#connection-status{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:4px 8px;padding:4px 14px}
#connection-status>span{display:inline-flex;align-items:center;gap:5px;margin:0;padding:2px 6px;border-radius:6px;font-size:10px;letter-spacing:0;line-height:1.4;background:none}
#connection-status .ai-connection{color:#376b95;background:#edf6ff;border:1px solid #d7eafb}
#connection-status .ai-connection b{font-size:10px;font-weight:750;color:#2578b9}
#connection-status .ai-connection.is-off{color:#76817c;background:#f0f2ef;border-color:#e2e6e0}
#connection-status .selection-status{color:#68756d;padding-right:0}
#connection-status .selection-status i{height:6px;width:6px;border-radius:50%;background:#a1aaa4}
#connection-status .selection-status.is-active{color:#36804e}
#connection-status .selection-status.is-active i{background:#39b965;box-shadow:0 0 0 3px #39b96512,0 0 9px #39b96565}
@media(max-width:380px){#connection-status{padding-inline:12px}#connection-status>span{font-size:9px}#restart.quiet{font-size:10px}.welcome-meta{gap:10px}}
@media(prefers-reduced-motion:reduce){.primary.start{transition:none}.primary.start:hover:not(:disabled){transform:none}}
.primary.start .start-copy strong{font-family:Inter,"Segoe UI",Arial,sans-serif}

.message .welcome-copy{font-family:"Segoe UI",Arial,sans-serif;font-size:15px;font-weight:400;line-height:1.7;letter-spacing:0;color:#626e66;max-width:36ch}
.message .assistant-label{font-family:"Segoe UI",Arial,sans-serif;font-size:12px;line-height:1.4;letter-spacing:0;text-transform:none;font-weight:400;gap:7px;color:#6c776f}
.assistant-label .assistant-name{font-family:inherit;font-size:12px;font-weight:650;letter-spacing:.1px;color:#34453a}
.assistant-label .assistant-role{font-family:inherit;font-size:12px;font-weight:400;letter-spacing:0}
.assistant-label .assistant-divider{color:#a8b1aa;margin:0 1px}
.message .welcome-copy{max-width:29ch;width:calc(100% - 24px)}
.message .welcome-copy{font-size:13px;line-height:1.65}

/* Checkout owns the available scroll area while the chat stays in place. */
main:has(:is(#order-panel, #build-editor):not([hidden])) :is(#conversation, #composer-area) { display: none; }
#build-editor.checkout-card:not([hidden]) { display: flex; flex-direction: column; margin: 6px 12px 8px; padding: 0; overflow: hidden; }
#build-editor .editor-heading { flex: none; display: flex; align-items: center; gap: 12px; padding: 4px 11px; border-bottom: 1px solid var(--line); }
#build-editor .editor-heading h2 { margin: 0; font-size: 16px; line-height: 1.25; overflow-wrap: anywhere; }
#build-editor .editor-back { flex: 0 0 auto; min-height: 38px; padding: 4px 8px; font-size: 11px; font-weight: 600; color: #1f5e8c; background: #edf6ff; border: 1px solid #c5dff6; border-radius: 8px; }
#build-editor .editor-back:hover:not(:disabled) { background: #deefff; border-color: #a8cdeb; }
#build-editor .editor-back:focus-visible { outline: 2px solid #2578b9; outline-offset: 1px; }
#build-editor :is(#editor-add, .editor-part-change) {
  border: 1px solid var(--accent-border);
  border-radius: 7px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 650;
  white-space: nowrap;
}
#build-editor :is(#editor-add, .editor-part-change):hover:not(:disabled) {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, #fff);
}
#build-editor :is(#editor-add, .editor-part-change):focus-visible { outline-offset: 1px; }
#build-editor :is(#editor-add, .editor-part-change):disabled { border-color: var(--line); background: var(--paper); color: var(--muted); }
#build-editor #editor-add { margin-inline-start: auto; flex: 0 0 auto; min-height: 34px; padding: 4px 9px; border-color: var(--accent); }
#editor-add > span { font-size: 14px; line-height: 1; vertical-align: -1px; }
#editor-add-options { gap: 6px; padding: 9px 0; }
#build-editor #editor-add-options .choice { min-height: 48px; padding: 6px 9px; font-size: 12px; }
#editor-add-status { margin: 8px 0 0; color: var(--muted); font-size: 11px; }
#editor-add-status:empty { display: none; }
#editor-draft:not([hidden]), #editor-picker:not([hidden]) { flex: 1; min-height: 0; display: flex; flex-direction: column; }
#build-editor .editor-scroll { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 0 11px; scrollbar-width: thin; scrollbar-color: #d9ddcf transparent; }
#editor-parts { list-style: none; padding: 0; margin: 0; }
#editor-parts li { padding: 4px 0; border-top: 1px solid var(--line); font-size: 12px; line-height: 1.25; }
.editor-part-title { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 1px 6px; }
.editor-part-name { grid-column: 1 / -1; min-width: 0; overflow-wrap: anywhere; }
.editor-part-category { min-width: 0; overflow-wrap: anywhere; color: var(--muted); font-size: 10px; }
.editor-part-title strong { white-space: nowrap; font-size: 12px; }
.editor-part-meta { display: flex; justify-content: space-between; align-items: center; gap: 6px; margin-top: 1px; }
.editor-part-meta > span { color: var(--muted); font-size: 10px; overflow-wrap: anywhere; }
.editor-part-controls { display: flex; align-items: center; flex: none; gap: 5px; }
.editor-part-controls .editor-quantity, #editor-price-sort { min-width: 0; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; font-size: 11px; }
.editor-part-controls .editor-quantity { min-height: 24px; padding: 1px 3px; }
.editor-fixed-quantity { color: var(--muted); font-size: 11px; white-space: nowrap; }
#editor-parts .editor-part-change { position: relative; min-height: 24px; padding: 2px 7px; }
#editor-parts .editor-part-change::before { content: ""; position: absolute; inset: -3px 0; }
#editor-status, #editor-baseline, #editor-ready, #editor-picker-status { margin: 4px 0; font-size: 11px; color: var(--muted); }
#editor-total { margin: 0; font-size: 13px; font-weight: 700; }
:is(#editor-baseline, #editor-ready) { margin: 1px 0 0; }
:is(#editor-total, #editor-baseline, #editor-ready, #editor-picker-status, #editor-quantity-status):empty { display: none; }
#editor-quantity-status { margin: 2px 0 4px; color: var(--muted); font-size: 11px; }
#build-editor #editor-quantity-retry, #build-editor .editor-quantity-limit { min-height: 22px; padding: 1px 4px; color: var(--accent-ink); font-size: 10px; }
#build-editor #editor-quantity-retry { margin-bottom: 4px; border: 1px solid var(--line); }
#build-editor .editor-quantity-limit { border: 1px solid var(--line); white-space: nowrap; }
#build-editor .editor-quantity-hint { margin: 4px 0 2px; color: var(--muted); font-size: 11px; }
.editor-issues { margin: 5px 0; padding-inline-start: 16px; color: var(--ink); font-size: 11px; }
.editor-issues li + li { margin-top: 3px; }
.editor-footer { flex: none; padding: 6px 11px max(7px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--paper); }
.editor-actions { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
#build-editor .editor-actions button { flex: 1 1 auto; width: auto; }
#build-editor .editor-actions button:not(.checkout-cta) { min-height: 33px; padding: 5px 7px; font-size: 12px; }
#editor-undo:disabled, #editor-parts button:disabled { cursor: default; opacity: .5; }
#editor-undo { border: 1px solid var(--line); }
.editor-picker-controls { flex: none; padding: 6px 11px; border-bottom: 1px solid var(--line); }
#editor-search { margin: 0 0 5px; }
#editor-search #editor-query { padding: 6px 8px; min-height: 34px; font-size: 13px; }
.editor-filter-row { display: flex; flex-wrap: wrap; gap: 1px 11px; }
.editor-filter { display: flex; align-items: center; gap: 4px; min-height: 24px; font-size: 11px; cursor: pointer; }
.editor-filter[hidden], #editor-undo[hidden], #editor-price-range[hidden] { display: none; }
.editor-filter input { width: 14px; height: 14px; margin: 0; accent-color: var(--accent); }
#editor-date-limit { color: var(--muted); font-size: 10px; white-space: nowrap; }
.editor-price-head, .editor-price-values { display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 11px; }
#editor-price-sort { min-height: 25px; padding: 2px 4px; }
.editor-price-values { margin-top: 2px; color: var(--muted); font-variant-numeric: tabular-nums; }
.editor-sliders { position: relative; height: 21px; margin: 0 1px; --range-start: 0%; --range-end: 100%; }
.editor-sliders::before { content: ""; position: absolute; inset: 9px 7px auto; height: 3px; border-radius: 4px; background: linear-gradient(to right, var(--line) var(--range-start), var(--accent) var(--range-start), var(--accent) var(--range-end), var(--line) var(--range-end)); }
#build-editor .editor-sliders input { position: absolute; inset: 0; width: 100%; height: 21px; margin: 0; padding: 0; border: 0; appearance: none; background: transparent; pointer-events: none; }
.editor-sliders input::-webkit-slider-thumb { appearance: none; width: 15px; height: 15px; border-radius: 50%; border: 1px solid var(--paper); background: var(--accent); pointer-events: auto; cursor: ew-resize; }
.editor-sliders input::-moz-range-thumb { width: 15px; height: 15px; border-radius: 50%; border: 1px solid var(--paper); background: var(--accent); pointer-events: auto; cursor: ew-resize; }
.editor-sliders input:focus-visible { outline: 1px solid var(--accent-ink); }
#editor-options { display: grid; gap: 4px; margin: 5px 0; }
.editor-option { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 6px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 8px; font-size: 12px; }
.editor-option-label, .editor-option-price { display: grid; gap: 2px; min-width: 0; }
.editor-option-label { overflow-wrap: anywhere; }
.editor-option-label a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 2px; }
.editor-option-actions { display: grid; justify-items: end; gap: 3px; }
.editor-option-price { text-align: right; white-space: nowrap; }
#build-editor .editor-option-select { min-height: 30px; padding: 2px 7px; border: 1px solid var(--line); border-radius: 6px; color: var(--accent-ink); font-size: 11px; font-weight: 600; }
#build-editor .editor-option-select:hover { background: var(--accent-soft); }
#editor-options :is(.editor-option-date,.editor-option-price small) { padding: 0; background: none; color: var(--muted); font-size: 10px; }
#build-editor .editor-badge { display: inline-block; max-width: 100%; padding: 1px 4px; margin-inline-start: 2px; border-radius: 4px; background: #edefe9; color: #515a50; font-size: 9px; font-weight: 600; line-height: 1.25; vertical-align: 1px; white-space: nowrap; }
#build-editor .editor-badge.is-compatible { background: #e6f1e8; color: #265d3c; }
#build-editor .editor-badge.is-conflict { background: #fff1e1; color: #784818; }
#build-editor #editor-more { min-height: 34px; padding: 4px 0; font-size: 11px; }
.keyboard-open #editor-picker:not([hidden]) { overflow: auto; }
.keyboard-open #editor-picker-scroll { flex: none; overflow: visible; }

.checkout-card {
  flex: 1 1 0;
  min-height: 0;
  min-width: 0;
  margin: 12px 20px;
  padding: 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scroll-padding: 16px;
  border: 1px solid var(--line, #ddd);
  border-radius: 16px;
  background: var(--paper, #fff);
}
.checkout-card[hidden] { display: none; }
.order-parts-heading { margin: 16px 0 6px; font-size: 15px; }
.checkout-card h2 { margin: 0 0 10px; font-size: 16px; line-height: 1.3; }
.checkout-card p, #order-summary { line-height: 1.55; overflow-wrap: anywhere; }
#order-summary li + li { margin-top: 6px; }
#order-summary .order-case-fans { display: block; font-size: 12px; }
#order-summary { padding-inline-start: 18px; font-size: 13px; color: #62695f; }
.checkout-totals { position: relative; border-top: 1px solid var(--line); padding-top: 4px; }
#checkout-share { flex: none; }
#order-terms { display: grid; gap: 4px; margin: 0; font-size: 13px; }
#order-terms dt { margin: 0; font-size: 12px; }
#order-terms > div:first-child { min-height: 28px; align-items: center; }
#order-terms > div { padding: 0; border: 0; display: flex; flex-wrap: wrap; gap: 2px 12px; justify-content: space-between; }
#order-terms dd { margin: 0; font-weight: 600; }
.checkout-card form { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 16px; }
.checkout-field { display: grid; gap: 6px; }
.checkout-field > label, .checkout-name-summary span { font-size: 13px; font-weight: 600; }
.checkout-name-summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.checkout-name-summary > div { display: grid; gap: 4px; overflow-wrap: anywhere; }
.checkout-card .checkout-contact-button { border: 1px solid #899183; color: var(--ink, #30382e); font-weight: 600; }
.checkout-card .checkout-contact-link { justify-self: start; padding: 6px 0; text-decoration: underline; }
.checkout-contact-status { margin: 0; font-size: 13px; }
.checkout-field[hidden], .checkout-name-summary[hidden], .checkout-card button[hidden], .checkout-contact-status:empty { display: none; }
.checkout-card input:not([type=checkbox]) {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border: 1px solid #ccd0d8;
  border-radius: 8px;
  background: #fff;
  font: inherit;
  font-size: 16px;
}
.checkout-actions { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin-top: 12px; padding: 8px 0; position: sticky; bottom: 0; background: var(--paper, #fff); }
.checkout-actions[hidden] { display: none; }
.checkout-card form[hidden], #order-calculation-note[hidden] { display: none; }
.checkout-notice { margin: 4px 0; font-size: 12px; color: #62695f; }
.checkout-actions .quiet { border: 1px solid #899183; font-weight: 600; background: #fff; color: var(--ink, #30382e); }
.checkout-card button { font-size: 14px; max-width: 100%; padding: 12px; border-radius: 8px; white-space: normal; line-height: 1.5; }
.checkout-card button.primary { width: 100%; }
.checkout-card .checkout-cta {
  justify-content: center;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--accent);
  border-radius: 13px;
  background: var(--accent-soft);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 650;
  text-align: center;
}
.checkout-card .checkout-cta:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 16%, #fff); }
.checkout-card .checkout-cta:disabled { background: #f5f6f0; border-color: var(--line); color: var(--muted); }
#order-error:empty { display: none; }
@media (max-width: 380px) {
  .checkout-card { margin: 10px 12px; padding: 16px; }
}

.pdf-share-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.pdf-share-heading :is(h2,h3) { margin: 0; }
.pdf-share-heading .pdf-share, #checkout-share .pdf-share { display: inline-grid; place-items: center; flex: none; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--ink,#30382e); cursor: pointer; }
.pdf-share:focus-visible { outline: 2px solid currentColor; }
:is(.pdf-share-status, #checkout-share-status):empty { display: none; }
:is(.pdf-share-status, #checkout-share-status):not(:empty) { display: block; margin: 4px 0 8px; }
:is(.pdf-share-status, #checkout-share-status) a { text-decoration: underline; }
:is(.pdf-share-status, #checkout-share-status) a + a { margin-inline-start: 10px; }
.order-receipt { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.order-receipt h3 { margin: 0; font-size: 19px; line-height: 1.35; }
.order-receipt .order-receipt-number { margin: 4px 0 10px; font-size: 13px; color: #62695f; }
.order-receipt .order-receipt-site { width: 100%; justify-content: center; min-height: 44px; margin-bottom: 8px; }
.order-receipt dl { margin: 14px 0; padding: 1px 10px; border-radius: 8px; background: var(--accent-soft); }
.order-receipt dl div { display: flex; justify-content: space-between; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; padding: 8px 0; }
.order-receipt dl div:first-child { border-top: 0; }
.order-receipt dt { margin: 0; color: var(--accent-strong); font-size: 13px; }
.order-receipt dd { font-size: 15px; font-weight: 700; }
.order-receipt-download { width: 100%; min-height: 46px; font-size: 15px; }
.order-receipt-download[aria-busy="true"] { cursor: progress; }
.order-receipt .order-receipt-pdf-status { margin: 8px 0 0; font-size: 13px; color: #62695f; }
.order-receipt-pdf-status:empty { display: none; }

/* The brand image arrives from the organization catalogue after the first paint. */
.loading-chip, .brand-logo[hidden] { display: none; }
.logo-loading .loading-chip {
  display: block;
  width: 100%;
  height: 100%;
  color: #92979a;
  animation: icon-loading-pulse 1.4s ease-in-out infinite alternate;
}
.logo-loading .mobile-brand .loading-chip { flex: 0 0 30px; width: 30px; height: 30px; }
.logo-loading .assistant-icon { background: #eceeed; color: #767c79; animation: icon-loading-pulse 1.4s ease-in-out infinite alternate; }
@keyframes icon-loading-pulse { from { opacity: .5; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .logo-loading .loading-chip, .logo-loading .assistant-icon { animation: none; }
}
