.album-trades-page {
    --album-header-bg: rgba(10, 16, 20, 0.85);
    --album-header-border: rgba(255, 255, 255, 0.08);
    --album-particle-glow: rgba(43, 209, 216, 0.5);
    min-height: 100vh;
    background:
        radial-gradient(circle at 50% 15%, rgba(9, 184, 189, 0.12), transparent 45%),
        radial-gradient(circle at 80% 25%, rgba(9, 184, 189, 0.04), transparent 30%),
        linear-gradient(180deg, #070b0d 0%, #0b1114 100%);
    background-attachment: fixed;
    color: #e3edf0;
    font-family: 'Outfit', 'Inter', sans-serif;
}

.album-trades-page :is(h1, h2, h3, p, span, strong, label, button, a) {
    text-shadow: none;
}

/* Header Overrides for dark premium feel */
.album-trades-page .album-header-brand {
    color: #ffffff;
}

/* Header inherits the default premium styles from the album page */

.album-header-center-trades {
    gap: 0;
}

.album-trades-pill {
    min-height: 44px;
    padding: 6px 16px;
}

.album-trades-shell {
    padding-top: 18px;
    width: min(1320px, calc(100% - 60px));
}

.album-trades-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    width: 100%;
}

/* Tabs layout */
.album-trades-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.album-trades-tab {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid rgba(43, 209, 216, 0.22);
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(9, 88, 96, 0.8) 0%, rgba(8, 125, 132, 0.62) 100%);
    color: #ecfeff;
    font: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    white-space: nowrap;
    transition: all 0.25s ease;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.album-trades-tab:hover {
    background: linear-gradient(135deg, #0aa7b2 0%, #10b7bd 100%);
    color: #ffffff;
    border-color: rgba(43, 209, 216, 0.65);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(10, 167, 178, 0.22), 0 0 18px rgba(43, 209, 216, 0.16);
}

.album-trades-tab.is-active {
    background: linear-gradient(135deg, #08a1aa 0%, #18c0c6 100%);
    color: #ffffff;
    border: 1px solid rgba(43, 209, 216, 0.85);
    box-shadow: 0 8px 22px rgba(10, 167, 178, 0.28), 0 0 18px rgba(43, 209, 216, 0.2);
    transform: translateY(-1px);
}

/* Search bar styling */
.album-trades-search {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    border-radius: 12px;
    background: rgba(13, 22, 26, 0.65);
    border: 1px solid rgba(43, 209, 216, 0.15);
    backdrop-filter: blur(8px);
    width: 300px;
    flex-shrink: 0;
}

.album-trades-search label {
    color: #2bd1d8;
    font-size: 0.86rem;
    font-weight: 800;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
}

.album-trades-search label::before {
    content: "";
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 6px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='14' height='14' stroke='%232bd1d8' stroke-width='2.5' fill='none'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") no-repeat center;
    background-size: contain;
}

.album-trades-search input {
    padding: 6px 10px;
    font-size: 0.86rem;
}

.album-trades-search input,
.album-trades-form input,
.album-trades-form select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid rgba(43, 209, 216, 0.18);
    border-radius: 10px;
    background: rgba(7, 12, 15, 0.9);
    color: #ffffff;
    font: inherit;
    transition: all 0.2s ease;
}

.album-trades-search input:focus,
.album-trades-form input:focus,
.album-trades-form select:focus {
    outline: none;
    border-color: #2bd1d8;
    box-shadow: 0 0 8px rgba(43, 209, 216, 0.35);
}

.album-trades-form select option {
    background: #0b1114;
    color: #ffffff;
}

.album-trades-layout {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.album-trades-sidebar,
.album-trades-content {
    display: grid;
    gap: 14px;
    align-content: start;
    align-items: start;
}

/* Panels styling (Glassmorphism) */
.album-trades-panel {
    padding: 18px;
    border-radius: 18px;
    background: rgba(13, 22, 26, 0.8);
    border: 1px solid rgba(43, 209, 216, 0.05);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(12px);
}

.album-trades-panel h2 {
    margin: 0;
    color: #ffffff;
    font-size: 1.15rem;
    font-weight: 800;
}

.album-trades-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.album-trades-head-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

/* New CSS filter rows standard styles */
.album-card-filters-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    flex-wrap: wrap;
    gap: 12px;
    width: 100%;
}

.album-card-filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    margin: 0;
}

.album-filter-card-name {
    max-width: 220px;
    padding: 8px 32px 8px 12px;
    border: 1px solid rgba(43, 209, 216, 0.18);
    border-radius: 10px;
    background: rgba(7, 12, 15, 0.9) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='14' height='14' stroke='%232bd1d8' stroke-width='2.5' fill='none'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") no-repeat right 10px center;
    background-size: 14px;
    color: #ffffff;
    font-family: inherit;
    transition: all 0.2s ease;
}

.album-filter-card-name:focus {
    outline: none;
    border-color: #2bd1d8;
    box-shadow: 0 0 8px rgba(43, 209, 216, 0.35);
}

.album-filter-card-team,
.album-filter-card-rarity {
    padding: 8px 12px;
    border: 1px solid rgba(43, 209, 216, 0.18);
    border-radius: 10px;
    background: rgba(7, 12, 15, 0.9);
    color: #ffffff;
    font-family: inherit;
    font-weight: 700;
    transition: all 0.2s ease;
}

.album-filter-card-team:focus,
.album-filter-card-rarity:focus {
    outline: none;
    border-color: #2bd1d8;
    box-shadow: 0 0 8px rgba(43, 209, 216, 0.35);
}

.album-filter-card-team option,
.album-filter-card-rarity option {
    background: #0b1114;
    color: #ffffff;
}

.album-trades-panel-head span,
.album-trades-selected-user {
    color: #2bd1d8;
    font-weight: 700;
}

.album-trades-user-list {
    display: grid;
    gap: 8px;
    margin-top: 12px;
    max-height: 280px;
    overflow: auto;
}

.album-trades-user-list::-webkit-scrollbar {
    width: 6px;
}
.album-trades-user-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}
.album-trades-user-list::-webkit-scrollbar-thumb {
    background: rgba(43, 209, 216, 0.2);
    border-radius: 10px;
}

.album-trades-user-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: rgba(20, 32, 38, 0.5);
    color: #ffffff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
}

.album-trades-user-button:hover {
    background: rgba(9, 184, 189, 0.08);
    border-color: rgba(43, 209, 216, 0.3);
    color: #ffffff;
}

.album-trades-user-button.is-active {
    border-color: rgba(43, 209, 216, 0.5);
    background: rgba(9, 184, 189, 0.16);
    color: #2bd1d8;
    box-shadow: 0 0 12px rgba(43, 209, 216, 0.15);
}

.album-trades-user-button span {
    color: #ffffff;
    transition: color 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
    flex-grow: 1;
}

.album-trades-user-button.is-active span {
    color: #2bd1d8;
}

.album-trades-user-button strong {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 0.8rem;
    padding: 2px 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.album-trades-user-button.is-active strong {
    background: rgba(43, 209, 216, 0.2);
    color: #2bd1d8;
}

.album-trades-sidebar .album-trades-panel:nth-child(2) {
    padding: 24px 20px;
}

.album-trades-form {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.album-trades-form label {
    color: #8faeb4;
    font-size: 0.86rem;
    font-weight: 700;
}

.album-trades-form label:not(:first-of-type) {
    margin-top: 8px;
}

/* Nova Proposta submit button styling */
.album-trades-form .album-button {
    background: linear-gradient(135deg, #0a5864 0%, #09b8bd 100%);
    color: #ffffff;
    border: 1px solid rgba(43, 209, 216, 0.3);
    box-shadow: 0 6px 20px rgba(9, 184, 189, 0.2);
    font-weight: 800;
    transition: all 0.2s ease;
    margin-top: 14px;
}

.album-trades-form .album-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(9, 184, 189, 0.35);
    background: linear-gradient(135deg, #09b8bd 0%, #2bd1d8 100%);
}

.album-trades-view {
    display: none;
}

.album-trades-view.is-active {
    display: block;
}

.album-trades-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(172px, 172px));
    gap: 18px;
    align-items: start;
}

.album-trade-card,
.album-trade-request,
.album-trade-history-card {
    border: 1px solid rgba(43, 209, 216, 0.12);
    border-radius: 16px;
    background: rgba(13, 22, 26, 0.75);
    overflow: hidden;
}

.album-trade-card {
    display: grid;
    grid-template-rows: auto auto;
    gap: 10px;
    padding: 0;
    border: 0;
    background: transparent;
    overflow: visible;
    width: 172px;
    min-width: 0;
}

.album-trade-card-media {
    position: relative;
    aspect-ratio: 0.72;
    min-height: 0;
    transition: transform 0.2s ease, filter 0.2s ease;
    border-radius: 18px; /* Match tdj-card border radius */
}

.album-trade-card-media:has(.tdj-card.rarity-prime) {
    box-shadow: 0 0 0 2px #a855f7, 0 4px 12px rgba(168, 85, 247, 0.6);
}

.album-trade-card-media:has(.tdj-card.rarity-legend) {
    box-shadow: 0 0 0 2px #ffd700, 0 4px 12px rgba(255, 215, 0, 0.5);
}

.album-trade-card-media:has(.tdj-card.rarity-alien) {
    box-shadow: 0 0 0 2px #39ff14, 0 4px 12px rgba(57, 255, 20, 0.5);
}

.album-trade-card-media:has(.tdj-card.rarity-raro) {
    box-shadow: 0 0 0 2px #00bfff, 0 4px 12px rgba(0, 191, 255, 0.5);
}

.album-trade-card:hover .album-trade-card-media {
    transform: translateY(-6px) scale(1.02);
    filter: drop-shadow(0 12px 24px rgba(9, 184, 189, 0.3));
    z-index: 10;
}

.album-trade-card-media .album-sticker-frame {
    width: 100%;
    height: 100%;
}

.album-trade-card-media .album-figurinha-art > img,
.album-trade-card-media .album-figurinha-art > .album-sticker-placeholder {
    width: 100%;
    height: 100%;
}

.album-trade-card-body {
    min-height: 78px;
    padding: 10px 11px;
    display: grid;
    gap: 8px;
    align-content: start;
    border-radius: 12px;
    background: rgba(9, 30, 35, 0.7);
    border: 1px solid rgba(43, 209, 216, 0.12);
    min-width: 0;
    overflow: hidden;
}

.album-trade-card-top {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.album-trade-card-top strong,
.album-trade-request-card strong,
.album-trade-history-card strong {
    color: #ffffff;
}

.album-trade-card-top strong {
    display: block;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.album-trade-card-body span,
.album-trade-request-card span,
.album-trade-history-card span {
    color: #8faeb4;
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
}

.album-trade-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    color: #8faeb4;
    font-size: 0.84rem;
    font-weight: 700;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.album-trade-card-meta-pills > span {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(7, 12, 15, 0.6);
    border: 1px solid rgba(43, 209, 216, 0.14);
    color: #cfdcdb;
    line-height: 1.1;
    max-width: 100%;
    box-sizing: border-box;
}

.album-trade-card-meta-pills .album-trade-user-pill {
    display: flex !important;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 6px 10px;
    border-radius: 8px;
    background: rgba(7, 12, 15, 0.7);
    border: 1px solid rgba(43, 209, 216, 0.16);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    gap: 3px;
    min-height: unset;
}

.album-trade-user-label {
    font-size: 0.62rem !important;
    color: #8faeb4 !important;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    line-height: 1 !important;
    font-weight: 700;
    pointer-events: none;
}

.album-trade-user-name {
    font-size: 0.8rem !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    display: block;
    line-height: 1.2 !important;
    text-transform: uppercase;
}

.album-trade-card-meta-pills .album-trade-card-rarity {
    font-weight: 900;
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
}

.album-trade-card-meta-pills .album-trade-card-rarity.rarity-comum {
    background: rgba(9, 184, 189, 0.12);
    color: #2bd1d8;
    border-color: rgba(43, 209, 216, 0.3);
}

.album-trade-card-meta-pills .album-trade-card-rarity.rarity-raro {
    background: rgba(0, 191, 255, 0.15);
    color: #00bfff;
    border-color: rgba(0, 191, 255, 0.35);
}

.album-trade-card-meta-pills .album-trade-card-rarity.rarity-prime {
    background: rgba(168, 85, 247, 0.18);
    color: #c582f3;
    border-color: rgba(168, 85, 247, 0.4);
}

.album-trade-card-meta-pills .album-trade-card-rarity.rarity-legend {
    background: rgba(255, 215, 0, 0.15);
    color: #ffd700;
    border-color: rgba(255, 215, 0, 0.35);
}

.album-trade-card-meta-pills .album-trade-card-rarity.rarity-alien {
    background: rgba(57, 255, 20, 0.15);
    color: #39ff14;
    border-color: rgba(57, 255, 20, 0.35);
}

.album-trades-request-list,
.album-trades-history-list {
    display: grid;
    gap: 12px;
}

.album-trade-request,
.album-trade-history-card {
    padding: 14px;
    border: 1px solid rgba(43, 209, 216, 0.12);
    background: rgba(13, 22, 26, 0.75);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.album-trade-request-head,
.album-trade-history-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    min-width: 0;
}

.album-trade-request-head strong,
.album-trade-history-head strong {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}

.album-trade-history-users {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.album-trade-history-users strong {
    color: #ffffff;
}

.album-trade-history-users span {
    color: #2bd1d8;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
}

.album-trade-request-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 12px;
    align-items: center;
}

.album-trade-swap-divider {
    display: flex;
    align-items: center;
    justify-content: center;
}

.album-trade-swap-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(7, 12, 15, 0.95);
    border: 1px solid rgba(43, 209, 216, 0.25);
    color: #2bd1d8;
    font-size: 1.15rem;
    box-shadow: 0 0 10px rgba(43, 209, 216, 0.15);
    user-select: none;
    transition: transform 0.25s ease;
}

.album-trade-request:hover .album-trade-swap-icon,
.album-trade-history-card:hover .album-trade-swap-icon {
    transform: rotate(180deg);
}

.album-trade-date {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8rem !important;
    color: #8faeb4 !important;
}

@media (max-width: 640px) {
    .album-trade-request-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .album-trade-swap-divider {
        padding: 4px 0;
    }

    .album-trade-swap-icon {
        transform: rotate(90deg);
    }

    .album-trade-request:hover .album-trade-swap-icon,
    .album-trade-history-card:hover .album-trade-swap-icon {
        transform: rotate(270deg);
    }
}

.album-trade-request-card {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 14px;
    background: rgba(9, 30, 35, 0.7);
    border: 1px solid rgba(43, 209, 216, 0.1);
}

.album-trade-request-card-info {
    min-width: 0;
    display: grid;
    gap: 7px;
    align-content: center;
}

.album-trade-request-card-info strong {
    line-height: 1.12;
    overflow-wrap: anywhere;
}

.album-trade-request-card-label {
    width: fit-content;
    max-width: 100%;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(9, 184, 189, 0.16);
    color: #2bd1d8 !important;
    font-size: 0.72rem !important;
    font-weight: 900 !important;
    line-height: 1.15;
}

.album-trade-request-card-media {
    position: relative;
    width: 86px;
    aspect-ratio: 0.72;
    overflow: hidden;
    border-radius: 12px;
}

.album-trade-request-card-media:has(.tdj-card.rarity-prime) {
    box-shadow: 0 0 0 2px #a855f7, 0 4px 12px rgba(168, 85, 247, 0.6);
}

.album-trade-request-card-media:has(.tdj-card.rarity-legend) {
    box-shadow: 0 0 0 2px #ffd700, 0 4px 12px rgba(255, 215, 0, 0.5);
}

.album-trade-request-card-media:has(.tdj-card.rarity-alien) {
    box-shadow: 0 0 0 2px #39ff14, 0 4px 12px rgba(57, 255, 20, 0.5);
}

.album-trade-request-card-media:has(.tdj-card.rarity-raro) {
    box-shadow: 0 0 0 2px #00bfff, 0 4px 12px rgba(0, 191, 255, 0.5);
}

.album-trade-request-card-media .album-sticker-frame {
    width: 100%;
    height: 100%;
    border-width: 2px;
    border-radius: 12px;
}

.album-trade-request-card-media .album-figurinha-flag,
.album-trade-request-card-media .album-figurinha-ribbon span,
.album-trade-request-card-media .album-placeholder-flag,
.album-trade-request-card-media .album-placeholder-team {
    display: none;
}

.album-trade-request-card-media .album-figurinha-ribbon {
    min-height: 28px;
    padding: 5px 5px 6px;
    border-top-width: 2px;
}

.album-trade-request-card-media .album-figurinha-ribbon strong {
    font-size: 0.52rem;
    line-height: 1;
}

.album-trade-request-card-media .album-placeholder-number {
    font-size: 1.7rem;
}

.album-trade-request-card-media .album-sticker-placeholder-card {
    padding: 12px 8px 28px;
    border-width: 4px;
    border-radius: 10px;
}

.album-trade-request-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.album-trade-action {
    min-height: 40px;
    padding: 0 18px;
    border: 0;
    border-radius: 999px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
}

.album-trade-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

.album-trade-action.accept {
    background: linear-gradient(135deg, #1d6f3a 0%, #2bb673 100%);
    color: #fff;
}

.album-trade-action.accept:hover {
    background: linear-gradient(135deg, #228043 0%, #30ca80 100%);
}

.album-trade-action.reject,
.album-trade-action.cancel {
    background: linear-gradient(135deg, #8a2a2a 0%, #d9534f 100%);
    color: #fff;
}

.album-trade-action.reject:hover,
.album-trade-action.cancel:hover {
    background: linear-gradient(135deg, #9e3030 0%, #e0605c 100%);
}

.album-trade-status {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.album-trade-status.pendente {
    background: rgba(224, 170, 42, 0.15);
    color: #ffd066;
}

.album-trade-status.aceita {
    background: rgba(43, 182, 115, 0.15);
    color: #2be588;
}

.album-trade-status.recusada,
.album-trade-status.cancelada {
    background: rgba(217, 83, 79, 0.15);
    color: #ff6b6b;
}

.album-trades-empty {
    padding: 24px 18px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    color: #8faeb4;
    font-weight: 700;
    text-align: center;
}

@media (max-width: 1080px) {
    .album-trades-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 920px) {
    .album-trades-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    .album-trades-search {
        width: 100%;
    }
}

@media (max-width: 720px) {
    .album-trade-request-grid {
        grid-template-columns: 1fr;
    }

    .album-trades-grid {
        grid-template-columns: repeat(2, minmax(120px, 168px));
        justify-content: center;
        gap: 14px;
    }
}

/* Paginação Estilizada para Tela de Trocas */
.album-trades-page .pagination-container {
    display: none; /* Controlado via JS: flex/none */
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border-radius: 20px;
    gap: 10px;
    margin: 0;
    background-color: rgba(13, 22, 26, 0.9);
    border: 1px solid rgba(43, 209, 216, 0.15);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

.album-trades-page .pagination-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(9, 184, 189, 0.15);
    border-color: rgba(43, 209, 216, 0.3);
}

.album-trades-page .album-message {
    z-index: 100001;
}

.album-trades-page .pagination-btn::before {
    display: none !important;
}

.album-trades-page .pagination-btn {
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 700;
    padding: 4px 10px;
    font-size: 0.8rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.album-trades-page .pagination-btn:hover:not(:disabled) {
    background: rgba(9, 184, 189, 0.15);
    color: #2bd1d8;
    border-color: #2bd1d8;
    box-shadow: 0 0 10px rgba(9, 184, 189, 0.3);
}

.album-trades-page .pagination-btn:disabled {
    opacity: 0.35;
    background: rgba(255, 255, 255, 0.02);
    color: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.05);
    cursor: not-allowed;
}

.album-trades-page #page-info,
.album-trades-page .page-info {
    color: #ffffff;
    background-color: rgba(9, 184, 189, 0.1);
    font-size: 0.82rem;
    padding: 3px 8px;
    min-width: 90px;
    border-radius: 8px;
    text-align: center;
    font-weight: 700;
}

/* Update Pin Micro-animations */
@keyframes pin-bounce {
    0% {
        transform: translateY(0) scale(1);
        filter: drop-shadow(0 2px 4px rgba(255, 77, 77, 0.5));
    }
    100% {
        transform: translateY(-3px) scale(1.15);
        filter: drop-shadow(0 5px 9px rgba(255, 77, 77, 0.8));
    }
}

.tab-update-pin {
    animation: pin-bounce 0.8s infinite alternate ease-in-out;
    display: inline-block;
    flex-shrink: 0;
}

/* Notice Banner for Trade Rules */
.album-trades-notice-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-radius: 14px;
    background: rgba(43, 209, 216, 0.06);
    border: 1px solid rgba(43, 209, 216, 0.15);
    margin-bottom: 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(8px);
}

.album-trades-notice-icon {
    font-size: 1.4rem;
    animation: pulseNotice 2s infinite alternate ease-in-out;
    user-select: none;
}

.album-trades-notice-content {
    color: #e3edf0;
    font-size: 0.88rem;
    line-height: 1.45;
}

.album-trades-notice-content strong {
    color: #2bd1d8;
    font-weight: 800;
}

.album-trades-notice-content u {
    text-decoration: underline;
    text-underline-offset: 2px;
    color: #ffd066;
    font-weight: 700;
}

@keyframes pulseNotice {
    0% { transform: scale(1); }
    100% { transform: scale(1.15); }
}

@media (max-width: 720px) {
    .album-trades-notice-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 12px 16px;
    }

    /* Ajustes de responsividade para evitar vazamentos e quebras */
    .album-trades-panel-head {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 12px !important;
        width: 100%;
    }

    .album-trades-panel-head h2 {
        font-size: 1.4rem !important;
        margin: 0;
    }

    .album-trades-head-actions {
        width: 100%;
        justify-content: space-between !important;
        gap: 8px !important;
    }

    /* Reduzir paddings e tamanhos da paginação no mobile */
    .album-trades-page .pagination-container {
        padding: 4px 8px !important;
        gap: 6px !important;
        border-radius: 12px !important;
    }

    .album-trades-page .pagination-btn {
        padding: 4px 8px !important;
        font-size: 0.75rem !important;
        border-radius: 8px !important;
    }

    .album-trades-page #page-info,
    .album-trades-page .page-info {
        font-size: 0.75rem !important;
        min-width: 80px !important;
        padding: 2px 6px !important;
        border-radius: 6px !important;
    }

    .album-trades-page .page-jump-input {
        width: 42px !important;
        font-size: 0.75rem !important;
        border-radius: 4px !important;
        padding: 1px !important;
    }

    /* Grid de Estatísticas Geral compactado em mobile */
    .album-trades-stats-banner {
        padding: 10px 12px !important;
        grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)) !important;
        gap: 10px !important;
    }

    .album-trades-stat-item {
        justify-content: flex-start !important;
        gap: 8px !important;
        padding: 5px 0 !important;
    }

    .album-trades-stat-item:not(:last-child) {
        border-right: none !important;
    }

    .album-trades-stats-banner > div > div:first-child {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        font-size: 1.2rem !important;
    }

    .album-trades-stats-banner #stat-top-trader,
    .album-trades-stats-banner #stat-top-card {
        max-width: 110px !important;
        font-size: 0.95rem !important;
    }

    /* Cards de Histórico e Propostas */
    .album-trade-history-card {
        padding: 10px !important;
        border-radius: 12px !important;
    }

    .album-trade-history-head {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 6px !important;
    }

    .album-trade-history-head > span {
        align-self: flex-end !important;
        font-size: 0.78rem !important;
        color: #8faeb4 !important;
    }

    .album-trade-history-users {
        flex-wrap: wrap !important;
        gap: 4px !important;
        line-height: 1.3 !important;
    }

    .album-trade-request-card {
        gap: 8px !important;
        padding: 8px !important;
        border-radius: 10px !important;
    }
}

/* ==========================================================================
   🚀 ROCKET LEAGUE / FIFA STYLE TRADING SYSTEM MODAL
   ========================================================================== */
.rl-trade-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(5, 10, 12, 0.97);
    backdrop-filter: blur(20px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', 'Inter', sans-serif;
    color: #e3edf0;
    box-sizing: border-box;
    padding: 20px;
    animation: rlFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes rlFadeIn {
    from { opacity: 0; transform: scale(1.02); }
    to { opacity: 1; transform: scale(1); }
}

.rl-trade-container {
    width: 95vw;
    height: 90vh;
    max-width: 1350px;
    max-height: 850px;
    background: linear-gradient(135deg, rgba(13, 23, 28, 0.96) 0%, rgba(7, 12, 15, 0.99) 100%);
    border: 1px solid rgba(43, 209, 216, 0.2);
    border-radius: 24px;
    box-shadow: 
        0 24px 70px rgba(0, 0, 0, 0.8),
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 0 40px rgba(43, 209, 216, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* HEADER STYLE */
.rl-trade-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    background: rgba(10, 16, 20, 0.6);
    border-bottom: 1px solid rgba(43, 209, 216, 0.12);
}

.rl-trade-header-tag {
    color: #2bd1d8;
    font-size: 0.7rem;
    font-weight: 900;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.rl-trade-main-title {
    margin: 4px 0 0;
    font-size: 1.6rem;
    font-weight: 900;
    background: linear-gradient(90deg, #ffffff 0%, #aeeef1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.rl-trade-user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #8faeb4;
}

.rl-username-highlight {
    color: #2bd1d8;
    background: rgba(43, 209, 216, 0.1);
    border: 1px solid rgba(43, 209, 216, 0.25);
    padding: 4px 12px;
    border-radius: 999px;
    font-weight: 800;
    text-transform: uppercase;
}

/* MAIN LAYOUT */
.rl-trade-layout {
    display: grid;
    grid-template-columns: 1fr 440px;
    flex-grow: 1;
    overflow: hidden;
}

/* LEFT INVENTORY PANEL */
.rl-trade-inventory-panel {
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(43, 209, 216, 0.08);
    overflow: hidden;
    background: rgba(7, 12, 15, 0.35);
}

.rl-inventory-tabs {
    display: flex;
    gap: 2px;
    background: rgba(5, 8, 10, 0.5);
    border-bottom: 1px solid rgba(43, 209, 216, 0.08);
}

.rl-inv-tab {
    flex: 1;
    padding: 18px 24px;
    background: none;
    border: 0;
    color: #8faeb4;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.25s ease;
    border-bottom: 3px solid transparent;
}

.rl-inv-tab:hover {
    color: #2bd1d8;
    background: rgba(43, 209, 216, 0.03);
}

.rl-inv-tab.active {
    color: #2bd1d8;
    background: rgba(9, 184, 189, 0.06);
    border-bottom-color: #2bd1d8;
}

.tab-bullet {
    width: 6px;
    height: 6px;
    background: #8faeb4;
    border-radius: 50%;
    transition: all 0.25s ease;
}

.rl-inv-tab.active .tab-bullet {
    background: #2bd1d8;
    box-shadow: 0 0 8px #2bd1d8;
}

/* SEARCH & FILTERS */
.rl-inventory-filter-bar {
    display: grid;
    grid-template-columns: 1fr 200px;
    gap: 15px;
    padding: 15px 25px;
    background: rgba(10, 16, 20, 0.2);
    border-bottom: 1px solid rgba(43, 209, 216, 0.05);
}

.rl-search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(7, 12, 15, 0.75);
    border: 1px solid rgba(43, 209, 216, 0.15);
    padding: 0 14px;
    border-radius: 12px;
}

.rl-search-input-wrapper svg {
    color: #2bd1d8;
}

.rl-search-input-wrapper input {
    background: none;
    border: 0;
    width: 100%;
    padding: 10px 0;
    font-family: inherit;
    font-size: 0.88rem;
    color: #ffffff;
    outline: none;
}

.rl-select-filter {
    background: rgba(7, 12, 15, 0.75);
    border: 1px solid rgba(43, 209, 216, 0.15);
    border-radius: 12px;
    padding: 10px;
    color: #ffffff;
    font-family: inherit;
    font-size: 0.88rem;
    outline: none;
    font-weight: 700;
}

.rl-select-filter option {
    background: #0b1114;
    color: #ffffff;
}

/* INVENTORY SCROLL & GRID */
.rl-inventory-scroll {
    flex-grow: 1;
    overflow-y: auto;
    padding: 25px;
}

.rl-inventory-scroll::-webkit-scrollbar {
    width: 8px;
}
.rl-inventory-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}
.rl-inventory-scroll::-webkit-scrollbar-thumb {
    background: rgba(43, 209, 216, 0.15);
    border-radius: 4px;
}

.rl-inventory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(136px, 136px));
    gap: 16px;
    justify-content: center;
}

/* CUSTOM RL INVENTORY CARD */
.rl-inv-card {
    cursor: pointer;
    position: relative;
    transition: all 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 136px;
    user-select: none;
}

.rl-inv-card-media {
    position: relative;
    aspect-ratio: 0.72;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(43, 209, 216, 0.1);
    background: rgba(10, 16, 20, 0.6);
    transition: all 0.25s ease;
}

.rl-inv-card:hover .rl-inv-card-media {
    transform: translateY(-5px);
    border-color: rgba(43, 209, 216, 0.4);
    box-shadow: 0 10px 20px rgba(9, 184, 189, 0.25);
}

.rl-inv-card.selected .rl-inv-card-media {
    border-color: #ffd700;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
    transform: scale(0.96) translateY(0);
}

/* Card Selection badge */
.rl-card-selected-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 22px;
    height: 22px;
    background: #ffd700;
    color: #0b1114;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 900;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
    z-index: 15;
}

.rl-inv-card-name {
    display: block;
    margin-top: 6px;
    font-size: 0.76rem;
    font-weight: 800;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #e3edf0;
}

.rl-inv-card-qty {
    position: absolute;
    bottom: 4px;
    right: 4px;
    background: rgba(7, 12, 15, 0.9);
    border: 1px solid rgba(43, 209, 216, 0.2);
    color: #2bd1d8;
    padding: 1px 6px;
    border-radius: 6px;
    font-size: 0.68rem;
    font-weight: 900;
    z-index: 10;
}

/* RIGHT SLOTS PANEL */
.rl-trade-slots-panel {
    display: flex;
    flex-direction: column;
    background: rgba(10, 16, 20, 0.4);
    padding: 25px;
    overflow-y: auto;
    box-sizing: border-box;
    justify-content: space-between;
}

.rl-slots-section {
    background: rgba(7, 12, 15, 0.45);
    border: 1px solid rgba(43, 209, 216, 0.08);
    border-radius: 18px;
    padding: 18px;
    margin-bottom: 20px;
}

.rl-slots-section-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.rl-slots-section-header h3 {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.05em;
}

.rl-slots-desc {
    font-size: 0.76rem;
    color: #8faeb4;
    width: 100%;
}

.rl-slots-container {
    display: flex;
    justify-content: center;
    gap: 14px;
}

.rl-slots-container.col-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

/* TRADE SLOT OBJECT */
.rl-trade-slot {
    aspect-ratio: 0.72;
    border-radius: 14px;
    position: relative;
    transition: all 0.25s ease;
    overflow: visible;
    width: 100%;
    max-width: 136px;
}

.rl-trade-slot.empty {
    border: 2px dashed rgba(43, 209, 216, 0.2);
    background: rgba(13, 22, 26, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
}

.rl-trade-slot.empty:hover {
    border-color: rgba(43, 209, 216, 0.4);
    background: rgba(9, 184, 189, 0.04);
}

.rl-trade-slot.empty.locked {
    border-color: rgba(255, 107, 125, 0.22);
    background: rgba(255, 77, 77, 0.04);
    cursor: not-allowed;
}

.rl-trade-slot.empty.locked:hover {
    border-color: rgba(255, 107, 125, 0.3);
    background: rgba(255, 77, 77, 0.06);
}

.rl-trade-slot.empty.locked .plus-icon,
.rl-trade-slot.empty.locked .slot-text {
    font-size: 0;
}

.rl-trade-slot.empty.locked .plus-icon::after {
    content: "!";
    font-size: 1.1rem;
    font-weight: 900;
    color: #ff6b7d;
}

.rl-trade-slot.empty.locked .slot-text::after {
    content: "Limite: 2 cartas em um lado";
    font-size: 0.62rem;
    font-weight: 800;
    line-height: 1.25;
    color: #ff9aa8;
}

.rl-slot-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 10px;
    gap: 6px;
    color: #8faeb4;
}

.rl-slot-inner .plus-icon {
    font-size: 1.4rem;
    font-weight: 300;
    color: #2bd1d8;
}

.rl-slot-inner .slot-text {
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.2;
}

/* Active Slot card container */
.rl-slot-card-active {
    width: 100%;
    height: 100%;
    position: relative;
    border-radius: 14px;
    animation: rlCardDrop 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.15) forwards;
}

