/* Borup WebDesign Order List Styles */

.bweb-order-list-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Login required message */
.bweb-login-required {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.bweb-login-required h2 {
    color: var(--bweb-brand-color, #b89233);
    margin-bottom: 20px;
}

.bweb-login-required p {
    font-size: 16px;
    color: #666;
    margin-bottom: 30px;
}

/* Buttons */
.bweb-button {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    background-color: #666;
    color: white;
    margin: 0 5px;
}

.bweb-button-primary {
    background-color: var(--bweb-brand-color, #b89233);
}

.bweb-button-primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.bweb-button-danger {
    background-color: #dc3545;
}

.bweb-button-danger:hover {
    background-color: #c82333;
}

.bweb-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Order list header */
.bweb-order-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
    flex-wrap: wrap;
    gap: 15px;
}

.bweb-order-list-header h1 {
    margin: 0;
    color: var(--bweb-brand-color, #b89233);
}

.bweb-order-list-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Order list table */
.bweb-order-list-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.bweb-order-list-table thead {
    background-color: var(--bweb-brand-color, #b89233);
    color: white;
}

.bweb-order-list-table th {
    padding: 15px 10px;
    text-align: left;
    font-weight: 600;
    border-right: 1px solid rgba(255,255,255,0.2);
}

.bweb-order-list-table th:last-child {
    border-right: none;
}

.bweb-order-list-table td {
    padding: 12px 10px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.bweb-order-list-table tbody tr:hover {
    background-color: #f9f9f9;
}

.bweb-order-list-table .bweb-product-image {
    width: 60px;
    height: auto;
    border-radius: 3px;
}

.bweb-order-list-table .bweb-product-name-cell a {
    color: var(--bweb-brand-color, #b89233);
    text-decoration: none;
    font-weight: 500;
}

.bweb-order-list-table .bweb-product-name-cell a:hover {
    text-decoration: underline;
}

.bweb-order-list-table .bweb-variant-info {
    color: #666;
    font-size: 14px;
}

.bweb-order-list-table .bweb-quantity-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bweb-order-list-table .bweb-quantity-input {
    width: 60px;
    padding: 5px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
}

.bweb-order-list-table .bweb-update-quantity {
    background-color: var(--bweb-brand-color, #b89233);
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
}

.bweb-order-list-table .bweb-update-quantity:hover {
    opacity: 0.9;
}

.bweb-order-list-table .bweb-remove-item {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
}

.bweb-order-list-table .bweb-remove-item:hover {
    background-color: #c82333;
}

/* Order list summary */
.bweb-order-list-summary {
    text-align: right;
    margin-top: 20px;
    padding: 15px;
    background: #f5f5f5;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
}

.bweb-order-list-summary .bweb-total-amount {
    margin-top: 10px;
    font-size: 18px;
    color: var(--bweb-brand-color, #b89233);
}

/* Empty state */
#bweb-order-list-empty {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#bweb-order-list-empty p {
    font-size: 18px;
    color: #666;
    margin-bottom: 20px;
}

/* Print-only elements */
.print-only {
    display: none;
}

/* Print styles */
@media print {
    @page {
        margin: 2cm;
    }
    
    body {
        font-size: 12pt;
    }
    
    .bweb-order-list-wrapper {
        padding: 0;
    }
    
    .print-only {
        display: block !important;
    }
    
    .no-print {
        display: none !important;
    }
    
    .bweb-print-header {
        margin-bottom: 30px;
        padding-bottom: 20px;
        border-bottom: 2px solid var(--bweb-brand-color, #b89233);
    }
    
    .bweb-print-header h1 {
        color: var(--bweb-brand-color, #b89233);
        margin: 0 0 20px 0;
        font-size: 24pt;
    }
    
    .bweb-customer-info {
        background: #f9f9f9;
        padding: 15px;
        border-radius: 5px;
    }
    
    .bweb-customer-info-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    
    .bweb-info-row {
        display: flex;
        gap: 10px;
    }
    
    .bweb-info-row label {
        font-weight: 600;
        min-width: 100px;
    }
    
    .bweb-info-row span {
        flex: 1;
        border-bottom: 1px solid #999;
    }
    
    .bweb-order-list-table {
        font-size: 11pt;
        page-break-inside: auto;
    }
    
    .bweb-order-list-table thead {
        background-color: var(--bweb-brand-color, #b89233) !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .bweb-order-list-table th {
        padding: 10px 8px;
        font-size: 11pt;
    }
    
    .bweb-order-list-table td {
        padding: 10px 8px;
    }
    
    .bweb-order-list-table tr {
        page-break-inside: avoid;
    }
    
    .bweb-order-list-table .bweb-product-image {
        width: 40px;
    }
    
    .bweb-print-footer {
        margin-top: 40px;
        padding-top: 20px;
        border-top: 2px solid var(--bweb-brand-color, #b89233);
        page-break-inside: avoid;
    }
    
    .bweb-print-footer h3 {
        color: var(--bweb-brand-color, #b89233);
        margin: 0 0 10px 0;
    }
    
    .bweb-print-footer p {
        margin: 5px 0;
        line-height: 1.6;
    }
    
    .bweb-order-list-summary {
        background: #f5f5f5 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        page-break-inside: avoid;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .bweb-order-list-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .bweb-order-list-actions {
        width: 100%;
    }
    
    .bweb-button {
        flex: 1;
        min-width: auto;
        margin: 0;
    }
    
    .bweb-order-list-table {
        font-size: 14px;
    }
    
    .bweb-order-list-table th,
    .bweb-order-list-table td {
        padding: 8px 5px;
    }
    
    .bweb-order-list-table .bweb-product-image {
        width: 40px;
    }
}

/* Custom Danish Confirm Dialog */
.bweb-confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bweb-confirm-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
}

.bweb-confirm-modal.show .bweb-confirm-overlay {
    background: rgba(0, 0, 0, 0.5);
}

.bweb-confirm-dialog {
    position: relative;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    max-width: 400px;
    width: 90%;
    opacity: 0;
    transform: scale(0.9) translateY(-20px);
    transition: all 0.3s ease;
}

.bweb-confirm-modal.show .bweb-confirm-dialog {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.bweb-confirm-message {
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 25px;
    color: #333;
}

.bweb-confirm-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.bweb-confirm-buttons button {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bweb-confirm-no {
    background: #f0f0f0;
    color: #666;
}

.bweb-confirm-no:hover {
    background: #e0e0e0;
}

.bweb-confirm-yes {
    background: var(--bweb-brand-color, #b89233);
    color: white;
}

.bweb-confirm-yes:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}
