/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: #0a0a0a url('/static/img/hermes-bg.png') no-repeat center center fixed;
    background-size: cover;
    color: #ffffff;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    z-index: -1;
    pointer-events: none;
}

/* Background */
.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

.background-image {
    display: none;
}

.background-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(2px);
}

/* Container */
.container {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Trading Results Tables - Scrollable */
.trades-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    overflow: hidden;
    max-height: 400px; /* Limit table height */
}

.trades-section {
    margin-bottom: 20px;
}

/* Scrollable container for trade tables */
.trades-table-container {
    max-height: 400px; /* About 15-16 rows */
    overflow-y: auto;
    overflow-x: auto;
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

.trades-table thead th {
    position: sticky;
    top: 0;
    background-color: rgba(30, 58, 138, 0.8);
    z-index: 15;
    border-bottom: 2px solid rgba(59, 130, 246, 0.6);
    box-shadow: 0 2px 5px rgba(59, 130, 246, 0.2);
    padding: 8px 12px;
    text-align: left;
    font-weight: 600;
    color: #ffffff;
}

.trades-table tbody tr {
    height: 24px;
    min-height: 24px;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

.trades-table tbody tr:hover {
    background-color: rgba(59, 130, 246, 0.15) !important;
    transition: background-color 0.2s ease;
}

.trades-table tbody td {
    padding: 6px 12px;
    font-size: 13px;
    color: #ffffff;
}

/* Info Panels - Blue Theme */
.info-panel {
    background: linear-gradient(135deg, 
        rgba(30, 58, 138, 0.25) 0%, 
        rgba(59, 130, 246, 0.2) 50%, 
        rgba(30, 58, 138, 0.25) 100%);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 12px;
    box-shadow: 
        0 4px 20px rgba(59, 130, 246, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.info-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(59, 130, 246, 0.6) 50%, 
        transparent 100%);
}

.info-panel:hover {
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 
        0 8px 32px rgba(59, 130, 246, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

/* Header */
.header {
    margin-bottom: 24px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.logo-section {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.page-title-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.market-icon {
    position: relative;
    padding: 12px;
    background: linear-gradient(135deg, 
        rgba(30, 58, 138, 0.15) 0%, 
        rgba(59, 130, 246, 0.1) 50%, 
        rgba(30, 58, 138, 0.15) 100%);
    backdrop-filter: blur(12px);
    border: 2px solid rgba(34, 197, 94, 0.5);
    border-radius: 16px;
    box-shadow: 
        0 0 15px rgba(34, 197, 94, 0.4),
        0 0 30px rgba(34, 197, 94, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    overflow: hidden;
}

.market-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(34, 197, 94, 0.8) 50%, 
        transparent 100%);
}

.market-icon:hover {
    border-color: rgba(34, 197, 94, 0.8);
    box-shadow: 
        0 0 20px rgba(34, 197, 94, 0.6),
        0 0 40px rgba(34, 197, 94, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-2px) scale(1.05);
}

.market-image {
    width: 300px;
    height: 180px;
    object-fit: cover;
    filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.5));
    transition: all 0.3s ease;
}

.market-icon:hover .market-image {
    filter: drop-shadow(0 0 12px rgba(34, 197, 94, 0.8));
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: #3b82f6;
    text-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

.version {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: #60a5fa;
    background: rgba(59, 130, 246, 0.2);
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.header-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    gap: 20px;
}

.nav-section {
    display: flex;
    align-items: center;
    background: rgba(13, 34, 71, 0.4);
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.1);
}

.header-nav {
    display: flex;
    gap: 10px;
    align-items: center;
}

.header-nav .nav-btn {
    padding: 8px 14px;
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(13, 34, 71, 0.7), rgba(30, 58, 138, 0.5));
    color: #e2e8f0;
    text-decoration: none;
    font-weight: 600;
    font-size: 12px;
    transition: all 0.3s ease;
    white-space: nowrap;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-nav .nav-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(37, 99, 235, 0.1));
    border-radius: 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.header-nav .nav-btn:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.4), rgba(37, 99, 235, 0.3));
    border-color: #3b82f6;
    color: #60a5fa;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.4),
                0 0 24px rgba(59, 130, 246, 0.2);
    transform: translateY(-1px);
}

.header-nav .nav-btn:hover::before {
    opacity: 1;
}

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

/* Home Icon Styles */
.header-nav .nav-btn .home-icon {
    font-size: 1.2rem;
    color: #00ffff;
    text-shadow: 0 0 10px rgba(0, 255, 255, 0.8);
    transition: all 0.3s ease;
}

.header-nav .nav-btn:hover .home-icon {
    color: #00ffff;
    text-shadow: 0 0 20px rgba(0, 255, 255, 1),
                 0 0 30px rgba(0, 255, 255, 0.8);
    transform: scale(1.1);
}

/* User Section - Three Rows Layout */
.user-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: flex-end;
    min-width: 200px;
}

.user-row {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
}

.user-name-row {
    justify-content: center;
}

.user-buttons-row {
    justify-content: center;
    gap: 8px;
}

.user-status-row {
    justify-content: space-between;
    gap: 16px;
}

.user-display {
    font-weight: 600;
    color: #60a5fa;
    font-size: 14px;
    text-align: center;
}

.user-info-display {
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-name {
    font-weight: 600;
    color: #60a5fa;
    font-size: 14px;
}

.user-btn {
    padding: 6px 12px;
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(13, 34, 71, 0.7), rgba(30, 58, 138, 0.5));
    color: #e2e8f0;
    text-decoration: none;
    font-weight: 500;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.user-btn:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.4), rgba(37, 99, 235, 0.3));
    border-color: #3b82f6;
    color: #60a5fa;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.3);
    transform: translateY(-1px);
}

.profile-btn {
    margin-right: 6px;
}

.logout-btn {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.7), rgba(239, 68, 68, 0.5));
    border-color: rgba(239, 68, 68, 0.4);
}

.logout-btn:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.4), rgba(220, 38, 38, 0.3));
    border-color: #ef4444;
    color: #fca5a5;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

.bot-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ef4444;
    animation: pulse 2s infinite;
}

.status-indicator.running {
    background: #22c55e;
}

.status-indicator.paused {
    background: #f59e0b;
}

.status-text {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    font-weight: 500;
}

.balance-info {
    text-align: right;
}

.balance-label {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 4px;
}

.balance-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 16px;
    font-weight: 600;
    color: #60a5fa;
}

/* Main Content */
.main-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Control Panel */
.control-panel .info-panel {
    padding: 24px;
}

.panel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #3b82f6;
    margin-bottom: 16px;
}

.control-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.stat-item {
    text-align: center;
    padding: 16px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.stat-label {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 4px;
}

.stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
}

.risk-monitor {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.risk-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.risk-label {
    font-size: 14px;
    color: #ffffff;
}

.risk-percentage {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 600;
    color: #60a5fa;
}

.risk-bar {
    height: 8px;
    background: rgba(59, 130, 246, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.risk-progress {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

/* Buttons */
.btn {
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.btn-success {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: white;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #15803d, #16a34a);
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.4);
}

.btn-warning {
    background: linear-gradient(135deg, #d97706, #f59e0b);
    color: white;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.btn-warning:hover:not(:disabled) {
    background: linear-gradient(135deg, #b45309, #d97706);
    box-shadow: 0 4px 16px rgba(245, 158, 11, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: white;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, #b91c1c, #dc2626);
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4);
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: white;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4);
}

.btn-outline {
    background: transparent;
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.5);
}

.btn-outline:hover:not(:disabled) {
    background: rgba(59, 130, 246, 0.1);
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.2);
}

/* Trading Parameters */
.trading-parameters {
    margin: 0 auto 30px auto;
    max-width: 1350px;
    width: 100%;
}

.trading-parameters .info-panel {
    padding: 24px;
}

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

.panel-title {
    font-size: 20px;
    font-weight: 600;
    color: #3b82f6;
}

.preset-controls {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.preset-input, .preset-select {
    padding: 8px 12px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
}

.preset-input:focus, .preset-select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.parameters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.parameter-item {
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s ease;
}

/* Trading parameters - blue theme */
.parameter-item[data-category="trading"] {
    background: rgba(37, 99, 235, 0.4);
    border: 1px solid rgba(59, 130, 246, 0.6);
}

.parameter-item[data-category="trading"]:hover {
    background: rgba(37, 99, 235, 0.6);
    border-color: #3b82f6;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.4);
}

/* Risk parameters - yellow theme */
.parameter-item[data-category="risk"] {
    background: rgba(234, 179, 8, 0.2);
    border: 1px solid rgba(250, 204, 21, 0.4);
}

.parameter-item[data-category="risk"]:hover {
    background: rgba(234, 179, 8, 0.3);
    border-color: #facc15;
    box-shadow: 0 0 15px rgba(234, 179, 8, 0.3);
}

/* Time parameters - green theme */
.parameter-item[data-category="time"] {
    background: rgba(22, 163, 74, 0.4);
    border: 1px solid rgba(34, 197, 94, 0.6);
}

.parameter-item[data-category="time"]:hover {
    background: rgba(22, 163, 74, 0.6);
    border-color: #22c55e;
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.4);
}

/* Technical parameters - purple theme */
.parameter-item[data-category="technical"] {
    background: rgba(126, 34, 206, 0.4);
    border: 1px solid rgba(168, 85, 247, 0.6);
}

.parameter-item[data-category="technical"]:hover {
    background: rgba(126, 34, 206, 0.6);
    border-color: #a855f7;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.4);
}

/* Daily limit parameters - violet theme */
.parameter-item[data-category="daily-limit"] {
    background: rgba(109, 40, 217, 0.4);
    border: 1px solid rgba(139, 69, 232, 0.6);
}

.parameter-item[data-category="daily-limit"]:hover {
    background: rgba(109, 40, 217, 0.6);
    border-color: #8b45e8;
    box-shadow: 0 0 15px rgba(139, 69, 232, 0.4);
}

/* Default fallback - original blue */
.parameter-item:not([data-category]) {
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.parameter-item:not([data-category]):hover {
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.1);
}

.parameter-item.parameter-highlight {
    background: rgba(185, 28, 28, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.1);
}

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

.parameter-label {
    font-size: 14px;
    font-weight: 500;
    color: #3b82f6;
}

.parameter-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: #60a5fa;
}

.parameter-input {
    width: 100%;
    padding: 10px 12px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    margin-bottom: 8px;
}

.parameter-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.parameter-description {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.4;
}

/* Slider Styles */
.slider-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 12px 0;
}

.parameter-slider {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: rgba(59, 130, 246, 0.2);
    outline: none;
    border: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.parameter-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
}

.parameter-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

.parameter-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
}

.parameter-slider::-moz-range-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

.slider-label {
    font-size: 12px;
    color: rgba(148, 163, 184, 0.8);
    font-weight: 500;
    min-width: 35px;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
}

.slider-label.min {
    text-align: left;
}

.slider-label.max {
    text-align: right;
}

/* Trading Display */
.trading-display {
    margin: 0 auto 24px auto;
    max-width: 1350px;
    width: 100%;
}

.display-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.trades-panel .info-panel,
.performance-panel .info-panel {
    padding: 24px;
    height: 100%;
}

.trades-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 200px;
}

.no-trades {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
    color: #94a3b8;
    font-size: 14px;
}

/* Orderbook Styles */
.orderbook-container {
    width: 100%;
    font-family: 'JetBrains Mono', monospace;
}

.orderbook-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

.orderbook-header h4 {
    margin: 0;
    color: #3b82f6;
    font-size: 16px;
}

.orderbook-spread {
    font-size: 12px;
    color: #94a3b8;
    background: rgba(59, 130, 246, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
}

.orderbook-section {
    margin-bottom: 16px;
}

.orderbook-title {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
    padding: 4px 8px;
    border-radius: 4px;
}

.asks-title {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.bids-title {
    color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
}

.orderbook-header-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    padding: 6px 8px;
    background: rgba(59, 130, 246, 0.05);
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    margin-bottom: 4px;
}

.orderbook-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    padding: 4px 8px;
    font-size: 12px;
    border-radius: 3px;
    transition: background-color 0.2s ease;
}

.orderbook-row:hover {
    background: rgba(59, 130, 246, 0.05);
}

.ask-row {
    border-left: 2px solid rgba(239, 68, 68, 0.3);
}

.bid-row {
    border-left: 2px solid rgba(34, 197, 94, 0.3);
}

.ask-price {
    color: #ef4444;
    font-weight: 600;
}

.bid-price {
    color: #22c55e;
    font-weight: 600;
}

.quantity {
    color: #94a3b8;
    text-align: center;
}

.total {
    color: #60a5fa;
    text-align: right;
    font-weight: 500;
}

.current-price {
    text-align: center;
    padding: 12px;
    margin: 16px 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(59, 130, 246, 0.05));
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
    color: #3b82f6;
    font-size: 14px;
    font-family: 'JetBrains Mono', monospace;
}

.trade-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    transition: all 0.3s ease;
}

.trade-item:hover {
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.15);
}

.trade-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.trade-symbol {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
}

.trade-details {
    font-size: 11px;
    color: #94a3b8;
}

.trade-pnl {
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pnl-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 600;
}

.pnl-positive {
    color: #22c55e;
}

.pnl-negative {
    color: #ef4444;
}

.trade-quantity {
    font-size: 11px;
    color: #94a3b8;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.metric-item {
    text-align: center;
    padding: 20px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    transition: all 0.3s ease;
}

.metric-item:hover {
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.15);
}

.metric-label {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 8px;
}

.metric-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 20px;
    font-weight: 700;
    color: #3b82f6;
}

/* Footer */
.footer .info-panel {
    padding: 16px 24px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-info {
    display: flex;
    gap: 24px;
    align-items: center;
    flex-wrap: wrap;
}

.update-time, .connection-status {
    font-size: 12px;
    color: #94a3b8;
}

.status-active {
    color: #22c55e;
    font-weight: 500;
}

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

/* Range Input Styling */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    cursor: pointer;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(59, 130, 246, 0.2);
    outline: none;
}

input[type="range"]::-webkit-slider-track {
    background: rgba(59, 130, 246, 0.2);
    height: 6px;
    border-radius: 3px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    background: #3b82f6;
    border: 2px solid #ffffff;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
    cursor: pointer;
}

input[type="range"]::-moz-range-track {
    background: rgba(59, 130, 246, 0.2);
    height: 6px;
    border-radius: 3px;
    border: none;
}

input[type="range"]::-moz-range-thumb {
    background: #3b82f6;
    border: 2px solid #ffffff;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
    cursor: pointer;
}

/* Animations */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 12px;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        padding: 10px;
    }
    
    .logo-section {
        order: 1;
    }
    
    .market-image {
        width: 60px;
        height: 60px;
    }
    
    .header-center {
        order: 2;
        gap: 15px;
    }
    
    .page-title-container h1 {
        font-size: 1.8rem;
    }
    
    .version {
        font-size: 0.8rem;
    }
    
    .header-nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    
    .nav-btn {
        padding: 8px 16px;
        font-size: 0.8rem;
        min-width: auto;
    }
    
    .header-right {
        order: 3;
        width: 100%;
    }
    
    .user-section {
        gap: 10px;
    }
    
    .user-row {
        gap: 10px;
        justify-content: center;
    }
    
    .bot-status,
    .balance-info {
        font-size: 0.85rem;
    }
    
    .status-indicator {
        width: 8px;
        height: 8px;
    }
    
    .panel-grid {
        grid-template-columns: 1fr;
    }
    
    .display-grid {
        grid-template-columns: 1fr;
    }
    
    .parameters-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .preset-controls {
        flex-direction: column;
        width: 100%;
    }
    
    .preset-input, .preset-select {
        width: 100%;
    }
}

