@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');
:root {
--wpn-font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
--wpn-bg-color: #f4f7f6;
--wpn-card-bg: #ffffff;
--wpn-text-primary: #1a202c;
--wpn-text-secondary: #4a5568;
--wpn-border-color: #e2e8f0;
--wpn-accent-primary: #ff7618;
--wpn-accent-primary-hover: #e66a15;
--wpn-accent-secondary: #2d3748;
--wpn-accent-secondary-hover: #1a202c;
--wpn-danger-color: #e53e3e;
--wpn-danger-hover: #c53030;
--wpn-success-color: #38a169;
--wpn-success-hover: #2f855a;
--wpn-radius-md: 8px;
--wpn-radius-lg: 12px;
--wpn-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -1px rgba(0, 0, 0, 0.04);
--wpn-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.07), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
}
#wpn-container {
max-width: 90vw;
width: 1200px;
margin: 40px auto;
padding: 0;
background: transparent;
font-family: var(--wpn-font-family);
color: var(--wpn-text-primary);
}
#wpn-bulk-upload-area {
border: 2px dashed var(--wpn-border-color);
border-radius: var(--wpn-radius-lg);
padding: 40px;
text-align: center;
margin-bottom: 30px;
background-color: var(--wpn-card-bg);
transition: all 0.3s ease;
box-shadow: var(--wpn-shadow);
}
#wpn-bulk-upload-area label {
cursor: pointer;
display: flex;
flex-direction: column;
align-items: center;
gap: 12px;
}
#wpn-bulk-upload-area label::before {
content: '';
display: block;
width: 48px;
height: 48px;
background-color: var(--wpn-accent-primary);
-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke-width='1.5' stroke='currentColor'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M12 16.5V9.75m0 0l-3 3m3-3l3 3m0 0l-3 3m3-3l3 3M3 16.5v2.25A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75V16.5m-18 0v-2.25A2.25 2.25 0 015.25 12h13.5A2.25 2.25 0 0121 14.25v2.25' /%3E%3C/svg%3E") no-repeat center;
mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke-width='1.5' stroke='currentColor'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M12 16.5V9.75m0 0l-3 3m3-3l3 3m0 0l-3 3m3-3l3 3M3 16.5v2.25A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75V16.5m-18 0v-2.25A2.25 2.25 0 015.25 12h13.5A2.25 2.25 0 0121 14.25v2.25' /%3E%3C/svg%3E") no-repeat center;
transition: all 0.3s ease;
}
#wpn-bulk-upload-area p {
font-size: 1.125rem;
font-weight: 600;
color: var(--wpn-text-primary);
margin: 0;
}
#wpn-bulk-upload-area span {
color: var(--wpn-text-secondary);
display: block;
margin: 0;
}
#wpn-bulk-upload-area strong {
color: var(--wpn-accent-primary);
text-decoration: none;
font-weight: 600;
}
#wpn-bulk-upload-area.dragover,
#wpn-bulk-upload-area:hover {
border-color: var(--wpn-accent-primary);
background-color: #fffaf0;
box-shadow: var(--wpn-shadow-lg);
}
#wpn-bulk-upload-area:hover label::before {
transform: scale(1.1) translateY(-2px);
}
.job-item {
background: var(--wpn-card-bg);
border: 1px solid var(--wpn-border-color);
border-radius: var(--wpn-radius-lg);
padding: 24px;
margin-bottom: 24px;
display: flex;
gap: 24px;
align-items: flex-start;
box-shadow: var(--wpn-shadow);
transition: box-shadow 0.3s ease;
}
.job-item:focus-within {
box-shadow: var(--wpn-shadow-lg);
border-color: var(--wpn-accent-primary);
}
.job-inputs {
flex: 1;
min-width: 0;
}
.form-group {
margin-bottom: 20px;
}
.form-group label {
display: block;
font-weight: 600;
margin-bottom: 8px;
font-size: 0.875rem;
color: var(--wpn-text-primary);
}
.job-item input[type="file"],
.job-item select,
.job-item input[type="number"] {
width: 100%;
padding: 12px 14px;
border: 1px solid var(--wpn-border-color);
border-radius: var(--wpn-radius-md);
box-sizing: border-box;
font-size: 0.9375rem;
background: #fdfdfd;
transition: all 0.2s ease;
color: var(--wpn-text-primary);
}
.job-item input[type="file"] {
padding: 10px;
font-size: 0.875rem;
background: var(--wpn-card-bg);
}
.job-item input[type="file"]::file-selector-button {
margin-right: 12px;
padding: 8px 12px;
border: none;
border-radius: var(--wpn-radius-md);
background: var(--wpn-accent-secondary);
color: white;
font-weight: 500;
cursor: pointer;
transition: background-color 0.2s ease;
}
.job-item input[type="file"]::file-selector-button:hover {
background: var(--wpn-accent-secondary-hover);
}
.job-item select {
appearance: none;
-webkit-appearance: none;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
background-repeat: no-repeat;
background-position: right 14px center;
background-size: 1.2em;
padding-right: 40px;
}
.job-item input[type="file"]:focus,
.job-item select:focus,
.job-item input[type="number"]:focus {
outline: none;
border-color: var(--wpn-accent-primary);
box-shadow: 0 0 0 2px var(--wpn-accent-primary-hover);
}
.dxf-preview-wrapper {
flex-shrink: 0;
width: 260px;
text-align: center;
padding: 20px;
background: var(--wpn-bg-color);
border-radius: var(--wpn-radius-md);
}
.dxf-preview-canvas {
border: 1px solid #a0aec0;
background: #ffffff;
border-radius: var(--wpn-radius-md);
width: 100%;
height: auto;
aspect-ratio: 4 / 3;
}
.dxf-info {
margin-top: 15px;
font-size: 0.8125rem;
text-align: left;
color: var(--wpn-text-secondary);
word-wrap: break-word;
}
.dxf-info p {
margin: 0 0 8px 0;
line-height: 1.5;
}
.dxf-info strong {
color: var(--wpn-text-primary);
font-weight: 600;
}
.dxf-info .dxf-filename {
font-style: italic;
color: var(--wpn-text-primary);
font-weight: 500;
}
.dxf-info .dxf-component-cost {
font-weight: 600;
color: var(--wpn-success-color);
}
.dxf-info .dxf-component-weight {
font-weight: 600;
color: var(--wpn-success-color);
}
.wpn-buttons {
display: flex;
gap: 16px;
margin-bottom: 24px;
}
#wpn-add-job,
#wpn-calculate,
.wpn-remove-job,
#wpn-add-to-cart {
padding: 14px 28px;
font-size: 1rem;
font-weight: 700;
border: none;
border-radius: var(--wpn-radius-md);
cursor: pointer;
transition: all 0.2s ease-in-out;
text-align: center;
font-family: var(--wpn-font-family);
box-shadow: var(--wpn-shadow);
}
#wpn-calculate {
flex-grow: 1;
background: var(--wpn-accent-primary);
color: white;
display: inline-flex;
align-items: center;
justify-content: center;
gap: 0.5em;
}
#wpn-calculate:hover {
background: var(--wpn-accent-primary-hover);
box-shadow: var(--wpn-shadow-lg);
transform: translateY(-1px);
}
#wpn-calculate:disabled {
background: #ccc;
cursor: not-allowed;
box-shadow: none;
transform: none;
}
#wpn-calculate.is-complete:disabled {
background: var(--wpn-accent-secondary);
color: white;
cursor: not-allowed;
opacity: 0.8;
}
#wpn-calculate.is-complete:disabled::after {
content: '✓';
font-size: 1.2em;
font-weight: 700;
line-height: 1;
}
#wpn-add-job {
background: var(--wpn-accent-secondary);
color: white;
}
#wpn-add-job:hover {
background: var(--wpn-accent-secondary-hover);
box-shadow: var(--wpn-shadow-lg);
transform: translateY(-1px);
}
.wpn-remove-wrapper {
margin-top: 20px;
text-align: right;
border-top: 1px solid var(--wpn-border-color);
padding-top: 20px;
}
.job-item:only-child .wpn-remove-wrapper {
display: none;
}
.wpn-remove-job {
padding: 8px 16px;
font-size: 0.875rem;
font-weight: 600;
color: white;
background-color: var(--wpn-danger-color);
box-shadow: none;
}
.wpn-remove-job:hover {
background-color: var(--wpn-danger-hover);
transform: translateY(-1px);
}
#wpn-progress-container {
width: 100%;
margin: 0;
padding: 22px 24px;
border-radius: calc(var(--wpn-radius-lg) - 2px);
background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(247, 249, 252, 0.96) 100%);
box-sizing: border-box;
}
.wpn-progress-header {
display: flex;
justify-content: space-between;
align-items: flex-start;
gap: 16px;
margin-bottom: 8px;
}
.wpn-progress-copy {
min-width: 0;
}
.wpn-progress-eyebrow {
margin: 0 0 6px 0;
font-size: 0.78rem;
font-weight: 700;
letter-spacing: 0.08em;
text-transform: uppercase;
color: var(--wpn-text-muted);
}
#wpn-progress-title {
margin: 0;
font-size: 1.2rem;
line-height: 1.25;
color: var(--wpn-text-primary);
}
#wpn-progress-percent {
flex: 0 0 auto;
font-size: 1.8rem;
font-weight: 800;
line-height: 1;
color: var(--wpn-accent-primary);
}
#wpn-progress-status {
font-size: 0.98rem;
color: var(--wpn-text-secondary);
font-weight: 500;
margin: 0 0 14px 0;
text-align: left;
}
#wpn-progress-bar-wrapper {
width: 100%;
height: 14px;
min-height: 14px;
box-sizing: border-box;
display: block;
background: rgba(15, 23, 42, 0.08);
border-radius: 999px;
overflow: hidden;
position: relative;
}
#wpn-progress-bar {
display: block;
width: 0;
height: 100%;
background: linear-gradient(90deg, var(--wpn-accent-primary) 0%, var(--wpn-accent-primary) 72%, rgba(255, 255, 255, 0.92) 100%);
border-radius: inherit;
transition: width 0.45s ease;
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
position: relative;
overflow: hidden;
}
#wpn-progress-bar::after {
content: '';
position: absolute;
inset: 0;
background: linear-gradient(110deg, transparent 0%, rgba(255,255,255,0.18) 35%, rgba(255,255,255,0.45) 50%, rgba(255,255,255,0.18) 65%, transparent 100%);
transform: translateX(-100%);
opacity: 0;
pointer-events: none;
}
#wpn-progress-container.has-progress #wpn-progress-bar::after {
animation: wpn-progress-sheen 1.8s linear infinite;
opacity: 1;
}
#wpn-progress-container.is-indeterminate #wpn-progress-bar {
animation: none;
}
.wpn-progress-meta {
display: flex;
justify-content: space-between;
align-items: center;
gap: 16px;
margin-top: 12px;
font-size: 0.9rem;
font-weight: 600;
color: var(--wpn-text-secondary);
flex-wrap: wrap;
}
#wpn-progress-job-meta,
#wpn-progress-time-meta {
min-width: 0;
}
@keyframes wpn-progress-sheen {
0% {
transform: translateX(-100%);
}
100% {
transform: translateX(120%);
}
}
#wpn-result {
margin-top: 0;
padding: 20px 24px;
border: 1px solid var(--wpn-border-color);
background: var(--wpn-card-bg);
border-radius: var(--wpn-radius-lg);
font-size: 1.125rem;
display: flex;
justify-content: space-between;
align-items: center;
box-shadow: var(--wpn-shadow);
}
#wpn-result.is-progress-only {
display: block !important;
padding: 0;
overflow: hidden;
border: 0;
background: transparent;
box-shadow: none;
}
#wpn-result.is-progress-only #wpn-progress-container {
margin: 0;
}
#wpn-result .price {
font-weight: 700;
font-size: 1.5rem;
color: var(--wpn-accent-primary);
}
@media (min-width: 768px) {
#wpn-add-to-cart {
padding: 12px 180px;
background: var(--wpn-success-color);
font-size: 1rem;
font-weight: 700;
color: white;
}
}
@media (max-width: 767px) {
#wpn-add-to-cart {
padding: 12px 24px;
background: var(--wpn-success-color);
font-size: 1rem;
font-weight: 700;
color: white;
}
}
#wpn-add-to-cart:hover {
background: var(--wpn-success-hover);
box-shadow: var(--wpn-shadow-lg);
transform: translateY(-1px);
}
@media (max-width: 768px) {
#wpn-container {
max-width: 100%;
margin: 10px auto;
padding: 10px;
}
.job-item {
flex-direction: column;
padding: 20px;
}
.job-inputs {
width: 100%;
}
.dxf-preview-wrapper {
width: 100%;
box-sizing: border-box;
padding: 15px;
}
.wpn-buttons {
flex-direction: column;
gap: 12px;
}
#wpn-add-job,
#wpn-calculate {
width: 100%;
padding: 16px;
font-size: 1.125rem;
}
#wpn-result {
flex-direction: column;
gap: 15px;
padding: 20px;
}
#wpn-result .price {
font-size: 1.25rem;
}
#wpn-add-to-cart {
width: 100%;
}
#wpn-bulk-upload-area {
padding: 25px;
margin-bottom: 20px;
}
}
.wpn-cart-thumbnail {
width: 100px;
height: auto;
border: 1px solid #ddd;
border-radius: 4px;
}
.wc-item-meta,
.wc-block-cart-item__product .wc-block-components-product-metadata__value {
font-size: 0.9em;
color: #555;
}
.wpn-parts-breakdown hr {
border: 0;
border-top: 1px solid #eee;
margin: 8px 0;
}
.wc-item-meta,
.wc-block-cart-item__product .wc-block-components-product-metadata__value {
font-size: 0.9em;
color: #555;
}
.wc-item-meta li.wc-item-meta-key-wpn_separator {
margin: 0.5em 0 !important;
padding: 0 !important;
border-top: 1px solid #eee;
}
.wc-item-meta li.wc-item-meta-key-wpn_separator p {
display: none;
}
.wc-block-components-product-metadata ul {
display: flex;
flex-direction: column;
gap: 1em;
}
.wpn-meta-item {
display: flex;
align-items: flex-start;
gap: 15px;
border-top: 1px solid #eee;
padding-top: 1em;
}
.wc-block-components-product-metadata ul > li:first-child.wpn-meta-item {
border-top: none;
padding-top: 0;
}
.wpn-meta-item__image {
width: 130px;
height: auto;
border: 1px solid #ddd;
border-radius: 4px;
flex-shrink: 0;
}
.page-id-16 .wpn-meta-item__image {
width: 60px;
height: auto;
border: 1px solid #ddd;
border-radius: 4px;
flex-shrink: 0;
}
.page-id-16 .wc-block-components-order-summary .wc-block-components-order-summary-item .wc-block-components-product-metadata {
font-size: 0.8em;
}
.page-id-16 .wc-block-components-product-metadata ul.wc-block-components-product-details {
gap: 1em;
}
.wpn-meta-item__details div {
line-height: 1.5;
}
.wc-item-meta,
.wc-block-cart-item__product .wc-block-components-product-metadata__value,
.wc-block-components-order-summary-item__description .wc-block-components-product-metadata {
font-size: 0.9em;
color: #555;
}
.wc-item-meta li.wc-item-meta-key-wpn_separator {
margin: 0.5em 0 !important;
padding: 0 !important;
border-top: 1px solid #eee;
}
.wc-item-meta li.wc-item-meta-key-wpn_separator p,
.wc-block-components-product-details li[class*="__wpn-separator"] span {
display: none;
}
.wc-block-components-product-details li[class*="__wpn-separator"] {
padding-top: 0.5em !important;
margin-top: 0.5em !important;
border-top: 1px solid #ddd;
}
.wc-block-components-product-metadata ul {
display: flex;
flex-direction: column;
gap: 1em;
}
.wpn-meta-item {
display: flex;
align-items: flex-start;
gap: 15px;
border-top: 1px solid #eee;
padding-top: 1em;
}
.wc-block-components-product-metadata ul > li:first-child.wpn-meta-item {
border-top: none;
padding-top: 0;
}
.wpn-meta-item__details div {
line-height: 1.5;
}
.fkcart-item-meta-content .fkcart-attr-wrap {
display: block;
margin-bottom: 4px;
}
.fkcart-item-meta-content .fkcart-attr-key {
font-weight: 600;
}
.fkcart-attr-key[data-attr-key*="wpn_separator"] {
display: none;
}
.fkcart-attr-key[data-attr-key*="wpn_separator"] + .fkcart-attr-value {
display: block;
height: 1px;
background-color: #e0e0e0;
margin: 10px 0;
padding: 0;
}
.job-item:only-child .wpn-remove-wrapper {
display: none;
}
@keyframes scanline-lr {
0% {
left: 0;
}
100% {
left: calc(100% - 3px);
}
}
.dxf-canvas-container {
position: relative;
border-radius: var(--wpn-radius-md);
overflow: hidden;
line-height: 0;
}
.dxf-canvas-container.is-scanning::after {
content: '';
position: absolute;
top: 0;
left: 0;
width: 3px;
height: 100%;
background: var(--wpn-accent-primary);
box-shadow: 0 0 10px 2px var(--wpn-accent-primary);
opacity: 0.75;
animation: scanline-lr 2.5s linear infinite alternate;
}
.wpn-material-select-wrapper {
display: flex;
align-items: center;
gap: 10px;
}
.wpn-material-select-wrapper select {
flex: 1;
}
.wpn-apply-material-to-all {
padding: 8px 12px;
font-size: 0.875rem;
font-weight: 600;
background: var(--wpn-accent-secondary);
color: white;
border: none;
border-radius: var(--wpn-radius-md);
cursor: pointer;
transition: all 0.2s ease;
flex-shrink: 0;
display: none;
}
.wpn-apply-material-to-all:hover {
background: var(--wpn-accent-secondary-hover);
transform: translateY(-1px);
}
.dxf-info .dxf-part-error {
margin-top: 8px;
color: var(--wpn-danger-color);
font-weight: 600;
font-size: 0.8125rem;
line-height: 1.5;
word-wrap: break-word;
}
.job-item.has-error {
border-color: var(--wpn-danger-color);
box-shadow: 0 0 0 2px var(--wpn-danger-color);
}

