/* --- Variables y Reseteo --- */
:root {
    --primary-color: #4a90e2;
    --primary-hover: #357abd;
    --secondary-color: #50e3c2;
    --background-color: #f7f9fc;
    --text-color: #333;
    --text-light: #6c757d;
    --card-bg: #ffffff;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 8px 30px rgba(0, 0, 0, 0.1);
    --border-radius: 16px;
    --border-color: #eaecef;
    --income-color: #2ecc71;
    --expense-color: #e74c3c;
    --gradient-primary: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    --gradient-secondary: linear-gradient(135deg, #50e3c2 0%, #3bb99d 100%);
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.2);
}

/* =================== MODO NOCHE NEW =================== */
body.dark-mode {
    --primary-color: #58a6ff;
    --primary-hover: #79b8ff;
    --secondary-color: #39d3b5;
    --background-color: #0d1117;
    --text-color: #c9d1d9;
    --text-light: #8b949e;
    --card-bg: #161b22;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    --shadow-hover: 0 8px 30px rgba(0, 0, 0, 0.3);
    --border-color: #30363d;
    --income-color: #34d399;
    --expense-color: #f87171;
    --glass-bg: rgba(22, 27, 34, 0.85);
    --glass-border: rgba(48, 54, 61, 0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter", sans-serif;
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* --- Estructura de Secciones --- */
#login-section,
#app-section,
#verify-email-section {
    display: none;
}

/* --- Loader --- */
.loader-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: var(--background-color);
    position: fixed;
    inset: 0;
    z-index: 9999;
}
.loader-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(74, 144, 226, 0.2);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* --- Login con Glassmorfismo --- */
#login-section {
    min-height: 100vh;
    width: 100%;
    background-color: #eef5ff;
    background-image: radial-gradient(
            at 40% 20%,
            hsla(28, 100%, 74%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 80% 0%,
            hsla(189, 100%, 56%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 0% 50%,
            hsla(355, 100%, 93%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 80% 50%,
            hsla(340, 100%, 76%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 0% 100%,
            hsla(22, 100%, 77%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 80% 100%,
            hsla(242, 100%, 70%, 0.3) 0px,
            transparent 50%
        ),
        radial-gradient(
            at 0% 0%,
            hsla(343, 100%, 76%, 0.3) 0px,
            transparent 50%
        );
    display: grid;
    place-items: center;
    padding: 20px;
}
#verify-email-section {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background-color: #eef5ff;
}

.login-container {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow);
    text-align: center;
    width: 100%;
    max-width: 440px;
}
.login-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 1rem;
}
.login-header i {
    font-size: 2.2rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.login-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.login-container p {
    margin-bottom: 1.8rem;
    color: var(--text-light);
    font-weight: 500;
}

#auth-form input {
    width: 100%;
    padding: 1rem;
    margin-bottom: 1.2rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.6);
}
#auth-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
    background: white;
}
#auth-form .g-recaptcha {
    margin: 0 auto 1.2rem auto;
    display: inline-block;
}
#forgot-password-link {
    display: block;
    margin-top: 1.2rem;
    font-size: 0.95rem;
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}
#forgot-password-link:hover {
    color: var(--primary-color);
}
button {
    cursor: pointer;
    border: none;
    padding: 1rem 1.8rem;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 1rem;
}
#login-btn,
#register-btn {
    width: 100%;
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow);
}
#login-btn:hover,
#register-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}
#register-btn {
    margin-top: 0.8rem;
    background: var(--gradient-secondary);
}
.error-message {
    color: var(--expense-color);
    margin-top: 1.2rem;
    font-size: 0.95rem;
    min-height: 1.2em;
    font-weight: 500;
}

/* --- App principal --- */
main#app-section {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    display: none;
}
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    flex-wrap: wrap;
    gap: 1rem;      
}
.header-left,
.header-right,
.user-profile {
    display: flex;
    align-items: center;
    gap: 20px;
}
.header-left h1 {
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.currency-selector select,
.view-toggle button {
    padding: 0.6rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    font-weight: 400;
    transition: all 0.3s ease;
}
.currency-selector select:focus {
    outline: none;
    border-color: var(--primary-color);
}
#logout-btn {
    background: none;
    color: var(--expense-color);
    padding: 0.6rem;
    border-radius: 50%;
    width: 42px;
    height: 42px;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
#logout-btn:hover {
    background-color: rgba(231, 76, 60, 0.1);
    transform: rotate(90deg);
}

