/**
 * RefundPro Frontend Styles
 */

/* Refund Request Form */
.refund-pro-form {
    max-width: 600px;
    margin: 0 auto;
    padding: 30px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.refund-pro-form h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #23282d;
    text-align: center;
}

.refund-pro-form .form-group {
    margin-bottom: 20px;
}

.refund-pro-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #23282d;
}

.refund-pro-form input,
.refund-pro-form select,
.refund-pro-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    font-family: inherit;
}

.refund-pro-form input:focus,
.refund-pro-form select:focus,
.refund-pro-form textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.1);
}

.refund-pro-form textarea {
    min-height: 100px;
    resize: vertical;
}

.refund-pro-form .form-description {
    font-size: 14px;
    color: #666;
    margin-top: 5px;
}

.refund-pro-form .required {
    color: #dc3232;
}

.refund-pro-form .submit-button {
    background: #0073aa;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    transition: background 0.3s ease;
}

.refund-pro-form .submit-button:hover {
    background: #005a87;
}

.refund-pro-form .submit-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

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

.refund-status.pending {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.refund-status.processing {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.refund-status.completed {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.refund-status.failed {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.refund-status.cancelled {
    background: #e2e3e5;
    color: #383d41;
    border: 1px solid #d6d8db;
}

/* Refund Details Card */
.refund-details-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.refund-details-card h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #23282d;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.refund-details-card .detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f5f5f5;
}

.refund-details-card .detail-row:last-child {
    border-bottom: none;
}

.refund-details-card .detail-label {
    font-weight: 600;
    color: #666;
}

.refund-details-card .detail-value {
    color: #23282d;
    text-align: right;
}

/* Progress Indicator */
.refund-progress {
    display: flex;
    align-items: center;
    margin: 20px 0;
}

.refund-progress .step {
    flex: 1;
    text-align: center;
    position: relative;
}

.refund-progress .step:not(:last-child):after {
    content: '';
    position: absolute;
    top: 15px;
    right: -50%;
    width: 100%;
    height: 2px;
    background: #ddd;
    z-index: 1;
}

.refund-progress .step.completed:not(:last-child):after {
    background: #46b450;
}

.refund-progress .step-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #ddd;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 5px;
    position: relative;
    z-index: 2;
    font-size: 14px;
    font-weight: bold;
}

.refund-progress .step.completed .step-icon {
    background: #46b450;
}

.refund-progress .step.current .step-icon {
    background: #0073aa;
}

.refund-progress .step-label {
    font-size: 12px;
    color: #666;
}

/* Notifications */
.refund-notification {
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    border-left: 4px solid;
}

.refund-notification.success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.refund-notification.error {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

.refund-notification.info {
    background: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

.refund-notification.warning {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

/* Refund List */
.refund-list {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.refund-list-item {
    padding: 15px 20px;
    border-bottom: 1px solid #f5f5f5;
    transition: background 0.2s ease;
}

.refund-list-item:last-child {
    border-bottom: none;
}

.refund-list-item:hover {
    background: #f8f9fa;
}

.refund-list-item .item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.refund-list-item .refund-id {
    font-weight: 600;
    color: #0073aa;
}

.refund-list-item .refund-amount {
    font-weight: 600;
    font-size: 18px;
}

.refund-list-item .item-details {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: #666;
}

/* Loading States */
.refund-loading {
    text-align: center;
    padding: 40px 20px;
}

.refund-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #0073aa;
    border-radius: 50%;
    animation: refund-spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes refund-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .refund-pro-form {
        margin: 0 15px;
        padding: 20px;
    }
    
    .refund-details-card .detail-row {
        flex-direction: column;
        text-align: left;
    }
    
    .refund-details-card .detail-value {
        text-align: left;
        margin-top: 5px;
    }
    
    .refund-list-item .item-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .refund-list-item .item-details {
        flex-direction: column;
    }
    
    .refund-progress {
        flex-direction: column;
    }
    
    .refund-progress .step {
        margin-bottom: 20px;
    }
    
    .refund-progress .step:not(:last-child):after {
        display: none;
    }
}

/* Print Styles */
@media print {
    .refund-pro-form .submit-button,
    .refund-notification {
        display: none;
    }
    
    .refund-details-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #000;
    }
    
    .refund-status {
        border: 1px solid #000 !important;
        background: white !important;
        color: black !important;
    }
}

/* Accessibility */
.refund-pro-form input:focus,
.refund-pro-form select:focus,
.refund-pro-form textarea:focus {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

.refund-status[aria-label] {
    cursor: help;
}

/* High Contrast Support */
@media (prefers-contrast: high) {
    .refund-details-card {
        border: 2px solid #000;
    }
    
    .refund-status {
        border: 2px solid #000;
        font-weight: bold;
    }
    
    .refund-pro-form input,
    .refund-pro-form select,
    .refund-pro-form textarea {
        border: 2px solid #000;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .refund-spinner,
    .refund-pro-form .submit-button,
    .refund-list-item {
        animation: none;
        transition: none;
    }
}