/**
 * سیستم پاداش و کیف پول شاهکار
 * Styles for Reward System
 */

/* ==================== */
/* Variables */
/* ==================== */
:root {
    --srs-primary: #6366f1;
    --srs-secondary: #8b5cf6;
    --srs-success: #10b981;
    --srs-warning: #f59e0b;
    --srs-danger: #ef4444;
    --srs-gold: #fbbf24;
    --srs-silver: #d1d5db;
    --srs-bronze: #cd7f32;
    --srs-border: #e5e7eb;
    --srs-bg: #f9fafb;
    --srs-text: #1f2937;
    --srs-text-light: #6b7280;
    --srs-radius: 12px;
    --srs-shadow: 0 1px 3px rgba(0,0,0,0.1);
    --srs-shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
}

/* ==================== */
/* پاداش روزانه */
/* ==================== */
.srs-daily-reward {
    background: linear-gradient(135deg, var(--srs-primary) 0%, var(--srs-secondary) 100%);
    padding: 30px;
    border-radius: var(--srs-radius);
    color: white;
    text-align: center;
    box-shadow: var(--srs-shadow-lg);
    margin: 20px 0;
}

.srs-daily-reward__icon {
    font-size: 60px;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.srs-daily-reward__title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
}

.srs-daily-reward__amount {
    font-size: 36px;
    font-weight: bold;
    margin: 15px 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.srs-daily-reward__streak {
    background: rgba(255,255,255,0.2);
    padding: 10px 20px;
    border-radius: 50px;
    display: inline-block;
    margin: 10px 0;
    font-size: 14px;
}

.srs-daily-reward__timer {
    opacity: 0.9;
    margin-top: 10px;
    font-size: 14px;
}

.srs-btn {
    background: white;
    color: var(--srs-primary);
    border: none;
    padding: 15px 40px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.srs-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.srs-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.srs-btn:disabled:hover {
    transform: none;
}

/* ==================== */
/* لاگ تراکنش‌ها */
/* ==================== */
.srs-wallet-log {
    background: white;
    border-radius: var(--srs-radius);
    box-shadow: var(--srs-shadow);
    overflow: hidden;
    margin: 20px 0;
}

.srs-wallet-log__header {
    background: var(--srs-bg);
    padding: 20px;
    border-bottom: 1px solid var(--srs-border);
}

.srs-wallet-log__title {
    font-size: 20px;
    font-weight: bold;
    color: var(--srs-text);
    margin: 0;
}

.srs-wallet-log__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.srs-transaction {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    border-bottom: 1px solid var(--srs-border);
    transition: background 0.2s ease;
}

.srs-transaction:hover {
    background: var(--srs-bg);
}

.srs-transaction:last-child {
    border-bottom: none;
}

.srs-transaction__icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-left: 15px;
}

.srs-transaction--cashback .srs-transaction__icon {
    background: #dcfce7;
    color: var(--srs-success);
}

.srs-transaction--referral .srs-transaction__icon {
    background: #dbeafe;
    color: #3b82f6;
}

.srs-transaction--daily .srs-transaction__icon {
    background: #fef3c7;
    color: var(--srs-warning);
}

.srs-transaction--manual .srs-transaction__icon {
    background: #f3e8ff;
    color: var(--srs-secondary);
}

.srs-transaction__content {
    flex: 1;
}

.srs-transaction__desc {
    font-weight: 600;
    color: var(--srs-text);
    margin-bottom: 5px;
}

.srs-transaction__date {
    font-size: 13px;
    color: var(--srs-text-light);
}

.srs-transaction__amount {
    font-size: 18px;
    font-weight: bold;
    color: var(--srs-success);
}

.srs-transaction__amount--negative {
    color: var(--srs-danger);
}

.srs-transaction__status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    margin-right: 10px;
}

.srs-transaction__status--approved {
    background: #dcfce7;
    color: #16a34a;
}

.srs-transaction__status--pending {
    background: #fef3c7;
    color: #d97706;
}

.srs-transaction__status--rejected {
    background: #fee2e2;
    color: #dc2626;
}

/* ==================== */
/* سطح‌بندی کاربر */
/* ==================== */
.srs-user-level {
    background: white;
    border-radius: var(--srs-radius);
    box-shadow: var(--srs-shadow);
    padding: 30px;
    margin: 20px 0;
}

.srs-user-level__header {
    text-align: center;
    margin-bottom: 30px;
}

.srs-user-level__badge {
    font-size: 80px;
    margin-bottom: 10px;
    display: block;
}

.srs-user-level__title {
    font-size: 28px;
    font-weight: bold;
    color: var(--srs-text);
    margin-bottom: 5px;
}

.srs-user-level__subtitle {
    color: var(--srs-text-light);
    font-size: 14px;
}

.srs-level-badge {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: bold;
    margin-top: 10px;
}

.srs-level-badge--normal {
    background: linear-gradient(135deg, #cd7f32 0%, #e6a157 100%);
    color: white;
}

.srs-level-badge--special {
    background: linear-gradient(135deg, #9ca3af 0%, #d1d5db 100%);
    color: white;
}

.srs-level-badge--pro {
    background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
    color: white;
}

.srs-user-level__stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.srs-stat-card {
    background: var(--srs-bg);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
}

.srs-stat-card__icon {
    font-size: 30px;
    margin-bottom: 10px;
}

.srs-stat-card__value {
    font-size: 24px;
    font-weight: bold;
    color: var(--srs-text);
    margin-bottom: 5px;
}

.srs-stat-card__label {
    font-size: 13px;
    color: var(--srs-text-light);
}

.srs-benefits {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid var(--srs-border);
}

.srs-benefits__title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--srs-text);
}

