/* Client Side Styles */
.client-container {
    max-width: 1400px;
    margin: 50px auto;
    padding: 20px;
}

/* Large Desktop (1600px+) */
@media (min-width: 1600px) {
    .client-container {
        max-width: 1600px;
    }
}

/* Desktop (1024px - 1599px) */
@media (min-width: 1024px) and (max-width: 1599px) {
    .client-container {
        max-width: 1200px;
    }
}

/* Tablet */
@media (max-width: 1023px) {
    .client-container {
        max-width: 100%;
        padding: 15px;
    }
}

@media (max-width: 768px) {
    .client-container {
        margin: 15px auto;
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .client-container {
        margin: 10px auto;
        padding: 5px;
    }
}

.client-card {
    background: white;
    border-radius: 20px;
    padding: 0;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    overflow: hidden;
}

@media (max-width: 768px) {
    .client-card {
        border-radius: 15px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    }
}

@media (max-width: 480px) {
    .client-card {
        border-radius: 12px;
        box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    }
}

/* User Header Bar */
#user-header-bar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
}

@media (max-width: 768px) {
    #user-header-bar {
        padding: 0.625rem 1rem;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    #user-header-bar {
        padding: 0.5rem 0.75rem;
        flex-wrap: nowrap;
        overflow-x: auto;
    }
}

.header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

@media (max-width: 480px) {
    .header-left {
        gap: 0.5rem;
    }
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

@media (max-width: 768px) {
    .header-right {
        gap: 0.75rem;
    }
}

@media (max-width: 480px) {
    .header-right {
        gap: 0.5rem;
    }
}

#user-header-bar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.3) 50%, transparent 100%);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .user-info {
        gap: 0.4rem;
    }
}

@media (max-width: 480px) {
    .user-info {
        gap: 0.3rem;
    }
}

.user-info i {
    font-size: 1.5rem;
    opacity: 0.95;
}

@media (max-width: 768px) {
    .user-info i {
        font-size: 1.25rem;
    }
}

@media (max-width: 480px) {
    .user-info i {
        font-size: 1.1rem;
    }
}

.user-info span {
    font-size: 1rem;
    letter-spacing: 0.02em;
}

@media (max-width: 768px) {
    .user-info span {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .user-info span {
        font-size: 0.8rem;
        max-width: 100px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

/* Rules Button */
.btn-rules {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: white;
    padding: 0.4rem 0.85rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    backdrop-filter: blur(10px);
    font-weight: 500;
}

.btn-rules:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.btn-rules:active {
    transform: translateY(0);
}

.btn-rules i {
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .btn-rules {
        padding: 0.35rem 0.6rem;
        font-size: 0.8rem;
    }
    
    .btn-rules span {
        display: none;
    }
    
    .btn-rules i {
        margin: 0 !important;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .btn-rules {
        padding: 0.3rem 0.5rem;
    }
    
    .btn-rules i {
        font-size: 1rem;
    }
}

.btn-change-user {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: white;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    backdrop-filter: blur(10px);
}

.btn-change-user:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-change-user:active {
    transform: translateY(0);
}

.btn-change-user i {
    font-size: 1rem;
}

/* History Button in Header */
.btn-history {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: white;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    backdrop-filter: blur(10px);
    position: relative;
}

.btn-history:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-history:active {
    transform: translateY(0);
}

.btn-history i {
    font-size: 1.1rem;
}

.history-badge {
    background: rgba(255, 255, 255, 0.9);
    color: var(--primary-color);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.45rem;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* Username Form */
#username-form {
    padding: 3rem 2.5rem;
}

@media (max-width: 768px) {
    #username-form {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    #username-form {
        padding: 1.5rem 1rem;
    }
}

.user-form-icon {
    display: inline-block;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .user-form-icon {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .user-form-icon {
        width: 50px;
        height: 50px;
    }
}

.user-form-icon i {
    font-size: 3rem;
    color: white;
}

@media (max-width: 768px) {
    .user-form-icon i {
        font-size: 2.25rem;
    }
}

@media (max-width: 480px) {
    .user-form-icon i {
        font-size: 1.8rem;
    }
}

/* Bonus List Container */
#bonus-list {
    padding: 2rem 2.5rem;
}

@media (max-width: 768px) {
    #bonus-list {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 480px) {
    #bonus-list {
        padding: 1rem 0.75rem;
    }
}

/* Modern Bonus Grid - Responsive with Fixed Columns */
.bonuses-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-bottom: 1.5rem;
    width: 100%;
    align-items: stretch;
}

/* Extra Large Desktop - 5 columns (1600px+) */
@media (min-width: 1600px) {
    .bonuses-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 1.5rem;
    }
}

/* Large Desktop - 4 columns (1200px - 1599px) */
@media (min-width: 1200px) and (max-width: 1599px) {
    .bonuses-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.25rem;
    }
}

/* Desktop - 3 columns (1024px - 1199px) */
@media (min-width: 1024px) and (max-width: 1199px) {
    .bonuses-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
    }
}

/* Tablet - 2 columns (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .bonuses-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
}

/* Mobile - 1 column (0 - 767px) */
@media (max-width: 767px) {
    .bonuses-grid {
        grid-template-columns: 1fr;
        gap: 0.875rem;
    }
}

/* Mobile-First Bonus Card - Material Design 3 + iOS Standards */
.bonus-card {
    /* Layout */
    border: 2px solid #e9ecef;
    border-radius: 16px; /* Material Design 3: 12-16px */
    padding: 16px; /* 1rem = 16px - standard spacing */
    
    /* Interaction */
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Material easing */
    
    /* Visual */
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.08); /* Elevation 1 */
    
    /* Structure */
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    
    /* Touch target - ensure 48x48px minimum */
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

/* Background Image for Bonus Card */
.bonus-card-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    opacity: 0.8;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.bonus-card-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.6) 0%, 
        rgba(0, 0, 0, 0.5) 50%, 
        rgba(0, 0, 0, 0.6) 100%);
    z-index: 1;
}

.bonus-card-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.bonus-card:has(.bonus-card-background) .bonus-card-title,
.bonus-card:has(.bonus-card-background) .bonus-card-description,
.bonus-card:has(.bonus-card-background) .bonus-card-icon {
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.bonus-card:has(.bonus-card-background) .bonus-badge {
    background: rgba(255, 255, 255, 0.25) !important;
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.bonus-card:hover .bonus-card-background {
    opacity: 1;
    transform: scale(1.05);
}

.bonus-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.bonus-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 2px 6px rgba(0, 0, 0, 0.1); /* Elevation 3 */
}

.bonus-card:hover::before {
    transform: scaleY(1);
}

/* Active/Pressed state - Material Design */
.bonus-card:active {
    transform: translateY(-2px) scale(0.98);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* Touch feedback for mobile devices */
@media (hover: none) and (pointer: coarse) {
    .bonus-card:active {
        background-color: rgba(102, 126, 234, 0.04);
    }
}

.bonus-card.selected {
    border-color: var(--primary-color);
    border-width: 3px; /* Thicker border for better visual feedback */
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.25), 0 2px 8px rgba(102, 126, 234, 0.15); /* Elevation 4 */
    padding: 15px; /* Adjust for thicker border */
}

.bonus-card.selected::before {
    transform: scaleY(1);
}

/* Bonus Card Content */
.bonus-card-header {
    display: flex;
    align-items: start;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding-right: 35px; /* Checkbox için boşluk */
}

.bonus-card-icon {
    /* Icon size: 24x24px minimum (Material Design) */
    font-size: 1.75rem; /* 28px - better visibility on mobile */
    color: var(--primary-color);
    flex-shrink: 0;
    line-height: 1;
    /* Ensure proper alignment */
    display: flex;
    align-items: center;
    justify-content: center;
}

.bonus-card-title {
    /* Typography: Headline/Title style */
    font-size: 1rem; /* 16px - minimum readable size on mobile */
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
    line-height: 1.5; /* Better line height for readability */
    
    /* Text handling */
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    
    /* Flex */
    flex: 1;
    min-width: 0;
    
    /* Ensure touch target for clickable text */
    padding: 4px 0; /* Add some vertical padding */
}

.bonus-card-description {
    /* Typography: Body text */
    font-size: 0.875rem; /* 14px - minimum for body text (WCAG) */
    color: var(--text-color);
    opacity: 0.8;
    margin-bottom: auto; /* Push footer/button to bottom */
    padding-bottom: 12px; /* Spacing */
    line-height: 1.6; /* Optimal reading line-height */
    
    /* Text handling */
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
    
    /* Height control - 2 lines */
    min-height: 2.8rem; /* ~44px (approx 2 lines) */
    max-height: 2.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Devamını Oku Button - Touch-friendly */
.btn-read-more {
    /* Visual */
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border: none;
    color: white;
    border-radius: 8px; /* Rounder for better mobile feel */
    box-shadow: 0 1px 4px rgba(102, 126, 234, 0.2);
    
    /* Typography */
    font-size: 0.75rem; /* 12px - small but readable */
    font-weight: 600;
    
    /* Spacing - Touch target minimum */
    padding: 8px 12px; /* Min height ~28px + text = ~36px */
    margin-top: 4px;
    
    /* Layout */
    display: inline-flex;
    align-items: center;
    gap: 6px;
    
    /* Interaction */
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.btn-read-more:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.35);
}

.btn-read-more:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(102, 126, 234, 0.25);
}

.btn-read-more i {
    font-size: 0.6rem;
    transition: transform 0.2s ease;
}

.btn-read-more:hover i {
    transform: scale(1.05);
}

/* Bonus Description Modal */
#bonusDescriptionModal .modal-content {
    border-radius: 20px;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

#bonusDescriptionModal .modal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 20px 20px 0 0;
    border: none;
    padding: 1.5rem;
    position: relative;
}

#bonusDescriptionModal .modal-header .btn-close {
    position: absolute;
    right: 1rem;
    top: 1rem;
}

#bonusDescriptionModal .modal-body {
    padding: 2rem;
}

#modal-bonus-description {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-color);
    opacity: 0.85;
    white-space: pre-wrap;
}

/* HTML içeriği için formatlar */
#modal-bonus-description p {
    margin-bottom: 1rem;
}

#modal-bonus-description ul,
#modal-bonus-description ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

#modal-bonus-description li {
    margin-bottom: 0.5rem;
}

#modal-bonus-description strong,
#modal-bonus-description b {
    font-weight: 600;
    color: var(--text-color);
}

#modal-bonus-description a {
    color: var(--primary-color);
    text-decoration: none;
}

#modal-bonus-description a:hover {
    text-decoration: underline;
}

#bonusDescriptionModal .modal-footer {
    border-top: none;
    padding: 0 2rem 2rem 2rem;
}

#bonusDescriptionModal .modal-footer .btn {
    border-radius: 12px;
    padding: 0.875rem;
    font-weight: 600;
}

/* History Modal */
#historyModal .modal-content {
    border-radius: 20px;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

#historyModal .modal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border: none;
    padding: 1.5rem 2rem;
    position: relative;
}

#historyModal .modal-header-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

#historyModal .modal-header-content i {
    font-size: 1.75rem;
    color: white;
    opacity: 0.95;
}

#historyModal .modal-title {
    color: white;
    font-weight: 600;
    font-size: 1.25rem;
    margin: 0;
}

#historyModal .btn-close {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
}

#historyModal .modal-body {
    padding: 0;
    max-height: 60vh;
}

@media (max-width: 768px) {
    #historyModal .modal-body {
        max-height: 70vh;
    }
}

@media (max-width: 480px) {
    #historyModal .modal-dialog {
        margin: 0.5rem;
    }
    
    #historyModal .modal-body {
        max-height: 75vh;
    }
}

/* History Table */
.history-modal-table {
    margin: 0;
    width: 100%;
}

/* Hide mobile cards on desktop */
.history-mobile-cards {
    display: none;
}

.history-modal-table thead {
    background: linear-gradient(to bottom, #f8fafc, #f1f5f9);
    position: sticky;
    top: 0;
    z-index: 10;
}

.history-modal-table thead th {
    padding: 1rem 1.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-color);
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid #e2e8f0;
}

.history-modal-table tbody tr {
    transition: all 0.2s ease;
    border-bottom: 1px solid #f1f5f9;
}

.history-modal-table tbody tr:hover {
    background: linear-gradient(to right, #f8fafc, #ffffff);
}

.history-modal-table tbody tr:last-child {
    border-bottom: none;
}

.history-modal-table tbody td {
    padding: 1.25rem 1.5rem;
    vertical-align: middle;
}

.history-bonus-name {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
}

.history-date {
    color: var(--text-color);
    opacity: 0.7;
    font-size: 0.9rem;
}

.history-modal-table .badge {
    font-size: 0.8rem;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

#history-empty-state {
    padding: 3rem 1.5rem;
}

/* Status Cell and Rejection Reason Button */
.status-cell {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-rejection-reason {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.3);
    flex-shrink: 0;
}

.btn-rejection-reason:hover {
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.5);
}

.btn-rejection-reason:active {
    transform: scale(1.05);
}

.btn-rejection-reason i {
    font-size: 0.9rem;
}

/* Rejection Reason Popover */
.rejection-popover {
    position: fixed;
    z-index: 9999;
    max-width: 320px;
    min-width: 280px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: popoverFadeIn 0.3s ease;
}

@keyframes popoverFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.rejection-popover-header {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    padding: 0.875rem 1.25rem;
    border-radius: 12px 12px 0 0;
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 600;
    font-size: 0.95rem;
}

.rejection-popover-header i {
    font-size: 1.1rem;
    opacity: 0.95;
}

.rejection-popover-body {
    padding: 1.25rem;
    color: var(--text-color);
    opacity: 0.85;
    font-size: 0.9rem;
    line-height: 1.6;
    max-height: 200px;
    overflow-y: auto;
}

.rejection-popover-arrow {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #ef4444;
}

.bonus-card-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
}

.bonus-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.bonus-badge i {
    font-size: 0.85rem;
}

/* Selection Indicator */
.bonus-card-check {
    /* Position */
    position: absolute;
    top: 12px; /* 8px grid spacing */
    right: 12px;
    
    /* Size - Minimum touch target: 44x44px (iOS) / 48x48px (Material) */
    width: 32px;
    height: 32px;
    
    /* Visual */
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    
    /* Layout */
    display: flex;
    align-items: center;
    justify-content: center;
    
    /* Interaction */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 3;
    
    /* Touch-friendly */
    -webkit-tap-highlight-color: transparent;
}

.bonus-card:hover .bonus-card-check {
    border-color: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.25);
}

.bonus-card.selected .bonus-card-check {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-color: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
}

.bonus-card-check i {
    color: white;
    font-size: 1rem; /* 16px - better visibility */
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    line-height: 1;
}

.bonus-card.selected .bonus-card-check i {
    opacity: 1;
    transform: scale(1);
}

/* Card highlight animation for scroll focus */
.card-highlight {
    animation: cardFocusPulse 1s ease-in-out;
}

@keyframes cardFocusPulse {
    0% {
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.08);
    }
    50% {
        box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3), 0 2px 10px rgba(102, 126, 234, 0.2);
        transform: scale(1.02);
    }
    100% {
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.08);
        transform: scale(1);
    }
}

/* Pulse Animation for Selected Card */
@keyframes pulse-border {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
    }
    50% {
        box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
    }
}

.bonus-card.selected {
    animation: pulse-border 2s ease-in-out infinite;
}

/* Request Button Inside Card */
.bonus-card-request-btn {
    width: 100%;
    margin-top: 1rem;
    padding: 0.875rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    display: none; /* Başlangıçta tamamen gizli */
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    letter-spacing: 0.02em;
    text-transform: uppercase;
    font-size: 0.875rem;
    position: relative;
    overflow: hidden;
}

/* Shimmer effect on button */
.bonus-card-request-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.bonus-card-request-btn:hover::before {
    left: 100%;
}

.bonus-card.selected .bonus-card-request-btn {
    display: flex; /* Sadece seçili kartta göster */
    animation: slideInUp 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.bonus-card-request-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.5);
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

.bonus-card-request-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.bonus-card-request-btn i {
    font-size: 1.1rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

/* Slide in animation */
@keyframes slideInUp {
    0% {
        opacity: 0;
        transform: translateY(15px) scale(0.95);
    }
    60% {
        transform: translateY(-5px) scale(1.02);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

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

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

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

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 2px dashed #dee2e6;
}

.empty-state i {
    font-size: 3rem;
    color: #adb5bd;
    margin-bottom: 1rem;
}

.empty-state h6 {
    color: var(--text-color);
    opacity: 0.7;
    margin-bottom: 0.5rem;
}

/* Processing & Result Containers */
#processing-container,
#result-container {
    padding: 2rem 2.5rem;
}

@media (max-width: 768px) {
    #processing-container,
    #result-container {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 480px) {
    #processing-container,
    #result-container {
        padding: 1rem 0.75rem;
    }
}

.cooldown-box {
    margin: 1rem 0;
}

@media (max-width: 480px) {
    .cooldown-box {
        margin: 0.75rem 0;
    }
    
    .cooldown-box i {
        font-size: 2.5rem !important;
    }
    
    .cooldown-box h4 {
        font-size: 1.25rem !important;
    }
    
    .cooldown-box p {
        font-size: 0.9rem !important;
    }
}

/* History Section */
#history-section {
    padding-top: 1rem;
    margin-top: 1rem;
    border-top: 1px solid #e9ecef;
}

/* Rules Modal Styling */
.rules-modal-content {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.rules-modal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 2rem;
    position: relative;
    text-align: center;
    border-bottom: none;
}

.rules-modal-icon {
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.rules-modal-icon i {
    font-size: 2rem;
    color: white;
}

.rules-modal-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.rules-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.rules-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.rules-modal-body {
    padding: 2.5rem;
    max-height: 60vh;
    overflow-y: auto;
    background: white;
}

.rules-modal-body::-webkit-scrollbar {
    width: 8px;
}

.rules-modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.rules-modal-body::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

.rules-modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* İçerik Stilleri */
.rules-modal-body h1,
.rules-modal-body h2,
.rules-modal-body h3,
.rules-modal-body h4,
.rules-modal-body h5,
.rules-modal-body h6 {
    color: var(--primary-color);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.rules-modal-body h1 { font-size: 1.75rem; }
.rules-modal-body h2 { font-size: 1.5rem; }
.rules-modal-body h3 { font-size: 1.25rem; }

.rules-modal-body p {
    line-height: 1.8;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.rules-modal-body ul,
.rules-modal-body ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    color: var(--text-color);
}

.rules-modal-body li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
    color: var(--text-color);
}

.rules-modal-body strong {
    color: var(--text-color);
    font-weight: 600;
}

.rules-modal-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.rules-modal-body table th,
.rules-modal-body table td {
    padding: 0.75rem;
    border: 1px solid #dee2e6;
}

.rules-modal-body table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
}

.rules-modal-body table tr:nth-child(even) {
    background: #f8f9fa;
}

.empty-rules {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-color);
    opacity: 0.7;
}

.empty-rules i {
    font-size: 4rem;
    opacity: 0.3;
    margin-bottom: 1rem;
}