/* Mobile Phones (480px and below) */
@media (max-width: 480px) {
    .container {
        padding: 8px;
    }
    
    .header {
        padding: 8px;
    }
    
    .header-content {
        gap: 10px;
        padding: 8px;
    }
    
    .market-image {
        width: 50px;
        height: 50px;
    }
    
    .page-title-container h1 {
        font-size: 1.4rem;
    }
    
    .version {
        font-size: 0.7rem;
    }
    
    .header-nav {
        gap: 8px;
    }
    
    .nav-btn {
        padding: 6px 12px;
        font-size: 0.7rem;
    }
    
    .user-section {
        gap: 8px;
    }
    
    .user-row {
        gap: 8px;
        font-size: 0.8rem;
    }
    
    .bot-status,
    .balance-info {
        font-size: 0.75rem;
    }
    
    .status-indicator {
        width: 6px;
        height: 6px;
    }
    
    .control-buttons {
        flex-direction: column;
        gap: 8px;
    }
    
    .btn {
        width: 100%;
        padding: 10px;
        font-size: 0.9rem;
    }
    
    .info-panel {
        padding: 12px;
    }
    
    .section-title {
        font-size: 1rem;
    }
}

/* Service Description Panel */
.service-description {
    margin-top: 32px;
    padding-bottom: 32px;
}

.service-panel {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
    border: 2px solid #0ea5e9;
    box-shadow: 
        0 0 20px rgba(14, 165, 233, 0.4),
        inset 0 0 20px rgba(14, 165, 233, 0.1);
    animation: neonGlow 2s ease-in-out infinite alternate;
}

@keyframes neonGlow {
    from {
        box-shadow: 
            0 0 20px rgba(14, 165, 233, 0.4),
            inset 0 0 20px rgba(14, 165, 233, 0.1);
    }
    to {
        box-shadow: 
            0 0 30px rgba(14, 165, 233, 0.6),
            inset 0 0 30px rgba(14, 165, 233, 0.15);
    }
}

.service-content {
    position: relative;
    z-index: 2;
    padding: 32px;
    display: flex;
    gap: 32px;
    align-items: flex-start;
}

.service-background {
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background-image: linear-gradient(135deg, rgba(14, 165, 233, 0.2), rgba(59, 130, 246, 0.3)), url('img/hermes-bg-opt.jpg?v=4');
    background-size: cover;
    background-position: center;
    opacity: 0.3;
    z-index: 1;
}

.service-text {
    position: relative;
    z-index: 2;
    flex: 1;
}

.service-image-container {
    position: relative;
    flex-shrink: 0;
    width: 300px;
    height: 200px;
    border: 3px solid #0ea5e9;
    border-radius: 12px;
    overflow: hidden;
    background-color: #1e293b;
    box-shadow: 
        0 0 15px rgba(14, 165, 233, 0.5),
        inset 0 0 15px rgba(14, 165, 233, 0.1);
    animation: imageNeonGlow 3s ease-in-out infinite alternate;
    z-index: 10;
}

@keyframes imageNeonGlow {
    from {
        box-shadow: 
            0 0 15px rgba(14, 165, 233, 0.5),
            inset 0 0 15px rgba(14, 165, 233, 0.1);
    }
    to {
        box-shadow: 
            0 0 25px rgba(14, 165, 233, 0.8),
            inset 0 0 25px rgba(14, 165, 233, 0.2);
    }
}

.service-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
    display: block;
    position: relative;
    z-index: 5;
}

.service-title {
    font-size: 28px;
    font-weight: 700;
    color: #0ea5e9;
    margin-bottom: 16px;
    text-shadow: 0 0 15px rgba(14, 165, 233, 0.5);
}

.service-description-text {
    font-size: 16px;
    line-height: 1.6;
    color: #cbd5e1;
    margin-bottom: 24px;
}

.service-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #94a3b8;
    font-size: 14px;
}

.feature i {
    color: #0ea5e9;
    font-size: 18px;
    width: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    .service-content {
        padding: 24px;
        flex-direction: column;
        gap: 24px;
    }
    
    .service-background {
        width: 100%;
        height: 30%;
        top: auto;
        bottom: 0;
        opacity: 0.2;
    }
    
    .service-text {
        max-width: 100%;
    }
    
    .service-image-container {
        width: 100%;
        height: 180px;
        margin: 0 auto;
    }
    
    .service-features {
        grid-template-columns: 1fr;
    }
}

/* Authentication and Profile Styles */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    padding: 20px;
}

.auth-card {
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid #334155;
    border-radius: 16px;
    padding: 40px;
    max-width: 400px;
    width: 100%;
    box-shadow: 
        0 0 30px rgba(14, 165, 233, 0.1),
        inset 0 0 30px rgba(14, 165, 233, 0.05);
}

