* {
    padding: 0;
    margin: 0;
}

body {
    background-color: var(--bg-color);
    font-family: "Gabarito", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
}
:root{
    --sidebar-w: 260px;
}

.layout { 
    display:flex; 
    min-height:100vh; 
}

/* Sidebar (desktop) */
.sidebar {
    width: var(--sidebar-w);
    flex: 0 0 var(--sidebar-w);
    position:sticky;
    top:0; 
    height:100vh; 
    overflow-y:auto;
    background:#fff;
}
.sidebar .nav-link{
    color: var(--anti-light);
    border-radius: .5rem; 
    font-weight: 400;
}
.sidebar .nav-link.active{
    color: var(--anti);
    background: var(--bg-color); 
}

/* Fixed top navbar */
.navbar.fixed-top { 
    border-bottom:1px solid var(--border); 
}

/* Fixed sidebar (desktop) */
.sidebar-fixed {
  position: fixed;
  top: var(--navbar-h);
  left: 0;
  width: var(--sidebar-w);
  height: calc(100vh - var(--navbar-h));
  border-right:1px solid var(--border);
  background:#fff;
  overflow-y:auto;
}

/* Sidebar mobile */
.offcanvas-body .nav-link{
    color: var(--anti-light);
    border-radius: .5rem; 
    font-weight: 400;
}

.offcanvas-body .nav-link.active{
    color: var(--anti);
    background: var(--bg-color); 
}

/* Content */
.content { 
    flex:1 1 auto; 
    min-width:0; 
}
/* Layout spacing: push content to the right + below navbar */
.content-fixed {
    padding-top: var(--navbar-h);
    margin-left: var(--sidebar-w);
}

.content-inner { 
    max-width: 1140px; 
    margin-inline:auto; 
    padding: 1rem; 
}

/* Mobile: hide fixed sidebar, use offcanvas */
@media (max-width: 991.98px){
    .sidebar { display:none; }
    .sidebar-fixed { display:none; }
    .content-fixed { margin-left: 0; }
}

.block {
    margin: 10px 0;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    /* From https://css.glass */
    background: #ffffff;
    border-radius: 20px;
    padding: 30px;
}

.block .kpi-value{
    font-size: 25px;
    font-weight: 600;
    align-items: center;
    display: flex;
}

/* Badges */

.profit-badge {
    display: inline-flex;
    color: var(--green);                    /* greenCustom color */
    padding: 6px 10px;                 /* vertical horizontal - matches medium size */
    background-color: color-mix(in srgb, var(--green) 10%, transparent);  /* greenCustom with 15% opacity */
    font-size: 12px;                   /* medium size */
    border-radius: 20px;               /* medium size */
    line-height: inherit;
    align-items: center;
    font-weight: 600;
    gap: 4px;                          /* Space between icon and text */
}

.profit-badge i {
    font-size: 14px;
}

.loss-badge {
    display: inline-flex;
    color: var(--red);                    /* redCustom color */
    padding: 6px 10px;                 /* vertical horizontal - matches medium size */
    background-color: color-mix(in srgb, var(--red) 10%, transparent);  /* redCustom with 15% opacity */
    font-size: 12px;                   /* medium size */
    border-radius: 20px;               /* medium size */
    line-height: inherit;
    align-items: center;
    font-weight: 600;
    gap: 4px;                          /* Space between icon and text */
}

.loss-badge i {
    font-size: 14px;
}

.primary-badge {
    display: inline-flex;
    color: var(--primary);
    padding: 6px 10px;
    background-color: color-mix(in srgb, var(--primary) 15%, transparent);
    font-size: 12px;
    border-radius: 20px;
    line-height: inherit;
    align-items: center;
    font-weight: 600;
    gap: 4px;                          /* Space between icon and text */
}

.primary-badge i {
    font-size: 14px;
}

/* Ticker badge - combines ticker symbol with price change */
.ticker-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    line-height: inherit;
}

.ticker-badge .ticker-symbol {
    font-weight: 700;
}

.ticker-badge.small {
    padding: 4px 8px;
    font-size: 10px;
}

.ticker-badge i {
    font-size: 12px;
}

.ticker-badge.small i {
    font-size: 10px;
}

/* Time badge - matches other badge styles */
.time-badge {
    display: inline-flex;
    align-items: center;
    color: var(--anti-light);
    padding: 6px 10px;
    background-color: color-mix(in srgb, var(--anti-light) 10%, transparent);
    font-size: 12px;
    border-radius: 20px;
    line-height: inherit;
    font-weight: 500;
}