.empty-rules p {
    font-size: 1.1rem;
    margin: 0;
}

.rules-modal-footer {
    padding: 1.5rem 2rem;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.rules-modal-btn-close {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border: none;
    color: white;
    padding: 0.875rem 2.5rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.rules-modal-btn-close:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.rules-modal-btn-close:active {
    transform: translateY(0);
}

/* Modal Animation */
.modal.fade .rules-modal-content {
    transform: scale(0.9);
    opacity: 0;
    transition: all 0.3s ease;
}

.modal.show .rules-modal-content {
    transform: scale(1);
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .client-card {
        border-radius: 15px;
    }
    
    #user-header-bar {
        padding: 0.625rem 1rem;
        flex-direction: row;
    }
    
    .user-info {
        font-size: 0.9rem;
    }
    
    .user-info i {
        font-size: 1.25rem;
    }
    
    .btn-change-user {
        padding: 0.35rem 0.6rem;
        font-size: 0.85rem;
    }
    
    .btn-history {
        padding: 0.35rem 0.6rem;
        font-size: 0.85rem;
        gap: 0.35rem;
    }
    
    .btn-history i {
        font-size: 1rem;
    }
    
    .history-badge {
        font-size: 0.65rem;
        padding: 0.1rem 0.35rem;
        min-width: 18px;
    }
    
    #username-form {
        padding: 2rem 1.5rem;
    }
    
    .user-form-icon {
        width: 60px;
        height: 60px;
    }
    
    .user-form-icon i {
        font-size: 2.25rem;
    }
    
    /* Bonus Description Modal - Mobile */
    #bonusDescriptionModal .modal-header {
        padding: 1rem;
    }
    
    #bonusDescriptionModal .modal-body {
        padding: 1.25rem;
    }
    
    #modal-bonus-description {
        font-size: 0.9rem;
        line-height: 1.6;
    }
    
    #bonusDescriptionModal .modal-footer {
        padding: 0 1.25rem 1.25rem 1.25rem;
    }
    
    /* History Modal - Mobile */
    #historyModal .modal-dialog {
        margin: 0.5rem;
        max-width: calc(100% - 1rem);
    }
    
    #historyModal .modal-content {
        height: calc(100vh - 1rem);
        max-height: calc(100vh - 1rem);
        border-radius: 16px;
    }
    
    #historyModal .modal-header {
        padding: 1rem 1.25rem;
        border-bottom: 1px solid #e2e8f0;
        background: white;
    }
    
    #historyModal .modal-header-content i {
        font-size: 1.25rem;
    }
    
    #historyModal .modal-title {
        font-size: 1.1rem;
    }
    
    #historyModal .modal-body {
        padding: 0;
        overflow-y: auto;
        flex: 1;
    }
    
    /* Hide table on mobile, show cards */
    .history-modal-table {
        display: none;
    }
    
    .history-mobile-cards {
        display: block;
        padding: 1rem;
    }
    
    .history-mobile-card {
        background: white;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 1rem;
        margin-bottom: 0.75rem;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    }
    
    .history-mobile-card:last-child {
        margin-bottom: 0;
    }
    
    .history-mobile-card-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 0.75rem;
    }
    
    .history-mobile-card-title {
        font-weight: 600;
        font-size: 0.875rem;
        color: var(--text-color);
        margin: 0;
        flex: 1;
        margin-right: 0.5rem;
    }
    
    .history-mobile-card-date {
        font-size: 0.75rem;
        color: var(--text-color);
        opacity: 0.7;
        white-space: nowrap;
    }
    
    .history-mobile-card-status {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    
    .history-mobile-card-status .badge {
        font-size: 0.7rem;
        padding: 0.25rem 0.5rem;
    }
    
    .history-mobile-card-status .btn-rejection-reason {
        padding: 0.25rem 0.375rem;
        font-size: 0.7rem;
    }
    
    .history-mobile-card-status .btn-rejection-reason i {
        font-size: 0.65rem;
    }
    
    .btn-rejection-reason {
        width: 24px;
        height: 24px;
    }
    
    .btn-rejection-reason i {
        font-size: 0.8rem;
    }
    
    .rejection-popover {
        max-width: 90vw;
        min-width: 260px;
        left: 5vw !important;
        right: 5vw;
    }
    
    .rejection-popover-header {
        padding: 0.75rem 1rem;
        font-size: 0.85rem;
    }
    
    .rejection-popover-body {
        padding: 1rem;
        font-size: 0.85rem;
    }
    
    #bonus-list {
        padding: 1.5rem 1rem;
    }
    
    #processing-container,
    #result-container {
        padding: 1.5rem 1rem;
    }
    
    .bonus-card {
        padding: 1rem 0.875rem;
        min-width: auto;
    }
    
    .bonus-card-icon {
        font-size: 1.25rem;
    }
    
    .bonus-card-title {
        font-size: 0.85rem;
        line-height: 1.3;
    }
    
    .bonus-card-description {
        font-size: 0.8rem;
    }
    
    .bonus-card-header {
        padding-right: 28px;
        gap: 0.625rem;
    }
    
    .bonus-card-check {
        width: 20px;
        height: 20px;
        top: 0.625rem;
        right: 0.625rem;
    }
    
    .bonus-card-check i {
        font-size: 0.75rem;
    }
    
    .bonus-card-request-btn {
        padding: 0.75rem 0.875rem;
        font-size: 0.8125rem;
    }
    
    .bonus-card-request-btn i {
        font-size: 1rem;
    }
    
    @keyframes slideInUp {
        0% {
            opacity: 0;
            transform: translateY(10px) scale(0.95);
        }
        60% {
            transform: translateY(-3px) scale(1.02);
        }
        100% {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }
    
    /* Rules Modal Responsive */
    .rules-modal-header {
        padding: 1.5rem 1rem;
    }
    
    .rules-modal-icon {
        width: 60px;
        height: 60px;
    }
    
    .rules-modal-icon i {
        font-size: 1.75rem;
    }
    
    .rules-modal-title {
        font-size: 1.25rem;
    }
    
    .rules-modal-body {
        padding: 1.5rem;
        max-height: 50vh;
    }
    
    .rules-modal-footer {
        padding: 1rem;
    }
    
    .rules-modal-btn-close {
        padding: 0.75rem 2rem;
        font-size: 0.9rem;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .bonus-card-title {
        font-size: 0.875rem;
    }
    
    .bonus-card-header {
        padding-right: 32px;
    }
}

/* Çok küçük ekranlar için ekstra optimizasyon */
@media (max-width: 400px) {
    .bonuses-grid {
        gap: 0.625rem;
    }
    
    .bonus-card {
        padding: 0.75rem;
        border-radius: 10px;
    }
    
    .bonus-card-title {
        font-size: 0.75rem;
        line-height: 1.2;
    }
    
    .bonus-card-description {
        font-size: 0.7rem;
        margin-bottom: 0.5rem;
    }
    
    .bonus-badge {
        font-size: 0.65rem;
        padding: 0.2rem 0.45rem;
    }
    
    .bonus-badge i {
        font-size: 0.75rem;
    }
    
    .bonus-card-icon {
        font-size: 1.1rem;
    }
    
    .bonus-card-header {
        gap: 0.5rem;
        padding-right: 26px;
        margin-bottom: 0.5rem;
    }
    
    .bonus-card-check {
        width: 18px;
        height: 18px;
        top: 0.5rem;
        right: 0.5rem;
    }
    
    .bonus-card-check i {
        font-size: 0.7rem;
    }
    
    .bonus-card-request-btn {
        padding: 0.625rem 0.75rem;
        font-size: 0.75rem;
        margin-top: 0.75rem;
    }
    
    .bonus-card-request-btn i {
        font-size: 0.9rem;
    }
}

