/* Warranty Selector Styling */
.warranty-selector {
    margin: 20px 0 30px 0 !important;
    border: 1px solid #e1e5e9;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.warranty-selector h3,
.warranty-selector .warranty-title {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    font-weight: 600;
    color: #2c3338;
}

.warranty-options {
    gap: 12px !important;
}

.warranty-option {
    transition: all 0.2s ease !important;
    margin: 0 !important;
}

.warranty-option:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) !important;
}

.warranty-option-content {
    display: block;
    width: 100%;
}

.warranty-option-content strong {
    display: block;
    margin-bottom: 4px;
    font-weight: 600;
    color: inherit;
}

.warranty-option-content .description {
    font-size: 0.9em !important;
    line-height: 1.4;
    color: rgba(0, 0, 0, 0.7) !important;
    margin: 6px 0 0 0 !important;
    padding-top: 6px !important;
}

.warranty-option-content .price {
    display: inline-block;
    margin-top: 6px;
    font-weight: 600 !important;
}

.warranty-option-wrapper {
    background: #f8f8f8;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 20px;
    margin: 0 0 20px;
}

.warranty-option-wrapper h3 {
    margin: 0 0 15px;
    padding: 0;
    font-size: 1.2em;
    color: #333;
}

.warranty-checkbox-field {
    margin: 0 !important;
}

.warranty-checkbox-field label {
    font-weight: 600 !important;
    color: #2c3338 !important;
}

.warranty-checkbox-field .description {
    font-size: 0.9em;
    color: #666;
    margin-top: 8px;
    font-style: italic;
}

/* Checkbox styling */
.warranty-checkbox-field input[type="checkbox"] {
    border: 2px solid #555;
    width: 18px;
    height: 18px;
}

.warranty-checkbox-field input[type="checkbox"]:checked {
    background-color: #2271b1;
    border-color: #2271b1;
}

/* Modern Warranty Orders Design */
.woocommerce-warranty-orders {
    max-width: 100%;
    background: transparent;
    transition: all 0.3s ease;
}

/* Header Section */
.warranty-orders-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--wc-gray-200, #e0e0e0);
}

.warranty-orders-title {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--wp-admin-theme-color, #2271b1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.warranty-icon {
    font-size: 1.5rem;
    opacity: 0.8;
}

.warranty-orders-summary {
    display: flex;
    align-items: center;
}

