/* ============================================================================================================ */
/* BUY PAGE */
/* ============================================================================================================ */
.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out, opacity 0.3s ease-out;
    opacity: 0;
}

/* ============================================================================================================ */
/* TOOLS PAGE - RESPONSIVE BREAKPOINT FOR XS (EXTRA SMALL) */
/* ============================================================================================================ */

/* XS breakpoint: 480px - for very small mobile devices */
@media (min-width: 480px) {
    .xs\:inline {
        display: inline !important;
    }

    .xs\:hidden {
        display: none !important;
    }
}

@media (max-width: 479px) {
    .xs\:inline {
        display: none !important;
    }

    .xs\:hidden {
        display: inline !important;
    }

    /* Make buttons more touch-friendly on very small screens */
    button[role="tab"] {
        min-height: 44px !important;
    }

    /* Reduce form field sizes for better mobile fit */
    input[type="number"] {
        font-size: 16px !important;
        /* Prevents zoom on iOS */
    }
}

/* ============================================================================================================ */
/* CALENDAR RESPONSIVE LAYOUT */
/* ============================================================================================================ */

/* Desktop: Mostrar resumo lateral, esconder resumo mobile */
@media (min-width: 1280px) {
    .calendar-week-summary-desktop {
        display: flex !important;
        flex-direction: column !important;
    }

    .calendar-week-summary-mobile {
        display: none !important;
    }

    /* Garantir que o resumo semanal tenha a mesma altura do calendário */
    .calendar-week-summary-desktop>div:last-child {
        flex: 1 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .calendar-week-summary-desktop>div:last-child>div {
        height: 100% !important;
        display: flex !important;
        flex-direction: column !important;
    }

    /* Fazer cada semana ocupar espaço igual */
    .calendar-week-summary-desktop>div:last-child>div>div {
        flex: 1 !important;
        min-height: 0 !important;
    }
}

/* Mobile: Esconder resumo lateral, mostrar resumo mobile */
@media (max-width: 1279px) {
    .calendar-week-summary-desktop {
        display: none !important;
    }

    .calendar-week-summary-mobile {
        display: block !important;
    }
}

/* ============================================================================================================ */
/* CALENDAR DAY CELLS - MOBILE RESPONSIVE */
/* ============================================================================================================ */

/* Desktop: Garante que as informações sejam totalmente visíveis */
@media (min-width: 641px) {
    .calendar-day-number {
        font-size: 1.125rem !important;
        font-weight: 700 !important;
        line-height: 1.2 !important;
        margin-bottom: 0.25rem !important;
    }

    .calendar-day-pnl {
        font-size: 0.875rem !important;
        font-weight: 600 !important;
        line-height: 1.3 !important;
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: clip !important;
        max-width: none !important;
    }

    .calendar-day-meta {
        font-size: 0.75rem !important;
        line-height: 1.2 !important;
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: clip !important;
        max-width: none !important;
    }

    /* Altura adequada para desktop */
    .grid.grid-cols-7.border-collapse > div {
        min-height: 120px !important;
        height: 120px !important;
    }

    /* Padding adequado para desktop */
    .grid.grid-cols-7.border-collapse > div > div {
        padding: 0.75rem !important;
        overflow: visible !important;
    }
}

/* Layout responsivo para os dias do calendário em mobile */
@media (max-width: 640px) {
    /* Remove padding do container principal em mobile */
    main .flex.flex-1.flex-col.gap-3.sm\:gap-4.p-4 {
        padding: 0.5rem !important;
    }

    /* Remove espaçamento do card do calendário */
    .rounded-lg.border.bg-card.text-card-foreground.shadow-sm.p-6 {
        padding: 0.75rem !important;
    }

    /* Ajusta header do calendário */
    .flex.items-center.justify-between.p-6.bg-gradient-to-r {
        padding: 0.75rem !important;
    }

    /* Reduz gap entre calendário e resumo semanal */
    .flex.gap-6.min-h-\[600px\] {
        gap: 0 !important;
        min-height: auto !important;
    }

    /* Altura dos dias em mobile */
    .grid.grid-cols-7.border-collapse > div {
        min-height: 85px !important;
        height: 85px !important;
    }

    /* Ajusta padding interno das células - compacto */
    .grid.grid-cols-7.border-collapse > div > div {
        padding: 0.375rem !important;
        overflow: hidden !important;
    }

    /* Layout compacto para informações do dia */
    .calendar-day-info {
        display: flex;
        flex-direction: column;
        gap: 0.125rem;
        width: 100%;
        overflow: hidden;
    }

    /* Número do dia - muito compacto */
    .calendar-day-number {
        font-size: 0.5rem !important;
        font-weight: 600 !important;
        line-height: 1 !important;
        margin-bottom: 0.0625rem;
    }

    /* Valor principal (PnL) - muito compacto */
    .calendar-day-pnl {
        font-size: 0.5rem !important;
        font-weight: 600 !important;
        line-height: 1.1 !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: clip !important;
        max-width: 100%;
    }

    /* RR e número de trades - ultra compacto */
    .calendar-day-meta {
        font-size: 0.4375rem !important;
        line-height: 1.1 !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: clip !important;
        max-width: 100%;
    }

    /* Ajusta header dos dias da semana */
    .w-full.bg-gradient-to-r.from-muted\/50.to-muted\/30.rounded-t-2xl.border-b.border-border\/30 {
        padding: 0.5rem !important;
    }

    /* Remove padding excessivo do grid do calendário */
    .bg-card\/50.rounded-b-2xl.border.border-border\/30.overflow-hidden.flex-1 {
        padding: 0 !important;
    }

    /* Empilha informações verticalmente em telas muito pequenas */
    @media (max-width: 380px) {
        .grid.grid-cols-7.border-collapse > div {
            min-height: 80px !important;
            height: 80px !important;
        }

        .grid.grid-cols-7.border-collapse > div > div {
            padding: 0.25rem !important;
        }

        .calendar-day-number {
            font-size: 0.4375rem !important;
        }

        .calendar-day-pnl {
            font-size: 0.4375rem !important;
        }

        .calendar-day-meta {
            font-size: 0.375rem !important;
        }
    }

    /* Oculta resumo do mês em mobile para dar mais espaço */
    .rounded-lg.bg-card.text-card-foreground.mb-4.sm\:mb-6 {
        margin-bottom: 0.75rem !important;
    }

    /* Reduz padding do cabeçalho da página */
    .flex.flex-col.sm\:flex-row.justify-between.items-start.sm\:items-center.gap-4.mb-2 h1 {
        font-size: 1.5rem !important;
    }
}

/* Tablets pequenos - ajuste intermediário */
@media (min-width: 641px) and (max-width: 768px) {
    .grid.grid-cols-7.border-collapse > div {
        min-height: 110px !important;
        height: 110px !important;
    }

    .calendar-day-number {
        font-size: 1rem !important;
    }

    .calendar-day-pnl {
        font-size: 0.875rem !important;
    }

    .calendar-day-meta {
        font-size: 0.8125rem !important;
    }
}

/* ============================================================================================================ */
/* BUY PAGE - FAQ */
/* ============================================================================================================ */

.faq-content {
    max-height: 500px;
    /* Ajuste conforme necessário */
    opacity: 1;
    padding-top: 0;
    padding-bottom: 1rem;
}

.faq-button svg {
    transition: transform 0.3s ease-out;
}

.faq-button svg.rotate-180 {
    transform: rotate(180deg);
}

html {
    scroll-behavior: smooth;
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out, opacity 0.3s ease-out;
    opacity: 0;
}

.faq-content.open {
    max-height: 500px;
    opacity: 1;
    padding-top: 0;
    padding-bottom: 1rem;
}

.faq-button svg {
    transition: transform 0.3s ease-out;
}

.faq-button svg.rotate-180 {
    transform: rotate(180deg);
}

/* ============================================================================================================ */
/* DASHBOARD - AI INSIGHTS CAROUSEL */
/* ============================================================================================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-slide-in {
    animation: slideIn 0.4s ease-out forwards;
}

/* Animação para os indicadores do carrossel */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.carousel-indicator-active {
    animation: pulse 2s ease-in-out infinite;
}

/* ============================================================================================================ */
/* BUY PAGE */
/* ============================================================================================================ */

/* ============================================================================================================ */
/* MODAL ANIMATIONS */
/* ============================================================================================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

@keyframes modalScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes scaleOut {
    from {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }

    to {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.2s ease-out forwards;
}

.animate-fadeOut {
    animation: fadeOut 0.2s ease-out forwards;
}

.animate-modal-scale {
    animation: modalScale 0.3s ease-out forwards;
}

.animate-scaleIn {
    animation: scaleIn 0.2s ease-out forwards;
}

.animate-scaleOut {
    animation: scaleOut 0.2s ease-out forwards;
}

/* ============================================================================================================ */
/* BUY PAGE */
/* ============================================================================================================ */

/* Reset apenas para o componente de preços */
.pricing-section * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.pricing-section {
    color: #000000; /* Preto no modo claro */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.dark .pricing-section {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-container {
    max-width: 1200px;
    width: 100%;
}

.pricing-main-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 15px;
    font-weight: 600;
    color: #000000; /* Preto no modo claro */
}