/* ... Add to bottom of file ... */

/* Result Wrapper Layout */
#wpn-result {
    flex-wrap: wrap; /* Allow wrapping */
}

.wpn-result-actions {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
}

/* Gallery Container */
.wpn-nesting-gallery {
    display: flex;
    gap: 20px;
    overflow-x: auto; /* Horizontal scroll */
    padding-bottom: 15px;
    /* Smooth scrolling */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

/* Individual Preview Cards */
.wpn-result-preview-item {
    flex: 0 0 auto; /* Don't shrink */
    width: 250px;
    background: #fff;
    border: 1px solid var(--wpn-border-color);
    border-radius: var(--wpn-radius-md);
    padding: 10px;
    text-align: center;
    box-shadow: var(--wpn-shadow);
}

.wpn-result-preview-item p {
    margin: 10px 0 0 0;
    font-weight: 600;
    color: var(--wpn-text-secondary);
    font-size: 0.9rem;
}

/* The Canvas */
.dxf-result-canvas {
    width: 100%;
    height: auto;
    aspect-ratio: 4/3;
    border: 1px solid #eee;
    background-color: #fff;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .wpn-result-actions {
        flex-direction: column;
        gap: 15px;
    }
    .wpn-result-preview-item {
        width: 200px;
    }
}