.main-nav {
    display: flex;
    gap: 12px;
}
.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    padding: 0.7rem 1.2rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}
.nav-link:hover {
    background-color: #eaecef;
}
.nav-link.active {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow);
}

/* --- Tarjetas y tablas --- */
.dashboard-grid,
.tools-grid,
.budgets-grid,
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 1.8rem;
}
.card {
    background: var(--card-bg);
    padding: 1.8rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.8);
    display: flex;
    flex-direction: column;
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}
.card h2 {
    margin-bottom: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    font-size: 1.4rem;
}

.summary .summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 0;
    border-bottom: 1px solid var(--border-color);
}
.summary .summary-item:last-child {
    border-bottom: none;
}
.summary .balance strong {
    font-size: 1.8rem;
    color: var(--primary-color);
}
.income-color {
    color: var(--income-color);
    font-weight: 600;
}
.expense-color {
    color: var(--expense-color);
    font-weight: 600;
}

.chart-container {
    height: 380px;
    display: flex;
    flex-direction: column;
}
.chart-container canvas {
    flex-grow: 1;
    width: 90% !important;
    max-height: 100%;
    min-height: 0;
}
.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.actions button {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin-bottom: 1rem;
    background-color: #f7f9fc;
    color: var(--text-color);
    justify-content: flex-start;
    padding: 1rem 1.2rem;
    border-radius: 12px;
    transition: all 0.3s ease;
}
.actions button:hover {
    background-color: #eaecef;
    transform: translateX(5px);
}

.transaction-list .table-container,
.tool-content .table-container,
.reports-table-container {
    max-height: 320px;
    overflow-y: auto;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}
table {
    width: 100%;
    border-collapse: collapse;
}
.table-container {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

th,
td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}
th {
    font-weight: 600;
    color: var(--text-light);
    background-color: #f7f9fc;
    position: sticky;
    top: 0;
    z-index: 1;
}

.action-buttons button {
    background: none;
    margin-right: 8px;
    padding: 6px 10px;
    font-size: 0.9rem;
    border-radius: 8px;
}
.edit-btn {
    color: var(--primary-color);
    background: rgba(74, 144, 226, 0.1) !important;
}
.delete-btn {
    color: var(--expense-color);
    background: rgba(231, 76, 60, 0.1) !important;
}

/* --- Modales --- */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}
.modal.active {
    display: flex;
}
.modal-content {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 560px;
    position: relative;
    box-shadow: var(--shadow-hover);
    border: 1px solid var(--glass-border);
    animation: fadeInModal 0.3s ease-out;
}
@keyframes fadeInModal {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--text-light);
    transition: color 0.3s ease;
}
.close-btn:hover {
    color: var(--expense-color);
}
.form-group {
    margin-bottom: 1.2rem;
}
.form-row {
    display: flex;
    gap: 1rem;
}
.form-row .form-group {
    flex: 1;
}

#transaction-form label,
#category-form label,
#networth-form label,
.support-form label,
.tool-content label,
.budgets-form label,
.reports-filters label {
    display: block;
    margin-bottom: 0.6rem;
    font-weight: 600;
    color: var(--text-color);
}
#transaction-form input,
#transaction-form select,
#category-form input,
#networth-form input,
.support-form textarea,
.tool-content input,
.tool-content textarea,
#bulk-transaction-form textarea,
.budgets-form input,
.reports-filters input,
.reports-filters select {
    width: 100%;
    padding: 0.9rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.6);
}
#transaction-form input:focus,
#transaction-form select:focus,
#category-form input:focus,
.support-form textarea:focus,
.tool-content input:focus,
.tool-content textarea:focus,
#bulk-transaction-form textarea:focus,
.budgets-form input:focus,
.reports-filters input:focus,
.reports-filters select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
    background: white;
}

#transaction-form button,
#category-form button,
#networth-form button,
.support-form button,
.tool-content button,
#bulk-transaction-form button,
.budgets-form button,
.reports-actions button {
    width: 100%;
    margin-top: 1.2rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 12px;
    padding: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
}
#transaction-form button:hover,
#category-form button:hover,
.support-form button:hover,
.tool-content button:hover,
#bulk-transaction-form button:hover,
.budgets-form button:hover,
.reports-actions button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

#category-list {
    list-style: none;
    margin-top: 1.5rem;
    max-height: 200px;
    overflow-y: auto;
}
#category-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.9rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 0.8rem;
    background: rgba(255, 255, 255, 0.6);
}