.profile-container {
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid #334155;
    border-radius: 16px;
    padding: 40px;
    max-width: 800px;
    width: 100%;
    box-shadow: 
        0 0 30px rgba(14, 165, 233, 0.1),
        inset 0 0 30px rgba(14, 165, 233, 0.05);
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h1 {
    color: #0ea5e9;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    text-shadow: 0 0 15px rgba(14, 165, 233, 0.5);
}

.auth-header h2 {
    color: #cbd5e1;
    font-size: 18px;
    font-weight: 400;
    margin: 0;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    color: #cbd5e1;
    font-size: 14px;
    font-weight: 500;
}

.form-group input {
    background: rgba(51, 65, 85, 0.5);
    border: 1px solid #475569;
    border-radius: 8px;
    padding: 12px 16px;
    color: #f1f5f9;
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.2);
}

.form-group small {
    color: #94a3b8;
    font-size: 12px;
}

.auth-btn {
    background: linear-gradient(135deg, #0ea5e9, #3b82f6);
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.auth-btn:hover {
    background: linear-gradient(135deg, #0284c7, #2563eb);
    box-shadow: 0 0 20px rgba(14, 165, 233, 0.4);
}

.auth-links {
    text-align: center;
    margin-top: 20px;
}

.auth-links a {
    color: #0ea5e9;
    text-decoration: none;
    font-size: 14px;
}

.auth-links a:hover {
    text-decoration: underline;
}

.auth-message {
    margin-top: 20px;
}

.auth-message .success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid #22c55e;
    color: #22c55e;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}

.auth-message .error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid #ef4444;
    color: #ef4444;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}

/* Profile specific styles */
.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

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

.profile-btn {
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.profile-btn.primary {
    background: linear-gradient(135deg, #0ea5e9, #3b82f6);
    color: white;
}

.profile-btn.secondary {
    background: rgba(51, 65, 85, 0.5);
    color: #cbd5e1;
    border: 1px solid #475569;
}

.profile-btn.danger {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid #ef4444;
}

.profile-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.profile-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.profile-section {
    background: rgba(51, 65, 85, 0.2);
    border: 1px solid #475569;
    border-radius: 12px;
    padding: 24px;
}

.profile-section h3 {
    color: #0ea5e9;
    font-size: 18px;
    margin-bottom: 16px;
}

.user-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.info-item label {
    color: #94a3b8;
    font-weight: 500;
}

.info-item span {
    color: #f1f5f9;
    font-weight: 600;
}

.settings-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    color: #cbd5e1;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
}

.security-info {
    background: rgba(14, 165, 233, 0.05);
    border: 1px solid rgba(14, 165, 233, 0.2);
    border-radius: 8px;
    padding: 16px;
}

.security-info p {
    color: #94a3b8;
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.5;
}

.security-info strong {
    color: #0ea5e9;
}

/* User action buttons in header */
.user-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

/* User section container with frame */
.user-section {
    background: linear-gradient(135deg, 
        rgba(30, 58, 138, 0.15) 0%, 
        rgba(59, 130, 246, 0.1) 50%, 
        rgba(30, 58, 138, 0.15) 100%);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 
        0 4px 20px rgba(59, 130, 246, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.user-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(59, 130, 246, 0.6) 50%, 
        transparent 100%);
}

.user-section:hover {
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 
        0 8px 32px rgba(59, 130, 246, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.user-btn {
    padding: 10px 18px;
    border: 1px solid rgba(34, 197, 94, 0.4);
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(13, 34, 71, 0.6), rgba(22, 163, 74, 0.3));
    color: #86efac;
    cursor: pointer;
    font-weight: 600;
    font-size: 12px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 4px;
}

.user-btn:hover {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.4), rgba(22, 163, 74, 0.3));
    border-color: #22c55e;
    color: #bbf7d0;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.4),
                0 0 24px rgba(34, 197, 94, 0.2);
    transform: translateY(-1px);
}

.user-btn.profile-btn {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(22, 163, 74, 0.2));
    border-color: #22c55e;
    color: #86efac;
}

.user-btn.logout-btn {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
    border-color: #ef4444;
    color: #fca5a5;
}

.user-btn.logout-btn:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.4), rgba(220, 38, 38, 0.3));
    border-color: #dc2626;
    color: #fecaca;
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.4);
}

.user-btn.login-btn {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(37, 99, 235, 0.2));
    border-color: #3b82f6;
    color: #93c5fd;
}

.user-btn.register-btn {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.3), rgba(147, 51, 234, 0.2));
    border-color: #a855f7;
    color: #c4b5fd;
}

.user-info-display {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.user-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1px solid rgba(148, 163, 184, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 10px;
    font-weight: 600;
    overflow: hidden;
    background-image: url('/static/img/user.png') !important;
    background-size: cover;
    background-position: center;
}

.user-name {
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 500;
}

/* Profile incognito avatar styles */
.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0f172a, #1e293b, #334155);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 28px;
    font-weight: 400;
    margin: 0 auto 20px;
    box-shadow: 
        0 0 20px rgba(0, 0, 0, 0.7),
        inset 0 0 20px rgba(100, 116, 139, 0.1);
    border: 2px solid rgba(71, 85, 105, 0.5);
    position: relative;
    overflow: hidden;
}

.profile-avatar::before {
    content: '👤';
    position: absolute;
    font-size: 36px;
    z-index: 2;
    filter: grayscale(100%) brightness(0.7);
}

