.ccp-widget {
    display: flex;
    align-items: center;
    gap: 0;
    /* background: linear-gradient(135deg, #1e1e27 0%, #222230 55%, #1e1e27 100%); */
    /* border: 1px solid rgba(255,255,255,.06); */
    border-radius: 14px;
    padding: 16px;
    position: relative;
    overflow: hidden;
}
.ccp-widget::before {
    /* content: ''; */
    /* position: absolute; */
    /* inset: 0; */
    /* background: radial-gradient(ellipse at 15% 50%, rgba(40,180,80,.06) 0%, transparent 60%); */
    pointer-events: none;
}

.ccp-rank-col {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 88px;
    padding-right: 14px;
    border-right: 1px solid rgba(255,255,255,.06);
    margin-right: 16px;
}
.ccp-rank-img {
    width: 68px;
    height: 68px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(40,200,80,.35));
}
.ccp-rank-name {
    font-size: 9px;
    font-weight: 700;
    color: rgba(255,255,255,.4);
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .6px;
    line-height: 1.3;
}

.ccp-stats-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ccp-top-row { display: flex; align-items: stretch; }
.ccp-top-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 2px 0;
}
.ccp-top-val {
    font-size: 20px;
    font-weight: 900;
    color: #fff;
    line-height: 1;
    letter-spacing: -.5px;
}
.ccp-top-lbl {
    font-size: 10px;
    color: rgba(255,255,255,.35);
    white-space: nowrap;
}
.ccp-top-sep {
    width: 1px;
    align-self: stretch;
    background: rgba(255,255,255,.06);
    margin: 0 4px;
    flex-shrink: 0;
}

.ccp-showcase-row {
    display: flex;
    align-items: center;
    gap: 7px;
}
.ccp-showcase-slot {
    width: 56px;
    height: 57px;
    border-radius: 10px;
    background: rgba(255,255,255,.04);
    border: 1px dashed rgba(255,255,255,.1);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: border-color .2s, background .2s, transform .15s;
    flex-shrink: 0;
    cursor: default;
}
.ccp-showcase-slot--own { cursor: pointer; }
.ccp-showcase-slot--own:hover {
    border-color: rgba(40,200,80,.5);
    background: rgba(40,200,80,.07);
    transform: translateY(-2px);
}
.ccp-showcase-slot--filled {
    border-style: solid;
    border-color: rgba(40,200,80,.2);
    background: rgba(40,200,80,.05);
}
.ccp-showcase-slot--filled:hover {
    border-color: rgba(40,200,80,.5);
}
.ccp-showcase-img {
    width: 46px;
    height: 46px;
    object-fit: contain;
    border-radius: 6px;
}
.ccp-showcase-empty-icon {
    font-size: 18px;
    color: rgba(255,255,255,.18);
}
.ccp-showcase-empty-icon--guest { color: rgba(255,255,255,.08); }
.ccp-showcase-hint {
    font-size: 10px;
    color: rgba(255,255,255,.18);
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: 2px;
    white-space: nowrap;
}

.ccp-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.65);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.ccp-modal {
    background: linear-gradient(1deg, #25252e 30%, #292932 100%);
    border: 1px solid rgba(255,255,255,.07);
    border-radius: 20px;
    width: 520px;
    max-width: 96vw;
    max-height: 82vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 64px rgba(0,0,0,.6);
    overflow: hidden;
    animation: ccpModalIn .18s ease;
}
@keyframes ccpModalIn {
    from { opacity: 0; transform: scale(.96) translateY(8px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}
.ccp-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 17px 20px 17px 20px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.ccp-modal-head-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
}
.ccp-modal-head-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: rgba(40,180,80,.15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4ade80;
    font-size: 17px;
    flex-shrink: 0;
}
.ccp-modal-close {
    background: linear-gradient(228deg, #ff4b4b12 10%, #ff4b4b3d 100%);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    color: #ff7e7ea1;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity .2s;
    flex-shrink: 0;
}
.ccp-modal-close:hover { opacity: .7; }
.ccp-modal-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    border-bottom: 1px solid rgba(255,255,255,.05);
    background: rgba(0,0,0,.1);
}
.ccp-modal-slot-label {
    font-size: 12px;
    color: rgba(255,255,255,.35);
}
.ccp-modal-slot-label b { color: #4ade80; font-weight: 700; }
.ccp-modal-fill-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(40,180,80,.1);
    border: 1px solid rgba(40,180,80,.25);
    border-radius: 8px;
    color: #4ade80;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    cursor: pointer;
    transition: background .15s, border-color .15s;
}
.ccp-modal-fill-btn:hover { background: rgba(40,180,80,.2); border-color: rgba(40,180,80,.45); }
.ccp-modal-fill-btn i { font-size: 14px; }
.ccp-modal-list {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-content: flex-start;
}
.ccp-modal-list::-webkit-scrollbar { width: 5px; }
.ccp-modal-list::-webkit-scrollbar-track { background: transparent; }
.ccp-modal-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 4px; }
.ccp-modal-item {
    width: 68px;
    height: 68px;
    border-radius: 12px;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.07);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: transform .15s, border-color .15s, background .15s, box-shadow .15s;
}
.ccp-modal-item:hover {
    transform: translateY(-3px) scale(1.07);
    border-color: rgba(40,200,80,.6);
    background: rgba(40,200,80,.1);
    box-shadow: 0 6px 18px rgba(0,0,0,.3);
}
.ccp-modal-item img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}
.ccp-modal-item--used { opacity: .38; }
.ccp-modal-item--used:hover { opacity: .6; }
.ccp-modal-item-used {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 18px;
    height: 18px;
    background: #4ade80;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #1a1a22;
    border: 2px solid #292932;
}
.ccp-modal-loading, .ccp-modal-empty {
    width: 100%;
    padding: 40px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,.25);
    font-size: 13px;
}
.ccp-modal-loading i, .ccp-modal-empty i { font-size: 36px; }
body.ccp-modal-open { overflow: hidden; }

.ccp-tip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: #1a1a22;
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 11px;
    color: rgba(255,255,255,.85);
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity .15s;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,.4);
}
.ccp-tip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: rgba(255,255,255,.1);
}
.ccp-showcase-slot:hover .ccp-tip,
.ccp-modal-item:hover .ccp-tip { opacity: 1; }

@media (max-width: 480px) {
    .ccp-widget { padding: 12px; }
    .ccp-rank-col { width: 70px; padding-right: 10px; margin-right: 10px; }
    .ccp-rank-img { width: 56px; height: 56px; }
    .ccp-top-val { font-size: 17px; }
    .ccp-showcase-slot { width: 42px; height: 42px; }
    .ccp-showcase-img { width: 32px; height: 32px; }
}
