/* =====================================================
   INVESTIMENTO.CSS — Estilos exclusivos de investimento.html
   Projeto: Confiança FIDC
   Depende de: style.css (base, header, footer, utilitários)
   ===================================================== */

/* =====================================================
   HERO SIMULATOR — barra inferior do hero
   ===================================================== */
.hero-sim {
    position: relative;
    z-index: 4;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(22px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 5px var(--page-pad);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    height: 140px;
}

.hero-sim-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin: 15px;
    flex-wrap: wrap;
    width: 100%;
}

/* ── Toggles Único / Mensal ── */
.hero-sim-type {
    display: flex;
    gap: 2px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    padding: 3px;
    flex-shrink: 0;
}

.hsim-btn {
    background: transparent;
    border: none;
    padding: 9px 18px;
    font-family: var(--font-main);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.32);
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.22s, color 0.22s;
    white-space: nowrap;
}

.hsim-btn.active {
    background: rgba(255, 255, 255, 0.13);
    color: rgba(255, 255, 255, 0.9);
}

.hsim-btn:hover:not(.active) {
    color: rgba(255, 255, 255, 0.58);
}

/* ── Separador vertical ── */
.hsim-vsep {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

/* ── Campos de entrada ── */
.hero-sim-fields {
    display: flex;
    align-items: center;
    gap: clamp(12px, 1.8vw, 22px);
    flex: 1;
    min-width: 0;
}

.hsim-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.hsim-label {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.700);
    white-space: nowrap;
}

.hsim-input-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 8px 12px;
    transition: border-color 0.2s;
}

.hsim-input-wrap:focus-within {
    border-color: rgba(255, 255, 255, 0.28);
}

.hsim-prefix,
.hsim-suffix {
    font-size: var(--fs-xs);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.28);
    white-space: nowrap;
    flex-shrink: 0;
}

.hsim-input-wrap input {
    background: transparent;
    border: none;
    outline: none;
    font-family: var(--font-main);
    font-size: var(--fs-sm);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    width: 100%;
    min-width: 80px;
}

.hsim-input-wrap input::placeholder {
    color: rgba(255, 255, 255, 0.18);
}

/* Remove arrows on number inputs */
.hsim-input-wrap input[type=number]::-webkit-inner-spin-button,
.hsim-input-wrap input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
}
.hsim-input-wrap input[type=number] { -moz-appearance: textfield; }

/* ── Seta ── */
.hero-sim-arrow {
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
}

/* ── Resultados ── */
.hero-sim-result {
    display: flex;
    align-items: center;
    gap: 30px;
    flex-shrink: 0;
}

.hsim-out {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.hsim-out-label {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.28);
    white-space: nowrap;
}

.hsim-out-label em {
    font-style: normal;
    color: rgba(255, 255, 255, 0.42);
}

.hsim-out-val {
    font-size: clamp(13px, 1vw, 16px);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.72);
    white-space: nowrap;
    letter-spacing: -0.01em;
    transition: color 0.3s;
}

.hsim-out-val.is-tax {
    color: rgba(255, 160, 100, 0.75);
}

.hsim-out.is-highlight .hsim-out-val {
    color: rgba(255, 255, 255, 0.96);
    font-size: clamp(15px, 1.2vw, 19px);
}

.hsim-out-div {
    width: 1px;
    height: 32px;
    background: rgba(255, 255, 255, 0.09);
    flex-shrink: 0;
    align-self: center;
}

/* ── Rodapé do simulador ── */
.hero-sim-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-sim-note {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.5;
    text-align: center;
}

/* Overlay padronizado */
#investHero .page-hero-overlay {
    background: rgba(0, 0, 0, 0.8);
}

/* Corpo do hero: texto à esquerda, gráfico à direita (simulador vai no rodapé) */
.inv-hero-body {
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    align-items: flex-start;
    padding: 150px var(--page-pad) clamp(12px, 1.6vw, 24px);
}
.inv-hero-body .page-hero-content {
    flex: none;
    max-width: 550px;
    padding: 0;
    position: relative;
    z-index: 3;
}
#investHero h1 {
    font-size: 30px;
    font-weight: 800;
    line-height: 1.07;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    margin-bottom: 18px;
}
#investHero .page-hero-content p {
    font-size: var(--fs-base);
    line-height: 1.4;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.8);
    max-width: 560px;
    margin-bottom: 24px;
}

