/**
 * CM Order Confirmation Styles
 * Version: 1.0.0
 */

/* Main container */
.cm-order-confirmation-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Order header */
.cm-order-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.cm-order-header h2 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 28px;
}

.cm-order-number {
    font-size: 18px;
    font-weight: bold;
    color: #555;
    margin: 10px 0;
}

.cm-order-date {
    font-size: 14px;
    color: #777;
    margin: 5px 0;
}

/* Order summary */
.cm-order-summary {
    margin-bottom: 30px;
}

.cm-order-summary h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 20px;
    border-bottom: 1px solid #e5e5e5;
    padding-bottom: 10px;
}

.cm-order-totals {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 15px;
}

.cm-order-totals tr {
    border-bottom: 1px solid #f0f0f0;
}

.cm-order-totals th {
    text-align: left;
    padding: 10px;
    font-weight: normal;
    color: #666;
}

.cm-order-totals td {
    text-align: right;
    padding: 10px;
    font-weight: 500;
    color: #333;
}

.cm-order-totals tr.cm-order-total th,
.cm-order-totals tr.cm-order-total td {
    font-size: 18px;
    font-weight: bold;
    color: #000;
    border-top: 2px solid #333;
    padding-top: 15px;
}

.cm-payment-method {
    background: #f9f9f9;
    padding: 10px 15px;
    border-left: 3px solid #0073aa;
    margin: 15px 0 0 0;
    font-size: 14px;
}

/* Order items */
.cm-order-items {
    margin-bottom: 30px;
}

.cm-order-items h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 20px;
    border-bottom: 1px solid #e5e5e5;
    padding-bottom: 10px;
}

.cm-items-table {
    width: 100%;
    border-collapse: collapse;
}

.cm-items-table thead th {
    background: #f5f5f5;
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #ddd;
}

.cm-items-table tbody tr {
    border-bottom: 1px solid #e5e5e5;
}

.cm-items-table tbody tr:last-child {
    border-bottom: none;
}

.cm-items-table tbody td {
    padding: 12px;
    color: #555;
}

.cm-items-table tbody td:last-child {
    text-align: right;
    font-weight: 500;
}

/* Billing and Shipping Details */
.cm-billing-details,
.cm-shipping-details {
    margin-bottom: 30px;
    padding: 20px;
    background: #fafafa;
    border-radius: 5px;
}

.cm-billing-details h3,
.cm-shipping-details h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 18px;
    border-bottom: 1px solid #e5e5e5;
    padding-bottom: 10px;
}

.cm-billing-details address,
.cm-shipping-details address {
    font-style: normal;
    line-height: 1.8;
    color: #555;
}

/* Simple template */
.cm-order-confirmation-simple {
    padding: 20px;
    background: #f9f9f9;
    border-left: 4px solid #0073aa;
    margin: 20px 0;
}

.cm-order-confirmation-simple p {
    margin: 10px 0;
    font-size: 16px;
}

/* Error message */
.cm-order-confirmation-error {
    padding: 15px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 4px;
    color: #856404;
    text-align: center;
    margin: 20px 0;
}

/* Responsive design */
@media screen and (max-width: 768px) {
    .cm-order-confirmation-container {
        margin: 10px;
        padding: 15px;
    }
    
    .cm-order-header h2 {
        font-size: 24px;
    }
    
    .cm-items-table {
        font-size: 14px;
    }
    
    .cm-items-table thead th,
    .cm-items-table tbody td {
        padding: 8px;
    }
    
    .cm-billing-details,
    .cm-shipping-details {
        padding: 15px;
    }
}

@media screen and (max-width: 480px) {
    .cm-order-totals th,
    .cm-order-totals td {
        padding: 8px 5px;
        font-size: 14px;
    }
    
    .cm-items-table {
        font-size: 12px;
    }
    
    .cm-items-table thead th {
        padding: 8px 5px;
    }
    
    .cm-items-table tbody td {
        padding: 8px 5px;
    }
}