.warranty-count {
    background: var(--wp-admin-theme-color, #2271b1);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
}

/* Card Grid Layout */
.warranty-orders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

/* Card Styling */
.warranty-order-card {
    background: var(--wp-admin-background-color, #ffffff);
    border: 1px solid var(--wc-gray-200, #e0e0e0);
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.2s ease;
    position: relative;
    backdrop-filter: blur(10px);
}

.warranty-order-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    transform: translateY(-1px);
    border-color: var(--wp-admin-theme-color, #2271b1);
}

/* Card Header */
.warranty-card-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 1px solid var(--wc-gray-100, #f0f0f0);
}

.warranty-card-order-info {
    flex: 1;
}

.warranty-order-number {
    margin: 0 0 0.5rem 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.warranty-order-link {
    color: var(--wp-admin-theme-color, #2271b1);
    text-decoration: none;
    transition: color 0.2s ease;
}

.warranty-order-link:hover {
    color: var(--wp-admin-theme-color-darker, #135e96);
    text-decoration: underline;
}

.warranty-order-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--wc-gray-600, #666);
}

.warranty-order-date {
    font-weight: 500;
}

.warranty-item-count {
    opacity: 0.8;
}

/* Status Badge */
.warranty-order-status {
    margin-left: 1rem;
}

.warranty-status-badge {
    background: var(--wc-gray-100, #f0f0f0);
    color: var(--wc-gray-700, #333);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Status Colors */
.warranty-order-card--status-completed .warranty-status-badge {
    background: #d4edda;
    color: #155724;
}

.warranty-order-card--status-processing .warranty-status-badge {
    background: #fff3cd;
    color: #856404;
}

.warranty-order-card--status-pending .warranty-status-badge {
    background: #f8d7da;
    color: #721c24;
}

/* Card Body */
.warranty-card-body {
    padding: 1rem 1.5rem;
}

.warranty-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.warranty-detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.warranty-detail-label {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--wc-gray-600, #666);
    opacity: 0.8;
}

.warranty-id-code {
    background: var(--wc-gray-100, #f8f9fa);
    color: var(--wc-gray-800, #333);
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    border: 1px solid var(--wc-gray-200, #e0e0e0);
    font-weight: 500;
    letter-spacing: 0.5px;
}

.warranty-plan-name {
    font-weight: 600;
    color: var(--wp-admin-theme-color, #2271b1);
    font-size: 0.9rem;
}

.warranty-duration {
    font-weight: 500;
    color: var(--wc-gray-700, #333);
}

.warranty-fee {
    font-weight: 600;
    color: var(--wc-gray-800, #333);
    font-size: 1rem;
}

/* Card Footer */
.warranty-card-footer {
    padding: 1rem 1.5rem 1.5rem;
    border-top: 1px solid var(--wc-gray-100, #f0f0f0);
    background: var(--wc-gray-50, #fafafa);
}

.warranty-order-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.warranty-action-button {
    background: var(--wp-admin-theme-color, #2271b1);
    color: white !important;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.warranty-action-button:hover {
    background: var(--wp-admin-theme-color-darker, #135e96);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.warranty-action-button--view {
    background: var(--wp-admin-theme-color, #2271b1);
}

.warranty-action-button--cancel {
    background: #dc3545;
}

.warranty-action-button--cancel:hover {
    background: #c82333;
}

/* Empty State */
.warranty-orders-empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: rgba(255, 255, 255, 0.6);
    border: 2px dashed var(--wc-gray-300, #c0c0c0);
    border-radius: 8px;
    margin-top: 2rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.warranty-orders-empty-state:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: var(--wp-admin-theme-color, #2271b1);
}

.warranty-empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.6;
}

.warranty-empty-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--wc-gray-700, #333);
    margin: 0 0 1rem 0;
}

.warranty-empty-description {
    font-size: 1rem;
    color: var(--wc-gray-600, #666);
    margin: 0 0 2rem 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.warranty-empty-cta {
    background: var(--wp-admin-theme-color, #2271b1);
    color: white !important;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-block;
}

.warranty-empty-cta:hover {
    background: var(--wp-admin-theme-color-darker, #135e96);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Mobile responsiveness */
@media screen and (max-width: 768px) {
    /* Original warranty option styling */
    .warranty-option-wrapper {
        padding: 15px;
        margin: 0 0 15px;
    }
    
    .warranty-option-wrapper h3 {
        font-size: 1.1em;
    }

    /* Modern warranty orders mobile styling */
    .warranty-orders-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        margin-bottom: 1.5rem;
    }

    .warranty-orders-title {
        font-size: 1.5rem;
    }

    .warranty-orders-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .warranty-order-card {
        border-radius: 8px;
    }

    .warranty-card-header {
        padding: 1.25rem 1.25rem 0.75rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .warranty-order-status {
        margin-left: 0;
        align-self: flex-end;
    }

    .warranty-order-number {
        font-size: 1rem;
    }

    .warranty-order-meta {
        flex-direction: column;
        gap: 0.25rem;
    }

    .warranty-card-body {
        padding: 0.75rem 1.25rem;
    }

    .warranty-details-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .warranty-card-footer {
        padding: 0.75rem 1.25rem 1.25rem;
    }

    .warranty-order-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .warranty-action-button {
        text-align: center;
        width: 100%;
        padding: 0.75rem 1rem;
    }

    .warranty-orders-empty-state {
        padding: 3rem 1.5rem;
        margin-top: 1rem;
    }

    .warranty-empty-icon {
        font-size: 3rem;
    }

    .warranty-empty-title {
        font-size: 1.25rem;
    }

    .warranty-empty-description {
        font-size: 0.9rem;
    }
}

/* Dark mode support using CSS custom properties */
@media (prefers-color-scheme: dark) {
    .warranty-order-card {
        background: var(--wp-admin-background-color, #1e1e1e);
        border-color: var(--wc-gray-600, #444);
    }
    
    .warranty-orders-title {
        color: var(--wp-admin-theme-color, #4f94d4);
    }
    
    .warranty-orders-header {
        border-bottom-color: var(--wc-gray-600, #444);
    }
    
    .warranty-card-header {
        border-bottom-color: var(--wc-gray-600, #333);
    }
    
    .warranty-card-footer {
        background: var(--wc-gray-800, #2a2a2a);
        border-top-color: var(--wc-gray-600, #444);
    }
    
    .warranty-empty-state {
        background: var(--wp-admin-background-color, #1e1e1e);
        border-color: var(--wc-gray-600, #444);
    }
}

/* ===========================================
   CLAIM SYSTEM STYLES
   =========================================== */

/* Claim Status Badges */
.warranty-claim-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.warranty-claim-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.375rem 0.75rem;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

/* Claim Status Colors */
.warranty-status-no-claim .warranty-claim-status-badge {
    background-color: var(--wc-gray-100, #f8f9fa);
    color: var(--wc-gray-700, #495057);
    border-color: var(--wc-gray-300, #dee2e6);
}

.warranty-status-pending .warranty-claim-status-badge {
    background-color: #fff3cd;
    color: #856404;
    border-color: #ffeaa7;
}

.warranty-status-approved .warranty-claim-status-badge {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.warranty-status-rejected .warranty-claim-status-badge {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

/* Claim Action Buttons */
.warranty-action-button--claim {
    background: linear-gradient(135deg, #007cba 0%, #0073aa 100%);
    color: white;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 124, 186, 0.2);
}

.warranty-action-button--claim:hover {
    background: linear-gradient(135deg, #005a87 0%, #004a74 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 124, 186, 0.3);
}

.warranty-action-info {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid transparent;
}

.warranty-action-info--pending {
    background-color: #fff3cd;
    color: #856404;
    border-color: #ffeaa7;
}

.warranty-action-info--approved {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.warranty-action-info--rejected {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

/* Claim Form Styles */
.woocommerce-warranty-claim-form {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.warranty-claim-card {
    background: var(--wp-admin-background-color, #ffffff);
    border-radius: 12px;
    box-shadow: 0 8px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--wc-gray-200, #e5e7eb);
    overflow: hidden;
    transition: all 0.3s ease;
}

.warranty-claim-card:hover {
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.15), 0 8px 16px -8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.warranty-claim-header {
    background: var(--wc-gray-50, #f9fafb);
    border-bottom: 1px solid var(--wc-gray-200, #e5e7eb);
    padding: 2rem;
    text-align: center;
}

.warranty-claim-title {
    margin: 0 0 0.75rem 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--wc-gray-900, #111827);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.warranty-icon {
    font-size: 1.5rem;
    opacity: 0.8;
}

.warranty-claim-description {
    margin: 0;
    color: var(--wc-gray-600, #6b7280);
    font-size: 0.875rem;
    line-height: 1.5;
}

.warranty-claim-order-info {
    background: var(--wc-gray-50, #f8f9fa);
    border: 1px solid var(--wc-gray-200, #e9ecef);
    border-radius: 6px;
    padding: 1.5rem;
    margin: 0 2rem 2rem 2rem;
}

.warranty-claim-order-info h3 {
    margin: 0 0 1rem 0;
    color: var(--wc-gray-800, #333);
    font-size: 1.125rem;
}

.warranty-claim-order-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.order-detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.detail-label {
    font-size: 0.875rem;
    color: var(--wc-gray-600, #6c757d);
    font-weight: 500;
}

.detail-value {
    font-weight: 600;
    color: var(--wc-gray-800, #333);
}

.warranty-id-display {
    font-family: 'Courier New', monospace;
    background: var(--wc-gray-100, #e9ecef);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    border: 1px solid var(--wc-gray-300, #ced4da);
}

/* Form Sections */
.warranty-claim-form-section {
    padding: 2rem;
    border-bottom: 1px solid var(--wc-gray-200, #e5e7eb);
}

.warranty-claim-form-section:last-of-type {
    border-bottom: none;
}

.warranty-claim-form-section h3 {
    margin: 0 0 1.5rem 0;
    color: var(--wc-gray-900, #111827);
    font-size: 1.125rem;
    font-weight: 600;
    border-bottom: 2px solid var(--wc-gray-200, #e5e7eb);
    padding-bottom: 0.5rem;
}

.warranty-form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.warranty-form-row:last-child {
    margin-bottom: 0;
}

.warranty-form-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.warranty-form-field label {
    font-weight: 600;
    color: var(--wc-gray-800, #333);
    font-size: 0.875rem;
}

.required {
    color: #dc3545;
}

.warranty-form-input,
.warranty-form-textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--wc-gray-300, #d1d5db);
    border-radius: 6px;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    background: var(--wp-admin-background-color, #ffffff);
    color: var(--wc-gray-900, #111827);
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.warranty-form-input:focus,
.warranty-form-textarea:focus {
    outline: none;
    border-color: var(--wc-blue, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.warranty-form-input.error,
.warranty-form-textarea.error {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.warranty-form-description {
    font-size: 0.875rem;
    color: var(--wc-gray-600, #6c757d);
    margin: 0;
}

.character-counter {
    font-size: 0.75rem;
    color: var(--wc-gray-500, #999);
    text-align: right;
    margin-top: 0.25rem;
}

.character-counter.warning {
    color: #ffc107;
}

/* Terms & Conditions */
.warranty-terms-box {
    background: var(--wc-gray-50, #f8f9fa);
    border: 1px solid var(--wc-gray-200, #e9ecef);
    border-radius: 6px;
    padding: 1.5rem;
}

.warranty-terms-box p {
    color: var(--wc-gray-800, #1f2937) !important;
    margin-bottom: 1rem;
    font-weight: 500;
}

.warranty-terms-list {
    margin: 1rem 0 0 0;
    padding-left: 1.5rem;
}

.warranty-terms-list li {
    margin-bottom: 0.5rem;
    color: var(--wc-gray-700, #374151) !important;
    line-height: 1.6;
}

/* Form Actions */
.warranty-claim-form-actions {
    padding: 2rem;
    background: var(--wc-gray-50, #f9fafb);
    border-top: 1px solid var(--wc-gray-200, #e5e7eb);
    display: flex;
    gap: 1rem;
    justify-content: center;
    align-items: center;
}

.warranty-claim-submit-btn {
    background: var(--wc-blue, #2563eb);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.warranty-claim-submit-btn:hover:not(:disabled) {
    background: var(--wc-blue-dark, #1d4ed8);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.warranty-claim-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.warranty-claim-cancel-btn {
    background: transparent;
    color: var(--wc-gray-600, #6b7280);
    border: 1px solid var(--wc-gray-300, #d1d5db);
    padding: 0.75rem 2rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.warranty-claim-cancel-btn:hover {
    background: var(--wc-gray-50, #f9fafb);
    border-color: var(--wc-gray-400, #9ca3af);
    color: var(--wc-gray-700, #374151);
    text-decoration: none;
}

/* Responsive Design for Claim Form */
@media (max-width: 768px) {
    .woocommerce-warranty-claim-form {
        margin: 1rem;
        border-radius: 6px;
    }
    
    .warranty-claim-header {
        padding: 1.5rem 1rem;
    }
    
    .warranty-claim-title {
        font-size: 1.5rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .warranty-claim-order-info {
        margin: 1rem;
        padding: 1rem;
    }
    
    .warranty-claim-order-details {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .warranty-claim-form-section {
        padding: 1.5rem 1rem;
    }
    
    .warranty-form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .warranty-claim-form-actions {
        padding: 1.5rem 1rem;
        flex-direction: column;
    }
    
    .warranty-claim-submit-btn,
    .warranty-claim-cancel-btn {
        width: 100%;
        justify-content: center;
    }
} 