/* Painel do gráfico (direita) */
.inv-hero-chart {
    position: absolute;
    left: var(--page-pad);
    right: var(--page-pad);
    top: 20px;
    bottom: 70px;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 14px;
    pointer-events: none;
    /* Ajuste manual da altura do gráfico: aumente para descer, diminua para subir */
    transform: translateY(20%);
}
.inv-hero-chart .tc-chart-wrap { width: 100%; }
.inv-hero-chart svg {
    width: 100%;
    height: auto;
    display: block;
    overflow: visible;
}
.inv-hero-chart-caption {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 0 4px;
}
.inv-chart-title {
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
}
.inv-chart-legend { display: flex; gap: 18px; }
.inv-leg {
    position: relative;
    font-size: var(--fs-xs);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    padding-left: 18px;
}
.inv-leg::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 3px;
    border-radius: 2px;
}
.inv-leg-fundo::before { background: #ffffff; }
.inv-leg-cdi::before   { background: #1fd1c8; }

/* Simulador — barra inferior compacta */
#investHero .hero-sim {
    padding: 10px var(--page-pad);
    gap: 4px;
}
#investHero .hero-sim-title {
    margin: 0px;
}
#investHero .hsim-input-wrap {
    padding-top: 6px;
    padding-bottom: 6px;
}
#investHero .hero-sim-footer {
    margin-top: 0;
}
#investHero .hero-sim-footer {
    margin-top: 0px;
}
#investHero .hero-sim-note {
    font-size: 12px;
    line-height: 1.3;
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.6);
    max-width: none;
}

/* =====================================================
   APP DO INVESTIDOR — seção de um app
   ===================================================== */
.apps-section-single {
    padding: clamp(27px, 3.4vw, 46px) var(--page-pad);
}
.apps-section-single .app-panel {
    max-width: 1080px;
    min-height: 220px;
    margin: 0 auto;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
}
.apps-section-single .app-panel-img {
    flex: 0 0 28%;
}

/* Tema claro — inverte cores do conteúdo e botões */
.apps-section-single .app-eyebrow {
    color: rgba(0, 0, 0, 0.5);
}
.apps-section-single .app-title {
    color: #0a0a0a;
}
.apps-section-single .app-desc {
    color: rgba(0, 0, 0, 0.6);
}
.apps-section-single .btn-store {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.28);
    color: rgba(0, 0, 0, 0.85);
}
.apps-section-single .btn-store::after {
    border-color: rgba(0, 0, 0, 0.7);
}
.apps-section-single .btn-store:hover {
    background: #0a0a0a;
    border-color: transparent;
    color: #ffffff;
    box-shadow:
        0 0 0 5px rgba(0, 0, 0, 0.06),
        0 0 28px rgba(0, 0, 0, 0.15);
}
.apps-section-single .app-panel-img img {
    object-fit: contain;
    object-position: right center;
    opacity: 0;
    transform: translateX(-70px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
.apps-section-single .app-panel.visible .app-panel-img img {
    opacity: 1;
    transform: translateX(0);
}
.apps-section-single .app-panel-content {
    align-items: center;
    text-align: center;
    padding: 0 clamp(24px, 4vw, 64px);
}
.apps-section-single .app-features {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 26px;
    width: 100%;
    max-width: 640px;
    margin: 2px auto;
    text-align: left;
}
.apps-section-single .app-features li {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: var(--fs-xs);
    color: rgba(0, 0, 0, 0.6);
    line-height: 1.45;
}
.apps-section-single .app-features li svg {
    width: 16px;
    height: 16px;
    color: #0a0a0a;
    flex-shrink: 0;
    margin-top: 1px;
}
@media (max-width: 560px) {
    .apps-section-single .app-features { grid-template-columns: 1fr; }
}
.apps-section-single .app-desc {
    max-width: 560px;
}
/* Título do simulador (card inferior) */
.hero-sim-title {
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.72);
    text-align: center;
    margin-bottom: 50px;
}

.hero-sim-wa {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    border-radius: 20px;
    background: rgba(37, 211, 102, 0.08);
    border: 1px solid rgba(37, 211, 102, 0.28);
    color: rgba(37, 211, 102, 0.72);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-decoration: none;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: visible;
    transition: background 0.35s ease, border-color 0.35s ease,
                color 0.35s ease, box-shadow 0.4s ease;
    flex-shrink: 0;
}

.hero-sim-wa::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 20px;
    border: 1.5px solid rgba(37, 211, 102, 0.7);
    opacity: 0;
    transform: scale(1);
    pointer-events: none;
}

.hero-sim-wa:hover {
    background: rgba(37, 211, 102, 0.88);
    border-color: transparent;
    color: #0a0a0a;
    box-shadow:
        0 0 0 4px rgba(37, 211, 102, 0.1),
        0 0 22px rgba(37, 211, 102, 0.28);
}

.hero-sim-wa:hover::after {
    animation: btnRippleGreen 0.52s ease forwards;
}

@keyframes btnRippleGreen {
    0%   { opacity: 0.6; transform: scale(1);    }
    100% { opacity: 0;   transform: scale(1.28); }
}

/* =====================================================
   STEPS GRID — Por que investir / Como funciona
   ===================================================== */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(16px, 2vw, 32px);
    position: relative;
}

.steps-grid::before {
    content: '';
    position: absolute;
    top: 28px;
    left: calc(12.5% + 12px);
    right: calc(12.5% + 12px);
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 0;
}

.step-item {
    position: relative;
    z-index: 1;
    text-align: center;
}

.step-num {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: var(--color-black);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: var(--fs-sm);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.55);
}

.step-item h3 {
    font-size: var(--fs-sm);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.88);
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.step-item p {
    font-size: var(--fs-xs);
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.65;
    margin: 0;
}