.time-badge.small {
    padding: 4px 8px;
    font-size: 10px;
}

/* Small badge variants */
.profit-badge.small,
.loss-badge.small,
.primary-badge.small {
    padding: 4px 8px;
    font-size: 10px;
}

.badge.small {
    padding: 4px 8px;
    font-size: 10px;
}

.chip.small {
    padding: 4px 8px;
    font-size: 10px;
}

/* Block href */
.block-href {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
    transition: 0.1s ease;
}

.block-href:hover{
    background: var(--bg-color) !important;
}

/* Table href */
/* Base cells (normal state): make bg explicit & animatable */
.table.positions-table > :not(caption) > * > * {
    background-color: transparent !important;   /* beat Bootstrap var */
    transition: background-color 0.1s ease;     /* animate */
  }
  
  /* Hover state: explicit color, animates from transparent */
  .table.positions-table > tbody > tr:hover > * {
    background-color: var(--bg-color) !important;
  }

/* Positions table headers */
.table.positions-table thead th {
  font-weight: normal !important;
  text-transform: uppercase;
  color: var(--anti-light) !important;
}

/* Positions table row borders */
.table.positions-table tbody tr:not(:last-child) {
  border-bottom: 1px solid rgba(105, 113, 128, 0.1) !important;
}

/* PL percentage text */
.loss-percentage-text {
    font-weight: 400;
    color: var(--red);
}


.profit-percentage-text {
    font-weight: 400;
    color: var(--green);
}

/* Border radius */
.br-30 {
    border-radius: 30px;
}

/* Tables */
.positions th{
    color: var(--text-strong);
}

.positions td{
    color: var(--anti);
}

tr[data-href] {
    cursor: pointer;
}

/* Forms */


.custom-form {
    width: 100%;
    display: block;
    font-size: 15px;
    padding: 10px 20px;
    border-radius: 15px;
    outline: 0;
    border: 0;
    background-color: var(--bg-color);
}

.custom-form.alter{
    background-color: var(--bs-gray-200);
}

select.custom-form{
    appearance: none;           /* hide native arrow */
    -webkit-appearance: none;
    -moz-appearance: none;

    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='black' class='bi bi-caret-down-fill' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E") no-repeat, var(--bg-color);
    background-position: right 1rem center; /* move arrow inward from right edge */
    background-size: 1rem;
}

.custom-input-group .custom-form {
    display: inline-block;
    margin-left: -5px;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.custom-input-group .custom-input-group-text {
    display: inline-block;
    font-size: 15px;
    border-top-left-radius: 15px;
    border-bottom-left-radius: 15px;
    padding: 10px;
    padding-left: 20px;
    height: 100%;
    background-color: var(--bg-color);
}

/* ------------ Slider selector thumbler ------------- */
.custom-slider-thumbler {
    padding: 5px;
    border-radius: 15px;
    background: var(--bg-color);
    width: fit-content;
    height: fit-content;
    list-style: none;
    margin: auto;
}

.custom-slider-thumbler li{
    display: inline-block;
}

.custom-slider-thumbler li button{
    background: transparent;
    color: var(--text-strong);
    border: 0;
    padding: 10px 15px;
    border-radius: 15px;
    transition: 0.3s ease;
}

.custom-slider-thumbler li button.active{
    background: var(--primary);
    color: white;
}
/* Small */
.custom-slider-thumbler.small{
    font-size: 12px;
}
.custom-slider-thumbler li button{
    padding: 5px 10px;
}
/* No color */
.custom-slider-thumbler.no-color li button.active{
    background: white;
    color: var(--text-strong);
    font-weight: 900;
}

/* billing button (widthdraw/deposit) */
.billing-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;

    /* fixed size */
    width: 240px;
    height: 96px;
    padding: 16px 20px;
    border-radius: 12px;

    /* theme colors */
    background-color: white;  /* white */
    color: var(--primary);
    border: 1px solid var(--primary);

    text-align: center;
    font-weight: 600;

    transition: 0.3s ease;
}

/* fixed icon size for withdraw/deposit button*/
.billing-buttons .bi { font-size: 24px; }

/* billing button simple invert on hover (no animation/transform) */
.billing-buttons:hover {
    background-color: var(--primary);   /* #394dff */
    color: white;
}

/* button for adding ach and wire link in billing */
.billing-button-link {
    background: transparent;
    border: 0;
    color: var(--primary);
    padding: 0;
    cursor: pointer;
}

.billing-button-link:hover {
    color: var(--secondary);
}