/* Diagnostics (admin-only) */
.wpn-diagnostics {
    margin-top: 20px;
    padding: 15px;
    background: #fff;
    border: 1px solid var(--wpn-border-color);
    border-radius: var(--wpn-radius-md);
    box-shadow: var(--wpn-shadow);
}

.wpn-diagnostics h4 {
    margin-top: 0;
}

.wpn-diagnostics table {
    width: 100%;
    border-collapse: collapse;
}

.wpn-diagnostics th,
.wpn-diagnostics td {
    border-bottom: 1px solid #eee;
    padding: 6px 8px;
    text-align: left;
    font-size: 0.9rem;
}

.wpn-diagnostics details {
    margin-top: 10px;
}


/* Diagnostics breakdown lists */
.wpn-diag-subrow th {
    border-bottom: none;
}
.wpn-diag-subrow td {
    border-bottom: 1px solid #eee;
    padding-top: 0;
}
.wpn-diag-breakdown {
    margin: 6px 0 0 0;
    padding-left: 18px;
    font-size: 0.85rem;
}
.wpn-diag-breakdown li {
    margin: 2px 0;
    list-style: disc;
    overflow: hidden;
}
.wpn-diag-breakdown li span:first-child {
    display: inline-block;
    max-width: 70%;
}

/* --------------------------------------------------------------------------
   Front-end modal (used for visible API errors)
   -------------------------------------------------------------------------- */
.wpn-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.wpn-modal {
    width: 100%;
    max-width: 560px;
    background: #fff;
    border-radius: var(--wpn-radius-lg);
    box-shadow: var(--wpn-shadow-lg);
    overflow: hidden;
}

.wpn-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border-bottom: 1px solid var(--wpn-border-color);
}

.wpn-modal-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--wpn-text-primary);
}

.wpn-modal-close {
    border: none;
    background: transparent;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    color: var(--wpn-text-secondary);
    padding: 0 4px;
}

.wpn-modal-close:hover {
    color: var(--wpn-text-primary);
}

.wpn-modal-body {
    padding: 16px 18px;
    color: var(--wpn-text-primary);
}

.wpn-modal-body p {
    margin: 0;
    white-space: pre-wrap;
    line-height: 1.5;
}

.wpn-modal-footer {
    padding: 14px 18px;
    border-top: 1px solid var(--wpn-border-color);
    display: flex;
    justify-content: flex-end;
}

.wpn-modal-button {
    padding: 10px 16px;
    border: none;
    border-radius: var(--wpn-radius-md);
    background: var(--wpn-accent-secondary);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
}

.wpn-modal-button:hover {
    background: var(--wpn-accent-secondary-hover);
}

/* -------------------------------------------------------------------------- */
/* Frontend form style variants                                               */
/* -------------------------------------------------------------------------- */

#wpn-job-list {
    counter-reset: wpn-part-counter;
}

#wpn-job-list .job-item {
    counter-increment: wpn-part-counter;
}

.wpn-part-badge,
.wpn-workbench-part-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 58px;
    min-height: 58px;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--wpn-accent-secondary), var(--wpn-accent-primary));
    color: #ffffff;
    font-size: 1rem;
    font-weight: 800;
    box-shadow: var(--wpn-shadow);
}

.wpn-part-badge::before,
.wpn-workbench-part-badge::before {
    content: counter(wpn-part-counter, decimal-leading-zero);
}

.wpn-form-style-classic .job-item {
    align-items: stretch;
}

.wpn-form-style-classic .dxf-preview-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.wpn-form-style-studio {
    width: min(1380px, 96vw);
}
#wpn-container.wpn-form-style-studio {
  max-width: 90vw;
  width: 1920px;
}
.wpn-form-style-studio .wpn-part-file-empty {
  font-size: 15px;
}
.wpn-form-style-studio .wpn-part-card__actions {
  display: grid;
}

.wpn-studio-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.85fr);
    gap: 28px;
    align-items: start;
}

.wpn-studio-main {
    display: grid;
    gap: 24px;
}

.wpn-form-style-studio #wpn-bulk-upload-area {
    margin-bottom: 0;
    padding: 52px 34px;
    border-radius: 28px;
    background: linear-gradient(135deg, rgba(255, 118, 24, 0.1), rgba(45, 55, 72, 0.05));
}

.wpn-form-style-studio #wpn-job-list {
    display: grid;
    gap: 24px;
}

.wpn-form-style-studio .job-item {
    padding: 0;
    margin-bottom: 0;
    overflow: hidden;
}

.wpn-studio-part-shell {
    display: grid;
    grid-template-columns: minmax(280px, 0.76fr) minmax(0, 1fr);
    align-items: stretch;
    width: 100%;
    background: var(--wpn-card-bg);
    border-radius: inherit;
    overflow: hidden;
}

.wpn-studio-preview-column {
    padding: 24px 22px;
    background: linear-gradient(180deg, rgba(45, 55, 72, 0.98), rgba(26, 32, 44, 1));
    display: flex;
    flex-direction: column;
    align-self: stretch;
    gap: 16px;
    min-height: 100%;
}

.wpn-studio-preview-column .dxf-preview-wrapper {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.06);
}

.wpn-studio-preview-column .dxf-info,
.wpn-studio-preview-column .dxf-info strong,
.wpn-studio-preview-column .dxf-info .dxf-filename {
    color: #ffffff;
}

.wpn-studio-preview-column .dxf-info .dxf-component-cost,
.wpn-studio-preview-column .dxf-info .dxf-component-weight {
    color: #9ae6b4;
}

.wpn-studio-preview-column .dxf-preview-canvas {
    border-color: rgba(255, 255, 255, 0.18);
}

.wpn-studio-main-pane {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-width: 0;
}

.wpn-studio-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 16px 18px;
    padding: 22px 24px 12px;
    align-content: start;
}

.wpn-studio-fields .form-group {
    margin-bottom: 0;
}

.wpn-studio-fields .form-group:first-child {
    grid-column: 1 / -1;
}

.wpn-studio-fields .form-group:nth-child(2) {
    grid-column: 1 / 2;
}

.wpn-studio-fields .form-group:nth-child(3) {
    grid-column: 2 / 3;
}

.wpn-form-style-studio .wpn-remove-wrapper {
    margin-top: 0;
    padding: 8px 24px 22px;
    border-top: 0;
    text-align: left;
}

.wpn-form-style-studio .wpn-buttons {
    margin-bottom: 0;
    padding: 24px 28px;
    background: var(--wpn-card-bg);
    border: 1px solid var(--wpn-border-color);
    border-radius: 24px;
    box-shadow: var(--wpn-shadow);
}

.wpn-studio-sidebar {
    position: sticky;
    top: 24px;
}

.wpn-studio-sidebar-shell {
    min-height: 160px;
    padding: 18px;
    border-radius: 24px;
    background: var(--wpn-card-bg);
    border: 1px solid var(--wpn-border-color);
    box-shadow: var(--wpn-shadow);
}

.wpn-form-style-studio #wpn-result {
    margin-top: 0;
}

.wpn-form-style-studio .wpn-result-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
}

.wpn-form-style-studio .wpn-price-display {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.wpn-form-style-studio #wpn-add-to-cart {
    width: 100%;
    padding: 14px 20px;
    white-space: nowrap;
    line-height: 1.2;
}

.wpn-form-style-workbench {
    width: min(1480px, 97vw);
}

.wpn-form-style-workbench #wpn-bulk-upload-area {
    margin-bottom: 18px;
    border-radius: 20px;
    padding: 28px 32px;
}

.wpn-workbench-toolbar {
    margin-bottom: 10px;
}

.wpn-form-style-workbench .wpn-buttons {
    margin-bottom: 0;
}

.wpn-workbench-head {
    display: grid;
    grid-template-columns: 110px 1.35fr 1.5fr 130px 1.25fr 160px;
    gap: 0;
    margin-bottom: 8px;
    padding: 0 6px;
    color: var(--wpn-text-secondary);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.wpn-form-style-workbench #wpn-job-list {
    display: grid;
    gap: 14px;
}