@media (max-width: 700px) {
    .steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .steps-grid::before { display: none; }
}

/* =====================================================
   FEAT GRID — Diferenciais (cards com ícone)
   ===================================================== */
.feat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(16px, 2vw, 28px);
}
.feat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: clamp(22px, 2.2vw, 30px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}
.feat-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-4px);
}
.feat-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.85);
}
.feat-icon svg { width: 22px; height: 22px; }
.feat-card h3 {
    font-size: var(--fs-sm);
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    letter-spacing: -0.01em;
    margin: 0;
}
.feat-card p {
    font-size: var(--fs-xs);
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.65;
    margin: 0;
}
@media (max-width: 860px) {
    .feat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .feat-grid { grid-template-columns: 1fr; }
}


/* =====================================================
   TRIBUTAÇÃO — Tabela IRPF regressiva
   ===================================================== */
.irpf-section {
    padding: clamp(56px, 7vw, 96px) var(--page-pad);
    background: var(--color-white);
}

.irpf-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(40px, 6vw, 80px);
    align-items: start;
}

.irpf-text {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.irpf-table {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.irpf-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: background 0.18s;
}

.irpf-row:last-child {
    border-bottom: none;
}

.irpf-row:hover {
    background: rgba(0, 0, 0, 0.025);
}

.irpf-row-head {
    background: #0a0a0a;
    cursor: default;
}

.irpf-row-head:hover {
    background: #0a0a0a;
}

.irpf-cell {
    padding: 14px 18px;
    font-size: var(--fs-xs);
    color: rgba(0, 0, 0, 0.62);
    line-height: 1.4;
    display: flex;
    align-items: center;
}

.irpf-cell:first-child {
    flex: 1.3;
    border-right: 1px solid rgba(0, 0, 0, 0.06);
}

.irpf-cell:last-child {
    flex: 1;
    font-weight: 700;
    justify-content: flex-end;
}

.irpf-row-head .irpf-cell {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.38);
}

.irpf-row-head .irpf-cell:first-child {
    border-right-color: rgba(255, 255, 255, 0.08);
}

.irpf-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.irpf-badge-25 { background: rgba(220, 80, 60, 0.1);  color: #c84040; }
.irpf-badge-22 { background: rgba(210, 110, 40, 0.1); color: #c06020; }
.irpf-badge-20 { background: rgba(180, 140, 20, 0.1); color: #987010; }
.irpf-badge-17 { background: rgba(60, 160, 80, 0.1);  color: #2a8a44; }
.irpf-badge-15 { background: rgba(30, 140, 100, 0.1); color: #1a7a60; }

@media (max-width: 840px) {
    .irpf-wrap { grid-template-columns: 1fr; }
}

/* =====================================================
   CTA SECTION
   ===================================================== */
.cta-section {
    background: var(--color-white);
    padding: clamp(56px, 7vw, 96px) var(--page-pad);
    text-align: center;
}

.cta-section.dark {
    background: var(--color-black);
}

.cta-section h2 {
    font-size: var(--fs-xl);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.02em;
    margin-bottom: 18px;
}

.cta-section.dark h2  { color: var(--color-white); }
.cta-section:not(.dark) h2 { color: #0a0a0a; }

.cta-section p {
    font-size: var(--fs-base);
    line-height: 1.65;
    max-width: 520px;
    margin: 0 auto 36px;
}

.cta-section.dark p  { color: rgba(255, 255, 255, 0.55); }
.cta-section:not(.dark) p { color: rgba(0, 0, 0, 0.52); }

/* CTA em duas colunas — imagem à esquerda, texto à direita */
.cta-section { padding-block: clamp(34px, 4vw, 56px); }
.cta-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: clamp(32px, 5vw, 72px);
    max-width: 1080px;
    margin: 0 auto;
    text-align: left;
}
.cta-inner .cta-text { flex: 1 1 auto; }
.cta-inner .cta-text p { margin: 0 0 32px; max-width: 480px; }
.cta-media {
    flex: 0 0 auto;
    order: -1;
    width: clamp(300px, 40vw, 460px);
    aspect-ratio: 1 / 1;
    align-self: center;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.cta-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
@media (max-width: 820px) {
    .cta-inner { flex-direction: column; text-align: center; }
    .cta-inner .cta-text p { margin-left: auto; margin-right: auto; }
    .cta-media { width: 100%; min-height: 220px; }
}




/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 900px) {
    .inv-hero-body {
        flex-direction: column;
        align-items: stretch;
        gap: clamp(24px, 4vw, 36px);
        padding-top: clamp(90px, 12vh, 120px);
    }
    .inv-hero-body .page-hero-content {
        flex: none;
        max-width: 100%;
    }
    .inv-hero-chart {
        position: static;
        left: auto;
        right: auto;
        top: auto;
        bottom: auto;
    }
}

@media (max-width: 720px) {
    .hero-sim-row {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    .hero-sim-arrow { display: none; }
    .hero-sim-result { width: 100%; justify-content: space-between; }
    .hsim-input-wrap input { min-width: 60px; }
}
