@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,300;0,400;0,500;0,600;1,300&display=swap');

.instrument-plugin-wrapper {
    --primary-color: #00ff00;
    --primary-hover: #00e600;
    --primary-light: rgba(0, 255, 0, 0.1);
    --bg-color: #fcfdfe;
    --card-bg: #ffffff;
    --text-main: #2d3436;
    --text-muted: #7f8c8d;
    --border-color: #f1f2f6;
    --radius: 8px;
    --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.05);
    
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.instrument-plugin-wrapper * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.instrument-plugin-wrapper {
    background-color: var(--bg-color);
    color: var(--text-main);
}

.instrument-plugin-wrapper .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.instrument-plugin-wrapper .controls {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

.instrument-plugin-wrapper .search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.instrument-plugin-wrapper .search-box input {
    width: 100%;
    padding: 0.9rem 1.2rem;
    padding-left: 2.8rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
    font-size: 0.9rem;
    outline: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--card-bg);
}

.instrument-plugin-wrapper .search-box input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.instrument-plugin-wrapper .search-icon {
    position: absolute;
    left: 1.1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    width: 18px;
    height: 18px;
}

.instrument-plugin-wrapper .category-filter {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.instrument-plugin-wrapper .mobile-filter-container {
    display: none;
}

.instrument-plugin-wrapper .filter-btn {
    padding: 0.6rem 1.2rem;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    border-radius: 6px;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-muted);
    transition: all 0.2s;
}

.instrument-plugin-wrapper .filter-btn:hover {
    border-color: var(--primary-color);
    color: var(--text-main);
}

.instrument-plugin-wrapper .filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #000;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 255, 0, 0.2);
}

.instrument-plugin-wrapper .table-container {
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: var(--shadow);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.instrument-plugin-wrapper .table-scroll {
    overflow-x: auto;
}

.instrument-plugin-wrapper table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.instrument-plugin-wrapper th {
    text-align: left;
    padding: 1.25rem 1rem;
    background: #fafbfc;
    border-bottom: 2px solid var(--border-color);
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    white-space: nowrap;
}

.instrument-plugin-wrapper td {
    padding: 1.1rem 1rem;
    border-bottom: 1px solid var(--border-color);
    font-weight: 400;
    color: #444;
}

.instrument-plugin-wrapper tr:last-child td {
    border-bottom: none;
}

.instrument-plugin-wrapper tr:hover td {
    background-color: rgba(0, 255, 0, 0.04);
}

.instrument-plugin-wrapper .symbol-badge {
    display: inline-block;
    padding: 0.3rem 0.6rem;
    background: #eefbee;
    color: #27ae60;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.75rem;
}

.instrument-plugin-wrapper .category-tag {
    font-size: 0.7rem;
    color: #555;
    background: #f1f3f5;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-weight: 400;
}

.instrument-plugin-wrapper .swap-val {
    color: #e67e22;
    font-weight: 500;
}

.instrument-plugin-wrapper .hours-val {
    font-family: monospace;
    color: #7f8c8d;
    font-size: 0.8rem;
}

@media (max-width: 992px) {
    .instrument-plugin-wrapper .controls {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 1.25rem;
        position: sticky;
        top: 0;
        z-index: 1000;
        background: var(--bg-color);
        padding: 1rem 0.5rem;
        border-bottom: 1px solid var(--border-color);
    }
    
    .instrument-plugin-wrapper .search-box {
        max-width: 100%;
    }

    .instrument-plugin-wrapper .category-filter {
        display: none !important;
    }
    
    .instrument-plugin-wrapper .mobile-filter-container {
        display: block !important;
        width: 100% !important;
    }

    .instrument-plugin-wrapper .mobile-filter-container select {
        width: 100%;
        height: 48px;
        padding: 0 1rem;
        border: 1px solid var(--border-color);
        border-radius: 6px;
        background: var(--card-bg);
        font-family: 'Poppins', sans-serif;
        font-size: 0.95rem;
        color: var(--text-main);
        outline: none;
        cursor: pointer;
        appearance: none;
        background-repeat: no-repeat;
        background-position: right 1rem center;
        background-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    .instrument-plugin-wrapper .table-container {
        background: transparent;
        box-shadow: none;
        border: none;
    }

    .instrument-plugin-wrapper table, 
    .instrument-plugin-wrapper thead, 
    .instrument-plugin-wrapper tbody, 
    .instrument-plugin-wrapper th, 
    .instrument-plugin-wrapper td, 
    .instrument-plugin-wrapper tr {
        display: block;
    }

    .instrument-plugin-wrapper thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }

    .instrument-plugin-wrapper tr {
        background: var(--card-bg);
        margin-bottom: 1.5rem;
        border-radius: var(--radius);
        box-shadow: var(--shadow);
        border: 1px solid var(--border-color);
        padding: 0.5rem;
    }

    .instrument-plugin-wrapper td {
        border: none;
        border-bottom: 1px solid #f9f9f9;
        position: relative;
        padding-left: 50% !important;
        text-align: right;
        min-height: 2.8rem;
        display: flex;
        align-items: center;
        justify-content: flex-end;
    }

    .instrument-plugin-wrapper td:before {
        content: attr(data-label);
        position: absolute;
        left: 1rem;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
        text-align: left;
        font-weight: 500;
        font-size: 0.75rem;
        color: var(--text-muted);
        text-transform: uppercase;
        letter-spacing: 0.05em;
    }
}
