/* Chull Point Trading Platform - Dark Cyberpunk Theme */

.trading-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 20px;
    max-width: 1400px;
    margin: 0 auto;
    min-height: calc(100vh - 200px);
    background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 50%, #0f0f1e 100%);
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

/* Desktop layout - 3 columns */
@media (min-width: 1200px) {
    .trading-container {
        grid-template-columns: 300px 1fr 400px;
    }
}

/* Tablet layout - 2 columns */
@media (min-width: 768px) and (max-width: 1199px) {
    .trading-container {
        grid-template-columns: 1fr 1fr;
    }
    
    .trading-middle-panel {
        grid-column: 1 / -1;
    }
}

.trading-left-panel,
.trading-middle-panel,
.trading-right-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.trading-panel-card {
    background: rgba(10, 10, 20, 0.8);
    border: 1px solid rgba(0, 255, 136, 0.2);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.1),
                inset 0 0 20px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.trading-panel-card:hover {
    border-color: rgba(0, 255, 136, 0.4);
    box-shadow: 0 0 30px rgba(0, 255, 136, 0.2),
                inset 0 0 20px rgba(0, 0, 0, 0.5);
}

.panel-title {
    font-size: 18px;
    font-weight: 700;
    color: #00ff88;
    margin: 0 0 15px 0;
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
    border-bottom: 2px solid rgba(0, 255, 136, 0.3);
    padding-bottom: 10px;
}

/* CP Display */
.cp-display-large {
    font-size: 48px;
    font-weight: 800;
    color: #00ff88;
    text-align: center;
    margin: 20px 0;
    text-shadow: 0 0 20px rgba(0, 255, 136, 0.8),
                 0 0 40px rgba(0, 255, 136, 0.4);
    font-variant-numeric: tabular-nums;
}

.cps-display {
    text-align: center;
    margin-bottom: 20px;
    padding: 10px;
    background: rgba(0, 255, 136, 0.1);
    border-radius: 8px;
}

.cps-label {
    display: block;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 5px;
}

.cps-value {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: #00ff88;
}

/* Security Indicator */
.security-indicator {
    margin-top: 20px;
}

.security-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.security-level-badge {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
    padding: 4px 12px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14px;
}

.security-bar-container {
    height: 20px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 10px;
}

.security-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff88 0%, #00cc6a 100%);
    border-radius: 10px;
    transition: width 0.3s ease, background 0.3s ease;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
}

.security-bar-fill.security-critical {
    background: linear-gradient(90deg, #ff4444 0%, #cc0000 100%);
    box-shadow: 0 0 10px rgba(255, 68, 68, 0.5);
    animation: pulse-red 1s infinite;
}

.security-bar-fill.security-warning {
    background: linear-gradient(90deg, #ffaa00 0%, #cc8800 100%);
    box-shadow: 0 0 10px rgba(255, 170, 0, 0.5);
}

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

.security-info {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.security-info .security-critical {
    color: #ff4444;
    font-weight: 700;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Buttons */
.trading-btn {
    width: 100%;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.trading-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.trading-btn:hover::before {
    width: 300px;
    height: 300px;
}

.trading-btn:active {
    transform: scale(0.98);
}

.security-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin-top: 15px;
}

.security-btn:hover {
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.5);
}

.buy-btn {
    background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    color: #0a0a0f;
}

.buy-btn:hover {
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.5);
}

.buy-btn:disabled {
    background: rgba(100, 100, 100, 0.3);
    color: rgba(255, 255, 255, 0.3);
    cursor: not-allowed;
}

.btn-cost {
    display: block;
    font-size: 12px;
    margin-top: 5px;
    opacity: 0.8;
}

/* Statistics */
.stats-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    border-left: 3px solid #00ff88;
}

.stat-label {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
}

.stat-value {
    color: #00ff88;
    font-weight: 700;
    font-size: 14px;
}

/* Investments */
.investments-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.investment-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(0, 255, 136, 0.2);
    border-radius: 10px;
    padding: 15px;
    transition: all 0.3s ease;
}

.investment-card:hover {
    border-color: rgba(0, 255, 136, 0.5);
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}

.investment-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.investment-emoji {
    font-size: 32px;
}

.investment-info {
    flex: 1;
}

.investment-name {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.investment-level {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.investment-details {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
}

.investment-detail {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
}

.detail-value {
    font-size: 14px;
    font-weight: 700;
    color: #00ff88;
}

/* Market Indicator */
.market-indicator {
    text-align: center;
}

.market-status {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px;
    background: rgba(0, 255, 136, 0.1);
    border-radius: 10px;
}

.market-emoji {
    font-size: 48px;
}

.market-text {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
}

.market-multiplier {
    font-size: 32px;
    font-weight: 800;
    color: #00ff88;
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
}

.market-multiplier.bull {
    color: #00ff88;
}

.market-multiplier.bear {
    color: #ff4444;
}

/* Trade Area */
.trade-area {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.trade-chart-container {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    padding: 10px;
    border: 1px solid rgba(0, 255, 136, 0.2);
}

#tradingChart {
    width: 100%;
    height: 200px;
    border-radius: 4px;
}

.trade-input-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.trade-input-section label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    font-weight: 600;
}

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

.trade-amount-btn {
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(0, 255, 136, 0.3);
    border-radius: 6px;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.trade-amount-btn:hover {
    background: rgba(0, 255, 136, 0.2);
    border-color: rgba(0, 255, 136, 0.6);
}

.trade-amount-btn.active {
    background: rgba(0, 255, 136, 0.3);
    border-color: #00ff88;
}

.trade-amount-input {
    padding: 12px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(0, 255, 136, 0.3);
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
}

.trade-amount-input:focus {
    outline: none;
    border-color: #00ff88;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
}

.trade-amount-display {
    text-align: center;
    padding: 10px;
    background: rgba(0, 255, 136, 0.1);
    border-radius: 6px;
    color: #00ff88;
    font-weight: 700;
    font-size: 16px;
}

.trade-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.trade-long-btn {
    background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    color: #0a0a0f;
}

.trade-long-btn:hover {
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.5);
}

.trade-short-btn {
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    color: #fff;
}

.trade-short-btn:hover {
    box-shadow: 0 0 20px rgba(255, 68, 68, 0.5);
}

.trade-long-btn:disabled,
.trade-short-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.trade-result {
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    font-weight: 800;
    font-size: 24px;
    animation: popIn 0.5s ease;
}

@keyframes popIn {
    0% { transform: scale(0.5); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

.trade-result.trade-won {
    background: rgba(0, 255, 136, 0.2);
    border: 2px solid #00ff88;
    color: #00ff88;
}

.trade-result.trade-lost {
    background: rgba(255, 68, 68, 0.2);
    border: 2px solid #ff4444;
    color: #ff4444;
}

.trade-result-title {
    font-size: 28px;
    margin-bottom: 10px;
}

.trade-result-amount {
    font-size: 36px;
    text-shadow: 0 0 20px currentColor;
}

/* Notifications */
.trading-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 8px;
    font-weight: 600;
    z-index: 10000;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.trading-notification.show {
    opacity: 1;
    transform: translateX(0);
}

.trading-notification-success {
    background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    color: #0a0a0f;
}

.trading-notification-error {
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    color: #fff;
}

.trading-notification-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

/* Responsive */
@media (max-width: 1400px) {
    .trading-container {
        grid-template-columns: 280px 1fr 350px;
    }
}

@media (max-width: 1200px) {
    .trading-container {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }
    
    .trading-left-panel,
    .trading-middle-panel,
    .trading-right-panel {
        flex-direction: row;
        overflow-x: auto;
    }
    
    .trading-panel-card {
        min-width: 300px;
    }
}

@media (max-width: 768px) {
    .trading-container {
        padding: 10px;
        gap: 15px;
    }
    
    .cp-display-large {
        font-size: 36px;
    }
    
    .trading-panel-card {
        padding: 15px;
    }
}

