.slicer-page { min-height: 100svh; background: radial-gradient(ellipse at 25% 12%, #fffaf2 0, transparent 52%), #f1efeb; -webkit-font-smoothing: antialiased; }
.slicer-header { display: flex; justify-content: space-between; align-items: center; max-width: 1440px; margin: auto; padding: 30px 114px 0 52px; }
.slicer-header { --brand-width: 134px; }
.back-home { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--muted); }
.back-home svg { width: 17px; height: 17px; }
.back-home span { color: #aba69d; }
.slicer-main { max-width: 1440px; padding: 0 114px 32px 52px; margin: auto; }
.slicer-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin: 26px 0 26px; }
.eyebrow { color: var(--muted); font-size: 12px; margin: 0 0 5px; }
.slicer-intro h1 { font-size: clamp(30px, 3vw, 43px); line-height: 1.5; margin: 0; font-weight: 760; }
.intro-copy { font-size: 13px; color: var(--muted); margin: 5px 0 0; }
.preview-label { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--muted); padding-bottom: 4px; white-space: nowrap; }
.preview-label > span { width: 5px; height: 5px; background: var(--accent-text); border-radius: 50%; }
.slicer-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 340px; direction: ltr; gap: 20px; align-items: stretch; }
.slicer-workspace > * { direction: rtl; min-width: 0; }
.model-panel, .print-panel, .estimate-panel { border-radius: 26px; box-shadow: 0 12px 38px #4d3c2410, 0 2px 6px #4d3c2404; animation: surface-rise 650ms var(--settle) both; }
.model-panel { background: linear-gradient(150deg, #ffffffb8, #faf7f1b8); display: flex; flex-direction: column; overflow: hidden; }
.model-panel [hidden] { display: none !important; }
.model-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 24px 26px 0; }
.model-heading > div, .settings-title { display: flex; align-items: center; gap: 12px; }
.slicer-page h2 { font-size: 16px; line-height: 1.7; font-weight: 650; margin: 0; }
.section-index { font-size: 12px; color: var(--accent-text); font-variant-numeric: tabular-nums; }
.model-badge { font-size: 11px; border-radius: 20px; padding: 4px 11px; background: #ebe7df; color: #665f55; }
.model-stage { position: relative; flex: 1; min-height: 310px; display: grid; place-items: center; isolation: isolate; }
.model-empty { width: min(380px, calc(100% - 44px)); text-align: center; padding-block: 12px; }
.model-empty p { margin: 12px 0 2px; color: var(--muted); font-size: .8125rem; }
.model-empty .text-button { min-height: 44px; font-size: .8125rem; }
.model-panel.is-dragging .model-stage { background: #ecd9cb88; }
#model-canvas { display: block; width: 100%; height: 100%; position: absolute; inset: 0; cursor: grab; touch-action: none; }
#model-canvas:active { cursor: grabbing; }
.stage-caption { position: absolute; top: 30px; left: 28px; display: grid; color: #8b8377; pointer-events: none; text-align: left; direction: ltr; }
.stage-caption > span { font-size: 12px; letter-spacing: 3px; }
.stage-caption small { font-size: 10px; margin-top: 2px; }
.viewer-tools { position: absolute; left: 22px; bottom: 25px; display: flex; gap: 3px; direction: ltr; padding: 3px; background: #ffffffb8; backdrop-filter: blur(12px); border-radius: 22px; box-shadow: 0 8px 26px #4d3c240e; }
.viewer-tools button { width: 38px; height: 38px; border: 0; background: transparent; display: grid; place-items: center; border-radius: 50%; transition: background .35s, transform .35s; }
.viewer-tools button:hover { background: var(--accent-soft); transform: translateY(-1px); }
.viewer-tools svg { width: 17px; height: 17px; }
#viewer-hint { position: absolute; right: 26px; bottom: 28px; font-size: 11px; color: #6d665c; margin: 0; pointer-events: none; }
.model-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 21px 26px 12px; background: #ffffff7d; }
.model-meta > div { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.model-meta span, .model-meta small { font-size: 11px; color: var(--muted); }
.model-meta strong { font-size: 14px; font-weight: 550; margin-top: 5px; max-width: 100%; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.text-button { padding: 4px 0; border: 0; background: transparent; color: var(--accent-text); font-size: 11px; text-align: start; }
.text-button:hover { color: #242321; }
.add-model { grid-column: 1 / -1; justify-self: start; display: inline-flex; align-items: center; gap: 7px; min-height: 44px; font-size: .8125rem; }
.add-model svg { width: 16px; height: 16px; }
.unit-note { margin: 0; padding: 0 26px 18px; background: #ffffff7d; color: #736b61; font-size: 10px; }
.print-panel { padding: 24px; background: #ffffffc2; backdrop-filter: blur(18px); animation-delay: 80ms; }
.upload-button { width: 100%; border: 0; display: flex; align-items: center; gap: 10px; padding: 14px 12px; margin-top: 19px; background: #eeebe5; border-radius: 17px; text-align: right; transition: background 400ms; }
.upload-button:hover, .is-dragging .upload-button { background: var(--accent-soft); }
.upload-button strong { display: block; font-size: 12px; font-weight: 600; }
.upload-button small { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.upload-icon { color: var(--accent-text); }
.upload-button .upload-arrow { width: 15px; height: 15px; margin-inline-start: auto; }
.file-status { color: var(--muted); font-size: 12px; min-height: 18px; margin: 6px 26px 18px; overflow-wrap: anywhere; }
.file-status:empty { margin-block: 0; }
.file-status[data-error] { color: var(--accent-text); }
.print-panel fieldset { border: 0; padding: 0; margin: 0 0 19px; min-width: 0; }
.print-panel legend, .infill-control > label, .quantity-control > label { font-size: 12px; font-weight: 600; margin-bottom: 9px; padding: 0; }
.print-panel legend small { color: var(--muted); font-weight: 400; font-size: 10px; margin-inline-start: 8px; }
.material-options, .quality-options { display: flex; gap: 5px; background: #eeece7; border-radius: 13px; padding: 4px; }
.material-options label, .quality-options label { flex: 1; min-width: 0; position: relative; cursor: pointer; }
.material-options input, .quality-options input, .color-options input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.material-options label > span, .quality-options label > span { min-height: 40px; display: flex; justify-content: center; align-items: center; border-radius: 10px; font-size: 12px; transition: background 350ms, box-shadow 350ms; }
.material-options input:checked + span, .quality-options input:checked + span { background: #fff; box-shadow: 0 3px 10px #4d3c2410; color: var(--accent-text); }
.print-panel input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 3px; }
.control-hint { font-size: 10px; color: var(--muted); margin: 7px 0 0; min-height: 17px; }
.quality-options label > span { flex-direction: column; padding: 7px 2px; gap: 1px; }
.quality-options strong { font-size: 11px; font-weight: 550; }
.quality-options small { font-size: 10px; direction: ltr; }
.infill-control { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 17px; }
.infill-control output { text-align: left; font-size: 12px; color: var(--accent-text); font-variant-numeric: tabular-nums; }
.infill-control input { grid-column: 1 / -1; width: 100%; margin: 0; height: 28px; accent-color: var(--accent-text); direction: rtl; cursor: pointer; }
.infill-control > span { font-size: 10px; color: var(--muted); }
.infill-control > span:last-child { text-align: left; }
.compact-settings { display: flex; justify-content: space-between; gap: 12px; }
.compact-settings fieldset { margin: 0; }
.color-options { display: flex; gap: 3px; }
.color-options label { position: relative; width: 34px; height: 38px; display: grid; place-items: center; cursor: pointer; }
.color-options label > span { background: var(--swatch); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; }
.color-options input:checked + span::after { content: ''; width: 7px; height: 7px; background: #fff; border-radius: 50%; box-shadow: 0 1px 3px #0003; }
.quantity-control > label { display: block; }
.quantity-control > div { display: flex; direction: ltr; background: #f0ede7; border-radius: 12px; }
.quantity-control button { width: 36px; height: 38px; border: 0; background: transparent; border-radius: 12px; font-size: 18px; }
.quantity-control button:hover { background: var(--accent-soft); }
.quantity-control input { border: 0; width: 37px; padding: 0; background: transparent; text-align: center; font-size: 14px; appearance: textfield; }
.quantity-control input::-webkit-inner-spin-button { appearance: none; }
.settings-note { font-size: 10px; color: #70695f; margin: 16px 0 0; }
.estimate-panel { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; padding: 23px 26px; background: #ffffffa8; animation-delay: 150ms; }
.estimate-copy { display: flex; align-items: baseline; gap: 14px; flex: 1; }
.estimate-copy p { font-size: 11px; color: var(--muted); margin: 3px 0 0; }
.estimate-metrics { display: flex; gap: 34px; }
.estimate-metrics > div { display: flex; flex-direction: column; gap: 4px; }
.estimate-metrics span { font-size: 10px; color: var(--muted); }
.estimate-metrics strong { font-size: 22px; font-weight: 500; }
.estimate-metrics small { font-size: 11px; font-weight: 400; color: var(--muted); }
.continue-button { border: 0; padding: 15px 21px; border-radius: 16px; background: #292724; color: #fff; display: flex; align-items: center; justify-content: center; gap: 20px; font-size: 13px; transition: background 400ms, transform 400ms; }
.continue-button:not(:disabled):hover { background: var(--accent-text); transform: translateY(-2px); }
.continue-button:disabled { background: #ece7df; color: #686057; cursor: default; }
.continue-button svg { width: 18px; height: 18px; }
.settings-help { margin-top: 14px; padding: 9px 14px; min-height: 44px; gap: 9px; }
.slicer-support { display: flex; align-items: center; min-height: 44px; gap: 7px; margin: 7px 0; font-size: .8125rem; }
.slicer-support input { accent-color: var(--accent); }
.estimate-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.estimate-disclosure { flex-basis: 100%; margin: 0; color: var(--muted); font-size: .75rem; }
.slicer-footnote { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; font-size: 10px; color: #70695f; padding: 18px 4px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.is-dragging .model-panel { box-shadow: 0 12px 45px #c67b3b28; }
@media (max-width: 1080px) {
  .slicer-header { padding-left: 30px; padding-right: 92px; }
  .slicer-main { padding-left: 30px; padding-right: 92px; }
  .slicer-workspace { grid-template-columns: minmax(0, 1fr) 300px; gap: 16px; }
  .print-panel { padding: 20px; }
  .estimate-panel { gap: 20px; flex-wrap: wrap; }
  .estimate-copy { min-width: 230px; }
  #viewer-hint { bottom: 80px; right: 22px; }
}
@media (max-width: 820px) {
  .slicer-workspace { grid-template-columns: 1fr; }
  .model-stage { min-height: 360px; }
  .model-panel { min-height: 535px; }
  .print-panel { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; }
  .settings-title, .upload-button, .file-status, .settings-note { grid-column: 1 / -1; }
  .upload-button, .settings-note { margin-top: 0; }
  .file-status { margin-top: -12px; margin-bottom: 0; }
  .print-panel fieldset { margin-bottom: 0; }
  .infill-control { align-content: start; margin-bottom: 0; }
  .compact-settings { flex-wrap: wrap; }
  .preview-label { display: none; }
}
@media (max-width: 680px) {
  .slicer-header { padding: 24px 20px 0; }
  .back-home { font-size: 10px; gap: 7px; }
  .back-home svg { display: none; }
  .slicer-main { padding: 0 16px 105px; }
  .slicer-intro { margin: 28px 5px 22px; }
  .slicer-intro h1 { font-size: 32px; }
  .intro-copy { font-size: 12px; max-width: 30ch; }
  .model-heading { padding: 20px 18px 0; }
  .slicer-page h2 { font-size: 14px; }
  .model-heading > div { gap: 8px; }
  .model-badge { font-size: 10px; }
  .model-stage { min-height: 280px; }
  .model-panel { min-height: 0; }
  .stage-caption { top: 22px; left: 20px; }
  .viewer-tools { left: 18px; bottom: 18px; }
  .viewer-tools button { width: 42px; height: 42px; }
  #viewer-hint { right: 20px; bottom: 80px; font-size: 10px; background: #faf8f2d9; border-radius: 16px; padding: 3px 8px; }
  .model-meta { padding: 18px 18px 10px; gap: 14px; }
  .model-meta strong { font-size: 12px; }
  .unit-note { padding: 0 18px 16px; }
  .print-panel { display: block; padding: 22px; }
  .upload-button { margin-top: 18px; }
  .file-status { margin-inline: 18px; }
  .print-panel fieldset { margin-bottom: 20px; }
  .infill-control { margin-bottom: 20px; }
  .compact-settings fieldset { margin-bottom: 0; }
  .settings-note { margin-top: 16px; }
  .material-options label > span { min-height: 44px; }
  .color-options label { min-width: 40px; min-height: 44px; }
  .quantity-control button { width: 40px; height: 44px; }
  .estimate-panel { padding: 22px; gap: 20px; }
  .estimate-copy { min-width: 0; flex-basis: 100%; }
  .estimate-metrics { width: 100%; justify-content: space-between; padding-inline-start: 30px; }
  .continue-button { width: 100%; }
  .estimate-actions { width: 100%; }
  .slicer-footnote { padding-inline: 8px; }
}
