/* ========================================
   WALLET MODALS - COMPREHENSIVE STYLES
   Responsive across all devices
   ======================================== */

/* ========================================
   COMMON MODAL STYLES
   ======================================== */

/* Spinner for loading states */
.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Notification animations */
@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* Shake animation for errors */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* ========================================
   WALLET CONNECT MODAL
   ======================================== */

/* Wallet Modal Overlay */
.wallet-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.wallet-modal-overlay.show {
    opacity: 1;
    pointer-events: all;
}

.wallet-modal-container {
    max-width: 550px;
    width: 100%;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.98) 0%, rgba(30, 58, 138, 0.95) 100%);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5), 0 0 60px rgba(59, 130, 246, 0.3);
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    max-height: 90vh;
    overflow-y: auto;
}

.wallet-modal-overlay.show .wallet-modal-container {
    transform: scale(1) translateY(0);
}

.wallet-modal-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
    animation: modalGlow 10s linear infinite;
    pointer-events: none;
}

@keyframes modalGlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.wallet-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: rgba(148, 163, 184, 0.8);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.wallet-modal-close:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #EF4444;
    color: #EF4444;
    transform: rotate(90deg);
}

.wallet-modal-header {
    padding: 2.5rem 2rem 1.5rem;
    text-align: center;
    position: relative;
    z-index: 1;
}

.wallet-modal-header h2 {
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(135deg, #FFFFFF 0%, #60A5FA 50%, #FFD700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.wallet-modal-header p {
    font-size: 0.95rem;
    color: rgba(148, 163, 184, 0.8);
    font-weight: 500;
}

.wallet-modal-content {
    padding: 0 2rem 2rem;
    position: relative;
    z-index: 1;
}

/* Connect Options */
.connect-option {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 1rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.connect-option:hover {
    border-color: #60A5FA;
    transform: translateX(5px);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.3);
}

.option-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.option-content {
    flex: 1;
}

.option-content h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 0.25rem;
}

.option-content p {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    margin-bottom: 0.25rem;
}

.payment-info {
    font-size: 0.8rem !important;
    color: #FFD700 !important;
    font-weight: 600;
    margin-top: 0.5rem;
}

.connect-btn {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    border: 1px solid rgba(59, 130, 246, 0.5);
    border-radius: 0.5rem;
    color: white;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.connect-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.connect-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.primary-btn {
    background: linear-gradient(135deg, #10B981 0%, #059669 100%);
    border-color: rgba(16, 185, 129, 0.5);
}

.primary-btn:hover:not(:disabled) {
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

/* Divider */
.divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

.divider span {
    padding: 0 1rem;
    color: rgba(148, 163, 184, 0.6);
    font-size: 0.85rem;
    font-weight: 600;
}

/* Input Groups */
.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(148, 163, 184, 0.9);
    margin-bottom: 0.5rem;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.75rem;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: #60A5FA;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.input-group input::placeholder {
    color: rgba(148, 163, 184, 0.4);
}

/* Referral Section */
.referral-section {
    padding: 1.5rem;
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 1rem;
    margin-bottom: 1.5rem;
}

.referral-header {
    margin-bottom: 1rem;
}

.optional-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: #60A5FA;
    font-size: 0.85rem;
    font-weight: 700;
}

.required-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(255, 215, 0, 0.2);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 0.5rem;
    color: #FFD700;
    font-size: 0.85rem;
    font-weight: 700;
}

.referral-note {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    margin-bottom: 1rem;
    line-height: 1.5;
}

/* Balance Check Section */
.balance-check-section {
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: rgba(148, 163, 184, 0.9);
    font-weight: 500;
}

.checkbox-label input[type="checkbox"] {
    width: 1.25rem;
    height: 1.25rem;
    cursor: pointer;
    accent-color: #3B82F6;
}

.info-box {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0.75rem;
    margin-top: 1rem;
}

.info-box svg {
    color: #60A5FA;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.info-box span {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.8);
    line-height: 1.5;
}

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 1.25rem;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    border: 1px solid rgba(255, 215, 0, 0.5);
    border-radius: 0.75rem;
    color: #0F172A;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(255, 215, 0, 0.5);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Help Section */
.help-section {
    text-align: center;
}

.help-btn {
    background: transparent;
    border: none;
    color: #60A5FA;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: underline;
}

.help-btn:hover {
    color: #FFD700;
}

/* ========================================
   WALLET PROFILE MODAL
   ======================================== */

.wallet-profile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.wallet-profile-overlay.show {
    opacity: 1;
    pointer-events: all;
}