@keyframes rlCardDrop {
    from { transform: scale(0.85); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.rl-slot-card-active .album-sticker-frame {
    width: 100%;
    height: 100%;
    border-radius: 14px;
}

/* Remove button on hover in slot */
.rl-slot-remove-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ff4d4d;
    border: 0;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0,0,0,0.5);
    z-index: 20;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.2s ease;
}

.rl-trade-slot:hover .rl-slot-remove-btn {
    opacity: 1;
    transform: scale(1);
}

/* Qty Adjustment Widget */
.rl-slot-qty-widget {
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(7, 12, 15, 0.95);
    border: 1px solid rgba(43, 209, 216, 0.3);
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 6px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.4);
    z-index: 10;
}

.rl-qty-btn {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 0;
    color: #2bd1d8;
    font-size: 0.8rem;
    font-weight: 900;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}

.rl-qty-btn:hover {
    background: rgba(9, 184, 189, 0.2);
    color: #ffffff;
}

.rl-slot-qty-val {
    font-size: 0.76rem;
    font-weight: 900;
    color: #ffffff;
    min-width: 14px;
    text-align: center;
}

/* FOOTER OPERATIONS */
.rl-trade-footer-actions {
    margin-top: 15px;
    border-top: 1px solid rgba(43, 209, 216, 0.08);
    padding-top: 15px;
}

