.order-page { padding: 64px 0 88px; }
.order-intro { max-width: 720px; margin-bottom: 30px; }
.order-intro h1 { margin: 0 0 14px; }
.order-intro p { margin: 0; color: var(--brand-muted); font-size: .94rem; }
.order-progress { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 22px; }
.progress-step { display: flex; align-items: center; gap: 9px; min-height: 45px; padding: 8px 12px; border: 1px solid var(--brand-border); border-radius: var(--radius-control); background: rgba(255, 255, 255, .52); color: var(--brand-muted); font-size: .76rem; font-weight: 700; text-decoration: none; }
.progress-step span { display: grid; width: 25px; height: 25px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: #eeece8; color: var(--brand-muted); font-size: .68rem; }
.progress-step:hover { border-color: var(--brand-coral); }
.order-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
.order-layout > #message { grid-column: 1 / -1; }
.order-form { display: grid; gap: 0; min-width: 0; padding: 26px; }
.order-section { min-width: 0; margin: 0; padding: 27px 0; border: 0; border-top: 1px solid var(--brand-border); }
.order-section:first-child { padding-top: 0; border-top: 0; }
.section-legend { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 7px; font-size: 1.14rem; font-weight: 800; letter-spacing: -.035em; }
.section-legend small { color: var(--brand-coral); font-size: .7rem; font-weight: 750; letter-spacing: .04em; }
.order-section > .field-hint { margin: 0 0 17px; }
.plan-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.plan-card { display: grid; grid-template-columns: 22px 1fr auto; grid-template-rows: auto auto; gap: 5px 9px; align-items: center; padding: 18px; cursor: pointer; }
.plan-card input { grid-row: 1 / 3; margin: 0; }
.plan-card strong { font-size: .99rem; }
.plan-card b { grid-column: 2; font-size: 1.22rem; letter-spacing: -.04em; }
.plan-card small { grid-column: 3; grid-row: 1 / 3; align-self: center; color: var(--brand-muted); font-size: .75rem; white-space: nowrap; }
.plan-card::after { content: ""; position: absolute; top: 13px; right: 13px; display: grid; width: 22px; height: 22px; place-items: center; border-radius: 50%; background: var(--brand-coral); color: var(--brand-ink); font-size: .78rem; opacity: 0; transform: scale(.75); transition: opacity .18s ease, transform .18s ease; }
.plan-card.is-selected::after { content: "✓"; opacity: 1; transform: scale(1); }
.reference-styles-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.reference-style-card { display: grid; gap: 8px; padding: 9px; cursor: pointer; }
.reference-style-card input { position: absolute; top: 12px; left: 12px; z-index: 1; width: 20px; margin: 0; }
.reference-style-card img { width: 100%; height: clamp(260px, 28vw, 360px); aspect-ratio: 3 / 4; object-fit: contain; object-position: center; background: #f2efeb; border-radius: 10px; }
.reference-style-card strong { padding: 0 3px; font-size: .88rem; line-height: 1.45; }
.reference-style-card small { padding: 0 3px 3px; color: var(--brand-muted); font-size: .74rem; font-weight: 400; line-height: 1.55; }
.reference-style-card .selection-badge { position: absolute; top: 10px; right: 10px; padding: 5px 8px; border-radius: var(--radius-pill); background: var(--brand-coral); color: var(--brand-ink); font-size: .67rem; font-weight: 800; opacity: 0; transform: translateY(-3px); transition: opacity .18s ease, transform .18s ease; }
.reference-style-card.is-selected .selection-badge { opacity: 1; transform: translateY(0); }
.upload-zone { display: grid; min-height: 180px; place-items: center; padding: 24px; border: 1px dashed var(--brand-coral); border-radius: var(--radius-md); background: #fffaf6; text-align: center; cursor: pointer; }
.upload-zone:hover { background: var(--brand-coral-soft); }
.upload-zone strong { display: block; margin-bottom: 5px; font-size: 1rem; }
.upload-zone p { margin: 0; color: var(--brand-muted); font-size: .82rem; }
.upload-zone small { display: block; margin-top: 11px; color: var(--brand-muted); font-size: .73rem; }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.file-list { display: grid; gap: 8px; margin-top: 13px; }
.file-item { display: grid; grid-template-columns: 45px 1fr auto; gap: 11px; align-items: center; padding: 9px; border: 1px solid var(--brand-border); border-radius: var(--radius-control); background: var(--brand-surface); }
.file-item img, .file-placeholder { width: 45px; height: 55px; object-fit: cover; border-radius: 7px; background: var(--brand-coral-soft); }
.file-placeholder { display: grid; place-items: center; color: #b95046; font-size: .62rem; text-align: center; }
.file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .81rem; }
.file-meta { margin-top: 3px; color: var(--brand-muted); font-size: .7rem; }
.file-remove { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--brand-border); border-radius: 10px; background: #fff; color: var(--brand-muted); cursor: pointer; }
.customer-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.field-label { gap: 7px; }
.required-mark { color: var(--brand-coral); font-size: .7rem; }
.field-error { min-height: 0; margin: 0; color: #b4433b; font-size: .76rem; font-weight: 500; }
.field-error:empty { display: none; }
.field-label.field-has-error input, .field-label.field-has-error textarea { border-color: #c3564c; box-shadow: 0 0 0 3px rgba(195, 86, 76, .12); }
[data-field="files"].field-has-error .upload-zone { border-color: #c3564c; box-shadow: 0 0 0 3px rgba(195, 86, 76, .12); }
.upload-zone.is-dragging { border-color: var(--brand-coral); background: var(--brand-coral-soft); }
.intake-notice { margin: 20px 0 0; padding: 12px 16px; border: 1px solid rgba(195, 86, 76, .28); border-radius: var(--radius-sm); background: rgba(255, 236, 231, .72); color: #9f463e; font-size: .88rem; font-weight: 700; }
.terms-row { display: flex; align-items: flex-start; gap: 9px; font-size: .82rem; font-weight: 400; }
.terms-row input { flex: 0 0 auto; margin-top: 2px; }
.order-legal-links { margin: 12px 0 0; font-size: .8rem; }
.order-legal-links a { color: var(--brand-muted); }
.order-actions { display: grid; gap: 14px; margin-top: 23px; }
.order-actions button { width: 100%; }
.order-message { margin: 18px 0 0; font-size: .88rem; line-height: 1.75; }
.order-message a { font-weight: 750; }
.order-summary { position: sticky; top: 18px; padding: 21px; box-shadow: var(--brand-shadow); }
.mobile-order-summary { display: none; }
.summary-kicker { margin: 0 0 5px; color: var(--brand-coral); font-size: .7rem; font-weight: 800; letter-spacing: .12em; }
.order-summary h2 { margin: 0 0 19px; font-size: 1.15rem; }
.summary-empty { margin: 0; color: var(--brand-muted); font-size: .83rem; }
.summary-list { display: grid; gap: 14px; margin: 0; }
.summary-list div { display: grid; gap: 4px; }
.summary-list dt { color: var(--brand-muted); font-size: .72rem; }
.summary-list dd { margin: 0; font-size: .88rem; font-weight: 700; line-height: 1.45; }
.summary-list a { color: #a94b43; text-decoration: underline; text-underline-offset: 2px; }
.order-side-note { margin: 13px 0 0; color: var(--brand-muted); font-size: .72rem; line-height: 1.65; }
.order-success { padding: 30px; text-align: center; }
.order-success strong { display: block; margin: 7px 0; font-size: 1.5rem; }
.order-success .button { margin-top: 18px; }
.pending-order { display: grid; gap: 8px; padding: 21px; border-radius: var(--radius-sm); background: var(--brand-mint); color: #315d4e; }
.pending-order strong { font-size: .98rem; }
.pending-order-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 6px; }
.pending-order-actions .button { margin-top: 0; }

@media (max-width: 1180px) {
  .reference-styles-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
}
@media (max-width: 900px) {
  .order-layout { grid-template-columns: 1fr; }
  .order-summary { position: static; grid-row: 2; }
  .reference-styles-grid {
    display: flex;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    gap: 12px;
    padding: 2px 2px 11px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }
  .reference-style-card {
    flex: 0 0 min(72vw, 300px);
    scroll-snap-align: start;
  }
  .reference-style-card img {
    height: clamp(220px, 48vw, 280px);
    aspect-ratio: auto;
    object-fit: contain;
    object-position: center;
    background: #f2efeb;
  }
}
@media (max-width: 700px) {
  .order-page { padding: 47px 0 62px; }
  .order-progress { grid-template-columns: repeat(4, 1fr); gap: 5px; }
  .progress-step { justify-content: center; padding: 7px 4px; }
  .progress-step span { width: 23px; height: 23px; }
  .progress-step strong { display: none; }
  .order-form { padding: 20px; }
  .order-layout > #order-summary { display: none; }
  .mobile-order-summary { display: block; margin-bottom: 23px; box-shadow: none; }
  .order-section { padding: 23px 0; }
  .plan-options, .customer-fields { grid-template-columns: 1fr; }
  .reference-styles-grid {
    display: flex;
    width: calc(100% + 40px);
    max-width: calc(100% + 40px);
    min-width: 0;
    gap: 12px;
    margin-inline: -20px;
    padding: 2px 20px 11px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }
  .reference-style-card {
    flex: 0 0 min(78vw, 300px);
    scroll-snap-align: start;
  }
  .reference-style-card img {
    height: clamp(220px, 72vw, 280px);
    aspect-ratio: auto;
    object-fit: contain;
    object-position: center;
    background: #f2efeb;
  }
  .reference-style-card strong { font-size: .84rem; }
  .reference-style-card small {
    display: -webkit-box;
    overflow: hidden;
    padding-bottom: 3px;
    font-size: .72rem;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }
  .reference-style-card.is-selected { box-shadow: 0 0 0 3px var(--brand-coral-soft), 0 10px 24px rgba(23, 25, 35, .1); }
}
