﻿/*
 * (c) 2026 guardfolio.live / David Purand. All rights reserved.
 * Unauthorized copying, modification, distribution, or sale of this file is strictly prohibited.
 * Proprietary and confidential.
 */

/* ===================================
   Trades Module Styles (Mobile First)
   =================================== */

/* 1. Filter Section */
.trade-filters-container {
    background: var(--gtj-bg-card);
    border: 1px solid var(--gtj-border);
    border-radius: 8px;
    margin-bottom: var(--space-lg);
    overflow: hidden;
}

.trade-filter-header {
    padding: var(--space-md) var(--space-lg);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--gtj-bg-dark);
    cursor: pointer;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.trade-filter-header.open {
    border-bottom-color: var(--gtj-border);
}

.trade-filter-title {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    font-weight: 600;
    color: var(--gtj-text-primary);
}

.trade-filter-content {
    display: none;
    /* Toggled via JS */
    padding: var(--space-lg);
}

.trade-filter-grid {
    display: grid;
    /* Fluid Grid */
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--space-md);
}

.trade-filter-input,
.trade-filter-select {
    width: 100%;
    padding: var(--input-pad);
    border: 1px solid var(--gtj-border);
    border-radius: 6px;
    font-size: var(--fs-sm);
    background: white;
}

.trade-filter-btn-reset {
    width: 100%;
    padding: var(--btn-pad-y) var(--btn-pad-x);
    background: var(--gtj-bg-dark);
    border: 1px solid var(--gtj-border);
    border-radius: 6px;
    color: var(--gtj-text-secondary);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.trade-filter-btn-reset:hover {
    background: #e5e7eb;
    color: var(--gtj-text-primary);
}

/* 2. Symbol Overview Panel */
.symbol-overview-panel {
    background: var(--gtj-bg-card);
    border: 1px solid var(--gtj-border);
    border-radius: 8px;
    margin-bottom: var(--space-lg);
    overflow: hidden;
}

.symbol-overview-header {
    width: 100%;
    padding: var(--space-md) var(--space-lg);
    background: var(--gtj-bg-dark);
    border: none;
    text-align: left;
    cursor: pointer;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 3. Open Trades Widget */
.open-trades-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.open-trades-count {
    background: var(--gtj-bg-dark);
    color: var(--gtj-text-secondary);
    padding: 2px var(--space-sm);
    border-radius: 12px;
    font-size: 11px;
    margin-left: var(--space-sm);
}

/* 4. Action Buttons (Grid) */
.trade-actions {
    display: flex;
    justify-content: center;
    gap: var(--space-sm);
}

.trade-filter-footer {
    display: flex;
    align-items: flex-end;
}

.active-filters-container {
    margin-top: var(--space-md);
    display: none;
}

.active-filters-label {
    font-size: 12px;
    color: var(--gtj-text-secondary);
    margin-bottom: var(--space-xs);
}

.widget-margin-bottom {
    margin-bottom: var(--space-xl);
}

.open-trades-body {
    display: none;
    margin-top: var(--space-md);
}

.hidden-initially {
    display: none;
}