.rl-status-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.35);
    padding: 8px 12px;
    border-radius: 8px;
    border-left: 2px solid #2bd1d8;
    margin-bottom: 15px;
}

.status-dot {
    width: 6px;
    height: 6px;
    background: #2bd1d8;
    border-radius: 50%;
}

.status-dot.pulsing {
    animation: rlDotPulse 1.2s infinite alternate ease-in-out;
}

@keyframes rlDotPulse {
    0% { transform: scale(1); opacity: 0.4; }
    100% { transform: scale(1.3); opacity: 1; box-shadow: 0 0 6px #2bd1d8; }
}

.status-strip-text {
    font-size: 0.78rem;
    font-weight: 700;
    color: #8faeb4;
}

.rl-footer-buttons {
    display: flex;
    gap: 12px;
}

.rl-action-btn {
    flex: 1;
    min-height: 48px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    letter-spacing: 0.03em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rl-btn-primary {
    background: linear-gradient(135deg, #09b8bd 0%, #178184 100%);
    border: 1px solid rgba(43, 209, 216, 0.3);
    color: #ffffff;
    box-shadow: 0 6px 20px rgba(9, 184, 189, 0.2);
}

.rl-btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #2bd1d8 0%, #09b8bd 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(9, 184, 189, 0.35);
}

.rl-btn-primary:disabled {
    opacity: 0.35;
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.05);
    color: rgba(255,255,255,0.3);
    cursor: not-allowed;
    box-shadow: none;
}

.rl-btn-secondary {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.rl-btn-secondary:hover {
    background: rgba(255, 77, 77, 0.12);
    border-color: rgba(255, 77, 77, 0.35);
    color: #ff4d4d;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(255, 77, 77, 0.1);
}

/* RESPONSIVENESS */
@media (max-width: 1200px) {
    .rl-trade-container {
        width: 98vw;
        height: 96vh;
    }
    .rl-trade-layout {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr auto;
    }
    .rl-trade-slots-panel {
        max-height: 380px;
    }
}

.rl-modal-close-btn {
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.rl-modal-close-btn:hover {
    background: rgba(255, 77, 77, 0.15) !important;
    border-color: rgba(255, 77, 77, 0.4) !important;
    color: #ff4d4d !important;
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 0 12px rgba(255, 77, 77, 0.25);
}

/* ==========================================================================
   RARITY FRAME COMPATIBILITY — RL TRADE MODAL CONTAINERS
   Makes .rl-inv-card-media and .rl-slot-card-active behave like
   .album-sticker-frame / .inv-card so that rarity frames are visible.
   ========================================================================== */

/* 1. Both containers need position:relative so .tdj-card (position:absolute;
      inset:0) fills them correctly */
.rl-inv-card-media,
.rl-slot-card-active {
    position: relative;
    overflow: visible;
    background: transparent;
}

/* 2. Ensure the .tdj-card fills RL containers just like sticker frames */
.rl-inv-card-media .tdj-card,
.rl-slot-card-active .tdj-card {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    background: transparent !important;
}

/* 3. Prime rarity — purple border glow */
.rl-inv-card-media:has(.tdj-card.rarity-prime),
.rl-slot-card-active:has(.tdj-card.rarity-prime) {
    box-shadow: 0 0 0 2px #a855f7, 0 4px 18px rgba(168, 85, 247, 0.9) !important;
    border-radius: 14px;
}

/* 4. Legend rarity — gold aura animation */
.rl-inv-card-media:has(.tdj-card.rarity-legend),
.rl-slot-card-active:has(.tdj-card.rarity-legend) {
    animation: legendMysticAura 3s ease-in-out infinite alternate !important;
    border-radius: 14px;
}

/* 5. Alien rarity — neon green border */
.rl-inv-card-media:has(.tdj-card.rarity-alien),
.rl-slot-card-active:has(.tdj-card.rarity-alien) {
    box-shadow: 0 0 0 2px #39ff14, 0 4px 18px rgba(57, 255, 20, 0.8) !important;
    border-radius: 14px;
}

/* 6. Retro-champion — golden border */
.rl-inv-card-media:has(.tdj-card.rarity-retro-champion),
.rl-slot-card-active:has(.tdj-card.rarity-retro-champion) {
    box-shadow: 0 0 0 2px #ffd700, 0 4px 18px rgba(255, 215, 0, 0.7) !important;
    border-radius: 14px;
}

/* 7. Inner golden glow for legend & retro-champion */
.rl-inv-card-media .tdj-card.rarity-legend,
.rl-inv-card-media .tdj-card.rarity-retro-champion,
.rl-slot-card-active .tdj-card.rarity-legend,
.rl-slot-card-active .tdj-card.rarity-retro-champion {
    box-shadow: inset 0 0 50px rgba(255, 215, 0, 0.4), inset 0 0 10px rgba(255, 255, 255, 0.6) !important;
}

/* 8. Inner alien glow */
.rl-inv-card-media .tdj-card.rarity-alien,
.rl-slot-card-active .tdj-card.rarity-alien {
    box-shadow: inset 0 0 50px rgba(57, 255, 20, 0.4), inset 0 0 10px rgba(255, 255, 255, 0.6) !important;
}

/* 9. Raro cards — full-bleed player photo */
.rl-inv-card-media .tdj-card.rarity-raro .tdj-card-player-container,
.rl-slot-card-active .tdj-card.rarity-raro .tdj-card-player-container {
    top: 0 !important; left: 0 !important;
    right: 0 !important; bottom: 0 !important;
    border-radius: inherit !important;
}

/* ==========================================================================
   RL TRADE OPEN CONFIRMATION DIALOG
   ========================================================================== */

#rl-confirm-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: rlConfirmFadeIn 0.2s ease;
}

@keyframes rlConfirmFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.rl-confirm-box {
    background: linear-gradient(160deg, #0d1e24 0%, #071218 100%);
    border: 1px solid rgba(43, 209, 216, 0.25);
    border-radius: 22px;
    padding: 36px 40px 28px;
    max-width: 480px;
    width: 92%;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(43, 209, 216, 0.08);
    animation: rlConfirmSlideUp 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.15);
}

@keyframes rlConfirmSlideUp {
    from { transform: translateY(24px) scale(0.96); opacity: 0; }
    to   { transform: translateY(0) scale(1);       opacity: 1; }
}

.rl-confirm-icon {
    font-size: 2.6rem;
    margin-bottom: 12px;
    line-height: 1;
}

.rl-confirm-title {
    margin: 0 0 10px;
    font-size: 1.15rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.rl-confirm-msg {
    margin: 0 0 24px;
    font-size: 0.9rem;
    color: #8faeb4;
    line-height: 1.5;
}

.rl-confirm-msg strong {
    color: #2bd1d8;
    font-weight: 800;
}

.rl-confirm-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.rl-confirm-btn {
    flex: 1;
    min-height: 44px;
    border-radius: 12px;
    border: 0;
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    letter-spacing: 0.02em;
}

.rl-confirm-yes {
    background: linear-gradient(135deg, #09b8bd 0%, #178184 100%);
    color: #ffffff;
    box-shadow: 0 4px 16px rgba(9, 184, 189, 0.4);
}

.rl-confirm-yes:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(9, 184, 189, 0.55);
    filter: brightness(1.1);
}

.rl-confirm-no {
    background: rgba(255, 255, 255, 0.06);
    color: #8faeb4;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.rl-confirm-no:hover {
    background: rgba(255, 77, 77, 0.1);
    border-color: rgba(255, 77, 77, 0.35);
    color: #ff6b6b;
}

/* Mobile/tablet trade center: keep inventory visible before the offer slots. */
@media (max-width: 1200px) {
    .rl-trade-overlay {
        align-items: flex-start;
        padding: 10px;
        overflow: hidden;
    }

    .rl-trade-container {
        width: 100%;
        height: calc(100dvh - 20px);
        max-height: none;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .rl-trade-layout {
        display: flex;
        flex-direction: column;
        overflow: visible;
    }

    .rl-trade-inventory-panel {
        overflow: visible;
        border-right: 0;
        border-bottom: 1px solid rgba(43, 209, 216, 0.08);
        flex: 0 0 auto;
    }

    .rl-inventory-scroll {
        flex: 0 0 auto;
        min-height: 360px;
        max-height: 52dvh;
        overflow-y: auto;
        padding: 18px;
    }

    .rl-trade-slots-panel {
        max-height: none;
        overflow: visible;
        flex: 0 0 auto;
    }
}

@media (max-width: 640px) {
    .rl-trade-container {
        border-radius: 18px;
    }

    .rl-trade-header {
        align-items: flex-start;
        gap: 14px;
        padding: 18px 22px;
    }

    .rl-trade-main-title {
        font-size: 1.45rem;
        line-height: 1.25;
    }

    .rl-trade-user-info {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
        font-size: 0.82rem;
    }

    .rl-inv-tab {
        min-width: 0;
        padding: 14px 10px;
        font-size: 0.86rem;
        line-height: 1.15;
        text-align: center;
    }

    .rl-inventory-filter-bar {
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
        padding: 14px 22px;
    }

    .rl-search-input-wrapper input {
        min-width: 0;
    }

    .rl-inventory-grid {
        grid-template-columns: repeat(2, minmax(112px, 1fr));
        gap: 16px 12px;
        justify-content: stretch;
    }

    .rl-inv-card {
        width: min(100%, 136px);
        margin: 0 auto;
    }

    .rl-trade-slots-panel {
        padding: 18px 22px 22px;
    }

    .rl-slots-section {
        padding: 16px;
    }

    .rl-slots-container.col-2 {
        gap: 12px;
    }

    .rl-footer-buttons {
        flex-direction: column;
    }
}

@media (max-width: 380px) {
    .rl-inventory-scroll {
        padding: 14px;
    }

    .rl-inventory-grid {
        grid-template-columns: repeat(2, minmax(96px, 1fr));
        gap: 14px 10px;
    }

    .rl-inv-tab {
        font-size: 0.78rem;
    }
}

/* Custom Stats Banner & Grid Info */
.album-trades-stats-banner {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    margin-bottom: 20px;
    background: #0d161a;
    border: 1px solid rgba(43, 209, 216, 0.05);
    padding: 15px 0;
    border-radius: 15px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.album-trades-stat-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 0 15px;
}

.album-trades-stat-item:not(:last-child) {
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.album-trades-stat-icon-wrapper {
    font-size: 1.8rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.album-trades-stat-icon-wrapper.icon-today,
.album-trades-stat-icon-wrapper.icon-total {
    background: rgba(43, 209, 216, 0.1);
    border: 1px solid rgba(43, 209, 216, 0.25);
}

.album-trades-stat-icon-wrapper.icon-top-trader {
    background: rgba(255, 210, 122, 0.1);
    border: 1px solid rgba(255, 210, 122, 0.25);
}

.album-trades-stat-icon-wrapper.icon-top-card {
    background: rgba(255, 77, 77, 0.1);
    border: 1px solid rgba(255, 77, 77, 0.25);
}

.album-trades-stat-label {
    font-size: 0.72rem;
    color: #8faeb4;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.album-trades-stat-value {
    font-size: 1.2rem;
    font-weight: 800;
    color: #fff;
    margin-top: 2px;
}

.album-trades-stat-value.val-gold {
    color: #ffd27a;
    font-size: 1.1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
}

.album-trades-stat-value.val-cyan {
    color: #2bd1d8;
    font-size: 1.1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
}

.album-trades-grid-info {
    text-align: center;
    color: #8faeb4;
    font-size: 0.88rem;
    font-weight: 700;
    margin-top: 20px;
    margin-bottom: 10px;
}

/* Support for Horizontal Moment Cards in Trade System */
.album-trade-card-media:has(.tdj-card.is-horizontal) {
    aspect-ratio: 25/18 !important;
}
.album-trade-request-card-media:has(.tdj-card.is-horizontal) {
    aspect-ratio: 25/18 !important;
    height: auto !important;
}
.rl-trade-slot:has(.tdj-card.is-horizontal) {
    aspect-ratio: 25/18 !important;
}
.rl-inv-card-media:has(.tdj-card.is-horizontal) {
    aspect-ratio: 25/18 !important;
}

/* Hover effect on trade cards for horizontal names */
.album-trade-card:hover .tdj-card.is-horizontal .tdj-card-name,
.album-trade-request-card:hover .tdj-card.is-horizontal .tdj-card-name,
.rl-inv-card:hover .tdj-card.is-horizontal .tdj-card-name,
.rl-trade-slot:hover .tdj-card.is-horizontal .tdj-card-name {
    transform: translateY(0) !important;
    opacity: 1 !important;
}
