/* ============================================================
   growth_leaderboard.css
   Styles khusus untuk halaman Growth Leaderboard
   ============================================================ */

/* ── Hero Banner ─────────────────────────────────────────── */
.gl-hero {
    background: linear-gradient(135deg, #064e3b 0%, #065f46 40%, #047857 100%);
    color: #fff;
    padding: 52px 0 44px;
    position: relative;
    overflow: hidden;
}

.gl-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 10% 20%, rgba(52,211,153,0.18) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(16,185,129,0.12) 0%, transparent 50%);
    pointer-events: none;
}

.gl-hero-inner {
    position: relative;
    z-index: 1;
}

.gl-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.92);
    margin-bottom: 14px;
}

.gl-hero-badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6ee7b7;
    animation: pulseDot 1.8s ease-in-out infinite;
}

@keyframes pulseDot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.55; transform: scale(0.75); }
}

.gl-hero-title {
    font-size: clamp(1.65rem, 1.2rem + 2vw, 2.6rem);
    font-weight: 800;
    line-height: 1.12;
    margin-bottom: 10px;
}

.gl-hero-title span {
    color: #6ee7b7;
}

.gl-hero-subtitle {
    font-size: 0.96rem;
    color: rgba(255,255,255,0.8);
    max-width: 620px;
    line-height: 1.6;
}

.gl-hero-formula {
    margin-top: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.gl-formula-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 999px;
    padding: 7px 14px;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.92);
}

.gl-formula-chip-icon {
    font-size: 1rem;
    line-height: 1;
}

/* ── Period Tabs ──────────────────────────────────────────── */
.gl-tabs-wrapper {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 6px;
    width: fit-content;
}

.gl-tab {
    padding: 9px 22px;
    border-radius: 8px;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    color: #6c757d;
    cursor: pointer;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
}

.gl-tab.active {
    background: linear-gradient(135deg, #047857, #059669);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(4,120,87,0.3);
}

.gl-tab:not(.active):hover {
    background: #f0fdf4;
    color: #047857;
}

/* ── Period Info Bar ──────────────────────────────────────── */
.gl-period-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    margin-bottom: 18px;
    font-size: 0.88rem;
    color: #6c757d;
}

.gl-period-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.gl-period-label {
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9ca3af;
    font-weight: 600;
}

.gl-period-value {
    font-weight: 600;
    color: #111827;
}

.gl-period-sep {
    color: #d1d5db;
}

/* ── Search ───────────────────────────────────────────────── */
.gl-search-wrapper {
    margin-bottom: 16px;
    position: relative;
}

.gl-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    pointer-events: none;
    font-size: 1rem;
}