.profile-avatar::after {
    content: '';
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    height: 12px;
    background: linear-gradient(90deg, #334155, #475569);
    border-radius: 20px;
    z-index: 3;
    opacity: 0.8;
}

.profile-avatar-text {
    position: relative;
    z-index: 2;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    font-size: 28px;
    line-height: 1;
}

/* User info container layout */
.user-info-container {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 30px;
    align-items: start;
    margin-bottom: 20px;
    padding: 20px;
    background: rgba(51, 65, 85, 0.3);
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.profile-avatar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-self: start;
    min-width: 120px;
}

.profile-avatar {
    margin: 0 0 15px 0;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0f172a, #1e293b);
    border: 2px solid rgba(148, 163, 184, 0.3);
    transition: all 0.3s ease;
}

.profile-avatar:hover {
    border-color: rgba(59, 130, 246, 0.5);
    transform: scale(1.05);
}

.avatar-controls {
    text-align: center;
}

.user-info {
    justify-self: end;
    text-align: right;
    min-width: 250px;
}

.user-info .info-item {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

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

.user-info .info-item label {
    font-weight: 500;
    color: rgba(148, 163, 184, 0.8);
    margin-right: 15px;
    min-width: 120px;
    text-align: right;
}

.user-info .info-item span {
    color: #e2e8f0;
    font-weight: 400;
    max-width: 200px;
    word-break: break-word;
}

/* Avatar selector modal */
.avatar-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.avatar-modal-content {
    background: linear-gradient(135deg, rgba(51, 65, 85, 0.95), rgba(71, 85, 105, 0.95));
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 12px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.avatar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.avatar-option {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.avatar-option:hover {
    border-color: #0ea5e9;
    transform: scale(1.1);
}

.avatar-option.selected {
    border-color: #22c55e;
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.5);
}

/* OAuth buttons */
.oauth-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.oauth-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 160px;
    justify-content: center;
}

.oauth-btn.google {
    background: linear-gradient(135deg, #4285f4, #34a853);
    color: white;
}

.oauth-btn.apple {
    background: linear-gradient(135deg, #000000, #333333);
    color: white;
}

/* Google and Apple OAuth icons using CSS */
.oauth-btn.google .oauth-icon {
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 2px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #4285f4;
    font-size: 12px;
}

.oauth-btn.apple .oauth-icon {
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-weight: bold;
    font-size: 14px;
}

.oauth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.oauth-icon {
    font-size: 18px;
}

.help-text {
    display: block;
    font-size: 12px;
    color: rgba(148, 163, 184, 0.7);
    margin-top: 5px;
    font-style: italic;
}

.oauth-section {
    margin-top: 20px;
}

.oauth-divider {
    text-align: center;
    margin: 20px 0;
    position: relative;
}

.oauth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(148, 163, 184, 0.3);
}

.oauth-divider span {
    background: linear-gradient(135deg, rgba(51, 65, 85, 0.95), rgba(71, 85, 105, 0.95));
    padding: 0 15px;
    color: rgba(148, 163, 184, 0.8);
    font-size: 14px;
}

.google-login {
    width: 100%;
    background: linear-gradient(135deg, #4285f4, #34a853);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.google-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(66, 133, 244, 0.3);
}

.google-login .oauth-icon {
    background: white;
    color: #4285f4;
    width: 18px;
    height: 18px;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 12px;
}

/* Results Panel Styles */
.results-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 8px;
}

.trades-section {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.successful-section {
    border-left: 4px solid #22c55e;
}

.unsuccessful-section {
    border-left: 4px solid #ef4444;
}

.trades-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.trades-header h4 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #e2e8f0;
}

.trades-badge {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.trades-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    margin-bottom: 16px;
}

.trades-table thead th {
    background: rgba(255, 255, 255, 0.05);
    color: #94a3b8;
    padding: 12px 8px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.trades-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: background-color 0.2s ease;
}

.trades-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.trades-table tbody td {
    padding: 12px 8px;
    vertical-align: middle;
}

.trade-id {
    color: #94a3b8;
    font-size: 13px;
    font-weight: 500;
}

.trade-symbol {
    font-weight: 600;
    color: #ffffff;
    font-size: 13px;
}

.status-badge {
    font-size: 11px;
    padding: 5px 10px;
    border-radius: 4px;
    text-align: center;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
}

.status-badge.opened {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.status-badge.closed {
    background: rgba(156, 163, 175, 0.2);
    color: #9ca3af;
    border: 1px solid rgba(156, 163, 175, 0.3);
}

.type-badge {
    font-size: 11px;
    padding: 5px 10px;
    border-radius: 4px;
    text-align: center;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
}

.type-badge.long {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.type-badge.short {
    background: rgba(234, 179, 8, 0.2);
    color: #eab308;
    border: 1px solid rgba(234, 179, 8, 0.3);
}

.trade-pnl {
    font-weight: 700;
    text-align: right;
    font-size: 14px;
    font-family: 'JetBrains Mono', monospace;
}

.trade-pnl.positive {
    color: #22c55e;
    text-shadow: 0 0 8px rgba(34, 197, 94, 0.3);
}

.trade-pnl.negative {
    color: #ef4444;
    text-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

.trades-summary {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    color: #e2e8f0;
    font-size: 13px;
}

.summary-item span {
    flex: 1;
}

.summary-pnl {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    font-weight: 700;
    text-align: right;
}

.summary-pnl.positive {
    color: #22c55e;
    text-shadow: 0 0 8px rgba(34, 197, 94, 0.3);
}

.summary-pnl.negative {
    color: #ef4444;
    text-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

.loading-message {
    text-align: center;
    color: #9ca3af;
    font-style: italic;
    padding: 40px 20px;
    font-size: 14px;
}

/* Специальное выделение заголовка результатов */
.results-panel-header {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(99, 102, 241, 0.1));
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 20px;
    position: relative;
    text-align: center;
}

.results-panel-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 2px;
    background: linear-gradient(90deg, #3b82f6, #6366f1, #3b82f6);
    border-radius: 1px;
}

.results-panel-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #e2e8f0;
    text-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
    letter-spacing: 1px;
}

.results-panel-header .subtitle {
    margin-top: 8px;
    font-size: 12px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* Strategy Selection Panel */
.strategy-selection-panel {
    margin: 0 auto 30px auto;
    padding: 25px;
    background: linear-gradient(135deg, rgba(14, 17, 23, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    border: 1px solid rgba(0, 191, 255, 0.3);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    max-width: 1350px;
    width: 100%;
}

.strategy-selection-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('/static/img/hermes-bg-opt.jpg') center center;
    background-size: cover;
    opacity: 0.08;
    pointer-events: none;
    z-index: 0;
}

.strategy-panel-header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
}

.strategy-title {
    font-size: 28px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(0, 191, 255, 0.5);
    letter-spacing: 1px;
}

.strategy-subtitle {
    font-size: 16px;
    color: #94a3b8;
    margin: 0;
    font-weight: 400;
}

.strategy-cards-container {
    position: relative;
    z-index: 1;
}

.strategy-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.strategy-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9) 0%, rgba(15, 23, 42, 0.9) 100%);
    border: 2px solid rgba(0, 191, 255, 0.3);
    border-radius: 12px;
    padding: 20px;
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer;
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    min-height: 350px;
}

.strategy-card:hover {
    border-color: rgba(0, 255, 136, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 255, 136, 0.2);
}

.strategy-card.selected {
    border-color: #00ff88;
    background: linear-gradient(135deg, rgba(0, 255, 136, 0.1) 0%, rgba(30, 41, 59, 0.9) 100%);
    box-shadow: 0 0 30px rgba(0, 255, 136, 0.3);
}

.strategy-card-header {
    margin-bottom: 15px;
    min-height: 80px;
    display: flex;
    flex-direction: column;
}

.strategy-name {
    font-size: 20px;
    font-weight: 700;
    color: #00ff88;
    margin-bottom: 8px;
    text-shadow: 0 0 15px rgba(0, 255, 136, 0.6);
    transition: all 0.3s ease;
}

.strategy-card.selected .strategy-name {
    color: #ffd700;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
}

/* Условная стилизация названий стратегий */
.strategy-name-running {
    color: #00ff88 !important;
    text-shadow: 0 0 15px rgba(0, 255, 136, 0.8) !important;
}

.strategy-name-stopped {
    color: #00bfff !important;
    text-shadow: 0 0 15px rgba(0, 191, 255, 0.8) !important;
}

.strategy-description {
    font-size: 14px;
    color: #00bfff;
    line-height: 1.4;
    margin-bottom: 15px;
    flex-grow: 1;
}

.strategy-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
    flex-grow: 1;
}

.strategy-metric {
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 10px;
    border-radius: 6px;
    border: 1px solid rgba(0, 191, 255, 0.2);
}

.strategy-metric-label {
    font-size: 11px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.strategy-metric-value {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
}

/* Условная стилизация значений MPR и LOSE */
.mpr-negative {
    color: #ff4757 !important;
    text-shadow: 0 0 10px rgba(255, 71, 87, 0.6);
}

.lose-positive {
    color: #ff4757 !important;
    text-shadow: 0 0 10px rgba(255, 71, 87, 0.6);
}

/* Стилизация поля WIN зеленым цветом */
.win-green {
    color: #00ff88 !important;
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.6);
}

/* Стилизация поля Trading time голубым цветом */
.trading-time-blue {
    color: #00bfff !important;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.6);
}

/* Стилизация префикса USDT голубым цветом */
.usdt-prefix {
    color: #00bfff !important;
    text-shadow: 0 0 8px rgba(0, 191, 255, 0.6);
    margin-right: 4px;
}

/* P&L and Wallet Section */
.strategy-pnl-section {
    border-top: 2px solid rgba(0, 255, 136, 0.4);
    margin-top: 15px;
    padding-top: 15px;
}

.strategy-pnl-wallet {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.strategy-wallet, .strategy-pnl {
    flex: 1;
    text-align: center;
}

.strategy-wallet-label, .strategy-pnl-label {
    font-size: 12px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.strategy-wallet-value, .strategy-pnl-value {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
}



/* P&L styling with color coding */
.strategy-pnl-value {
    border-radius: 6px;
    padding: 6px 8px;
    font-weight: bold;
    text-align: center;
}

.strategy-pnl-value.positive {
    border: 2px solid rgba(34, 197, 94, 0.5);
    background: rgba(34, 197, 94, 0.1);
    color: #22c55e;
}

.strategy-pnl-value.negative {
    border: 2px solid rgba(239, 68, 68, 0.5);
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* USDT text styling */
.usdt-text {
    color: #3b82f6;
    font-weight: 600;
}



.strategy-pnl {
    margin-bottom: 15px;
    text-align: center;
}

.strategy-pnl-label {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 5px;
}

.strategy-pnl-value {
    font-size: 18px;
    font-weight: 700;
}

.strategy-pnl-value.positive {
    color: #22c55e;
    text-shadow: 0 0 10px rgba(34, 197, 94, 0.4);
}

.strategy-pnl-value.negative {
    color: #ef4444;
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
}

.strategy-controls {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.strategy-btn {
    flex: 1;
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.strategy-start-btn {
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: white;
}

.strategy-start-btn:hover {
    background: linear-gradient(135deg, #16a34a, #15803d);
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.4);
}

.strategy-stop-btn {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.strategy-stop-btn:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
}

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

.strategy-status {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.strategy-status.running {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.strategy-status.stopped {
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
    border: 1px solid rgba(107, 114, 128, 0.3);
}

.strategy-status.paused {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

/* Mobile Strategy Panel Styles */
@media (max-width: 768px) {
    .strategy-selection-panel {
        margin-bottom: 20px;
        padding: 15px;
    }

    .strategy-title {
        font-size: 22px;
        margin-bottom: 8px;
    }

    .strategy-subtitle {
        font-size: 14px;
    }

    .strategy-cards-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .strategy-card {
        padding: 15px;
    }

    .strategy-name {
        font-size: 18px;
        margin-bottom: 6px;
    }

    .strategy-description {
        font-size: 13px;
        margin-bottom: 12px;
    }

    .strategy-metrics {
        gap: 8px;
        margin-bottom: 12px;
    }

    .strategy-metric {
        padding: 6px 8px;
    }

    .strategy-metric-label {
        font-size: 10px;
    }

    .strategy-metric-value {
        font-size: 13px;
    }

    .strategy-pnl-value {
        font-size: 16px;
    }

    .strategy-btn {
        padding: 10px 16px;
        font-size: 11px;
    }

    .strategy-status {
        top: 10px;
        right: 10px;
        padding: 3px 6px;
        font-size: 9px;
    }
}

@media (max-width: 480px) {
    .strategy-selection-panel {
        padding: 12px;
        margin-bottom: 15px;
    }

    .strategy-title {
        font-size: 20px;
    }

    .strategy-subtitle {
        font-size: 13px;
    }

    .strategy-cards-grid {
        gap: 12px;
    }

    .strategy-card {
        padding: 12px;
    }

    .strategy-name {
        font-size: 16px;
    }

    .strategy-description {
        font-size: 12px;
        margin-bottom: 10px;
    }

    .strategy-metrics {
        gap: 6px;
        margin-bottom: 10px;
    }

    .strategy-metric {
        padding: 5px 6px;
    }

    .strategy-pnl {
        margin-bottom: 12px;
    }

    .strategy-pnl-value {
        font-size: 15px;
    }
}

/* P&L Percent styling - smaller font for percentage values */
.pnl-percent {
    font-size: 0.85em;
    opacity: 0.9;
}
/* Strategy Toggle Button CSS */
.strategy-toggle-btn {
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    text-transform: uppercase;
    transition: all 0.3s ease;
    color: white;
    min-width: 80px;
}

.strategy-toggle-btn.stopped {
    background: linear-gradient(135deg, #28a745, #20c997);
    box-shadow: 0 4px 8px rgba(40, 167, 69, 0.3);
}

.strategy-toggle-btn.stopped:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(40, 167, 69, 0.4);
}

.strategy-toggle-btn.running {
    background: linear-gradient(135deg, #dc3545, #fd7e14);
    box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3);
}

.strategy-toggle-btn.running:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(220, 53, 69, 0.4);
}

/* Beautiful scrollbar styles for TRADER page */
.table-container::-webkit-scrollbar,
.scrollable-table::-webkit-scrollbar,
*::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.table-container::-webkit-scrollbar-track,
.scrollable-table::-webkit-scrollbar-track,
*::-webkit-scrollbar-track {
    background: rgba(0, 20, 40, 0.9);
    border-radius: 5px;
    border: 1px solid rgba(0, 191, 255, 0.2);
}

.table-container::-webkit-scrollbar-thumb,
.scrollable-table::-webkit-scrollbar-thumb,
*::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, 
        rgba(0, 191, 255, 0.8) 0%, 
        rgba(0, 255, 136, 0.8) 50%,
        rgba(255, 215, 0, 0.8) 100%);
    border-radius: 5px;
    border: 1px solid rgba(0, 191, 255, 0.4);
    box-shadow: 0 0 8px rgba(0, 191, 255, 0.5);
}

.table-container::-webkit-scrollbar-thumb:hover,
.scrollable-table::-webkit-scrollbar-thumb:hover,
*::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, 
        rgba(0, 191, 255, 1) 0%, 
        rgba(0, 255, 136, 1) 50%,
        rgba(255, 215, 0, 1) 100%);
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
    transform: scale(1.1);
}

.table-container::-webkit-scrollbar-corner,
.scrollable-table::-webkit-scrollbar-corner,
*::-webkit-scrollbar-corner {
    background: rgba(0, 20, 40, 0.9);
}
