:root {
    --rr-bg-1: #f7fbff;
    --rr-bg-2: #fff8f4;
    --rr-bg-3: #f8f4ff;
    --rr-card: #ffffff;
    --rr-text: #30415f;
    --rr-muted: #7282a3;
    --rr-primary: #3bb273;
    --rr-primary-2: #61a8ff;
    --rr-border: #e8eef9;
    --rr-shadow: 0 14px 34px rgba(70, 99, 146, 0.12);
}

body.recent-ranking-page {
    background:
        radial-gradient(circle at 8% 10%, rgba(164, 228, 198, 0.32) 0 6%, transparent 7%),
        radial-gradient(circle at 92% 14%, rgba(154, 198, 255, 0.28) 0 7%, transparent 8%),
        linear-gradient(135deg, var(--rr-bg-1), var(--rr-bg-2) 50%, var(--rr-bg-3));
    color: var(--rr-text);
}

.recent-shell {
    max-width: 1220px;
    margin: 0 auto;
    padding: 16px 14px 28px;
}

.recent-hero {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    padding: 28px 24px;
    background: linear-gradient(135deg, rgba(255,255,255,.95), rgba(245,255,250,.95), rgba(244,249,255,.94));
    border: 1px solid rgba(255,255,255,.9);
    box-shadow: var(--rr-shadow);
}

.recent-hero::before,
.recent-hero::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    background: linear-gradient(135deg, #d7f7e5, #d7e6ff);
    opacity: .55;
}

.recent-hero::before {
    width: 190px;
    height: 190px;
    right: -44px;
    top: -48px;
}

.recent-hero::after {
    width: 120px;
    height: 120px;
    left: -20px;
    bottom: -24px;
}

.recent-hero > * {
    position: relative;
    z-index: 1;
}

.recent-title {
    margin: 0 0 10px;
    font-size: 32px;
    font-weight: 900;
}

.recent-subtitle {
    margin: 0;
    color: var(--rr-muted);
    line-height: 1.7;
}

.recent-chips,
.recent-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.recent-chip,
.recent-stat {
    border-radius: 999px;
    background: rgba(255,255,255,.88);
    border: 1px solid #d9eede;
    padding: 8px 13px;
    font-size: 13px;
}

.recent-stat strong {
    color: #248557;
}

.recent-toolbar {
    margin-top: 18px;
    display: grid;
    grid-template-columns: 1.2fr .8fr .8fr auto;
    gap: 10px;
    padding: 12px;
    background: rgba(255,255,255,.84);
    border-radius: 18px;
    border: 1px solid var(--rr-border);
    box-shadow: 0 10px 24px rgba(81, 102, 149, 0.08);
}

.recent-toolbar input,
.recent-toolbar select,
.recent-toolbar button {
    border-radius: 12px;
    border: 1px solid #e5eaf6;
    padding: 10px 12px;
    background: #fff;
    color: #445270;
}

.recent-toolbar button {
    background: linear-gradient(90deg, var(--rr-primary), var(--rr-primary-2));
    color: #fff;
    border: none;
    font-weight: 700;
}

.recent-section-title {
    margin: 22px 0 8px;
    font-size: 24px;
    font-weight: 900;
}

.recent-status,
.recent-empty {
    margin-top: 16px;
    padding: 18px;
    border-radius: 16px;
    background: rgba(255,255,255,.8);
    border: 1px solid var(--rr-border);
    color: var(--rr-muted);
}

.recent-empty {
    display: none;
    text-align: center;
}

.recent-grid {
    margin-top: 16px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.recent-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    background: var(--rr-card);
    border-radius: 22px;
    border: 1px solid var(--rr-border);
    box-shadow: var(--rr-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}

.recent-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(63, 90, 140, 0.16);
}

.recent-thumb {
    height: 190px;
    position: relative;
    overflow: hidden;
}

.recent-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,.02), rgba(0,0,0,.28));
    pointer-events: none;
}

.recent-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.recent-card-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px;
    min-height: 250px;
}

.recent-topline {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
    color: var(--rr-muted);
    font-size: 12px;
}

.recent-badge {
    border-radius: 999px;
    padding: 4px 10px;
    background: linear-gradient(90deg, #d7f6e6, #d8ebff);
    color: #45606f;
    font-weight: 700;
}

.recent-card-title {
    margin: 0;
    font-size: 18px;
    line-height: 1.45;
    font-weight: 800;
    color: #2d3b59;
}

.recent-card-desc {
    margin: 0;
    min-height: 46px;
    color: #647391;
    line-height: 1.65;
    font-size: 14px;
}

.recent-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.recent-metric {
    background: #f7f9fe;
    border-radius: 14px;
    padding: 10px;
}

.recent-metric strong {
    display: block;
    font-size: 15px;
    color: #253556;
}

.recent-metric span {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: var(--rr-muted);
}

.recent-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.recent-tag {
    border-radius: 999px;
    padding: 5px 10px;
    background: #eefbf2;
    color: #26835a;
    font-size: 12px;
    border: 1px solid #ccefd9;
}

.recent-card-foot {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--rr-muted);
    font-size: 13px;
}

.recent-read {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 8px 12px;
    background: linear-gradient(90deg, var(--rr-primary), var(--rr-primary-2));
    color: #fff;
    font-weight: 700;
}

@media (max-width: 980px) {
    .recent-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .recent-toolbar {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 700px) {
    .recent-title {
        font-size: 25px;
    }

    .recent-grid,
    .recent-toolbar,
    .recent-metrics {
        grid-template-columns: 1fr;
    }

    .recent-card-body {
        min-height: unset;
    }
}
