/* Nexus V3 Indice Dashboard Layout */

.nexus-indice-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #1a1a1a;
}

.nexus-indice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #eee;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.nexus-indice-header__brand {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nexus-indice-header__badge {
    background: linear-gradient(135deg, #D93025 0%, #1A73E8 100%);
    color: #fff;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.nexus-indice-header h1 {
    margin: 0;
    font-size: 28px;
    font-weight: 400;
}

.nexus-indice-header h1 strong {
    font-weight: 800;
}

.nexus-btn-login {
    background: #4285F4;
    color: #fff;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.2s;
    display: inline-block;
}

.nexus-btn-login:hover {
    background: #3367D6;
    color: #fff;
}

.nexus-btn-login--large {
    padding: 16px 32px;
    font-size: 18px;
    border-radius: 8px;
}

.nexus-status-pill {
    background: #f1f3f4;
    color: #3c4043;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}
.nexus-status-pill--logged { background: #e8f0fe; color: #1a73e8; }
.nexus-status-pill--pro { background: #fce8e6; color: #d93025; }
.nexus-status-pill--api { background: #e6f4ea; color: #1e8e3e; }

.nexus-indice-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 40px;
    align-items: start;
}

.nexus-indice-nav {
    display: flex;
    flex-direction: column;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 16px;
    position: sticky;
    top: 40px;
}

.nexus-indice-nav a {
    padding: 12px 16px;
    color: #444;
    text-decoration: none;
    font-weight: 600;
    border-radius: 8px;
    margin-bottom: 4px;
    transition: all 0.2s;
}

.nexus-indice-nav a:hover {
    background: #e8eaed;
}

.nexus-indice-nav a.active {
    background: #111;
    color: #fff;
}

.nexus-indice-nav a.locked {
    opacity: 0.5;
    cursor: not-allowed;
    background: #fff;
    border: 1px dashed #ccc;
}

/* ── Sections ────────────────────────────────────────────── */

.nexus-idx-section {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-left: 4px solid #e0e0e0;
    border-radius: 12px;
    padding: 28px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

/* Watermark for anti-screenshot */
.nexus-idx-section::after {
    content: 'piranot.com.br';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg);
    font-size: 48px;
    font-weight: 800;
    color: rgba(0,0,0,0.03);
    pointer-events: none;
    white-space: nowrap;
}

.nexus-idx-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 8px;
}

.nexus-idx-subtitle {
    color: #666;
    font-size: 14px;
    margin: 0 0 20px;
}

/* ── KPI Cards ───────────────────────────────────────────── */

.nexus-idx-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin: 24px 0;
}

.nexus-idx-kpi {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 24px 20px;
    text-align: center;
}

.nexus-idx-kpi__value {
    display: block;
    font-size: 36px;
    font-weight: 800;
    color: #1a73e8;
    line-height: 1.1;
}

.nexus-idx-kpi__label {
    display: block;
    font-size: 13px;
    color: #666;
    margin-top: 6px;
    font-weight: 600;
}

/* ── Charts ──────────────────────────────────────────────── */

.nexus-idx-chart {
    margin-top: 16px;
}

/* ── Gated (blurred for anon) ────────────────────────────── */

.nexus-idx-gated {
    position: relative;
    margin-top: 16px;
}

.nexus-idx-gated__blur {
    filter: blur(8px);
    opacity: 0.5;
    pointer-events: none;
}

.nexus-idx-gated__placeholder {
    height: 200px;
    background: linear-gradient(135deg, #e8eaed 25%, #f1f3f4 50%, #e8eaed 75%);
    border-radius: 8px;
}

.nexus-idx-gated__cta {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    background: rgba(255,255,255,0.95);
    padding: 24px 32px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.nexus-idx-gated__cta p {
    margin: 0 0 16px;
    font-weight: 600;
    color: #333;
}

/* ── Insights Cards ──────────────────────────────────────── */

.nexus-idx-insights {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.nexus-idx-insight-card {
    background: #f8f9fa;
    border-left: 4px solid #1a73e8;
    border-radius: 0 8px 8px 0;
    padding: 20px;
}

.nexus-idx-insight-card__type {
    display: inline-block;
    background: #e8f0fe;
    color: #1a73e8;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 12px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.nexus-idx-insight-card p {
    margin: 8px 0;
    line-height: 1.6;
}

.nexus-idx-insight-card small {
    color: #888;
    font-size: 12px;
}

/* ── Login Wall (bottom CTA) ─────────────────────────────── */

.nexus-idx-login-wall {
    margin-top: 32px;
}

.nexus-idx-login-wall__inner {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: #fff;
    border-radius: 16px;
    padding: 48px 40px;
    text-align: center;
}

.nexus-idx-login-wall__inner h3 {
    font-size: 24px;
    margin: 0 0 12px;
}

.nexus-idx-login-wall__inner p {
    font-size: 16px;
    opacity: 0.85;
    margin: 0 0 24px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

/* ── Skeleton Loader ─────────────────────────────────────── */

.nexus-loading-skeleton {
    animation: nexusPulse 2s infinite ease-in-out;
    background: #eee;
    border-radius: 12px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-weight: 600;
}

@keyframes nexusPulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 768px) {
    .nexus-indice-grid {
        grid-template-columns: 1fr;
    }
    .nexus-indice-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .nexus-indice-nav {
        position: static;
        flex-direction: row;
        overflow-x: auto;
        gap: 4px;
    }
    .nexus-indice-nav a {
        white-space: nowrap;
        font-size: 13px;
        padding: 8px 12px;
    }
    .nexus-idx-kpis {
        grid-template-columns: 1fr;
    }
    .nexus-idx-login-wall__inner {
        padding: 32px 20px;
    }
}

/* ── Topic Pills ─────────────────────────────────────────── */

.nexus-idx-topic-pills {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.nexus-idx-pill {
    display: inline-block;
    border: 2px solid currentColor;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    background: transparent;
}