/* My Account - Cleaning Orders Styling */
.cbp-my-orders {
    max-width: 100%;
}

.cbp-my-orders h2 {
    margin-bottom: 20px;
    font-size: 24px;
}

/* Status Filters */
.cbp-order-filters {
    display: flex;
    gap: 15px;
    list-style: none;
    padding: 0;
    margin: 0 0 30px;
    border-bottom: 2px solid #e5e7eb;
}

.cbp-order-filters li {
    margin: 0;
}

.cbp-order-filters a {
    display: block;
    padding: 12px 20px;
    text-decoration: none;
    color: #666;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s;
}

.cbp-order-filters a:hover {
    color: #0f766e;
    border-bottom-color: #0f766e;
}

.cbp-order-filters a.active {
    color: #0f766e;
    font-weight: 600;
    border-bottom-color: #0f766e;
}

/* Orders List */
.cbp-orders-list {
    display: grid;
    gap: 20px;
}

/* Order Card */
.cbp-order-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.cbp-order-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.cbp-order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid #e5e7eb;
}

.cbp-order-id strong {
    font-size: 16px;
    color: #0f766e;
}

.cbp-order-id .cbp-wc-id {
    font-size: 13px;
    color: #999;
    margin-left: 8px;
}

/* Status Badge */
.cbp-status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cbp-status-badge.status-pending {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffc107;
}

.cbp-status-badge.status-processing {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #28a745;
}

.cbp-status-badge.status-completed {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #17a2b8;
}

.cbp-status-badge.status-cancelled {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #dc3545;
}

/* Order Body */
.cbp-order-body {
    padding: 20px;
}

.cbp-order-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 15px;
}

.cbp-order-col {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.cbp-order-col.cbp-col-full {
    grid-column: 1 / -1;
}

.cbp-label {
    font-size: 13px;
    color: #666;
    font-weight: 600;
}

.cbp-value {
    font-size: 15px;
    color: #333;
}

.cbp-maps-link {
    display: inline-block;
    margin-top: 8px;
    padding: 6px 12px;
    background: #0f766e;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 13px;
    transition: background 0.3s;
}

.cbp-maps-link:hover {
    background: #0d6661;
    color: white;
}

.cbp-order-meta {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e5e7eb;
    font-size: 13px;
    color: #666;
}

/* Order Actions */
.cbp-order-actions {
    display: flex;
    gap: 10px;
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e5e7eb;
}

.cbp-order-actions .button {
    flex: 1;
    text-align: center;
    padding: 10px 20px;
    font-size: 14px;
}

.cbp-cancel-order {
    background: transparent;
    color: #dc3545;
    border: 1px solid #dc3545;
}

.cbp-cancel-order:hover {
    background: #dc3545;
    color: white;
}

.cbp-cancel-order.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Pagination */
.cbp-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
    padding: 20px 0;
}

.cbp-pagination a {
    display: inline-block;
    padding: 8px 14px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
}

.cbp-pagination a:hover {
    background: #0f766e;
    color: white;
    border-color: #0f766e;
}

.cbp-pagination a.active {
    background: #0f766e;
    color: white;
    border-color: #0f766e;
    font-weight: 600;
}

/* Empty State */
.woocommerce-message--info {
    padding: 30px;
    text-align: center;
    background: #f8f9fa;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin: 20px 0;
}

/* Review Button */
.cbp-leave-review {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
    border-color: #d97706 !important;
    color: #fff !important;
}

.cbp-leave-review:hover {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.cbp-reviewed-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: #ecfdf5;
    color: #059669;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
}

/* Review Modal */
.cbp-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.cbp-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.cbp-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    max-width: 480px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: cbpModalSlideIn 0.3s ease-out;
}

@keyframes cbpModalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.cbp-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border: none;
    background: #f3f4f6;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10;
}

.cbp-modal-close:hover {
    background: #e5e7eb;
    transform: rotate(90deg);
}

.cbp-modal-header {
    text-align: center;
    padding: 32px 24px 24px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-radius: 16px 16px 0 0;
}

.cbp-modal-icon {
    margin-bottom: 12px;
}

.cbp-modal-header h3 {
    margin: 0 0 8px;
    font-size: 22px;
    color: #92400e;
}

.cbp-modal-service-name {
    margin: 0;
    color: #b45309;
    font-size: 14px;
}

/* Review Form */
.cbp-review-form {
    padding: 24px;
}

.cbp-form-row {
    margin-bottom: 20px;
}

.cbp-form-row label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #374151;
    font-size: 14px;
}

.cbp-form-row input[type="text"],
.cbp-form-row input[type="email"],
.cbp-form-row textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.cbp-form-row input:focus,
.cbp-form-row textarea:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

.cbp-form-row input[readonly] {
    background: #f9fafb;
    color: #6b7280;
}

/* Star Rating Input */
.cbp-star-rating-input {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    gap: 5px;
    padding: 10px 0;
}

.cbp-star-rating-input input[type="hidden"] {
    display: none;
}

.cbp-star-rating-input .star-item {
    font-size: 40px;
    color: #9ca3af;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1;
    user-select: none;
}

/* Hover effect */
.cbp-star-rating-input .star-item:hover {
    transform: scale(1.2);
    color: #f59e0b;
}

/* Selected/Active state */
.cbp-star-rating-input .star-item.selected {
    color: #f59e0b !important;
}

/* Form Actions */
.cbp-form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.cbp-modal-cancel {
    background: #f3f4f6 !important;
    color: #374151 !important;
}

.cbp-submit-review {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
    border-color: #d97706 !important;
    min-width: 140px;
    justify-content: center;
}

.cbp-submit-review:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.cbp-spinner {
    animation: cbpSpin 1s linear infinite;
}

@keyframes cbpSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Success State */
.cbp-review-success {
    text-align: center;
    padding: 48px 24px;
}

.cbp-success-icon {
    margin-bottom: 20px;
    animation: cbpSuccessPop 0.5s ease-out;
}

@keyframes cbpSuccessPop {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.cbp-review-success h3 {
    margin: 0 0 8px;
    font-size: 24px;
    color: #059669;
}

.cbp-review-success p {
    margin: 0 0 24px;
    color: #6b7280;
}

/* Responsive */
@media (max-width: 768px) {
    .cbp-order-filters {
        flex-wrap: wrap;
        gap: 10px;
    }

    .cbp-order-filters a {
        padding: 10px 15px;
        font-size: 14px;
    }

    .cbp-order-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .cbp-order-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .cbp-order-actions {
        flex-direction: column;
    }

    .cbp-pagination {
        flex-wrap: wrap;
    }

    .cbp-modal-content {
        margin: 10px;
        max-height: 85vh;
    }

    .cbp-star-rating-input label {
        font-size: 28px;
    }

    .cbp-form-actions {
        flex-direction: column;
    }

    .cbp-form-actions button {
        width: 100%;
    }
}