/* ============================================================
   AUCTIUM – THEME.CSS
   ============================================================ */

/* VARIABLES -------------------------------------------------- */

:root {
    --bg-light: #f3f4f6;
    --bg-card-light: #ffffff;
    --text-light: #0f172a;

    --primary: #2563eb;
    --primary-dark: #1e40af;
    --primary-darker: #1e3a8a;

    --border-light: rgba(148,163,184,0.35);
}

/* BASE ------------------------------------------------------- */

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif;
    background-color: var(--bg-light) !important;
    background-image: none !important;
    color: var(--text-light);
}

/* HEADER FLOTANTE ------------------------------------------- */

.header {
    background: rgba(26, 22, 37, 0.7) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
    margin: 1.9375rem 1rem 1rem 1rem;
    width: calc(100% - 2rem);
    max-width: 100%;
}

@media (min-width: 768px) {
    .header {
        margin-left: auto;
        margin-right: auto;
        width: calc(100% - 3rem);
        max-width: calc(100% - 3rem);
    }
}

@media (min-width: 1280px) {
    .header {
        max-width: 1232px;
    }
}

@media (min-width: 1536px) {
    .header {
        max-width: 1280px;
    }
}

.header > div {
    width: 100%;
}

/* LOGO ------------------------------------------------------- */

.logo-img {
    height: 32px;
    width: auto;
    object-fit: contain;
    filter: brightness(1.1);
}

@media (min-width: 768px) {
    .logo-img {
        height: 36px;
    }
}

/* NAV LINKS -------------------------------------------------- */

.nav-link {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.2s ease;
    letter-spacing: 0.01em;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.nav-link-mobile {
    display: block;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-link-mobile:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

/* HEADER BUTTONS -------------------------------------------- */

.header-btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 18px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: transparent;
}

.header-btn-ghost:hover {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.35);
    color: #ffffff;
}

.header-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 20px;
    border-radius: 8px;
    background: linear-gradient(180deg, #ff7b45 0%, #ff6b35 100%);
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    box-shadow: none;
}

.header-btn-primary:hover {
    background: linear-gradient(180deg, #ff8c52 0%, #ff7b45 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    color: #ffffff;
}

.header-btn-primary:active {
    transform: translateY(0);
}

/* LINK TEXT GLOBAL ------------------------------------------ */

a {
    color: var(--primary);
}
a:hover {
    color: var(--primary-dark);
}

/* BOTONES AZULES -------------------------------------------- */

.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary);
    color: #ffffff;

    padding: 0.55rem 1.1rem;
    border-radius: 0.6rem;
    font-weight: 600;
    font-size: 0.85rem;

    box-shadow: none !important;
    border: none;
    cursor: pointer;

    transition: background-color 0.15s ease, transform 0.05s ease;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
}

.btn-primary,
.btn-primary:hover,
.btn-primary:active {
    color: #ffffff;
}

.btn-primary:active {
    background-color: var(--primary-darker);
    transform: scale(0.97);
}

/* Botón secundario para acciones de cancelar */
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #6b7280;
    color: #ffffff;

    padding: 0.55rem 1.1rem;
    border-radius: 0.6rem;
    font-weight: 600;
    font-size: 0.85rem;

    box-shadow: none !important;
    border: none;
    cursor: pointer;

    transition: background-color 0.15s ease, transform 0.05s ease;
}

.btn-secondary:hover {
    background-color: #4b5563;
}

.btn-secondary,
.btn-secondary:hover,
.btn-secondary:active {
    color: #ffffff;
}

.btn-secondary:active {
    background-color: #374151;
    transform: scale(0.97);
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0.45rem 0.9rem;
    border-radius: 0.6rem;

    border: 1px solid var(--border-light);
    color: inherit;
    font-size: 0.85rem;

    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn-ghost:hover {
    background-color: rgba(148,163,184,0.12);
    border-color: rgba(148,163,184,0.6);
}

/* CARDS ------------------------------------------------------ */

.card {
    border-radius: 1rem;
    background-color: var(--bg-card-light);
    border: 1px solid rgba(148,163,184,0.25);
    padding: 1.3rem;
    transition: all 0.3s ease;
}

a.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border-color: rgba(148,163,184,0.4);
}

/* CARDS DE MÉTRICAS ----------------------------------------- */

.metric-card {
    border-radius: 1rem;
    padding: 1.1rem;
    background-color: var(--bg-card-light);
    border: 1px solid rgba(148,163,184,0.25);
}

.metric-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: rgba(100,116,139,0.85);
}

.metric-value {
    font-size: 1.7rem;
    font-weight: 700;
}

/* INPUTS ----------------------------------------------------- */

.input {
    width: 100%;
    border-radius: 0.6rem;
    border: 1px solid var(--border-light);
    padding: 0.55rem 0.7rem;
    font-size: 0.9rem;
    background-color: rgba(255,255,255,0.95);
    color: var(--text-light);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 1px var(--primary);
}

/* TABLE ------------------------------------------------------ */

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.55rem 0.55rem;
    border-bottom: 1px solid rgba(148,163,184,0.25);
}

.table th {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-weight: 600;
    color: rgba(100,116,139,0.95);
}

.table tr:hover td {
    background-color: rgba(148,163,184,0.07);
}

/* BADGES ----------------------------------------------------- */

.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 600;
    background-color: rgba(37,99,235,0.15);
    color: var(--primary-dark);
}

/* Badge size variants */
.badge-lg {
    padding: 0.35rem 0.85rem;
    font-size: 0.75rem;
}

.badge-sm {
    padding: 0.15rem 0.5rem;
    font-size: 0.65rem;
}

/* Badge color variants - Stocks */
.badge-blue {
    background-color: rgba(37, 99, 235, 0.15) !important;
    color: #1e40af !important;
    font-weight: 600;
}

.badge-orange {
    background-color: rgba(255, 107, 53, 0.2) !important;
    color: #ff6b35 !important;
    font-weight: 700 !important;
    border: 1px solid rgba(255, 107, 53, 0.3) !important;
}

.badge-green {
    background-color: rgba(34, 197, 94, 0.15) !important;
    color: #15803d !important;
    font-weight: 600;
}

/* Badge color variants - Properties */
.badge-green-dark {
    background-color: rgba(5, 46, 22, 0.9);
    color: #d1fae5;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.badge-yellow {
    background-color: rgba(254, 243, 199, 0.95);
    color: #854d0e;
    border: 1px solid rgba(234, 179, 8, 0.3);
}

/* Text color variants */
.text-terracotta {
    color: #a0522d;
}

/* CHIPS POSITIVE/NEGATIVE ----------------------------------- */

.chip-green {
    background-color: rgba(22,163,74,0.18);
    color: #166534;
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
}

.chip-red {
    background-color: rgba(220,38,38,0.18);
    color: #b91c1c;
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
}

/* ============================================================
   LANDING PAGE - DARK THEME
   ============================================================ */