.wallet-profile-container {
    max-width: 500px;
    width: 100%;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.98) 0%, rgba(30, 58, 138, 0.95) 100%);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    max-height: 90vh;
    overflow-y: auto;
}

.wallet-profile-overlay.show .wallet-profile-container {
    transform: scale(1);
}

.wallet-profile-content {
    padding: 2rem;
}

/* Profile Header */
.wallet-profile-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
    position: relative;
}

.wallet-profile-icon-container {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #3B82F6, #2563EB);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.wallet-profile-header-text {
    flex: 1;
    min-width: 0;
}

.wallet-details-label {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    margin-bottom: 0.5rem;
}

.wallet-balance-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.wallet-balance-row svg {
    color: #60A5FA;
    flex-shrink: 0;
}

.wallet-balance-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
    font-family: 'Orbitron', monospace;
}

.wallet-total-usd {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
}

.wallet-profile-close-btn {
    position: absolute;
    top: 0;
    right: 0;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: rgba(148, 163, 184, 0.8);
    cursor: pointer;
    transition: all 0.3s ease;
}

.wallet-profile-close-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #EF4444;
    color: #EF4444;
    transform: rotate(90deg);
}

/* Rank Section */
.wallet-rank-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 1rem;
    margin-bottom: 1.5rem;
}

.wallet-rank-info {
    flex: 1;
}

.wallet-rank-label {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    margin-bottom: 0.5rem;
}

.wallet-rank-badge {
    font-size: 1.1rem;
    font-weight: 700;
}

.wallet-view-progress-btn {
    padding: 0.5rem 1rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: #60A5FA;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.wallet-view-progress-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    transform: translateY(-2px);
}

/* Info Sections */
.wallet-info-section,
.wallet-referral-section {
    padding: 1.5rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 1rem;
    margin-bottom: 1.5rem;
}

.wallet-info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.wallet-info-label {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    font-weight: 600;
}

.wallet-copy-btn {
    padding: 0.5rem 0.75rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: #60A5FA;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.wallet-copy-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    transform: scale(1.05);
}

.wallet-address-text {
    font-size: 0.9rem;
    color: white;
    font-family: monospace;
    word-break: break-all;
    padding: 0.75rem;
    background: rgba(30, 41, 59, 0.6);
    border-radius: 0.5rem;
}

.wallet-referral-code {
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFD700;
    font-family: 'Orbitron', monospace;
    letter-spacing: 0.1em;
    text-align: center;
    padding: 1rem;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 0.75rem;
    margin-bottom: 0.75rem;
}

.wallet-referral-hint {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    text-align: center;
    margin-bottom: 0;
}

/* Balance Section */
.wallet-balance-section {
    padding: 1.5rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 1rem;
    margin-bottom: 1.5rem;
}

.wallet-balance-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wallet-balance-label {
    font-size: 0.85rem;
    color: rgba(148, 163, 184, 0.7);
    margin-bottom: 0.5rem;
}

.wallet-balance-amount {
    font-size: 1.75rem;
    font-weight: 700;
    color: white;
    font-family: 'Orbitron', monospace;
}

.wallet-refresh-btn {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: #60A5FA;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wallet-refresh-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    transform: rotate(180deg);
}

.wallet-refresh-btn.spinning svg {
    animation: spin 1s linear infinite;
}

/* Connection Status */
.wallet-connection-status {
    margin-bottom: 1.5rem;
}

.connection-indicator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0.75rem;
}

.connection-dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
    animation: pulse 2s ease-in-out infinite;
}

.connection-indicator.view-only .connection-dot {
    background: #F59E0B;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.connection-text {
    font-size: 0.9rem;
    color: rgba(148, 163, 184, 0.9);
    font-weight: 600;
}

/* Disconnect Button */
.wallet-disconnect-btn {
    width: 100%;
    padding: 1.25rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 0.75rem;
    color: #EF4444;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.wallet-disconnect-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(239, 68, 68, 0.3);
}

/* ========================================
   HELP MODAL
   ======================================== */

.help-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 11000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.help-modal-overlay.show {
    opacity: 1;
    pointer-events: all;
}

.help-modal-container {
    max-width: 600px;
    width: 100%;
    background: rgba(15, 23, 42, 0.98);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.help-modal-overlay.show .help-modal-container {
    transform: scale(1);
}

.help-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
    flex-shrink: 0;
}

.help-modal-header h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #FFFFFF;
    font-family: 'Orbitron', sans-serif;
}

.help-modal-close {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.5rem;
    color: rgba(148, 163, 184, 0.8);
    font-size: 1.75rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.3s ease;
}

.help-modal-close:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: #EF4444;
    color: #EF4444;
}

.help-modal-content {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
}