.srs-benefits__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.srs-benefits__item {
    padding: 12px 0;
    display: flex;
    align-items: center;
    color: var(--srs-text);
}

.srs-benefits__item::before {
    content: "✓";
    display: inline-block;
    width: 25px;
    height: 25px;
    background: var(--srs-success);
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 25px;
    margin-left: 10px;
    font-weight: bold;
}

/* ==================== */
/* آمار رفرال */
/* ==================== */
.srs-referral-stats {
    background: white;
    border-radius: var(--srs-radius);
    box-shadow: var(--srs-shadow);
    padding: 30px;
    margin: 20px 0;
}

.srs-referral-stats__title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 20px;
    color: var(--srs-text);
}

.srs-referral-link {
    background: var(--srs-bg);
    padding: 15px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
    border: 2px dashed var(--srs-border);
}

.srs-referral-link__url {
    flex: 1;
    color: var(--srs-primary);
    font-weight: 600;
    direction: ltr;
    text-align: left;
    padding-left: 10px;
}

.srs-copy-btn {
    background: var(--srs-primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.srs-copy-btn:hover {
    background: var(--srs-secondary);
    transform: translateY(-1px);
}

.srs-referrals-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.srs-referrals-table th {
    background: var(--srs-bg);
    padding: 15px;
    text-align: right;
    font-weight: bold;
    color: var(--srs-text);
    border-bottom: 2px solid var(--srs-border);
}

.srs-referrals-table td {
    padding: 15px;
    border-bottom: 1px solid var(--srs-border);
    color: var(--srs-text);
}

.srs-referrals-table tr:hover {
    background: var(--srs-bg);
}

.srs-empty-state {
    text-align: center;
    padding: 40px;
    color: var(--srs-text-light);
}

.srs-empty-state__icon {
    font-size: 60px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.srs-empty-state__text {
    font-size: 16px;
}

/* ==================== */
/* پنل ادمین */
/* ==================== */
.srs-admin-wrapper {
    background: white;
    margin: 20px 0;
    padding: 30px;
    border-radius: 8px;
    box-shadow: var(--srs-shadow);
}

.srs-admin-header {
    border-bottom: 1px solid var(--srs-border);
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.srs-admin-header h1 {
    margin: 0;
    color: var(--srs-text);
}

.srs-settings-section {
    margin-bottom: 40px;
}

.srs-settings-section__title {
    font-size: 20px;
    font-weight: bold;
    color: var(--srs-text);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--srs-primary);
}

.srs-form-group {
    margin-bottom: 25px;
}

.srs-form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--srs-text);
}

.srs-form-group input[type="text"],
.srs-form-group input[type="number"],
.srs-form-group select {
    width: 100%;
    max-width: 400px;
    padding: 12px;
    border: 1px solid var(--srs-border);
    border-radius: 6px;
    font-size: 14px;
}

.srs-form-group input[type="text"]:focus,
.srs-form-group input[type="number"]:focus,
.srs-form-group select:focus {
    outline: none;
    border-color: var(--srs-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.srs-form-group small {
    display: block;
    margin-top: 5px;
    color: var(--srs-text-light);
    font-size: 13px;
}

.srs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.srs-card {
    background: var(--srs-bg);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--srs-border);
}

.srs-card__title {
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--srs-text);
}

.srs-admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.srs-admin-table th {
    background: var(--srs-bg);
    padding: 12px;
    text-align: right;
    font-weight: bold;
    border-bottom: 2px solid var(--srs-border);
}

.srs-admin-table td {
    padding: 12px;
    border-bottom: 1px solid var(--srs-border);
}

.srs-admin-table tr:hover {
    background: #fafafa;
}

.srs-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
}

.srs-badge--success {
    background: #dcfce7;
    color: #16a34a;
}

.srs-badge--warning {
    background: #fef3c7;
    color: #d97706;
}

.srs-badge--danger {
    background: #fee2e2;
    color: #dc2626;
}

.srs-badge--info {
    background: #dbeafe;
    color: #2563eb;
}

/* ==================== */
/* Responsive */
/* ==================== */
@media (max-width: 768px) {
    .srs-user-level__stats {
        grid-template-columns: 1fr;
    }
    
    .srs-transaction {
        flex-wrap: wrap;
    }
    
    .srs-transaction__content {
        width: 100%;
        margin-top: 10px;
    }
    
    .srs-referral-link {
        flex-direction: column;
        gap: 10px;
    }
    
    .srs-referrals-table {
        font-size: 14px;
    }
    
    .srs-admin-table {
        font-size: 13px;
    }
    
    .srs-admin-table th,
    .srs-admin-table td {
        padding: 8px;
    }
}

/* ==================== */
/* انیمیشن‌ها */
/* ==================== */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.srs-transaction,
.srs-stat-card,
.srs-card {
    animation: slideIn 0.3s ease;
}

/* ==================== */
/* دکمه‌های اصلی */
/* ==================== */
.srs-btn-primary {
    background: var(--srs-primary);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.srs-btn-primary:hover {
    background: var(--srs-secondary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.srs-btn-success {
    background: var(--srs-success);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.srs-btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
}

/* ==================== */
/* Toast Notifications */
/* ==================== */
.srs-toast {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    z-index: 9999;
    animation: slideIn 0.3s ease;
}

.srs-toast--success {
    border-right: 4px solid var(--srs-success);
}

.srs-toast--error {
    border-right: 4px solid var(--srs-danger);
}

.srs-toast--info {
    border-right: 4px solid var(--srs-primary);
}

/* RTL Support */
[dir="rtl"] .srs-transaction__icon {
    margin-left: 0;
    margin-right: 15px;
}

[dir="rtl"] .srs-benefits__item::before {
    margin-left: 0;
    margin-right: 10px;
}