/* Fondo oscuro con gradiente azul central */
body.landing-page {
    background: #0f0f0f !important;
    background-image: radial-gradient(ellipse 100% 50% at 50% 10%, rgba(37, 99, 235, 0.15) 0%, transparent 50%),
                      radial-gradient(ellipse 80% 40% at 50% 0%, rgba(59, 130, 246, 0.1) 0%, transparent 40%) !important;
    color: #ffffff;
    min-height: 100vh;
}

/* Sobrescribir main para landing */
body.landing-page main {
    background: transparent !important;
}

/* Hero Section */
.hero-headline {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: #ffffff;
    margin-bottom: 1.5rem;
}

.hero-headline-highlight {
    background: linear-gradient(135deg, #ff6b35 0%, #ff8c42 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@media (min-width: 640px) {
    .hero-headline {
        font-size: 3.5rem;
    }
}

@media (min-width: 768px) {
    .hero-headline {
        font-size: 4.5rem;
    }
}

@media (min-width: 1024px) {
    .hero-headline {
        font-size: 5rem;
    }
}

.hero-subtitle {
    font-size: 1.375rem;
    line-height: 1.6;
    color: #ffffff;
    max-width: 48rem;
    margin: 0 auto 3rem;
    font-weight: 400;
}

@media (min-width: 768px) {
    .hero-subtitle {
        font-size: 1.5rem;
    }
}

/* Botones Landing */
.landing-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    border-radius: 10px;
    background: linear-gradient(180deg, #ff7b45 0%, #ff6b35 100%);
    color: #ffffff;
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    box-shadow: none;
    text-decoration: none;
}

.landing-btn-primary:hover {
    background: linear-gradient(180deg, #ff8c52 0%, #ff7b45 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    color: #ffffff;
}

.landing-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    border-radius: 10px;
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.landing-btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
}

/* Feature Cards Landing */
.landing-feature-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.landing-feature-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.landing-feature-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.75rem;
}

.landing-feature-description {
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.6);
}

/* Stats Section */
.landing-stat {
    text-align: center;
}

