.template-admin-list { display: grid; gap: 10px; }
.template-admin-card { padding: 15px; display: grid; grid-template-columns: auto 1fr auto; gap: 13px; align-items: center; border: 1px solid var(--line); border-radius: 13px; }
.template-admin-shape { width: 45px; height: 62px; border: 2px solid #8eadde; background: #f2f6fc; }
.template-admin-card strong, .template-admin-card small { display: block; }
.template-admin-card small { margin-top: 4px; color: var(--muted); }
.template-admin-card button { border: 0; color: var(--danger); background: transparent; font-weight: 700; }
.order-buttons { display: flex; gap: 4px; }
.product-node-row { display: flex; gap: 5px; align-items: center; }
.product-node-row .product-node { flex: 1; min-width: 0; }
.order-buttons button { width: 30px; height: 30px; padding: 0; border: 1px solid #cbd8ea; border-radius: 8px; color: var(--blue); background: #fff; font-size: 16px; font-weight: 900; }
.order-buttons button:disabled { color: #aeb8c7; background: #f1f3f6; cursor: not-allowed; }
.template-card-actions { align-self: stretch; display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 12px; }
.template-admin-card .delete-template-button { color: var(--danger); }
.product-photo-editor,.template-photo-editor { padding: 12px; display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: 12px; background: #f7faff; }
.product-photo-editor img,.template-photo-editor img,.photo-placeholder { width: 82px; height: 82px; object-fit: contain; border-radius: 10px; background: #eaf2ff; }
.photo-placeholder { display: grid; place-items: center; padding: 8px; color: var(--muted); text-align: center; font-size: 9px; }
.product-photo-editor small { display: block; margin-top: 4px; color: var(--muted); }
.shape-reference-list { display: grid; grid-template-columns: repeat(auto-fit,minmax(230px,1fr)); gap: 10px; }
.shape-reference-card { padding: 12px; display: grid; grid-template-columns: auto 1fr auto; gap: 11px; align-items: center; border: 1px solid var(--line); border-radius: 12px; background: #f7faff; }
.shape-reference-card img,.shape-reference-placeholder { width: 68px; height: 68px; object-fit: contain; border: 2px solid #9cb8e1; border-radius: 9px; background: #eaf2ff; }
.shape-reference-card strong,.shape-reference-card small { display: block; }
.shape-reference-card small { margin: 3px 0 7px; color: var(--muted); font-size: 10px; }
.shape-reference-card label span { font-size: 9px; }
.shape-reference-card input { padding: 7px; font-size: 10px; }
.custom-shipping-editor { padding: 12px; display: grid; grid-template-columns: auto repeat(4,1fr) auto; gap: 9px; align-items: end; border: 1px solid var(--line); border-radius: 12px; background: #f7faff; }
.custom-shipping-editor > strong { align-self: center; color: var(--navy); font-size: 12px; }
.custom-shipping-editor .toggle-row { padding: 10px; }
.custom-packaging-editor,.custom-size-rules-editor { grid-template-columns: repeat(4,minmax(100px,1fr)); }
.custom-packaging-editor > strong,.custom-size-rules-editor > strong { grid-column: 1/-1; padding-bottom: 2px; }
.custom-packaging-editor > label:not(.toggle-row),.custom-size-rules-editor > label { min-width: 0; display: grid; align-content: end; gap: 5px; }
.custom-packaging-editor > label:not(.toggle-row) span,.custom-size-rules-editor > label span { min-height: 26px; display: flex; align-items: flex-end; color: var(--muted); font-size: 10px; font-weight: 800; line-height: 1.2; }
.custom-packaging-editor input[type="number"],.custom-size-rules-editor input[type="number"],.custom-size-rules-editor select { width: 100%; min-width: 0; min-height: 42px; padding: 8px 10px; }
.custom-packaging-editor > .toggle-row { grid-column: span 2; min-height: 42px; }
@media (max-width: 900px) { .custom-shipping-editor { grid-template-columns: repeat(2,1fr); } }
.template-admin-card.template-is-hidden { border-color: #e0e3e8; background: #f6f7f9; opacity: .78; }
.template-visibility-toggle { width: fit-content; margin-top: 10px; padding: 9px 11px; display: flex; align-items: center; gap: 9px; color: #087255; border: 1px solid #b8ead8; border-radius: 10px; background: #eaf9f3; cursor: pointer; }
.template-visibility-toggle.is-off { color: #7b3940; border-color: #efc5c9; background: #fff0f1; }
.template-visibility-toggle input { width: auto; }
.template-visibility-toggle span strong,.template-visibility-toggle span small { display: block; }
.template-visibility-toggle span small { margin-top: 2px; color: inherit; font-size: 9px; }
.template-shipping-toggle { width: fit-content; margin-top: 9px; padding: 7px 9px; display: flex; align-items: center; gap: 7px; color: var(--navy); border-radius: 9px; background: var(--ice); font-size: 11px; font-weight: 700; }
.template-shipping-toggle input { width: auto; }
.template-shipping-editor { margin-top: 10px; display: grid; grid-template-columns: repeat(4,minmax(105px,1fr)); gap: 8px; }
.template-shipping-details { margin-top: 10px; border: 1px solid #d8e2f0; border-radius: 10px; background: #fbfcfe; }
.template-shipping-details summary { padding: 10px; color: var(--blue); cursor: pointer; font-size: 11px; font-weight: 800; }
.template-shipping-details .template-shipping-editor { padding: 0 10px 10px; }
.template-shipping-editor .template-shipping-toggle { grid-column: span 2; margin: 0; }
.template-shipping-editor label:not(.template-shipping-toggle) { padding: 8px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.template-shipping-editor label span,.template-shipping-editor label small { display: block; }
.template-shipping-editor label span { margin-bottom: 5px; color: var(--muted); font-size: 9px; font-weight: 700; }
.template-shipping-editor label small { margin-top: 3px; }
.template-shipping-editor input[type="number"] { padding: 8px; }
.pdf-shape-preview { overflow: hidden; pointer-events: none; border: 2px solid #8eadde; background: #fff; }
.template-full-editor { margin-top: 10px; border: 1px solid #c9d8ef; border-radius: 11px; background: #f7faff; }
.template-full-editor summary { padding: 11px; color: var(--blue); cursor: pointer; font-weight: 800; }
.template-full-editor-grid { padding: 0 11px 12px; display: grid; grid-template-columns: repeat(3,1fr); gap: 9px; }
.template-full-editor-grid .wide { grid-column: 1/-1; }
.template-full-editor-grid label:not(.template-shipping-toggle) { padding: 8px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
.template-full-editor-grid label span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 9px; font-weight: 700; }
.template-builder { margin-top: 15px; padding: 18px; border: 2px dashed #b8c6da; border-radius: 15px; background: #f9fbfe; }
.template-builder-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: 14px; }
.template-builder-grid .wide { grid-column: 1 / -1; }
.template-price-guide { margin-top: 12px; padding: 11px; color: var(--muted); border-radius: 10px; background: #fff; font-size: 11px; }
@media (max-width: 900px) { .template-builder-grid { grid-template-columns: 1fr; } .template-builder-grid .wide { grid-column: auto; } .template-shipping-editor,.template-full-editor-grid { grid-template-columns: repeat(2,1fr); } }
.service-editor-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.service-editor-grid .toggle-row { min-height: 48px; }
.delivery-global-note { padding: 12px; display: grid; gap: 4px; color: var(--muted); border: 1px solid var(--line); border-radius: 11px; background: #f7f9fc; font-size: 11px; }
.delivery-global-note strong { color: var(--navy); }
@media (max-width: 900px) { .service-editor-grid { grid-template-columns: 1fr; } }