.wpn-form-style-workbench .job-item {
    padding: 0;
    margin-bottom: 0;
    overflow: hidden;
}

.wpn-form-style-workbench .job-inputs {
    display: grid;
    grid-template-columns: 110px 1.35fr 1.5fr 130px 1.25fr 160px;
    gap: 0;
    width: 100%;
}

.wpn-workbench-cell {
    padding: 18px 16px;
    border-right: 1px solid var(--wpn-border-color);
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.wpn-workbench-cell:last-child {
    border-right: 0;
}

.wpn-form-style-workbench .wpn-workbench-cell--part {
    align-items: flex-start;
    background: linear-gradient(180deg, rgba(255, 118, 24, 0.08), rgba(255, 118, 24, 0.02));
}

.wpn-form-style-workbench .wpn-workbench-cell .form-group {
    margin-bottom: 0;
}

.wpn-form-style-workbench .wpn-workbench-cell .form-group label {
    display: none;
}

.wpn-form-style-workbench .wpn-workbench-cell--preview .dxf-preview-wrapper {
    width: 100%;
    padding: 12px;
    background: var(--wpn-bg-color);
}

.wpn-form-style-workbench .wpn-workbench-cell--actions {
    align-items: stretch;
}

.wpn-form-style-workbench .wpn-remove-wrapper {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
    text-align: left;
}

.wpn-form-style-workbench .wpn-remove-job,
.wpn-form-style-workbench .wpn-apply-material-to-all {
    width: 100%;
}

.wpn-form-style-workbench .wpn-material-select-wrapper {
    align-items: stretch;
    flex-direction: column;
}

.wpn-form-style-workbench #wpn-result {
    margin-top: 18px;
}

.wpn-form-style-workbench .job-item.has-error {
    box-shadow: 0 0 0 2px var(--wpn-danger-color);
}

@media (max-width: 1100px) {
    .wpn-studio-layout {
        grid-template-columns: 1fr;
    }

    .wpn-studio-sidebar {
        position: static;
    }

    .wpn-workbench-head {
        display: none;
    }

    .wpn-form-style-workbench .job-inputs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wpn-form-style-workbench .wpn-workbench-cell {
        border-bottom: 1px solid var(--wpn-border-color);
    }

    .wpn-form-style-workbench .wpn-workbench-cell:nth-child(2n) {
        border-right: 0;
    }

    .wpn-form-style-workbench .wpn-workbench-cell--preview,
    .wpn-form-style-workbench .wpn-workbench-cell--actions {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .wpn-studio-part-shell {
        grid-template-columns: 1fr;
    }

    .wpn-studio-fields {
        grid-template-columns: 1fr;
    }

    .wpn-studio-fields .form-group:first-child,
    .wpn-studio-fields .form-group:nth-child(2),
    .wpn-studio-fields .form-group:nth-child(3) {
        grid-column: span 1;
    }

    .wpn-form-style-workbench .job-inputs {
        grid-template-columns: 1fr;
    }

    .wpn-form-style-workbench .wpn-workbench-cell,
    .wpn-form-style-workbench .wpn-workbench-cell:nth-child(2n) {
        border-right: 0;
    }

    .wpn-form-style-workbench .wpn-workbench-cell--preview,
    .wpn-form-style-workbench .wpn-workbench-cell--actions {
        grid-column: span 1;
    }

    .wpn-form-style-workbench .wpn-workbench-cell .form-group label {
        display: block;
    }
}

/* -------------------------------------------------------------
   Studio / Workbench refresh
   Compact Fractory-inspired rows for Studio and Workbench only.
   Classic remains untouched by relying on the original stylesheet above.
-------------------------------------------------------------- */
.wpn-form-style-studio,
.wpn-form-style-workbench {
    --wpn-shell-bg: #f8fafc;
    --wpn-shell-card: #ffffff;
    --wpn-shell-muted: #64748b;
    --wpn-shell-text: #0f172a;
    --wpn-shell-border: #d9e2ec;
    --wpn-shell-soft: #f1f5f9;
    --wpn-shell-soft-strong: #eef4fb;
    --wpn-shell-shadow: 0 16px 34px rgba(15, 23, 42, 0.06);
    --wpn-shell-radius: 18px;
    max-width: min(94vw, 1480px);
    width: 100%;
    margin: 32px auto;
    padding: 0;
}

.wpn-form-style-studio #wpn-bulk-upload-area,
.wpn-form-style-workbench #wpn-bulk-upload-area {
    background: var(--wpn-shell-card);
    border: 2px dashed #bfd5ea;
    border-radius: 24px;
    box-shadow: none;
    padding: 34px 28px;
    margin-bottom: 24px;
}

.wpn-form-style-studio #wpn-bulk-upload-area:hover,
.wpn-form-style-studio #wpn-bulk-upload-area.dragover,
.wpn-form-style-workbench #wpn-bulk-upload-area:hover,
.wpn-form-style-workbench #wpn-bulk-upload-area.dragover {
    border-color: #7aa9d8;
    background: #f7fbff;
    box-shadow: 0 0 0 4px rgba(34, 110, 196, 0.08);
}

.wpn-form-style-studio #wpn-bulk-upload-area label,
.wpn-form-style-workbench #wpn-bulk-upload-area label {
    gap: 10px;
}

.wpn-form-style-studio #wpn-bulk-upload-area p,
.wpn-form-style-workbench #wpn-bulk-upload-area p {
    font-size: 1.1rem;
    font-weight: 700;
}

.wpn-form-style-studio #wpn-bulk-upload-area span,
.wpn-form-style-workbench #wpn-bulk-upload-area span {
    font-size: 1rem;
}

.wpn-form-style-studio #wpn-bulk-upload-area strong,
.wpn-form-style-workbench #wpn-bulk-upload-area strong {
    font-size: 1rem;
}

.wpn-studio-layout-shell {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.wpn-studio-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 24px;
    align-items: start;
}

.wpn-studio-main,
.wpn-studio-sidebar,
.wpn-workbench-footer {
    min-width: 0;
}

.wpn-studio-sidebar-shell {
    position: sticky;
    top: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.wpn-workbench-footer {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 24px;
}

.wpn-parts-shell {
    background: var(--wpn-shell-card);
    border: 1px solid var(--wpn-shell-border);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--wpn-shell-shadow);
}

.wpn-parts-shell__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    padding: 24px 28px;
    border-bottom: 1px solid var(--wpn-shell-border);
    background: linear-gradient(180deg, #ffffff 0%, #fcfdff 100%);
}

.wpn-parts-shell__eyebrow,
.wpn-live-summary__eyebrow,
.wpn-result-summary-card__eyebrow,
.wpn-result-panel__eyebrow {
    margin: 0 0 6px;
    font-size: 0.75rem;
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #475569;
}

.wpn-parts-shell__title,
.wpn-live-summary__header h3,
.wpn-result-panel__header h3 {
    margin: 0;
    font-size: 2rem;
    line-height: 1.08;
    color: var(--wpn-shell-text);
}

.wpn-parts-shell__copy,
.wpn-live-summary__hint,
.wpn-result-panel__copy,
.wpn-result-summary-card__note {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.7;
    color: var(--wpn-shell-muted);
    max-width: 520px;
}

.wpn-form-style-studio #wpn-job-list,
.wpn-form-style-workbench #wpn-job-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 18px;
}

.wpn-form-style-studio #wpn-job-list .job-item,
.wpn-form-style-workbench #wpn-job-list .job-item {
    display: block;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.wpn-form-style-studio #wpn-job-list .job-item:focus-within,
.wpn-form-style-workbench #wpn-job-list .job-item:focus-within {
    box-shadow: none;
    border-color: transparent;
}

