/* ========================================================================
   COMPACT POSITION CARDS - Clean & Minimal Design
   ======================================================================== */

.position-card-modern {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 12px;
    transition: all 0.2s ease;
}

.position-card-modern:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Card Header - Compact */
.position-card-header {
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.position-card-header.profit-bg {
    background: rgba(14, 203, 129, 0.08);
}

.position-card-header.loss-bg {
    background: rgba(246, 70, 93, 0.08);
}

.position-symbol-section {
    display: flex;
    align-items: center;
    gap: 8px;
}

.symbol-main {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-color);
}

.position-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.position-type-badge.type-long {
    background: rgba(14, 203, 129, 0.15);
    color: #0ecb81;
}

.position-type-badge.type-short {
    background: rgba(246, 70, 93, 0.15);
    color: #c8272b;
}

.position-pl-section {
    text-align: right;
}

.pl-value {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 2px;
}

.pl-value.profit-text {
    color: #0ecb81;
}

.pl-value.loss-text {
    color: #c8272b;
}

.pl-percent {
    font-size: 11px;
    font-weight: 600;
    opacity: 0.7;
}

/* Card Body - Compact Grid */
.position-card-body {
    padding: 10px 14px;
}

.position-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
}

.stat-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
}

.stat-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-color);
}

.stat-value.stat-small {
    font-size: 11px;
}

/* Card Actions - Minimal */
.position-card-actions {
    padding: 10px 14px;
    border-top: 1px solid var(--border-color);
}

.action-btn-modern {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 10px 16px;
    background: var(--primary-color);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.action-btn-modern:hover {
    background: #c8272b;
    transform: translateY(-1px);
}

.action-btn-modern:active {
    transform: translateY(0);
}

/* Price Cell Animation */
.price-cell {
    transition: all 0.3s ease;
}

.flash-success {
    animation: flash-green 0.8s ease-out;
}

.flash-danger {
    animation: flash-red 0.8s ease-out;
}

@keyframes flash-green {
    0% {
        background: rgba(14, 203, 129, 0.3);
        color: #0ecb81;
    }

    100% {
        background: transparent;
        color: inherit;
    }
}

@keyframes flash-red {
    0% {
        background: rgba(246, 70, 93, 0.3);
        color: #c8272b;
    }

    100% {
        background: transparent;
        color: inherit;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .symbol-main {
        font-size: 15px;
    }

    .pl-value {
        font-size: 15px;
    }
}