.help-section {
    margin-bottom: 2rem;
}

.help-section:last-child {
    margin-bottom: 0;
}

.help-section h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 0.75rem;
}

.help-section p {
    font-size: 0.95rem;
    color: rgba(148, 163, 184, 0.8);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.help-section ol,
.help-section ul {
    padding-left: 1.5rem;
    margin-top: 0.75rem;
}

.help-section li {
    font-size: 0.95rem;
    color: rgba(148, 163, 184, 0.8);
    line-height: 1.8;
    margin-bottom: 0.5rem;
}

.help-section.important {
    padding: 1.5rem;
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 1rem;
}

.help-section.important h3 {
    color: #60A5FA;
}

.help-section.important ul {
    list-style: none;
    padding-left: 0;
}

.help-section.important li {
    padding-left: 1.5rem;
    position: relative;
}

.help-section.important li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #60A5FA;
    font-weight: bold;
}

.help-modal-footer {
    padding: 1rem 2rem 2rem;
    text-align: center;
    flex-shrink: 0;
}

.help-ok-btn {
    padding: 1rem 3rem;
    background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
    border: 1px solid rgba(59, 130, 246, 0.5);
    border-radius: 0.75rem;
    color: white;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.help-ok-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(59, 130, 246, 0.5);
}

/* ========================================
   RESPONSIVE STYLES
   ======================================== */

/* Tablets and below */
@media (max-width: 768px) {
    .wallet-modal-container,
    .wallet-profile-container {
        max-height: 85vh;
    }

    .wallet-modal-header h2 {
        font-size: 1.75rem;
    }

    .connect-option {
        gap: 1rem;
    }

    .option-content h3 {
        font-size: 1rem;
    }

    .wallet-balance-value {
        font-size: 1.1rem;
    }

    .wallet-balance-amount {
        font-size: 1.5rem;
    }

    .wallet-referral-code {
        font-size: 1.25rem;
    }
}

/* Mobile devices */
@media (max-width: 640px) {
    .wallet-modal-overlay,
    .wallet-profile-overlay,
    .help-modal-overlay {
        padding: 0.5rem;
    }

    .wallet-modal-container,
    .wallet-profile-container {
        border-radius: 1rem;
        max-height: 95vh;
    }

    .wallet-modal-header,
    .wallet-profile-content {
        padding: 2rem 1.5rem 1rem;
    }

    .wallet-modal-content {
        padding: 0 1.5rem 1.5rem;
    }

    .wallet-modal-header h2 {
        font-size: 1.5rem;
    }

    .wallet-modal-header p {
        font-size: 0.85rem;
    }

    .connect-option {
        flex-direction: column;
        text-align: center;
        padding: 1.25rem;
    }

    .option-content {
        text-align: center;
    }

    .option-icon {
        font-size: 2rem;
    }

    .connect-btn {
        width: 100%;
        justify-content: center;
    }

    .wallet-rank-section {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .wallet-view-progress-btn {
        width: 100%;
        justify-content: center;
    }

    .wallet-balance-display {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .wallet-refresh-btn {
        margin: 0 auto;
    }

    .wallet-profile-header {
        flex-wrap: wrap;
    }

    .wallet-balance-value {
        font-size: 1rem;
    }

    .wallet-balance-amount {
        font-size: 1.25rem;
    }

    .wallet-referral-code {
        font-size: 1.1rem;
        padding: 0.75rem;
    }

    .help-modal-header h2 {
        font-size: 1.5rem;
    }

    .help-modal-content {
        padding: 1.5rem;
    }

    .help-section {
        margin-bottom: 1.5rem;
    }

    .help-ok-btn {
        padding: 0.875rem 2rem;
        width: 100%;
    }

    .submit-btn {
        font-size: 1rem;
    }

    .wallet-copy-btn {
        font-size: 0.75rem;
        padding: 0.4rem 0.6rem;
    }
}

/* Small mobile devices */
@media (max-width: 375px) {
    .wallet-modal-header h2 {
        font-size: 1.25rem;
    }

    .option-icon {
        font-size: 1.75rem;
    }

    .option-content h3 {
        font-size: 0.95rem;
    }

    .option-content p {
        font-size: 0.8rem;
    }

    .wallet-balance-value,
    .wallet-balance-amount {
        font-size: 1rem;
    }

    .wallet-referral-code {
        font-size: 1rem;
        letter-spacing: 0.05em;
    }
}

/* Landscape mode for phones */
@media (max-height: 600px) and (orientation: landscape) {
    .wallet-modal-container,
    .wallet-profile-container,
    .help-modal-container {
        max-height: 95vh;
    }

    .wallet-modal-header,
    .wallet-profile-content {
        padding: 1.5rem 1.5rem 1rem;
    }

    .wallet-modal-content {
        padding: 0 1.5rem 1.5rem;
    }

    .connect-option {
        padding: 1rem;
    }

    .help-modal-content {
        padding: 1rem;
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

/* Focus styles for keyboard navigation */
button:focus-visible,
input:focus-visible,
select:focus-visible {
    outline: 2px solid #60A5FA;
    outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High contrast mode adjustments */
@media (prefers-contrast: high) {
    .wallet-modal-container,
    .wallet-profile-container,
    .help-modal-container {
        border-width: 2px;
    }

    .connect-option,
    .wallet-info-section,
    .wallet-referral-section {
        border-width: 2px;
    }
}

/* Print styles */
@media print {
    .wallet-modal-overlay,
    .wallet-profile-overlay,
    .help-modal-overlay {
        display: none;
    }
}
/* Locked Referral Section Styles */
.referral-section.locked {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(5, 150, 105, 0.05) 100%);
    border: 2px solid rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
    margin: 1.5rem 0;
}

.locked-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #10B981 0%, #059669 100%);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.875rem;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
    }
    50% {
        box-shadow: 0 4px 20px rgba(16, 185, 129, 0.5);
    }
}

.referral-section.locked .referral-note {
    color: #10B981;
    font-weight: 500;
    margin: 1rem 0;
}

.referral-section.locked .input-group.locked-input {
    position: relative;
}

.locked-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.25rem;
    pointer-events: none;
    z-index: 10;
    animation: lockShake 0.5s ease-in-out;
}

@keyframes lockShake {
    0%, 100% { transform: translateY(-50%) rotate(0deg); }
    25% { transform: translateY(-50%) rotate(-5deg); }
    75% { transform: translateY(-50%) rotate(5deg); }
}

.referral-section.locked input[readonly],
input.locked-input {
    background: linear-gradient(135deg, #10B981 0%, #059669 100%) !important;
    color: white !important;
    cursor: not-allowed !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    padding-right: 3rem !important;
    font-weight: 600 !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    text-align: center;
    letter-spacing: 2px;
}

.referral-section.locked input[readonly]:focus,
input.locked-input:focus {
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.2) !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
    outline: none !important;
}

.referral-section.locked input[readonly]::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Locked input label style */
.referral-section.locked label {
    color: #10B981;
    font-weight: 600;
}
/* ==================== REFERRAL LINK SECTION IN PROFILE MODAL ==================== */

.wallet-referral-link-section {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(5, 150, 105, 0.05) 100%);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 12px;
  padding: 1.25rem;
  margin: 1rem 0;
}