/* --- Notificaciones --- */
.notification-toast {
    position: fixed;
    top: 25px;
    right: 25px;
    background-color: var(--expense-color);
    color: white;
    padding: 1.2rem 1.8rem;
    border-radius: 12px;
    box-shadow: var(--shadow-hover);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 15px;
    max-width: 380px;
    animation: slideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
.notification-toast.success {
    background: var(--gradient-secondary);
}
.notification-toast.info {
    background: var(--gradient-primary);
}
.close-notification {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 20px;
    padding: 0;
    margin-left: auto;
}

.content-section {
    display: none;
}
.content-section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Estilos herramientas --- */
.tool-content h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.8rem;
}
.loan-results {
    margin-top: 1.5rem;
    padding: 1.2rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #f7f9fc;
}
.loan-results p {
    display: flex;
    justify-content: space-between;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}
.loan-results strong {
    color: var(--primary-color);
}

/* --- Cuenta de Cobro --- */
.invoice-items-container {
    overflow-x: auto;
    margin-top: 1rem;
}
#invoice-items-table {
    width: 100%;
    min-width: 500px;
}
#invoice-items-table input {
    padding: 0.6rem;
    width: 100%;
}
#invoice-items-table th:nth-child(1) {
    width: 45%;
}
#invoice-items-table th:nth-child(2) {
    width: 15%;
}
#invoice-items-table th:nth-child(3) {
    width: 25%;
}
#invoice-items-table th:nth-child(4) {
    width: 15%;
}
#invoice-items-table button {
    padding: 0.6rem;
    width: auto;
    min-width: 38px;
    margin: 0;
}
.invoice-totals {
    margin-top: 1.5rem;
    text-align: right;
}
.invoice-totals p {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}
.invoice-totals strong {
    display: inline-block;
    min-width: 120px;
}
.currency-converter-inputs {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1rem;
}
.currency-converter-inputs i {
    font-size: 1.5rem;
    color: var(--text-light);
}

/* --- Presupuestos --- */
.budget-row {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 2.4fr;
    gap: 12px;
    align-items: center;
    margin-bottom: 12px;
}
.progress {
    background: #eef2f7;
    height: 14px;
    border-radius: 999px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}
.progress-bar {
    height: 100%;
    width: 0%;
    background: var(--gradient-secondary);
    transition: width 0.4s ease;
}
.progress-bar.warn {
    background: linear-gradient(135deg, #ffb020, #ff7a00);
}
.progress-bar.danger {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}
.budgets-actions {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}
.budgets-actions button {
    width: auto;
}

/* --- Informes --- */
.reports-filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    align-items: end;
    margin-bottom: 12px;
}
.reports-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 8px;
}
.reports-actions button {
    width: auto;
}
.reports-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    margin-top: 12px;
}
.reports-summary .stat {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 12px;
    background: #f7f9fc;
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 2rem;
    margin-top: 3rem;
    background-color: #eef5ff;
    color: var(--text-light);
    font-size: 0.95rem;
}
footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}
footer a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* --- Responsive --- */
@media (max-width: 992px) {
    header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
}
@media (max-width: 768px) {
    main#app-section {
        padding: 1.2rem;
    }
    .header-left,
    .header-right {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        width: 100%;
    }
    .main-nav {
        flex-wrap: wrap;
    }
    .dashboard-grid,
    .tools-grid,
    .budgets-grid,
    .reports-grid,
    .subscriptions-grid { /* <-- AÑADE ESTA LÍNEA */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 1.8rem;
}
@media (max-width: 480px) {
    .login-container,
    .modal-content,
    .card {
        padding: 1.2rem;
        border-radius: 10px;
    }

    .form-row {
        flex-direction: column;
    }

    .main-nav {
        flex-direction: column;
        gap: 6px;
    }

    .dashboard-grid,
    .tools-grid,
    .budgets-grid,
    .reports-grid {
        grid-template-columns: 1fr;
    }

    .currency-selector select,
    .view-toggle button {
        width: 100%;
    }

    .header-left h1 {
        font-size: 1.4rem;
    }

    .login-header h1 {
        font-size: 2rem;
    }

    .login-header i {
        font-size: 1.8rem;
    }

    button {
        font-size: 0.95rem;
        padding: 0.8rem 1rem;
    }

    .progress {
        height: 10px;
    }

    button,
    input,
    select,
    textarea {
        font-size: 1rem;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .nav-link i,
    .actions button i {
        font-size: 1rem;
    }

    .nav-link {
        font-size: 0.95rem;
        padding: 0.6rem 1rem;
    }
}

/* --- Soporte: ayuda/guía --- */
 .help-accordion details {
            border: 1px solid var(--border-color);
            border-radius: 12px;
            background: #fff;
            margin-bottom: 10px;
            box-shadow: var(--shadow);
    }
.help-accordion summary {
            cursor: pointer;
            padding: 0.9rem 1.1rem;
            list-style: none;
            font-weight: 600;
            color: var(--text-color);
            display: flex;
            align-items: center;
            gap: 10px;
  }
        .help-accordion .help-content {
            padding: 0 1.1rem 1.1rem 1.1rem;
            color: var(--text-color);
        }
        .help-accordion summary i {
            color: var(--primary-color);
        }
        .help-list {
            margin-top: 8px;
            padding-left: 16px;
        }
        .help-list li {
            margin: 6px 0;
    }
}
         /* Estilo para botones en estado de carga/desactivados */
        button:disabled {
        cursor: not-allowed;
        opacity: 0.75;
        }

        /* --- Soporte: ayuda/guía --- */