/* billing unlink button */
.billing-button-unlink {

    color: rgb(225, 45, 45);

    border-width: 1px;
    border-style: solid;
    border-color: rgb(225, 45, 45);
    border-radius: 9999px;

    padding-top: 3px;
    padding-bottom: 3px;

    padding-left: 14px;
    padding-right: 14px;

    font-size: 14px;

}

.billing-button-unlink:hover {
    color: white;
    background-color: rgb(225, 45, 45); 
}

/* Links */
.custom-link {
    color: var(--secondary);
    transition: 0.3s ease;
    text-decoration: none;
}
.custom-link:hover {
    color: var(--primary);
}

/* buttons */
.primary-button {
    border: 0;
    padding: 10px 30px;
    background: var(--primary);
    border-radius: 15px;
    color: white;
    transition: 0.3s ease;
    text-decoration: none;
}
.primary-button:hover {
    background: var(--secondary);
}

.secondary-button {
    border: 0;
    padding: 10px 30px;
    background: transparent;
    border-radius: 15px;
    color: var(--primary);
    border: 1px solid var(--primary);
    transition: 0.3s ease;
    text-decoration: none;
}
.secondary-button:hover {
    background: rgba(var(--primary), 0.5);
}

.lang-button {
    padding: 5px 20px;
    border-radius: 50px;
    background: transparent;
    border: 1px solid var(--text-strong);
    color: var(--text-strong);

}

.anti-button {
    border: 1px solid var(--anti-light);
    padding: 10px 30px;
    border-radius: 15px;
    color: var(--anti-light);
    background: transparent;
    transition: 0.3s ease;
}
.anti-button:hover {
    background: var(--secondary);
}

/* Stock view page labels */
#tf-change.profit  { 
    font-weight: bold;
    color: var(--green); 
}
#tf-change.loss    { 
    font-weight: bold;
    color: var(--red); 
}
#tf-change.neutral { 
    font-weight: bold;
    color: black; 
}
#tf-change-label {
    font-weight: 400 ;
    color: var(--anti);
}

.stock-logo {
    width: 50px;
    height: 50px;
    margin-right: 10px;
    border-radius: 50px;
    /* background: black; */
}

.loss-pct {
    font-size: 12px;
    color: var(--red);
}

.profit-pct {
    font-size: 13px;
    color: var(--green);
}

/* News Section Styles */
.news-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.news-item {
    border-bottom: 1px solid var(--bg-color);
    transition: background-color 0.2s ease;
}

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

.news-item:hover {
    background-color: var(--bg-color);
}

.news-sentiment {
    flex-shrink: 0;
    margin-top: 2px;
}

.sentiment-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
}

.sentiment-badge.positive {
    background-color: var(--green-light);
    color: var(--green);
}

.sentiment-badge.negative {
    background-color: var(--red-light);
    color: var(--red);
}

.sentiment-badge.neutral {
    background-color: var(--bg-color);
    color: var(--anti-light);
}

/* Movers List Styles */
.movers-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.mover-item {
    border-bottom: 1px solid var(--bg-color);
    transition: background-color 0.2s ease;
}

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

.mover-item:hover {
    background-color: var(--bg-color);
}

/* Order Tabs Styles */
.order-tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--bg-color);
    margin-bottom: 0;
    padding: 0;
}

.order-tabs .nav-item {
    margin: 0;
}

.order-tabs .nav-link {
    border: none;
    border-bottom: 3px solid transparent;
    background: transparent;
    color: var(--anti-light);
    padding: 12px 20px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    position: relative;
    cursor: pointer;
}

.order-tabs .nav-link:hover {
    color: var(--text-strong);
    background: transparent;
    border-bottom-color: transparent;
}

.order-tabs .nav-link.active {
    color: var(--primary);
    background: transparent;
    border-bottom-color: var(--primary);
    font-weight: 600;
}

.order-count {
    margin-left: 6px;
    padding: 2px 8px;
    border-radius: 12px;
    background: var(--bg-color);
    font-size: 12px;
    font-weight: 500;
    color: var(--anti-light);
}

.order-tabs .nav-link.active .order-count {
    background: color-mix(in srgb, var(--primary) 15%, transparent);
    color: var(--primary);
}

/* Notification Toast Styles */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.notification {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    pointer-events: auto;
    min-width: 300px;
    max-width: 400px;
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

.notification.removing {
    animation: slideOutRight 0.3s ease-out forwards;
}

.notification.success {
    background-color: var(--green);
    color: white;
}

.notification.error {
    background-color: var(--red);
    color: white;
}

.notification-icon {
    font-size: 20px;
    flex-shrink: 0;
    color: white;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 2px;
    color: white;
}

.notification-message {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
}