.wpn-part-card {
    background: var(--wpn-shell-card);
    border: 1px solid var(--wpn-shell-border);
    border-radius: 18px;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.wpn-part-card:hover {
    border-color: #bfd0e2;
}

.wpn-form-style-studio .job-item.is-expanded .wpn-part-card,
.wpn-form-style-workbench .job-item.is-expanded .wpn-part-card {
    box-shadow: 0 14px 26px rgba(15, 23, 42, 0.08);
}

.wpn-form-style-studio .job-item.has-error .wpn-part-card,
.wpn-form-style-workbench .job-item.has-error .wpn-part-card {
    border-color: #f1a5ad;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.08);
}

.wpn-part-card__header {
    padding: 0;
}

.wpn-part-row {
    display: grid;
    grid-template-columns: minmax(280px, 1.6fr) minmax(250px, 1.2fr) 120px 140px auto;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
}

.wpn-part-row__file,
.wpn-part-row__material,
.wpn-part-row__quantity,
.wpn-part-row__price,
.wpn-part-card__actions {
    min-width: 0;
}

.wpn-form-style-studio .dxf-upload,
.wpn-form-style-workbench .dxf-upload {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.wpn-part-file-trigger {
    display: block;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.wpn-part-file-copy {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.wpn-part-file-topline {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.wpn-part-number {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #475569;
}

.wpn-part-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 10px;
    border-radius: 999px;
    background: #eef2f7;
    color: #334155;
    font-size: 0.74rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.wpn-part-status-badge.is-empty,
.wpn-live-summary__check strong.is-pending {
    background: #eef2f7;
    color: #475569;
}

.wpn-part-status-badge.is-pending {
    background: #fff7ed;
    color: #c2410c;
}

.wpn-part-status-badge.is-ready,
.wpn-live-summary__check strong.is-ready {
    background: #ecfdf3;
    color: #15803d;
}

.wpn-part-status-badge.is-complete {
    background: #eff6ff;
    color: #1d4ed8;
}

.wpn-part-status-badge.is-error,
.wpn-live-summary__check strong.is-error {
    background: #fff1f2;
    color: #be123c;
}

.wpn-part-file-empty,
.wpn-part-file-filled {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.wpn-form-style-studio .job-item.has-file .wpn-part-file-empty,
.wpn-form-style-workbench .job-item.has-file .wpn-part-file-empty {
    display: none;
}

.wpn-form-style-studio .job-item:not(.has-file) .wpn-part-file-filled,
.wpn-form-style-workbench .job-item:not(.has-file) .wpn-part-file-filled {
    display: none;
}

.wpn-part-file-empty {
    padding: 11px 14px;
    border: 1px dashed #bfd0e2;
    border-radius: 14px;
    background: var(--wpn-shell-soft);
    width: fit-content;
    max-width: 100%;
}

.wpn-part-file-empty__icon {
    width: 18px;
    height: 18px;
    border: 2px solid var(--wpn-accent-primary);
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    color: var(--wpn-accent-primary);
    flex: 0 0 18px;
}

.wpn-part-file-empty__icon::before,
.wpn-part-file-empty__icon::after {
    content: '';
    position: absolute;
    background: currentColor;
    border-radius: 999px;
}

.wpn-part-file-empty__icon::before {
    width: 10px;
    height: 2px;
}

.wpn-part-file-empty__icon::after {
    width: 2px;
    height: 10px;
}

.wpn-part-file-empty__text {
    font-weight: 700;
    color: var(--wpn-accent-primary);
}

.wpn-part-card__thumb {
    width: 64px;
    height: 64px;
    border: 1px solid var(--wpn-shell-border);
    border-radius: 14px;
    background: var(--wpn-shell-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 0 0 64px;
}

.wpn-part-thumb-image {
    display: none;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.wpn-part-thumb-image.is-visible {
    display: block;
}

.wpn-form-style-studio .job-item.has-preview .wpn-part-thumb-placeholder,
.wpn-form-style-workbench .job-item.has-preview .wpn-part-thumb-placeholder {
    display: none;
}

.wpn-part-thumb-placeholder {
    font-size: 0.82rem;
    font-weight: 800;
    color: #64748b;
}

.wpn-part-file-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.wpn-part-file-summary {
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
    color: var(--wpn-shell-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wpn-part-subsummary {
    font-size: 0.82rem;
    color: var(--wpn-shell-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wpn-part-cell-label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
}

.wpn-form-style-studio .wpn-part-row select,
.wpn-form-style-studio .wpn-part-row input[type="number"],
.wpn-form-style-workbench .wpn-part-row select,
.wpn-form-style-workbench .wpn-part-row input[type="number"] {
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid var(--wpn-shell-border);
    background: #ffffff;
    box-sizing: border-box;
    color: var(--wpn-shell-text);
    box-shadow: none;
}

.wpn-form-style-studio .wpn-part-row select:focus,
.wpn-form-style-studio .wpn-part-row input[type="number"]:focus,
.wpn-form-style-workbench .wpn-part-row select:focus,
.wpn-form-style-workbench .wpn-part-row input[type="number"]:focus {
    outline: none;
    border-color: #7aa9d8;
    box-shadow: 0 0 0 3px rgba(34, 110, 196, 0.12);
}

.wpn-part-row__material .wpn-material-select-wrapper {
    display: flex;
    align-items: stretch;
    gap: 8px;
}

.wpn-part-row__material .wpn-material-select-wrapper select {
    min-width: 0;
}

.wpn-form-style-studio .wpn-part-row .wpn-apply-material-to-all,
.wpn-form-style-workbench .wpn-part-row .wpn-apply-material-to-all {
    flex: 0 0 auto;
    padding: 0 12px;
    height: 46px;
    border-radius: 12px;
    border: 1px solid var(--wpn-shell-border);
    background: var(--wpn-shell-soft);
    color: var(--wpn-shell-text);
    font-size: 0.82rem;
    font-weight: 800;
    box-shadow: none;
}

.wpn-form-style-studio .wpn-part-row .wpn-apply-material-to-all:hover,
.wpn-form-style-workbench .wpn-part-row .wpn-apply-material-to-all:hover {
    background: #e8f0fb;
    transform: none;
}

.wpn-part-row__price strong {
    display: inline-flex;
    align-items: center;
    min-height: 46px;
    font-size: 1.18rem;
    line-height: 1.1;
    font-weight: 800;
    color: var(--wpn-shell-text);
}

.wpn-form-style-studio .job-item.has-quote .wpn-part-row__price strong,
.wpn-form-style-workbench .job-item.has-quote .wpn-part-row__price strong {
    color: var(--wpn-accent-primary);
}

.wpn-part-card__actions {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-self: end;
}

.wpn-form-style-studio .wpn-remove-job--icon,
.wpn-form-style-workbench .wpn-remove-job--icon,
.wpn-part-toggle {
    width: 44px;
    height: 44px;
    min-width: 44px;
    padding: 0;
    border-radius: 999px;
    border: 1px solid var(--wpn-shell-border);
    background: #ffffff;
    color: #334155;
    box-shadow: none;
    position: relative;
}

.wpn-form-style-studio .wpn-remove-job--icon::before,
.wpn-form-style-workbench .wpn-remove-job--icon::before {
    content: '×';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    line-height: 1;
    font-weight: 600;
    color: #dc2626;
}

.wpn-form-style-studio .job-item:only-child .wpn-remove-job--icon,
.wpn-form-style-workbench .job-item:only-child .wpn-remove-job--icon {
    opacity: 0.55;
}

.wpn-part-toggle::before {
    content: '⌄';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    line-height: 1;
    color: #334155;
    transition: transform 0.18s ease;
}

.job-item.is-expanded .wpn-part-toggle::before {
    transform: rotate(180deg);
}

.wpn-form-style-studio .wpn-remove-job--icon:hover,
.wpn-form-style-studio .wpn-remove-job--icon:focus-visible,
.wpn-form-style-studio .wpn-part-toggle:hover,
.wpn-form-style-studio .wpn-part-toggle:focus-visible,
.wpn-form-style-workbench .wpn-remove-job--icon:hover,
.wpn-form-style-workbench .wpn-remove-job--icon:focus-visible,
.wpn-form-style-workbench .wpn-part-toggle:hover,
.wpn-form-style-workbench .wpn-part-toggle:focus-visible {
    transform: none;
    background: #f8fafc;
    box-shadow: 0 0 0 3px rgba(34, 110, 196, 0.1);
}

.wpn-part-card__body {
    border-top: 1px solid var(--wpn-shell-border);
    background: #fbfdff;
}

.wpn-part-details {
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    gap: 22px;
    padding: 22px 24px 24px;
}

.wpn-part-details__preview {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    padding: 18px;
    border: 1px solid var(--wpn-shell-border);
    border-radius: 18px;
    background: var(--wpn-bg-color);
}

.wpn-part-preview-placeholder {
    max-width: 240px;
    text-align: center;
    color: var(--wpn-shell-muted);
    font-size: 1rem;
    line-height: 1.75;
}

.wpn-part-details__preview .dxf-preview-wrapper {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
}

.wpn-part-preview-frame {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    padding: 14px;
    border: 1px solid var(--wpn-shell-border);
    border-radius: 14px;
    background: var(--wpn-shell-soft);
}

.wpn-part-details__preview .dxf-preview-canvas {
    width: 100%;
    height: auto;
    max-height: 280px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
}

.wpn-part-details__preview .dxf-part-error:empty {
    display: none;
}

.wpn-part-details__preview .dxf-part-error {
    margin: 0;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid #fecdd3;
    background: #fff1f2;
    color: #be123c;
    font-size: 0.84rem;
    line-height: 1.6;
}

.wpn-part-details__meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-content: start;
}

.wpn-part-detail-card,
.wpn-part-detail-note {
    min-width: 0;
    padding: 16px 18px;
    border: 1px solid var(--wpn-shell-border);
    border-radius: 16px;
    background: #ffffff;
}

.wpn-part-detail-card span,
.wpn-part-detail-note__label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #64748b;
}

.wpn-part-detail-card strong,
.wpn-part-detail-note strong {
    display: block;
    font-size: 1rem;
    line-height: 1.5;
    color: var(--wpn-shell-text);
    word-break: break-word;
}

.wpn-part-detail-note {
    grid-column: 1 / -1;
    background: var(--wpn-shell-soft);
}

.wpn-live-summary,
.wpn-result-summary-card,
.wpn-result-panel,
.wpn-form-style-studio #wpn-progress-container,
.wpn-form-style-workbench #wpn-progress-container {
    background: var(--wpn-shell-card);
    border: 1px solid var(--wpn-shell-border);
    border-radius: 24px;
    padding: 22px 24px;
    box-shadow: var(--wpn-shell-shadow);
}

.wpn-live-summary {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.wpn-live-summary__header {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wpn-live-summary__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.wpn-live-summary__stat,
.wpn-live-summary__check,
.wpn-live-summary__quote {
    border: 1px solid var(--wpn-shell-border);
    border-radius: 18px;
    background: #ffffff;
}

.wpn-live-summary__stat {
    padding: 16px 14px;
}

.wpn-live-summary__stat span,
.wpn-live-summary__check span,
.wpn-live-summary__quote-label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.8rem;
    font-weight: 800;
    color: #475569;
}

.wpn-live-summary__stat strong {
    font-size: 2rem;
    line-height: 1;
    color: var(--wpn-shell-text);
}

.wpn-live-summary__checks {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wpn-live-summary__check {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}

.wpn-live-summary__check span {
    margin: 0;
}

.wpn-live-summary__check strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 0.84rem;
    font-weight: 800;
    background: #eef2f7;
    color: #475569;
    min-width: 72px;
}

.wpn-live-summary__quote {
    padding: 18px 18px 20px;
}

#wpn-summary-total {
    display: block;
    font-size: 2.2rem;
    line-height: 1;
    font-weight: 800;
    color: var(--wpn-shell-text);
    margin-bottom: 12px;
}

#wpn-summary-total.is-priced {
    color: var(--wpn-accent-primary);
}

#wpn-summary-total.is-error {
    color: #dc2626;
}

#wpn-summary-total-hint {
    display: block;
    color: var(--wpn-shell-muted);
    font-size: 0.92rem;
    line-height: 1.7;
}

.wpn-form-style-studio .wpn-buttons,
.wpn-form-style-workbench .wpn-buttons {
    display: flex;
    gap: 14px;
    margin: 0;
}

.wpn-buttons--stacked {
    flex-direction: column;
}

.wpn-form-style-studio #wpn-add-job,
.wpn-form-style-studio #wpn-calculate,
.wpn-form-style-workbench #wpn-add-job,
.wpn-form-style-workbench #wpn-calculate,
.wpn-result-summary-card #wpn-add-to-cart {
    min-height: 52px;
    border-radius: 14px;
    box-shadow: none;
    font-size: 1rem;
    font-weight: 800;
    padding: 14px 20px;
}

.wpn-form-style-studio #wpn-add-job,
.wpn-form-style-workbench #wpn-add-job {
    background: #0f172a;
    color: #ffffff;
}

.wpn-form-style-studio #wpn-add-job:hover,
.wpn-form-style-workbench #wpn-add-job:hover {
    background: #1e293b;
    transform: none;
}

.wpn-form-style-studio #wpn-calculate,
.wpn-form-style-workbench #wpn-calculate {
    background: var(--wpn-accent-primary);
    color: #ffffff;
}

.wpn-form-style-studio #wpn-calculate:hover,
.wpn-form-style-workbench #wpn-calculate:hover {
    background: var(--wpn-accent-primary-hover);
    transform: none;
}