.help-accordion details {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    margin-bottom: 10px;
    box-shadow: var(--shadow);
}
.help-accordion summary {
    cursor: pointer;
    padding: 0.9rem 1.1rem;
    list-style: none; /* Esta es la línea clave que quita el triángulo */
    font-weight: 600;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 10px;
}
.help-accordion .help-content {
    padding: 0 1.1rem 1.1rem 1.1rem;
    color: var(--text-color);
}
.help-accordion summary i {
    color: var(--primary-color);
}
.help-list {
    margin-top: 8px;
    padding-left: 16px;
}
.help-list li {
    margin: 6px 0;
}

/* Theme switcher styles */
.theme-switcher button {
    background: none;
    color: var(--text-light);
    padding: 0.6rem;
    border-radius: 50%;
    width: 42px;
    height: 42px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}
.theme-switcher button:hover {
    color: var(--primary-color);
    background-color: rgba(74, 144, 226, 0.1);
    transform: rotate(15deg);
}
body.dark-mode .theme-switcher button:hover {
    background-color: rgba(88, 166, 255, 0.1);
}
/* Template Buttons Styles ACTION CARD */
.template-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;  
    margin-bottom: 1rem;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}

.template-buttons .template-btn {
    width: 100%;
    margin-bottom: 0;
    padding: 0.8rem;
    background-color: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-light);
    justify-content: center;
    font-size: 0.9rem;
}

.template-buttons .template-btn:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Subscription List Styles */
.subscriptions-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
    padding: 1rem;
    background-color: var(--background-color);
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
}
.subscriptions-summary strong {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.subscriptions-list {
    list-style: none;
    padding: 0;
}

.subscriptions-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 1rem;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.3s ease;
}

.subscriptions-list li:last-child {
    border-bottom: none;
}

.subscriptions-list li:hover {
    background-color: var(--background-color);
}

.subscription-info h4 {
    margin: 0;
    font-weight: 600;
    color: var(--text-color);
}

.subscription-info p {
    margin: 4px 0 0;
    font-size: 0.9rem;
    color: var(--text-light);
}

.subscription-amount {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--expense-color);
}
/* COMPARATIVA ANUAL/MES Styles */
.comparison strong {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
}

.comparison .increase {
    color: var(--expense-color);
}

.comparison .decrease {
    color: var(--income-color);
}

.comparison .increase::before {
    content: "▲";
    font-size: 0.8rem;
}

.comparison .decrease::before {
    content: "▼";
    font-size: 0.8rem;
}
/* Patrimonio Section Styles */
.networth-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.8rem;
}

.summary-networth .balance strong {
    font-size: 2.2rem;
}

.list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.list-header h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 600;
}

.add-item-btn {
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
    background: var(--gradient-secondary);
    color: white;
}

.networth-grid .table-container {
    max-height: 250px;
}

/* Seguridad Password Policy Styles */
.password-policy-container {
    text-align: left;
    font-size: 0.85rem;
    margin-top: -0.8rem;
    margin-bottom: 1.2rem;
    display: none; /* Oculto por defecto */
}

.password-policy-container p {
    margin: 4px 0 4px 10px;
    color: var(--expense-color);
    transition: color 0.3s ease;
}

.password-policy-container p.valid {
    color: var(--income-color);
}

.password-policy-container p i {
    margin-right: 8px;
    width: 15px; /* Para alinear los íconos */
}