.landing-stat-emoji {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.landing-stat-icon {
    width: 64px;
    height: 64px;
    object-fit: contain;
}

.landing-stat-text {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

/* Feature Icons */
.landing-feature-icon {
    width: 56px;
    height: 56px;
    object-fit: contain;
}

/* Social Proof */
.landing-social-proof {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.landing-stars {
    color: #fbbf24;
    font-size: 1.5rem;
}

/* Subrayado animado manual en naranja */
.animated-underline {
    position: relative;
    display: inline-block;
}

.animated-underline::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b35 0%, #ff8c42 100%);
    transform: skewY(-2deg);
    border-radius: 2px;
    transition: width 0.4s ease-in-out;
}

body.landing-page .animated-underline::after {
    animation: underlineGrow 1s ease-in-out 0.3s forwards;
}

@keyframes underlineGrow {
    0% {
        width: 0;
        opacity: 0.8;
    }
    100% {
        width: 100%;
        opacity: 1;
    }
}

/* Pain Points / Quotes List */
.landing-quotes {
    list-style: none;
    padding: 0;
    margin: 0;
}

.landing-quote {
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid #ff6b35;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    line-height: 1.6;
    font-style: italic;
    transition: all 0.3s ease;
}

.landing-quote:hover {
    background: rgba(255, 255, 255, 0.05);
    border-left-color: #ff8c42;
    transform: translateX(8px);
}

.landing-quote::before {
    content: '"';
    color: #ff6b35;
    font-size: 2rem;
    font-weight: 700;
    line-height: 0;
    margin-right: 0.5rem;
    vertical-align: -0.3rem;
}
/* ============================================================
   DASHBOARD DARK THEME
   ============================================================ */

/* Aplicar fondo oscuro a todas las páginas excepto landing */
body:not(.landing-page) {
    background: #0f0f0f !important;
    background-image: radial-gradient(ellipse 100% 50% at 50% 10%, rgba(37, 99, 235, 0.08) 0%, transparent 50%) !important;
    color: #ffffff;
    min-height: 100vh;
}

/* Main oscuro */
body:not(.landing-page) main {
    background: transparent !important;
}

/* Cards oscuras con el estilo de la captura */
body:not(.landing-page) .card {
    background: rgba(26, 31, 41, 0.8) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #ffffff;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

body:not(.landing-page) .card:hover {
    background: rgba(26, 31, 41, 0.9) !important;
    border-color: rgba(255, 255, 255, 0.12) !important;
}

body:not(.landing-page) .metric-card {
    background: rgba(26, 31, 41, 0.8) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: #ffffff;
}

/* Card de patrimonio total más destacada */
body:not(.landing-page) .bg-gradient-to-br {
    background: rgba(26, 31, 41, 0.9) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* HR lines en cards oscuras */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Textos en cards oscuras */
body:not(.landing-page) .metric-label,
body:not(.landing-page) .text-gray-600 {
    color: rgba(255, 255, 255, 0.5) !important;
}

body:not(.landing-page) .metric-value {
    color: #ffffff !important;
}

/* Títulos y headings */
body:not(.landing-page) h1,
body:not(.landing-page) h2,
body:not(.landing-page) h3,
body:not(.landing-page) h4 {
    color: #ffffff !important;
}

body:not(.landing-page) .text-gray-700 {
    color: rgba(255, 255, 255, 0.85) !important;
}

body:not(.landing-page) .text-gray-900 {
    color: #ffffff !important;
}

body:not(.landing-page) .text-gray-500 {
    color: rgba(255, 255, 255, 0.5) !important;
}

body:not(.landing-page) .text-gray-400 {
    color: rgba(255, 255, 255, 0.4) !important;
}

body:not(.landing-page) .text-gray-300 {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Porcentajes de asignación */
body:not(.landing-page) .allocation-percentage,
body:not(.landing-page) .card .text-2xl.font-bold.text-gray-400 {
    color: rgba(255, 255, 255, 0.4) !important;
}

/* Inputs oscuros */
body:not(.landing-page) .input,
body:not(.landing-page) input,
body:not(.landing-page) select,
body:not(.landing-page) textarea {
    background-color: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

body:not(.landing-page) .input:focus,
body:not(.landing-page) input:focus,
body:not(.landing-page) select:focus,
body:not(.landing-page) textarea:focus {
    background-color: rgba(255, 255, 255, 0.08) !important;
    border-color: #ff6b35 !important;
    box-shadow: 0 0 0 1px #ff6b35 !important;
}

body:not(.landing-page) .input::placeholder,
body:not(.landing-page) input::placeholder,
body:not(.landing-page) textarea::placeholder {
    color: rgba(255, 255, 255, 0.4) !important;
}

/* Tablas oscuras */
body:not(.landing-page) .table th {
    color: rgba(255, 255, 255, 0.6) !important;
    border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

body:not(.landing-page) .table td {
    color: rgba(255, 255, 255, 0.85) !important;
    border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .table tr:hover td {
    background-color: rgba(255, 255, 255, 0.03) !important;
}

/* Chips verdes y rojos - Solo color, sin fondo por defecto */
body:not(.landing-page) .text-green-600,
body:not(.landing-page) .dark\:text-green-400 {
    color: #4ade80 !important;
}

body:not(.landing-page) .text-red-600,
body:not(.landing-page) .dark\:text-red-400 {
    color: #f87171 !important;
}

/* Chips con clase específica llevan fondo */
body:not(.landing-page) .chip-green {
    background-color: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    display: inline-block;
}

body:not(.landing-page) .chip-red {
    background-color: rgba(239, 68, 68, 0.15) !important;
    color: #f87171 !important;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    display: inline-block;
}

/* SOLO spans con font-semibold Y color verde/rojo llevan fondo */
body:not(.landing-page) span.font-semibold.text-green-600,
body:not(.landing-page) span.font-semibold.dark\:text-green-400 {
    background-color: rgba(34, 197, 94, 0.15) !important;
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    display: inline-block;
}

body:not(.landing-page) span.font-semibold.text-red-600,
body:not(.landing-page) span.font-semibold.dark\:text-red-400 {
    background-color: rgba(239, 68, 68, 0.15) !important;
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    display: inline-block;
}

/* Badges oscuros */
body:not(.landing-page) .badge {
    background-color: rgba(37, 99, 235, 0.15) !important;
    color: #60a5fa !important;
}

body:not(.landing-page) .badge-green-dark {
    background-color: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
}

body:not(.landing-page) .badge-yellow {
    background-color: rgba(234, 179, 8, 0.15) !important;
    color: #fbbf24 !important;
}

/* Links oscuros */
body:not(.landing-page) a:not(.btn-primary):not(.btn-ghost):not(.header-btn-primary):not(.header-btn-ghost):not(.nav-link):not(.nav-link-mobile) {
    color: #60a5fa !important;
}

body:not(.landing-page) a:not(.btn-primary):not(.btn-ghost):not(.header-btn-primary):not(.header-btn-ghost):not(.nav-link):not(.nav-link-mobile):hover {
    color: #93c5fd !important;
}

/* Mensajes de error/éxito oscuros */
body:not(.landing-page) .bg-red-50 {
    background-color: rgba(239, 68, 68, 0.1) !important;
}

body:not(.landing-page) .bg-green-100 {
    background-color: rgba(34, 197, 94, 0.1) !important;
}

body:not(.landing-page) .text-red-800 {
    color: #f87171 !important;
}

body:not(.landing-page) .text-green-800 {
    color: #4ade80 !important;
}

/* Hover para cards clickeables */
body:not(.landing-page) a.card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3) !important;
}

/* HR (separadores horizontales) oscuros */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Eliminar efectos de subrayado en cifras y porcentajes */
body:not(.landing-page) .metric-value,
body:not(.landing-page) .text-2xl,
body:not(.landing-page) .text-3xl,
body:not(.landing-page) .text-4xl {
    text-decoration: none !important;
    background: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: unset !important;
}

/* Mantener subrayado solo en cifras con clase específica de color verde/rojo */
body:not(.landing-page) .text-green-600,
body:not(.landing-page) .text-red-600,
body:not(.landing-page) .dark\:text-green-400,
body:not(.landing-page) .dark\:text-red-400 {
    background: linear-gradient(to right, currentColor 0%, currentColor 100%) !important;
    background-size: 100% 1px !important;
    background-repeat: no-repeat !important;
    background-position: 0 100% !important;
    padding-bottom: 2px !important;
}

/* HR oscuros que coincidan con bordes de cards */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* HR oscuro que coincide con el borde de las cards */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Eliminar decoraciones en cifras y porcentajes */
body:not(.landing-page) .metric-value,
body:not(.landing-page) .text-2xl,
body:not(.landing-page) .text-3xl,
body:not(.landing-page) .text-4xl {
    text-decoration: none !important;
    background-image: none !important;
    -webkit-background-clip: unset !important;
    -webkit-text-fill-color: unset !important;
    background-clip: unset !important;
}

/* HR y bordes dentro de cards oscuras - mismo color que borde de card */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Eliminar underline de enlaces en cards */
body:not(.landing-page) a.card {
    text-decoration: none !important;
}

/* HR oscuros que coincidan con el borde de las cards */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Separadores hr oscuros que coincidan con bordes de cards */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Remover cualquier text-decoration de números y porcentajes */
body:not(.landing-page) .card .text-2xl,
body:not(.landing-page) .card .text-3xl,
body:not(.landing-page) .card .text-4xl,
body:not(.landing-page) .metric-value {
    text-decoration: none !important;
}

/* HR dentro de cards debe coincidir con el borde de la card */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* HR dentro de cards - mismo color que el borde */
body:not(.landing-page) hr,
body:not(.landing-page) .border-gray-200,
body:not(.landing-page) .dark\:border-gray-700 {
    border-color: rgba(255, 255, 255, 0.08) !important;
}
/* Eliminar líneas de subrayado en elementos verdes y rojos */
body:not(.landing-page) .text-green-600,
body:not(.landing-page) .text-red-600,
body:not(.landing-page) .dark\:text-green-400,
body:not(.landing-page) .dark\:text-red-400 {
    text-decoration: none !important;
    background: none !important;
    background-image: none !important;
    border-bottom: none !important;
}

body:not(.landing-page) .text-xs.text-green-600,
body:not(.landing-page) .text-xs.text-red-600,
body:not(.landing-page) .text-xs.dark\:text-green-400,
body:not(.landing-page) .text-xs.dark\:text-red-400 {
    text-decoration: none !important;
    background: none !important;
    background-image: none !important;
    border-bottom: none !important;
}
/* ============================================================
   MODALES DARK THEME
   ============================================================ */

/* Fondo del modal oscuro */
body:not(.landing-page) .fixed.inset-0.bg-black {
    background-color: rgba(0, 0, 0, 0.75) !important;
}

/* Contenedor del modal oscuro */
body:not(.landing-page) .bg-white {
    background-color: rgba(26, 31, 41, 0.95) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body:not(.landing-page) .dark\:bg-gray-800 {
    background-color: rgba(26, 31, 41, 0.95) !important;
}

/* Títulos en modales */
body:not(.landing-page) .bg-white h3,
body:not(.landing-page) .dark\:bg-gray-800 h3 {
    color: #ffffff !important;
}

/* Botón de cerrar modal */
body:not(.landing-page) .text-gray-500.hover\:text-gray-700 {
    color: rgba(255, 255, 255, 0.6) !important;
}

body:not(.landing-page) .text-gray-500.hover\:text-gray-700:hover {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Info boxes dentro de modales */
body:not(.landing-page) .bg-blue-50 {
    background-color: rgba(37, 99, 235, 0.1) !important;
    color: #ffffff !important;
}

body:not(.landing-page) .dark\:bg-blue-900\/20 {
    background-color: rgba(37, 99, 235, 0.1) !important;
}

body:not(.landing-page) .bg-yellow-50 {
    background-color: rgba(234, 179, 8, 0.1) !important;
    color: #ffffff !important;
}

body:not(.landing-page) .dark\:bg-yellow-900\/20 {
    background-color: rgba(234, 179, 8, 0.1) !important;
}

body:not(.landing-page) .bg-red-50 {
    background-color: rgba(239, 68, 68, 0.1) !important;
}

body:not(.landing-page) .dark\:bg-red-900\/20 {
    background-color: rgba(239, 68, 68, 0.1) !important;
}

/* Labels en modales */
body:not(.landing-page) label.text-gray-500,
body:not(.landing-page) label.dark\:text-gray-400 {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* Select oscuro */
body:not(.landing-page) select {
    background-color: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

body:not(.landing-page) select:focus {
    background-color: rgba(255, 255, 255, 0.08) !important;
    border-color: #ff6b35 !important;
    box-shadow: 0 0 0 1px #ff6b35 !important;
}

body:not(.landing-page) select option {
    background-color: #1a1f29 !important;
    color: #ffffff !important;
}

/* Asterisco requerido */
body:not(.landing-page) .text-red-500 {
    color: #f87171 !important;
}

/* Textos en modales */
body:not(.landing-page) .bg-white .text-sm,
body:not(.landing-page) .dark\:bg-gray-800 .text-sm {
    color: rgba(255, 255, 255, 0.85) !important;
}

/* Info box verde en modal de vender */
body:not(.landing-page) .bg-green-50 {
    background-color: rgba(34, 197, 94, 0.1) !important;
    color: #ffffff !important;
}

body:not(.landing-page) .dark\:bg-green-900\/20 {
    background-color: rgba(34, 197, 94, 0.1) !important;
}

/* Textos dentro del info box verde */
body:not(.landing-page) .bg-green-50 .text-gray-500,
body:not(.landing-page) .bg-green-50 .text-gray-600,
body:not(.landing-page) .dark\:bg-green-900\/20 .text-gray-500,
body:not(.landing-page) .dark\:bg-green-900\/20 .text-gray-600,
body:not(.landing-page) .dark\:bg-green-900\/20 .dark\:text-gray-400 {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Hover en filas de tabla oscuras */
body:not(.landing-page) tr.hover\:bg-gray-50:hover {
    background-color: rgba(255, 255, 255, 0.03) !important;
}

/* Tfoot oscuro */
body:not(.landing-page) tfoot tr.bg-gray-50 {
    background-color: rgba(255, 255, 255, 0.05) !important;
}

body:not(.landing-page) tfoot td {
    color: rgba(255, 255, 255, 0.9) !important;
}

body:not(.landing-page) tfoot .text-green-600 {
    color: #4ade80 !important;
}

/* ============================================================
   CASH.PHP - CORRECCIONES DARK MODE
   ============================================================ */

/* Hover en items de cuentas */
body:not(.landing-page) .hover\:bg-gray-50:hover {
    background-color: rgba(255, 255, 255, 0.03) !important;
}

body:not(.landing-page) .dark\:hover\:bg-gray-800\/50:hover {
    background-color: rgba(255, 255, 255, 0.03) !important;
}

/* Badges de moneda oscuros */
body:not(.landing-page) .bg-gray-100 {
    background-color: rgba(255, 255, 255, 0.08) !important;
    color: rgba(255, 255, 255, 0.7) !important;
}

body:not(.landing-page) .dark\:bg-gray-800 {
    background-color: rgba(255, 255, 255, 0.08) !important;
}

/* Textos de cifras principales */
body:not(.landing-page) .text-gray-800 {
    color: #ffffff !important;
}

body:not(.landing-page) .dark\:text-gray-100 {
    color: #ffffff !important;
}

/* Textos secundarios mejorados */
body:not(.landing-page) .text-gray-400 {
    color: rgba(255, 255, 255, 0.5) !important;
}

body:not(.landing-page) .dark\:text-gray-400 {
    color: rgba(255, 255, 255, 0.5) !important;
}

body:not(.landing-page) .dark\:text-gray-500 {
    color: rgba(255, 255, 255, 0.4) !important;
}

/* Bordes/divisores entre items */
body:not(.landing-page) .divide-y > * {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .divide-gray-200 > * {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

body:not(.landing-page) .dark\:divide-gray-700 > * {
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Botones de borrar rojos */
body:not(.landing-page) .text-red-500 {
    color: #f87171 !important;
}

body:not(.landing-page) .hover\:text-red-700:hover {
    color: #fca5a5 !important;
}

body:not(.landing-page) .dark\:text-red-400 {
    color: #f87171 !important;
}

body:not(.landing-page) .dark\:hover\:text-red-300:hover {
    color: #fca5a5 !important;
}

/* Corrección botones ghost en items */
body:not(.landing-page) a.btn-ghost {
    color: rgba(255, 255, 255, 0.85) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

body:not(.landing-page) a.btn-ghost:hover {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
}

/* Botón ghost rojo con borde */
body:not(.landing-page) a.btn-ghost.text-red-500,
body:not(.landing-page) a.btn-ghost.dark\:text-red-400 {
    color: #f87171 !important;
    border: 1px solid rgba(248, 113, 113, 0.3) !important;
    padding: 0.45rem 0.9rem !important;
}

body:not(.landing-page) a.btn-ghost.text-red-500:hover,
body:not(.landing-page) a.btn-ghost.dark\:text-red-400:hover {
    color: #fca5a5 !important;
    background-color: rgba(239, 68, 68, 0.1) !important;
    border-color: rgba(248, 113, 113, 0.5) !important;
}
/* ============================================================
   BOTÓN DANGER (para acciones destructivas)
   ============================================================ */

.btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0.375rem;
    border: 1px solid #fca5a5;
    background-color: transparent;
    color: #dc2626;
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-danger:hover {
    background-color: rgba(220, 38, 38, 0.05);
    border-color: #f87171;
    color: #b91c1c;
}

/* Dark mode */
body:not(.landing-page) .btn-danger {
    border-color: #991b1b;
    color: #f87171;
}

body:not(.landing-page) .btn-danger:hover {
    background-color: rgba(248, 113, 113, 0.1);
    border-color: #b91c1c;
    color: #fca5a5;
}

/* Forzar sin efectos de subrayado para evitar conflictos */
.btn-danger {
    text-decoration: none !important;
    background-image: none !important;
    padding-bottom: 0.5rem !important;
}
/* ============================================================
   MODO CLARO ALTERNATIVO
   Se activa cuando html tiene la clase "dark"
   El diseño por defecto (oscuro actual) permanece sin cambios
   ============================================================ */

/* MODO CLARO: Cuando tiene la clase .dark */

/* ============================================================
   MODO FINTECH (Light Mode)
   Paleta: Grises claros, azules corporativos, naranja accent
   ============================================================ */

/* Variables del tema fintech */
html.dark {
    --fintech-bg: #f8f9fb;
    --fintech-card: #ffffff;
    --fintech-border: rgba(15, 23, 42, 0.08);
    --fintech-text-primary: #0f172a;
    --fintech-text-secondary: #475569;
    --fintech-blue: #0066cc;
    --fintech-blue-hover: #0052a3;
    --fintech-orange: #ff7b45;
    --fintech-orange-hover: #ff6b35;
}

/* Body y fondo */
html.dark body {
    background-color: var(--fintech-bg) !important;
    background-image: radial-gradient(ellipse 120% 60% at 50% -10%, rgba(0, 102, 204, 0.03) 0%, transparent 50%) !important;
    color: var(--fintech-text-primary) !important;
}

/* Header fintech */
html.dark .header {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--fintech-border);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    color: var(--fintech-text-primary) !important;
}

/* Nav links */
html.dark .nav-link {
    color: var(--fintech-text-secondary);
    font-weight: 500;
}

html.dark .nav-link:hover {
    background-color: rgba(0, 102, 204, 0.06);
    color: var(--fintech-blue);
}

html.dark .nav-link-mobile {
    color: var(--fintech-text-secondary);
}

html.dark .nav-link-mobile:hover {
    background-color: rgba(0, 102, 204, 0.06);
    color: var(--fintech-blue);
}

/* Botones header */
html.dark .header-btn-ghost {
    background-color: transparent;
    border-color: var(--fintech-border);
    color: var(--fintech-text-primary);
    font-weight: 500;
}

html.dark .header-btn-ghost:hover {
    background-color: rgba(0, 102, 204, 0.06);
    border-color: var(--fintech-blue);
    color: var(--fintech-blue);
}

html.dark .header-btn-primary {
    background: linear-gradient(180deg, var(--fintech-orange) 0%, var(--fintech-orange-hover) 100%);
    color: #ffffff;
}

html.dark .header-btn-primary:hover {
    background: linear-gradient(180deg, #ff8c52 0%, var(--fintech-orange) 100%);
}

/* Botones principales */
html.dark .btn-primary {
    background-color: var(--fintech-orange);
    color: #ffffff;
    font-weight: 600;
}

html.dark .btn-primary:hover {
    background-color: var(--fintech-orange-hover);
}

/* Botones ghost */
html.dark .btn-ghost {
    border-color: var(--fintech-border) !important;
    color: var(--fintech-text-secondary) !important;
    background-color: #ffffff !important;
    font-weight: 500;
}

html.dark .btn-ghost:hover {
    background-color: rgba(0, 102, 204, 0.04) !important;
    border-color: var(--fintech-blue) !important;
    color: var(--fintech-blue) !important;
}

/* Botones danger */
html.dark .btn-danger {
    border-color: #dc2626;
    color: #dc2626;
    background-color: #ffffff;
}

html.dark .btn-danger:hover {
    background-color: rgba(220, 38, 38, 0.06);
    border-color: #b91c1c;
    color: #b91c1c;
}

/* Cards */
html.dark .card {
    background-color: var(--fintech-card) !important;
    border-color: var(--fintech-border) !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
    transition: all 0.2s ease;
}

html.dark .card:hover {
    background-color: #fafbfc !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
    border-color: rgba(0, 102, 204, 0.15);
}

/* Inputs y formularios */
html.dark .input {
    background-color: #ffffff !important;
    border-color: var(--fintech-border) !important;
    color: var(--fintech-text-primary) !important;
}

html.dark .input:focus {
    border-color: var(--fintech-blue) !important;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

html.dark input[type="text"],
html.dark input[type="number"],
html.dark input[type="date"],
html.dark input[type="email"],
html.dark input[type="password"],
html.dark select,
html.dark textarea {
    background-color: #ffffff !important;
    color: var(--fintech-text-primary) !important;
    border-color: var(--fintech-border) !important;
}

/* Títulos */
html.dark h1 {
    color: var(--fintech-text-primary) !important;
    font-weight: 700;
}

html.dark h2,
html.dark h3 {
    color: var(--fintech-text-primary) !important;
    font-weight: 600;
}

/* Textos */
html.dark p {
    color: var(--fintech-text-secondary) !important;
}

html.dark label {
    color: var(--fintech-text-secondary) !important;
    font-weight: 500;
}

html.dark .text-sm {
    color: var(--fintech-text-secondary) !important;
}

html.dark .font-medium {
    color: var(--fintech-text-primary) !important;
}

html.dark .font-semibold {
    color: var(--fintech-text-primary) !important;
}

html.dark .font-bold {
    color: var(--fintech-text-primary) !important;
}

/* Colores azules (primary) */
html.dark .text-primary {
    color: var(--fintech-blue) !important;
}

/* Colores grises */
html.dark .text-gray-300 {
    color: #94a3b8 !important;
}

html.dark .text-gray-400 {
    color: #64748b !important;
}

html.dark .text-gray-500 {
    color: #64748b !important;
}

html.dark .text-gray-600 {
    color: var(--fintech-text-secondary) !important;
}

html.dark .text-gray-700 {
    color: #334155 !important;
}

html.dark .text-gray-800 {
    color: var(--fintech-text-primary) !important;
}

html.dark .bg-gray-50 {
    background-color: #f8f9fb !important;
}

html.dark .bg-gray-100 {
    background-color: #f1f3f5 !important;
}

html.dark .bg-gray-200 {
    background-color: #e5e7eb !important;
}

html.dark .bg-gray-800 {
    background-color: #f8f9fb !important;
}

html.dark .bg-gray-900 {
    background-color: #f1f3f5 !important;
}

html.dark .border-gray-200 {
    border-color: var(--fintech-border) !important;
}

html.dark .border-gray-300 {
    border-color: rgba(15, 23, 42, 0.12) !important;
}

html.dark .border-gray-700 {
    border-color: rgba(15, 23, 42, 0.15) !important;
}

/* Colores verde (positivo) */
html.dark .text-green-600,
html.dark .text-green-400,
html.dark .text-green-300 {
    color: #059669 !important;
    font-weight: 600;
}

html.dark .text-green-800 {
    color: #065f46 !important;
}

html.dark .text-green-200 {
    color: #059669 !important;
}

html.dark .bg-green-100 {
    background-color: #d1fae5 !important;
}

html.dark .bg-green-900 {
    background-color: #d1fae5 !important;
}

/* Colores rojo (negativo) */
html.dark .text-red-600,
html.dark .text-red-400,
html.dark .text-red-300 {
    color: #dc2626 !important;
    font-weight: 600;
}

html.dark .text-red-800 {
    color: #991b1b !important;
}

html.dark .text-red-200 {
    color: #dc2626 !important;
}

html.dark .bg-red-100 {
    background-color: #fee2e2 !important;
}

html.dark .bg-red-900 {
    background-color: #fee2e2 !important;
}

/* Colores amarillo/warning */
html.dark .text-yellow-900,
html.dark .text-yellow-200 {
    color: #d97706 !important;
    font-weight: 600;
}

html.dark .bg-yellow-100 {
    background-color: #fef3c7 !important;
}

html.dark .bg-yellow-900 {
    background-color: #fef3c7 !important;
}

/* Badges */
html.dark .badge-green-dark {
    background-color: #059669 !important;
    color: #ffffff !important;
    font-weight: 600;
}

html.dark .badge-yellow {
    background-color: #d97706 !important;
    color: #ffffff !important;
    font-weight: 600;
}

html.dark .badge-red {
    background-color: #dc2626 !important;
    color: #ffffff !important;
    font-weight: 600;
}

/* Footer */
html.dark footer {
    border-color: var(--fintech-border);
}

html.dark footer .text-gray-400 {
    color: var(--fintech-text-secondary) !important;
}

html.dark #theme-toggle:hover {
    background-color: rgba(0, 102, 204, 0.06);
}

/* Logo - se cambia con JS */
html.dark .logo-img {
    /* El src se cambia mediante JavaScript */
}

/* 2. Porcentajes oscuros y visibles */
html.dark .text-gray-400 {
    color: #9ca3af !important;
}

html.dark .text-gray-500 {
    color: #9ca3af !important;
}

html.dark .dark\:text-gray-400 {
    color: #9ca3af !important;
}

html.dark .dark\:text-gray-500 {
    color: #9ca3af !important;
}

/* 3. Botones ghost con borde y texto visible */
html.dark a.btn-ghost,
html.dark button.btn-ghost {
    border: 1px solid var(--fintech-border) !important;
    color: var(--fintech-text-secondary) !important;
    background-color: #ffffff !important;
    font-weight: 500;
}

html.dark a.btn-ghost:hover,
html.dark button.btn-ghost:hover {
    background-color: rgba(0, 102, 204, 0.04) !important;
    border-color: var(--fintech-blue) !important;
    color: var(--fintech-blue) !important;
}

/* 4. Labels de formularios oscuros y visibles */
html.dark .text-xs {
    color: #6b7280 !important;
}

html.dark .dark\:text-gray-400 {
    color: #6b7280 !important;
}

html.dark label.text-gray-500,
html.dark label.dark\:text-gray-400 {
    color: #374151 !important;
}

/* 5. Tablas visibles */
html.dark table {
    color: var(--fintech-text-primary) !important;
}

html.dark table th {
    color: var(--fintech-text-primary) !important;
    font-weight: 600;
    border-bottom: 2px solid var(--fintech-border) !important;
}

html.dark table td {
    color: var(--fintech-text-secondary) !important;
    border-bottom: 1px solid var(--fintech-border) !important;
}

html.dark table tbody tr {
    border-bottom: 1px solid var(--fintech-border) !important;
}

html.dark table tbody tr:hover {
    background-color: #fafbfc !important;
}

/* Badges en tablas - tamaño */
html.dark .badge-sm {
    font-size: 0.75rem !important;
    padding: 0.125rem 0.5rem !important;
}

/* Color azul en tablas */
html.dark .text-blue-300 {
    color: var(--fintech-blue) !important;
}

/* Botones en tablas */
html.dark table .btn-ghost {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.75rem !important;
}

html.dark table .text-red-500 {
    color: #dc2626 !important;
}

/* 1 y 2. Botones de colores con texto blanco */
html.dark .bg-green-600 {
    background-color: #059669 !important;
    color: #ffffff !important;
}

html.dark .bg-green-600:hover,
html.dark .hover\:bg-green-700:hover {
    background-color: #047857 !important;
}

html.dark .bg-blue-600 {
    background-color: #0066cc !important;
    color: #ffffff !important;
}

html.dark .bg-blue-600:hover,
html.dark .hover\:bg-blue-700:hover {
    background-color: #0052a3 !important;
}

html.dark .text-white {
    color: #ffffff !important;
}

/* 3. Tabla - todos los elementos visibles */
html.dark table.table {
    color: var(--fintech-text-primary) !important;
}

html.dark table.table thead {
    background-color: #f8f9fb !important;
}

html.dark table.table thead th {
    color: var(--fintech-text-primary) !important;
    font-weight: 600;
    border-bottom: 2px solid var(--fintech-border) !important;
    padding: 0.75rem 1rem;
}

html.dark table.table tbody td {
    color: var(--fintech-text-secondary) !important;
    border-bottom: 1px solid var(--fintech-border) !important;
    padding: 0.75rem 1rem;
}

html.dark table.table tbody tr {
    border-bottom: 1px solid var(--fintech-border) !important;
}

html.dark table.table tbody tr:hover {
    background-color: #fafbfc !important;
}

html.dark table.table .font-medium {
    color: var(--fintech-text-primary) !important;
}

html.dark table.table .text-right {
    text-align: right !important;
}

/* Badge verde en tabla */
html.dark table.table .badge-green {
    background-color: #059669 !important;
    color: #ffffff !important;
    font-weight: 600;
}

html.dark table.table .badge-sm {
    font-size: 0.75rem !important;
    padding: 0.25rem 0.5rem !important;
    border-radius: 0.25rem;
}

/* Plusvalías azules */
html.dark table.table .text-blue-300 {
    color: var(--fintech-blue) !important;
    font-weight: 700;
}

/* Botones en tabla */
html.dark table.table .btn-ghost {
    border: 1px solid var(--fintech-border) !important;
    color: var(--fintech-text-secondary) !important;
    background-color: #ffffff !important;
    padding: 0.25rem 0.5rem !important;
}

html.dark table.table .btn-ghost:hover {
    border-color: var(--fintech-blue) !important;
    color: var(--fintech-blue) !important;
}

html.dark table.table .text-red-500 {
    color: #dc2626 !important;
}

html.dark table.table .text-red-500:hover {
    color: #b91c1c !important;
}

/* 4. Modal claro */
html.dark .bg-gray-800 {
    background-color: #ffffff !important;
}

html.dark .dark\:bg-gray-800 {
    background-color: #ffffff !important;
}

html.dark .bg-blue-50 {
    background-color: #eff6ff !important;
}

html.dark .dark\:bg-blue-900\/20 {
    background-color: #eff6ff !important;
}

html.dark .text-gray-500 {
    color: var(--fintech-text-secondary) !important;
}

html.dark .dark\:text-gray-400 {
    color: var(--fintech-text-secondary) !important;
}

html.dark .text-gray-700 {
    color: var(--fintech-text-primary) !important;
}

html.dark .hover\:text-gray-700:hover {
    color: var(--fintech-text-primary) !important;
}

/* Fondo del overlay del modal */
html.dark .bg-black.bg-opacity-50 {
    background-color: rgba(0, 0, 0, 0.5) !important;
}

/* Inputs dentro del modal */
html.dark .input {
    background-color: #ffffff !important;
    border-color: var(--fintech-border) !important;
    color: var(--fintech-text-primary) !important;
}

html.dark .input:focus {
    border-color: var(--fintech-blue) !important;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

/* Modal - títulos y textos oscuros */
html.dark .text-lg {
    color: var(--fintech-text-primary) !important;
}

html.dark h3 {
    color: var(--fintech-text-primary) !important;
}

html.dark .font-bold {
    color: var(--fintech-text-primary) !important;
}

/* Spans de tipo (Acción, etc) */
html.dark span.text-gray-500 {
    color: var(--fintech-text-secondary) !important;
}

/* Botón cerrar modal (×) */
html.dark button.text-gray-500 {
    color: var(--fintech-text-secondary) !important;
}

html.dark button.hover\:text-gray-700:hover {
    color: var(--fintech-text-primary) !important;
}

/* Div de info gris (property cash flow) */
html.dark .bg-gray-50 {
    background-color: #f8f9fb !important;
}

html.dark .dark\:bg-gray-800 {
    background-color: #f8f9fb !important;
}

html.dark .text-sm.text-gray-500 {
    color: var(--fintech-text-secondary) !important;
}

/* Verde en property */
html.dark .text-green-600 {
    color: #059669 !important;
}

html.dark .text-3xl {
    font-size: 1.875rem !important;
}

/* Botones con texto de colores (metals) */
html.dark a.btn-ghost.text-green-600,
html.dark a.btn-ghost.dark\:text-green-400 {
    color: #059669 !important;
    border: 1px solid var(--fintech-border) !important;
    background-color: #ffffff !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

html.dark a.btn-ghost.text-green-600:hover,
html.dark a.btn-ghost.hover\:text-green-700:hover,
html.dark a.btn-ghost.dark\:hover\:text-green-300:hover {
    color: #047857 !important;
    border-color: #059669 !important;
}

html.dark a.btn-ghost.text-blue-600,
html.dark a.btn-ghost.dark\:text-blue-400 {
    color: var(--fintech-blue) !important;
    border: 1px solid var(--fintech-border) !important;
    background-color: #ffffff !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

html.dark a.btn-ghost.text-blue-600:hover {
    color: var(--fintech-blue-hover) !important;
    border-color: var(--fintech-blue) !important;
}

/* Texto general en modales y formularios */
html.dark label {
    color: var(--fintech-text-secondary) !important;
}

html.dark .text-xs.font-medium {
    color: var(--fintech-text-secondary) !important;
}

html.dark .text-red-500 {
    color: #dc2626 !important;
}

/* Info boxes */
html.dark .bg-blue-50 {
    background-color: #eff6ff !important;
}

html.dark .dark\:bg-blue-900\/20 {
    background-color: #eff6ff !important;
}

html.dark .bg-blue-50 .font-bold {
    color: var(--fintech-text-primary) !important;
}

/* Modal stocks - títulos h3 oscuros */
html.dark h3.text-lg.font-bold {
    color: #0f172a !important;
}

/* Div verde de info en modal vender */
html.dark .bg-green-50 {
    background-color: #d1fae5 !important;
}

html.dark .dark\:bg-green-900\/20 {
    background-color: #d1fae5 !important;
}

html.dark .bg-green-50 .text-sm,
html.dark .dark\:bg-green-900\/20 .text-sm {
    color: #0f172a !important;
}

html.dark .bg-green-50 .font-bold,
html.dark .dark\:bg-green-900\/20 .font-bold {
    color: #0f172a !important;
}

html.dark .bg-green-50 .text-gray-500,
html.dark .dark\:bg-green-900\/20 .text-gray-500 {
    color: #475569 !important;
}

html.dark .bg-green-50 .text-xs,
html.dark .dark\:bg-green-900\/20 .text-xs {
    color: #374151 !important;
}

html.dark .bg-green-50 .text-gray-600,
html.dark .dark\:bg-green-900\/20 .text-gray-600 {
    color: #475569 !important;
}

html.dark .bg-green-50 .dark\:text-gray-400,
html.dark .dark\:bg-green-900\/20 .dark\:text-gray-400 {
    color: #475569 !important;
}

html.dark .bg-green-50 .font-semibold,
html.dark .dark\:bg-green-900\/20 .font-semibold {
    color: #0f172a !important;
}

/* Div azul de info en modal añadir */
html.dark .bg-blue-50 .text-sm {
    color: #0f172a !important;
}

html.dark .bg-blue-50 .font-bold {
    color: #0f172a !important;
}

html.dark .bg-blue-50 .text-gray-500 {
    color: #475569 !important;
}

html.dark .dark\:bg-blue-900\/20 .text-sm {
    color: #0f172a !important;
}

html.dark .dark\:bg-blue-900\/20 .font-bold {
    color: #0f172a !important;
}

html.dark .dark\:bg-blue-900\/20 .text-gray-500 {
    color: #475569 !important;
}

/* Hover de cards del dashboard con elevación suave */
html.dark a.card {
    transition: all 0.3s ease;
}

html.dark a.card:hover {
    background-color: #ffffff !important;
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(15, 23, 42, 0.08) !important;
    border-color: rgba(0, 102, 204, 0.12);
}

/* Clase hover:shadow-lg debe ser suave también */
html.dark .hover\:shadow-lg:hover {
    box-shadow: 0 8px 16px rgba(15, 23, 42, 0.08) !important;
}

/* Porcentajes en cards dashboard - más oscuros y visibles */
html.dark .text-2xl.text-gray-400,
html.dark .text-2xl.dark\:text-gray-500 {
    color: #6b7280 !important;
}

html.dark .font-bold.text-gray-400,
html.dark .font-bold.dark\:text-gray-500 {
    color: #6b7280 !important;
}

/* Iconos de criptomonedas oscuros y visibles */
html.dark .text-4xl {
    color: var(--fintech-text-primary) !important;
}

html.dark span.text-4xl {
    color: var(--fintech-text-primary) !important;
}

/* Botones con colores - alineación vertical correcta */
html.dark a.btn-ghost.text-green-600,
html.dark a.btn-ghost.dark\:text-green-400 {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

html.dark a.btn-ghost.text-blue-600,
html.dark a.btn-ghost.dark\:text-blue-400 {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

html.dark a.btn-ghost.text-red-500,
html.dark a.btn-ghost.text-red-600 {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

/* Label "Habilitar análisis con IA" oscuro y visible */
html.dark label[for="ai_enabled"] {
    color: var(--fintech-text-primary) !important;
}

html.dark label.select-none {
    color: var(--fintech-text-primary) !important;
}

/* Label checkbox IA más específico con mayor prioridad */
html.dark .bg-gray-50 label.text-sm.font-medium,
html.dark .dark\:bg-gray-800 label.text-sm.font-medium {
    color: #0f172a !important;
}

html.dark label.font-medium.select-none {
    color: #0f172a !important;
}

html.dark .text-sm.font-medium.select-none {
    color: #0f172a !important;
}

/* Modo alternativo - badges stocks */
html.dark .badge-blue {
    background-color: rgba(37, 99, 235, 0.12) !important;
    color: #3b82f6 !important;
    font-weight: 600;
}

html.dark .badge-orange {
    background-color: rgba(255, 123, 69, 0.18) !important;
    color: #fb923c !important;
    font-weight: 700 !important;
    border: 1px solid rgba(255, 123, 69, 0.3) !important;
}

html.dark .badge-green {
    background-color: rgba(34, 197, 94, 0.12) !important;
    color: #22c55e !important;
    font-weight: 600;
}
/* =================================================================
   CORRECCIONES PARA MODO DARK (tema fintech claro)
   ================================================================= */

/* Porcentajes de cards principales - más visibles en modo dark */
html.dark .text-gray-400 {
    color: #9ca3af !important;
}

html.dark .text-gray-500 {
    color: #6b7280 !important;
}

/* Rentabilidades negativas - rojas en ambos modos */
.text-red-600 {
    color: #dc2626 !important;
}

html.dark .text-red-400 {
    color: #f87171 !important;
}

/* Rentabilidades positivas - verdes en ambos modos */
.text-green-600 {
    color: #16a34a !important;
}

html.dark .text-green-400 {
    color: #4ade80 !important;
}
/* =================================================================
   CORRECCIONES FINALES PARA COLORES EN MODO DARK (tema claro)
   ================================================================= */

/* Rojos - pérdidas y rentabilidad negativa */
html.dark .text-red-600 {
    color: #dc2626 !important;
}

html.dark .text-red-400 {
    color: #f87171 !important;
}

html.dark .dark\:text-red-400 {
    color: #f87171 !important;
}

/* Verdes - ganancias y rentabilidad positiva */
html.dark .text-green-600 {
    color: #16a34a !important;
}

html.dark .text-green-400 {
    color: #22c55e !important;
}

html.dark .dark\:text-green-400 {
    color: #22c55e !important;
}

/* Azules - plusvalías no realizadas */
html.dark .text-blue-300 {
    color: #93c5fd !important;
}

html.dark .text-blue-400 {
    color: #60a5fa !important;
}

html.dark .dark\:text-blue-400 {
    color: #60a5fa !important;
}

/* Font-bold con colores - tablas y cards */
html.dark .font-bold.text-red-600,
html.dark .text-lg.font-bold.text-red-600,
html.dark .text-lg.font-bold.dark\:text-red-400 {
    color: #dc2626 !important;
}

html.dark .font-bold.text-green-600,
html.dark .text-lg.font-bold.text-green-600,
html.dark .text-lg.font-bold.dark\:text-green-400 {
    color: #16a34a !important;
}

html.dark .font-bold.text-blue-300,
html.dark .text-lg.font-bold.text-blue-300,
html.dark .text-lg.font-bold.dark\:text-blue-400 {
    color: #60a5fa !important;
}

/* Font-medium con colores - tablas */
html.dark .font-medium.text-red-600,
html.dark .text-right.font-medium.text-red-600 {
    color: #dc2626 !important;
}

html.dark .font-medium.text-green-600,
html.dark .text-right.font-medium.text-green-600 {
    color: #16a34a !important;
}

/* Celdas de tabla con colores */
html.dark td.text-green-600,
html.dark td.font-bold.text-green-600,
html.dark td.text-right.font-bold.text-green-600,
html.dark td.text-right.font-bold.text-lg.text-green-600 {
    color: #16a34a !important;
}

html.dark td.text-red-600,
html.dark td.font-bold.text-red-600,
html.dark td.text-right.font-bold.text-red-600,
html.dark td.text-right.font-bold.text-lg.text-red-600 {
    color: #dc2626 !important;
}

/* Texto medium gris en modo dark (fondo claro) */
html.dark .text-gray-700 {
    color: #374151 !important;
}

html.dark .dark\:text-gray-300 {
    color: #d1d5db !important;
}

html.dark .text-sm.font-medium.text-gray-700 {
    color: #374151 !important;
}

/* =================================================================
   RESPONSIVE PARA CARDS DE MÉTRICAS - Ajuste automático de fuente
   ================================================================= */

/* Cards de métricas principales - ajuste de fuente según viewport */
.card .text-3xl.font-bold {
    font-size: clamp(1.5rem, 2vw, 1.875rem) !important;
}

/* En pantallas pequeñas, reducir más */
@media (max-width: 1280px) {
    .card .text-3xl.font-bold {
        font-size: clamp(1.25rem, 1.8vw, 1.5rem) !important;
    }
}

@media (max-width: 1024px) {
    .card .text-3xl.font-bold {
        font-size: clamp(1.125rem, 1.6vw, 1.375rem) !important;
    }
}

@media (max-width: 768px) {
    .card .text-3xl.font-bold {
        font-size: 1.5rem !important;
    }
}

/* Cards de métricas - ajuste de padding */
@media (max-width: 1280px) {
    .grid.grid-cols-1.md\:grid-cols-5 > .card {
        padding: 0.75rem !important;
    }
}

/* Text-2xl también necesita ajuste */
.card .text-2xl.font-bold {
    font-size: clamp(1.25rem, 1.8vw, 1.5rem) !important;
}

@media (max-width: 1024px) {
    .card .text-2xl.font-bold {
        font-size: clamp(1.125rem, 1.6vw, 1.375rem) !important;
    }
}

@media (max-width: 768px) {
    .card .text-2xl.font-bold {
        font-size: 1.25rem !important;
    }
}

/* Text-lg también necesita ajuste */
.card .text-lg.font-bold {
    font-size: clamp(1rem, 1.4vw, 1.125rem) !important;
}

@media (max-width: 768px) {
    .card .text-lg.font-bold {
        font-size: 1rem !important;
    }
}

/* Texto en ticker/ISIN en modo dark */
html.dark .text-gray-700 {
    color: #374151 !important;
}

html.dark .dark\:text-gray-200 {
    color: #e5e7eb !important;
}
/* =================================================================
   CORRECCIONES PARA PROPERTY.PHP EN MODO DARK (fondo claro)
   ================================================================= */

/* Textos grises que deben verse en modo dark */
html.dark .text-gray-800 {
    color: #1f2937 !important;  /* Gris muy oscuro - visible en fondo claro */
}

html.dark .dark\:text-gray-100 {
    color: #1f2937 !important;  /* Gris oscuro en modo dark (fondo claro) */
}

/* Textos en negrita pequeños - números principales */
html.dark .text-sm.font-bold.text-gray-800,
html.dark .text-sm.font-bold.dark\:text-gray-100 {
    color: #111827 !important;  /* Gris muy muy oscuro - máxima visibilidad */
}

/* Textos grandes en negrita */
html.dark .text-3xl.font-bold.text-green-600 {
    color: #15803d !important;  /* Verde muy oscuro */
}

/* Textos azules para rentabilidades */
html.dark .text-blue-400 {
    color: #1d4ed8 !important;  /* Azul muy oscuro visible en fondo claro */
}

html.dark .dark\:text-blue-300 {
    color: #1d4ed8 !important;  /* Azul muy oscuro en modo dark (fondo claro) */
}

html.dark .text-sm.font-bold.text-blue-400,
html.dark .text-sm.font-bold.dark\:text-blue-300 {
    color: #1e40af !important;  /* Azul muy oscuro para mejor contraste */
}

/* Textos verdes para cash flow positivo */
html.dark .text-green-600 {
    color: #16a34a !important;  /* Verde oscuro visible */
}

/* Fondos de cards - CLARO en modo dark */
html.dark .bg-gray-50 {
    background-color: #f9fafb !important;  /* Gris muy claro */
}

html.dark .dark\:bg-gray-800 {
    background-color: #f9fafb !important;  /* Fondo claro en modo dark */
}

/* Textos grises en labels */
html.dark .text-gray-500 {
    color: #6b7280 !important;  /* Gris medio */
}

html.dark .dark\:text-gray-400 {
    color: #6b7280 !important;  /* Gris medio en modo dark */
}

html.dark .text-gray-400 {
    color: #9ca3af !important;  /* Gris más claro */
}

html.dark .text-xs.text-gray-400 {
    color: #6b7280 !important;  /* Gris medio para textos pequeños */
}