.wpn-form-style-studio .wpn-buttons--stacked #wpn-add-job,
.wpn-form-style-studio .wpn-buttons--stacked #wpn-calculate {
    width: 100%;
}

.wpn-form-style-studio #wpn-result,
.wpn-form-style-workbench #wpn-result {
    display: block;
}

.wpn-form-style-studio #wpn-result:empty,
.wpn-form-style-workbench #wpn-result:empty {
    display: none;
}

.wpn-form-style-studio #wpn-result.is-progress-only,
.wpn-form-style-workbench #wpn-result.is-progress-only {
    display: block;
}

.wpn-form-style-studio #wpn-progress-container,
.wpn-form-style-workbench #wpn-progress-container {
    margin: 0;
}

.wpn-result-summary-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.wpn-result-summary-card__price-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
}

.wpn-result-summary-card__label {
    font-size: 0.88rem;
    font-weight: 800;
    color: #475569;
}

.wpn-result-summary-card .price {
    font-size: 2.4rem;
    line-height: 1;
    font-weight: 800;
    color: var(--wpn-accent-primary);
}

.wpn-result-summary-card #wpn-add-to-cart {
    width: 100%;
    background: #0f172a;
    color: #ffffff;
}

.wpn-result-summary-card #wpn-add-to-cart:hover {
    background: #1e293b;
    transform: none;
}

.wpn-result-extra-shell {
    margin-top: 24px;
}

.wpn-result-secondary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.wpn-result-panel {
    min-width: 0;
}

.wpn-result-panel__header {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 18px;
}

.wpn-result-panel__header h3 {
    font-size: 1.5rem;
}

.wpn-form-style-studio .wpn-nesting-gallery,
.wpn-form-style-workbench .wpn-nesting-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.wpn-form-style-studio .wpn-result-preview-item,
.wpn-form-style-workbench .wpn-result-preview-item {
    padding: 14px;
    border: 1px solid var(--wpn-shell-border);
    border-radius: 16px;
    background: #ffffff;
}

.wpn-form-style-studio .dxf-result-canvas,
.wpn-form-style-workbench .dxf-result-canvas {
    width: 100%;
    height: auto;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background: #ffffff;
}

.wpn-form-style-studio .wpn-result-preview-item p,
.wpn-form-style-workbench .wpn-result-preview-item p {
    margin: 12px 0 0;
    font-weight: 700;
    color: var(--wpn-shell-text);
}

.wpn-form-style-studio .wpn-diagnostics,
.wpn-form-style-workbench .wpn-diagnostics {
    width: 100%;
}

@media (max-width: 1240px) {
    .wpn-studio-layout {
        grid-template-columns: 1fr;
    }

    .wpn-studio-sidebar-shell {
        position: static;
    }
}

@media (max-width: 1080px) {
    .wpn-part-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wpn-part-row__file,
    .wpn-part-card__actions {
        grid-column: 1 / -1;
    }

    .wpn-part-card__actions {
        justify-self: start;
    }

    .wpn-part-details {
        grid-template-columns: 1fr;
    }

    .wpn-result-secondary-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    .wpn-parts-shell__header {
        flex-direction: column;
        align-items: flex-start;
    }

    .wpn-live-summary__stats {
        grid-template-columns: 1fr;
    }

    .wpn-form-style-workbench .wpn-buttons {
        flex-direction: column;
    }

    .wpn-form-style-workbench .wpn-buttons #wpn-add-job,
    .wpn-form-style-workbench .wpn-buttons #wpn-calculate {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .wpn-form-style-studio,
    .wpn-form-style-workbench {
        max-width: 96vw;
        margin: 20px auto;
    }

    .wpn-form-style-studio #wpn-bulk-upload-area,
    .wpn-form-style-workbench #wpn-bulk-upload-area {
        padding: 26px 18px;
    }

    .wpn-form-style-studio #wpn-job-list,
    .wpn-form-style-workbench #wpn-job-list {
        padding: 14px;
    }

    .wpn-part-row {
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 14px;
    }

    .wpn-part-row__file,
    .wpn-part-row__material,
    .wpn-part-row__quantity,
    .wpn-part-row__price,
    .wpn-part-card__actions {
        grid-column: 1 / -1;
    }

    .wpn-part-row__material .wpn-material-select-wrapper {
        flex-direction: column;
    }

    .wpn-form-style-studio .wpn-part-row .wpn-apply-material-to-all,
    .wpn-form-style-workbench .wpn-part-row .wpn-apply-material-to-all {
        width: 100%;
        height: 44px;
    }

    .wpn-part-card__actions {
        justify-content: flex-start;
    }

    .wpn-part-details {
        padding: 18px 14px;
    }

    .wpn-part-details__meta {
        grid-template-columns: 1fr;
    }

    .wpn-result-summary-card__price-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .wpn-result-summary-card .price,
    #wpn-summary-total {
        font-size: 2rem;
    }
}

/* Final Workbench compact accordion refinement */
.wpn-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.wpn-form-style-workbench .wpn-parts-shell--workbench .wpn-parts-shell__header {
    align-items: flex-start;
    justify-content: flex-start;
    padding: 18px 22px;
}

.wpn-form-style-workbench .wpn-parts-shell--workbench .wpn-parts-shell__title {
    font-size: 1.7rem;
}

.wpn-form-style-workbench .wpn-parts-shell--workbench .wpn-parts-shell__copy {
    display: none !important;
}

.wpn-form-style-workbench #wpn-job-list {
    gap: 0 !important;
    padding: 0 !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item {
    position: relative;
}

.wpn-form-style-workbench #wpn-job-list .job-item + .job-item {
    border-top: 1px solid var(--wpn-border-color);
}

.wpn-form-style-workbench #wpn-job-list .job-item .wpn-part-card {
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(odd) .wpn-part-card__header {
    background: var(--wpn-card-bg);
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(even) .wpn-part-card__header {
    background: var(--wpn-card-bg);
    background: color-mix(in srgb, var(--wpn-card-bg) 94%, #f4efe7 6%);
}

.wpn-form-style-workbench .wpn-part-row {
    grid-template-columns: minmax(330px, 1.45fr) minmax(280px, 1.1fr) 94px 108px 88px;
    gap: 14px;
    padding: 14px 20px;
    align-items: center;
}

.wpn-form-style-workbench .wpn-part-file-copy {
    gap: 4px;
}

.wpn-form-style-workbench .wpn-part-file-topline {
    gap: 10px;
    margin-bottom: 2px;
}

.wpn-form-style-workbench .wpn-part-number {
    font-size: 0.75rem;
}

.wpn-form-style-workbench .wpn-part-status-badge {
    padding: 4px 10px;
    font-size: 0.72rem;
}

.wpn-form-style-workbench .wpn-part-file-empty,
.wpn-form-style-workbench .wpn-part-file-filled {
    gap: 12px;
}

.wpn-form-style-workbench .wpn-part-file-empty {
    padding: 8px 12px;
    border-radius: 12px;
}

.wpn-form-style-workbench .wpn-part-card__thumb {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    border-radius: 12px;
}

.wpn-form-style-workbench .wpn-part-file-summary {
    font-size: 0.95rem;
}

.wpn-form-style-workbench .wpn-part-subsummary {
    font-size: 0.8rem;
    line-height: 1.35;
}

.wpn-form-style-workbench .wpn-part-file-text {
    gap: 2px;
}

.wpn-form-style-workbench .wpn-inline-add-part {
    display: none;
    margin-top: 6px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--wpn-accent-primary);
    font-size: 0.82rem;
    line-height: 1.2;
    font-weight: 700;
    cursor: pointer;
    text-align: left;
}

.wpn-form-style-workbench .job-item.is-last-part .wpn-inline-add-part {
    display: inline-flex;
    align-items: center;
}

.wpn-form-style-workbench .wpn-inline-add-part:hover,
.wpn-form-style-workbench .wpn-inline-add-part:focus-visible {
    color: var(--wpn-accent-secondary);
    outline: none;
    text-decoration: underline;
}

.wpn-form-style-workbench .wpn-part-cell-label {
    margin-bottom: 4px;
    font-size: 0.68rem;
}

.wpn-form-style-workbench .wpn-part-row select,
.wpn-form-style-workbench .wpn-part-row input[type="number"] {
    min-height: 40px;
    padding: 9px 12px;
    border-radius: 10px;
}

.wpn-form-style-workbench .wpn-part-row__material .wpn-material-select-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.wpn-form-style-workbench .wpn-part-row__material .wpn-material-select-wrapper select {
    width: 100%;
}

.wpn-form-style-workbench .wpn-part-row .wpn-apply-material-to-all {
    display: none;
    height: auto;
    min-height: 0;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.74rem;
    line-height: 1.1;
    align-self: flex-start;
}

.wpn-form-style-workbench .wpn-part-row__price strong {
    min-height: 40px;
    font-size: 1.02rem;
}

.wpn-form-style-workbench .wpn-part-card__actions {
    gap: 8px;
}

.wpn-form-style-workbench .wpn-remove-job--icon,
.wpn-form-style-workbench .wpn-part-toggle {
    width: 38px;
    height: 38px;
    min-width: 38px;
}

.wpn-form-style-workbench .wpn-remove-job--icon::before {
    font-size: 1.15rem;
}

.wpn-form-style-workbench .wpn-part-toggle::before {
    font-size: 1.15rem;
}

.wpn-form-style-workbench .wpn-part-card__body {
    border-top: 1px solid var(--wpn-border-color);
    background: color-mix(in srgb, var(--wpn-card-bg) 97%, #eef3f8 3%);
}

.wpn-form-style-workbench .wpn-part-details {
    padding: 18px 20px 20px;
    gap: 18px;
}

.wpn-form-style-workbench .wpn-workbench-footer {
    margin-top: 18px;
}

.wpn-form-style-workbench .wpn-buttons--workbench-footer {
    justify-content: flex-start;
    gap: 12px;
}

.wpn-form-style-workbench .wpn-buttons--workbench-footer #wpn-calculate {
    width: auto;
    min-width: 220px;
}

@media (max-width: 1180px) {
    .wpn-form-style-workbench .wpn-part-row {
        grid-template-columns: minmax(280px, 1.4fr) minmax(220px, 1fr) 88px 96px 82px;
        gap: 12px;
    }
}

@media (max-width: 900px) {
    .wpn-form-style-workbench .wpn-part-row {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 14px 16px;
    }

    .wpn-form-style-workbench .wpn-part-card__actions {
        justify-self: start;
    }

    .wpn-form-style-workbench .wpn-part-row__material .wpn-material-select-wrapper {
        align-items: stretch;
    }

    .wpn-form-style-workbench .wpn-inline-add-part {
        margin-top: 8px;
    }

    .wpn-form-style-workbench .wpn-buttons--workbench-footer #wpn-calculate {
        width: 100%;
        min-width: 0;
    }
}

/* -------------------------------------------------------------------------- */
/* Workbench row spacing / striping refinement                                 */
/* -------------------------------------------------------------------------- */
.wpn-form-style-workbench {
    --wpn-workbench-row-odd: #ffffff;
    --wpn-workbench-row-even: #fcfcf8;
    --wpn-workbench-row-body-odd: #fbfdff;
    --wpn-workbench-row-body-even: #f7f9fb;
}

.wpn-form-style-workbench .wpn-parts-shell--workbench {
    overflow: hidden;
}

.wpn-form-style-workbench .wpn-parts-shell--workbench .wpn-parts-shell__header {
    padding: 18px 22px;
}

.wpn-form-style-workbench #wpn-job-list {
    display: block !important;
    padding: 0 !important;
    gap: 0 !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item {
    position: relative;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:not(:first-child)::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--wpn-shell-border);
    pointer-events: none;
    z-index: 3;
}

.wpn-form-style-workbench #wpn-job-list .job-item .wpn-part-card {
    position: relative;
    z-index: 1;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    overflow: visible !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(odd) .wpn-part-card__header {
    background: var(--wpn-workbench-row-odd) !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(odd) .wpn-part-card__body {
    background: var(--wpn-workbench-row-body-odd) !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(even) .wpn-part-card__header {
    background: var(--wpn-workbench-row-even) !important;
}

.wpn-form-style-workbench #wpn-job-list .job-item:nth-child(even) .wpn-part-card__body {
    background: var(--wpn-workbench-row-body-even) !important;
}

.wpn-form-style-workbench .wpn-part-row {
    grid-template-columns: minmax(300px, 1.45fr) minmax(250px, 1.08fr) 86px 96px 84px;
    gap: 12px;
    padding: 12px 18px;
    align-items: center;
}

.wpn-form-style-workbench .wpn-part-file-copy {
    gap: 3px;
}

.wpn-form-style-workbench .wpn-part-file-topline {
    gap: 8px;
    margin-bottom: 0;
}

.wpn-form-style-workbench .wpn-part-number {
    font-size: 0.74rem;
}

.wpn-form-style-workbench .wpn-part-status-badge {
    padding: 4px 9px;
    font-size: 0.7rem;
}

.wpn-form-style-workbench .wpn-part-file-empty,
.wpn-form-style-workbench .wpn-part-file-filled {
    gap: 10px;
}

.wpn-form-style-workbench .wpn-part-file-empty {
    padding: 7px 10px;
    border-radius: 11px;
}

.wpn-form-style-workbench .wpn-part-card__thumb {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: 10px;
}

.wpn-form-style-workbench .wpn-part-file-summary {
    font-size: 0.92rem;
    line-height: 1.2;
}

.wpn-form-style-workbench .wpn-part-subsummary {
    font-size: 0.78rem;
    line-height: 1.28;
}

.wpn-form-style-workbench .wpn-part-file-text {
    gap: 2px;
}

.wpn-form-style-workbench .wpn-inline-add-part {
    margin-top: 5px;
}

.wpn-form-style-workbench .wpn-part-cell-label {
    margin-bottom: 4px;
    font-size: 0.67rem;
}

.wpn-form-style-workbench .wpn-part-row select,
.wpn-form-style-workbench .wpn-part-row input[type="number"] {
    min-height: 38px;
    padding: 8px 12px;
    border-radius: 10px;
}

.wpn-form-style-workbench .wpn-part-row__material .wpn-material-select-wrapper {
    gap: 6px;
}

.wpn-form-style-workbench .wpn-part-row .wpn-apply-material-to-all {
    padding: 6px 12px;
    font-size: 0.72rem;
    line-height: 1.15;
}

.wpn-form-style-workbench .wpn-part-row__price strong {
    min-height: 38px;
    font-size: 1rem;
}

.wpn-form-style-workbench .wpn-part-card__actions {
    gap: 8px;
}

.wpn-form-style-workbench .wpn-remove-job--icon,
.wpn-form-style-workbench .wpn-part-toggle {
    width: 36px;
    height: 36px;
    min-width: 36px;
}

.wpn-form-style-workbench .wpn-part-card__body {
    border-top: 1px solid var(--wpn-shell-border) !important;
}

.wpn-form-style-workbench .wpn-part-details {
    padding: 16px 20px 18px;
    gap: 16px;
}

.wpn-form-style-workbench .wpn-workbench-footer {
    margin-top: 16px;
}

@media (max-width: 1180px) {
    .wpn-form-style-workbench .wpn-part-row {
        grid-template-columns: minmax(250px, 1.35fr) minmax(220px, 1fr) 84px 92px 80px;
        gap: 10px;
    }
}

@media (max-width: 900px) {
    .wpn-form-style-workbench #wpn-job-list .job-item:not(:first-child)::before {
        left: 14px;
        right: 14px;
    }

    .wpn-form-style-workbench .wpn-part-row {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 14px 16px;
    }

    .wpn-form-style-workbench .wpn-part-card__actions {
        justify-self: start;
    }

    .wpn-form-style-workbench .wpn-part-row__material .wpn-material-select-wrapper {
        align-items: stretch;
    }
}


/* Studio refinement: Fractory-inspired desktop layout with summary on the right */
.wpn-form-style-studio {
    --wpn-studio-border: #d9d9d9;
    --wpn-studio-muted: #7a8c96;
    --wpn-studio-surface: #ffffff;
    --wpn-studio-soft: #f8f9fb;
    --wpn-studio-track: #efefef;
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    max-width: min(100%, 1296px);
    color: #333f48;
}

.wpn-form-style-studio .wpn-studio-layout {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 430px);
    gap: 24px;
    align-items: start;
}

.wpn-form-style-studio .wpn-parts-shell,
.wpn-form-style-studio .wpn-live-summary,
.wpn-form-style-studio .wpn-result-summary-card,
.wpn-form-style-studio .wpn-result-panel,
.wpn-form-style-studio #wpn-progress-container,
.wpn-form-style-studio .wpn-studio-sidebar-shell {
    border-color: var(--wpn-studio-border);
    box-shadow: none;
}

.wpn-form-style-studio .wpn-studio-sidebar-shell {
    padding: 24px;
    border: 1px solid var(--wpn-studio-border);
    border-radius: 18px;
    background: var(--wpn-studio-surface);
    gap: 16px;
}

.wpn-form-style-studio .wpn-parts-shell {
    border-radius: 18px;
}

.wpn-form-style-studio .wpn-parts-shell__header {
    align-items: flex-start;
    padding: 24px;
    border-bottom-color: var(--wpn-studio-border);
    background: #ffffff;
}

.wpn-form-style-studio .wpn-parts-shell__eyebrow,
.wpn-form-style-studio .wpn-live-summary__eyebrow,
.wpn-form-style-studio .wpn-result-summary-card__eyebrow,
.wpn-form-style-studio .wpn-result-panel__eyebrow,
.wpn-form-style-studio .wpn-part-cell-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
    color: var(--wpn-studio-muted);
}

.wpn-form-style-studio .wpn-parts-shell__title,
.wpn-form-style-studio .wpn-live-summary__header h3,
.wpn-form-style-studio .wpn-result-panel__header h3 {
    font-size: 22px;
    line-height: 1.1;
    font-weight: 700;
    color: #333f48;
}

.wpn-form-style-studio .wpn-parts-shell__copy,
.wpn-form-style-studio .wpn-live-summary__hint,
.wpn-form-style-studio .wpn-result-panel__copy,
.wpn-form-style-studio .wpn-result-summary-card__note,
.wpn-form-style-studio #wpn-summary-total-hint {
    font-size: 14px;
    line-height: 1.5;
    color: var(--wpn-studio-muted);
}

.wpn-form-style-studio #wpn-job-list {
    gap: 8px;
    padding: 12px 16px 16px;
}

.wpn-form-style-studio #wpn-job-list .job-item + .job-item {
    border-top: 1px solid var(--wpn-studio-track);
    padding-top: 8px;
}

.wpn-form-style-studio .wpn-part-card {
    border: 0;
    border-radius: 0;
    background: transparent;
}

.wpn-form-style-studio .wpn-part-row {
    grid-template-columns: minmax(0, 1fr) 250px 90px 100px 56px;
    gap: 16px;
    padding: 10px 8px;
}

.wpn-form-style-studio .wpn-part-file-empty,
.wpn-form-style-studio .wpn-part-file-filled {
    gap: 8px;
}

.wpn-form-style-studio .wpn-part-card__thumb {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border-radius: 10px;
}

.wpn-form-style-studio .wpn-part-file-summary,
.wpn-form-style-studio .wpn-part-cost-summary,
.wpn-form-style-studio .wpn-part-detail-card strong,
.wpn-form-style-studio .wpn-part-detail-note strong {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.35;
    color: #333f48;
}

.wpn-form-style-studio .wpn-part-number,
.wpn-form-style-studio .wpn-part-subsummary,
.wpn-form-style-studio .wpn-part-status-badge,
.wpn-form-style-studio .wpn-part-detail-card span,
.wpn-form-style-studio .wpn-part-detail-note__label,
.wpn-form-style-studio .wpn-live-summary__stat span,
.wpn-form-style-studio .wpn-live-summary__check span,
.wpn-form-style-studio .wpn-live-summary__quote-label {
    font-size: 12px;
    letter-spacing: 0;
}

.wpn-form-style-studio .wpn-part-status-badge,
.wpn-form-style-studio .wpn-live-summary__check strong {
    font-weight: 600;
}

.wpn-form-style-studio .wpn-inline-add-part {
    margin-top: 2px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--wpn-accent-primary);
    font-size: 12px;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.wpn-form-style-studio .wpn-inline-add-part:hover,
.wpn-form-style-studio .wpn-inline-add-part:focus-visible {
    background: transparent;
    color: var(--wpn-accent-primary-hover);
}

.wpn-form-style-studio .wpn-remove-job--icon,
.wpn-form-style-studio .wpn-part-toggle {
    width: 36px;
    height: 36px;
    border-radius: 10px;
}

.wpn-form-style-studio .wpn-part-card__body {
    padding: 0 8px 14px;
}

.wpn-form-style-studio .wpn-part-details {
    padding: 20px;
    border: 1px solid var(--wpn-studio-border);
    border-radius: 14px;
    background: var(--wpn-studio-soft);
}

.wpn-form-style-studio .wpn-part-detail-card,
.wpn-form-style-studio .wpn-part-detail-note,
.wpn-form-style-studio .wpn-live-summary__stat,
.wpn-form-style-studio .wpn-live-summary__check,
.wpn-form-style-studio .wpn-live-summary__quote {
    border-radius: 12px;
    border-color: var(--wpn-studio-border);
}

.wpn-form-style-studio .wpn-live-summary {
    gap: 16px;
    padding: 0;
    border: 0;
    box-shadow: none;
}

.wpn-form-style-studio .wpn-live-summary__stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.wpn-form-style-studio .wpn-live-summary__stat {
    padding: 14px 12px;
}

.wpn-form-style-studio .wpn-live-summary__stat strong {
    font-size: 28px;
    line-height: 1;
    font-weight: 700;
}

.wpn-form-style-studio .wpn-live-summary__checks {
    gap: 8px;
}

.wpn-form-style-studio .wpn-live-summary__check {
    padding: 12px 14px;
}

.wpn-form-style-studio #wpn-summary-total,
.wpn-form-style-studio .wpn-result-summary-card .price {
    font-size: 34px;
    line-height: 1;
    font-weight: 700;
}

.wpn-form-style-studio .wpn-buttons {
    gap: 8px;
}

.wpn-form-style-studio #wpn-add-job,
.wpn-form-style-studio #wpn-calculate,
.wpn-form-style-studio .wpn-result-summary-card #wpn-add-to-cart {
    min-height: 48px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 700;
}

.wpn-form-style-studio #wpn-add-job {
    background: #333f48;
}

.wpn-form-style-studio #wpn-add-job:hover {
    background: #243038;
}

.wpn-form-style-studio .wpn-result-summary-card,
.wpn-form-style-studio .wpn-result-panel,
.wpn-form-style-studio #wpn-progress-container {
    padding: 24px;
    border-radius: 14px;
}

.wpn-form-style-studio #wpn-progress-container .wpn-progress-eyebrow,
.wpn-form-style-studio #wpn-progress-container #wpn-progress-status,
.wpn-form-style-studio #wpn-progress-container .wpn-progress-meta {
    font-size: 12px;
}

.wpn-form-style-studio #wpn-progress-title {
    font-size: 22px;
    line-height: 1.1;
}

@media (max-width: 1240px) {
    .wpn-form-style-studio .wpn-studio-layout {
        grid-template-columns: 1fr;
    }

    .wpn-form-style-studio .wpn-studio-sidebar-shell {
        position: static;
    }
}

@media (max-width: 900px) {
    .wpn-form-style-studio .wpn-part-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wpn-form-style-studio .wpn-part-row__file,
    .wpn-form-style-studio .wpn-part-card__actions {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .wpn-form-style-studio .wpn-studio-sidebar-shell,
    .wpn-form-style-studio .wpn-parts-shell__header,
    .wpn-form-style-studio .wpn-result-summary-card,
    .wpn-form-style-studio .wpn-result-panel,
    .wpn-form-style-studio #wpn-progress-container {
        padding: 18px;
    }

    .wpn-form-style-studio .wpn-live-summary__stats {
        grid-template-columns: 1fr;
    }

    .wpn-form-style-studio .wpn-part-row {
        grid-template-columns: 1fr;
    }
}