.wallet-referral-link-display {
  margin: 1rem 0;
}

.wallet-referral-link-input {
  width: 100%;
  padding: 0.875rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #e5e7eb;
  font-family: monospace;
  font-size: 0.75rem;
  text-overflow: ellipsis;
  cursor: pointer;
  transition: all 0.3s ease;
}

.wallet-referral-link-input:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(16, 185, 129, 0.3);
}

.wallet-referral-link-input:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.wallet-referral-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}

.wallet-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Rajdhani', sans-serif;
}

.wallet-action-btn.copy-link {
  background: linear-gradient(135deg, #10B981 0%, #059669 100%);
  color: white;
}

.wallet-action-btn.copy-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.wallet-action-btn.copy-link:active {
  transform: translateY(0);
}

.wallet-action-btn.share-link {
  background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
  color: white;
}

.wallet-action-btn.share-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.wallet-action-btn.share-link:active {
  transform: translateY(0);
}

.wallet-referral-benefits {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.benefits-title {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.75rem;
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.benefit-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  transition: all 0.3s ease;
}

.benefit-item:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}

.benefit-icon {
  font-size: 1.25rem;
  margin-bottom: 0.25rem;
}

.benefit-text {
  color: #10B981;
  font-size: 0.75rem;
  font-weight: 600;
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .wallet-referral-actions {
    grid-template-columns: 1fr;
  }

  .benefits-grid {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .benefit-item {
    flex-direction: row;
    justify-content: center;
    gap: 0.5rem;
  }

  .benefit-icon {
    margin-bottom: 0;
  }

  .wallet-referral-link-input {
    font-size: 0.625rem;
  }
}

/* Loading/Spinning Animation for Refresh Button */
.wallet-refresh-btn.spinning svg {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* Enhance existing copy button for referral code */
.wallet-copy-btn.referral-copy {
  background: linear-gradient(135deg, #10B981 0%, #059669 100%);
}

.wallet-copy-btn.referral-copy:hover {
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}