/**
 * DTG Quote Builder Styles
 * ========================
 * Extracted from inline styles - January 6, 2026
 * Part of Quote Builder CSS Unification project
 *
 * This file was extracted from dtg-quote-builder.html to enable:
 * 1. Easier maintenance and updates
 * 2. Browser caching of CSS
 * 3. Future consolidation into universal quote builder CSS
 *
 * Sections marked with SHARED are candidates for quote-builder-universal.css
 * Sections marked with DTG-SPECIFIC should remain separate
 */

/* CSS Variables, Reset, Header, Main Layout — moved to quote-builder-common.css (2026-03-23) */

/* ============================================
   DTG-SPECIFIC: Logo Configuration Section
   ============================================ */
.logo-section {
    background: #f8f9fa;
    border-bottom: 1px solid var(--border-color);
    padding: 15px 20px;
}

.primary-logo-config {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 15px;
    margin-bottom: 12px;
}

.logo-section-label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    min-width: 120px;
}

.logo-section-label i {
    margin-right: 6px;
    color: var(--nwca-green);
}

.logo-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.logo-select {
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    background: white;
}

.stitch-input-group {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
}

.stitch-input-group input {
    width: 80px;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

.digitizing-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    cursor: pointer;
}

.digitizing-label input {
    cursor: pointer;
}

/* ============================================
   DTG-SPECIFIC: Print Location Styles
   ============================================ */
.location-radio {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 6px 10px;
    border-radius: 6px;
    transition: background 0.15s;
}

.location-radio:hover {
    background: #e8f4ff;
}

.location-radio input[type="radio"] {
    cursor: pointer;
    accent-color: var(--nwca-green);
}

.location-radio span {
    font-size: 13px;
    color: #333;
}

.location-group {
    min-width: 180px;
}

/* ============================================
   DTG-SPECIFIC: Additional Logos Section
   ============================================ */
.additional-logos-section {
    padding-top: 12px;
    border-top: 1px dashed #ddd;
}

.al-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.add-logo-btn {
    padding: 6px 14px;
    background: var(--nwca-green);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: background 0.2s;
}

.add-logo-btn:hover {
    background: #3da344;
}

.additional-logos-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.no-logos {
    color: #999;
    font-size: 12px;
    font-style: italic;
    padding: 8px;
}

.additional-logo-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
}

.additional-logo-row select {
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 12px;
}

.additional-logo-row .stitch-input-group input {
    width: 70px;
    padding: 5px 8px;
    font-size: 12px;
}

.additional-logo-row .stitch-input-group span {
    font-size: 11px;
    color: #666;
}

.al-digitizing {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
}

.al-price {
    font-weight: 600;
    color: var(--nwca-green);
    min-width: 75px;
    font-size: 13px;
}

.remove-al-btn {
    background: none;
    border: none;
    color: #dc3545;
    cursor: pointer;
    padding: 4px 8px;
    font-size: 14px;
    transition: color 0.2s;
}

.remove-al-btn:hover {
    color: #a71d2a;
}

/* Legacy preset-btn kept for any remaining uses */
.preset-btn {
    padding: 8px 16px;
    border: 2px solid var(--border-color);
    background: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.preset-btn:hover {
    border-color: var(--nwca-blue);
    background: #f0f7ff;
}

.preset-btn.active {
    border-color: var(--nwca-blue);
    background: var(--nwca-blue);
    color: white;
}

.preset-btn i {
    font-size: 12px;
}

.logo-config-display {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 13px;
    color: #666;
}

.logo-config-display strong {
    color: #333;
}

.digitizing-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
}

.digitizing-toggle input {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Product Grid, Search, Product Table, Child Rows, Cell Inputs, Add Row — moved to quote-builder-common.css (2026-03-23) */

/* DTG-SPECIFIC: Compact cell overrides (36px vs 40px default) */
.product-table td {
    padding: 0;
}

.cell-input {
    height: 36px;
    padding: 0 8px;
}

.cell-select {
    height: 36px;
    padding: 0 4px;
}

/* Color picker styles in /shared_components/css/color-picker-shared.css */

/* Pricing Sidebar, LTM Toggle, Customer Panel — moved to quote-builder-common.css (2026-03-23) */

/* Action Buttons — moved to quote-builder-common.css (2026-03-23) */

/* Coming Soon, Modal, Toast — moved to quote-builder-common.css (2026-03-23) */

/* OSFA, Cap Badge, Desc Cell, Pricing Breakdown — moved to quote-builder-common.css (2026-03-23) */

/* ============================================
   DTG-SPECIFIC: Per-Product Additional Logo (AL) Button and Config
   ============================================ */
.al-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #f0fdf4;
    border: 1px solid #22c55e;
    border-radius: 12px;
    font-size: 11px;
    color: #16a34a;
    cursor: pointer;
    margin-top: 4px;
    transition: all 0.15s ease;
}

.al-btn:hover {
    background: #22c55e;
    color: white;
}

.al-btn.has-al {
    background: #eff6ff;
    border-color: #3b82f6;
    color: #2563eb;
}

.al-btn.has-al:hover {
    background: #3b82f6;
    color: white;
}

.al-btn .al-badge {
    background: #3b82f6;
    color: white;
    border-radius: 10px;
    padding: 0 6px;
    font-size: 10px;
    font-weight: 600;
}

.al-btn.has-al .al-label {
    display: none;
}

.al-btn:not(.has-al) .al-badge {
    display: none;
}

/* AL Configuration Row */
.al-config-row {
    background: #fffbeb !important;
    border-left: 3px solid #f59e0b;
}

.al-config-row td {
    padding: 8px !important;
    vertical-align: middle;
}

.al-indicator {
    color: #d97706;
    font-family: 'Consolas', monospace;
    font-size: 12px;
    font-weight: 600;
}

.al-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.al-position-select {
    padding: 4px 8px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 12px;
    min-width: 120px;
}

.al-stitch-input {
    width: 70px;
    padding: 4px 6px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 12px;
    text-align: right;
}

.al-stitch-label {
    font-size: 11px;
    color: #6b7280;
}

.al-price-cell {
    text-align: right;
}

.al-unit-price {
    font-weight: 600;
    color: #059669;
}

.al-total {
    font-size: 11px;
    color: #6b7280;
    margin-left: 8px;
}

.add-al-row {
    background: #fefce8 !important;
}

.add-al-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    background: #f0fdf4;
    border: 1px dashed #22c55e;
    border-radius: 4px;
    font-size: 11px;
    color: #16a34a;
    cursor: pointer;
}

.add-al-btn:hover {
    background: #dcfce7;
    border-style: solid;
}

.add-al-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Size label override for non-standard columns */
.size-label-override {
    display: block;
    font-size: 9px;
    color: #666;
    text-align: center;
    margin-bottom: 2px;
    font-weight: 600;
}

/* Visual indicator for non-standard products */
tr[data-size-category="osfa-only"] {
    background-color: #f8f9fa;
}

tr[data-size-category="combo-only"],
tr[data-size-category="youth-only"],
tr[data-size-category="toddler-only"],
tr[data-size-category="tall-only"] {
    background-color: #fff9e6;
}

/* Size-disabled cells */
td.size-disabled input {
    background-color: #f5f5f5 !important;
    color: #999 !important;
    cursor: not-allowed !important;
}

/* Animations, Keyboard Hint — moved to quote-builder-common.css (2026-03-23) */

/* Size Picker Popup — moved to quote-builder-common.css (2026-03-23) */

/* ============================================
   RESPONSIVE - Mobile Breakpoints
   ============================================ */
@media (max-width: 1024px) {
    .power-main {
        flex-direction: column;
        height: auto;
    }

    .power-sidebar {
        width: 100%;
        position: static;
        border-left: none;
        border-top: 1px solid var(--border-color);
        max-height: none;
    }

    .power-content {
        padding: 16px;
    }

    .location-config-section {
        flex-direction: column;
    }

    .location-groups {
        flex-direction: column;
        gap: 12px;
    }
}

@media (max-width: 768px) {
    .power-header {
        padding: 8px 12px;
    }

    .power-header .logo {
        max-width: 100px;
    }

    .header-actions {
        gap: 6px;
    }

    .btn-header {
        padding: 6px 10px;
        font-size: 12px;
    }

    .product-table th.desc-col,
    .product-table td:nth-child(2) {
        display: none;
    }

    .product-table th,
    .product-table td {
        padding: 6px 4px;
        font-size: 12px;
    }

    .size-input {
        width: 40px;
        padding: 4px 2px;
    }

    .search-row {
        flex-direction: column;
        gap: 8px;
    }

    .search-input-wrapper {
        width: 100%;
    }

    .pricing-section {
        padding: 12px;
    }

    .summary-modal-content {
        width: 100%;
        height: 100%;
        max-height: 100%;
        border-radius: 0;
    }

    /* Extended size popup responsive */
    .size-popup {
        min-width: 95%;
        max-width: 95%;
        margin: 10px;
    }

    .size-popup-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .power-header {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }

    .power-header .logo {
        order: 1;
        margin-bottom: 8px;
    }

    .header-actions {
        order: 3;
        width: 100%;
        justify-content: center;
    }

    .product-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .product-table th,
    .product-table td {
        padding: 4px 2px;
        font-size: 11px;
    }

    .size-input {
        width: 35px;
        padding: 3px 1px;
        font-size: 11px;
    }

    .customer-field input,
    .customer-field textarea {
        padding: 8px;
        font-size: 14px;
    }

    .sidebar-actions {
        flex-direction: column;
        gap: 8px;
    }

    .sidebar-actions button {
        width: 100%;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .power-header,
    .sidebar-actions,
    .search-row,
    .keyboard-hint {
        display: none !important;
    }

    .power-main {
        height: auto;
        display: block;
    }

    .power-sidebar {
        width: 100%;
        border: none;
    }
}

/* Loading State — now in quote-builder-common.css (2026-03-23) */