.gl-search-input {
    width: 100%;
    padding: 12px 16px 12px 40px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.gl-search-input:focus {
    outline: none;
    border-color: #059669;
    box-shadow: 0 0 0 3px rgba(5,150,105,0.12);
}

/* ── Summary Stats Bar ────────────────────────────────────── */
.gl-summary-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.gl-summary-card {
    flex: 1;
    min-width: 130px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.gl-summary-value {
    font-size: 1.4rem;
    font-weight: 800;
    color: #047857;
    line-height: 1;
}

.gl-summary-label {
    font-size: 0.78rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
    margin-top: 4px;
}

/* ── Card List ────────────────────────────────────────────── */
.gl-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* ── Individual Growth Card ───────────────────────────────── */
.gl-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 16px 18px;
    transition: box-shadow 0.18s, transform 0.18s;
    cursor: default;
    position: relative;
    overflow: hidden;
}

.gl-card:hover {
    box-shadow: 0 8px 24px rgba(4,120,87,0.1);
    transform: translateY(-1px);
}

.gl-card--top3 {
    border-left: 4px solid transparent;
}

.gl-card--rank1 { border-left-color: #f59e0b; background: linear-gradient(to right, #fffbeb 0%, #fff 60%); }
.gl-card--rank2 { border-left-color: #94a3b8; background: linear-gradient(to right, #f8fafc 0%, #fff 60%); }
.gl-card--rank3 { border-left-color: #d97706; background: linear-gradient(to right, #fffbf0 0%, #fff 60%); }

.gl-card--newcomer {
    border: 1px dashed #6ee7b7;
    background: linear-gradient(to right, #f0fdf4 0%, #fff 60%);
}

/* Card header row */
.gl-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.gl-rank-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.88rem;
    flex-shrink: 0;
    background: #f3f4f6;
    color: #374151;
}

.gl-rank-badge--1 { background: linear-gradient(135deg, #f59e0b, #d97706); color: #fff; }
.gl-rank-badge--2 { background: linear-gradient(135deg, #94a3b8, #64748b); color: #fff; }
.gl-rank-badge--3 { background: linear-gradient(135deg, #d97706, #b45309); color: #fff; }
.gl-rank-badge--new { background: #d1fae5; color: #047857; font-size: 1.1rem; }

.gl-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e7eb;
    flex-shrink: 0;
    background: #f3f4f6;
}

.gl-avatar-placeholder {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    color: #065f46;
    flex-shrink: 0;
    border: 2px solid #6ee7b7;
}

.gl-card-identity {
    flex: 1;
    min-width: 0;
}

.gl-card-name {
    font-weight: 700;
    font-size: 0.97rem;
    white-space: normal;
    word-break: break-word;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #111827;
}

.gl-card-grad {
    font-weight: 400;
    color: #6b7280;
    font-size: 0.86rem;
    margin-left: 4px;
    display: inline-block;
}

.gl-newcomer-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 3px;
    background: #d1fae5;
    color: #047857;
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 0.72rem;
    font-weight: 600;
}

/* Growth Score bubble */
.gl-score-bubble {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 72px;
    padding: 6px 10px;
    border-radius: 12px;
    text-align: center;
    flex-shrink: 0;
}

.gl-score-bubble--positive {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.gl-score-bubble--negative {
    background: #fff7f7;
    border: 1px solid #fecaca;
}

.gl-score-bubble--neutral {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.gl-score-number {
    font-size: 1.25rem;
    font-weight: 800;
    font-family: 'Montserrat', sans-serif;
    line-height: 1;
}

.gl-score-number--positive { color: #059669; }
.gl-score-number--negative { color: #dc2626; }
.gl-score-number--neutral  { color: #6b7280; }

.gl-score-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9ca3af;
    font-weight: 600;
    margin-top: 2px;
}

/* Growth breakdown bar */
.gl-breakdown {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.gl-dim {
    background: #f9fafb;
    border: 1px solid #f3f4f6;
    border-radius: 8px;
    padding: 8px 6px;
    text-align: center;
    font-size: 0.78rem;
}

.gl-dim-icon {
    font-size: 1rem;
    line-height: 1;
    margin-bottom: 2px;
}

.gl-dim-label {
    color: #9ca3af;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
    display: block;
    margin-bottom: 2px;
}

.gl-dim-value {
    font-weight: 700;
    font-size: 0.82rem;
}

.gl-dim-value--up   { color: #059669; }
.gl-dim-value--down { color: #dc2626; }
.gl-dim-value--none { color: #9ca3af; }

/* Stats comparison row */
.gl-stats-compare {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    font-size: 0.8rem;
    color: #6c757d;
}

.gl-stat-item {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.gl-stat-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #9ca3af;
    font-weight: 600;
}

.gl-stat-now {
    font-weight: 700;
    color: #111827;
    font-size: 0.86rem;
}

.gl-stat-prev {
    font-size: 0.74rem;
    color: #9ca3af;
}

/* ── Empty & Loading States ───────────────────────────────── */
.gl-empty {
    text-align: center;
    padding: 52px 20px;
    color: #9ca3af;
}

.gl-empty-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.gl-empty-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 6px;
}

/* ── Responsive Adjustments ───────────────────────────────── */
@media (max-width: 600px) {
    .gl-card {
        padding: 12px 14px;
    }

    .gl-card-header {
        gap: 10px;
        margin-bottom: 8px;
    }

    .gl-rank-badge {
        width: 30px;
        height: 30px;
        font-size: 0.82rem;
    }

    .gl-avatar, .gl-avatar-placeholder {
        width: 38px;
        height: 38px;
        font-size: 0.9rem;
    }

    .gl-score-bubble {
        min-width: 60px;
        padding: 4px 6px;
    }

    .gl-score-number {
        font-size: 1.1rem;
    }

    .gl-score-label {
        font-size: 0.62rem;
    }

    .gl-dim {
        padding: 6px 2px;
    }

    .gl-dim-icon {
        font-size: 0.85rem;
        margin-bottom: 1px;
    }

    .gl-dim-label {
        font-size: 0.6rem;
    }

    .gl-dim-value {
        font-size: 0.76rem;
    }

    .gl-stats-compare {
        gap: 4px;
        font-size: 0.76rem;
    }

    .gl-stat-now {
        font-size: 0.78rem;
    }

    .gl-stat-prev {
        font-size: 0.66rem;
    }

    .gl-summary-card {
        min-width: 100px;
    }

    .gl-hero {
        padding: 36px 0 32px;
    }
}

@media (max-width: 380px) {
    .gl-tabs-wrapper {
        width: 100%;
        justify-content: center;
    }

    .gl-tab {
        flex: 1;
        text-align: center;
    }
}

/* ── Pagination ───────────────────────────────────────────── */
.gl-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    padding: 12px 0;
    border-top: 1px solid #e5e7eb;
    font-size: 0.85rem;
    color: #6c757d;
}

.gl-pagination-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gl-page-btn {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 7px 14px;
    background: #fff;
    cursor: pointer;
    font-size: 0.84rem;
    font-family: inherit;
    color: #374151;
    transition: background 0.15s;
}

.gl-page-btn:hover:not(:disabled) {
    background: #f0fdf4;
    border-color: #6ee7b7;
    color: #047857;
}

.gl-page-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/* ── Section spacing ──────────────────────────────────────── */
.gl-section {
    padding: 40px 0 60px;
}

/* ── Classic Leaderboard CTA & Dimension switcher ──────────── */
.gl-cta-classic-card {
    background: linear-gradient(135deg, rgba(4, 120, 87, 0.05) 0%, rgba(5, 150, 105, 0.02) 100%);
    border: 1px solid #a7f3d0;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.gl-cta-classic-content {
    display: flex;
    align-items: center;
    gap: 12px;
}
.gl-cta-classic-icon {
    font-size: 1.5rem;
}
.gl-cta-classic-text {
    font-size: 0.92rem;
    color: #065f46;
    font-weight: 500;
}
.gl-cta-classic-text a {
    color: #047857;
    text-decoration: underline;
    font-weight: 600;
}
.gl-cta-classic-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #047857;
    color: #fff;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.15s;
}
.gl-cta-classic-btn:hover {
    background: #065f46;
}

.gl-dim-tabs-wrapper {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    overflow-x: auto;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
}
.gl-dim-tab {
    padding: 10px 18px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    background: #fff;
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 500;
    color: #4b5563;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.18s;
}
.gl-dim-tab.active {
    background: #047857;
    color: #fff;
    border-color: #047857;
    box-shadow: 0 4px 10px rgba(4, 120, 87, 0.2);
}
.gl-dim-tab:not(.active):hover {
    background: #f0fdf4;
    color: #047857;
    border-color: #a7f3d0;
}

@media (max-width: 600px) {
    .gl-cta-classic-card {
        flex-direction: column;
        align-items: flex-start;
    }
    .gl-cta-classic-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ── Desktop Layout Optimization ──────────────────────────── */
@media (min-width: 992px) {
    .gl-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    .gl-search-wrapper {
        max-width: 480px;
    }
}