.dark .pricing-main-title {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #6b7280; /* Cinza escuro no modo claro */
    margin-bottom: 50px;
}

.dark .pricing-subtitle {
    color: #a0aec0; /* Cinza claro no modo escuro */
}

.pricing-plans-wrapper {
    display: flex;
    gap: 30px;
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

.pricing-plan-card {
    background: rgba(255, 255, 255, 0.8); /* Fundo claro no modo claro */
    border-radius: 20px;
    padding: 40px 30px;
    width: 100%;
    max-width: 380px;
    border: 2px solid rgba(0, 0, 0, 0.1); /* Borda escura no modo claro */
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    color: #000000; /* Texto preto no modo claro */
}

.dark .pricing-plan-card {
    background: rgba(255, 255, 255, 0.05); /* Fundo escuro no modo escuro */
    border: 2px solid rgba(255, 255, 255, 0.1); /* Borda clara no modo escuro */
    color: #ffffff; /* Texto branco no modo escuro */
}

.pricing-plan-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.pricing-plan-card--annual {
    border: 2px solid #22c55e;
    background: rgba(34, 197, 94, 0.1);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    color: #ffffff; /* Texto branco no badge */
}

.pricing-plan-title {
    text-align: center;
    font-size: 1.5rem;
    margin-bottom: 10px;
    font-weight: 600;
    color: #000000; /* Preto no modo claro */
}

.dark .pricing-plan-title {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-plan-discount {
    text-align: center;
    color: #22c55e;
    font-size: 0.9rem;
    margin-bottom: 20px;
    font-weight: 500;
}

.pricing-price {
    text-align: center;
    margin-bottom: 30px;
}

.pricing-price-amount {
    font-size: 2.5rem;
    font-weight: 700;
    color: #000000; /* Preto no modo claro */
}

.dark .pricing-price-amount {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-price-period {
    font-size: 1rem;
    color: #6b7280; /* Cinza escuro no modo claro */
}

.dark .pricing-price-period {
    color: #a0aec0; /* Cinza claro no modo escuro */
}

.pricing-features-list {
    list-style: none;
    margin-bottom: 30px;
    flex-grow: 1;
}

.pricing-feature-item {
    padding: 12px 0;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #000000; /* Preto no modo claro */
}

.dark .pricing-feature-item {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-feature-item::before {
    content: "✓";
    color: #22c55e;
    font-weight: bold;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.pricing-btn {
    width: 100%;
    padding: 16px 32px;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.pricing-btn--monthly {
    background: rgba(0, 0, 0, 0.1); /* Fundo escuro no modo claro */
    color: #000000; /* Texto preto no modo claro */
}

.dark .pricing-btn--monthly {
    background: rgba(255, 255, 255, 0.15); /* Fundo claro no modo escuro */
    color: #ffffff; /* Texto branco no modo escuro */
}

.pricing-btn--monthly:hover {
    background: rgba(0, 0, 0, 0.2); /* Fundo mais escuro no hover modo claro */
}

.dark .pricing-btn--monthly:hover {
    background: rgba(255, 255, 255, 0.25); /* Fundo mais claro no hover modo escuro */
}

.pricing-btn--annual {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.pricing-btn--annual:hover {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    transform: scale(1.02);
}

.pricing-footer-text {
    text-align: center;
    margin-top: 40px;
}

.pricing-footer-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #000000; /* Preto no modo claro */
}

.dark .pricing-footer-title {
    color: #ffffff; /* Branco no modo escuro */
}

.pricing-brand-name {
    color: #1989df;
    font-weight: 700;
}

.pricing-footer-description {
    color: #6b7280; /* Cinza escuro no modo claro */
    font-size: 1rem;
}

.dark .pricing-footer-description {
    color: #a0aec0; /* Cinza claro no modo escuro */
}

@media (max-width: 768px) {
    .pricing-main-title {
        font-size: 1.8rem;
    }

    .pricing-plans-wrapper {
        flex-direction: column;
        align-items: center;
    }
}

/* ============================================================================================================ */
/* IMAGE MODAL STYLES */
/* ============================================================================================================ */

.cursor-pointer {
    cursor: pointer;
}

.transition-transform {
    transition: transform 0.3s ease;
}

.hover\:scale-105:hover {
    transform: scale(1.05);
}



/* css do datatables */
/* Estilos customizados para DataTables no tema dark */
        .dark .dataTables_wrapper {
            color: hsl(var(--foreground));
        }

        .dark .dataTables_wrapper table.dataTable thead th,
        .dark .dataTables_wrapper table.dataTable thead td {
            border-bottom: 1px solid hsl(var(--border));
            color: hsl(var(--foreground));
        }

        .dark .dataTables_wrapper table.dataTable tbody tr {
            background-color: hsl(var(--card));
        }

        .dark .dataTables_wrapper table.dataTable tbody tr:hover {
            background-color: hsl(var(--accent));
        }

        .dark .dataTables_wrapper table.dataTable tbody td {
            border-bottom: 1px solid hsl(var(--border));
            color: hsl(var(--foreground));
        }

        .dark .dataTables_wrapper .dataTables_length,
        .dark .dataTables_wrapper .dataTables_filter,
        .dark .dataTables_wrapper .dataTables_info,
        .dark .dataTables_wrapper .dataTables_paginate {
            color: hsl(var(--foreground));
        }

        .dark .dataTables_wrapper .dataTables_paginate .paginate_button {
            color: hsl(var(--foreground)) !important;
        }

        .dark .dataTables_wrapper .dataTables_paginate .paginate_button:hover {
            background: hsl(var(--accent));
            color: hsl(var(--foreground)) !important;
        }

        .dark .dataTables_wrapper .dataTables_paginate .paginate_button.current {
            background: hsl(var(--primary));
            color: hsl(var(--primary-foreground)) !important;
        }

        .dark .dataTables_wrapper input[type="search"] {
            background-color: hsl(var(--background));
            border: 1px solid hsl(var(--border));
            color: hsl(var(--foreground));
            padding: 0.5rem;
            border-radius: 0.375rem;
        }

        .dark .dataTables_wrapper select {
            background-color: hsl(var(--background));
            border: 1px solid hsl(var(--border));
            color: hsl(var(--foreground));
            padding: 0.25rem 0.5rem;
            border-radius: 0.375rem;
        }

        /* Estilos para inputs editáveis na tabela */
        .subscription-status-select,
        .subscription-plan-select,
        .subscription-date-input,
        .subscription-price-input {
            font-size: 0.75rem;
            min-width: 120px;
        }

        .subscription-price-input {
            min-width: 90px;
        }

        .subscription-status-select:focus,
        .subscription-plan-select:focus,
        .subscription-date-input:focus,
        .subscription-price-input:focus {
            outline: 2px solid hsl(var(--ring));
            outline-offset: 2px;
        }

        .save-subscription-btn {
            transition: all 0.2s;
        }

        .save-subscription-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
        }

        .save-subscription-btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }