/* CSS Variables for Light Theme */
:root {
    --bg-primary: #F5F7FA;
    --bg-secondary: #FFFFFF;
    --bg-tertiary: #F0F2F5;
    --text-primary: #1A1A1A;
    --text-secondary: #6B7280;
    --text-tertiary: #9CA3AF;
    --border-color: #E4E7EB;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(91, 159, 255, 0.25);
    --accent-color: #4A90E2;
    --gradient-start: #5B9FFF;
    --gradient-end: #C061FF;
    --button-bg: #F0F2F5;
    --button-hover: #E4E7EB;
}

/* Dark Theme Variables */
body.dark {
    --bg-primary: #0F0F0F;
    --bg-secondary: #1A1A1A;
    --bg-tertiary: #262626;
    --text-primary: #F0F0F0;
    --text-secondary: #A0A0A0;
    --text-tertiary: #707070;
    --border-color: #2A2A2A;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.5);
    --accent-color: #5B9FFF;
    --gradient-start: #4A7FDF;
    --gradient-end: #9051DF;
    --button-bg: #262626;
    --button-hover: #333333;
}

/* Dark theme specific adjustments */
body.dark .balance-card {
    box-shadow: 0 10px 40px rgba(91, 159, 255, 0.15);
    background: linear-gradient(135deg, #3A5FBF 0%, #7041AF 100%);
}

body.dark .action-buttons {
    background: #1F1F1F;
    border: 1px solid #333333;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* Make action buttons more visible in dark theme */
body.dark .action-btn-icon {
    background: #2D2D2D;
    background: linear-gradient(135deg, #3A3A3A 0%, #2D2D2D 100%);
    border: 1px solid #404040;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

body.dark .action-btn:hover .action-btn-icon {
    background: linear-gradient(135deg, #454545 0%, #383838 100%);
    border-color: #505050;
    box-shadow: 0 6px 16px rgba(91, 159, 255, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

body.dark .action-btn:active .action-btn-icon {
    background: linear-gradient(135deg, #323232 0%, #282828 100%);
}

body.dark .action-btn-icon svg {
    stroke: #FFFFFF;
    stroke-width: 2.5;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.8));
}

body.dark .action-btn span {
    color: #F0F0F0;
    font-weight: 600;
}

body.dark .wallet-item {
    background: #1A1A1A;
    border: 1px solid #2A2A2A;
}

body.dark .wallet-item:hover {
    background: #222222;
}

body.dark .currency-icon {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

body.dark .bottom-nav {
    background: #1A1A1A;
    border-top: 1px solid #2A2A2A;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Smooth theme transitions */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    padding-bottom: 70px; /* Space for bottom nav */
    transition: background 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 100%;
    margin: 0 auto;
    min-height: 100vh;
    position: relative;
}

/* App Title Bar */
.app-header {
    background: white;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.app-title {
    font-size: 20px;
    font-weight: 700;
    color: #1A1A1A;
}

.app-actions {
    display: flex;
    gap: 12px;
}

/* Balance Card - Gradient Style like TronixPay */
.balance-card {
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    margin: 16px;
    padding: 24px;
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.balance-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 150%;
    height: 150%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

.balance-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    position: relative;
    z-index: 1;
}

.balance-label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.balance-actions {
    display: flex;
    gap: 10px;
}

.balance-refresh {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.balance-refresh:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(180deg);
}

.balance-refresh svg {
    width: 18px;
    height: 18px;
    stroke: white;
    fill: none;
    stroke-width: 2;
}

.balance-amount {
    color: white;
    font-size: 48px;
    font-weight: 700;
    text-align: center;
    margin: 16px 0;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 8px;
}

.balance-amount .currency-symbol {
    font-size: 32px;
    opacity: 0.9;
}

.balance-amount .amount-value {
    letter-spacing: -1px;
}

.balance-visibility {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    margin-left: 12px;
}

.balance-visibility:hover {
    background: rgba(255, 255, 255, 0.3);
}

.balance-visibility svg {
    width: 20px;
    height: 20px;
    stroke: white;
    fill: none;
}

.wallet-address {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
    margin-top: 20px;
}

.wallet-address-text {
    color: rgba(255, 255, 255, 0.95);
    font-size: 14px;
    font-family: 'SF Mono', Monaco, 'Courier New', monospace;
    letter-spacing: 0.5px;
}

.wallet-address-actions {
    display: flex;
    gap: 8px;
}

.wallet-address-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 8px;
    padding: 6px 10px;
    color: white;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.wallet-address-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Action Buttons Grid - Round Style like TronixPay */
.action-buttons {
    display: flex;
    justify-content: space-around;
    padding: 24px 16px;
    background: var(--bg-secondary);
    margin: 0 16px;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    padding: 8px;
}

.action-btn:active {
    transform: scale(0.95);
}

.action-btn-icon {
    width: 56px;
    height: 56px;
    background: var(--button-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.action-btn:hover .action-btn-icon {
    background: var(--button-hover);
    transform: scale(1.05);
}

.action-btn-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--text-primary);
    fill: none;
    stroke-width: 2;
}

.action-btn span {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Assets Section */
.assets-section {
    margin: 24px 16px;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

/* Wallet List - Modern Style */
.wallets-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wallet-item {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s;
    cursor: pointer;
}

.wallet-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.wallet-currency {
    display: flex;
    align-items: center;
    gap: 12px;
}

.currency-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 20px;
    position: relative;
}

.currency-icon.trx {
    background: #FF5454;
    color: white;
}

.currency-icon.usdt {
    background: #50AF95;
    color: white;
}

.currency-icon.ton {
    background: linear-gradient(135deg, #0098EA 0%, #0066CC 100%);
    color: white;
}

.currency-verified {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 18px;
    height: 18px;
    background: #4A90E2;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.currency-verified svg {
    width: 12px;
    height: 12px;
    stroke: white;
    fill: none;
    stroke-width: 2.5;
}

.wallet-currency-info {
    display: flex;
    flex-direction: column;
}

.wallet-currency-name {
    font-weight: 600;
    font-size: 16px;
    color: var(--text-primary);
}

.wallet-currency-rate {
    font-size: 13px;
    color: var(--text-tertiary);
    margin-top: 2px;
}

.wallet-balance {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.wallet-balance-crypto {
    font-weight: 600;
    font-size: 18px;
    color: var(--text-primary);
}

.wallet-balance-fiat {
    font-size: 14px;
    color: var(--text-secondary);
}

.wallet-arrow {
    margin-left: 8px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wallet-arrow svg {
    width: 16px;
    height: 16px;
    stroke: var(--accent-color);
    fill: none;
    stroke-width: 2;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    z-index: 100;
    border-top: 1px solid var(--border-color);
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--text-tertiary);
}

.nav-item.active {
    color: var(--accent-color);
}

.nav-item:hover {
    color: var(--accent-color);
}

.nav-item-icon {
    width: 24px;
    height: 24px;
}

.nav-item-icon svg {
    width: 100%;
    height: 100%;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.nav-item-label {
    font-size: 11px;
    font-weight: 500;
}

/* Loading States */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    color: var(--text-secondary);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--button-bg);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Settings Styles */
.settings-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
    padding: 20px 0;
    border-bottom: 1px solid #E4E7EB;
}

.settings-header h1 {
    font-size: 24px;
    font-weight: 700;
}

.back-btn {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #4A90E2;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
}

.back-btn svg {
    width: 20px;
    height: 20px;
}

.settings-content {
    padding: 0 20px;
}

.settings-section {
    background: white;
    border-radius: 16px;
    margin-bottom: 20px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.settings-item {
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid #F0F2F5;
}

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

.settings-item:hover {
    background: #F9FAFB;
}

.settings-item-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.settings-label {
    font-size: 16px;
    color: #1A1A1A;
    font-weight: 500;
}

.settings-value {
    font-size: 14px;
    color: #6B7280;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #4B5563;
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-size: 16px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(91, 159, 255, 0.15);
}

body.dark .form-input {
    background: #262626;
    border-color: #333333;
}

body.dark .form-input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(91, 159, 255, 0.1);
}

/* Buttons */
.primary-btn {
    background: linear-gradient(135deg, #5B9FFF 0%, #4A90E2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.3);
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(74, 144, 226, 0.4);
}

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

.primary-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.secondary-btn {
    background: var(--button-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.secondary-btn:hover {
    background: var(--button-hover);
}

/* Modal Styles */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    animation: fadeIn 0.2s;
}

body.dark .modal-backdrop {
    background: rgba(0, 0, 0, 0.7);
}

.modal-content {
    background: var(--bg-secondary);
    border-radius: 24px 24px 0 0;
    padding: 24px;
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideUp 0.3s;
    border: 1px solid var(--border-color);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.modal-header {
    margin-bottom: 20px;
    text-align: center;
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-buttons {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.modal-buttons button {
    flex: 1;
}

/* Toast Notifications */
.toast-notification {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: #1F2937;
    color: white;
    padding: 12px 24px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 2000;
    opacity: 0;
    transition: all 0.3s;
}

.toast-notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Empty States */
.empty-state-container {
    text-align: center;
    padding: 60px 20px;
    color: #6B7280;
}

.empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state-container h3 {
    font-size: 20px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
}

.empty-state-container p {
    font-size: 14px;
    margin-bottom: 24px;
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }

/* Common Header for Sub-Views */
.header, .send-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 20px;
}

.header h1, .send-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    flex: 1;
    text-align: center;
}

.back-btn {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    transition: all 0.2s;
}

.back-btn:hover {
    opacity: 0.7;
}

.back-btn svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

/* TopUp View Styles */
.topup-container {
    padding: 0 20px;
    max-width: 500px;
    margin: 0 auto;
}

.currency-selector {
    margin-bottom: 24px;
}

.currency-selector label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.currency-selector select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.currency-selector select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(91, 159, 255, 0.15);
}

.qr-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 16px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}

.qr-container canvas {
    border-radius: 8px;
}

.address-container {
    margin-bottom: 24px;
}

.address-container label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.address-box {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.address-box span {
    flex: 1;
    font-family: 'SF Mono', Monaco, monospace;
    font-size: 14px;
    color: var(--text-primary);
    word-break: break-all;
}

.copy-btn {
    padding: 8px 12px;
    background: var(--button-bg);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--text-primary);
}

.copy-btn:hover {
    background: var(--button-hover);
}

.copy-btn svg {
    width: 20px;
    height: 20px;
}

.warning-box, .info-box {
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 12px;
    margin-bottom: 16px;
    display: flex;
    gap: 12px;
    border: 1px solid var(--border-color);
}

.warning-box {
    background: #FEF2E8;
    border-color: #F59E0B;
}

body.dark .warning-box {
    background: #422C1D;
    border-color: #92400E;
}

.warning-box svg {
    width: 24px;
    height: 24px;
    fill: #F59E0B;
    flex-shrink: 0;
}

.info-box {
    display: block;
}

.info-box h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.info-box ul {
    list-style: none;
    padding: 0;
}

.info-box li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 14px;
}

.info-box li:before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--accent-color);
}

/* Send View Styles */
.send-content {
    padding: 0 20px;
    max-width: 500px;
    margin: 0 auto;
}

.transfer-options {
    margin-top: 20px;
}

.transfer-options h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.transfer-option {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.transfer-option:hover {
    border-color: var(--accent-color);
    box-shadow: var(--shadow-md);
}

.transfer-option-icon {
    width: 48px;
    height: 48px;
    background: var(--button-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.transfer-option-icon svg {
    width: 28px;
    height: 28px;
    fill: var(--accent-color);
}

.transfer-option-content {
    flex: 1;
}

.transfer-option-content h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.transfer-option-content p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

.transfer-option-arrow svg {
    width: 24px;
    height: 24px;
    fill: var(--text-tertiary);
}

.internal-transfer, .coin-selection {
    padding-top: 20px;
}

.selected-coin-header {
    margin-bottom: 24px;
}

.selected-coin {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.selected-coin:hover {
    border-color: var(--accent-color);
}

.currency-icon, .coin-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 18px;
    color: white;
}

.usdt-icon {
    background: #50AF95;
}

.ton-icon {
    background: linear-gradient(135deg, #0098EA 0%, #0066CC 100%);
}

.currency-name, .coin-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.currency-balance, .coin-balance {
    font-size: 14px;
    color: var(--text-secondary);
}

.coin-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.coin-item:hover {
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.coin-info {
    flex: 1;
}

.recipient-info {
    margin-top: 8px;
    font-size: 14px;
}

.recipient-found {
    color: #16A34A;
    padding: 8px 12px;
    background: #DCFCE7;
    border-radius: 8px;
}

body.dark .recipient-found {
    background: #14532D;
    color: #86EFAC;
}

.recipient-not-found {
    color: #DC2626;
    padding: 8px 12px;
    background: #FEE2E2;
    border-radius: 8px;
}

body.dark .recipient-not-found {
    background: #7F1D1D;
    color: #FCA5A5;
}

.amount-hint {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

.confirm-transfer, .success-animation {
    text-align: center;
}

.transfer-summary {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    margin: 20px 0;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

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

.summary-item.total {
    font-weight: 600;
    font-size: 18px;
    color: var(--text-primary);
    padding-top: 16px;
}

.summary-label {
    color: var(--text-secondary);
}

.summary-value {
    color: var(--text-primary);
    font-weight: 500;
}

.confirm-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.confirm-actions button {
    flex: 1;
}

/* Payment View Styles */
.payment-view {
    padding: 0;
    max-width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

.section-header {
    text-align: center;
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.section-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

#scanner-container {
    position: relative;
    flex: 1;
    background: #000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#qr-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.scanner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    background: radial-gradient(circle at center, transparent 150px, rgba(0, 0, 0, 0.7) 180px);
}

.scanner-frame {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 280px;
    height: 280px;
    pointer-events: none;
}

.scanner-frame::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 2px solid transparent;
    border-radius: 24px;
    background: linear-gradient(45deg, var(--gradient-start), var(--gradient-end)) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask-composite: exclude;
    animation: scanner-pulse 2s ease-in-out infinite;
}

/* Corner markers */
.scanner-frame::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 24px;
    background:
        linear-gradient(to right, var(--accent-color) 30px, transparent 30px) top left,
        linear-gradient(to bottom, var(--accent-color) 30px, transparent 30px) top left,
        linear-gradient(to left, var(--accent-color) 30px, transparent 30px) top right,
        linear-gradient(to bottom, var(--accent-color) 30px, transparent 30px) top right,
        linear-gradient(to right, var(--accent-color) 30px, transparent 30px) bottom left,
        linear-gradient(to top, var(--accent-color) 30px, transparent 30px) bottom left,
        linear-gradient(to left, var(--accent-color) 30px, transparent 30px) bottom right,
        linear-gradient(to top, var(--accent-color) 30px, transparent 30px) bottom right;
    background-size: 3px 3px;
    background-repeat: no-repeat;
}

/* Scanning line animation */
.scanner-line {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 240px;
    height: 2px;
    margin-left: -120px;
    margin-top: -140px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    animation: scanner-line 2s linear infinite;
}

@keyframes scanner-line {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(280px);
    }
}

@keyframes scanner-pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.scanner-hint {
    position: absolute;
    bottom: 120px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-size: 16px;
    font-weight: 500;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    padding: 0 20px;
    pointer-events: none;
}

#scanner-container .btn {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    min-width: 200px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    z-index: 10;
}

#scanner-container .btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
}

.payment-data {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
}

.payment-info {
    margin: 16px 0;
}

.data-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.data-row:last-child {
    border-bottom: none;
}

.data-label {
    color: var(--text-secondary);
    font-size: 14px;
}

.data-value {
    color: var(--text-primary);
    font-weight: 500;
    text-align: right;
}

.currency-selector {
    margin-top: 20px;
}

.currency-option {
    display: flex;
    justify-content: space-between;
    padding: 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.currency-option:hover {
    border-color: var(--accent-color);
    box-shadow: var(--shadow-sm);
}

.payment-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.payment-actions button {
    flex: 1;
}

/* Buttons - Updated for consistency */
.btn {
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(91, 159, 255, 0.3);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(91, 159, 255, 0.4);
}

.btn-secondary {
    background: var(--button-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--button-hover);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.full-width {
    width: 100%;
}

/* Success Animation */
.success-animation {
    padding: 40px 20px;
    text-align: center;
}

.success-circle {
    width: 120px;
    height: 120px;
    margin: 0 auto 24px;
}

.checkmark {
    stroke: #4A90E2;
    stroke-width: 2;
    fill: none;
}

.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: #4A90E2;
}

.checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
}

.checkmark-circle.animate {
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark-check.animate {
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

/* Error Messages */
.error-message {
    background: #FEE2E2;
    border: 1px solid #FCA5A5;
    color: #DC2626;
    padding: 12px 16px;
    border-radius: 12px;
    margin: 16px 0;
    text-align: center;
}

body.dark .error-message {
    background: #7F1D1D;
    border-color: #991B1B;
    color: #FCA5A5;
}

/* Error Container for Payment View */
.error-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    min-height: 400px;
    text-align: center;
}

.error-icon {
    margin-bottom: 24px;
    color: #DC2626;
    animation: shake 0.5s ease-in-out;
}

body.dark .error-icon {
    color: #EF4444;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.error-container h3 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.error-container p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 300px;
}

.error-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    max-width: 300px;
}

.error-actions .btn {
    width: 100%;
}

/* Spinner */
.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* P2P Specific Styles */
.p2p-container {
    padding: 0;
}

.p2p-header {
    background: white;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.p2p-tabs {
    display: flex;
    gap: 8px;
    padding: 16px;
    background: white;
}

.p2p-tab {
    flex: 1;
    padding: 10px;
    background: #F3F4F6;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    color: #6B7280;
    cursor: pointer;
    transition: all 0.2s;
}

.p2p-tab.active {
    background: #4A90E2;
    color: white;
}

.order-card {
    background: white;
    padding: 16px;
    margin: 8px 16px;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.2s;
    cursor: pointer;
}

.order-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.order-type {
    font-size: 14px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 8px;
}

.order-type.buy {
    background: #DCFCE7;
    color: #16A34A;
}

.order-type.sell {
    background: #FEE2E2;
    color: #DC2626;
}

.order-price {
    font-size: 18px;
    font-weight: 700;
    color: #1A1A1A;
}

.order-details {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #F0F2F5;
}

.order-amount {
    font-size: 14px;
    color: #6B7280;
}

.order-limits {
    font-size: 12px;
    color: #9CA3AF;
}

.order-payment-methods {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.payment-method-badge {
    padding: 4px 8px;
    background: #F3F4F6;
    border-radius: 6px;
    font-size: 11px;
    color: #4B5563;
}

/* Merchant Styles */
.store-card {
    background: white;
    padding: 20px;
    margin: 16px;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.2s;
}

.store-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.store-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.store-info h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1A1A1A;
    margin-bottom: 4px;
}

.store-url {
    font-size: 14px;
    color: #6B7280;
}

.store-status {
    display: flex;
    align-items: center;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.active {
    background: #DCFCE7;
    color: #16A34A;
}

.status-badge.inactive {
    background: #F3F4F6;
    color: #6B7280;
}

.store-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin: 16px 0;
    padding: 16px 0;
    border-top: 1px solid #F0F2F5;
    border-bottom: 1px solid #F0F2F5;
}

.stat-item {
    text-align: center;
}

.stat-label {
    font-size: 12px;
    color: #9CA3AF;
    display: block;
    margin-bottom: 4px;
}

.stat-value {
    font-size: 16px;
    font-weight: 600;
    color: #1A1A1A;
}

.store-actions {
    display: flex;
    gap: 8px;
    margin-top: 16px;
}

.store-action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px;
    background: #F3F4F6;
    border: none;
    border-radius: 10px;
    color: #4B5563;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.store-action-btn:hover {
    background: #E5E7EB;
}

.store-action-btn.danger {
    color: #DC2626;
}

.store-action-btn.danger:hover {
    background: #FEE2E2;
}

.store-action-btn svg {
    width: 16px;
    height: 16px;
}

/* Store actions duplicate - simplified version */
.store-detail-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 10px;
    background: #F3F4F6;
    border: none;
    border-radius: 8px;
    color: #4B5563;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.store-detail-btn:hover {
    background: #E5E7EB;
}

.store-detail-btn svg {
    width: 18px;
    height: 18px;
}

/* Trader Payment Waiting Styles */
.payment-waiting {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    min-height: 400px;
    text-align: center;
}

.waiting-spinner {
    margin-bottom: 24px;
}

.waiting-spinner .spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--button-bg);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.payment-waiting h3 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.payment-waiting p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 300px;
}

.payment-timer {
    width: 100%;
    max-width: 300px;
    margin-bottom: 32px;
}

.timer-text {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

#payment-timer-display {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    font-family: 'SF Mono', Monaco, monospace;
}

.timer-bar {
    width: 100%;
    height: 8px;
    background: var(--button-bg);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.timer-progress {
    height: 100%;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border-radius: 4px;
    transition: width 1s linear, background-color 0.3s ease;
}

.payment-info-waiting {
    background: var(--bg-tertiary);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
    width: 100%;
    max-width: 300px;
}

.payment-info-waiting .info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.payment-info-waiting .info-row:first-child {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.payment-info-waiting .info-row span {
    font-size: 14px;
    color: var(--text-secondary);
}

.payment-info-waiting .info-row strong {
    font-size: 16px;
    color: var(--text-primary);
    font-weight: 600;
}

.waiting-actions {
    width: 100%;
    max-width: 300px;
}

/* Payment Error Container */
.payment-error-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    min-height: 400px;
    text-align: center;
}

.payment-error-container .error-icon {
    margin-bottom: 24px;
    animation: shake 0.5s ease-in-out;
}

.payment-error-container h3 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.payment-error-container p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 300px;
}

/* Danger Button */
.btn-danger {
    background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

/* Success Overlay */
.success-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.success-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.success-animation {
    text-align: center;
    padding: 40px;
}

.success-checkmark {
    width: 100px;
    height: 100px;
    margin: 0 auto 24px;
    position: relative;
}

.check-icon {
    width: 100px;
    height: 100px;
    position: relative;
    border-radius: 50%;
    box-sizing: content-box;
    border: 4px solid #4CAF50;
}

.icon-line {
    height: 5px;
    background-color: #4CAF50;
    display: block;
    border-radius: 2px;
    position: absolute;
    z-index: 10;
}

.icon-line.line-tip {
    top: 46px;
    left: 14px;
    width: 25px;
    transform: rotate(45deg);
    animation: icon-line-tip 0.75s;
}

.icon-line.line-long {
    top: 38px;
    right: 8px;
    width: 47px;
    transform: rotate(-45deg);
    animation: icon-line-long 0.75s;
}

.icon-circle {
    top: -4px;
    left: -4px;
    z-index: 10;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    position: absolute;
    box-sizing: content-box;
    border: 4px solid rgba(76, 175, 80, 0.2);
}

.icon-fix {
    top: 8px;
    width: 5px;
    left: 26px;
    z-index: 1;
    height: 85px;
    position: absolute;
    transform: rotate(45deg);
    background-color: #FFFFFF;
}

@keyframes icon-line-tip {
    0% {
        width: 0;
        left: 1px;
        top: 19px;
    }
    54% {
        width: 0;
        left: 1px;
        top: 19px;
    }
    70% {
        width: 50px;
        left: -8px;
        top: 37px;
    }
    84% {
        width: 17px;
        left: 21px;
        top: 48px;
    }
    100% {
        width: 25px;
        left: 14px;
        top: 46px;
    }
}

@keyframes icon-line-long {
    0% {
        width: 0;
        right: 46px;
        top: 54px;
    }
    65% {
        width: 0;
        right: 46px;
        top: 54px;
    }
    84% {
        width: 55px;
        right: 0px;
        top: 35px;
    }
    100% {
        width: 47px;
        right: 8px;
        top: 38px;
    }
}

.success-message {
    color: white;
    font-size: 20px;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Payment Success Container - статичное окно успеха */
.payment-success-container {
    max-width: 400px;
    margin: 0 auto;
    padding: 30px 20px;
    text-align: center;
}

.success-icon-static {
    margin: 0 auto 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.success-icon-static svg {
    color: #4caf50;
}

.success-title {
    color: #4caf50;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 25px;
}

.payment-success-details {
    background: var(--tg-theme-secondary-bg-color, #f5f5f5);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}

.success-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.success-info-row:last-child {
    border-bottom: none;
}

.success-info-row span:first-child {
    color: var(--tg-theme-hint-color, #999);
    font-size: 14px;
}

.success-info-row strong {
    font-size: 16px;
    color: var(--tg-theme-text-color, #000);
}

.success-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.success-actions .btn {
    width: 100%;
    padding: 14px;
    font-size: 16px;
}

.success-note {
    color: var(--tg-theme-hint-color, #999);
    font-size: 13px;
    line-height: 1.5;
    padding: 0 10px;
}

/* Dispute Container - форма оспаривания */
.dispute-container {
    max-width: 400px;
    margin: 0 auto;
    padding: 30px 20px;
    text-align: center;
}

.warning-icon {
    margin: 0 auto 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.warning-icon svg {
    color: #ff9800;
}

.dispute-container h3 {
    color: #ff9800;
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 20px;
}

.dispute-info {
    text-align: left;
    margin-bottom: 20px;
}

.dispute-info p {
    color: var(--tg-theme-text-color, #000);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 20px;
}

.dispute-details {
    background: var(--tg-theme-secondary-bg-color, #f5f5f5);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 20px;
}

.dispute-details .info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.dispute-details .info-row span:first-child {
    color: var(--tg-theme-hint-color, #999);
    font-size: 14px;
}

.dispute-form {
    margin-bottom: 20px;
}

.dispute-form label {
    display: block;
    color: var(--tg-theme-text-color, #000);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
    text-align: left;
}

.dispute-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    font-size: 14px;
    resize: vertical;
    background: var(--tg-theme-bg-color, white);
    color: var(--tg-theme-text-color, #000);
}

.dispute-form textarea:focus {
    outline: none;
    border-color: var(--tg-theme-button-color, #007AFF);
}

.dispute-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.dispute-note {
    color: #ff6b6b;
    font-size: 12px;
    line-height: 1.5;
    padding: 10px;
    background: rgba(255, 107, 107, 0.1);
    border-radius: 8px;
    text-align: left;
}

/* Payment Error Container - улучшенный стиль ошибки */
.payment-error-container {
    max-width: 400px;
    margin: 0 auto;
    padding: 30px 20px;
    text-align: center;
}

.payment-error-container .error-icon {
    margin-bottom: 20px;
}

.payment-error-container h3 {
    color: #ff4444;
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 15px;
}

.payment-error-container p {
    color: var(--tg-theme-text-color, #000);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 25px;
}

.payment-error-container .error-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}